Reed Wanderman-Milne 9765b5ab7f Improve mixed precision docstrings.
The docstrings have been reworded to make them more clear and concise. Some clarifying information is also added.

I removed some examples for uncommon use cases in order to shorten the docstrings, and rewrote or shortened other examples to make them easier and faster to read.

All references to experimental mixed precision APIs have been changed to use the non-experimental APIs. Examples now use the newly added attribute Layer.dtype_policy as well.

The section "How to use float64 in a Keras model" has been removed. Float64 can be enabled by setting floatx to float64 so I don't think its necessary to mention it in the policy section. Also, it's fairly obvious after reading the Policy docstring how to use float64 using policies: Just set the global policy to "float64".

I intend on cherrypicking this change into TF 2.4.

PiperOrigin-RevId: 339780420
Change-Id: I5f6ad44f54964114c398c306d2d7a4da39bb1c54
2020-11-04 11:22:31 -08:00
..