I am using DeepStream 7.1 with Python bindings and I am trying to access the output tensors of a classifier when using nvdspreprocess together with input-tensor-meta=1. My objective is to retrieve one classifier output tensor for each ROI generated by the preprocessing stage, but I have been unable to access the corresponding NvDsInferTensorMeta.
I understand that when input-tensor-meta=1 is enabled in DeepStream 7.1, the tensor metadata is attached as user metadata inside NvDsRoiMeta, which is then attached to the frame metadata.
Since I am using Python, I found that NvDsRoiMeta bindings are available in DeepStream 8.0 (bindroimeta.cpp) but not in the DeepStream 7.1 Python bindings. NVIDIA suggested porting the relevant binding code from DeepStream 8.0 and rebuilding pyds.
I have ported the NvDsRoiMeta bindings from DeepStream 8.0 into the DeepStream 7.1 deepstream_python_apps source code and successfully rebuilt the Python bindings.
Functionality: Access the NvDsInferTensorMeta generated by nvinfer for each ROI produced by nvdspreprocess.
Expected result: Retrieve the output tensor and associate it with its corresponding ROI from Python.
At this point, I would appreciate some guidance on how to traverse the metadata hierarchy and retrieve the NvDsInferTensorMeta associated with each ROI. A Python example would be especially helpful.
Based on the title and content of your topic, it looks like it may receive better visibility and feedback in a different category. We took the liberty of moving it for you.
If this was an incorrect assessment, please send me a direct message.
Disclaimer: this moderation suggestion and message were generated with AI assistance.
Thank you for your reply.
We have tested the solution you suggested, but when using the pre-processor to generate multiple ROIs, the metadata is shared differently.
Furthermore, the version of Deepstream you recommend is not available for the Jetson Orin Nx, the last one is DS 7.1.
Sorry for overlooking the fact that you are using Orin NX and cannot upgrade to the latest DeepStream version. Bindings for NvDsRoiMeta are already supported in the pyds for DS-8.0; you can simply port this functionality to DS-7.1.