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

What 's the version of the keras + tensorflow

Open CristXu opened this issue 1 year ago • 3 comments

Describe the bug

After built and install the onnx-tf by pip install -e . The onnx-tf is installed correctly, but after run the onn-tf, it will said: no module keras.src.engin My package version: keras 2.12.0 tensorboard 2.16.2 tensorboard-data-server 0.7.2 tensorflow 2.16.1 tensorflow-addons 0.22.0 tensorflow-intel 2.16.1 tensorflow-io-gcs-filesystem 0.31.0 tensorflow-probability 0.24.0 termcolor 2.4.0 tf_keras 2.16.0

To Reproduce

Please give us instructions to reproduce your problem.

A self-contained piece of code that can demonstrate the problem is required.

Please do not expect us to have PyTorch, Caffe2 installed.

If a model exported from PyTorch and Caffe2 is having trouble in ONNX-TF, use the next section to attach the model.

ONNX model file

If applicable, attach the onnx model file in question using Gist, DropBox or Google Drive.

Python, ONNX, ONNX-TF, Tensorflow version

This section can be obtained by running get_version.py from util folder.

  • Python version:
  • ONNX version:
  • ONNX-TF version:
  • Tensorflow version:

Additional context

Add any other context about the problem here.

CristXu avatar Apr 25 '24 03:04 CristXu

I was able to convert a model from ONNX format to tf, and tf to tf-lite with the following dependency versions:

onnx==1.10.2
onnx_tf==1.10.0
tensorflow==2.8.0
tensorflow-addons==0.17.1
tensorflow-probability==0.16.0
numpy==1.20.0
protobuf==3.19.6 #(For tf -> tf-lite conversion)

Installing the TensorFlow dependencies will also get you the correct tf-keras (2.15.0) and keras (2.8.0) versions.

umihesh avatar Jun 04 '24 08:06 umihesh