2017-12-27 16 views
0

Ich versuche im2txt (https://github.com/tensorflow/models/tree/master/research/im2txt) Ich klonte das Repo und lud ein Modell herunter. Dann schrieb ich ein einfaches Shell-Skript zum Testen von im2txt wie unten.bazel-bin/im2txt/run_Inferenz - keine solche Datei

$ git clone https://github.com/tensorflow/models.git 
$ cd model/research/im2txt 

run.sh

CHECKPOINT_PATH="/Users/me/Desktop/machine-learning/ml/models/research/im2txt/im2txt/model/model.ckpt-3000000" 
VOCAB_FILE="/Users/me/Desktop/machine-learning/ml/models/research/im2txt/im2txt/data/word_counts.txt" 
IMAGE_FILE="/Users/me/Desktop/machine-learning/ml/models/research/im2txt/im2txt/data/COCO_val2014_000000224477.jpg" 

bazel build -c opt /im2txt:run_inference 

bazel-bin/im2txt/run_inference \ 
    --checkpoint_path=${CHECKPOINT_PATH} \ 
    --vocab_file=${VOCAB_FILE} \ 
    --input_files=${IMAGE_FILE} 

Ergebnis

$ ./run.sh 
INFO: Analysed 0 targets (0 packages loaded). 
INFO: Found 0 targets... 
INFO: Elapsed time: 0.360s, Critical Path: 0.02s 
INFO: Build completed successfully, 1 total action 
./run.sh: line 8: bazel-bin/im2txt/run_inference: No such file or directory 

Env

$ bazel version 
Build label: 0.9.0-homebrew 
Build target: bazel-out/darwin-opt/bin/src/main/java/com/google/devtools/build/lib/bazel/BazelServer_deploy.jar 
Build time: Sun Jul 12 03:29:57 +49936 (1513677382197) 
Build timestamp: 1513677382197 
Build timestamp as int: 1513677382197 

$ java -version 
java version "1.8.0_151" 
Java(TM) SE Runtime Environment (build 1.8.0_151-b12) 
Java HotSpot(TM) 64-Bit Server VM (build 25.151-b12, mixed mode) 

tensorflow (1.1.0) 

Hat jemand irgendwelche Ideen haben, dieses Problem zu beheben?

Vielen Dank für Ihre Hilfe!

Antwort

0

bazel build -c opt /im2txt:run_inference

braucht wahrscheinlich bazel build -c opt //im2txt:run_inference (Doppelschrägstriche)

+0

vielen Dank für Ihre Antwort zu sein. – Koji