You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm converting the YOLOv9 model to ONNX for use with NVIDIA DeepStream. Inside FastModelLoader, the _create_onnx_model function appears to handle the PyTorch-to-ONNX conversion. However, when I run this function, it outputs a list of 17 tensors with shapes like:
This is unexpected, as DeepStream typically expects a single output tensor or structured outputs containing bounding boxes (batch_size, num_boxes, 4), class confidence scores (batch_size, num_boxes, num_classes), and objectness scores (batch_size, num_boxes, 1).
How should I interpret these tensors and correctly format them for inference in DeepStream?
The text was updated successfully, but these errors were encountered:
Currently, the model outputs predictions at three different levels (20, 40, 80). For each resolution, it produces three types of outputs:
• 80 → class predictions
• 16×4 → grid information
• 4 → bounding box coordinates
Additionally, these outputs come from two branches: auxiliary and main. This results in a total of:
3 levels × 3 output types × 2 branches = 18 outputs.
Typically, we use PostProcess to select the main branch’s outputs and apply NMS to the predictions. The shape (batch_size, num_boxes, 4) is not robust because the number of boxes varies for each image. Customizing PostProcess with padding may help address this issue.
I'm converting the YOLOv9 model to ONNX for use with NVIDIA DeepStream. Inside
FastModelLoader
, the_create_onnx_model
function appears to handle the PyTorch-to-ONNX conversion. However, when I run this function, it outputs a list of 17 tensors with shapes like:This is unexpected, as DeepStream typically expects a single output tensor or structured outputs containing bounding boxes
(batch_size, num_boxes, 4)
, class confidence scores(batch_size, num_boxes, num_classes)
, and objectness scores(batch_size, num_boxes, 1)
.How should I interpret these tensors and correctly format them for inference in DeepStream?
The text was updated successfully, but these errors were encountered: