def test_fc_cnn():
x = tf.placeholder(name='x', shape=[50, 32, 32, 1], dtype=tf.float32)
c1 = conv2d(x, [5, 5], [1, 2, 2, 1], 16, scope='conv1')
c2 = conv2d(c1, [5, 5], [1, 2, 2, 1], 64, scope='conv2')
f0 = slim.flatten(c2)
f1 = dense(f0, 100, scope='dense1')
f2 = dense(f1, 10, scope='dense2')
return f2
# [TODO] Need to test BN
# d_params = tf.get_collection(tf.GraphKeys.TRAINABLE_VARIABLES, scope=scope.name)
layer.py 文件源码
python
阅读 40
收藏 0
点赞 0
评论 0
评论列表
文章目录