How can i save the complete frames with bounding boxes and get rtsp out in x_86 system?

Please provide complete information as applicable to your setup.

• Hardware Platform (Jetson / GPU) Geforce 3090
• DeepStream Version 6.1-triton
• JetPack Version (valid for Jetson only)
• TensorRT Version 8.2.5.1
• NVIDIA GPU Driver Version (valid for GPU only) 510.47.03
• Issue Type( questions, new requirements, bugs) bugs
• How to reproduce the issue ? (This is for bugs. Including which sample app is using, the configuration files content, the command line used and other details for reproducing)

Docker Image Url: nvcr.io/nvidia/deepstream:6.1-triton
Exec into the image and installed the depends
Sample App: python3 deepstream_test1_rtsp_out.py
I tryed to save the frame in deepstream_test1_rtsp_out and experiment with adding the following codes:



while l_obj is not None:
try:
# Casting l_obj.data to pyds.NvDsObjectMeta
obj_meta=pyds.NvDsObjectMeta.cast(l_obj.data)
except StopIteration:
break
obj_counter[obj_meta.class_id] += 1
try:
l_obj=l_obj.next
except StopIteration:
break

    n_frame = pyds.get_nvds_buf_surface(hash(gst_buffer), frame_meta.batch_id)
    frame_number = frame_meta.frame_num
    img_folder = "/opt/nvidia/deepstream/deepstream/sources/deepstream_python_apps/apps/deepstream-test1-rtsp-out/frames"
    img_path = "{}/stream_{}/frame_{}.jpg".format(img_folder, frame_meta.pad_index, frame_number)
    print(img_path)
    print("frame_shape = ",n_frame.shape)
    print(n_frame)
    cv2.imwrite(img_path, n_frame)

    # Acquiring a display meta object. The memory ownership remains in
    # the C code so downstream plugins can still access it. Otherwise
    # the garbage collector will claim it when this probe function exits.
    display_meta=pyds.nvds_acquire_display_meta_from_pool(batch_meta)
    display_meta.num_labels = 1
    py_nvosd_text_params = display_meta.text_params[0]
    .....
    .....

Failed Logs:
Creating Pipeline

Creating Source

Creating H264Parser

Creating Decoder

Creating H264 Encoder
Creating H264 rtppay
Playing file /opt/nvidia/deepstream/deepstream/samples/streams/sample_720p.h264
Adding elements to Pipeline

Linking elements in the Pipeline

*** DeepStream: Launched RTSP Streaming at rtsp://localhost:8554/ds-test ***

Starting pipeline

0:00:08.723336403 213 0x3e2ba10 WARN nvinfer gstnvinfer.cpp:643:gst_nvinfer_logger: NvDsInferContext[UID 1]: Warning from NvDsInferContextImpl::initialize() <nvdsinfer_context_impl.cpp:1161> [UID = 1]: Warning, OpenCV has been deprecated. Using NMS for clustering instead of cv::groupRectangles with topK = 20 and NMS Threshold = 0.5
0:00:11.190440787 213 0x3e2ba10 INFO nvinfer gstnvinfer.cpp:646:gst_nvinfer_logger: NvDsInferContext[UID 1]: Info from NvDsInferContextImpl::deserializeEngineAndBackend() <nvdsinfer_context_impl.cpp:1900> [UID = 1]: deserialized trt engine from :/opt/nvidia/deepstream/deepstream-6.1/samples/models/Primary_Detector/resnet10.caffemodel_b1_gpu0_int8.engine
INFO: …/nvdsinfer/nvdsinfer_model_builder.cpp:610 [Implicit Engine Info]: layers num: 3
0 INPUT kFLOAT input_1 3x368x640
1 OUTPUT kFLOAT conv2d_bbox 16x23x40
2 OUTPUT kFLOAT conv2d_cov/Sigmoid 4x23x40

0:00:11.229110522 213 0x3e2ba10 INFO nvinfer gstnvinfer.cpp:646:gst_nvinfer_logger: NvDsInferContext[UID 1]: Info from NvDsInferContextImpl::generateBackendContext() <nvdsinfer_context_impl.cpp:2003> [UID = 1]: Use deserialized engine model: /opt/nvidia/deepstream/deepstream-6.1/samples/models/Primary_Detector/resnet10.caffemodel_b1_gpu0_int8.engine
0:00:11.230478778 213 0x3e2ba10 INFO nvinfer gstnvinfer_impl.cpp:328:notifyLoadModelStatus: [UID 1]: Load new model:dstest1_pgie_config.txt sucessfully
/opt/nvidia/deepstream/deepstream/sources/deepstream_python_apps/apps/deepstream-test1-rtsp-out/frames/stream_0/frame_0.jpg
frame_shape = (1080, 1920, 4)

Segmentation fault (core dumped)

How can i save the complete frames with bounding boxes and get rtsp out in X_86 system?

• Requirement details( This is for new requirement. Including the module name-for which plugin or for which sample application, the function description)

Seems this is duplicated to How to save the complete frames and get rtsp out within x_86 system docker container - Intelligent Video Analytics / DeepStream SDK - NVIDIA Developer Forums, we will close this one.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.