-
Notifications
You must be signed in to change notification settings - Fork 57
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
User/f1p/merge gex ddep #151
base: main
Are you sure you want to change the base?
Conversation
See his e-mail of July 15, 2022
Tag for 2022.04 release
Apparently the subroutine called "get_from_xgrid_land" in older versions of coupler/xgrid was renamed "get_from_xgrid_ug" in some update. In this commit few references to the old name that were left in by merge are fixed to use the new name.
Tag for 2024.01 version 1 of FMScoupler
…e why this would be needed
Just want to note that this will need NOAA-GFDL/FMS#1637 merged in first before the CI will pass, since this depends on the added module. @fabienpaulot This will need some line length and trailing whitespace clean up to pass the linter before we can merge it. The linter output is here but you can also find it in the checks tab, it'll tell you which files need to have overly long lines or trailing whitespace fixed. |
Thanks,
is there a way to know which specific lines are causing the following
warnings:
Error: 2 file(s) contain(s) trailing whitespace
./full/full_coupler_mod.F90
./full/atm_land_ice_flux_exchange.F90
Error: 2 Fortran file(s) contain(s) lines longer than 121 characters
./full/flux_exchange.F90
./full/atm_land_ice_flux_exchange.F90
Thanks
…On Mon, Jan 27, 2025 at 4:37 PM Ryan Mulhall ***@***.***> wrote:
Just want to note that this will need NOAA-GFDL/FMS#1637
<NOAA-GFDL/FMS#1637> merged in first before the
CI will pass, since this depends on the added module.
@fabienpaulot <https://github.com/fabienpaulot> This will need some clean
up to pass the linter before we can merge it. The linter output is here
<https://github.com/NOAA-GFDL/FMScoupler/actions/runs/12997840249/job/36249675286?pr=151>
but you can also find it in the checks tab, it'll tell you which files need
to have overly long lines or trailing whitespace fixed.
—
Reply to this email directly, view it on GitHub
<#151 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AKAQA46OAKSMC2RW24YIWA32M2RI5AVCNFSM6AAAAABV66GWDSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDMMJWHE2DQNBSHE>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
@fabienpaulot The linter action only lets us know, but you can use grep to get an exact line number:
for trailing whitespace.
for line lengths |
Thanks for the tip!
…On Mon, Jan 27, 2025 at 5:04 PM Ryan Mulhall ***@***.***> wrote:
@fabienpaulot <https://github.com/fabienpaulot> The linter action only
lets us know, but you can use grep to get an exact line number:
grep -n " $" <filenames>
for trailing whitespace.
grep -n '.\{120\}' <filenames>
for line lengths
—
Reply to this email directly, view it on GitHub
<#151 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AKAQA46GLPE4IVSWON5FN3L2M2UO5AVCNFSM6AAAAABV66GWDSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDMMJWHE4TGMZSGI>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
This will need NOAA-GFDL/atmos_drivers#49 (comment) before this can be merged |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please make sure that all of the variables you add are documented using doxygen. I realize that there are hundreds of undocumented variables, but we request new variables are documented appropriately
full/atm_land_ice_flux_exchange.F90
Outdated
PI, CP_OCEAN, WTMCO2, WTMC, EPSLN, GRAV | ||
PI, CP_OCEAN, WTMCO2, WTMC, EPSLN, GRAV, WTMH2O | ||
|
||
!gex |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The comment should be removed or expanded. It doesn't provide any useful information.
full/atm_land_ice_flux_exchange.F90
Outdated
!map atm tracers to exchange, ice and land variables | ||
type(tracer_exch_ind_type), allocatable :: tr_table_map(:) | ||
!index of tracers in the array of tracers passed through flux exchange (tr_table) | ||
integer :: isphum = NO_TRACER !< specific humidity | ||
integer :: ico2 = NO_TRACER !< co2 tracer | ||
integer :: inh3 = NO_TRACER !< nh3 tracer |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please make sure all documentation is in doxygen format.
full/atm_land_ice_flux_exchange.F90
Outdated
@@ -302,6 +318,7 @@ subroutine atm_land_ice_flux_exchange_init(Time, Atm, Land, Ice, atmos_ice_bound | |||
real, intent(in) :: z_ref_heat_in, z_ref_mom_in | |||
logical, intent(in) :: scale_precip_2d_in | |||
logical, intent(in) :: do_area_weighted_flux_in | |||
logical, intent(in) :: ocn_atm_flux_vmr_bug_in |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please document in doxygen format
@@ -566,10 +566,12 @@ module flux_exchange_mod | |||
!! tfreeze parameter | |||
real, parameter :: tfreeze = 273.15 | |||
logical :: scale_precip_2d = .false. | |||
logical :: ocn_atm_flux_vmr_bug = .true. !set to .true. to reproduce old (erroneous) conversion |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please use doxygen format
full/atm_land_ice_flux_exchange.F90
Outdated
real :: rho | ||
real, dimension(n_xgrid_sfc,n_exch_tr) :: ex_tr_atm, ex_tr_ref |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please document these new variables in doxygen format
full/atm_land_ice_flux_exchange.F90
Outdated
!deposition velocity at reference height and atmospheric height | ||
real, allocatable, dimension(:,:) :: ex_tr_con_ref, ex_tr_con_atm |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please switch the documentation to doxygen format. The variables below show an example of the format using !<
for each variable.
full/atm_land_ice_flux_exchange.F90
Outdated
real, parameter :: tfreeze = 273.15 | ||
real, allocatable, dimension(:,:) :: frac_precip | ||
|
||
!--- the following is from flux_exchange_nml | ||
real :: z_ref_heat = 2. !< Reference height (meters) for temperature and relative humidity diagnostics | ||
!! (t_ref, rh_ref, del_h, del_q) | ||
real :: z_ref_mom = 10. !< Reference height (meters) for mementum diagnostics (u_ref, v_ref, del_m) | ||
logical :: ocn_atm_flux_vmr_bug |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please document this variable using a doxygen-format comment
full/atm_land_ice_flux_exchange.F90
Outdated
integer, allocatable :: id_tr_con_atm_land(:), id_tr_con_ref_land(:) | ||
integer, allocatable :: id_tr_con_atm(:), id_tr_con_ref(:) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add doxygen-style documentation for new variables
@thomas-robinson
I think I fixed all instances. Let me know if there are remaining issues.
Fabien
…On Tue, Jan 28, 2025 at 8:44 AM Tom Robinson ***@***.***> wrote:
***@***.**** requested changes on this pull request.
Please make sure that *all* of the variables you add are documented using
doxygen. I realize that there are hundreds of undocumented variables, but
we request new variables are documented appropriately
------------------------------
In full/atm_land_ice_flux_exchange.F90
<#151 (comment)>:
> @@ -72,7 +72,10 @@ module atm_land_ice_flux_exchange_mod
!! FMS
use FMS
use FMSconstants, only: rdgas, rvgas, cp_air, stefan, WTMAIR, HLV, HLF, Radius, &
- PI, CP_OCEAN, WTMCO2, WTMC, EPSLN, GRAV
+ PI, CP_OCEAN, WTMCO2, WTMC, EPSLN, GRAV, WTMH2O
+
+!gex
The comment should be removed or expanded. It doesn't provide any useful
information.
------------------------------
In full/atm_land_ice_flux_exchange.F90
<#151 (comment)>:
> + !map atm tracers to exchange, ice and land variables
+ type(tracer_exch_ind_type), allocatable :: tr_table_map(:)
+ !index of tracers in the array of tracers passed through flux exchange (tr_table)
+ integer :: isphum = NO_TRACER !< specific humidity
+ integer :: ico2 = NO_TRACER !< co2 tracer
+ integer :: inh3 = NO_TRACER !< nh3 tracer
Please make sure all documentation is in doxygen format.
------------------------------
In full/atm_land_ice_flux_exchange.F90
<#151 (comment)>:
> @@ -302,6 +318,7 @@ subroutine atm_land_ice_flux_exchange_init(Time, Atm, Land, Ice, atmos_ice_bound
real, intent(in) :: z_ref_heat_in, z_ref_mom_in
logical, intent(in) :: scale_precip_2d_in
logical, intent(in) :: do_area_weighted_flux_in
+ logical, intent(in) :: ocn_atm_flux_vmr_bug_in
Please document in doxygen format
------------------------------
In full/flux_exchange.F90
<#151 (comment)>:
> @@ -566,10 +566,12 @@ module flux_exchange_mod
!! tfreeze parameter
real, parameter :: tfreeze = 273.15
logical :: scale_precip_2d = .false.
+ logical :: ocn_atm_flux_vmr_bug = .true. !set to .true. to reproduce old (erroneous) conversion
Please use doxygen format
------------------------------
In full/atm_land_ice_flux_exchange.F90
<#151 (comment)>:
> + real :: rho
+ real, dimension(n_xgrid_sfc,n_exch_tr) :: ex_tr_atm, ex_tr_ref
Please document these new variables in doxygen format
------------------------------
In full/atm_land_ice_flux_exchange.F90
<#151 (comment)>:
> + !deposition velocity at reference height and atmospheric height
+ real, allocatable, dimension(:,:) :: ex_tr_con_ref, ex_tr_con_atm
Please switch the documentation to doxygen format. The variables below
show an example of the format using !< for each variable.
------------------------------
In full/atm_land_ice_flux_exchange.F90
<#151 (comment)>:
> real, parameter :: tfreeze = 273.15
real, allocatable, dimension(:,:) :: frac_precip
!--- the following is from flux_exchange_nml
real :: z_ref_heat = 2. !< Reference height (meters) for temperature and relative humidity diagnostics
!! (t_ref, rh_ref, del_h, del_q)
real :: z_ref_mom = 10. !< Reference height (meters) for mementum diagnostics (u_ref, v_ref, del_m)
+ logical :: ocn_atm_flux_vmr_bug
Please document this variable using a doxygen-format comment
------------------------------
In full/atm_land_ice_flux_exchange.F90
<#151 (comment)>:
> + integer, allocatable :: id_tr_con_atm_land(:), id_tr_con_ref_land(:)
+ integer, allocatable :: id_tr_con_atm(:), id_tr_con_ref(:)
Please add doxygen-style documentation for new variables
—
Reply to this email directly, view it on GitHub
<#151 (review)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AKAQA43TJ5ZUHHDC37PUZJL2M6CVHAVCNFSM6AAAAABV66GWDSVHI2DSMVQWIX3LMV43YUDVNRWFEZLROVSXG5CSMV3GSZLXHMZDKNZYGE4DENZQGQ>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
@fabienpaulot it looks like there are some issues with line length still |
Thanks @thomas-robinson for bearing with me. It looks like I finally passed the linter check. For my reference, here are the two functions I needed to use: grep '[[:space:]]$' -n FILENAME |
Modifications to:
a) handle dry deposition on land side
b) fix error in ocean flux diagnostics for vmr tracers (NH3 only in ESM4p5)
c) pass fluxes (not prognostic tracers) between land and atmosphere (gex)
Depends on esm4.5_ddep_gex tag (FMS, atmos_drivers)