Skip to main content

Converting TensorFlow Lite models to ONNX models

Project description

Convert TensorFlow Lite models to ONNX

Build and Test Sanity

This tflite2onnx package converts TensorFlow Lite (TFLite) models (*.tflite) to ONNX models (*.onnx).

This project is under early stage of development, contributions are welcome at GitHub.

Installation

Simply install via pip. This package requires tflite, onnx and numpy which should be installed automatically.

pip install tflite2onnx

Usage

It's simple as below. Command line tool will be provided soon.

import tflite2onnx

tflite_path = '/path/to/original/tflite/model'
onnx_path = '/path/to/save/converted/onnx/model'

tflite2onnx.convert(tflite_path, onnx_path)

If you'd like to convert a TensorFlow model (*.pb) to ONNX, you may try tf2onnx. Or, you can firstly convert TensorFlow model (*.pb) to TensorFlow Lite models (*.tflite), and then convert to ONNX using this tool.

Resources

License

Apache License Version 2.0.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

tflite2onnx-0.1.0-py3-none-any.whl (19.2 kB view details)

Uploaded Python 3

File details

Details for the file tflite2onnx-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: tflite2onnx-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 19.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.5.2

File hashes

Hashes for tflite2onnx-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 f5f1e8c755bd585186378901290ce6b4264ef9e7f013ce9b3c9f676a5bd1e99d
MD5 2331d06b2fa083bd54f0e134013d3d9a
BLAKE2b-256 0fd8296126f59d0b1019a6b3d960ea8e8c37bc5806e7d2fc36d1e8f51574c159

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page