EscVM / OIDv4_ToolKit

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

Getting Error While downloading multiple classes images #49

Closed satheeshkatipomu closed 4 years ago

satheeshkatipomu commented 4 years ago

Thanks for great tool to download Open Images. I am facing below error while downloading images of multiple classes. Traceback (most recent call last): File "main.py", line 37, in <module> bounding_boxes_images(args, DEFAULT_OID_DIR) File "/Users/OpenImages/OID/OIDv4_ToolKit/modules/bounding_boxes.py", line 106, in bounding_boxes_images class_dict[class_name] = df_classes.loc[df_classes[1] == class_name].values[0][0] IndexError: index 0 is out of bounds for axis 0 with size 0

I tried two method where listing all classes as command line argument and passing a text file which contains classes as a command line argument. But facing same error.

Also searched previous issues who faced similar issues and tried suggested method but no luck Issue 37 Issue 13

Commands I ran are: 1)python3 main.py downloader --classes Car Person Bicycle Taxi Truck Building Traffic_light Tree Traffic_sign Stop_sign Billboard Missle Motorcycle Van Tire Airplane Wheel Tank Stree_light Submarine --type_csv all --multiclasses 1 --limit 100

2)python3 main.py downloader --classes classes_custom.txt --type_csv all --multiclasses 1 --limit 100

contents in classes_custom.txt are: Car Person Bicycle Taxi Truck Building Traffic light Tree Traffic sign Stop sign Billboard Missle Motorcycle Van Tire Airplane Wheel Tank Street light Submarine

satheeshkatipomu commented 4 years ago

Ok, I got the issue, "Missile" spelling is wrong. We can provide most descriptive error message. Shall I raise a PR for this? Please close the issue if not required.

keldrom commented 4 years ago

May this could be another check to add into the toolkit in future

Niklaus28 commented 3 years ago

I also face the same issue, but I do not have any spelling error.

python main.py downloader --classes Football --type_csv train --limit 100

Traceback (most recent call last): File "main.py", line 35, in image_level(args, DEFAULT_OID_DIR) File "C:\OIDv4_ToolKit\modules\image_level.py", line 74, in image_level df_val = TTV(csv_dir, name_file, args.yes) File "C:\OIDv4_ToolKit\modules\csv_downloader.py", line 21, in TTV df_val = pd.read_csv(CSV) File "C:\Users\haoji\Python38\lib\site-packages\pandas\io\parsers.py", line 686, in read_csv return _read(filepath_or_buffer, kwds) File "C:\Users\haoji\Python38\lib\site-packages\pandas\io\parsers.py", line 458, in _read data = parser.read(nrows) File "C:\Users\haoji\Python38\lib\site-packages\pandas\io\parsers.py", line 1186, in read ret = self._engine.read(nrows) File "C:\Users\haoji\Python38\lib\site-packages\pandas\io\parsers.py", line 2145, in read data = self._reader.read(nrows) File "pandas_libs\parsers.pyx", line 826, in pandas._libs.parsers.TextReader.read File "pandas_libs\parsers.pyx", line 869, in pandas._libs.parsers.TextReader._read_low_memory File "pandas_libs\parsers.pyx", line 2053, in pandas._libs.parsers._concatenate_chunks File "<__array_function__ internals>", line 5, in concatenate MemoryError: Unable to allocate 213. MiB for an array with shape (27894289,) and data type int64

varun003 commented 3 years ago

Iam getting this error while downloading this class, I have checked there is no typing error:

python main.py downloader --classes Personal_flotation_device --type_csv train --limit 300.

Darmandran commented 2 years ago

Iam getting this error while downloading this class, I have checked there is no typing error:

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