glob search bug fix #77

This commit is contained in:
Glenn Jocher committed 2020-06-15 12:08:57 -07:00
1 parent ace56eb5b6
commit c5966abba8
4 files changed
+14 -3

No files matched your search

+2 -2
View File
@@ -384,8 +384,8 @@ if __name__ == '__main__':
parser.add_argument('--single-cls', action='store_true', help='train as single-class dataset')
opt = parser.parse_args()
opt.weights = last if opt.resume else opt.weights
opt.cfg = glob.glob('./**/' + opt.cfg, recursive=True)[0] # find file
opt.data = glob.glob('./**/' + opt.data, recursive=True)[0] # find file
opt.cfg = check_file(opt.cfg) # check file
opt.data = check_file(opt.data) # check file
print(opt)
opt.img_size.extend([opt.img_size[-1]] * (2 - len(opt.img_size))) # extend to 2 sizes (train, test)
device = torch_utils.select_device(opt.device, apex=mixed_precision, batch_size=opt.batch_size)