当前位置:网站首页>The difference between Tansig and logsig. Why does BP like to use Tansig
The difference between Tansig and logsig. Why does BP like to use Tansig
2022-07-07 01:30:00 【Old cake explanation BP neural network】
Original article , Reprint please indicate from 《 Old cake explains neural networks 》:bp.bbbdata.com
About 《 Old cake explains neural networks 》:
This website structurally explains the knowledge of Neural Networks , Principle and code .
repeat matlab Algorithm of neural network toolbox , It is a good assistant for learning neural networks .
Catalog
Why? BP Neural networks are generally used tansig, I believe this is the confusion of many people .
We might as well analyze tansig and logsig Properties of 、 characteristic 、 Derivative and so on ,
Try to find out why they tend to use tansig Why .
01. Formula analysis
The formula
tansig and logsig The formula is as follows :
analysis
From the formula of both , There is not much difference between the two ,
tansig It's just logsig Perform stretching and translation operation on the basis of .
Both rely on exponential calculations , There is no difference in computational complexity .
therefore , On the formula level , It does not constitute a tendentious choice tansig The reason of .
02. Characteristic analysis
characteristic
When tansig When the independent variable is one dimension , It's a S Shape curve .
● Its value range is (-1,1)
● tansig The nonlinear part mainly focuses on 【-1.7,1.7】 Between ,
● stay 【-1.7,1.7】 Outside ,tansig Gradually tend to saturation .When logsig When the independent variable is one dimension , It's a S Shape curve .
● Its value range is (0,1)
● logsig The nonlinear part mainly focuses on 【-1.7,1.7】 Between ,
● stay 【-1.7,1.7】 Outside ,logsig Gradually tend to saturation .
analysis
From the comparison of characteristics , We have not found any qualitative difference between the two ,
because tansig Will be logsig Stretch , Translation to 【-1,1】 The value range of .
I didn't find much difference in features ,
The only difference is , The two values are different .
03. Derivative Analysis
derivative
tansig The derivative of is :
logsig The derivative of is :
analysis
Through the comparison of derivatives ,
Both of them can use their own value to obtain the derivative value ,
The amount of calculation is also consistent ,
therefore , On derivative tansig There is no greater advantage ,
Does not constitute a tendency to use tansig Why
The author's view
Through the above analysis , We can hardly see tansig Than logsig What are the advantages of .
Then why use tansig Well ?
The author's view is ,
One 、 Unified input range .
Two 、 Make full use of the active interval of the activation function
We know , The input of the upper layer is the output of the lower layer ,
and tansig and logsig The active range of is 【-1.7,1.7】 Between ,
In the input layer , We will undoubtedly normalize the input to 【-1,1】,
It is more effective for using the active interval of the activation function of the first hidden layer .
And use tansig, In the case of multiple hidden layers ,
Output of each layer , That is, the input of the lower layer is still 【-1,1】
In this way, the input range of each layer is unified ,
And they all make effective use of the active interval of the activation function .
Unity is very beneficial ,
At least in theoretical research , It can bring a lot of convenience ,
Otherwise, we need to discuss the input layer and hidden layer respectively .
The above is the author's view , Because there is no literature research , For reference only .
边栏推荐
- Share a general compilation method of so dynamic library
- Your cache folder contains root-owned files, due to a bug in npm ERR! previous versions of npm which
- 搭建【Redis in CentOS7.x】
- 交叉验证如何防止过拟合
- 增加 pdf 标题浮窗
- Byte P7 professional level explanation: common tools and test methods for interface testing, Freeman
- [JS] obtain the N days before and after the current time or the n months before and after the current time (hour, minute, second, year, month, day)
- tansig和logsig的差异,为什么BP喜欢用tansig
- LeetCode:1175. Prime permutation
- Clickhouse fields are grouped and aggregated, and SQL is queried according to the granularity of any time period
猜你喜欢
How to manage distributed teams?
Lldp compatible CDP function configuration
tansig和logsig的差异,为什么BP喜欢用tansig
AI 从代码中自动生成注释文档
一起看看matlab工具箱内部是如何实现BP神经网络的
身体质量指数程序,入门写死的小程序项目
从底层结构开始学习FPGA----FIFO IP的定制与测试
Yunna | work order management software, work order management software app
Transplant DAC chip mcp4725 to nuc980
Asset security issues or constraints on the development of the encryption industry, risk control + compliance has become the key to breaking the platform
随机推荐
taro3.*中使用 dva 入门级别的哦
Case development of landlord fighting game
Force buckle 1037 Effective boomerang
What does security capability mean? What are the protection capabilities of different levels of ISO?
go-zero微服务实战系列(九、极致优化秒杀性能)
table表格设置圆角
云呐|工单管理办法,如何开展工单管理
7.6 simulation summary
Gnet: notes on the use of a lightweight and high-performance go network framework
编译命令行终端 swift
增加 pdf 标题浮窗
c语言—数组
Google released a security update to fix 0 days that have been used in chrome
【信号与系统】
树莓派/arm设备上安装火狐Firefox浏览器
NEON优化:关于交叉存取与反向交叉存取
Supersocket 1.6 creates a simple socket server with message length in the header
Go zero micro service practical series (IX. ultimate optimization of seckill performance)
系统休眠文件可以删除吗 系统休眠文件怎么删除
Dark horse notes - exception handling