Intel® Distribution of OpenVINO™ Toolkit
Community support and discussions about the Intel® Distribution of OpenVINO™ toolkit, OpenCV, and all things computer vision-related on Intel® platforms.
6023 Discussions

Error messages popped up when importing a custom COCO dataset in DL Workbench

nat98
Beginner
398 Views

Hello there, my project is image classification and I have decided to use COCO dataset format. I had created a custom COCO dataset at the website https://www.makesense.ai/ and selected the "image recognition" as the annotation format.

I encountered the error message "Error: Unknown dataset type" when I try to import the custom COCO datatset. However, I noticed that the .json file only contains "images" and "annotations".

Hence, I have added in "info" and "licenses" into the .json file. Now, the error message appeared as "Error: Cannot find annotation file".

I had attached the error message screenshot in this post for reference. Also, attached is the custom dataset zip file.

Am I missing out something? Is there any dataset format recommendations for image classification/image recognition where I can use my custom images?

Thanks.

0 Kudos
1 Solution
Nikolai_Vishniakov
378 Views

Hello nat98! Thanks for using DL Workbench.

In your case you cannot use COCO dataset format for the classification task. The best solution will be using ImageNet dataset format. If you want to prepare your dataset as ImageNet, you can keep images and add txt file with annotations (named, as example annotations_val.txt), in this file each row contains: image_file_name.jpg *class_id*, where class_id is unique id of your classes (ex: Cyclone=1, Earthquake=2, etc) and then package images and annotation file to zip. More information about ImageNet format you can get at the OpenVINO docs. For example content of your annotation file be like:

Cyclone_23.jpg 1
Cyclone_24.jpg 1
Earthquake_0.jpg 2
Earthquake_1.jpg 2
...
Wildfire_20.jpg 4
...

 

Same way, you can find short help at the right column of DL Workbench Import Dataset page (see attached screenshot)

WB Dataset Tip.png

View solution in original post

2 Replies
Nikolai_Vishniakov
379 Views

Hello nat98! Thanks for using DL Workbench.

In your case you cannot use COCO dataset format for the classification task. The best solution will be using ImageNet dataset format. If you want to prepare your dataset as ImageNet, you can keep images and add txt file with annotations (named, as example annotations_val.txt), in this file each row contains: image_file_name.jpg *class_id*, where class_id is unique id of your classes (ex: Cyclone=1, Earthquake=2, etc) and then package images and annotation file to zip. More information about ImageNet format you can get at the OpenVINO docs. For example content of your annotation file be like:

Cyclone_23.jpg 1
Cyclone_24.jpg 1
Earthquake_0.jpg 2
Earthquake_1.jpg 2
...
Wildfire_20.jpg 4
...

 

Same way, you can find short help at the right column of DL Workbench Import Dataset page (see attached screenshot)

WB Dataset Tip.png

Wan_Intel
Moderator
279 Views

Hi Nat98,

Thanks for your question.

 

This thread will no longer be monitored since this issue has been resolved.

If you need any additional information from Intel, please submit a new question.

 

 

Regards,

Wan

 

Reply