-
Notifications
You must be signed in to change notification settings - Fork 66
Multilinear operators #202
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
@kellertuer could you take a look if my approach to scalars for vector spaces makes sense? There may be some holes related to scalars of tangent spaces of complex manifolds. I'm also not sure if the relation to complex bases is clear enough (it's described in one of the docstrings). |
|
Can you point me to the code lines? I don't yet see through the new structure you are building here. |
|
Some code lines:
|
|
Looks fine to me and seems to be as generic as possible, which I like :) |
|
Now after some discussion in https://discourse.julialang.org/t/ann-tensoralgebra-jl-taking-covariance-seriously/43587 I'm starting to think that perhaps adding a number system argument to vector spaces wasn't a good idea. After all it can be deduced from a basis. |
|
You're right, it can be deduced from a basis. |
|
I've read some parts of the Absil's book and reevaluated (again) the plans here. It looks like the most important missing component are affine connections and that's what I've started working on in the last commit. I'm thinking about opening a separate PR with a narrower scope, with only affine connections and things that can be easily built on top of them, just like I did with gradients and differentials of curves. |
Codecov Report
@@ Coverage Diff @@
## master #202 +/- ##
==========================================
- Coverage 95.03% 94.45% -0.59%
==========================================
Files 63 62 -1
Lines 3744 3712 -32
==========================================
- Hits 3558 3506 -52
- Misses 186 206 +20
Continue to review full report at Codecov.
|
|
Could you also shortly check why Julia 1 is failing? It worked on my last commit before I merged to master but on master it failed; I think they might have introduced a rounding error in the complex case maybe? |
|
I've increased |
|
It seems that the GitHub action is broken, at least in my log file, the Julia v1 action loads Julia 1.5.0. |
|
That's weird. The CI file has 1.0 explicitly. I've added 1.5 and we'll see what happens. And it looks like I've been fixing the Grassmann problem wrong then. |
|
I think your approach was good, I also only noticed by chance, that the Julia 1.0 test was actually running 1.5 (and can't see why it does) |
|
I'll ask about it in the github-actions channel on Slack. And my approach was incorrect because I thought the failure is on 1.0, not 1.5... it's also on Windows so I've replaced the version check with system check. |
|
github-actions channel was very fast. Version 1.0 was parsed as 1 which is then converted to the latest stable version of Julia 1 😕 . Apparently we didn't have CI for Julia 1.0 for quite some time. |
|
Oh. I wasn't aware of that. Interesting. Well, let's hope 1.0 does not produce too many errors now. |
|
Maybe we should fix the 1.0 issue in a separate PR and for simplicity you disable it here, too? see #209. |
|
Thanks, good idea. |
|
I think this might help a lot, getting the Quasi newton more performant, as far as I see my student struggled there a little bit, will discuss with him this week. There is a branch but not yet a PR for (L-)BFGS in Manopt. |
|
What exactly is the problem this would help with? I stopped working on it because I didn't really have any applications that could guide the design. The other thing is that it's a very complex problem. I think it would be reasonable to first do some specific operators like cotangent vectors or maybe connections and then generalize it. By the way, do you currently have any form of ehess2rhess in Manopt.jl? Maybe that's what is needed? |
|
While we have a way to get from The problem we might have is, that we currently have two ways representing a hessian
That's why I am interested in an efficient way to do the Hessian :) |
Weingarten maps look like a reasonable solution. It's described here: https://link.springer.com/chapter/10.1007/978-3-642-40020-9_39 .
Well, I think the problem is that you don't really want to represent the Hessian itself, just calculate its values on tangent vectors. On (abstract) embedded manifolds you can just calculate Euclidean Hessian-vector product using an explicit formula or an AD tool like ReverseDiff.jl and then "Riemannize" it using a Weingarten map like in that link. I haven't thought about all the details here but I hope the general idea is clear enough. |
|
Yes, sure I want to store (as manopt does, too) the action on tangents, i.e. H maps a tangent to a tangent vector. Weingarten might be too complicated for that. And yes, your idea is clear. |
|
Why would Weingarten be too complicated for that? |
|
Sure, in general it is not, but maybe in special cases there are better options. |
|
I think there isn't anything particularly valuable in this PR and other approaches are generally more preferable. |
I've started some work to solve JuliaManifolds/ManifoldsBase.jl#45 . It's far from complete but the general idea is to have a
AbstractTensorFieldtype that represent arbitrary partial functions between vector bundles, which covers gradients, Hessians, metric fields, etc.TODO:
apply_operator.get_coordinates.apply_operator.get_coordinates.MetricManifold.Do we consider complex vector bundles on real manifolds and similar mixed scalar field cases? ProbablyVectorSpaceTypeshould hold the scalar field over which the vector space is over.Stretch goals:
VSInandVSOut. Includes extendingsharpandflat.get_coordinatesfor operators. Takes bases of both in and out space. How would tangent space bases relate to this? I'm not sure yet.get_coordinates.get_coordinates.get_vectoranalogue makes sense for these (even if it does I would call it out-of-scope for this issue).apply_operator.apply_operator.