1. demo.py
The detection of a single picture on the picture can be achieved by the following command
python3 demo.py --config-file ../configs/PascalVOC-Detection/faster_rcnn_R_50_FPN.yaml \
--input cat.jpg \
--output result_cat_voc.jpg \
--opts MODEL.WEIGHTS ../tools/output_bak/model_final.pth
demo.py
In the demo folder of detectron2 ,
``
The original image
detection result is