Last active
December 3, 2019 08:56
-
-
Save chaserileyroberts/30fe8c69f6432e5246395de419d78f8d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def test_convnet(): | |
image = tf.placeholder(tf.float32, (None, 100, 100, 3) | |
model = Model(image) | |
sess = tf.Session() | |
sess.run(tf.global_variables_initializer()) | |
before = sess.run(tf.trainable_variables()) | |
_ = sess.run(model.train, feed_dict={ | |
image: np.ones((1, 100, 100, 3)), | |
}) | |
after = sess.run(tf.trainable_variables()) | |
for b, a, n in zip(before, after): | |
# Make sure something changed. | |
assert (b != a).any() | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Line 11 should be changed to:
for b, a in zip(before, after):