ndarray
autograd
loss
NDArray.
ndim
Returns the number of dimensions of this array
Examples
>>> x = mx.nd.array([1, 2, 3, 4]) >>> x.ndim 1 >>> x = mx.nd.array([[1, 2], [3, 4]]) >>> x.ndim 2