对于 \(n\) 维向量 \(\mathbf{x} = \begin{bmatrix} x_1 \\ x_2 \\ \vdots \\ x_n \end{bmatrix}\) 中的元素 \(x_i\),可以计算 softmax: