Ask Your Question

zacdiggum's profile - activity

2018-11-09 17:05:49 -0600 asked a question how to use dnn face detector in TF?

how to use dnn face detector in TF? I'd like to use the UINT8 face detector model from dnn module directly through TF on

2016-06-06 03:36:20 -0600 asked a question re-encode video

Hi,

in my Python app I record a temporary video with fps being unpredictable when constructing the VideoWriter object. I use this one merely for collecting frames coming from some lengthy calculations. When done, I re-encode the temporary video to a new video with different fps in order to synchronize the video play length with the timestamp written to the video frames. Here is a snippet:

for i in np.arange(num_frames):
        _, frame = video_tmp.read()
        video_out.write( cv2.cvtColor(frame, cv2.COLOR_RGB2GRAY) )

where video_tmp is the temporary video and video_out is the video with different fps.

Basically, my questions are:

Is it possible to just 'set' the new fps without encoding again?

If not, could encoding be done not frame-wise but in parallel?

I'm aware of the possibility to call ffmpeg externally for re-encoding. I just hoped, I could do it with OpenCV somehow.

Thanks in advance...