Adds clarity on supported formats for TFLiteConverter 2.0.
PiperOrigin-RevId: 238324267
This commit is contained in:
parent
dd7daa8cc7
commit
278bddcee2
@ -150,7 +150,20 @@ output_data = interpreter.get_tensor(output_details[0]['index'])
|
|||||||
print(output_data)
|
print(output_data)
|
||||||
```
|
```
|
||||||
|
|
||||||
## Summary of changes in TFLiteConverter in 1.X and 2.0 <a name="differences"></a>
|
## Summary of changes in `TFLiteConverter` between 1.X and 2.0 <a name="differences"></a>
|
||||||
|
|
||||||
|
The following section summarizes the changes in `TFLiteConverter` from 1.X to
|
||||||
|
2.0. If any of the changes raise concerns, please file a
|
||||||
|
[GitHub issue](https://github.com/tensorflow/tensorflow/issues).
|
||||||
|
|
||||||
|
### Supported formats
|
||||||
|
|
||||||
|
`TFLiteConverter` in 2.0 supports SavedModels and Keras model files generated in
|
||||||
|
both 1.X and 2.0. However, the conversion process no longer supports frozen
|
||||||
|
`GraphDefs` generated in 1.X. Users who want to convert frozen `GraphDefs` to
|
||||||
|
TensorFlow Lite should use `tensorflow.compat.v1`.
|
||||||
|
|
||||||
|
### Quantization-aware training
|
||||||
|
|
||||||
The following attributes and methods associated with
|
The following attributes and methods associated with
|
||||||
[quantization-aware training](https://github.com/tensorflow/tensorflow/tree/master/tensorflow/contrib/quantize)
|
[quantization-aware training](https://github.com/tensorflow/tensorflow/tree/master/tensorflow/contrib/quantize)
|
||||||
@ -173,6 +186,8 @@ removed in the 2.0 API until the new quantization API is launched. Users who
|
|||||||
want to convert models generated by the rewriter function can use
|
want to convert models generated by the rewriter function can use
|
||||||
`tensorflow.compat.v1`.
|
`tensorflow.compat.v1`.
|
||||||
|
|
||||||
|
### Changes to attributes
|
||||||
|
|
||||||
The `target_ops` attribute has become an attribute of `TargetSpec` and renamed
|
The `target_ops` attribute has become an attribute of `TargetSpec` and renamed
|
||||||
to `supported_ops` in line with future additions to the optimization framework.
|
to `supported_ops` in line with future additions to the optimization framework.
|
||||||
|
|
||||||
@ -190,15 +205,14 @@ Additionally, the following attributes have been removed:
|
|||||||
* `dump_graphviz_dir`
|
* `dump_graphviz_dir`
|
||||||
* `dump_graphviz_video`
|
* `dump_graphviz_video`
|
||||||
|
|
||||||
|
### Deprecated APIs
|
||||||
|
|
||||||
The following methods that were previously deprecated in 1.X will no longer be
|
The following methods that were previously deprecated in 1.X will no longer be
|
||||||
exported in 2.0:
|
exported in 2.0:
|
||||||
|
|
||||||
* `lite.toco_convert`
|
* `lite.toco_convert`
|
||||||
* `lite.TocoConverter`
|
* `lite.TocoConverter`
|
||||||
|
|
||||||
If any of the changes raise concerns, please file a
|
|
||||||
[GitHub issue](https://github.com/tensorflow/tensorflow/issues).
|
|
||||||
|
|
||||||
## Installing TensorFlow <a name="versioning"></a>
|
## Installing TensorFlow <a name="versioning"></a>
|
||||||
|
|
||||||
### Installing the TensorFlow 2.0 nightly <a name="2.0-nightly"></a>
|
### Installing the TensorFlow 2.0 nightly <a name="2.0-nightly"></a>
|
||||||
|
Loading…
Reference in New Issue
Block a user