mirror of https://github.com/open-mmlab/mmcv.git
[Fix] Fix boxes.scalar_type in nms_npu (#2731)
parent
bc727f7132
commit
bfdd1f9c42
|
@ -4,7 +4,7 @@ using namespace NPU_NAME_SPACE;
|
|||
using namespace std;
|
||||
|
||||
Tensor nms_npu(Tensor boxes, Tensor scores, float iou_threshold, int offset) {
|
||||
TORCH_CHECK((boxes.scalar_type == at::ScalarType::Float),
|
||||
TORCH_CHECK((boxes.scalar_type() == at::ScalarType::Float),
|
||||
"The type of boxes tensor passed in nms_npu should be float");
|
||||
int64_t offset_64 = offset;
|
||||
at::Tensor iou_threshold_y = at_npu::native::OpPreparation::ApplyTensor(
|
||||
|
|
Loading…
Reference in New Issue