CABLE-LSM / CABLE

Home to the CABLE land surface model and its documentation
https://cable.readthedocs.io/en/latest/
Other
8 stars 4 forks source link

Merge GW back into trunk #176

Open penguian opened 2 years ago

penguian commented 2 years ago

keyword_ground_water keyword_gw_maygit type_science enhancement | by srb001@csiro.au


Mengyuan has made many modifications that hopefully fix the ground water model originally implemented by Mark Decker.

The big problem here is that Meng's branch which includes these fixes last touched trunk @ 4213. In the interim there have been numerous branch-branch copies. It seems there have been many manual inclusions of trunk developments which of course svn does not know about.

Therefore, the only way to reliably proceed is to merge these fixes manually. In this case the fixes have to be isolated. Consultation with Meng on this issue would be invaluable.


Issue migrated from trac:324 at 2023-11-27 11:40:40 +1100

penguian commented 2 years ago

@jxs599@nci.org.au commented


Jhan picked this up in early Jan whilst cleaning up tickets. Jhan's TRAC branch representing this start is labelled as 306X because the ticket which which sparked this whole project was Meng's Ticket CABLE-LSM/CABLE-Trac-archive#306. Herein this branch is referred to as 306X and Meng's branch (from above) which includes other fixes as well is referred to as Meng's branch.

Ramzi@UNSW is slated to continue this work. What follows is a description of the steps already taken and those suggested. Attached is a zipped copy of my working copy of 306X from gadi, less .svn/ links as they pushed the attachment over size limit (306X_JhansWorkingCopyFeb3.tgz). So things like svn status will be active.

To over simplify the aim is to fill 306X with the changes in Meng's branch since the trunk@4213. However, this is complicated by the fact that some of those changes were changes properly implemented in the trunk in the interim 4213:8663. So we have to exclude these. To further complicate matters, sometimes these changes are implemented (on Meng's side) in different places and/or the code might look different as it was manually entered.

A further complication is that the directory and file structure has changed significantly in the interim 4213:8663.

From the revision logs, Changesets from my 306X branch you can see files which have already been evaluated and are more or less ready to push back to the trunk. It appears I have not yet finalised cable_input.F90. This is the file I was working on when another crisis occurred. As it stands you should overwrite that in 306X (or your own counter part) with Meng's and start reconciling this again. I generally use vimdiff to compare files. You can use whatever tools you prefer but this is available remotely and pretty much anywhere.

less the cable_input described above, svn status in 306X as it stands now, shows:

M offline/cable_iovars.F90 M offline/cable_mpicommon.F90 M offline/cable_mpidrv.F90 M offline/cable_mpimaster.F90 M offline/cable_mpiworker.F90 M offline/cable_namelist_input.F90 M offline/cable_output.F90 M offline/cable_parameters.F90 M offline/cable_pft_params.F90 M science/canopy/cable_canopy.F90 M science/casa-cnp/CASAONLY_LUC.F90 M science/casa-cnp/cable_iovars_CMIP6.F90 M science/casa-cnp/casa_cable.F90 M science/casa-cnp/casa_dimension.F90 M science/casa-cnp/casa_inout.F90 M science/casa-cnp/casa_param.F90 M science/casa-cnp/casa_phenology.F90 M science/casa-cnp/casa_variable.F90 M science/casa-cnp/spincasacnp.F90 M science/gw_hydro/cable_gw_hydro.F90 M science/gw_hydro/cable_psm.F90 M science/misc/cable_carbon.F90 M science/misc/cable_climate.F90 M science/pop/POP.F90 M science/pop/POPLUC.F90 ? science/radiation/cable_radiation.F90 M science/roughness/cable_roughness.F90 M science/sli/cable_sli_main.F90 M science/sli/cable_sli_solve.F90 M science/sli/cable_sli_utils.F90 ? science/soilsnow/cable_soilsnow.F90

Here I will try to describe what needs to be done in more detail. Meng's input will be helpful in all cases but I will specifically note where I think it will be most important. In general, Meng has had to make changes for GW and also the fixes she has made along the way. These are the parts we want. Not the fixes etc that are manually pulled in from the trunk. To muddy this we also want those same changes going back 5 years to 4213, before Meng's time. With luck, in some instances Meng might tell you she has never had anything to do with a certain file and so the "changes" can just be reverted. In some of these cases at least - you should find that said file is equivalent to 4213. It is rarely that neat however, and you will at least encounter the differences that have happened to that file along the path from the trunk until when Meng got it.

These files need to be reconciled.

M offline/cable_iovars.F90 M offline/cable_mpicommon.F90 M offline/cable_mpidrv.F90 M offline/cable_mpimaster.F90 M offline/cable_mpiworker.F90 M offline/cable_namelist_input.F90 M offline/cable_output.F90 M offline/cable_parameters.F90 M offline/cable_pft_params.F90

The version of casa in the trunk is different and has been verified more than once. I suspect though Meng has made some changes in here.

M science/casa-cnp/CASAONLY_LUC.F90 M science/casa-cnp/cable_iovars_CMIP6.F90 M science/casa-cnp/casa_cable.F90 M science/casa-cnp/casa_dimension.F90 M science/casa-cnp/casa_inout.F90 M science/casa-cnp/casa_param.F90 M science/casa-cnp/casa_phenology.F90 M science/casa-cnp/casa_variable.F90 M science/casa-cnp/spincasacnp.F90

So far as I know Meng (a nd maybe Anna ) is the only one who has changed these AND got them to work - so can just accept Meng's version M science/gw_hydro/cable_gw_hydro.F90 M science/gw_hydro/cable_psm.F90

So far as I know Meng hasn't touched these (check with her) is the only one who has changed these AND got them to work - so can just accept trunk@HEAD version. Caveat:Interim changes between 4213 and Meng's branch may exist BUT if you reconcile the code manually - you will likely find that these modifications are in the trunk.


M science/misc/cable_carbon.F90 M science/misc/cable_climate.F90

M science/pop/POP.F90 M science/pop/POPLUC.F90

M science/roughness/cable_roughness.F90

M science/sli/cable_sli_main.F90 M science/sli/cable_sli_solve.F90 M science/sli/cable_sli_utils.F90

I think Meng probably has made some changes in here.

M science/canopy/cable_canopy.F90

I am pretty sure Meng probably has made some changes in here. problem is that cable_soilsnow.F90 has been broken up into its constituent SUBROUTINES. i.e. previously 1 .F90 file contained 1 module which included X SUBR. Now broken up into X files/modules

? science/soilsnow/cable_soilsnow.F90

I don't think Meng has made any changes in here. problem is like cable_soilsnow.F90, this has also been broken up into its constituent SUBROUTINES. i.e. previously 1 .F90 file contained 1 module which included X SUBR. Now broken up into X files/modules

? science/radiation/cable_radiation.F90

Please feel free to ask any questions.

Jhan

penguian commented 2 years ago

@jxs599@nci.org.au changed _comment0 which not transferred by tractive

penguian commented 2 years ago

@jxs599@nci.org.au changed _comment1 which not transferred by tractive

penguian commented 2 years ago

@jxs599@nci.org.au changed _comment2 which not transferred by tractive

penguian commented 2 years ago

@jxs599@nci.org.au _uploaded file 306X_JhansWorkingCopyFeb3.tgz (15796.7 KiB)_

Jhan's WC from Gadi of 306X

penguian commented 1 year ago

@ccc561@nci.org.au changed keywords from ground water, gw to ground water, gw maygit