在开发的时候,我的是amd显卡,所以下载的tensor flow是cpu版本,环境配置不方便,出了很多问题这是关于object_detection的配置问题
AttributeError: module 'object_detection.protos.faster_rcnn_pb2' has no attribute 'AttentionPosition'
AttributeError:模块“object_detection.protos.faster_rcnn_pb2”没有属性“AttentionPosition”
主要看下:
1、版本匹配,是否更新下最新版本
2、导入问题,检查下模块导入路径,最好是绝对路径,不用带有空格、中文等
可能是由于你下载的 TensorFlow 版本和代码中使用的 TensorFlow 版本不匹配造成的。
最上面加上试下
import sys
sys.path.append('yourpath/to/Tensorflow/models/research')