You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Define a generic DiagonalArrays.diagonalarray constructor. For standard inputs, like diagonalarray(randn(2), (2, 2)), it will construct a DiagonalArrays.DiagonalArray, but for special kinds of axes like named axes it can construct a NamedDimsArrays.NamedDimsArray or ITensors.ITensor wrapping a DiagonalArray.
Analogous to DiagonalArrays.diagonal introduced in #4 as a generalization of LinearAlgebra.Diagonal.