Cartucho / OpenLabeling

Label images and video for Computer Vision applications
Apache License 2.0
926 stars 266 forks source link

Predicted frame error #48

Closed Hozaifa-Bhutta closed 5 years ago

Hozaifa-Bhutta commented 5 years ago

Sometimes when switching between frames with predicted bounding boxes, I get this error Traceback (most recent call last): File "main.py", line 1007, in tmp_img = draw_bboxes_from_file(tmp_img, annotation_paths, width, height) File "main.py", line 344, in draw_bboxes_from_file tree = ET.parse(ann_path) File "", line 62, in parse File "", line 38, in parse cElementTree.ParseError: no element found: line 1, column 0

Can someone help me with this. By the way this is the first time I am here so forgive me if I did something wrong

Hozaifa-Bhutta commented 5 years ago

I now deleted that frame and the error disappeared, however, I am curious about why the error appeared.

Hozaifa-Bhutta commented 5 years ago

Should I close this since this is not a problem anymore?

Cartucho commented 5 years ago

Hello! I am very sorry for the late response.

So I believe you had two \n in that file.

Do you still have that file with you? The one that was giving this error?

If you could give that information I could make sure that this will not happen again.

Hozaifa-Bhutta commented 5 years ago

I still have the file but I have deleted that frame since then and changed the labels since then. I don't remember if I changed anything else, unfortunately. The name of the file is 'WIN_20190225_07_22_46_Pro', it is 4.63 MB. There is another video file there named 'WIN_20190330_10_20_46_Pro', but this is not the video with the error. Unfortunately, I do not think that any other piece of information could help since I have changed this part of the directory multiple times. I hope this can help you in fixing this error.

Cartucho commented 5 years ago

Ok, I think it was a matter of a \n but it's really hard to tell without that information. Anyway, I am glad that you were able to fix it.