cd $CAFFE_ROOT/data/mnist
./get_mnist.sh
- cd $CAFFE_ROOT/examples/lenet
+ cd $CAFFE_ROOT/examples/mnist
./create_mnist.sh
If it complains that `wget` or `gunzip` are not installed, you need to install them respectively. After running the script there should be two datasets, `mnist-train-leveldb`, and `mnist-test-leveldb`.
Training the model is simple after you have written the network definition protobuf and solver protobuf files. Simply run `train_mnist.sh`, or the following command directly:
- cd $CAFFE_ROOT/examples/lenet
+ cd $CAFFE_ROOT/examples/mnist
./train_lenet.sh
`train_lenet.sh` is a simple script, but here are a few explanations: `GLOG_logtostderr=1` is the google logging flag that prints all the logging messages directly to stderr. The main tool for training is `train_net.bin`, with the solver protobuf text file as its argument.