pytorch2keras icon indicating copy to clipboard operation
pytorch2keras copied to clipboard

Package crashes on import with protobuf==3.12.3 and tensorflow==2.2.0 on macOS

Open farzadab opened this issue 4 years ago • 0 comments

Describe the bug I cannot import the pytorch2keras package. I keep getting this error on import:

$ python -c "import pytorch2keras"
[libprotobuf ERROR google/protobuf/descriptor_database.cc:394] Invalid file descriptor data passed to EncodedDescriptorDatabase::Add().
[libprotobuf FATAL google/protobuf/descriptor.cc:1356] CHECK failed: GeneratedDatabase()->Add(encoded_file_descriptor, size):
libc++abi.dylib: terminating with uncaught exception of type google::protobuf::FatalException: CHECK failed: GeneratedDatabase()->Add(encoded_file_descriptor, size):
[1]    16043 abort      python

To Reproduce python -c "import pytorch2keras"

Expected behavior Not crashing.

Logs Already included

Environment (please complete the following information):

  • OS: macOS Catalina (10.15.5)
  • Python 3.6.9 |Intel Corporation (Conda)
  • Version 0.2.4
  • TensorFlow: 2.2.0
  • Protobuf: 3.12.3

Additional context Quick search on the web shows similar problems with TensorFlow (and related libraries) all over the place. However, TF seems alone seems to work fine for me (no errors). Here you can see the links to related problems: https://github.com/tensorflow/tensorflow/issues/35573 https://github.com/onnx/tensorflow-onnx/issues/927 https://stackoverflow.com/questions/60028929/failing-to-launch-tensorboard-from-jupyter

I tried the solutions provided in all of the above (basically reinstalling everything multiple times with different version combinations) but none worked for me.

farzadab avatar Jul 16 '20 20:07 farzadab