Bounding boxes on objects after training a classifier.

조회 수: 3 (최근 30일)
Juliana Qiu Ann Ho
Juliana Qiu Ann Ho 2020년 2월 13일
댓글: Raunak Gupta 2020년 2월 18일
Hi, I have a dataset with 5 classes. I have extracted the features using pre-trained CNN and then trained a classifier using SVM. Now, I would like to classify multiple objects in a single image (better if in video) by having bounding boxes on the objects and labelling to indicate the classes. I understand that it will be faster and easier using object detectors like R-CNN and YOLO v2 but is there a way I can do continuing from the trained classifier that I have mentioned?

채택된 답변

Raunak Gupta
Raunak Gupta 2020년 2월 18일
Hi,
For doing Object Detection, the training dataset require to have bounding boxes in it so that Network can be trained for classification as well as bounding box regression. As mentioned in the question you have a pretrained classifier which can classify 5 classes. So, I suggest labeling some images for getting a training data for fasterRCNNObjectDetector. For Labeling the images to get bounding boxes you may use Image Labeler App or Ground Truth Labeler App. You can mention the pretrained classifier while creating fasterRCNNLayers.
This example can be useful for getting started.
For Labeling you may this helpful.
  댓글 수: 2
Juliana Qiu Ann Ho
Juliana Qiu Ann Ho 2020년 2월 18일
Hi, thank you for your reply. So do you mean that I should start by labelling boxes on my training data before extracting features using CNN? Which means the sequence now would be, labelling boxes using the apps recommended -> extract features using CNN -> train a classifier using extracted features -> test the classifier? Another question here is do I need to have multiple-object images in the training and evaluation data as well? Because currently my training and testing data consist of only single-object images.
Raunak Gupta
Raunak Gupta 2020년 2월 18일
Hi,
If the classifier is trained for classification of those 5 classes there is no need to do the classifier training again. Only for bounding box regression the training is required. Once you give the training data with bounding boxes the classifier will also get fine-tuned.
As per the second part if the evaluation data consist multiple object then the Network will produce those many bounding boxes regardless of those present in training or testing set. Only the examples should be present for all five classes in training dataset and offcourse the training loss should be low.
You may follow the faster RCNN example I mentioned above for implementing.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

태그

Community Treasure Hunt

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

Start Hunting!

Translated by