CLI tool
onnx/tensorflow-onnx avatar
onnx/tensorflow-onnx

tensorflow-onnx asks for a new maintainer and states onnx 1.9 where the manifest says 1.14

Convert TensorFlow, Keras, Tensorflow.js and Tflite models to ONNX

2,561 stars477 forksJupyter NotebookApache-2.0

At a glance

What is it?
The converter that moves TensorFlow, Keras, tensorflow.js and tflite models into ONNX, from the ONNX organisation. The README opens with a request for a new maintainer, the documented onnx floor and the declared floor disagree, and the CLI reference block is cut off mid-argument.
Who is it for?
This is the converter to reach for if your model is already TensorFlow and you need it in ONNX, and the format coverage is documented well enough to check before you start. Three things to settle first.
Can I use it commercially?
Yes. Apache-2.0 is a permissive licence: you can use, modify and sell software built on it, as long as you keep its copyright and licence notices.
Is it still maintained?
Yes. The repository last received commits 12 days ago.
What is it written in?
Mainly Jupyter Notebook, according to GitHub's language statistics.

Answers come from the project's GitHub data, last synced on November 15, 2026, and from our analysis. They are not legal advice.

From daily snapshots

Star history

  • onnx/tensorflow-onnx2,561 ★ · +5
Star history
Repository2026-09-112026-11-15
onnx/tensorflow-onnx2.6k2.6k

5 Stars in the last 65 days, measured from the daily GitHub snapshot. Compare with other projects

Editorial analysis

The README opens with a request for a new maintainer

Before anything about conversion, the document carries a maintainer wanted section stating that the project is looking for a new maintainer to help support and evolve it, and asking interested people to open an issue or comment on the thread with their background. That sits above the technical content, which is unusual placement for a signal of this kind. The release record is consistent with it. v1.16.1 was published in January 2024, then nothing until a release candidate for 1.17.0 in February 2026, and the 1.17.0 final in March 2026. That is a gap of over two years between published versions. The last commit is dated 2026-10-01, so the branch is still moving. The tag naming is not uniform either: the final releases carry a v prefix while the release candidate tag does not.

The prose says onnx 1.9 and the manifest requires 1.14

The install section states that the converter requires onnx 1.9 or better and will install or upgrade onnx if needed. The project metadata declares a different number, listing onnx 1.14.0 or later among its runtime dependencies. A machine with onnx between those two versions satisfies the sentence a reader would consult and fails the constraint the installer enforces, and the failure appears at install time rather than as a clear message. The manifest is otherwise careful about the same kind of decision. numpy carries a floor, flatbuffers carries a floor, and protobuf carries no floor at all, with a comment explaining that it is a transitive dependency of onnx, tensorflow and onnxruntime which already agree, and that declaring its own floor would only risk resolver conflicts without adding safety.

The CLI reference block is cut off and one flag is misspelled

The reference listing gives the input formats as alternatives separated by pipes, one of which is written twice under two names: --input and --graphdef, the latter also appearing on its own as a getting started example. The same block then lists --outputs with the value placeholder spelled GRAPH_OUTPUS, missing the final letter. It ends mid-argument as well, at a flag named --extra_opset whose value is written as a truncated list-of- prefix. So the one place a user looks for the complete option surface has a typo, a cut-off entry, and no indication of what follows. The prose sections below the block do explain the options that did make it, which is where the shape syntax and the layout flags are actually described.

The version comes from a plain text file while the build still reaches for distutils

The metadata marks the version as dynamic, and the packaging script fills it in from a file named VERSION_NUMBER sitting at the repository root, read as plain text. The same script shells out to git rev-parse HEAD to capture the commit, tolerating a failure so a build without git still completes, and then writes a generated version module into the package source during the build and develop steps. Alongside that, the declared build requirement is setuptools 77 or newer while the script itself imports distutils command classes and subclasses build, build_py and develop from both distutils and setuptools. So the version is pinned by a checked-in text file rather than by a tag, and the build path still uses the older packaging entry points the setup.py install, develop and bdist_wheel commands in the README depend on. Three install routes are offered, and only the first two avoid the local script:

pip
pip install -U tf2onnx

Tested opsets run 14 to 18, the default is 15, and 6 to 13 are untested

