zoukankan      html  css  js  c++  java
  • Pooling

    Pooling: Overview

    After obtaining features using convolution, we would next like to use them for classification. In theory, one could use all the extracted features with a classifier such as a softmax classifier, but this can be computationally challenging. Consider for instance images of size 96x96 pixels, and suppose we have learned 400 features over 8x8 inputs. Each convolution results in an output of size (96 − 8 + 1) * (96 − 8 + 1) = 7921, and since we have 400 features, this results in a vector of 892 * 400 = 3,168,400 features per example. Learning a classifier with inputs having 3+ million features can be unwieldy, and can also be prone to over-fitting.  滑动窗口!

    To address this, first recall that we decided to obtain convolved features because images have the "stationarity" property, which implies that features that are useful in one region are also likely to be useful for other regions. Thus, to describe a large image, one natural approach is to aggregate statistics of these features at various locations. For example, one could compute the mean (or max) value of a particular feature over a region of the image. These summary statistics are much lower in dimension (compared to using all of the extracted features) and can also improve results (less over-fitting). We aggregation operation is called this operation pooling, or sometimes mean pooling or max pooling (depending on the pooling operation applied).

    The following image shows how pooling is done over 4 non-overlapping regions of the image.

    Pooling schematic.gif

    Pooling for Invariance

    If one chooses the pooling regions to be contiguous areas in the image and only pools features generated from the same (replicated) hidden units. Then, these pooling units will then be translation invariant. This means that the same (pooled) feature will be active even when the image undergoes (small) translations. Translation-invariant features are often desirable; in many tasks (e.g., object detection, audio recognition), the label of the example (image) is the same even when the image is translated. For example, if you were to take an MNIST digit and translate it left or right, you would want your classifier to still accurately classify it as the same digit regardless of its final position.

    对轻微的变换具有不变性

    Formal description

    Formally, after obtaining our convolved features as described earlier, we decide the size of the region, say m 	imes n to pool our convolved features over. Then, we divide our convolved features into disjoint m 	imes n regions, and take the mean (or maximum) feature activation over these regions to obtain the pooled convolved features. These pooled features can then be used for classification.

    在convolved feature之后,使用pooling —— 在m*n的不相交区域

    首先在前面的使用convolution时是利用了图像的stationarity特征,即不同部位的图像的统计特征是相同的,那么在使用convolution对图片中的某个局部部位计算时,得到的一个向量应该是对这个图像局部的一个特征,既然图像有stationarity特征,那么对这个得到的特征向量进行统计计算的话,所有的图像局部块应该也都能得到相似的结果。对convolution得到的结果进行统计计算过程就叫做pooling

    其实都是利用统计特性~~

  • 相关阅读:
    Python 自动化测试实战训练营,由浅入深,从小白到测试高手!
    接口测试 Mock 实战(二) | 结合 jq 完成批量化的手工 Mock
    从文科生转行测试,再到大厂测试开发工程师,我是如何做到的?
    严正声明|严厉打击盗版侵权、非法销售「霍格沃兹测试学院」课程的违法行为
    「金羽毛」有奖征文 | 记录测试开发技术进阶之路的点滴
    测试工程师职业发展漫谈
    Workshop 深圳站|实战+源码架构剖析带你揭开Appium的神秘面纱
    那些难改的 Bug,最后都怎样了?
    BAT大厂都在用的Docker。学会这三招,面试、工作轻松hold住
    2021 开年学习送福利,助力测试进阶提升!
  • 原文地址:https://www.cnblogs.com/sprint1989/p/3981702.html
Copyright © 2011-2022 走看看