layers.py 文件源码

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

项目:Theano-MPI 作者: uoguelph-mlrg 项目源码 文件源码
def __call__(self, c01b):
        """
        .. todo::
            WRITEME
        """
        half = self.n // 2

        sq = T.sqr(c01b)

        ch, r, c, b = c01b.shape

        extra_channels = T.alloc(0., ch + 2*half, r, c, b)

        sq = T.set_subtensor(extra_channels[half:half+ch,:,:,:], sq)

        scale = self.k

        for i in xrange(self.n):
            scale += self.alpha * sq[i:i+ch,:,:,:]

        scale = scale ** self.beta

        return c01b / scale
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号