Skip to content

Commit

Permalink
PR #17957: [keras/estimator] Standardise docstring usage of "Default to"
Browse files Browse the repository at this point in the history
Imported from GitHub PR #17957

This is one of many PRs. Discussion + request to split into multiple PRs @ #17748
Copybara import of the project:

--
037fc4a by Samuel Marks <807580+SamuelMarks@users.noreply.github.com>:

[keras/estimator/__init__.py] Standardise docstring usage of "Default to"

Merging this change closes #17957

FUTURE_COPYBARA_INTEGRATE_REVIEW=#17957 from SamuelMarks:keras.estimator-defaults-to 037fc4a
PiperOrigin-RevId: 535275444
  • Loading branch information
SamuelMarks authored and tensorflower-gardener committed May 26, 2023
1 parent 2b457af commit 73fdc74
Showing 1 changed file with 9 additions and 10 deletions.
19 changes: 9 additions & 10 deletions keras/estimator/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,18 +114,17 @@ def input_fn():
`tempfile.mkdtemp`
config: `RunConfig` to config `Estimator`. Allows setting up things in
`model_fn` based on configuration such as `num_ps_replicas`, or
`model_dir`. Defaults to `None`. If both `config.model_dir` and the
`model_dir`. If both `config.model_dir` and the
`model_dir` argument (above) are specified the `model_dir` **argument**
takes precedence.
takes precedence. Defaults to `None`.
checkpoint_format: Sets the format of the checkpoint saved by the
estimator when training. May be `saver` or `checkpoint`, depending on
whether to save checkpoints from `tf.train.Saver` or
`tf.train.Checkpoint`. This argument currently defaults to `saver`. When
2.0 is released, the default will be `checkpoint`. Estimators use
name-based `tf.train.Saver` checkpoints, while Keras models use
object-based checkpoints from `tf.train.Checkpoint`. Currently, saving
object-based checkpoints from `model_to_estimator` is only supported by
Functional and Sequential models. Defaults to 'saver'.
`tf.train.Checkpoint`. Estimators use name-based `tf.train.Saver`
checkpoints, while Keras models use object-based checkpoints from
`tf.train.Checkpoint`. Currently, saving object-based checkpoints
from `model_to_estimator` is only supported by Functional and
Sequential models. Defaults to 'saver'.
metric_names_map: Optional dictionary mapping Keras model output metric
names to custom names. This can be used to override the default Keras
model output metrics names in a multi IO model use case and provide
Expand Down Expand Up @@ -312,9 +311,9 @@ def input_fn():
`tempfile.mkdtemp`
config: `RunConfig` to config `Estimator`. Allows setting up things in
`model_fn` based on configuration such as `num_ps_replicas`, or
`model_dir`. Defaults to `None`. If both `config.model_dir` and the
`model_dir`. If both `config.model_dir` and the
`model_dir` argument (above) are specified the `model_dir` **argument**
takes precedence.
takes precedence. Defaults to `None`.
checkpoint_format: Sets the format of the checkpoint saved by the
estimator when training. May be `saver` or `checkpoint`, depending on
whether to save checkpoints from `tf.compat.v1.train.Saver` or
Expand Down

0 comments on commit 73fdc74

Please sign in to comment.