Object Detection Using YOLO v2 Deep Learning

2 visualizaciones (últimos 30 días)
Toni Vukasinovic
Toni Vukasinovic el 16 de Mayo de 2020
Respondida: Shishir Singhal el 19 de Mayo de 2020
I want to train a YOLO v2 Object Detection Network for pictures size of 4000*3000 where a have labeled very small objects,what would be the optimal size for the inputSize? As if i use the original image size(4000*3000) my computer crashes,but if i use the specified size(224*224) my Yolo2ObjectDetector does not detect any objects on a test image.
inputSize = [224 224 3];
numClasses = width(vehicleDataset)-1;
trainingDataForEstimation = transform(trainingData,@(data)preprocessData(data,inputSize));
numAnchors = 7;
[anchorBoxes, meanIoU] = estimateAnchorBoxes(trainingDataForEstimation, numAnchors);
featureExtractionNetwork = resnet50;
featureLayer = 'activation_40_relu';
lgraph = yolov2Layers(inputSize,numClasses,anchorBoxes,featureExtractionNetwork,featureLayer);
options = trainingOptions('sgdm',...
'InitialLearnRate',0.001,...
'Verbose',true,...
'MiniBatchSize',16,...
'MaxEpochs',30,...
'Shuffle','never',...
'VerboseFrequency',30,...
'CheckpointPath',tempdir);
[detector,info] = trainYOLOv2ObjectDetector(trainingDataForEstimation,lgraph,options);

Respuestas (1)

Shishir Singhal
Shishir Singhal el 19 de Mayo de 2020
Hi,
YOLO v2 object detector has a problem with detecting small objects. Instead you can try YOLO v3. It is far good for detecting small objects. You can refer to this documentation: https://www.mathworks.com/help/vision/examples/object-detection-using-yolo-v3-deep-learning.html to know more about its implementation in MATLAB.
Hope this helps....!!!

Community Treasure Hunt

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

Start Hunting!

Translated by