[RFC] Deprecate the iree-import-tf tool and iree-tools-tf package #19917
Labels
discussion
Proposals, open-ended questions, etc
integrations/tensorflow
TensorFlow model import and conversion
I propose we move to delete the existing TensorFlow support code and packages and direct users to upstream tools (if they exist) to produce programs in one of IREE's supported input formats (StableHLO/TOSA/Torch/Linalg MLIR).
Motivation
Issues like #19852 have recently shown that our support for importing from TensorFlow SavedModel and compiling via StableHLO is no longer reliable. I also have not seen many users deliberately using TensorFlow lately (TensorFlow Lite is a slightly different story), though several of our documentation pages still use TensorFlow as a guiding example. Separate from this RFC, I plan on updating those pages to use a different framework like ONNX.
Background
Our current import pipeline relies on the
iree-import-tf
tool that we publish as part of theiree-tools-tf
package:The import tool uses the
experimental_run_pass_pipeline
API from TensorFlow's Python packages, running thetf-lower-to-mlprogram-and-hlo
pipeline. This produces StableHLO but not VHLO, so it is not subject to the compatibility guarantees that StableHLO advertises: https://openxla.org/stablehlo/compatibility.Upstream alternatives
We can work with StableHLO (https://github.com/openxla/stablehlo) and TensorFlow (https://github.com/tensorflow/tensorflow/) maintainers to see what path (if any) from TensorFlow to our compiler can be supported. There are existing guides like https://openxla.org/stablehlo/tutorials/jax-export that show existing paths. This might need a new path, or maybe TF -> TFLite -> TOSA.
I'd like us to get to a state where we can say "follow this upstream guide to get into this format, then we'll support it". Right now, we provide our own packages built on experimental and unsupported APIs and this is too much of a support burden.
Deprecation tasklist
iree-base-compiler
package? Restructure Python wheels following TF[Lite] importer changes #13483The text was updated successfully, but these errors were encountered: