How to derived a new column using value_counts for one column with another columns : <p>I have dataframe which consists with many columns. </p>

<pre><code>df2



   TargetDescription                               Output_media_duration
0   VMN 4.0 16x9 25 - 1920x1080, 1280x720, 960x540...    NaN
1   VMN 4.0 16x9 25 - 1920x1080, 1280x720, 960x540...    NaN
2   XDCAM HD NTSC 1920x1080 MXF 8CA                      661.120000
3   VMN 4.0 16x9 29.97 - 1920x1080, 1280x720, 960x...   285.647686
4   VMN 4.0 16x9 29.97 - 1920x1080, 1280x720, 960x...   402.697303
5   VMN 4.0 16x9 29.97 - 1920x1080, 1280x720, 960x...   269.597070
6   VMN 4.0 16x9 29.97 - 1920x1080, 1280x720, 960x...   307.059607
7   Caption QC HD MOV 2CA                               2516.096917
8   QT Proxy 640x360 2997 12CA                          NaN
9   XDCAM HD NTSC 1920x1080 MXF 8CA                     1414.785215
10  Caption QC HD MOV 2CA                               1295.027067
11  QT Proxy 640x360 2398 4CA                           2524.980792
12  Caption QC HD MOV 2CA                               120.820700
13  Caption QC HD MOV 2CA                               2516.096917
</code></pre>

<p>Now I want to get one new dataframe which would show me like this </p>

<pre><code>TargetDescription                                                     format_duration
1   VMN 4.0 16x9 25 - 1920x1080, 1280x720, 960x540...                       NaN
2   XDCAM HD NTSC 1920x1080 MXF 8CA                                         661.120000
3   VMN 4.0 16x9 29.97 - 1920x1080, 1280x720, 960x...                       1656.561906 
4   Caption QC HD MOV 2CA                                                   2516.096917
5   QT Proxy 640x360 2997 12CA                                              NaN
6   Caption QC HD MOV 2CA                                                   2636.917
</code></pre>

<p>How can I achieve this in pandas,thanks in advance</p>
