Cytnx-dev / Cytnx

Project Cytnx, A Cross-section of Python & C++,Tensor network library
Apache License 2.0
35 stars 13 forks source link

permute_ and reshape_ return none #380

Open hunghaoti opened 10 months ago

hunghaoti commented 10 months ago

Function 'permute' and 'reshape' return None. For example:

A = cytnx.ones([2,3])
B = A.permute_(1,0)
print(B) #None
A = cytnx.UniTensor.ones([2,3])
B = A.permute_([1,0])
print(B) #None
pcchen commented 1 week ago

I think the in-place version returns None is proper?