Do not export from eval on train data steps.
PiperOrigin-RevId: 168374021
This commit is contained in:
parent
9b9e54b344
commit
f7ba16fdf3
@ -410,7 +410,8 @@ class Experiment(object):
|
||||
delay_secs,
|
||||
throttle_delay_secs,
|
||||
evaluate_checkpoint_only_once=True,
|
||||
continuous_eval_predicate_fn=None):
|
||||
continuous_eval_predicate_fn=None,
|
||||
export=True):
|
||||
"""Run continuous eval.
|
||||
|
||||
Runs infinite eval on the evaluation data set. This function starts
|
||||
@ -436,6 +437,7 @@ class Experiment(object):
|
||||
handles that gracefully. When `predicate_fn` is not specified,
|
||||
continuous eval will run in an infinite loop (if `train_steps` is None)
|
||||
or exit once global step reaches `train_steps`.
|
||||
export: Whether to export from this step. Default is 'True'.
|
||||
|
||||
Raises:
|
||||
ValueError: if `continuous_eval_predicate_fn` is neither None nor
|
||||
@ -495,7 +497,8 @@ class Experiment(object):
|
||||
if not eval_result:
|
||||
eval_result = {}
|
||||
|
||||
self._maybe_export(eval_result, checkpoint_path=latest_path)
|
||||
if export:
|
||||
self._maybe_export(eval_result, checkpoint_path=latest_path)
|
||||
|
||||
# Clear warning timer and update last evaluated checkpoint
|
||||
last_warning_time = 0
|
||||
@ -541,7 +544,8 @@ class Experiment(object):
|
||||
name=name,
|
||||
delay_secs=delay_secs,
|
||||
throttle_delay_secs=throttle_delay_secs,
|
||||
continuous_eval_predicate_fn=continuous_eval_predicate_fn)
|
||||
continuous_eval_predicate_fn=continuous_eval_predicate_fn,
|
||||
export=False)
|
||||
|
||||
def train_and_evaluate(self):
|
||||
"""Interleaves training and evaluation.
|
||||
|
Loading…
Reference in New Issue
Block a user