Closed
Description
Hi there,
I'm running into the issue described in #2370 when trying to run the electron
example in tfjs-examples
, but the recipes given there do not appear to help. Some more info below:
TensorFlow.js version
1.3.2
Browser version
74.0.3729.131
Node version
12.9.1 (also tried 10.13.0, 10.16.3)
Platform
CentOS Linux release 7.6.1810 (Core)
Describe the problem or feature request
Running the electron example at https://github.com/tensorflow/tfjs-examples/tree/master/electron results in:
node-pre-gyp info This Node instance does not support builds for N-API version 4
node-pre-gyp info This Node instance does not support builds for N-API version 4
App threw an error during load
Error: Cannot find module '/home/research/tfjs-examples/electron/node_modules/@tensorflow/tfjs-node/lib/napi-v3/tfjs_binding.node'
at Module._resolveFilename (internal/modules/cjs/loader.js:584:15)
at Function.Module._resolveFilename (/home/research/tfjs-examples/electron/node_modules/electron/dist/resources/electron.asar/common/reset-search-paths.js:43:12)
at Function.Module._load (internal/modules/cjs/loader.js:510:25)
at Module.require (internal/modules/cjs/loader.js:640:17)
at require (internal/modules/cjs/helpers.js:20:18)
at Object.<anonymous> (/home/research/tfjs-examples/electron/node_modules/@tensorflow/tfjs-node/dist/index.js:44:16)
at Object.<anonymous> (/home/research/tfjs-examples/electron/node_modules/@tensorflow/tfjs-node/dist/index.js:66:3)
at Module._compile (internal/modules/cjs/loader.js:693:30)
at Object.require.extensions.(anonymous function) [as .js] (/home/research/tfjs-examples/electron/node_modules/electron-compile/lib/require-hook.js:77:14)
at Module.load (internal/modules/cjs/loader.js:602:32)
A JavaScript error occurred in the main process
Uncaught Exception:
Error: Cannot find module '/home/research/tfjs-examples/electron/node_modules/@tensorflow/tfjs-node/lib/napi-v3/tfjs_binding.node'
at Module._resolveFilename (internal/modules/cjs/loader.js:584:15)
at Function.Module._resolveFilename (/home/research/tfjs-examples/electron/node_modules/electron/dist/resources/electron.asar/common/reset-search-paths.js:43:12)
at Function.Module._load (internal/modules/cjs/loader.js:510:25)
at Module.require (internal/modules/cjs/loader.js:640:17)
at require (internal/modules/cjs/helpers.js:20:18)
at Object.<anonymous> (/home/research/tfjs-examples/electron/node_modules/@tensorflow/tfjs-node/dist/index.js:44:16)
at Object.<anonymous> (/home/research/tfjs-examples/electron/node_modules/@tensorflow/tfjs-node/dist/index.js:66:3)
at Module._compile (internal/modules/cjs/loader.js:693:30)
at Object.require.extensions.(anonymous function) [as .js] (/home/research/tfjs-examples/electron/node_modules/electron-compile/lib/require-hook.js:77:14)
at Module.load (internal/modules/cjs/loader.js:602:32)
npm rebuild @tensorflow/tfjs-node --build-from-source
seems to run fine but doesn't fix the problem. The mnist-node
example runs without issues. Please let me know if you have any idea what could be going wrong.