Closed5

計算グラフ:スカラー積

nabeyangnabeyang
\begin{aligned} \left( \frac{\partial L}{\partial \bm{x}}\right)_{i,j} &= \sum_{l,m}\frac{\partial y_{l,m}}{\partial x_{i,j}} \frac{\partial L}{\partial y_{l,m}}\\ &= \sum_{l,m} a \delta_{i,l}\delta_{j,m} \frac{\partial L}{\partial y_{l,m}}\\ &= a \frac{\partial L}{\partial y_{i,j}}\\ &= a \left(\frac{\partial L}{\partial \bm{y}}\right)_{i,j} \end{aligned}
nabeyangnabeyang
\begin{aligned} \frac{\partial L}{\partial a} &= \sum_{i,j} \frac{\partial y_{i,j}}{\partial a} \frac{\partial L}{\partial y_{i,j}}\\ &= \frac{\partial}{\partial a} \left(ax_{i,j}\right) \frac{\partial L}{\partial y_{i,j}}\\ &= \sum_{i,j} x_{i,j} \frac{\partial L}{\partial y_{i,j}} \end{aligned}
このスクラップは2021/03/15にクローズされました