From b50f827621a288f38b857f4f127c234ffa137591 Mon Sep 17 00:00:00 2001 From: Sai Karthikey Pentapati Date: Mon, 3 Aug 2020 19:47:28 +0530 Subject: [PATCH] Update mytrain.py Replaced & operator with and. Using & will always return true and lr rate decay will happen every epoch --- mytrain.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mytrain.py b/mytrain.py index 289866f..de4eebf 100644 --- a/mytrain.py +++ b/mytrain.py @@ -223,7 +223,7 @@ def gkern(kernlen=13, nsig=1.6): sess.run(tf.global_variables_initializer()) # tf.global_variables_initializer().run() for global_step in range(num_epochs): - if global_step!=0 & np.mod(global_step,10)==0: + if global_step!=0 and np.mod(global_step,10)==0: sess.run(learning_rate_decay_op) total_train_loss = 0 total_valid_loss = 0