报错
source = open(source, "rb")
FileNotFoundError: [Errno 2] No such file or directory: 'datasets\\VOC2007\\Annotations\\.xml'
或 source = open(source, "rb")
FileNotFoundError: [Errno 2] No such file or directory: 'datasets\\VOC2012\\Annotations\\.xml'
说明txt文件中存在空行,仔细检测datasets/VOC2007/ImageSets/Main中的txt文件,找到空行,删除即可