The supported and tested range is opset 14 through 18, and the resulting graph defaults to opset 15. Anything from 6 to 13 is said to work but is not tested, which is a distinction worth keeping in mind when targeting an older runtime. A command line flag sets a different opset for the output graph:

```python -m tf2onnx.convert --saved-model tensorflow-model-path --opset 18 --output model.onnx```

The tflite example is the one that departs from the stated default, using opset 16. The test matrix in the README pairs those opsets with Python 3.10 to 3.12 and TensorFlow 2.13 to 2.15, and lists the operating systems as Linux and Windows only, while the optional runtime install note offers a runtime for Linux, Windows and Mac.

Unknown-rank inputs need a shape typed on the command line

Models in saved model format need nothing beyond a path and an output name. Every other input format requires you to name the graph inputs and outputs explicitly, with the node names typically carrying a colon and a zero suffix, and those names are found with a separate TensorFlow utility that the README notes must be downloaded and built from source. The recommendation is to go back to whoever produced the model and ask for saved model format instead. Where a model declares placeholders with unknown rank or dimensions, the conversion cannot map them, and the fix is to append a shape in square brackets after the input name, with minus one standing in for an unknown dimension. Two formats are the exception: tflite and tensorflow.js models need no inputs or outputs named at all.

The converted layout keeps whatever TensorFlow had, so it depends on the source

By default the converter preserves the input and output image format found in the TensorFlow model, either channel-first or channel-last, and the explanation given is that the host's native format may differ, with Windows named as an example. Two flags exist to override this in each direction, one for inputs and one for outputs, and the section describing them stops mid-sentence. So the layout of a converted graph is inherited rather than normalised, which means two models converted from the same TensorFlow version can disagree about layout depending on how they were written. The tensorflow.js path is the one explicitly flagged as experimental, with the note that many models from a model hub were tested but not all convert correctly.

Editorial conclusion

This is the converter to reach for if your model is already TensorFlow and you need it in ONNX, and the format coverage is documented well enough to check before you start. Three things to settle first. The project is actively asking for a maintainer, which is a governance signal worth weighing for anything on your critical path. The tested window is narrow, opset 14 to 18 with 6 to 13 untested, so an older target is on you. And the onnx floor appears as 1.9 in the README and 1.14 in the manifest, so the package manager will refuse an environment the documentation says is supported.

Frequently asked questions

How do I convert a TensorFlow saved model to ONNX?

Run the convert module with the saved model path and an output path. The command uses a default opset of 15, and the --opset flag changes it. Models in saved model format do not need their inputs and outputs named.

Which ONNX opsets does tf2onnx support?

Opset 14 to 18 are supported and tested. Opset 6 to 13 are expected to work but are not tested, and the default opset for the generated graph is 15.

What is the minimum onnx version tf2onnx needs?

The install section says onnx 1.9 or better, while the project metadata declares onnx 1.14.0 or later as a runtime dependency. The two floors do not agree, and the manifest is what the installer enforces.

Do I need onnxruntime to convert a model with tf2onnx?

Not for conversion. It is listed as optional, needed if you want to run the tests, with onnxruntime given as an example and noted as available for Linux, Windows and Mac.

Which Python and TensorFlow versions are supported?

Python 3.10 to 3.12 and TensorFlow 2.x, with the test matrix running on 2.13 to 2.15. The project metadata repeats the same Python range in its classifiers and requires 3.10 or newer.

Official sources

  1. Issues
  2. License: Apache-2.0
  3. onnx/tensorflow-onnx on GitHub
  4. README
  5. Releases
Add this badge to your README

If you maintain this project, the badge below links readers to this analysis and shows its maintenance status from the daily GitHub snapshot. Paste the markdown into your README; add ?metric=license or ?metric=stars to the image URL for a different field.

Add this badge to your README

markdown
[![Hysen Labs](https://hysenlabs.com/badge/onnx-tensorflow-onnx.svg)](https://hysenlabs.com/projects/onnx-tensorflow-onnx)

Star history chart for your README

markdown
[![Star history](https://hysenlabs.com/chart/onnx-tensorflow-onnx.svg)](https://hysenlabs.com/projects/onnx-tensorflow-onnx)

Was this useful?