Smooth l1 loss

(x,y)=L={l1,...,lN}T

With

ln={0.5(xnyn)2/beta,if |xnyn|<beta|xnyn|0.5beta,otherwise 

If reduction is not none, then:

(x,y)={mean(L),if reduction=`mean';sum(L),if reduction=`sum'.

等有机会 plot 一下。