yzqxy / Yolov8_obb_Prune_Track

GNU General Public License v3.0
185 stars 15 forks source link

训练报错 #21

Open hecheng000 opened 1 year ago

hecheng000 commented 1 year ago

Traceback (most recent call last): File "/home/hc/下载/yolo/Yolov8_obb_Prune_Track-main/train.py", line 648, in main(opt) File "/home/hc/下载/yolo/Yolov8_obb_Prune_Track-main/train.py", line 545, in main train(opt.hyp, opt, device, callbacks) File "/home/hc/下载/yolo/Yolov8_obb_Prune_Track-main/train.py", line 118, in train model = Model(cfg or ckpt['model'].yaml, ch=3, nc=nc).to(device) # create File "/home/hc/下载/yolo/Yolov8_obb_Prune_Track-main/models/yolo.py", line 180, in init self.model, self.save = parse_model(deepcopy(self.yaml), ch=[ch]) # model, savelist File "/home/hc/下载/yolo/Yolov8_obb_Prune_Track-main/models/yolo.py", line 332, in parse_model m = eval(m) if isinstance(m, str) else m # eval strings File "", line 1, in NameError: name 'Detect' is not defined

yzqxy commented 1 year ago

Traceback (most recent call last): File "/home/hc/下载/yolo/Yolov8_obb_Prune_Track-main/train.py", line 648, in main(opt) File "/home/hc/下载/yolo/Yolov8_obb_Prune_Track-main/train.py", line 545, in main train(opt.hyp, opt, device, callbacks) File "/home/hc/下载/yolo/Yolov8_obb_Prune_Track-main/train.py", line 118, in train model = Model(cfg or ckpt['model'].yaml, ch=3, nc=nc).to(device) # create File "/home/hc/下载/yolo/Yolov8_obb_Prune_Track-main/models/yolo.py", line 180, in init self.model, self.save = parse_model(deepcopy(self.yaml), ch=[ch]) # model, savelist File "/home/hc/下载/yolo/Yolov8_obb_Prune_Track-main/models/yolo.py", line 332, in parse_model m = eval(m) if isinstance(m, str) else m # eval strings File "", line 1, in NameError: name 'Detect' is not defined

看看你的yaml文件,head输出头得是Detect_v8,不能是Detect

hecheng000 commented 1 year ago

好的 谢谢

在 2023-10-26 14:44:09,"morning tea" @.***> 写道:

Traceback (most recent call last): File "/home/hc/下载/yolo/Yolov8_obb_Prune_Track-main/train.py", line 648, in main(opt) File "/home/hc/下载/yolo/Yolov8_obb_Prune_Track-main/train.py", line 545, in main train(opt.hyp, opt, device, callbacks) File "/home/hc/下载/yolo/Yolov8_obb_Prune_Track-main/train.py", line 118, in train model = Model(cfg or ckpt['model'].yaml, ch=3, nc=nc).to(device) # create File "/home/hc/下载/yolo/Yolov8_obb_Prune_Track-main/models/yolo.py", line 180, in init self.model, self.save = parse_model(deepcopy(self.yaml), ch=[ch]) # model, savelist File "/home/hc/下载/yolo/Yolov8_obb_Prune_Track-main/models/yolo.py", line 332, in parse_model m = eval(m) if isinstance(m, str) else m # eval strings File "", line 1, in NameError: name 'Detect' is not defined

看看你的yaml文件,head输出头得是Detect_v8,不能是Detect

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>