Torch.sparse to find inverse of a block-diagonal matrix?

Hey guys, so I am trying to find the inverse of a block diagonal matrix, namely, torch.inv

The issue is that, invert a large block diagonal matrix is not memory and computational efficient if inverting as an ordinary matrix…

So the right idea is to invert each diagonal block and put it back. Can torch.sparse do it? Does it have a future plan to implement this?

p.s. my block diagonal has each block of different size, so reshape and invert is not the right way to do it