Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Handling Buffer Accumulation in DeepStream Pipeline with Slow Inference Speed (app-source) #1140

Open
YoungjaeDev opened this issue Jan 22, 2024 · 3 comments
Assignees
Labels
question Further information is requested

Comments

@YoungjaeDev
Copy link
Collaborator

I previously shared a setup where I read an image buffer from a Redis server, converted it into a GStreamer buffer, and then created a DeepStream pipeline through an app-source. The buffer is ultimately pushed using this C++ code:

DslReturnType retval = dsl_source_app_buffer_push(L"app-source", buffer);

Now, in this setup where I'm using a player(interpipe-source) for DeepStream inference, I'm concerned about the scenario where the inference speed might be slower than the image push speed. In such a case, would image buffers continuously accumulate in a certain queue?
If yes, is there an existing structure that allows for the dropping of these accumulating buffers to prevent overload?
I'm currently using a fake-sink.

Thank you

@YoungjaeDev YoungjaeDev added the question Further information is requested label Jan 22, 2024
@rjhowell44
Copy link
Collaborator

@youngjae-avikus I plan to add two new component services to allow you to set the max-size of the input queue to any component... and control the leaky property. See https://gstreamer.freedesktop.org/documentation/coreelements/queue.html#queue:leaky. With this you can set the queue to drop (leak) either the oldest or newest buffers when max queue size is reached.

Let me know if this meets your needs.

@YoungjaeDev
Copy link
Collaborator Author

@youngjae-avikus I plan to add two new component services to allow you to set the max-size of the input queue to any component... and control the leaky property. See https://gstreamer.freedesktop.org/documentation/coreelements/queue.html#queue:leaky. With this you can set the queue to drop (leak) either the oldest or newest buffers when max queue size is reached.

Let me know if this meets your needs.

It seems to be true that things are accumulating in the queue.
In my case, maybe I set max-queue-size is 1, and my goal would be to inference the latest buffer at any time.
And it would be nice if there was an alarm if system was to be pushed back.

@rjhowell44
Copy link
Collaborator

This work is now covered by issue #1225

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants