Forward and reverse models compile and run#4
Forward and reverse models compile and run#4TerribleNews wants to merge 5 commits intogeoschem:gchp/devfrom
Conversation
|
I am unable to view the logs from the automated tests. Is there a way to trigger them to run again? Is that what is holding up this part of the PR set? |
|
You can ignore those as they are GMAO tests. I removed the relevant .github files in a recent commit to prevent them from being triggered. That is in the |
|
Are you planning on submitting these updates to GMAO to include in a future MAPL version? We are trying to keep our MAPL as close as possible to the upstream, and clearly mark anything that differs with comments that it is for GCHP. This helps with merge conflicts in the future during MAPL version updates. |
|
I've merged in all your CO2/adjoint PRs except for this one. My preference is for you to make a PR for these updates at https://github.com/GEOS-ESM/MAPL, and update this one to wrap all changes in ADJOINT ifdefs. This would make it very clear what has been added for the adjoint and ensure deactivation for the forward model. I'd the defer to GMAO on what they want to include in an official MAPL release that we would merge into our fork later. Does this sound okay? |
|
I'm not sure I follow completely. Are you proposing ditching this PR and me submitting a PR to GMAO and then these changes come into the geoschem/MAPL repo once they've been accepted at GMAO? Or are you proposing I basically make duplicate PRs here and at GMAO? |
| IF (FILENAME(1:1) == '-' .or. FILENAME(1:1) == '+') THEN | ||
| call MAPL_ESMFStateWriteToFile(STATE%INTERNAL,CLOCK,FILENAME(2:), & | ||
| FILETYPE, STATE, hdr/=0, oClients = o_Clients, RC=STATUS) | ||
| else | ||
| call MAPL_ESMFStateWriteToFile(STATE%INTERNAL,CLOCK,FILENAME, & | ||
| FILETYPE, STATE, hdr/=0, oClients = o_Clients, RC=STATUS) | ||
| endif |
There was a problem hiding this comment.
These and the subsequent changes are (I don't think) adjoint specific. I was having a lot of weird issues with files with + signs at the begining which was supposed to signify something to MAPL but it was trying to open them including the + and failing. I'm not sure if we've stopped using the + in files, but if so, I can remove these changes.
|
Right, it looks like most of the changes are not adjoint-specific. They may possibly affect GCHP as well and may or may not go in a direction GMAO agrees with. If you need these in the MAPL included in GCHP 13.1 within the next few weeks then I think the changes could still come in, but with ADJOINT ifdefs where functionality changes, and adjoint comments where it does not but the code is added purely for the adjoint. More generally I think a conversation about the changes should be in the GEOS-ESM space as a PR so the MAPL developers can comment and bring in to an official MAPL version. If they reject anything then we can discuss why and what to do about it. |
|
Yes, that is all fair. This will require some more thinking/testing/reworking on my end. All the MAPL stuff was pretty stickly. And as I mentioned in the original PR, I had to make a small change to the EMSF underlying c code (not the ESMA_cmake, but the source I downloaded for ESMF 8.0.0). I'll try to get back to you early next week. |
|
Okay, sounds good. I definitely recommend getting in touch with the ESMF developers as well if you had to change ESMF. I've contacted them about a few things and they were very responsive. They want their code to work for everyone. Now that we use ESMF externally we do not recommend custom updates. Heads up we just switched from MAPL v2.2.7 to v2.6.3. The new MAPL version is currently in branch |
|
Still working on this. Hope to have an update for you soon. |
I originally made an attempt at running the reverse integration by using a negative timestemp, but this required more code changes and more runtime configuration changes, so that was abandonned in favour of using the REVERSE_TIME resource. However, I didn't roll all those changes back when I changed strategies so there were a number of those code changes left hanging around. I have now removed them and confirmed that their removal does not impact the forward or reverse results.
|
Hi @lizziel while trying to put together a pull request for the GMAO team I found that there are some large differences in our version of |
|
Thanks for bringing this up. How about this for a plan:
Sound ok? |
|
Which branch should I be aiming for on As an aside, I have submitted the PR to I believe this PR is now the minimal set of changes to |
|
Sorry, I see that there are still conflicts but the "resolve conflicts" button next to them is greyed out for me. Are there a lot of them? Let me know if you want me to rebase my changes before you proceed. |
|
The conflicts are because two of the files moved. See my earlier comment about the update to MAPL v2.6. |
|
@TerribleNews, could you confirm this PR is now superceded by #12? |
|
Yes, this is superseded by #12 |
geoschem/GCHP#71
To get the model to run in reverse and appropriately output diagnostics, a number of changes had to be made the main run loop and the history clock and alarm system. I was also found what I believe to be a but in the ESMF C library code for alarms in reverse mode:
Description
Related Issue
Motivation and Context
How Has This Been Tested?
Types of changes
Checklist: