-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
add ort nms op #803
add ort nms op #803
Conversation
Codecov Report
@@ Coverage Diff @@
## master #803 +/- ##
==========================================
+ Coverage 61.94% 62.23% +0.29%
==========================================
Files 144 144
Lines 8467 8506 +39
Branches 1520 1521 +1
==========================================
+ Hits 5245 5294 +49
+ Misses 2954 2947 -7
+ Partials 268 265 -3
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
@grimoire Would you help review this PR? |
@hellock Sure, I will do it. |
Hi @tangyanf, thanks for your contribution! if torch.onnx.is_in_onnx_export() and offset == 1:
# ONNX only support offset == 1
boxes[:, -2:] += 1
inds = NMSop.apply(boxes, scores, iou_threshold, offset)
if torch.onnx.is_in_onnx_export() and offset == 1:
# ONNX only support offset == 1
boxes[:, -2:] -= 1 |
* start trt plugin prototype * Add test module, modify roialign convertor * finish roi_align trt plugin * fix conflict of RoiAlign and MMCVRoiAlign * fix for lint * fix test tensorrt module * test_tensorrt move import to test func * add except error type * add tensorrt to setup.cfg * code format with yapf * fix for clang-format * move tensorrt_utils to mmcv/tensorrt, add comments, better test module * fix line endings, docformatter * isort init, remove trailing whitespace * add except type * fix setup.py * put import extension inside trt setup * change c++ guard, update pytest script, better setup, etc * sort import with isort * sort import with isort * move init of plugin lib to init_plugins.py * add scatternd, nms plugin (WIP) * fix bugs of trt_nms * add trt nms test module * fix bugs of scatternd * code optimize, add comment about nms kernel * fix transform_if bug of trt_nms_kernel * fix struct name * default nms offset=0, fix bugs of batched input * format with clang-format * onnx preprocess * much better nms implementation, no need to transfer memory between host and device * update preprocess_onnx * parse constant tensor from initializer in preprocess_onnx * update nms * remove unnecessary codes * workspace aligned address * format trt_plugin_helper.hpp * fix index memory bugs * set alignment to 16 by default * fix lint * fix nms offset * fix bugs of preprocess onnx * update test for nms * tensorrt only accept int32, not int64 * update nms comments * fix indexing for scores in nms * update trt temp * make trt-nms compatiable to #803 * fix lint * add docstring to trt_nms_kernel.cuda, add description to preprocess_onnx * add comment to score indexing * fix bugs of max output boxes Co-authored-by: maningsheng <maningsheng@sensetime.com>
add onnxruntime custom op: nms