Imposing constraints on all (numbered) diagonals in CVXPY
I am looking to implement a constraint on an optimization on all diagonals of a matrix using CVXPY. The diag function in CVXPY only returns the main diagonal. Is there a simple way to implement the numbered diagonal function in numpy using a CVXPY variable, in order to iterate over all diagonals adding a constraint for each?