User Tools


Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Last revision Both sides next revision
cs:vision:object_detection:start [2018/03/31 19:46]
James Irwin [Getting a Model]
cs:vision:object_detection:start [2018/03/31 19:58]
James Irwin [Start Training]
Line 100: Line 100:
  
 ===== Start Training ===== ===== Start Training =====
-The following ​command ​assume your current working directory is the root of the workspace you created earlier. To start training, run:+The following ​commands ​assume your current working directory is the root of the workspace you created earlier. ​ 
 + 
 +To start training, run:
   python ~/​.local/​tensorflow_object_detection_api/​research/​object_detection/​train.py \   python ~/​.local/​tensorflow_object_detection_api/​research/​object_detection/​train.py \
     --logtostderr \     --logtostderr \
     --pipeline_config_path=<​model config file> \     --pipeline_config_path=<​model config file> \
-    --train_dir=+    --train_dir=output/​train 
 + 
 +To evaluate the performance of the network, run: 
 +  python ~/​.local/​tensorflow_object_detection_api/​research/​object_detection/​eval.py \ 
 +    --logtostderr \ 
 +    --pipeline_config_path=<​model config file> \ 
 +    --checkpoint_dir=output/​train/​ \ 
 +    --eval_dir=output/​eval/​ 
 +The eval.py script will notice every time the train.py script saves a new checkpoint, and evaluate its performance on the test dataset. 
 + 
 +To visualize the training process, start up tensorboard:​ 
 +  tensorboard --logdir=outputs 
 +Tensorboard is a little web server, you can access it at localhost:​6006 in your browser.
 ===== Exporting a trained model for inference ===== ===== Exporting a trained model for inference =====
 To export checkpoint trained data for ''​%%robosub_object_detection%%''​ format you need to follow [[https://​github.com/​tensorflow/​models/​blob/​master/​research/​object_detection/​g3doc/​exporting_models.md|these]] instructions. Or run this: To export checkpoint trained data for ''​%%robosub_object_detection%%''​ format you need to follow [[https://​github.com/​tensorflow/​models/​blob/​master/​research/​object_detection/​g3doc/​exporting_models.md|these]] instructions. Or run this: