Skip to content
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

failed to legalize operation 'torch.operator' that was explicitly marked illegal : onnx.NonMaxSuppression #892

Open
pdhirajkumarprasad opened this issue Dec 6, 2024 · 1 comment
Assignees

Comments

@pdhirajkumarprasad
Copy link

For the given IR, getting error ' failed to legalize operation 'torch.operator' that was explicitly marked illegal : onnx.NonMaxSuppression'

module {
  func.func @main_graph( %arg1: !torch.vtensor<[1,?,4],f32>, %arg2: !torch.vtensor<[1,1,?],f32>) -> (!torch.vtensor<[?,3],si64> ) attributes {torch.onnx_meta.ir_version = 8 : si64, torch.onnx_meta.opset_version = 21 : si64, torch.onnx_meta.producer_name = "pytorch", torch.onnx_meta.producer_version = "2.1.0"} {
    %1 = torch.operator "onnx.Constant"() {torch.onnx.value = dense_resource<__329> : tensor<1xsi64>} : () -> !torch.vtensor<[1],si64> 
    %2 = torch.operator "onnx.Constant"() {torch.onnx.value = dense_resource<__330> : tensor<1xf32>} : () -> !torch.vtensor<[1],f32> 
    %3 = torch.operator "onnx.NonMaxSuppression"(%arg1, %arg2, %1, %2) : (!torch.vtensor<[1,?,4],f32>, !torch.vtensor<[1,1,?],f32>, !torch.vtensor<[1],si64>, !torch.vtensor<[1],f32>) -> !torch.vtensor<[?,3],si64> 
    return %3: !torch.vtensor<[?,3],si64>
  }
}

{-#
  dialect_resources: {
    builtin: {
      __329: "0x08000000FFFFFFFFFFFFFF7F",
      __330: "0x080000003333333F"
    }
  }
#-}
@pdhirajkumarprasad
Copy link
Author

model impacted : 24

fasterrcnn_mobilenet_v3_large_320_fpn_Opset17_torchvision
maskrcnn_resnet50_fpn_v2_Opset16_torchvision
retinanet_resnet50_fpn_v2_Opset18_torchvision
retinanet_resnet50_fpn_v2_Opset17_torchvision
fcos_resnet50_fpn_Opset17_torchvision
fasterrcnn_mobilenet_v3_large_fpn_Opset16_torchvision
fasterrcnn_mobilenet_v3_large_fpn_Opset18_torchvision
fasterrcnn_mobilenet_v3_large_320_fpn_Opset18_torchvision
fasterrcnn_mobilenet_v3_large_320_fpn_Opset16_torchvision
MaskRCNN-12
MaskRCNN-12-qdq
MaskRCNN-10
maskrcnn_resnet50_fpn_v2_Opset17_torchvision
fasterrcnn_resnet50_fpn_v2_Opset17_torchvision
retinanet_resnet50_fpn_v2_Opset16_torchvision
FasterRCNN-12
fasterrcnn_resnet50_fpn_v2_Opset18_torchvision
FasterRCNN-12-qdq
FasterRCNN-10
fcos_resnet50_fpn_Opset18_torchvision
fcos_resnet50_fpn_Opset16_torchvision
fasterrcnn_mobilenet_v3_large_fpn_Opset17_torchvision
maskrcnn_resnet50_fpn_v2_Opset18_torchvision
fasterrcnn_resnet50_fpn_v2_Opset16_torchvision

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants