当前位置:网站首页>Channel attention and spatial attention module
Channel attention and spatial attention module
2022-07-24 06:03:00 【aMythhhhh】
Channel attention module

The purpose of using the channel attention module : In order to make the input image more meaningful , The general understanding is , Calculate the input image through the network The importance of each channel ( The weight ), That is, pay more attention to which channels contain key information , Pay less attention to channels with little important information , So as to achieve Improve feature representation Purpose .
In short : Attention mechanism can correct the characteristics , The corrected features can retain valuable features , Eliminate worthless features .
Channel attention mechanism steps :
extrusion (Squeeze) The input image
Compress the spatial dimension of the input feature graph , This step can be done by Global average pooling (GAP) and Global maximum pooling (GMP)( The effect of global average pooling is relatively better than that of maximum pooling ), Through this step .HxWxC The input image is compressed into 1x1x``C Channel descriptor for . Enter the following formula as SxSxB Of feature map:

Compress the global spatial information into the channel descriptor , It not only reduces the network parameters , It can also prevent over fitting .excitation Channel descriptor
This step is mainly to send the channel descriptor obtained in the previous step to two fully connected networks , Get the attention weight matrix , Then multiply with the original image to obtain the calibrated attention feature map .

Spatial attention module

The purpose of using channel attention : Find the key information in map Where is the most , yes Supplement to channel attention , Simply speaking , Channel attention is to find out which channel has important information , Spatial attention is based on this , Based on the direction of the channel , find Which location The most information gathered .
Spatial attention steps :
Apply average pooling and maximum pooling operations along the channel axis , Then connect them to generate a valid feature descriptor .
Be careful : The pooling operation is carried out along the channel axis , That is, the values between different channels are compared during each pooling , Instead of values in different areas of the same channel .
The feature descriptor is sent into a convolution network for convolution , The final spatial attention feature map is obtained through the activation function .

say concretely , Use two pooling Operations are aggregated into one feature map Channel information , Generate two 2D chart : Fsavg The size is 1×H×W,Fsmax The size is 1×H×W.σ Express sigmoid function ,f7×7 Indicates that the size of a filter is 7×7 Convolution of .
Reference link :
(1)https://blog.csdn.net/u011984148/article/details/109475440
(2)https://zhuanlan.zhihu.com/p/334349672
(3)https://zhuanlan.zhihu.com/p/101590167
349672
(3)https://zhuanlan.zhihu.com/p/101590167
边栏推荐
- Statistical learning methods (2nd Edition) Li Hang Chapter 22 summary of unsupervised learning methods mind mapping notes
- [activiti] activiti system table description
- Typora installation package in November 2021, the last free version of the installation package to download v13.6.1
- tensorflow和pytorch框架的安装以及cuda踩坑记录
- OSError: [WinError 127] 找不到指定的程序。Error loading “caffe2_detectron_ops.dll“ or one of its dependencies
- Xshell远程访问工具
- Qt新建工程简介
- Thymeleaf快速入门学习
- 【FatFs】手动移植FatFs,将SRAM虚拟U盘
- Signals and systems: Hilbert transform
猜你喜欢

Common methods of array

Introduction to QT new project

Typora 安装包2021年11月最后一次免费版本的安装包下载V13.6.1

列表写入txt直接去除中间的逗号

AD1256

Positional argument after keyword argument

MySQL download and installation environment settings

Deepsort summary

Sequential stack C language stack entry and exit traversal

餐饮数据统计分析---泰迪云课程大作业
随机推荐
树莓派大用处,利用校园网搭建一个校园局域网站
String methods and instances
[USB host] stm32h7 cubemx porting USB host with FreeRTOS to read USB disk, usbh_ Process_ The OS is stuck. There is a value of 0xa5a5a5
找数组中出现次数最多的数
【深度学习】手写神经网络模型保存
解决ModularNotFoundError: No module named “cv2.aruco“
论文阅读-Endmember-Guided Unmixing Network (EGU-Net) 端元指导型高光谱解混网络
Qt char型转QString型 16进制与char型 转 16进制整型
HAL_Delay()延时误差约1ms的问题
世界坐标系、相机坐标系和图像坐标系的转换
在网络中添加spp模块中的注意点
Unicast, multicast, broadcast, tool development, introduction to QT UDP communication protocol development and source code of development tools
用指针访问一维数组
++cnt1[s1.charAt(i) - ‘a‘];
day-7 jvm完结
Qt 使用纯代码画图异常
JUC并发编程基础(6)--Lock锁
The detailed process of connecting MySQL with QT and outputting data to QT window tablewidget.
DeepSort 总结
餐饮数据统计分析---泰迪云课程大作业