当前位置:网站首页>Lihongyi, machine learning 6 Convolutional neural network
Lihongyi, machine learning 6 Convolutional neural network
2022-06-25 02:36:00 【AXYZdong】
Author:AXYZdong
Li Hongyi 《 machine learning 》 series
Refer to the video address :https://www.bilibili.com/video/BV1Ht411g7Ef
Reference documents :DataWhale file
List of articles
One 、 Why? CNN For image processing
When we use fully connect feedforward network To do image processing , Often we need too many parameters , for instance , Suppose this is a 100 *100 The color chart ( A very small one imgage), You pull this into a vector,( How many of them are there pixel), It has 100 *100 3 Of pixel.
If it's a color chart , Every pixel Three are needed value To describe it , Namely 30000 dimension (30000 dimension), that input vector If so 30000dimension, So this one hidden layer The assumption is 1000 individual neural, So this hidden layer The parameter of the is 30000 *1000, That would be too much .
that CNN What you do is simplify neural network The architecture of . Based on our understanding of images , some weight It doesn't work , We filtered it out from the beginning . Not with fully connect feedforward network, It uses fewer parameters to do image processing . therefore CNN More than average DNN And simple .

CNN Just use power-knowledge Go get the original fully connect layer Remove some parameters from the .
Why is it possible for us to remove some parameters ( Why can image processing be performed with fewer parameters )
- Some feature images are much smaller than the whole image

- The same features will appear in different areas

- Pixel scaling does not affect the image much

Two 、CNN framework
First input a sheet image, This piece of image Will pass convolution layer, Next is max pooling, And then do it convolution, Do it again max pooling.
The above process can be repeated countless times ( How many times you have to decide in advance , It is network The architecture of ( It's like neural There are several layers ), How many layers should be made convolution, Make several layers Max Pooling, Ding Ding neural When it comes to architecture , It must be decided in advance ).
Finish what you want to do convolution and Max Pooling in the future , It's going to be flatten, And then flatten Of output Throw it to the general fully connected feedforward network, Then get the result of image recognition .

3、 ... and 、 Convolution (Convolution)
first filter It's a 3* 3 Of matrix, Put this filter Put it in image Top left corner of , hold filter Of 9 Value and image Of 9 Inner product of two values , On both sides 1,1,1( Diagonally ), The result of inner product is 3.
( How much to move is predetermined ) The distance of movement is called stride(stride The value of can also be set in advance ), The inner product is equal to -1. In the picture stride be equal to 1.


Four 、Convolution and Fully Connected The relationship between
take stride=1( Move one space ) Do the inner product to get another value -1, Suppose this -1 It's another one neural Of output, This neural Connect to input Of (2,3,4,8,9,10,14,15,16), alike weight Represents the same color .
stay fully connect Two of them neural I had my own weight, When we are doing convolution when , First, put each neural Connected wight Reduce , Force these two neural Share one weight. This is called shared weight, When we do this , This parameter we use is less than the original one .

5、 ... and 、 Maximum pooling (Max Pooling)
be relative to convolution Come on ,Max Pooling It's relatively simple . We according to the filter 1 obtain 4*4 Of maxtrix, according to filter2 Get another 4 *4 Of matrix, Next, put output ,4 In groups . The average of each group can be selected ( The average pooling ) Or choose the largest ( Maximum pooling ) All of them can , Is to put four value Synthesis of a value. This can make image narrow .
The essential function of pooling is : Zoom out the image , Reduce features .


6、 ... and 、 Flatten (Flatten)
Turn multidimensional input into one dimension , It is often used in the transition from convolution layer to fully connected layer .
flatten Namely feature map straighten , After straightening, you can throw it to fully connected feedforward netwwork.

7、 ... and 、To learn more …
- The methods of visualization in these slides
https://blog.keras.io/how-convolutional-neural-networks-see-the-world.html - More about visualization
http://cs231n.github.io/understanding-cnn/ - Very cool CNN visualization toolkit
http://yosinski.com/deepvis
http://scs.ryerson.ca/~aharley/vis/conv/
How to let machine draw an image
- PixelRNN:https://arxiv.org/abs/1601.06759
- Variation Autoencoder (VAE): https://arxiv.org/abs/1312.6114
- Generative Adversarial Network (GAN): http://arxiv.org/abs/1406.2661
8、 ... and 、 summary
Datawhale Team learning , Li Hongyi 《 machine learning 》Task6. Convolutional Neural Network( Convolutional neural networks ). Including why CNN For image processing 、CNN framework 、 Convolution (Convolution)、Convolution and Fully Connected The relationship between 、 Maximum pooling (Max Pooling)、 Flatten (Flatten) And other references .
It mainly introduces the principle part , In practice, one line of code may realize the corresponding functions . For beginners , I think there are many places that can be understood , Wait until the specific application time to dig deeper , This can improve efficiency .
If any of the above is inaccurate , Welcome below Leaving a message. . Or you have a better idea , Welcome to exchange and study together ~~~
For more, please go to AXYZdong The blog of
边栏推荐
- When an interface has an exception, how do you analyze the exception?
- Planification du réseau | [quatre couches de réseau] points de connaissance et exemples
- Can automate - 10k, can automate - 20K, do you understand automated testing?
- 計網 | 【四 網絡層】知識點及例題
- Network planning | [four network layers] knowledge points and examples
- It is said that Yijia will soon update the product line of TWS earplugs, smart watches and bracelets
- What is the reason for the disconnection of video playback due to the EHOME protocol access of easycvr platform?
- yarn : 无法加载文件 C:\Users\xxx\AppData\Roaming\npm\yarn.ps1,因为在此系统上禁止运行脚本
- MySQL command backup
- File system - basic knowledge of disk and detailed introduction to FAT32 file system
猜你喜欢

【STL源码剖析】配置器(待补充)

qt打包exe文件,解决“无法定位程序输入点_ZdaPvj于动态链接库Qt5Cored.dll”

1-6搭建Win7虚拟机环境

探索C语言程序奥秘——C语言程序编译与预处理

How to monitor the log through the easycvr interface to observe the platform streaming?

【直播回顾】战码先锋第七期:三方应用开发者如何为开源做贡献

Folding screen will become an important weapon for domestic mobile phones to share the apple market

文件系统 -- 磁盘基础知识和FAT32文件系统详细介绍

Processon producer process (customized)

业务与技术双向结合构建银行数据安全管理体系
随机推荐
Uncaught Error: [About] is not a <Route> component. All component children of <Routes> must be a <Ro
当人们用互联网式的思维和视角来看待产业互联网的时候,其实已陷入到了死胡同
Dirvish Chinese document of vim
把 Oracle 数据库从 Windows 系统迁移到 Linux Oracle Rac 集群环境(1)——迁移数据到节点1
Summary of knowledge points of computer level III (database) test preparation topics
Internship: use of SVN
What are the reasons for the abnormal playback of the online channel of the channel accessed by easycvr national standard protocol?
Intranet learning notes (7)
Talking about the advantages of flying book in development work | community essay solicitation
internship:svn的使用
Use of hashcat
psql 列转行
算力服务网络:一场多元融合的系统革命
Left hand dreams right hand responsibilities GAC Honda not only pays attention to sales but also children's safety
|遇到bug怎么分析,专业总结分析来了
Summary of stack frame in arm assembly
ACL access control of squid proxy server
Smartctl opens the device and encounters permission denied problem troubleshooting process record
yarn : 无法加载文件 C:\Users\xxx\AppData\Roaming\npm\yarn.ps1,因为在此系统上禁止运行脚本
Lizuofan, co-founder of nonconvex: Taking quantification as his lifelong career