在神經(jīng)網(wǎng)絡(luò)中偏置輸入的作用

轉(zhuǎn)載:https://stackoverflow.com/questions/2480650/role-of-bias-in-neural-networks

I think that biases are almost always helpful. In effect,a bias value allows you to shift the activation function to the left or right, which may be critical for successful learning.

It might help to look at a simple example. Consider this 1-input, 1-output network that has no bias:

The output of the network is computed by multiplying the input (x) by the weight (w0) and passing the result through some kind of activation function (e.g. a sigmoid function.)

Here is the function that this network computes, for various values of w0:

Changing the weight w0essentially changes the "steepness" of the sigmoid. That's useful, but what if you wanted the network to output 0 when x is 2? Just changing the steepness of the sigmoid won't really work --you want to be able to shift the entire curve to the right.

That's exactly what the bias allows you to do. If we add a bias to that network, like so:

...then the output of the network becomes sig(w0*x + w1*1.0). Here is what the output of the network looks like for various values of w1:

Having a weight of -5 for w1shifts the curve to the right, which allows us to have a network that outputs 0 when x is 2.

?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請(qǐng)聯(lián)系作者
【社區(qū)內(nèi)容提示】社區(qū)部分內(nèi)容疑似由AI輔助生成,瀏覽時(shí)請(qǐng)結(jié)合常識(shí)與多方信息審慎甄別。
平臺(tái)聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點(diǎn),簡(jiǎn)書系信息發(fā)布平臺(tái),僅提供信息存儲(chǔ)服務(wù)。

相關(guān)閱讀更多精彩內(nèi)容

  • rljs by sennchi Timeline of History Part One The Cognitiv...
    sennchi閱讀 7,847評(píng)論 0 10
  • 很享受運(yùn)動(dòng)后的大汗淋漓!任汗水在臉頰,發(fā)中,身體上肆虐橫行。汗水瞇了眼睛,澀的睜不開;汗水流到嘴角,咸的合不??;汗...
    那山那水那一片天閱讀 502評(píng)論 0 2
  • 又忘記了,是因?yàn)椴辉谝膺€是什么呢?
    Whser閱讀 310評(píng)論 0 0
  • 都說(shuō)高考是改變一個(gè)人生活地點(diǎn)的考試,去年的高考,讓我來(lái)到了"武城"-張家口。 經(jīng)歷3個(gè)多小時(shí)的火車,我來(lái)到長(zhǎng)得平平...
    西西里沒(méi)有里西西閱讀 300評(píng)論 0 0
  • 又到了春暖花開,在家呆不住要出門踏青閑逛的季節(jié)了。我這個(gè)非做飯小達(dá)人在中餐還沒(méi)有做得很好的情況下打算挑戰(zhàn)下高難度西...
    聞聽西辭閱讀 1,277評(píng)論 3 6

友情鏈接更多精彩內(nèi)容