EscVM / OIDv4_ToolKit

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

IndexError: index 0 is out of bounds for axis 0 with size 0 #37

Closed rahulroxx closed 5 years ago

rahulroxx commented 5 years ago
Traceback (most recent call last):
  File "main.py", line 36, in <module>
    bounding_boxes_images(args, DEFAULT_OID_DIR)
  File "/mountdir/OIDv4_ToolKit/modules/bounding_boxes.py", line 56, in bounding_boxes_images
    class_code = df_classes.loc[df_classes[1] == class_name].values[0][0]
IndexError: index 0 is out of bounds for axis 0 with size 0
rahulroxx commented 5 years ago

While downloading multiple classes with --classes=classes-new.txt

classes-new.txt

Bed Dining_table Microwave Chair

keldrom commented 5 years ago

Could you provide the full terminal command?

keldrom commented 5 years ago

In a few I will close this issue

thurussian commented 4 years ago

does anyone know what's the resolution to the bounding_boxes.py script error?! I am still not sorted out. I am getting exact print out as rahulroxx above single or multiple class

IdrissouSOUNON commented 3 years ago

Could you provide the full terminal command?

I have got the same error.

The command is python main.py downloader --classes person --type_csv train --limit 20000

IdrissouSOUNON commented 3 years ago

I see my mistake. The class name is incorrect. I should write Person instead of person.

varun003 commented 3 years ago

Could you provide the full terminal command?

I have got the same error.

The command is python main.py downloader --classes person --type_csv train --limit 20000

Iam also getting the same error, there is no typing error also. The command is : python main.py downloader --classes Personal_flotation_device --type_csv train --limit 300

Chaitanya-Thombare commented 3 years ago

Could you provide the full terminal command?

I have got the same error. The command is python main.py downloader --classes person --type_csv train --limit 20000

Iam also getting the same error, there is no typing error also. The command is : python main.py downloader --classes Personal_flotation_device --type_csv train --limit 300

I am not an expert or experienced. But I have an observation which might help. I get the same error for py main.py downloader --classes Volleyball_(Ball) Tennis_ball --type_csv train --limit 400 ,

but did not get that error for py main.py downloader --classes Car --type_csv train --limit 4

I think this doesn't work for some classes. Try to download some other class, like Car.

AlexDavydov357 commented 2 years ago

This problem only with apostrophe. You need to change it from ' to " and everything will be okay. For example: python main.py downloader --classes "Fire hydrant" "Traffic light" Car Bus --type_csv train --limit 400

Darmandran commented 2 years ago

Could you provide the full terminal command?

I have got the same error. The command is python main.py downloader --classes person --type_csv train --limit 20000

Iam also getting the same error, there is no typing error also. The command is : python main.py downloader --classes Personal_flotation_device --type_csv train --limit 300

for some reason Personal_flotation_device is actually Lifejacket python main.py downloader --classes Lifejacket --type_csv train --limit 300

AlexDavydov357 commented 2 years ago

This is full command line, what I used. But actually I get any dataset different way. I not use this utils. This utils I tried just once for learning experiment and never used again.

younes113 commented 1 year ago
Traceback (most recent call last):
  File "main.py", line 36, in <module>
    bounding_boxes_images(args, DEFAULT_OID_DIR)
  File "/mountdir/OIDv4_ToolKit/modules/bounding_boxes.py", line 56, in bounding_boxes_images
    class_code = df_classes.loc[df_classes[1] == class_name].values[0][0]
IndexError: index 0 is out of bounds for axis 0 with size 0

You should use capitol for classes names

younes113 commented 1 year ago

The command is python main.py downloader --classes person --type_csv train --limit 20000 use instead this command with capitol letters for classes name The command is python main.py downloader --classes Person --type_csv train --limit 20000