Fame latencty

Please provide complete information as applicable to your setup.

• Hardware Platform (GPU)
• DeepStream Version 6.1 - Docker environment

I exported these 2 ENV variables
To enable frame latency measurement, run this command on the console:

To enable latency for all plugins, run this command on the console:

This is the result I got when running with this DS example deepstream-app -c source4_1080p_dec_infer-resnet_tracker_sgie_tiled_display_int8.txt

I have 2 questions:
Q1: component latency is the time which the model run the inference for a batch, right? and is it in milisecond or second or any other?
ex: Comp name = primary_gie in_system_timestamp = 1679977821364.743896 out_system_timestamp = 1679977821365.792969 component latency= 1.049072

Q2: How do you guys calculate Frame latency? I saw it took Frame latency = 265.649902 ???
ex: Source id = 0 Frame_num = 56 Frame latency = 265.649902 (ms)

Many thanks.

Q1: Yes. It’s milisecond of Unix Timestamp.
Q2: You can refer to the nvds_measure_buffer_latency API in sources\includes\nvds_latency_meta.h.

It is computed from decoder input up to the point this API is called.
1 Like

I enable the latency measurement and try to print latency log with custom deepstream app but I see nothing.
How can my custom ds app work with latency measurement?

You can refer to the link below:

could you help me one more question?
I implemented 2 more customs plugins
decode → muxer-> nvpreprocess → nvinfer → demux → custom-plugin1 → custom-plugin 2

I cannot print latency measurement log with my custom gst plugins. Does it really work with custom plugins? If yes, where can I get the reference in deepstream source code?


You can refer to the open source code: sources\includes\nvds_latency_meta.h. Try to set the nvds_set_input_system_timestamp API in your own plugin.
If you have any other issues, please open a new topic. Thanks

1 Like

thank you so much, I got it

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