(rontolisp) docs
← Functions

torch:data

(torch:data tensor)

Returns the tensor's data: a linalg array (packed float, any rank), or a number for a scalar tensor. This is the raw array the linalg functions accept, so a value leaves the differentiable layer through this reader (use torch:detach to stay a tensor while leaving the tape).