EscVM / OIDv4_ToolKit

Download and visualize single or multiple classes from the huge Open Images v4 dataset
GNU General Public License v3.0
813 stars 633 forks source link

Multiple classes present in the same image #67

Open LewsTherin511 opened 4 years ago

LewsTherin511 commented 4 years ago

Hi, I have a problem regarding labeling of images containing instances from multiple classes I want to detect.

Say that I want to train a model to detect "guitars" and "human faces" in pictures. I download images specifying the 2 classes, and I got (say 1K) images for each class, with the corresponding annotations for bounding boxes. The problem is that, for every folder of images, only one class is annotated.

So, in the "human face" folder, I have 1000 images, and faces are labelled in every picture. On the other hand, in the "guitar" folder, I have 1000 images with labelled guitars...however, as you can imagine, in most of the pictures of guitars there are also people, but their faces are not annotated.

At this point, I can't use them for training as they are, because all the faces in the "guitar" images are not labeled as such, and it would provide lots of false negatives to the model. I tried using the multiclasses argument:

python3 main.py downloader --classes Guitar Human_face --type_csv train --limit 1000 --multiclasses 1

and it's the same, the images and annotations are downloaded in the same folder, but they are always separated per class.

Am I doing anything wrong here? Is there a way to download images with labels for all the classes I'm interested in?

ahmadalzoubi13579 commented 4 years ago

same issue .

aishwarya2905 commented 4 years ago

I am having the same problem.

ufukasia commented 3 years ago

yes this problem valid all multiclass detection. example i want to detect human head and person but i cant download two box label in one image. this is problem !!! someone respond this issue please !!!

ahmadalzoubi13579 commented 3 years ago

@ufukasia in my case i downloaded annotations files open image dataset (which have detailed information about every image ex: classes) from open image website and then create script to fix every thing, for example taking the image name from downloaded images and search in the annotation file for all classes exist in that image and select the classes i am interesting in.

Anas-Alshaghouri commented 2 years ago

Still no solution for this problem?! COCO has this option but its classes are limited to 80 :(

hichamhendy commented 2 years ago

I also have the same problem, I want to have the labels of Window and Window blind just as they show up; However the tool shows only one of them. Fiftyone handles that better but needs to adapted to yolo