diff options
author | 2018-01-09 15:12:55 -0800 | |
---|---|---|
committer | 2018-01-09 15:20:03 -0800 | |
commit | 8f07a0677bf26506a49d7a714a63f5fd115e6945 (patch) | |
tree | 97f2bb3f5e73789b5a0f6b3142f10de8920d2f96 /tensorflow/contrib/estimator/__init__.py | |
parent | 454885e6546660d8f7eeb3ce137580b0505e9a77 (diff) |
Simplify replicate_model_fn.GatheringOptimizer inspired by the past comments.
- I worked around the need to rely on Optimizer.__class__ for keeping track of the gradients. Now we are relying on the order of collecting them. I also added a basic verification that all towers have indeed called the same number of optimizers.
- I now allow the user to increment global step however many times they wish.
The changes above allowed me to support using the same optimizer class multiple times in a tower.
I also renamed GatheringOptimizer to TowerOptimizer, which is a breaking change. #lifeincontrib
PiperOrigin-RevId: 181381569
Diffstat (limited to 'tensorflow/contrib/estimator/__init__.py')
-rw-r--r-- | tensorflow/contrib/estimator/__init__.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tensorflow/contrib/estimator/__init__.py b/tensorflow/contrib/estimator/__init__.py index 7533943d48..0f75b77050 100644 --- a/tensorflow/contrib/estimator/__init__.py +++ b/tensorflow/contrib/estimator/__init__.py @@ -47,7 +47,7 @@ _allowed_symbols = [ 'dnn_logit_fn_builder', 'linear_logit_fn_builder', 'replicate_model_fn', - 'GatheringOptimizer', + 'TowerOptimizer', ] remove_undocumented(__name__, allowed_exception_list=_allowed_symbols) |