-
Notifications
You must be signed in to change notification settings - Fork 8
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
Adjoint handling #15
Comments
Thinking it further, some other "values" could be replaced by types: abstract type DiscreteOrContinuous end
struct Discrete <: DiscreteOrContinuous end
struct Continuous <: DiscreteOrContinuous end Now you could store the previous On a different note, why do you have the struct-constructors and then these smallcased, abbreviated functions like |
Thanks a lot for these valuable comments. I am about to release version v2.0 of ME announcing also the transition to LM. My last effort was to improve the performance of some of the basic solvers, so I ignored to check the issues. Sorry! (I wonder if it is any possibility to automatically get the notifications of new issues or PRs?) I think I need some time to evaluate the implications of your proposals and probably I will delay releasing v2.0 (it was planned for today, before my one week vacancy). Regarding the layer of functions like The handling of discrete/continuous issue as you propose, would probably have some implications at the level of basic solvers, which now have even different names (e.g., BTW: I was able to define for all my operators also the corresponding inverse operators, callable via the |
Regarding the |
I think you need to change the "watch" status at the top of the github page of ME.jl.
Not necessarily. You could simply dispatch on that value, let's say somefunction(::GeneralizedLyapunovMap{T,TA,TE,true}, args...; kwargs...) where {T,TA,TE}
# code that assumes
adj = true
end
somefunction(::GeneralizedLyapunovMap{T,TA,TE,false}, args...; kwargs...) where {T,TA,TE}
# code that assumes
adj = false
end This reduces the amount of branching, since branching would be done by multiple dispatch and not at runtime. |
Thanks for the hints. Since in the meantime I made some modifications (I think the operator part was not effected), I wonder how to handle the PRs which you suggested. Is it possible that some conflicts occur? |
Yes, there are some conflicts. I'll resolve them, but then it would be good to merge the PR and continue from there. 😅 |
Thanks. |
So, for the |
I mentioned that for some reason, after initially removing
When forming the inverse map with
The same applies for I also think |
I included that in my ongoing PR. |
I will not be able to perform any operation, probably until next Sunday (25.07.2021). I checked that similar changes of However, I am now receiving all notifications. |
No worries. Have a good vacation. |
I am back. I had a look to your changes. For me they are OK. Should I merge them? |
Did you try out some benchmarks? |
No. Actually I have no dedicated benchmarks for the operator functions. I intended to perform some tests after merging and pulling the new version to my local dev version. Or there is another way to make tests before merging? Sorry for my ignorance! |
No worries. If you use VS Code with the github extension, then you can simply "check out a PR". That will download my branch and add a git branch into your dev folder. You can then start a new Julia session and will run my branch, without committing or merging. |
I installed the Pull Request feature, which is a nice feature for cooperative developments! The two broken tests can be actually fixed with the new implementation of operators. The issue is that the real solvers exploit the real Schur form and work only for real right-hand side (no support for complex right-hand side). Therefore, for complex right-hand side, the Schur structure can be simply ignored and the general solvers can be used. |
I think I have troubles with the master repository. Erroneously I created a new branch andreasvarga/master which now contains your corrections and my last modifications (I fixed the broken tests). However, the automatic merging into master is apparently not possible and, to be honest, I have no idea what to do to get rid of this branch and integrate it in the master repository. Also locally things are now confused. I guess, my attempt to perform tests with your PR went wrong. I would appreciate very much your help in fixing these issues. |
Alright, so my PR is already merged into It could be that you have changed the remote repository to mine while checking out my branch. In VS Code you can simply choose the current branch in the lower left corner, I don't even use/know the command line commands for doing that. |
What about deleting everything locally and clone a new repository from the
current master?
Daniel Karrasch ***@***.***> schrieb am Mo., 26. Juli 2021,
20:26:
… Alright, so my PR is already merged into master, as well as your change
to the release notes. If your further changes are not too difficult, you
could delete the MatrixEquations folder in your local dev and then start
anew: dev MatrixEquations in pkg mode and off you go with creating new
branches, make the changes, open a PR, let CI run and merge if all is well.
It could be that you have changed the remote repository to mine while
checking out my branch. In VS Code you can simply choose the current branch
in the lower left corner, I don't even use/know the command line commands
for doing that.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#15 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ALJDHEAY5DX5TE3F5F2ZWILTZWSDRANCNFSM5AEFHO6A>
.
|
Exactly that's what's happening when you delete locally and |
Finally, I recovered the desired state and also fixed an initialization issue in I observed that I have a long list of branches on my
Excepting a few branches (e.g., Curiously, on the GitHub interface, I see only a part of these branches (more exacly only 2 branches, no one containing I would try to make a version bump. Since your modifications were substantial, I propose to make a bump to v2.1. Is this OK for you? |
Don't worry about the nightly issue. Julia triage is going to discuss whether the root cause should be reverted or the fix added. But in any case, v1.8 is not going to be released with this issue open. Concerning the many branches, you have now probably two remotes, As you noticed, I haven't turned the |
Indeed there are two remotes:
I removed some branches with
I still don't know how to get rid of some branches, which are not mines. I believe they somehow belong to the forked repository. Here is the current status as I am seeing from my local computer:
If you want you can close this issue, to which, the above discussion is not relevant. |
From what I understand, the
adj
field is typically computed from type information, likeisa(A, Adjoint)
and things like that. That means that the value ofadj
can be computed at compile time. Once the objects are generated, this type information is lost and only aBool
value is kept. This makes it unreachable for the compiler and in particular for multiple dispatch.I'd propose to consider to move the
adj
information into a type parameter, for instance like:You could then dispatch on types
::GeneralizedLyapunovMap{T,TA,TE,true}
and::GeneralizedLyapunovMap{T,TA,TE,false}
if needed. In this specific case, I don't even see why you would need that information, at least not in themeoperators
part. Anyway, I don't think it would lead to a major performance increase, but it could help clean up the code a little bit, i.e., have less branches.The text was updated successfully, but these errors were encountered: