Artificial intelligent assistant

代入時のカンマの意味 deep learning 2 < `W, = self.params` `W,` class MatMul: def __init__(self, W): self.params = [W] self.grads = [np.zeros_like(W)] self.x = None def forward(self, x): W, = self.params# out = np.dot(x, W) self.x = x return out def backward(self, dout): W, = self.params# dx = np.dot(dout, W.T) dW = np.dot(self.x.T, dout) self.grads[0][...] = dW return dx

():


(W,) = self.params


:


W = self.params[0]


↑(1)
():


a, b, c = 1, 2, 3

xcX3v84RxoQ-4GxG32940ukFUIEgYdPy bc170b567d4f743981a2fe20dc328b6e