I have a matrix A of dim(3,3) . Using torch.block_diag(A,A,…A) I can create a block diagonal which has 200 blocks of A on the diagonals but this code is very inefficient as I have to carefully type A 200 times . Please can I know if there is an efficient way to achieve this?