i have again an issues.
these command execute and wroking good. video streaming also.
------>1.
nawab@nawab-desktop:~$ gst-launch-1.0 -ev rtspsrc location=rtsp://admin:pass1234@192.168.1.204:554/mpeg4/media.amp ! application/x-rtp, media=video, encoding-name=H264, payload=96 ! rtph264depay ! h264parse ! nvv4l2decoder ! nvvidconv ! video/x-raw, format=BGRx, width=640, height=480 ! videoconvert ! xvimagesink
----->2.
root@nawab-desktop:/jetson-inference# detectnet.py --input-rtsp-latency=0 rtsp://admin:pass1234@192.168.1.204:554/test
------>But when I run my custom python programme then RTSP camera not working: error is below:
root@nawab-desktop:/my-detection# python3 my-camera.py
jetson.inference – detectNet loading build-in network ‘ssd-mobilenet-v2’
detectNet – loading detection network model from:
– model networks/SSD-Mobilenet-v2/ssd_mobilenet_v2_coco.uff
– input_blob ‘Input’
– output_blob ‘NMS’
– output_count ‘NMS_1’
– class_labels networks/SSD-Mobilenet-v2/ssd_coco_labels.txt
– threshold 0.500000
– batch_size 1
[TRT] TensorRT version 8.2.1
[TRT] loading NVIDIA plugins…
[TRT] Registered plugin creator - ::GridAnchor_TRT version 1
[TRT] Registered plugin creator - ::GridAnchorRect_TRT version 1
[TRT] Registered plugin creator - ::NMS_TRT version 1
[TRT] Registered plugin creator - ::Reorg_TRT version 1
[TRT] Registered plugin creator - ::Region_TRT version 1
[TRT] Registered plugin creator - ::Clip_TRT version 1
[TRT] Registered plugin creator - ::LReLU_TRT version 1
[TRT] Registered plugin creator - ::PriorBox_TRT version 1
[TRT] Registered plugin creator - ::Normalize_TRT version 1
[TRT] Registered plugin creator - ::ScatterND version 1
[TRT] Registered plugin creator - ::RPROI_TRT version 1
[TRT] Registered plugin creator - ::BatchedNMS_TRT version 1
[TRT] Registered plugin creator - ::BatchedNMSDynamic_TRT version 1
[TRT] Could not register plugin creator - ::FlattenConcat_TRT version 1
[TRT] Registered plugin creator - ::CropAndResize version 1
[TRT] Registered plugin creator - ::DetectionLayer_TRT version 1
[TRT] Registered plugin creator - ::EfficientNMS_TRT version 1
[TRT] Registered plugin creator - ::EfficientNMS_ONNX_TRT version 1
[TRT] Registered plugin creator - ::EfficientNMS_TFTRT_TRT version 1
[TRT] Registered plugin creator - ::Proposal version 1
[TRT] Registered plugin creator - ::ProposalLayer_TRT version 1
[TRT] Registered plugin creator - ::PyramidROIAlign_TRT version 1
[TRT] Registered plugin creator - ::ResizeNearest_TRT version 1
[TRT] Registered plugin creator - ::Split version 1
[TRT] Registered plugin creator - ::SpecialSlice_TRT version 1
[TRT] Registered plugin creator - ::InstanceNormalization_TRT version 1
[TRT] detected model format - UFF (extension ‘.uff’)
[TRT] desired precision specified for GPU: FASTEST
[TRT] requested fasted precision for device GPU without providing valid calibrator, disabling INT8
[TRT] [MemUsageChange] Init CUDA: CPU +230, GPU +0, now: CPU 254, GPU 1934 (MiB)
[TRT] [MemUsageSnapshot] Begin constructing builder kernel library: CPU 254 MiB, GPU 1939 MiB
[TRT] [MemUsageSnapshot] End constructing builder kernel library: CPU 283 MiB, GPU 1944 MiB
[TRT] native precisions detected for GPU: FP32, FP16
[TRT] selecting fastest native precision for GPU: FP16
[TRT] attempting to open engine cache file /usr/local/bin/networks/SSD-Mobilenet-v2/ssd_mobilenet_v2_coco.uff.1.1.8201.GPU.FP16.engine
[TRT] loading network plan from engine cache… /usr/local/bin/networks/SSD-Mobilenet-v2/ssd_mobilenet_v2_coco.uff.1.1.8201.GPU.FP16.engine
[TRT] device GPU, loaded /usr/local/bin/networks/SSD-Mobilenet-v2/ssd_mobilenet_v2_coco.uff
[TRT] [MemUsageChange] Init CUDA: CPU +0, GPU +0, now: CPU 288, GPU 1930 (MiB)
[TRT] Loaded engine size: 33 MiB
[TRT] Using cublas as a tactic source
[TRT] [MemUsageChange] Init cuBLAS/cuBLASLt: CPU +158, GPU -14, now: CPU 465, GPU 1932 (MiB)
[TRT] Using cuDNN as a tactic source
^[[TRT] [MemUsageChange] Init cuDNN: CPU +240, GPU +6, now: CPU 705, GPU 1938 (MiB)
[TRT] Deserialization required 35919065 microseconds.
[TRT] [MemUsageChange] TensorRT-managed allocation in engine deserialization: CPU +0, GPU +33, now: CPU 0, GPU 33 (MiB)
[TRT] Using cublas as a tactic source
[TRT] [MemUsageChange] Init cuBLAS/cuBLASLt: CPU +0, GPU +4, now: CPU 705, GPU 1930 (MiB)
[TRT] Using cuDNN as a tactic source
[TRT] [MemUsageChange] Init cuDNN: CPU +1, GPU +0, now: CPU 706, GPU 1930 (MiB)
[TRT] Total per-runner device persistent memory is 22241792
[TRT] Total per-runner host persistent memory is 118624
[TRT] Allocated activation device memory of size 13250560
[TRT] [MemUsageChange] TensorRT-managed allocation in IExecutionContext creation: CPU +0, GPU +34, now: CPU 0, GPU 67 (MiB)
[TRT]
[TRT] CUDA engine context initialized on device GPU:
[TRT] – layers 132
[TRT] – maxBatchSize 1
[TRT] – deviceMemory 13250560
[TRT] – bindings 3
[TRT] binding 0
– index 0
– name ‘Input’
– type FP32
– in/out INPUT
– # dims 3
– dim #0 3
– dim #1 300
– dim #2 300
[TRT] binding 1
– index 1
– name ‘NMS’
– type FP32
– in/out OUTPUT
– # dims 3
– dim #0 1
– dim #1 100
– dim #2 7
[TRT] binding 2
– index 2
– name ‘NMS_1’
– type FP32
– in/out OUTPUT
– # dims 3
– dim #0 1
– dim #1 1
– dim #2 1
[TRT]
[TRT] binding to input 0 Input binding index: 0
[TRT] binding to input 0 Input dims (b=1 c=3 h=300 w=300) size=1080000
[TRT] binding to output 0 NMS binding index: 1
[TRT] binding to output 0 NMS dims (b=1 c=1 h=100 w=7) size=2800
[TRT] binding to output 1 NMS_1 binding index: 2
[TRT] binding to output 1 NMS_1 dims (b=1 c=1 h=1 w=1) size=4
[TRT]
[TRT] device GPU, /usr/local/bin/networks/SSD-Mobilenet-v2/ssd_mobilenet_v2_coco.uff initialized.
[TRT] W = 7 H = 100 C = 1
[TRT] detectNet – maximum bounding boxes: 100
[TRT] detectNet – loaded 91 class info entries
[TRT] detectNet – number of object classes: 91
[gstreamer] initialized gstreamer, version 1.14.5.0
[gstreamer] gstCamera – attempting to create device rtspsrc location=rtsp://admin.pass1234@192.168.1.204:554/axis-media/media.amp latency=0 ! rtph264depay ! h264parse ! nvv4l2decoder ! nvvidconv ! video2/x-raw, format=BGRx, width=640, height=480
[gstreamer] gstCamera pipeline string:
[gstreamer] v4l2src device=admin.pass1234@192.168.1.204 ! video/x-raw, format=(string) , width=(int)640, height=(int)480 ! appsink name=mysink
[gstreamer] gstCamera failed to create pipeline
[gstreamer] (could not parse caps “video/x-raw, format=(string) , width=(int)640, height=(int)480”)
[gstreamer] gstCamera – failed to create device rtspsrc location=rtsp://admin.pass1234@192.168.1.204:554/axis-media/media.amp latency=0 ! rtph264depay ! h264parse ! nvv4l2decoder ! nvvidconv ! video2/x-raw, format=BGRx, width=640, height=480
Traceback (most recent call last):
File “my-camera.py”, line 5, in
camera = jetson.utils.gstCamera(640, 480, "rtspsrc location=rtsp://admin.pass1234@192.168.1.204:554/axis-media/media.amp latency=0 ! rtph264depay ! h264parse ! nvv4l2decoder ! nvvidconv ! video2/x-raw, format=BGRx, width=640, height=480 ")
Exception: jetson.utils – failed to create gstCamera device
kindly help me sir.