# Failed to create 'sink\_sub\_bin\_encoder1'

**URL:** <https://forums.developer.nvidia.com/t/failed-to-create-sink-sub-bin-encoder1/296325>\
**Category:** DeepStream SDK\
**Created:** [June 13, 2024, 1:35pm UTC](https://forums.developer.nvidia.com/t/failed-to-create-sink-sub-bin-encoder1/296325 "2024-06-13T13:35:46Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![walid.brini](https://sea2.discourse-cdn.com/nvidia/user_avatar/forums.developer.nvidia.com/walid.brini/32/229231_2.png) [@walid.brini](https://forums.developer.nvidia.com/u/walid.brini)\
**Post date:** [June 13, 2024, 1:35pm UTC](https://forums.developer.nvidia.com/t/failed-to-create-sink-sub-bin-encoder1/296325/1 "2024-06-13T13:35:46Z")

</div>

**• Hardware Platform (Jetson / GPU)** Jetson  
**• DeepStream Version** 6.0.1  
\*\*• JetPack Version (valid for Jetson only)\*\*4.6.  
**• TensorRT Version**  
**• Issue Type( questions, new requirements, bugs)** Failed to create ‘sink\_sub\_bin\_encoder1’

**• 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)**  
Running the sample app :  
`sudo deepstream-app -c source2_1080p_dec_infer-resnet_demux_int8.txt`

Hello, i have installed jetpack 4.6.4 on a jetson nano using the sdk manager, then installed deepstream 6.0.1, i’m having issues with the encoder plugin :

```auto
sudo deepstream-app -c source2_1080p_dec_infer-resnet_demux_int8.txt 
** ERROR: <create_encode_file_bin:372>: Failed to create 'sink_sub_bin_encoder1'
** ERROR: <create_encode_file_bin:467>: create_encode_file_bin failed
** ERROR: <create_sink_bin:781>: create_sink_bin failed
** ERROR: <create_processing_instance:815>: create_processing_instance failed
** ERROR: <create_pipeline:1326>: create_pipeline failed
** ERROR: <main:688>: Failed to create pipeline
Quitting
App run failed

```

And when i try to run :

```auto
/opt/nvidia/deepstream/deepstream-6.0/samples/configs/deepstream-app$ gst-launch-1.0 videotestsrc ! nvvidconv ! nvv4l2h264enc ! filesink location=out1.h264
WARNING: erroneous pipeline: no element "nvv4l2h264enc"

```

Although `vv4l2h264enc` is a component of the library `libgstnvvideo4linux2.so` and it exists :

```auto
/usr/lib/aarch64-linux-gnu/gstreamer-1.0$ ls | grep ibgstnvvideo4linux2.so
libgstnvvideo4linux2.so

```

I also tried to clear the gstreamer cache and i’m still facing the same error, any help will be appreciated !

---

<div class="post-metadata">

**Author:** ![yuweiw](https://sea2.discourse-cdn.com/nvidia/user_avatar/forums.developer.nvidia.com/yuweiw/32/101255_2.png) [@yuweiw](https://forums.developer.nvidia.com/u/yuweiw)\
**Post date:** [June 14, 2024, 2:51am UTC](https://forums.developer.nvidia.com/t/failed-to-create-sink-sub-bin-encoder1/296325/3 "2024-06-14T02:51:49Z")

</div>

Could you try to set the `codec=2` and see if it works?

---

<div class="post-metadata">

**Author:** ![walid.brini](https://sea2.discourse-cdn.com/nvidia/user_avatar/forums.developer.nvidia.com/walid.brini/32/229231_2.png) [@walid.brini](https://forums.developer.nvidia.com/u/walid.brini)\
**Post date:** [June 14, 2024, 8:57am UTC](https://forums.developer.nvidia.com/t/failed-to-create-sink-sub-bin-encoder1/296325/4 "2024-06-14T08:57:42Z")

</div>

> [@yuweiw](#):
>
> codec

I have changed the codec and i’m getting the same error:

```auto
deepstream-app -c source2_1080p_dec_infer-resnet_demux_int8.txt 
** ERROR: <create_encode_file_bin:372>: Failed to create 'sink_sub_bin_encoder1'
** ERROR: <create_encode_file_bin:467>: create_encode_file_bin failed
** ERROR: <create_sink_bin:781>: create_sink_bin failed
** ERROR: <create_processing_instance:815>: create_processing_instance failed
** ERROR: <create_pipeline:1326>: create_pipeline failed
** ERROR: <main:688>: Failed to create pipeline
Quitting
App run failed

```

[source2\_1080p\_dec\_infer-resnet\_demux\_int8.txt](https://forums.developer.nvidia.com/uploads/short-url/h98fWxQLBOrpiPZyx46fqNQagvy.txt) (4.4 KB)

Even by trying to change the encoder to software encoding, i get a different error:

```auto
deepstream-app -c source2_1080p_dec_infer-resnet_demux_int8.txt 
serialize cuda engine to file: /opt/nvidia/deepstream/deepstream-6.0/samples/models/Primary_Detector/resnet10.caffemodel_b1_gpu0_fp16.engine successfully
INFO: [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:01:26.497668151 24046 0xc4fe490 INFO nvinfer gstnvinfer_impl.cpp:313:notifyLoadModelStatus:<primary_gie> [UID 1]: Load new model:/opt/nvidia/deepstream/deepstream-6.0/samples/configs/deepstream-app/config_infer_primary.txt sucessfully

Runtime commands:
        h: Print this help
        q: Quit

        p: Pause
        r: Resume

**PERF: FPS 0 (Avg) FPS 1 (Avg)
**PERF: 0.00 (0.00) 0.00 (0.00)
** INFO: <bus_callback:194>: Pipeline ready

(deepstream-app:24046): GStreamer-CRITICAL **: 09:56:16.379: gst_caps_is_empty: assertion 'GST_IS_CAPS (caps)' failed

(deepstream-app:24046): GStreamer-CRITICAL **: 09:56:16.380: gst_caps_is_empty: assertion 'GST_IS_CAPS (caps)' failed

(deepstream-app:24046): GStreamer-CRITICAL **: 09:56:16.380: gst_caps_truncate: assertion 'GST_IS_CAPS (caps)' failed

(deepstream-app:24046): GStreamer-CRITICAL **: 09:56:16.380: gst_caps_truncate: assertion 'GST_IS_CAPS (caps)' failed

(deepstream-app:24046): GStreamer-CRITICAL **: 09:56:16.380: gst_caps_fixate: assertion 'GST_IS_CAPS (caps)' failed

(deepstream-app:24046): GStreamer-CRITICAL **: 09:56:16.380: gst_caps_fixate: assertion 'GST_IS_CAPS (caps)' failed

(deepstream-app:24046): GStreamer-CRITICAL **: 09:56:16.380: gst_caps_get_structure: assertion 'GST_IS_CAPS (caps)' failed

(deepstream-app:24046): GStreamer-CRITICAL **: 09:56:16.380: gst_caps_get_structure: assertion 'GST_IS_CAPS (caps)' failed

(deepstream-app:24046): GStreamer-CRITICAL **: 09:56:16.380: gst_structure_get_string: assertion 'structure != NULL' failed

(deepstream-app:24046): GStreamer-CRITICAL **: 09:56:16.380: gst_structure_get_string: assertion 'structure != NULL' failed

(deepstream-app:24046): GStreamer-CRITICAL **: 09:56:16.380: gst_mini_object_unref: assertion 'mini_object != NULL' failed

(deepstream-app:24046): GStreamer-CRITICAL **: 09:56:16.380: gst_mini_object_unref: assertion 'mini_object != NULL' failed
NvMMLiteOpen : Block : BlockType = 261 
NVMEDIA: Reading vendor.tegra.display-size : status: 6 
NvMMLiteBlockCreate : Block : BlockType = 261 
NvMMLiteOpen : Block : BlockType = 261 
NVMEDIA: Reading vendor.tegra.display-size : status: 6 
Allocating new output: 1920x1088 (x 9), ThumbnailMode = 0
OPENMAX: HandleNewStreamFormat: 3605: Send OMX_EventPortSettingsChanged: nFrameWidth = 1920, nFrameHeight = 1080 
NvMMLiteBlockCreate : Block : BlockType = 261 
Allocating new output: 1920x1088 (x 9), ThumbnailMode = 0
OPENMAX: HandleNewStreamFormat: 3605: Send OMX_EventPortSettingsChanged: nFrameWidth = 1920, nFrameHeight = 1080 
** INFO: <bus_callback:180>: Pipeline running

ERROR from src_bin_muxer: Input buffer number of surfaces (0) must be equal to mux->num_surfaces_per_frame (1)
        Set nvstreammux property num-surfaces-per-frame appropriately

Debug info: /dvs/git/dirty/git-master_linux/deepstream/sdk/src/gst-plugins/gst-nvmultistream/gstnvstreammux.c(495): gst_nvstreammux_chain (): /GstPipeline:pipeline/GstBin:multi_src_bin/GstNvStreamMux:src_bin_muxer
ERROR from omxh264dec-omxh264dec1: Internal data stream error.
Debug info: /dvs/git/dirty/git-master_linux/3rdparty/gst/gst-omx/omx/gstomxvideodec.c(3005): gst_omx_video_dec_loop (): /GstPipeline:pipeline/GstBin:multi_src_bin/GstBin:src_sub_bin1/GstURIDecodeBin:src_elem/GstDecodeBin:decodebin1/GstOMXH264Dec-omxh264dec:omxh264dec-omxh264dec1:
stream stopped, reason error
ERROR from queue: Internal data stream error.
Debug info: gstqueue.c(988): gst_queue_handle_sink_event (): /GstPipeline:pipeline/GstBin:multi_src_bin/GstBin:src_sub_bin1/GstQueue:queue:
streaming stopped, reason error (-5)
ERROR from qtdemux0: Internal data stream error.
Debug info: qtdemux.c(6073): gst_qtdemux_loop (): /GstPipeline:pipeline/GstBin:multi_src_bin/GstBin:src_sub_bin1/GstURIDecodeBin:src_elem/GstDecodeBin:decodebin1/GstQTDemux:qtdemux0:
streaming stopped, reason error (-5)
Quitting
ERROR from src_bin_muxer: Input buffer number of surfaces (0) must be equal to mux->num_surfaces_per_frame (1)
        Set nvstreammux property num-surfaces-per-frame appropriately

Debug info: /dvs/git/dirty/git-master_linux/deepstream/sdk/src/gst-plugins/gst-nvmultistream/gstnvstreammux.c(495): gst_nvstreammux_chain (): /GstPipeline:pipeline/GstBin:multi_src_bin/GstNvStreamMux:src_bin_muxer
ERROR from omxh264dec-omxh264dec0: Internal data stream error.
Debug info: /dvs/git/dirty/git-master_linux/3rdparty/gst/gst-omx/omx/gstomxvideodec.c(3005): gst_omx_video_dec_loop (): /GstPipeline:pipeline/GstBin:multi_src_bin/GstBin:src_sub_bin0/GstURIDecodeBin:src_elem/GstDecodeBin:decodebin0/GstOMXH264Dec-omxh264dec:omxh264dec-omxh264dec0:
stream stopped, reason error
ERROR from queue: Internal data stream error.
Debug info: gstqueue.c(988): gst_queue_handle_sink_event (): /GstPipeline:pipeline/GstBin:multi_src_bin/GstBin:src_sub_bin0/GstQueue:queue:
streaming stopped, reason error (-5)
ERROR from qtdemux1: Internal data stream error.
Debug info: qtdemux.c(6073): gst_qtdemux_loop (): /GstPipeline:pipeline/GstBin:multi_src_bin/GstBin:src_sub_bin0/GstURIDecodeBin:src_elem/GstDecodeBin:decodebin0/GstQTDemux:qtdemux1:
streaming stopped, reason error (-5)
App run failed

```

---

<div class="post-metadata">

**Author:** ![yuweiw](https://sea2.discourse-cdn.com/nvidia/user_avatar/forums.developer.nvidia.com/yuweiw/32/101255_2.png) [@yuweiw](https://forums.developer.nvidia.com/u/yuweiw)\
**Post date:** [June 14, 2024, 9:50am UTC](https://forums.developer.nvidia.com/t/failed-to-create-sink-sub-bin-encoder1/296325/5 "2024-06-14T09:50:30Z")

</div>

If you want to use software encoding, you need to install the x264enc plugin.

Could you run the command `gst-inspect-1.0 nvv4l2h264enc`?

---

<div class="post-metadata">

**Author:** ![walid.brini](https://sea2.discourse-cdn.com/nvidia/user_avatar/forums.developer.nvidia.com/walid.brini/32/229231_2.png) [@walid.brini](https://forums.developer.nvidia.com/u/walid.brini)\
**Post date:** [June 14, 2024, 12:11pm UTC](https://forums.developer.nvidia.com/t/failed-to-create-sink-sub-bin-encoder1/296325/6 "2024-06-14T12:11:27Z")

</div>

I have managed to fix the issue by reinstalling the NVIDIA BSP packages :

```auto
sudo apt install --reinstall nvidia-l4t-gstreamer
sudo apt install --reinstall nvidia-l4t-multimedia
sudo apt install --reinstall nvidia-l4t-core

```

---

<div class="post-metadata">

**Author:** ![system](https://sea2.discourse-cdn.com/nvidia/user_avatar/forums.developer.nvidia.com/system/32/68080_2.png) [@system](https://forums.developer.nvidia.com/u/system)\
**Post date:** [June 28, 2024, 12:11pm UTC](https://forums.developer.nvidia.com/t/failed-to-create-sink-sub-bin-encoder1/296325/7 "2024-06-28T12:11:53Z")

</div>

Closed on June 28, 2024, 12:11pm UTC

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