huggingface / huggingface/transformers.js
Windows 10 electron example app onnxruntime_binding.node not found
- Dominant language
- JavaScript
- Stars
- 16.3k
- Forks
- 1.2k
- Avg merge
- 6d 2h
- Merged PRs (30d)
- 6
Description
### System Info
transformers.js: ^2.6.2
Using the example app here https://github.com/xenova/transformers.js/tree/main/examples/electron
Tried both node 18 & 20 on fresh windows 10 home bootcamp install on an intel mac.
### Environment/Platform
- [ ] Website/web-app
- [ ] Browser extension
- [ ] Server-side (e.g., Node.js, Deno, Bun)
- [X] Desktop app (e.g., Electron)
- [ ] Other (e.g., VSCode extension)
### Description
```Error occurred in handler for 'transformers:run': Error: The specified module could not be found.
\\?\C:\Users\samto\Desktop\transformers.js\examples\electron\node_modules\onnxruntime-node\bin\napi-v3\win32\x64\onnxruntime_binding.node
at process.func [as dlopen] (node:electron/js2c/asar_bundle:2:1869)
at Module._extensions..node (node:internal/modules/cjs/loader:1326:18)
at Object.func [as .node] (node:electron/js2c/asar_bundle:2:1869)
at Module.load (node:internal/modules/cjs/loader:1096:32)
at Module._load (node:internal/modules/cjs/loader:937:12)
at f._load (node:electron/js2c/asar_bundle:2:13377)
at Module.require (node:internal/modules/cjs/loader:1120:19)
at require (node:internal/modules/cjs/helpers:103:18)
at Object. (C:\Users\samto\Desktop\transformers.js\examples\electron\node_modules\onnxruntime-node\dist\binding.js:9:1)
at Module._compile (node:internal/modules/cjs/loader:1241:14) {
code: 'ERR_DLOPEN_FAILED'
}
```
### Reproduction
On Windows 10 Home:
1. git clone https://github.com/xenova/transformers.js/tree/main/examples/electron
2. cd transformers.js\examples\electron
3. npm i
4. npm run start
5. enter something in the text box that appears on screen
Just tested this same flow on a mac and it works fine...
Thanks in advance for any help!
Contributor guide
Assessment
This issue has not been assessed yet.