当前位置:网站首页>Add se channel attention module to the network
Add se channel attention module to the network
2022-07-24 05:49:00 【Hehai CV chicken with vegetables】
First step : First, in the network structure py Add SELayer This class
class SELayer(nn.Module):
def __init__(self, channel, reduction=16):
super(SELayer, self).__init__()
self.avg_pool = nn.AdaptiveAvgPool2d(1)
self.fc = nn.Sequential(
nn.Linear(channel, channel // reduction, bias=False),
nn.ReLU(inplace=True),
nn.Linear(channel // reduction, channel, bias=False),
nn.Sigmoid()
)
def forward(self, x):
b, c, _, _ = x.size()
y = self.avg_pool(x).view(b, c)
y = self.fc(y).view(b, c, 1, 1)
return x * y.expand_as(x)The second step :

On the Internet body Class SE Module properties .
Be careful : This 75 Is the number to be modified , For example, I use it here yolov3, It uses voc Data sets , So this should be 3*(4+1+20)=75. If it is two categories, it should be changed to 3*(4+1+2)=21.
The third step :

At the end of the network output Place to use SE modular .
effect :


voc After the data set is used once map Promoted 0.86.


Own a very simple data set map Can also be improved .
边栏推荐
- Multi merchant mall system function disassembly lecture 06 - platform side merchant settlement agreement
- 使用bat命令快速创建系统还原点的方法
- 多商户商城系统功能拆解06讲-平台端商家入驻协议
- PLSQL query data garbled
- My little idea -- using MATLAB to realize reading similar to ring buffer
- Flink函数(1):rich function
- Canal+kafka actual combat (monitor MySQL binlog to realize data synchronization)
- 统计信号处理小作业——瑞利分布噪声中确定性直流信号的检测
- 达梦数据库_支持的表类型,用法,特性
- 【activiti】流程实例
猜你喜欢

Likeshop100%开源无加密-B2B2C多商户商城系统

【mycat】mycat配置文件

Canal+kafka实战(监听mysql binlog实现数据同步)

likeshop单商户商城系统搭建,代码开源无加密

Canal+kafka actual combat (monitor MySQL binlog to realize data synchronization)

《信号与系统》(吴京)部分课后习题答案与解析

推荐一款完全开源,功能丰富,界面精美的商城系统

【mycat】mycat搭建读写分离

The SaaS mall system of likeshop single merchant is built, and the code is open source without encryption.

《统计学习方法(第2版)》李航 第15章 奇异值分解 SVD 思维导图笔记 及 课后习题答案(步骤详细)SVD 矩阵奇异值 十五章
随机推荐
Two architectures of data integration: ELT and ETL
Canal+kafka actual combat (monitor MySQL binlog to realize data synchronization)
Introduction to PC mall module of e-commerce system
《统计学习方法(第2版)》李航 第15章 奇异值分解 SVD 思维导图笔记 及 课后习题答案(步骤详细)SVD 矩阵奇异值 十五章
多商户商城系统功能拆解07讲-平台端商品管理
Multi merchant mall system function disassembly lecture 08 - platform end commodity classification
Highcharts use custom vector maps
[vSphere high availability] virtual machine reset and restart
The way to attack the first poca hackson project "Manta network"
达梦数据库_常用初始化参数
国内外知名源码商城系统盘点
Detailed discussion on data synchronization tools ETL, ELT, reverse ETL
++cnt1[s1.charAt(i) - ‘a‘];
多商户商城系统功能拆解14讲-平台端会员等级
How to quickly connect CRM system and ERP system to realize the automatic flow of business processes
Brief introduction of [data mining] cluster analysis
Connect CRM system and effect advertising, help enterprises with precision marketing, and help enterprises with precision marketing
推荐一款完全开源,功能丰富,界面精美的商城系统
Unknown collation: ‘utf8mb4_ 0900_ ai_ Solution of CI '
Use streaming media to transfer RSTP to the Web terminal for playback (II) [review]