Skip to content
This repository has been archived by the owner on Feb 11, 2022. It is now read-only.

install error: fatal error: '../node_modules/@tensorflow/tfjs-node/deps/include/tensorflow/c/c_api.h' file not found #44

Open
superzoey opened this issue May 20, 2020 · 3 comments

Comments

@superzoey
Copy link

sudo npm --registry http://registry.npm.taobao.org install test-ai-classifier --unsafe-perm


use command install with error like below:

CXX(target) Release/obj.target/test-ai-classifier/cc/main.o
In file included from ../cc/main.cc:3:
../cc/detection.h:6:10: fatal error: '../node_modules/@tensorflow/tfjs-node/deps/include/tensorflow/c/c_api.h' file not found
#include "../node_modules/@tensorflow/tfjs-node/deps/include/tensorflow/c/c_api.h"
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.
make: *** [Release/obj.target/test-ai-classifier/cc/main.o] Error 1
gyp ERR! build error
gyp ERR! stack Error: make failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23)
gyp ERR! stack at ChildProcess.emit (events.js:198:13)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:248:12)
gyp ERR! System Darwin 18.7.0
gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /usr/local/lib/node_modules/appium/node_modules/test-ai-classifier
gyp ERR! node -v v10.16.3
gyp ERR! node-gyp -v v5.1.0
gyp ERR! not ok
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] install: node-gyp rebuild
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

@vikasthange
Copy link

Facing exactly same issue.

@vikasthange
Copy link

#33

@abbassabeti
Copy link

I had the exactly same issue. This resolved the issue for me:

npm install node-pre-gyp
npm install --unsafe-perm --verbose node-sass
npm install node-gyp --unsafe-perm=true
npm install @tensorflow/tfjs-node
npm install test-ai-classifier

reference: https://stackoverflow.com/a/65280741/9792460

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants