本文介绍了一种用于构建堆叠式卷积自动编码器的方法。基于该论文和一些Google搜索,我得以实现上述网络。基本上,您需要的所有内容都在Theano卷积网络和去噪自动编码器教程中进行了描述,但有一个关键例外:如何逆转卷积网络中的最大池化步骤。在这次讨论中 ,我能够使用一种方法来解决这一问题 -最棘手的部分是确定W_prime的正确尺寸,因为这些尺寸将取决于前馈滤波器的大小和池比率。这是我的反相函数:
def get_reconstructed_input(self, hidden):
""" Computes the reconstructed input given the values of the hidden layer """
repeated_conv = conv.conv2d(input = hidden, filters = self.W_prime, border_mode='full')
multiple_conv_out = [repeated_conv.flatten()] * np.prod(self.poolsize)
stacked_conv_neibs = T.stack(*multiple_conv_out).T
stretch_unpooling_out = neibs2images(stacked_conv_neibs, self.pl, self.x.shape)
rectified_linear_activation = lambda x: T.maximum(0.0, x)
return rectified_linear_activation(stretch_unpooling_out + self.b_prime.dimshuffle('x', 0, 'x', 'x'))
0
我想设计一个具有一个(或多个)卷积层(CNN)和一个或多个完全连接的隐藏层的深层网络。
对于具有完全连接层的深度网络,theano中提供了无监督预训练的方法,例如,使用降噪自动编码器或RBM 。
我的问题是:如何在卷积层中实现无监督的预训练阶段(在theano中)?
我不希望有完整的实现方案作为答案,但是,我希望能链接到好的教程或可靠的参考资料。