Browse Source

Add files via upload

tags/v1.0.0
Alexey Mikhailyuk 4 years ago
parent
commit
87ed02eb24
No account linked to committer's email address
1 changed files with 2 additions and 0 deletions
  1. 2
    0
      COCO2YOLO.py

+ 2
- 0
COCO2YOLO.py View File

for image in self.labels['images']: for image in self.labels['images']:
id = image['id'] id = image['id']
file_name = image['file_name'] file_name = image['file_name']
if file_name.find('\\') > -1:
file_name = file_name[file_name.index('\\')+1:]
w = image['width'] w = image['width']
h = image['height'] h = image['height']
images_info[id] = (file_name, w, h) images_info[id] = (file_name, w, h)

Loading…
Cancel
Save