|
Traceback (most recent call last):
File "./tools/train_net.py", line 124, in <module>
max_iters=args.max_iters)
File "/home/dfy888/py2_caffe_faster_rcnn_works/py-faster-rcnn/tools/../lib/fast_rcnn/train.py", line 161, in train_net
pretrained_model=pretrained_model)
File "/home/dfy888/py2_caffe_faster_rcnn_works/py-faster-rcnn/tools/../lib/fast_rcnn/train.py", line 52, in __init__
pb2.text_format.Merge(f.read(), self.solver_param)
AttributeError: 'module' object has no attribute 'text_format'
当前环境已经安装了protobuf == 3.9.1
import google.protobuf as pb2
解决:
18行后加上from google.protobuf import text_format
53行改为text_format.Merge(f.read(), self.solver_param)
|
|