Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot get model file successfully #63

Closed
lijiarui opened this issue Oct 13, 2017 · 3 comments
Closed

Cannot get model file successfully #63

lijiarui opened this issue Oct 13, 2017 · 3 comments

Comments

@lijiarui
Copy link
Contributor

lijiarui commented Oct 13, 2017

when try npm install get the following error

> cd python3 && if [ -d facenet ]; then (cd facenet && git pull); else git clone https://github.com/davidsandberg/facenet.git; fi && cd -

Already up-to-date.
/Users/jiaruili/git/rui/node-facenet

> facenet@0.3.19 postinstall:models /Users/jiaruili/git/rui/node-facenet
> set -e && if [ ! -d models ]; then mkdir models; fi && cd models && if [ ! -f model.tar.bz2 ]; then curl --location --output model.tar.bz2.tmp https://github.com/zixia/node-facenet/releases/download/v0.1.9/model-20170512.tar.bz2; mv model.tar.bz2.tmp model.tar.bz2; fi && tar jxvf model.tar.bz2 && cd -

x 20170512-110547.pb
x model-20170512-110547.ckpt-250000.data-00000-of-00001: (Empty error message)
tar: Error exit delayed from previous errors.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! facenet@0.3.19 postinstall:models: `set -e && if [ ! -d models ]; then mkdir models; fi && cd models && if [ ! -f model.tar.bz2 ]; then curl --location --output model.tar.bz2.tmp https://github.com/zixia/node-facenet/releases/download/v0.1.9/model-20170512.tar.bz2; mv model.tar.bz2.tmp model.tar.bz2; fi && tar jxvf model.tar.bz2 && cd -`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the facenet@0.3.19 postinstall:models script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/jiaruili/.npm/_logs/2017-10-13T11_26_46_320Z-debug.log
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! facenet@0.3.19 postinstall: `npm run venv && npm run postinstall:facenet && npm run postinstall:models`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the facenet@0.3.19 postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/jiaruili/.npm/_logs/2017-10-13T11_26_46_397Z-debug.log

Cannot install it successfully. Could you help to find the reason?

I found the reason is facenet@0.3.19 postinstall: npm run venv && npm run postinstall:facenet && npm run postinstall:models
When I try npm run venv and npm run postinstall:facenet, it works well, but when I try npm run postinstall:models, get the same error as follows:

> facenet@0.3.19 postinstall:models /Users/jiaruili/git/rui/node-facenet
> set -e && if [ ! -d models ]; then mkdir models; fi && cd models && if [ ! -f model.tar.bz2 ]; then curl --location --output model.tar.bz2.tmp https://github.com/zixia/node-facenet/releases/download/v0.1.9/model-20170512.tar.bz2; mv model.tar.bz2.tmp model.tar.bz2; fi && tar jxvf model.tar.bz2 && cd -

x 20170512-110547.pb
x model-20170512-110547.ckpt-250000.data-00000-of-00001: (Empty error message)
tar: Error exit delayed from previous errors.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! facenet@0.3.19 postinstall:models: `set -e && if [ ! -d models ]; then mkdir models; fi && cd models && if [ ! -f model.tar.bz2 ]; then curl --location --output model.tar.bz2.tmp https://github.com/zixia/node-facenet/releases/download/v0.1.9/model-20170512.tar.bz2; mv model.tar.bz2.tmp model.tar.bz2; fi && tar jxvf model.tar.bz2 && cd -`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the facenet@0.3.19 postinstall:models script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/jiaruili/.npm/_logs/2017-10-13T12_12_09_470Z-debug.log
@lijiarui
Copy link
Contributor Author

lijiarui commented Oct 13, 2017

I found the following command:

"postinstall:models": "set -e && if [ ! -d models ]; then mkdir models; fi && cd models && if [ ! -f model.tar.bz2 ]; then curl --location --output model.tar.bz2.tmp https://github.com/zixia/node-facenet/releases/download/v0.1.9/model-20170512.tar.bz2; mv model.tar.bz2.tmp model.tar.bz2; fi && tar jxvf model.tar.bz2 && cd -",

I download https://github.com/zixia/node-facenet/releases/download/v0.1.9/model-20170512.tar.bz2, the 187M file by hand, then, where should I put it?

@lijiarui
Copy link
Contributor Author

lijiarui commented Oct 13, 2017

What's more, I found when I try facenet@0.3.18, it can run npm run postinstall:models and begin to download the model-20170512.tar.bz2 file.

While when it comes to facenet@0.3.19(change version 0.3.18 to 0.3.19), it cannot run the command successfully.

facenet@0.3.18 result:

x model-20170512-110547.ckpt-250000.index
x model-20170512-110547.meta
/Users/jiaruili/git/node-facenet
npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN sinon-test@2.1.1 requires a peer of sinon@2.x - 3.x but none was installed.

added 123 packages, removed 88 packages, updated 25 packages and moved 9 packages in 623.836s

facenet@0.3.19 result:

x 20170512-110547.pb
x model-20170512-110547.ckpt-250000.data-00000-of-00001: (Empty error message)
tar: Error exit delayed from previous errors.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! facenet@0.3.19 postinstall:models: `set -e && if [ ! -d models ]; then mkdir models; fi && cd models && if [ ! -f model.tar.bz2 ]; then curl --location --output model.tar.bz2.tmp https://github.com/zixia/node-facenet/releases/download/v0.1.9/model-20170512.tar.bz2; mv model.tar.bz2.tmp model.tar.bz2; fi && tar jxvf model.tar.bz2 && cd -`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the facenet@0.3.19 postinstall:models script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/jiaruili/.npm/_logs/2017-10-13T12_35_40_714Z-debug.log
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! facenet@0.3.19 postinstall: `npm run venv && npm run postinstall:facenet && npm run postinstall:models`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the facenet@0.3.19 postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/jiaruili/.npm/_logs/2017-10-13T12_35_40_810Z-debug.log

@lijiarui lijiarui changed the title Cannot install successfully version facenet@0.3.19Cannot install successfully Oct 13, 2017
@lijiarui
Copy link
Contributor Author

lijiarui commented Oct 13, 2017

Solution:

download the file from https://github.com/zixia/node-facenet/releases/download/v0.1.9/model-20170512.tar.bz2

rename the file model.tar.bz2 and move it to the folder models

then try npm install again
as follows show:
image

@lijiarui lijiarui changed the title version facenet@0.3.19Cannot install successfully Cannot get model file successfully Oct 13, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant