@@ -66,25 +65,29 @@ After data preparation, one can start the training step by:
- Faster RCNN
```
python train.py \
--model_save_dir=output/ \
--pretrained_model=${path_to_pretrain_model} \
--data_dir=${path_to_data} \
--MASK_ON=False
```
- Mask RCNN
```
python train.py \
--model_save_dir=output/ \
--pretrained_model=${path_to_pretrain_model} \
--data_dir=${path_to_data} \
--MASK_ON=True
```
- Set ```export CUDA_VISIBLE_DEVICES=0,1,2,3,4,5,6,7``` to specifiy 8 GPU to train.
- Set ```MASK_ON``` to choose Faster RCNN or Mask RCNN model.
- For more help on arguments:
- Set ```export CUDA_VISIBLE_DEVICES=0,1,2,3,4,5,6,7``` to specifiy 8 GPU to train.
- Set ```MASK_ON``` to choose Faster RCNN or Mask RCNN model.
- For more help on arguments:
python train.py --help
python train.py --help
**data reader introduction:**
...
...
@@ -116,20 +119,25 @@ Evaluation is to evaluate the performance of a trained model. This sample provid
- Faster RCNN
```
python eval_coco_map.py \
--dataset=coco2017 \
--pretrained_model=${path_to_pretrain_model} \
--pretrained_model=${path_to_trained_model} \
--MASK_ON=False
```
- Mask RCNN
```
python eval_coco_map.py \
--dataset=coco2017 \
--pretrained_model=${path_to_pretrain_model} \
--pretrained_model=${path_to_trainde_model} \
--MASK_ON=True
```
- Set ```export CUDA_VISIBLE_DEVICES=0``` to specifiy one GPU to eval.
- Set ```MASK_ON``` to choose Faster RCNN or Mask RCNN model.
- Set ```--pretrained_model=${path_to_trained_model}``` to specifiy the trained model, not the initialized model.
- Set ```export CUDA_VISIBLE_DEVICES=0``` to specifiy one GPU to eval.
- Set ```MASK_ON``` to choose Faster RCNN or Mask RCNN model.
Evalutaion result is shown as below:
...
...
@@ -159,12 +167,14 @@ Mask RCNN:
Inference is used to get prediction score or image features based on trained models. `infer.py` is the main executor for inference, one can start infer step by: