当前位置:网站首页>DropBlock: Regularization method and reproduction code for convolutional layers
DropBlock: Regularization method and reproduction code for convolutional layers
2022-08-04 07:18:00 【hot-blooded chef】
论文:https://arxiv.org/pdf/1810.12890.pdf
1、什么是Dropout?
I believe you must understandDropout,所谓DropoutIs a method improving neural network generalization,Can effectively reduce the fitting.Why it works?From the chart analysis:

A standard neural network as shown in figure(a)所示,Because of the training data(Suppose to face data)的局限性,Makes the neural network is very dependent on a single neuron,And other neurons is equivalent to not work,Network only every time to determine whether the individual in the eyes.If at this time with a new set of test data directly to the network identification,Probably because in the picture, his eyes obscured and wrong results.It is also more common over fitting phenomenon.
So if we like(b)一样,Random inactivation of several neurons,Forcing the network to allow more neurons work,Network not only identify the human eye characteristics,But will also identify the mouth,鼻子等.So in the face of test set,Even if the training data and test data of different,Accuracy is not too low.
2、DropBlock
dropoutRegularization method is widely used in the connection layer,且效果较好,But for volume but less effective at the grass-roots level.Because the volume at the grass-roots level is the characteristics of the spatial correlation of,Just randomly on the space for some neurons deactivation,Equivalent to only make a few pixels deactivation,And the characteristics of the normal image is greater than the size of a pixel point,Convolution layer can still other no inactivation by sensing area unit determine the corresponding characteristics of,So the information will through the volume at the grass-roots level to the next layer of.
作者提出了DropBlock,A structureddropout.它和dropout思想一样,Is randomly throw away,But you lost a single piece of a lost,如下图(c)所示.Thus forcing the convolution layer neurons can not be lost through spatially associated reasoning out the characteristics of a living area information,Forcing the network from other feature reasoning,起到正则化作用.

3、DropBlock算法流程
简单来说,就两步:
- Randomly select two points on characteristic figure(和dropout一样的操作)
- 以这个点为中心,Diffusion of fixed size side,Then he put the rectangular piece of inactivation of neurons
但为了DropBlockDoes not exceed the area of feature layer etc,There are also some super parameters need to set up,Detailed pseudo-code algorithm process as shown in the figure below:

算法流程
- A feature input layer(A), b l o c k _ s i z e , γ , m o d e block\_size,\gamma,mode block_size,γ,mode三个参数
- 通过 m o d e mode modeJudgment is in the stage of training or prediction stage,如果是测试阶段,The direct return feature layerA
- 根据 γ \gamma γ,Using Bernoulli function( B e r n o u l l i Bernoulli Bernoulli)生成只有0,1的矩阵M
- 每个0Center of lattice as,创建形状为( b l o c k _ s i z e ∗ b l o c k _ s i z e block\_size * block\_size block_size∗block_size)The space of a squaremaskAnd fill out this area0处理
- 将A与M点乘
- For the sake of the layer with the same mean and variance,进行归一化操作
其中 γ \gamma γIs calculated:
γ = 1 − k e e p _ p r o b ( b l o c k _ s i z e ) 2 ( f e a t _ s i z e ) 2 ( f e a t _ s i z e − b l o c k _ s i z e + 1 ) 2 \gamma = \frac{1 - keep\_prob}{(block\_size)^2}\frac{(feat\_size)^2}{(feat\_size-block\_size+1)^2} γ=(block_size)21−keep_prob(feat_size−block_size+1)2(feat_size)2
- k e e p _ p r o b keep\_prob keep_prob是和dropoutThe probability of preserving neurons,The experimental results obtained in0.75-0.95之间比较好
- f e a t _ s i z e feat\_size feat_size是特征层的大小
- ( f e a t _ s i z e − b l o c k _ s i z e + 1 ) 2 (feat\_size-block\_size+1)^2 (feat_size−block_size+1)2保证dropOut of the area was not more than the size of the feature layer
DropBlock调度
固定的 k e e p _ p r o b keep\_prob keep_probIn training is not good.太小的 k e e p _ p r o b keep\_prob keep_probWould the hero at the start of the training,所以从1开始逐渐减小,Model will be more strong robustness.
4、实验结果
DropBlockVerifying the accuracy of
所有的实验都是在ImageNetData set on the test,DropBlock( b l o c k _ s i z e = 7 block\_size=7 block_size=7)相比dropout,Accuracy is about1.13%提升.

Keep_prob的选取
The main contrast in different k e e p _ p r o b keep\_prob keep_prob数值下,DropBlock和DropBlock的影响.其中所有的drop方法都是在ResNet的group3和group4上进行的,结果显示在 k e e p _ p r o b = 0.9 keep\_prob=0.9 keep_prob=0.9时效果最好.

Block_szie的选取
同样,所有的drop方法都是在ResNet的group3和group4上进行的,结果显示 b l o c k _ s i z e = 7 block\_size=7 block_size=7时效果最好.

结果可视化
The author also on hot to do the contrast,我们可以清楚的看到, b l o c k _ s i z e = 1 block\_size=1 block_size=1时,Characteristics of the activated areas sometimes than withoutDropBlock多,Sometimes the effect will be worse.这也很容易理解, b l o c k _ s i z e = 1 block\_size=1 block_size=1时DropBlock退化成dropout.而在 b l o c k _ s i z e = 7 block\_size=7 block_size=7时,Activate the regional obviously a lot more.

5、算法复现
The authors of the paper and not related to open source code,May be because of better repetition.The author himself withKerasThe custom level of repetition.
边栏推荐
猜你喜欢

nacos 返回 403 unknown user 太他么坑了 源码解析

零分贝超静音无线鼠标!数量有限!!先到先得!!!【元旦专享】

Online public account article content to audio file practical gadget

ERROR 2003 (HY000) Can‘t connect to MySQL server on ‘localhost3306‘ (10061)解决办法

Mac安装PHP开发环境

2022年7月总结

Computer software: recommend a disk space analysis tool - WizTree

JVM 快速检测死锁

CSRF和SSRF漏洞

Software: Recommend a domestic and very easy-to-use efficiency software uTools to everyone
随机推荐
【C# - 方法封装】数据转换
curl (7) Failed connect to localhost8080; Connection refused
窥探晶体世界的奥秘 —— 230种空间群晶体结构模型全在这里
Computer software: recommend a disk space analysis tool - WizTree
Provide 和 Inject 的用法
Error ER_NOT_SUPPORTED_AUTH_MODE Client does not support authentication protocol requested by serv
53个全球免费学术资源数据库整理,查资料写论文必备【开学必备】
unity webgl报 Uncaught SyntaxError: JSON.parse: unexpected character at line 1 column 1 of the JSON
类图规范总结
七夕送礼,心愿直抵!
MMDeploy部署实战系列【第三章】:MMdeploy pytorch模型转换onnx,tensorrt
unity 循环选择器
GRNN、RBF、PNN、KELM之间究竟有什么联系?
SQL去重的三种方法汇总
Transform 相对位置变换,坐标系转换
Error EPERM operation not permitted, mkdir ‘Dsoftwarenodejsnode_cache_cacach两种解决办法
自适应迁移学习核极限学习机用于预测
Software: Recommend a domestic and very easy-to-use efficiency software uTools to everyone
舍不得花钱买1stOpt,不妨试试这款免费的拟合优化神器【openLU】
likeshop单商户高级版企业源码发布了新的版本1.8.1