Returns the size of a tensor.