Cytnx icon indicating copy to clipboard operation
Cytnx copied to clipboard

Attribute or method?

Open pcchen opened this issue 2 years ago • 0 comments

I wonder if we have a convention to use attribute or method (when both are possible). For example, in numpy one uses array.shape, while for UniTensor one uses UniTensor.shape(). Other examples in Cytnx, we use UniTensor.at([2]).value and we use UniTensor.[2].item(). I wonder is there a way to know if () needed in the end.

pcchen avatar Dec 02 '23 06:12 pcchen