From 1efeefe323cb1e98bc667e14107f5e1ae3c53432 Mon Sep 17 00:00:00 2001 From: Bubbliiiing <47347516+bubbliiiing@users.noreply.github.com> Date: Thu, 31 Dec 2020 09:15:33 +0800 Subject: [PATCH] Add files via upload --- voc_annotation.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/voc_annotation.py b/voc_annotation.py index 3c80836..aad0657 100644 --- a/voc_annotation.py +++ b/voc_annotation.py @@ -6,7 +6,7 @@ sets=[('2007', 'train'), ('2007', 'val'), ('2007', 'test')] classes = ["aeroplane", "bicycle", "bird", "boat", "bottle", "bus", "car", "cat", "chair", "cow", "diningtable", "dog", "horse", "motorbike", "person", "pottedplant", "sheep", "sofa", "train", "tvmonitor"] def convert_annotation(year, image_id, list_file): - in_file = open('VOCdevkit/VOC%s/Annotations/%s.xml'%(year, image_id)) + in_file = open('VOCdevkit/VOC%s/Annotations/%s.xml'%(year, image_id), encoding='utf-8') tree=ET.parse(in_file) root = tree.getroot() -- GitLab