1
我訓練使用來自Caffe神經網絡模型:如何通過CLI在Caffe中生成預測標籤?
/home/f/caffe-master/build/tools/caffe train -solver=/media/my_solver.prototxt
我再入一球上驗證組學習模式:
/home/f/caffe-master/build/tools/caffe test -model=/media/my_train_test.prototxt
-weights model.caffemodel -iterations 100
但如何通過在訓練的神經網絡模型預測的標籤咖啡?
我知道我可以使用Python或Matlab綁定用於該目的,但我很好奇,想知道我們是否可以直接通過命令行界面獲得來自Caffe預測標籤。
它似乎並不在official Caffe's tutorial on interfaces被提及,看着caffe
的幫助沒有幫助:
> [email protected]:~/caffe/caffe-master/build/tools$ ./caffe
caffe: command line brew
usage: caffe <command> <args>
commands:
train train or finetune a model
test score a model
device_query show GPU diagnostic information
time benchmark model execution time
Flags from /home/f/caffe-master/tools/caffe.cpp:
-gpu (Run in GPU mode on given device ID.) type: int32 default: -1
-iterations (The number of iterations to run.) type: int32 default: 50
-model (The model definition protocol buffer text file..) type: string
default: ""
-snapshot (Optional; the snapshot solver state to resume training.)
type: string default: ""
-solver (The solver definition protocol buffer text file.) type: string
default: ""
-weights (Optional; the pretrained weights to initialize finetuning. Cannot
be set simultaneously with snapshot.) type: string default: ""