-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
failed to run "./convert.py examples/mnist/lenet.prototxt --code-output-path=mynet.py" #164
Comments
(tensorflow) ubuntu@vm:~/workspace/08_fine_train/fine-tune-alexnet/caffe-tensorflow$ ./convert.py examples/mnist/lenet.prototxt --caffemodel examples/mnist/lenet_iter_10000.caffemodel --data-output-path=mynet.npy |
How have you solved |
try pip install protobuf |
@dinglong1020 How did you fix "AttributeError: 'module' object has no attribute 'proto'"? |
Also, @dinglong1020 How did you fix "AttributeError: 'caffe' has no attribute 'proto'"? |
environment: ubuntu1604 python2.7 tensorflow1.6(only cpu)
(tensorflow) ubuntu@vm:~/workspace/08_fine_train/fine-tune-alexnet/caffe-tensorflow$ ./convert.py examples/mnist/lenet.prototxt --code-output-path=mynet.py
/usr/local/lib/python2.7/dist-packages/h5py/init.py:36: FutureWarning: Conversion of the second argument of issubdtype from
float
tonp.floating
is deprecated. In future, it will be treated asnp.float64 == np.dtype(float).type
.from ._conv import register_converters as _register_converters
Traceback (most recent call last):
File "./convert.py", line 60, in
main()
File "./convert.py", line 56, in main
args.phase)
File "./convert.py", line 27, in convert
transformer = TensorFlowTransformer(def_path, caffemodel_path, phase=phase)
File "/home/ubuntu/workspace/08_fine_train/fine-tune-alexnet/caffe-tensorflow/kaffe/tensorflow/transformer.py", line 221, in init
self.load(def_path, data_path, phase)
File "/home/ubuntu/workspace/08_fine_train/fine-tune-alexnet/caffe-tensorflow/kaffe/tensorflow/transformer.py", line 227, in load
graph = GraphBuilder(def_path, phase).build()
File "/home/ubuntu/workspace/08_fine_train/fine-tune-alexnet/caffe-tensorflow/kaffe/graph.py", line 140, in init
self.load()
File "/home/ubuntu/workspace/08_fine_train/fine-tune-alexnet/caffe-tensorflow/kaffe/graph.py", line 144, in load
self.params = get_caffe_resolver().NetParameter()
File "/home/ubuntu/workspace/08_fine_train/fine-tune-alexnet/caffe-tensorflow/kaffe/caffe/resolver.py", line 32, in get_caffe_resolver
SHARED_CAFFE_RESOLVER = CaffeResolver()
File "/home/ubuntu/workspace/08_fine_train/fine-tune-alexnet/caffe-tensorflow/kaffe/caffe/resolver.py", line 7, in init
self.import_caffe()
File "/home/ubuntu/workspace/08_fine_train/fine-tune-alexnet/caffe-tensorflow/kaffe/caffe/resolver.py", line 23, in import_caffe
self.caffepb = self.caffe.proto.caffe_pb2
AttributeError: 'module' object has no attribute 'proto'
The text was updated successfully, but these errors were encountered: