Softmax

Softmax

Softmax=exyey=exex+ey

Derivation of Softmax

Derivative w.r.t. x

f(x)=exex+eydf(x)dx=(ex+ey)ddxexexddx(ex+ey)(ex+ey)2=(ex+ey)exexex(ex+ey)2=ex(ex+ey)((ex+ey)(ex+ey)ex(ex+ey))=f(x)(1f(x))

Derivative w.r.t y

f(x)=exex+eydf(x)dy=(ex+ey)ddyexexddy(ex+ey)(ex+ey)2=(ex+ey)0exey(ex+ey)2=exex+ey.eyex+ey=f(x).f(y)

Related Notes