Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
MMCV
Commits
5df759ad
Unverified
Commit
5df759ad
authored
Feb 05, 2021
by
RunningLeon
Committed by
GitHub
Feb 05, 2021
Browse files
[Fix]: add header file for std::iota(#803) (#820)
* add header to std::iota * fix lint * fix lint for cpp
parent
459d728c
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
1 deletion
+3
-1
mmcv/ops/csrc/onnxruntime/cpu/nms.cpp
mmcv/ops/csrc/onnxruntime/cpu/nms.cpp
+1
-0
mmcv/ops/nms.py
mmcv/ops/nms.py
+2
-1
No files found.
mmcv/ops/csrc/onnxruntime/cpu/nms.cpp
View file @
5df759ad
...
@@ -6,6 +6,7 @@
...
@@ -6,6 +6,7 @@
#include <cmath>
#include <cmath>
#include <iostream>
#include <iostream>
#include <iterator>
#include <iterator>
#include <numeric> // std::iota
#include <vector>
#include <vector>
#include "../ort_mmcv_utils.h"
#include "../ort_mmcv_utils.h"
...
...
mmcv/ops/nms.py
View file @
5df759ad
...
@@ -291,7 +291,8 @@ def batched_nms(boxes, scores, idxs, nms_cfg, class_agnostic=False):
...
@@ -291,7 +291,8 @@ def batched_nms(boxes, scores, idxs, nms_cfg, class_agnostic=False):
nms_op
=
eval
(
nms_type
)
nms_op
=
eval
(
nms_type
)
split_thr
=
nms_cfg_
.
pop
(
'split_thr'
,
10000
)
split_thr
=
nms_cfg_
.
pop
(
'split_thr'
,
10000
)
if
boxes_for_nms
.
shape
[
0
]
<
split_thr
:
# Won't split to multiple nms nodes when exporting to onnx
if
boxes_for_nms
.
shape
[
0
]
<
split_thr
or
torch
.
onnx
.
is_in_onnx_export
():
dets
,
keep
=
nms_op
(
boxes_for_nms
,
scores
,
**
nms_cfg_
)
dets
,
keep
=
nms_op
(
boxes_for_nms
,
scores
,
**
nms_cfg_
)
boxes
=
boxes
[
keep
]
boxes
=
boxes
[
keep
]
scores
=
dets
[:,
-
1
]
scores
=
dets
[:,
-
1
]
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment