Skip to content

Commit

Permalink
IrrepsData.ndim
Browse files Browse the repository at this point in the history
  • Loading branch information
mariogeiger committed Mar 26, 2022
1 parent 51e6a9b commit 29ea074
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions e3nn_jax/_irreps.py
Original file line number Diff line number Diff line change
Expand Up @@ -764,6 +764,10 @@ def __repr__(self):
def shape(self):
return self.contiguous.shape[:-1]

@property
def ndim(self):
return len(self.shape)

def reshape(self, shape) -> "IrrepsData":
list = [
None if x is None else x.reshape(shape + (mul, ir.dim))
Expand Down

0 comments on commit 29ea074

Please sign in to comment.