Reputation: 11
I'm using Tensorflow object detection API models for my plate number detection project. I'm using MobileNet SSD pre-trained model ('ssd_mobilenet_v2_fpnlite_320x320_coco17_tpu-8'). I have evaluated my pre-trained models and only get the average precision and recall. Is there any other way I can get the value of the accuracy model or confusion matrix?
This is the command code of the evaluation model
command = "python {} --model_dir={} --pipeline_config_path={} --checkpoint_dir={}".format(TRAINING_SCRIPT, paths['CHECKPOINT_PATH'],files['PIPELINE_CONFIG'], paths['CHECKPOINT_PATH'])
This is the output
Average Precision (AP) @[ IoU=0.50:0.95 | area= all | maxDets=100 ] = 0.543641
Average Precision (AP) @[ IoU=0.50 | area= all | maxDets=100 ] = 1.00000
Average Precision (AP) @[ IoU=0.75 | area= all | maxDets=100 ] = 0.623451
Average Precision (AP) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = 0.570156
Average Precision (AP) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = 0.566508
Average Precision (AP) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.514109
Average Recall (AR) @[ IoU=0.50:0.95 | area= all | maxDets= 1 ] = 0.573684
Average Recall (AR) @[ IoU=0.50:0.95 | area= all | maxDets= 10 ] = 0.636842
Average Recall (AR) @[ IoU=0.50:0.95 | area= all | maxDets=100 ] = 0.636842
Average Recall (AR) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = 0.666667
Average Recall (AR) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = 0.630769
Average Recall (AR) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.633333
Upvotes: 0
Views: 344
Reputation:
To get the confusion matrix for the object detection model you have to find the Intersection over union(IoU) for the predictions.
IoU is defined as the area of intersection between ground truth mask and predicted mask divided by the area of the union between the two.
Based on the calculated IoU you have to define a threshold to get the True positive, False positive, True negative, False negative.
For more details please refer to this link. Thank You!
Upvotes: 1