-
Notifications
You must be signed in to change notification settings - Fork 691
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
fix(autoware_lidar_transfusion): set tensor names by matching with predefined values. #9057
fix(autoware_lidar_transfusion): set tensor names by matching with predefined values. #9057
Conversation
Thank you for contributing to the Autoware project! 🚧 If your pull request is in progress, switch it to draft mode. Please ensure:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for PR! Only one minor change requested.
perception/autoware_lidar_transfusion/lib/network/network_trt.cpp
Outdated
Show resolved
Hide resolved
e2a28e1
to
2dfbe77
Compare
Signed-off-by: Samrat Thapa <samratthapa120@gmail.com>
Signed-off-by: Samrat Thapa <samratthapa120@gmail.com>
Signed-off-by: Samrat Thapa <samratthapa120@gmail.com>
Signed-off-by: Samrat Thapa <samratthapa120@gmail.com>
2dfbe77
to
9a3e6b7
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Please, merge this PR with model update PR at the same time.
23bb4a0
into
autowarefoundation:main
…edefined values. (autowarefoundation#9057) * set tensor order using api Signed-off-by: Samrat Thapa <samratthapa120@gmail.com> * style(pre-commit): autofix Signed-off-by: Samrat Thapa <samratthapa120@gmail.com> * fix tensor order Signed-off-by: Samrat Thapa <samratthapa120@gmail.com> * style(pre-commit): autofix Signed-off-by: Samrat Thapa <samratthapa120@gmail.com> * style fix Signed-off-by: Samrat Thapa <samratthapa120@gmail.com> * style(pre-commit): autofix --------- Signed-off-by: Samrat Thapa <samratthapa120@gmail.com> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Description
When making minor architectural changes to onnx checkpoints, we found that the tensorrt IO tensor order changed, which results in the current code failing because the order of tensors is fixed in current code.
autoware.universe/perception/autoware_lidar_transfusion/include/autoware/lidar_transfusion/utils.hpp
Line 39 in c2438fd
It seems that the tensor output order of the optimized tensorrt engine can be different from onnx IO order, but the tensor names match the onnx IO names. So, it is better to use the names from trt engine API to find the IO tensor positions.
We also found out that the current deployed models have faulty output names i.e the names of dir_cls_pred0 and bbox_pred0 are swapped, so they do not work with this PR. Therefore, we had to update the deployed onnx models with this PR.
Related links
Merge with autowarefoundation/autoware#5318
Parent Issue:
How was this PR tested?
Tested using TIER IV's test rosbags locally within docker environment.
Tested using webauto evaluator. Only once test fails, because the lidar does not include intensity field in it, and transfusion requires intensity value to function properly
Notes for reviewers
None.
Interface changes
None.