问题描述
我正在写一些基本的神经网络方法 - 特别是激活函数 - 并且已经达到了我对数学的垃圾知识的极限。我明白各自的范围(-1/1)(0/1)等,但不同的描述和实现让我感到困惑。特别是 sigmoid em>, logistic , bipolar sigmoid , tanh 等。 em> sigmoid 只是描述函数的形状而不考虑范围?如果是这样,那么tanh是一个'sigmoid函数'?
在一篇论文中,我看到'bipolar sigmoid'与'tanh'相比较,但是我已经看到两个函数都实现了(在不同的库中)使用相同的代码:
((2 /(1 + Exp(-2 * n))) - 1)。他们是完全一样的东西吗?同样,我看到用相同的代码实现了 logistic 和 sigmoid 激活:
(1 /(1 + Exp(-1 * n)))。这些也是相同的吗?
最后,这在实践中有多重要?我在wiki上看到 - 可以使用这些函数吗?一些看起来像他们可能比其他人快得多。
Logistic函数:e /(e + e )逻辑函数的特殊(标准 /(1 + e )
双极sigmoid:从来没有听说过。
Tanh:(e -e )/(e + e )
Sigmoid通常指形状(和限制),所以是的,tanh是一个sigmoid函数。但在某些情况下,它特别指标准逻辑功能,所以你必须小心。是的,你可以使用任何sigmoid函数,并可能做得很好。
((2 /(1 + Exp(-2 * x))) - 1)是相当于tanh(x)。
I'm writing some basic neural network methods - specifically the activation functions - and have hit the limits of my rubbish knowledge of math. I understand the respective ranges (-1/1) (0/1) etc, but the varying descriptions and implementations have me confused.
Specifically sigmoid, logistic, bipolar sigmoid, tanh, etc.
Does sigmoid simply describe the shape of the function irrespective of range? If so, then is tanh a 'sigmoid function'?
I have seen 'bipolar sigmoid' compared against 'tanh' in a paper, however I have seen both functions implemented (in various libraries) with the same code:
(( 2/ (1 + Exp(-2 * n))) - 1). Are they exactly the same thing?
Likewise, I have seen logistic and sigmoid activations implemented with the same code:
( 1/ (1 + Exp(-1 * n))). Are these also equivalent?
Lastly, does it even matter that much in practise? I see on wiki a plot of very similar sigmoid functions - could any of these be used? Some look like they may be considerably faster to compute than others.
Logistic function: e/(e + e)
Special ("standard") case of the logistic function: 1/(1 + e)
Bipolar sigmoid: never heard of it.
Tanh: (e-e)/(e + e)
Sigmoid usually refers to the shape (and limits), so yes, tanh is a sigmoid function. But in some contexts it refers specifically to the standard logistic function, so you have to be careful. And yes, you could use any sigmoid function and probably do just fine.
(( 2/ (1 + Exp(-2 * x))) - 1) is equivalent to tanh(x).
这篇关于神经激活功能 - Logistic / Tanh /等的区别的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!