Training YOLO V2 with multiple (more than one) classes
古いコメントを表示
Hi all,
When I train YOLOV2 with single class (person) using trainYOLOv2ObjectDetector, I can get precision/recall of 0.92 but when I add another class (car) with same images and just few car labels, the accuracy is 0, meaning even the person cannot be detected in any of the images even my training images!
I even use AnchorBox estimation and treid many times.
All the matlab examples are tarined only on single objects but how about if we have more than one class to be trained? Does anyone have any success to help me please?
4 件のコメント
Abul Hassan Mashood
2019 年 8 月 12 日
I have the same problem!
Zahra Moayed
2019 年 9 月 4 日
jingxue chen
2020 年 7 月 15 日
I meet the same problem now!Have you find some solutions?
Sanjeev Madhave
2020 年 11 月 18 日
Hi Zahra Moayed,
I was also trying to train the yolo with multi class. I have a doubt. How did you mapped the training dataset table?
In my case, in some training image one class may not be there. In such cases how to fill the table? just leave it as empty? in that case matlab is throwing error. any help is much appreciated
回答 (3 件)
Srivardhan Gadila
2019 年 8 月 14 日
編集済み: Srivardhan Gadila
2019 年 8 月 14 日
0 投票
The procedure is same for both single and multi-class. The zero accuracy may imply that the dataset is biased, so try having nearly equal number of labels for cars and persons.
3 件のコメント
Zahra Moayed
2019 年 8 月 15 日
Srivardhan Gadila
2019 年 8 月 19 日
In general the first case should produce the good results i.e., having the following equally: Images/Frames having 1. Only vehicles 2. Only Pedestrains 3. Both Vehicles and Pedestrains.
Zahra Moayed
2019 年 8 月 26 日
Zahra Moayed
2019 年 10 月 7 日
0 投票
5 件のコメント
Srivardhan Gadila
2019 年 10 月 23 日
I have brought this issue to the notice of our developers. They will investigate the matter further.
Basim Azam
2019 年 11 月 3 日
Oscar Lema
2020 年 3 月 26 日
Updates?
Damjan Konjevod
2022 年 4 月 1 日
Any updates? I have the same problem, can detect 1 class but in case of multiple classes 0 recall
Anushikha Singh
2022 年 12 月 13 日
any updates?
m still facing same issue
Sunny Guha
2022 年 4 月 6 日
0 投票
Hi Zahra
Please refer to this R2022a example on training YOLO v2 for multiple classes:
In general, there could be multiple issues that hinder performance of networks on multiple class datasets. Here are few of the things you can try to resolve the issues:
- Ensure the classes are close to balanced. If you cannot obtain more labels resort to data augmentation. The example I linked above contains steps on how to perform augmentation.
- Change backbone/feature extraction layer. Object detectors have a hard time detecting smaller objects. Bigger (spatial resolution) feature extraction layers can detect smaller objects.
- Try a different detector like yolov4 which perform multiscale detection.
Hope this helps.
7 件のコメント
Damjan Konjevod
2022 年 4 月 7 日
Where can I find 'annotationsIndoor.mat' from the example you refered to?
Sunny Guha
2022 年 4 月 7 日
Hi Damjan,
On the top-right corner of the example screen you can find the "Copy Command" button. This copies command needed to open the example and also save the relevant files in your documents folder.
For this examples the command is:
openExample('deeplearning_shared/MulticlassObjectDetectionUsingDeepLearningExample')
You can use this in MATLAB and MATLAB will open the example in the newly created folder with all the required files.
Hope this helps.
Damjan Konjevod
2022 年 4 月 7 日
Hi Sunny,
thank you for such fast response. I tried the "Copy Command" but MATLAB cannot find the example.
I have both vision toolbox and deep learning toolbox installed. Is it maybe because MATLAB isn't installed in the default directory? Can I download example from somewhere?
Sunny Guha
2022 年 4 月 8 日
Hi Damjan,
Could you please post the error message that you are encountering.
In the meantime these are some steps you can try.
- Run restoredefaultpath command to restore all default MATLAB paths.
- Run rehash toolboxcache command to clean and restore toolbox cache.
- Run which annotationsIndoor.mat command to find the location of the file in your installed MATLAB directory.
Let me know if this resolves the issue.
Damjan Konjevod
2022 年 4 月 9 日
編集済み: Damjan Konjevod
2022 年 4 月 9 日
Hi Sunny,
I tried steps you recommended and it didnt work.
Error message that I get is:
Error using findExample (line 22)
Example "MulticlassObjectDetectionUsingDeepLearningExample" not found in "C:\Program Files\MATLAB\examples\deeplearning_shared\examples.xml".
Error in openExample (line 30)
metadata = findExample(exampleId);
michela Raimondi
2022 年 9 月 30 日
ho lo stesso problema di damjan
Anushikha Singh
2022 年 12 月 13 日
I have tried yolo v2, v3 and v4 but problem is still there
good accuracy for single class and no detection in case of multiple object
please help
カテゴリ
ヘルプ センター および File Exchange で Object Detection についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!