Object Detection using Yolov3 results : yolo insert of multiple boxes for the same object

6 vues (au cours des 30 derniers jours)
Hello Matlabers,
I am usong YOLO v3 on matlab 2021a to recognize objects using YOLOv3 detector pretrained on COCO dataset.
the detector initiation is performed as:
name = 'tiny-yolov3-coco';
detector = yolov3ObjectDetector(name);
after the detection , I insert the bounding boxes using insertObjectAnnotation function
my problem is that the detector shows multiple boxes for the same object as shown in the image bellow
I am using grayscale image with replicated channels as Image=[gray, gray, gray]
the detection part is performed as follow:
[bboxes,scores,labels] = detect(detector,Image);
detected = insertObjectAnnotation(Image,'rectangle',bboxes,strcat(string(labels),{' - '},num2str(scores)));
what could be the problem and what are the possible solutions?
regards,

Réponse acceptée

Vivek Akkala
Vivek Akkala le 28 Avr 2022
Hi,
You can use selectStrongestBboxMulticlass to suppress the detections. Try lowering the "OverlapThreshold" of selectStrongestBboxMulticlass function. Following is the reference code:
[updatedBboxes, updatedScores, updatedClassNames] = selectStrongestBboxMulticlass(bboxes, scores, labels ,...
'RatioType', 'Union', 'OverlapThreshold', 0.3);
bboxes, scores and lables in the above code can be obtained from the detect(detector,image).
  1 commentaire
ahcen aliouat
ahcen aliouat le 29 Avr 2022
Hi vivek,
Thank you for the sugestition, it helps me.
I have tried it before and the problem was that it eliminate the two inserted boxes in many cases. Which significantly reduce the accuracy. but as you said , I have to lowerise the overlap threshold to get best performances.

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

En savoir plus sur Tracking and Motion Estimation dans Help Center et File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by