Skip to content

Commit

Permalink
Merge pull request #100 from Pbatch/pb_onnx
Browse files Browse the repository at this point in the history
Add providers argument to support new ONNX versions
  • Loading branch information
Pbatch authored Dec 4, 2023
2 parents 84b5e2b + 3d9fe32 commit a786beb
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion clashroyalebuildabot/state/onnx_detector.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@ class OnnxDetector:
def __init__(self, model_path):
self.model_path = model_path

self.sess = onnxruntime.InferenceSession(self.model_path)
self.sess = onnxruntime.InferenceSession(self.model_path,
providers=['CPUExecutionProvider'])
self.output_name = self.sess.get_outputs()[0].name
self.input_name = self.sess.get_inputs()[0].name

Expand Down

0 comments on commit a786beb

Please sign in to comment.