AttributeError: ‘NoneType‘ object has no attribute ‘shape

在这里插入图片描述
出现这类错误一般都是我遇到的都是数据集相关的问题:

  • 数据集路径是否写对;
  • 分类问题,标签数量是否正确,打标签是否正确;
  • 语义分割,训练集、验证集中groundtruth与对应的image的数量是否相同;
  • 数据为图像时,其格式是否有要求,jpg,png等

猜你喜欢

转载自blog.csdn.net/weixin_42535423/article/details/115140146