Skip to content

Commit cce9bd0

Browse files
author
wayuanho
committed
fix unittest bug
1 parent fc8265f commit cce9bd0

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

tests/test_backend.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -381,8 +381,9 @@ def test_dropout(self):
381381
x_val = np.ones([1, 24, 24, 3], dtype=np.float32)
382382
# Define a scope for reusing the variables
383383
x = tf.placeholder(tf.float32, shape=x_val.shape, name="input_1")
384+
x_ = tf.identity(x)
384385

385-
fc1 = tf.layers.dropout(x, rate=.1, training=is_training)
386+
fc1 = tf.layers.dropout(x_, rate=.1, training=is_training)
386387

387388
_ = tf.identity(fc1, name="output")
388389
feed_dict = {"input_1:0": x_val}

0 commit comments

Comments
 (0)