DeepStream-Yolo icon indicating copy to clipboard operation
DeepStream-Yolo copied to clipboard

Saving video with python biding DeepStream

Open mam1680 opened this issue 2 years ago • 1 comments

Hi I have a question: I want to save the video with deepstream_test1.py and I add this part to my code:

    sink = Gst.ElementFactory.make("filesink", "filesink")
    if not sink:
        sys.stderr.write(" Unable to create file sink \n")

    sink.set_property("location", "./out.mp4")
    sink.set_property("sync", 1)
    sink.set_property("async", 0)

but it keeps running after 4 frames and won't stop (like it is in an infinite loop) what's the problem?

mam1680 avatar Sep 03 '23 08:09 mam1680

To save mp4 video you need: nvvideoconvert (caps format=I420) -> nvv4l2h264enc -> h264parse -> qtmux -> filesink.

marcoslucianops avatar Sep 05 '23 12:09 marcoslucianops