File tree 1 file changed +34
-0
lines changed 1 file changed +34
-0
lines changed Original file line number Diff line number Diff line change
1
+ ---
2
+ layout : post
3
+ title : " Implement Batch Normalization"
4
+ subtitle : " 基于Eigen实现Batch Normalization-1"
5
+ date : 2017-04-13
6
+ author : " Jinquan"
7
+ header-img : " img/post-dynet-insight-bg.jpg"
8
+ tags :
9
+ - 深度学习
10
+ - 深度学习trick
11
+
12
+ ---
13
+
14
+ > 上一篇文章详细介绍了Batch Normalization的原理、涉及的数学公式,基于这些内容,我们可以实现一个简单的BN操作。但是在实际应用中,只是实现公式描述的BN是无法满足系统需求的。本文将以作者向dynet贡献BN源代码的经历,详细描述如何基于Eigen实现一个实用的Batch Normalization操作。
15
+
16
+ ### 文章结构
17
+
18
+ 1 . [ 滑动均值] ( #滑动均值 )
19
+ 2 . [ 滑动方差] ( #滑动方差 )
20
+ 3 . [ 实现代码] ( #实现代码 )
21
+
22
+ #### 滑动均值
23
+
24
+ 上一篇文章中讲到在训练过程中,BN操作是基于当前batch计算mean和variance的。在测试过程中,我们希望每个BN操作是基于整体数据的mean和variance,扫描所有数据求得mean和variance显然是不现实的,但是测试阶段又不能缺少这两个变量,那么该怎么办呢?
25
+
26
+ 实际上,金融领域已经采取了一些在线方法来计算流数据的mean和variance,这些在线方法得到的mean和variance被称作[ movind_average] ( https://en.wikipedia.org/wiki/Moving_average )
27
+
28
+ #### 滑动方差
29
+
30
+ 待补充
31
+
32
+ #### 实现代码
33
+
34
+ 待补充
You can’t perform that action at this time.
0 commit comments