Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 3656bbc

Browse files
author
Taylor Robie
committed
make logs a little easier to read
1 parent 49d7c0e commit 3656bbc

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

official/resnet/resnet_run_loop.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -391,8 +391,11 @@ def resnet_main(
391391
"""
392392

393393
print("\n" * 3)
394+
sys.stdout.flush()
395+
394396
tf.logging.info("TF version: {}".format(tf.VERSION))
395397
tf.logging.info("TF git version: {}".format(tf.GIT_VERSION))
398+
396399
print("\n" * 3)
397400
sys.stdout.flush()
398401

@@ -490,8 +493,14 @@ def input_fn_eval():
490493
schedule[-1] = flags_obj.train_epochs - sum(schedule[:-1]) # over counting.
491494

492495
for cycle_index, num_train_epochs in enumerate(schedule):
496+
print("\n" * 3)
497+
sys.stdout.flush()
498+
493499
tf.logging.info('Starting cycle: %d/%d', cycle_index, int(n_loops))
494500

501+
print("\n" * 3)
502+
sys.stdout.flush()
503+
495504
if num_train_epochs:
496505
classifier.train(input_fn=lambda: input_fn_train(num_train_epochs),
497506
hooks=train_hooks, steps=5)

0 commit comments

Comments
 (0)