An issue with gst-nvdsanalytics with .yml files

Please provide complete information as applicable to your setup.

• Hardware Platform (Jetson / GPU)
• DeepStream Version 6.3
• JetPack Version (valid for Jetson only)
• TensorRT Version
• NVIDIA GPU Driver Version (valid for GPU only)
• Issue Type( questions, new requirements, 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)
• Requirement details( This is for new requirement. Including the module name-for which plugin or for which sample application, the function description)

There is an issue with nvdsanalytics when it parses the yml files. The line and the other features are not drawn correctly on the output. I believe the issue is related with attaching the config-width: and config-height:from the yml file. It is only occur with the yml files not txt files. So I have checked the nvdsanalytics_property_yaml_parser.cpp in the gst-nvdsanalytics plugin, which has a function nvdsanalytics_parse_yaml_config_file will be called when the yml file is applied. I compare it with the nvdsanalytics_property_parser.cpp which is for parsing the txt files and it has a function called nvdsanalytics_parse_config_file. At the end of nvdsanalytics_parse_config_file there is a for loop to attach the width and height of the nvdsanayltics which is not existed in nvdsanalytics_parse_yaml_config_fileafter I added it in the yml parser function it works

for (auto & info:nvdsanalytics->stream_analytics_info[0]) {
    info.second.config_width = nvdsanalytics->configuration_width;
    info.second.config_height = nvdsanalytics->configuration_height;

thanks for the sharing! I will check.

could you elaborate on “The line and the other features are not drawn correctly”? Thanks! what kind of line and other features are not drawn correctly? or could you provide a screenshot?

Try to to parse any nvdsanalytics yml file which has line-crossing entry and leaving for example. Is the the line drawn correctly on the output or not?

  1. are you sure the fix works? you can use the following code to test. info.second.config_width already is the same with nvdsanalytics->configuration_width before setting.
    for (auto & info:nvdsanalytics->stream_analytics_info[0]) {

    printf(“w:%d,h:%d, w:%d,h:%d\n”, info.second.config_width, info.second.config_height,
    nvdsanalytics->configuration_width, nvdsanalytics->configuration_height);
    info.second.config_width = nvdsanalytics->configuration_width;
    info.second.config_height = nvdsanalytics->configuration_height;

  2. how to reproduce your issue? could you share the cfg file and abnormal screenshot? Thanks! are you using sample_720p.mp4? what is source’s resolution?

**There is no update from you for a period, assuming this is not an issue any more. Hence we are closing this topic. If need further support, please open a new one. Thanks.**T
hanks for the sharing! please refer to this fix for bug “output video can’t show ROI label name and direction line”.
fix-64.txt (1010 Bytes)

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