码迷,mamicode.com
首页 > Web开发 > 详细

0 - Visualizing and Understanding Convolutional Networks(阅读翻译)

时间:2017-03-19 11:34:43      阅读:526      评论:0      收藏:0      [点我收藏+]

标签:previous   好的   角度   空间   opp   难度   struct   uri   compute   

卷积神经网络的可视化理解(Visualizing and Understanding Convolutional Networks)

 

摘要(Abstract)

近来,大型的卷积神经网络模型在Imagenet数据集上表现出了令人印象深刻的效果,但是现如今大家并没有很清楚地理解为什么它们有如此好的效果,以及如何改善其效果。在这篇文章中,我们对这两个问题均进行了讨论。我们介绍了一种创新性的可视化技术可以深入观察中间的特征层函数的作用以及分类器的行为。作为一项类似诊断性的技术,可视化操作可以使我们找到比Krizhevsky (ALexNet模型)的更好的模型架构。

 

在Imagenet分类数据集上,我们还进行了一项抽丝剥茧的工作,以发现不同的层对结果的影响。我们看到,当softmax分类器重训练后,我们的模型在Imagenet数据集上的结果可以很好地泛化到其他数据集,瞬间就击败了现如今caltech-101以及caltech-256上的最好的方法。

 

 

1、介绍(Introduction)

自从1989年LeCun等人研究推广卷积神经网络(以下称为CNN)之后,在1990年代, CNN在一些图像应用领域展现出极好的效果,例如手写字体识别,人脸识别等等。在去年,许多论文都表示他们可以在一些更有难度的数据集上取得较好的分类效果,Ciresan 等人于2012在NORB和CIFAR-10数据集上取得了最好的效果。更具有代表性的是Krizhevsky等人2012的论文,在ImageNet 2012数据集分类挑战中取得了绝对的优势,他们的错误率仅有16.4%,与此相对的第二名则是 26.1%。

 

造成这种有趣的现象的因素很多 (i)大量的训练数据和已标注数据; (ii) 强大的GPU训练 (iii) 更好的正则化方法如Dropout(Hinton et al., 2012)。尽管如此,我们还是很少能够深入理解神经网络中的机理,以及为何它们能取得如此效果。 从科学的角度讲,这是远远不够的。如果木有清楚地了解其中的本质,那么就只能变成整天像无头苍蝇一样乱试。在本文中,我们介绍一种可视化技术来揭示 输入响应如何在每一层得到独得的特征图谱的。

这也能让我们观察到特征在训练过程中的进化过程,以便分析出模型的潜在问题。我们使用的可视化技术是一种多层的反卷积网络,由Zeiler在2011年提出,把特征映射回最初的像素层层. 我们还进行了一项很有意义的研究,那就是遮挡输入图像的一部分,来说明哪一部分是最分类最有影响的。

 

我们从Krizhevsky的模型开始,逐步探索了其他不同的模型,并发掘出效果更好的模型。我们还探索了不同数据集上的模型泛化能力,仅依靠重训练softmax层。我们这儿讨论的上一种有监督的预训练, 与Hinton 和Bengio, Vincent等人的无监督的训练不同.另外特征泛化能力的讨论在Donahue的2013的论文中也有提及。

 

 

1.1. 相关工作(Related Work)

通过对神经网络可视化方式来获取一些科研灵感是很常有的,但大多数情况人们都只关注第一层,因为第一层比较容易映射到像素层。在较高的网络层就难以处理了, 有一些比较有局限的方法,可以推断出节点的活跃性---Erhan等2009的方法,找到每个节点的最大响应刺激方式, 这是通过在图像空间做梯度下降得到每个节点的最大响应。这需要很细心的操作, 而且也没有给出关于节点某种恒定属性的描述。

 

受此启发有一种改良的方法(Le et al, 2010),在 (Berkes & Wiskott,2006))的基础上作一些延伸,通过计算一个节点的Hessian矩阵来观测节点的一些稳定的属性,问题是对于高层的网络节点, 这些属性变量过于复杂,根本无法通过二次近似法(quadratic approximation)来描述(不懂,大概意思就是该方法难以描述高层复杂网络节点的性质)。

 

 

