Extending tensor class to integrate a simple attribute/function

I am trying to extend the tensor class, as a simple toy experiment to understand basics of the pytorch, to have a new function “say()”, which will only print the contents of the tensor or a related info. Of course, just calling repr would do a similar behaviour, however I am trying the extend the class.
If the tensor class were a common python class, which has an init function, then the following might have worked:
def new_tensor(torch.Tensor):
init(self, an_array):
def say(self):
a desired usage would be:
a = new_tensor([0, 1, 3])
a.say() // prints tensor([0.0000, 1.0000, 3.0000])
How can we extend the tensor class?