Cannot get model file successfully
lijiarui opened this issue · 3 comments
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
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?
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
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