e1aca5875121ef15bdb07243af56eb704d79c794,deepvariant/model_train.py,,run,#Any#Any#Any#Any#,186
Before Change
)
training_hooks = None
if FLAGS.use_early_stopping:
// Early stopping hook depends on existence of events directory.
eval_dir = os.path.join(FLAGS.train_dir, FLAGS.early_stopping_directory)
tf.io.gfile.makedirs(eval_dir)
plateau_decrease = True
if FLAGS.early_stopping_metric_direction == "increase":
plateau_decrease = False
early_stopping_hook = metrics_hook.EarlyStoppingHook(
events_dir=eval_dir,
tag=FLAGS.early_stopping_tag,
num_plateau_steps=FLAGS.early_stopping_num_plateau_steps,
plateau_delta=FLAGS.early_stopping_plateau_delta,
plateau_decrease=plateau_decrease,
every_n_steps=FLAGS.early_stopping_every_n_steps)
training_hooks = [early_stopping_hook]
estimator.train(
input_fn=tf_dataset,
max_steps=FLAGS.number_of_steps,
hooks=training_hooks)
After Change
)
training_hooks = None
if FLAGS.use_early_stopping:
// redacted
raise ValueError("Currently not implemented.")
estimator.train(
input_fn=tf_dataset,
max_steps=FLAGS.number_of_steps,
hooks=training_hooks)
In pattern: SUPERPATTERN
Frequency: 4
Non-data size: 5
Instances
Project Name: google/deepvariant
Commit Name: e1aca5875121ef15bdb07243af56eb704d79c794
Time: 2019-12-05
Author: pichuan@google.com
File Name: deepvariant/model_train.py
Class Name:
Method Name: run
Project Name: NeuroTechX/moabb
Commit Name: 66b0061685aa10d124ef89c9a2f5ddeb7ce1ea1b
Time: 2018-01-24
Author: vjayaram@danube.is.localnet
File Name: moabb/datasets/download.py
Class Name:
Method Name: data_path
Project Name: sassoftware/python-dlpy
Commit Name: 4e82f2a7d39136c2246800090e671c5b3fb978b6
Time: 2019-08-28
Author: ethem.can@sas.com
File Name: dlpy/network.py
Class Name: Network
Method Name: save_to_astore
Project Name: ilastik/ilastik
Commit Name: 1e7ede5f3494e58e54fecd292c8c640ff2cc4720
Time: 2020-10-08
Author: emilmelnikov@gmail.com
File Name: ilastik/config.py
Class Name:
Method Name: init_ilastik_config