OIDv4_ToolKit icon indicating copy to clipboard operation
OIDv4_ToolKit copied to clipboard

Update convert_annotations.py

Open mralamdari opened this issue 3 years ago • 0 comments

There were some errors, so I tried to solve them and improve the code. Here is the Error I got when I ran the code with Traffic sign pictures:

Error: Traceback (most recent call last): File "convert_annotations.py", line 63, in <module> coords = np.asarray([float(labels[1]), float(labels[2]), float(labels[3]), float(labels[4])]) ValueError: could not convert string to float: 'sign'

So I decided to change the label indexing so that this Error won't happen in the future.

My Solution: Indexing labels from the end of the labels array.

mralamdari avatar Aug 25 '22 12:08 mralamdari