相反,我们的方法并不是通过大量参数来对节点属性进行描述, 而是看图像的哪一部分激活了特征(类似Donahue et al., 2013,看可视化结果能表明模型中高层的节点究竟是被哪一块区域给激活).我们的可视化结果与此不同,不仅仅是一些输入图像的集合,而是进行了由顶向下的映射来揭示出到底是什么样的结构激活了特征。

 

2. 我们的方法(Approach)

我们使用标准的卷积神经网络模型来实验(LeCun et al.,1989)和(Krizhevsky et al., 2012)。这些模型输入一张2维图像 x i , 通过一系列网络层计算最后输出C个类别的概率向量 y i .每一层都是通过对上一层的(i)个卷积操作得到 (第一层则是原图) ,其中所有的滤波器(卷积权重)都是学习得到的; (ii) 将结果通过一个线性修正函数(relu(x) = max(x,0)); (iii) [可选操作] 对临近点进行最大值池化 (iv) [可选操作] 通过(local contrast operation) 归一化特征(不懂)。更多细节参考(Krizhevsky et al., 2012)的论文以及 (Jarrett et al.,2009)的论文.

 

神经网络的顶部是全连接层,最后一层是softmax层,图3展示了我们实验中使用最多的模型。我们使用一个N幅图像组成的大数据集{x,y},y是类别表签,我们使用交叉熵代价函数,因为这比较适合图像分类,通过?y i与 y i计算得到。网络中的参数:包括卷积权重和全链接权重、偏移值,都是通过梯度反向传播训练得到, 采用的是随机梯度下降法. 第3部分详细讲述其中的细节。

 

2.1. 反卷积可视化(Visualization with a Deconvnet)

想要理解卷积操作要先理解中间层的特征激活是怎么一回事,我们在此介绍一种创新的方法来把特征响应映射回初始的像素空间,看看到底是怎样的输入模式导致了节点响应,我们通过一个反卷积来做到这点 (Zeiler et al., 2011). 反卷积也可以认为是一种神经网络模型,具有同样功能,包括卷积滤波,池化,但是均为反操作, so

instead of mapping pixels to features does the oppo-

site. In (Zeiler et al., 2011), deconvnets were proposed

as a way of performing unsupervised learning. Here,

they are not used in any learning capacity, just as a

probe of an already trained convnet.

To examine a convnet, a deconvnet is attached to each

of its layers, as illustrated in Fig. 1(top), providing a

continuous path back to image pixels. To start, an

input image is presented to the convnet and features

computed throughout the layers. To examine a given

convnet activation, we set all other activations in the

layer to zero and pass the feature maps as input to

the attached deconvnet layer. Then we successively

(i) unpool, (ii) rectify and (iii) filter to reconstruct

the activity in the layer beneath that gave rise to the

chosen activation. This is then repeated until input

pixel space is reached.

Unpooling: In the convnet, the max pooling opera-

tion is non-invertible, however we can obtain an ap-

proximate inverse by recording the locations of the

maxima within each pooling region in a set of switch

variables. In the deconvnet, the unpooling operation

uses these switches to place the reconstructions from

the layer above into appropriate locations, preserving

the structure of the stimulus. See Fig. 1(bottom) for

an illustration of the procedure.

Rectification: The convnet uses relu non-linearities,

which rectify the feature maps thus ensuring the fea-

ture maps are always positive. To obtain valid fea-

ture reconstructions at each layer (which also should

be positive), we pass the reconstructed signal through

a relu non-linearity.

Filtering: The convnet uses learned filters to con-

volve the feature maps from the previous layer. To

Visualizing and Understanding Convolutional Networks

invert this, the deconvnet uses transposed versions of

the same filters, but applied to the rectified maps, not

the output of the layer beneath. In practice this means

flipping each filter vertically and horizontally.

Projecting down from higher layers uses the switch

settings generated by the max pooling in the convnet

on the way up. As these switch settings are peculiar

to a given input image, the reconstruction obtained

from a single activation thus resembles a small piece

of the original input image, with structures weighted

according to their contribution toward to the feature

activation. Since the model is trained discriminatively,

they implicitly show which parts of the input image

are discriminative. Note that these projections are not

samples from the model, since there is no generative

process involved.

 

 

 

 

 

 

 

 

 

 

 

 

 

 

0 - Visualizing and Understanding Convolutional Networks(阅读翻译)

标签:previous   好的   角度   空间   opp   难度   struct   uri   compute   

原文地址:http://www.cnblogs.com/lucky3206/p/6579244.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!