# Deepstream dynamic update configuration

**URL:** <https://forums.developer.nvidia.com/t/deepstream-dynamic-update-configuration/279823>\
**Category:** DeepStream SDK\
**Tags:** gstreamer, ubuntu\
**Created:** [January 23, 2024, 9:00am UTC](https://forums.developer.nvidia.com/t/deepstream-dynamic-update-configuration/279823 "2024-01-23T09:00:18Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![ThomaSpyrou](https://developer.download.nvidia.com/images/forums/profile-default-devtalk-84.png) [@ThomaSpyrou](https://forums.developer.nvidia.com/u/ThomaSpyrou)\
**Post date:** [January 23, 2024, 9:00am UTC](https://forums.developer.nvidia.com/t/deepstream-dynamic-update-configuration/279823/1 "2024-01-23T09:00:18Z")

</div>

Hi

I am currently working on a project where I need to create an application that can receive new configuration messages on the fly and update the DeepStream pipeline accordingly. Specifically, I would like to handle scenarios where the pipeline starts when a new stream comes in, but there’s a need to reconfigure the stream dynamically, for example, by changing the Region of Interest (ROI) size. Additionally, I am interested in dynamically removing streams from the pipeline, stopping analytics for the removed streams.

I have considered using Gst-nvdsanalytics, but it seems limited in terms of modification for new use cases beyond the ones provided in the documentation. In addition, is it possible to change the confidence threshold of the models while it’s running for one stream in a multiple stream app?

Are there any sample applications or documentation available that could provide guidance or inspiration for implementing dynamic configuration updates and stream management within a DeepStream application? I would appreciate any advice or resources you could share.

Ubuntu 22  
DS 6.4

Thank you in advance for your assistance!

---

<div class="post-metadata">

**Author:** ![AakankshaS](https://sea2.discourse-cdn.com/nvidia/user_avatar/forums.developer.nvidia.com/aakankshas/32/14047_2.png) [@AakankshaS](https://forums.developer.nvidia.com/u/AakankshaS)\
**Post date:** [January 23, 2024, 3:26pm UTC](https://forums.developer.nvidia.com/t/deepstream-dynamic-update-configuration/279823/2 "2024-01-23T15:26:45Z")

</div>

Hi @ThomaSpyrou ,  
Deepstream Forum should be able to assist you better.  
Moving the case.  
Thanks

---

<div class="post-metadata">

**Author:** ![Fiona.Chen](https://sea2.discourse-cdn.com/nvidia/user_avatar/forums.developer.nvidia.com/fiona.chen/32/15508_2.png) [@Fiona.Chen](https://forums.developer.nvidia.com/u/Fiona.Chen)\
**Post date:** [January 24, 2024, 7:18am UTC](https://forums.developer.nvidia.com/t/deepstream-dynamic-update-configuration/279823/4 "2024-01-24T07:18:30Z")

</div>

> [@ThomaSpyrou](#):
>
> I have considered using Gst-nvdsanalytics, but it seems limited in terms of modification for new use cases beyond the ones provided in the documentation.

If you want to change ROIs with new stream, that means you have to update the context for the corresponding pad inside nvdsanalytics. What kind of issue have you met with modifying the nvdsanalytics source code？

---

<div class="post-metadata">

**Author:** ![ThomaSpyrou](https://developer.download.nvidia.com/images/forums/profile-default-devtalk-84.png) [@ThomaSpyrou](https://forums.developer.nvidia.com/u/ThomaSpyrou)\
**Post date:** [January 30, 2024, 8:45am UTC](https://forums.developer.nvidia.com/t/deepstream-dynamic-update-configuration/279823/5 "2024-01-30T08:45:28Z")

</div>

It’s not an issue but mainly lack of experience, my main questions is how possible is it and if there are any examples or documentation how to do it?

Apart from the ROI how is it possible to change the confidence threshold of a model e.g. detection for just one stream following the same approach?

---

<div class="post-metadata">

**Author:** ![Fiona.Chen](https://sea2.discourse-cdn.com/nvidia/user_avatar/forums.developer.nvidia.com/fiona.chen/32/15508_2.png) [@Fiona.Chen](https://forums.developer.nvidia.com/u/Fiona.Chen)\
**Post date:** [January 30, 2024, 10:05am UTC](https://forums.developer.nvidia.com/t/deepstream-dynamic-update-configuration/279823/6 "2024-01-30T10:05:53Z")

</div>

> [@ThomaSpyrou](#):
>
> It’s not an issue but mainly lack of experience, my main questions is how possible is it and if there are any examples or documentation how to do it?

The proper way is to set the pipeline to NULL state and you change the new source and set new configurations to any elements in the pipeline.

> [@ThomaSpyrou](#):
>
> Apart from the ROI how is it possible to change the confidence threshold of a model e.g. detection for just one stream following the same approach?

Do you mean you want to apply different cluster algorithms to different streams in the same batch? Currently it is not supported. You can implement by yourself by customize your own postprocessing with setting “output-tensor-meta=1” and “network-type=100” of gst-nvinfer. Then you can write your own postprocessing including cluster algorithm by yourself. [Gst-nvinfer — DeepStream documentation](https://docs.nvidia.com/metropolis/deepstream/dev-guide/text/DS_plugin_gst-nvinfer.html)

---

<div class="post-metadata">

**Author:** ![ThomaSpyrou](https://developer.download.nvidia.com/images/forums/profile-default-devtalk-84.png) [@ThomaSpyrou](https://forums.developer.nvidia.com/u/ThomaSpyrou)\
**Post date:** [January 30, 2024, 1:42pm UTC](https://forums.developer.nvidia.com/t/deepstream-dynamic-update-configuration/279823/7 "2024-01-30T13:42:46Z")

</div>

Thanks Fiona for the info I will take a better look on that.

No I don’t mean different algorithms, if I have the same classifier (nvinfer) running analytics for multiple streams can I change the confidence of the classifier for one stream and remain the same for the others.

---

<div class="post-metadata">

**Author:** ![Fiona.Chen](https://sea2.discourse-cdn.com/nvidia/user_avatar/forums.developer.nvidia.com/fiona.chen/32/15508_2.png) [@Fiona.Chen](https://forums.developer.nvidia.com/u/Fiona.Chen)\
**Post date:** [January 31, 2024, 5:09am UTC](https://forums.developer.nvidia.com/t/deepstream-dynamic-update-configuration/279823/8 "2024-01-31T05:09:00Z")

</div>

> [@ThomaSpyrou](#):
>
> can I change the confidence of the classifier for one stream and remain the same for the others.

Do you mean to change the “pre-cluster-threshold/post-cluster-threshold” parameters dynamically? [Gst-nvinfer — DeepStream 6.1.1 Release documentation](https://docs.nvidia.com/metropolis/deepstream/6.1.1/dev-guide/text/DS_plugin_gst-nvinfer.html#id3)

---

<div class="post-metadata">

**Author:** ![ThomaSpyrou](https://developer.download.nvidia.com/images/forums/profile-default-devtalk-84.png) [@ThomaSpyrou](https://forums.developer.nvidia.com/u/ThomaSpyrou)\
**Post date:** [February 5, 2024, 10:30am UTC](https://forums.developer.nvidia.com/t/deepstream-dynamic-update-configuration/279823/9 "2024-02-05T10:30:14Z")

</div>

> [@Fiona.Chen](#):
>
> post-cluster-threshold

Yes, I would like to change the

- classifier-threshold
- pre-cluster-threshold
- post-cluster-threshold

for each stream dynamically/on the fly.

Is that possible?

---

<div class="post-metadata">

**Author:** ![Fiona.Chen](https://sea2.discourse-cdn.com/nvidia/user_avatar/forums.developer.nvidia.com/fiona.chen/32/15508_2.png) [@Fiona.Chen](https://forums.developer.nvidia.com/u/Fiona.Chen)\
**Post date:** [February 6, 2024, 1:33am UTC](https://forums.developer.nvidia.com/t/deepstream-dynamic-update-configuration/279823/10 "2024-02-06T01:33:27Z")

</div>

It is possible. The gst-nvinfer is open source, you may change the code to do it.

---

<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:** [February 24, 2024, 6:02am UTC](https://forums.developer.nvidia.com/t/deepstream-dynamic-update-configuration/279823/11 "2024-02-24T06:02:37Z")

</div>

Closed on February 24, 2024, 6:02am UTC

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