tensorflow / 2.9.1 / compat / v1 / lite / toco_convert.html /

tf.compat.v1.lite.toco_convert

Convert a TensorFlow GraphDef to TFLite. (deprecated)

This function is deprecated. Please use tf.lite.TFLiteConverter API instead. Conversion can be customized by providing arguments that are forwarded to build_model_flags and build_conversion_flags (see documentation for details). Args: input_data: Input data (i.e. often sess.graph_def). input_tensors: List of input tensors. Type and shape are computed using foo.shape and foo.dtype. output_tensors: List of output tensors (only .name is used from this). *args: See build_model_flags and build_conversion_flags. **kwargs: See build_model_flags and build_conversion_flags.

Returns
The converted TensorFlow Lite model in a bytes array.
Raises
Defined in convert.

© 2022 The TensorFlow Authors. All rights reserved.
Licensed under the Creative Commons Attribution License 4.0.
Code samples licensed under the Apache 2.0 License.
https://www.tensorflow.org/versions/r2.9/api_docs/python/tf/compat/v1/lite/toco_convert