How to run eval.py job for tensorflow object detection models

点点圈 提交于 2019-11-30 04:02:50

The setup looks good. I had to wait a long time for the Scalars tab to load/show up alongside the other two - like 10 minutes after the evaluation job finished.

But at the end of the evaluation job, it prints in the console all the scalar metrics that will be displayed in the Scalars tab:

Accumulating evaluation results...
DONE (t=1.57s).
Average Precision  (AP) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.434
Average Precision  (AP) @[ IoU=0.50      | area=   all | maxDets=100 ] = 0.693
Average Precision  (AP) @[ IoU=0.75      | area=   all | maxDets=100 ] = 0.470
Average Precision  (AP) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = 0.000

etc.

If you want to use the new model_main.py script instead of legacy/eval.py, you can call it like

python model_main.py --alsologtostderr --run_once --checkpoint_dir=/dir/with/checkpoint/at/one/timestamp --model_dir=eval/ --pipeline_config_path=training/faster_rcnn_inception_v2_pets.config 

Note that this new API would require the optimizer field in train_config, which is probably already in your pipeline.config since you're using the same for both training and evaluation.

For those who are looking to run the new model_main.py in evaluation only. There is a flag in the parameter that you can set that does just that. That flaf is checkpoint_dir, if you set it equal to a folder containing past training checkpoints, the model will run in evaluation only.

Hope I can help a few that missed it like myself! Cheers,

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!