Add files via upload
apparently, onnxruntime 1.9 and later require that the available providers be explicitly listed as an argument in InferenceSession() or i was getting that error anyway, and it was preventing OpenSeeFace from working i'm running Arch Linux using the build of python-onnxruntime available in the AUR anyway, i edited tracker.py and retinaface.py to find the list of available providers and pass that argument and that makes it work for me! yay!
This commit is contained in:
parent
9aff345720
commit
0204d8a4a7
2 changed files with 10 additions and 5 deletions
|
|
@ -66,7 +66,8 @@ class RetinaFaceDetector():
|
|||
options.execution_mode = onnxruntime.ExecutionMode.ORT_SEQUENTIAL
|
||||
options.graph_optimization_level = onnxruntime.GraphOptimizationLevel.ORT_ENABLE_ALL
|
||||
options.log_severity_level = 3
|
||||
self.session = onnxruntime.InferenceSession(model_path, sess_options=options)
|
||||
providersList = onnxruntime.capi._pybind_state.get_available_providers()
|
||||
self.session = onnxruntime.InferenceSession(model_path, sess_options=options, providers=providersList)
|
||||
self.res_w, self.res_h = res
|
||||
with open(json_path, "r") as prior_file:
|
||||
self.priorbox = np.array(json.loads(prior_file.read()))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue