logoalt Hacker News

zsergetoday at 1:48 PM1 replyview on HN

Not in a general mathematical sense, of course. Rather carthesian tensors. Seems like for most libraries it's `numpy.ndarray`: https://docs.tinygrad.org/tensor/ or https://docs.pytorch.org/docs/main/tensors.html


Replies

sreantoday at 1:54 PM

To add to the confusion, Mathematicians and Physicists often disagree on what that word means. A Physicist's tensor is often a mathematicians tensor field.

An appropriate tensor can certainly be represented by a multidimensional array but not all multidimensional arrays are tensors. It depends on how that multidimensional array participates with others.

For example, (lat, long) is not a 2d vector although it can be represented as a 2 dimensional array.