UltralyticsAssistant 3 months ago
parent b5a973f833
commit 088c0f4e3b
  1. 7
      ultralytics/nn/autobackend.py

@ -177,12 +177,11 @@ class AutoBackend(nn.Module):
providers = ["CUDAExecutionProvider", "CPUExecutionProvider"] if cuda else ["CPUExecutionProvider"]
if mct:
from sony_custom_layers.pytorch.object_detection import nms_ort
import mct_quantizers as mctq
session = onnxruntime.InferenceSession(w,
mctq.get_ort_session_options(),
providers=["CPUExecutionProvider"])
session = onnxruntime.InferenceSession(
w, mctq.get_ort_session_options(), providers=["CPUExecutionProvider"]
)
task = "detect"
else:
session = onnxruntime.InferenceSession(w, providers=providers)

Loading…
Cancel
Save