tensorflow-vgg16 icon indicating copy to clipboard operation
tensorflow-vgg16 copied to clipboard

Unable to parse the model

Open firstprayer opened this issue 8 years ago • 1 comments

I downloaded the result (cuz I don't wanna install Caffe) and tried to read it in code with:

with open(FLAGS.model_path, 'rb') as f:
  graph_def = tf.GraphDef()
  graph_def.ParseFromString(f.read())

And I got

Traceback (most recent call last):
  File "synthesis.py", line 131, in <module>
    main()
  File "synthesis.py", line 56, in main
    X = load_vgg16() #load_inception()
  File "synthesis.py", line 35, in load_vgg16
    graph_def.ParseFromString(s)
  File "/Users/taiyuanz/tensorflow/lib/python2.7/site-packages/google/protobuf/message.py", line 185, in ParseFromString
    self.MergeFromString(serialized)
  File "/Users/taiyuanz/tensorflow/lib/python2.7/site-packages/google/protobuf/internal/python_message.py", line 1090, in MergeFromString
    raise message_mod.DecodeError('Unexpected end-group tag.')
google.protobuf.message.DecodeError: Unexpected end-group tag.

I don't see anything particularly wrong so I can only guess it was due to incompatibility of protobuf versions. Can you help take a look?

firstprayer avatar Jan 25 '17 09:01 firstprayer

Are there any updates on this? I am currently facing this issue.

kemusa avatar Aug 10 '17 10:08 kemusa