当前位置:网站首页>【2022新生学习】第三周要点
【2022新生学习】第三周要点
2022-07-29 04:59:00 【AI前沿理论组@OUC】
1、Batch Normalization
使用BN时需要注意的问题:
- 因为训练时会实时统计均值和方差,但是测试时要使用历史统计的值,不用当前的,所以要进行设置。在pytorch中可通过创建模型的model.train()和model.eval()方法控制。(类似的还有 Dropout)
- batch size尽可能设置大点,设置的越大求的均值和方差越接近整个数据集的真实分布。(但也要考虑你的硬件设备)
- 将BN层放在卷积层(Conv)和激活层(例如ReLU)之间,且卷积层不要使用偏置bias。
2、分组卷积

Group Convolution 是对输入feature map进行分组,然后每组分别卷积。如果分为G组,则参数量会降低为原来的 1/G。
速度提升: 理论上可以提高网络的速度,但实际上未必有3X3的卷积效率高,这是因为 pytorch 专门对 3X3 的卷积进行了优化,而分组卷积破坏了这种优化。
精度提升: 分组可以把特征变为若干子空间(subspace),对于图像信息有更加全面的了解。有些像Transformer 里的 Multi-Head Self-Attention,只不过 Transformer 里面是对注意力计算分组,起了个名字叫做“多头”,而组卷积里是对 convolution 分组。

Transformer来自于自然语言处理,在真实语言环境中,每一个词和不同的词,都有不同的关系。可以用不同的 Attention 来补充这些不同的关系。上图展示了三种 attention,即三个子空间,放在子空间里可以更好的学习这种关系。

AlexNet里也有一个经典的发现,上图中前三行是 GPU1 学习到的滤波器,后三行是GPU2学习到的滤波器。可以发现一个主要学习了纹理、梯度信息,另一个主要学习了色彩信息,可以理解为不同的子空间。
3、Res2Net

来自于南开大学程明明老师组的工作,特征分组+多尺度的完美结合。论文中有两个实验讨论了特征的分组。可以看出,随着尺度的提升,准确率会提升,速度会降低。而且,分组大于4的时候,相对于分组为4提升并不十分明显。所以,特征分组并不是越多越好,组数增加会增加计算消耗,需要一定的平衡。


边栏推荐
- 输入的查询SQL语句,是如何执行的?
- Operator operation list of spark
- 1 sentence of code, get asp Net core binds multiple sources to the same class
- Excel怎么筛选出自己想要的内容?excel表格筛选内容教程
- How to solve the problem of configuring the progress every time Office2010 is opened?
- Solution to the fourth game of 2022 Hangzhou Electric Multi school league
- Common rules of makefile (make) (II)
- Torch.nn.crossentropyloss() details
- 2021-11-02
- Introduction to auto.js script development
猜你喜欢

Download addresses of various versions of MySQL and multi version coexistence installation

excel怎么设置行高和列宽?excel设置行高和列宽的方法

1 sentence of code, get asp Net core binds multiple sources to the same class

2022杭电多校联赛第四场 题解

< El table column> place multiple pictures

How to make the characters in the photos laugh? HMS core video editing service one click smile function makes people smile more naturally

五个关联分析,领略数据分析师一大重要必会处理技能
![[untitled]](/img/6c/df2ebb3e39d1e47b8dd74cfdddbb06.gif)
[untitled]

力扣------对奇偶下标分别排序

Implementation of img responsive pictures (including the usage of srcset attribute and sizes attribute, and detailed explanation of device pixel ratio)
随机推荐
P5714 [deep foundation 3. Case 7] obesity
Sguard64.exe ace guard client exe: frequent disk reading and writing, game jamming, and Solutions
Connection database time zone setting
WPS如何进行快速截屏?WPS快速截屏的方法
Introduction of JDBC preparestatement+ database connection pool
Using jupyter (I), install jupyter under windows, open the browser, and modify the default opening address
Un7.28: common commands of redis client.
Implementation of flutter gesture monitoring and Sketchpad
输入的查询SQL语句,是如何执行的?
五个关联分析,领略数据分析师一大重要必会处理技能
金达威董秘回复:公司看好NMN产品的市场前景,已推出系列产品
Flutter 手势监听和画板实现
JS daily question (12)
带你一文理解JS数组
SparkSql批量插入或更新,保存数据到Mysql中
Reveal installation configuration debugging
def fasterrcnn_resnet50_fpn()实例测试
Sparksql inserts or updates in batches and saves data to MySQL
[untitled]
JS daily question (11)