Skip to content
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

When to convert tensorflow mobilenet frozen graph, occurred error #7

Closed
FrozenGene opened this issue Apr 19, 2018 · 4 comments
Closed

Comments

@FrozenGene
Copy link

The mobilenet model: https://storage.googleapis.com/download.tensorflow.org/models/mobilenet_v1_1.0_224_frozen.tgz

when to convert it, prompt:
File "/usr/local/lib/python3.6/site-packages/tf2onnx-0.0.0.1-py3.6.egg/tf2onnx/convert.py", line 67, in
File "/usr/local/lib/python3.6/site-packages/tf2onnx-0.0.0.1-py3.6.egg/tf2onnx/convert.py", line 56, in main
File "/usr/local/lib/python3.6/site-packages/tf2onnx-0.0.0.1-py3.6.egg/tf2onnx/tfonnx.py", line 1000, in process_tf_graph
File "/usr/local/lib/python3.6/site-packages/tf2onnx-0.0.0.1-py3.6.egg/tf2onnx/tfonnx.py", line 939, in tensorflow_onnx_mapping
File "/usr/local/lib/python3.6/site-packages/tf2onnx-0.0.0.1-py3.6.egg/tf2onnx/tfonnx.py", line 521, in relu6_op
ValueError: negative dimensions are not allowed

@guschmue
Copy link
Collaborator

I changed the default for unknown dimension from -1 to 1 in case the runtime does not support -1 (onnx-caffe2 ie. does not support -1)

@leeqiaogithub
Copy link

I have the same problem when convert mobilenet_v2_1.0_224.pb to onnx.how can i do to resolve it?

@guschmue
Copy link
Collaborator

different issue related to relu6.
Let me see if I can fix it.

@guschmue
Copy link
Collaborator

@leeqiaogithub , I just made some change and the model at least will convert. You could give it a try.
My runtime barks at it, need to look at why but you could try it on your runtime.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants