def multilayer_perceptron(x):
fc1 = layers.fully_connected(x, 256, activation_fn=tf.nn.relu, scope='fc1')
fc2 = layers.fully_connected(fc1, 256, activation_fn=tf.nn.relu, scope='fc2')
out = layers.fully_connected(fc2, 10, activation_fn=None, scope='out')
tf.Assert(out > 0, [out], name='assert_out_positive')
return out
# build model, loss, and train op
14-mnist-assert-wrong.py 文件源码
python
阅读 32
收藏 0
点赞 0
评论 0
评论列表
文章目录