最近自己在搞YOLOv5目标检测学习,对模型的搭建遇到了很多问题,查看了很多资料,经过一些大神的回答,这个模型终于是跑起来了。把自己的错误总结整理一下。
错误一:
AttributeError: Can't get attribute 'SPPF' on
改正:
你去他的6.0版本的moudle里把SPPFF类复制到你的5.0里 或者
class SPPF(nn.Module):
# export-friendly version of nn.SiLU()
@staticmethod
def forward(x):
return x * torch.sigmoid(x) 这段加到models的common
错误二;
DistributionNotFound: The 'pycocotools>=2.0' distribution was not found and is required by the application
改正 :
安装包https://pan.baidu.com/s/1nWQdPRtGwNnOO2DkxRuGuA提取码:i5d7
安装完直接解压复制其中pycocotools两个文件夹到conda环境…Libsite-packages之中
错误三:
Error loading data from ../coco128/images/train2017/: train: ..coco128imagestrain2017 does not exist
改正;
查看你下载的,需要将数据解压
错误四:
ValueError: Media Bounding Box Debugger/Images is invalid. Please remove invalid filename characters
改正:
pip uninstall wandb 在你的环境中卸载掉
错误五:
parser.add_argument('--cfg', type=str, default='./models/yolov5s.yaml', help='model.yaml path')
改正:
把cfg那行default填上
错误六:
Image Not Found
改正:
不能有中文路径
错误七:
Command 'pip install 'colorama; platform_system == "Windows"'' returned non-zero exit status 1.
改正
pip install colorama
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)