Use Onnxruntime in C# with Unity for iOS: Can't load DLL 'onnxruntime' #14913
Unanswered
digitalmonkey
asked this question in
Other Q&A
Replies: 1 comment
-
Similar issue with dotnet maui |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I have a Unity App which uses the C# onnxruntime. It works fine on my MacOS device. When I build it for iOS, I created the Xcode file and manually added the iOS framework (I tried both the framework and xcframework) to the project. I'm able to compile and install on device and run the app. However, since onnxruntime is dynamically loaded, the moment my first onnxruntime code gets hit, I get the following error:
DllNotFoundException: Unable to load DLL 'onnxruntime'. Tried the load the following dynamic libraries: Unable to load dynamic library '/onnxruntime' because of 'Failed to open the requested dynamic library (0x06000000) dlerror() = dlopen(/onnxruntime, 0x0005): tried: '/onnxruntime' (errno=2), '/private/preboot/Cryptexes/OS/onnxruntime' (errno=2), '/onnxruntime' (errno=2)
It's a silent failure, in that it doesn't crash, none of my inference code is run either. I tried various ways of embedding the binary, but I just can't seem to open it. Anyone have any ideas?
Beta Was this translation helpful? Give feedback.
All reactions