ops_test.py 文件源码

python
阅读 32 收藏 0 点赞 0 评论 0

项目:the-neural-perspective 作者: GokuMohandas 项目源码 文件源码
def testMovingAverageVariables(self):
    height, width = 3, 3
    with self.test_session():
      images = tf.random_uniform((5, height, width, 3), seed=1)
      ops.batch_norm(images, scale=True)
      moving_mean = tf.moving_average_variables()[0]
      moving_variance = tf.moving_average_variables()[1]
      self.assertEquals(moving_mean.op.name, 'BatchNorm/moving_mean')
      self.assertEquals(moving_variance.op.name, 'BatchNorm/moving_variance')
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号