Deepstream python app deepstream-test3 Unable to create NvStreamMux

I recently installed deepstream 4.0 and downloaded the python binding, I tried to run the deepstrem_test_3.py and I copied the sample_1080p_h264.mp4 video to the same folder as .py file

then I run the command “python3 deepstream_test_3.py sample_1080p_h264.mp4”
which gives an error: Unable to create NvStreamMux
can anyone tell me how to solve it?
nv1.PNG
nv2.PNG

e.g.
$ python3 deepstream_test_3.py file:///home/ubuntu/video1.mp4 file:///home/ubuntu/video2.mp4

i copy the mp4 to home/ubuntu/, and runt he code it still doesnt work

$ python3 deepstream_test_3.py file:///home/ubuntu/video.mp4
deepstream_test_3.py:221: PyGIDeprecationWarning: Since version 3.11, calling threads_init is no longer needed. See: https://wiki.gnome.org/PyGObject/Threading
  GObject.threads_init()
Creating Pipeline 
 
Creating streamux 
 
 Unable to create NvStreamMux 
Traceback (most recent call last):
  File "deepstream_test_3.py", line 346, in <module>
    sys.exit(main(sys.argv))
  File "deepstream_test_3.py", line 238, in main
    pipeline.add(streammux)
TypeError: Argument 1 does not allow None as a value

i tried to run code like this in jupyter notebook, it seems that Gst.ElementFactory.make cannot make ‘nvstreammux’

streammux = Gst.ElementFactory.make("nvstreammux", "Stream-muxer")
print(streammux)
None

Can you detect nvstreammux plugin?
gst-inspect-1.0 nvstreammux

Hi Zhangliao322,

Can you detect nvstreammux plugin? Any result can be shared?

I typed ‘gst-inspect-1.0 nvstreammux’ and it says: No such element or plugin ‘nvstreammux’

Please check your environments, make sure you can find nvstreammux plugin first. you can follow README to setup
the environments.