deface icon indicating copy to clipboard operation
deface copied to clipboard

Error: explicit providers required

Open Aziks0 opened this issue 3 years ago • 2 comments
trafficstars

I have an error using deface on Windows 10, caused by onnx, saying that providers are explicitly required since ORT 1.9.

ValueError: This ORT build has ['TensorrtExecutionProvider', 'CUDAExecutionProvider', 'CPUExecutionProvider'] enabled.
Since ORT 1.9, you are required to explicitly set the providers parameter when instantiating InferenceSession.
For example, onnxruntime.InferenceSession(..., providers=['TensorrtExecutionProvider', 'CUDAExecutionProvider',
'CPUExecutionProvider'], ...)

Aziks0 avatar Feb 22 '22 15:02 Aziks0

Mostly fixed by #22 but I'll leave this open because of the reasons I gave in #22's discussion.

mdraw avatar Mar 14 '22 00:03 mdraw

There are a lot of execution providers, which means that it would be difficult for non-power users to select the best one for them, but at the same time, non-power users probably do not use ML to anonymize images.

By checking the OS, the architecture, the GPU/CPU, it might be possible to select automatically the best provider (if the user hasn't selected any using the CLI arg for example). Many combinations are possible though, so it's a tricky solution.

Aziks0 avatar Mar 14 '22 21:03 Aziks0

This has been fixed in c5552645d69e4a1c2231d5a5b0baafc2a71de52f

mdraw avatar Oct 06 '23 18:10 mdraw