Support for the manifold of Hermitian Positive Definite (HPD) matrices (Julia)

65 views
Skip to first unread message

Santos Michelena

unread,
May 22, 2023, 10:01:33 AMMay 22
to Manopt
Hello,

I am currently dealing with a problem where I need to minimize a cost functional over the manifold of Hermitian Positive Definite matrices. However, Manifolds.jl currently only supports Symmetric Positive Definite matrices so I was wondering if there is any way I can work around this issue.

I tried setting up the problem over the manifold of Hermitian Positive Semi-Definite (HPSD) matrices but I cannot get automatic differentiation to work with it, which I do need. I can provide an extensive account of what I am attempting to do here if anyone's interested.

I am also thinking I could implement the HPD manifold myself. However, I am terribly inexperienced with differential geometry so some guidance on how to do this would be dearly appreciated. This implementation would have to allow for automatic differentiation of smooth functions defining over the manifold.

Best and thanks, Santos.

Ronny Bergmann

unread,
May 23, 2023, 10:24:11 AMMay 23
to Manopt
HI,
it might be easier to track your issue as a discussion at https://github.com/JuliaManifolds/Manifolds.jl/issues, since there are more Julia people hanging out than here.
However neither the complex case nor the semi-definite part are covered in Manifold.jl I think. Maybe you could also post some literature and we might be able to help to get that manifold implemented?

We can surely help you also with the AD part – if you want to have the gradient, we mainly would need the gradient conversion from Euclidean to Riemannian (change_representer) be implemented in Manifolds.jl, then you can use Euclidean AD tools.
We would – however – need some links/literature to that manifold to help you (and probably implement PSDs along the way as well), especially which metric you are using and such.

As soon as the manifold is implemented (we can discuss all functions you need, e.g. a retraction) you can use it with Manopt.jl for sure.

Best
Ronny

Santos Michelena

unread,
May 23, 2023, 11:17:51 AMMay 23
to Manopt
Hello,

Thanks for the reply.

Thanks for the suggestion, I will open an issue as soon as possible.

The semidefinite (+ fixed rank, so not exactly just semidefinite) case is actually covered in Manifolds.jl. See: https://docs.juliahub.com/Manifolds/H884l/0.4.2/manifolds/symmetricpsdfixedrank.html 
However, I believe this lacks an implementation of change_representer so I can't use euclidean AD tools and then convert to Riemannian, in fact, I can't get AD to work on this manifold with neither the intrinsic (targent space) approach nor the Riemannian projection approach.

As for literature, I found the following paper: https://arxiv.org/pdf/1312.1039.pdf here they solve a problem very similar to my problem and over the manifold I need to solve mine as well.  But as far as I can tell, this is just the manifold of SPD matrices but over the complex field. 

Best, Santos

Ronny Bergmann

unread,
May 23, 2023, 11:56:03 AMMay 23
to Manopt
Well, the SPDs are much nicer than the semi-definite case.

And ah, yes, sure, we have fixed rank – but that is different from general semi-definite (where all ranks are allowed).
If we are not aware of a change_representer formula, wo can not implement it – similarly for what you call intrinsic approach – I am not sure which projection you might miss, but if you could post example code that fails and the error message to you issue as. well, than we can check how much we can help (i.e. identify the functions that are missing, but then we still need ideas where to get formulae for these functions from ;))

Yes, complex SPDs are also not yet covered in Manifolds.jl as far as I can see. But maybe your link might help doing a few steps in that direction.

Best
Ronny

Santos Michelena

unread,
May 23, 2023, 1:16:23 PMMay 23
to Manopt
Hello again,

As for the code that gives me errors, please take a look at the following screenshot of my code:

Screenshot 2023-05-23 at 19.07.18.png

Here you can see how I am defining the backends and the gradient, as well as the error message I get, which I get when trying to call ∇f_11(M₁₁, testp)
Where M\_11 = M₁₁ = Manifolds.SymmetricPositiveSemidefiniteFixedRank(2, 2, Manifolds.ComplexNumbers())

As for the functions we need to implement the HPD manifold (and possibly also the HPSD manifold), I will dig into the literature and get back to you. I am VERY inexperienced with differential geometry so if you can suggest a general "search direction" for where to look I would really appreciate it. 
What I know for my particular problem is that I need to minimize a cost function f that takes an HPD matrix in its argument and that the solution should of course be an HPD matrix, additionally, I am using the Frobenius norm as a distance. I can of course provide more information on the problem if need be.

Thanks! Santos.

Ronny Bergmann

unread,
May 23, 2023, 3:08:32 PMMay 23
to Manopt
HI, I can not see the cell called that causes the error, but as far as I can see the error message the SPSdFR is missing an orthonormal basis function for their tangent spaces.
But again, opening an issue would be easier, since this is not Manopt/Manopt.jl related and (besides me) none of the Manifolds.jl-people is on this list.

Reply all
Reply to author
Forward
0 new messages