snow/sea ice shortwave radiative transfer harmonization#63
snow/sea ice shortwave radiative transfer harmonization#63akturner merged 176 commits intoMPAS-Dev:seaice/developfrom
Conversation
Added get_domain to testing system.
…se into cice/develop
This PR updates config flags/parameters and output biogeochemistry fields.
New namelist parameter, config_aggregate_halo_exch, to control use of aggregated halo exchanges Most halo exchanges now have option to be aggregated Removed multiple block test from test suite
… into cice/develop
Add bgc coupling namelist option
…ions' into cice/develop
Cleanup of a few namelist descriptions.
Added option for mpi_barriers before halo exchanges and timers around them Added new namelist option config_load_balance_timers
…develop Modify COMPASS scripts to be PEP8 compliant The four main scripts that drive the COMPASS testing infrastructure were written with tabs, long lines and many other coding conventions that are discouraged in python. This merge ensures that the scripts are compliant with the PEP8 specification, as determined by the automatic code analysis within the spyder editor. The following mode line (for vim) has been added to the bottom of each file: # vim: foldmethod=marker ai ts=4 sts=4 et sw=4 ft=python All empty except: clauses have been replaced with explicit exception names. Empty except clauses are considered a bad practice in python because (among other issues) even syntax errors in the code itself will be trapped by the except (a potential debugging nightmare). With one exception, the scripts are expected to function identically before and after this merge. Only formatting changes for PEP8 compliance have been performed. The exception is that support for the --verbose flag has been added to the cleanup phase of the manage_regression_suite.py script for consistency with the setup phase. Copying of the environment in subprocess calls has been removed, as this is the default behavior. Auto-generated scripts have been made PEP8 compliant to the extent possible. (The main PEP8 violations are that lines are often too long because of long strings that can not easily be broken into substrings.)
This fixes analysis members that currently write warnings on every call.
Added halo barriers after coupling and after halo exchange Added option to turn off halo exchanges
|
@akturner I removed the files you mentioned and snicar_optics_5bnd_snow_and_aerosols.nc, and updated namelist.seaice and streams.seaice under directory: testing_and_setup/seaice/configurations/standard_physics/ |
| config_calendar_type = 'gregorian_noleap' | ||
| config_start_time = '2000-01-01_00:00:00' | ||
| config_stop_time = 'none' | ||
| config_run_duration = '00-00-01_00:00:00' |
There was a problem hiding this comment.
Don't make unnecessary changes to pre-exisiting configurations.
There was a problem hiding this comment.
Okay, this change was made for model simulation. Revised
| config_AM_timeSeriesStatsCustom_reset_intervals = '00-00-07_00:00:00' | ||
| config_AM_timeSeriesStatsCustom_backward_output_offset = '00-00-01_00:00:00' | ||
| / | ||
| &snicar_variables |
There was a problem hiding this comment.
Put this in the "shortwave" namelist section
| config_AM_timeSeriesStatsCustom_backward_output_offset = '00-00-01_00:00:00' | ||
| / | ||
| &snicar_variables | ||
| config_turn_snicar_system_on = true |
There was a problem hiding this comment.
Rename this config_use_snicar
src/core_seaice/Registry.xml
Outdated
| possible_values="true or false" | ||
| /> | ||
| </nml_record> | ||
|
|
There was a problem hiding this comment.
Remove unnecessarly added blank line
src/core_seaice/Registry.xml
Outdated
| </var_struct> | ||
|
|
||
| <!-- Snicar 5-band optical property varables --> | ||
| <var_struct name="snicar_variables" time_levs="1" packages="pkgSnicarSystem"> |
There was a problem hiding this comment.
Rename pool "snicar" from "snicar_variables"
| pondLidMeltFluxFraction(:,iCell), & | ||
| .false., & | ||
| lInitialization) | ||
| lInitialization, & |
There was a problem hiding this comment.
Excess spaces - fix formatting
| call MPAS_pool_get_subpool(block % structs, "initial", initial) | ||
| call MPAS_pool_get_subpool(block % structs, "velocity_solver", velocity_solver) | ||
|
|
||
|
|
There was a problem hiding this comment.
Remove excess blank line
| call MPAS_pool_get_config(domain % configs, "config_scales_absorption_phaeocystis", config_scales_absorption_phaeocystis) | ||
| call MPAS_pool_get_config(domain % configs, "config_ratio_C_to_N_proteins", config_ratio_C_to_N_proteins) | ||
|
|
||
|
|
|
Adrian, thanks for checking the code. Modified files have been pushed. Please check if there are more changes need to be made. |
rewrote modified streams.seaice based off streams.seaice on master branch
akturner
left a comment
There was a problem hiding this comment.
Please pay attention to code formatting and ensure you keep indenting and general style the same as before.
| &shortwave | ||
| config_shortwave_type = 'dEdd' | ||
| config_albedo_type = 'ccsm3' | ||
| config_use_snicar = true |
There was a problem hiding this comment.
Why is this set to true?
| albedoIRDiffuseCategory, & | ||
| snowFractionCategory | ||
| snowFractionCategory,& | ||
| iceAsymmtryParameterDirect, & |
There was a problem hiding this comment.
Fix this formatting: extra spaces
| brineFraction, & | ||
| modalBCabsorptionParameter, & | ||
| bioTracerShortwave | ||
| bioTracerShortwave, & |
| ext_cff_mss_ice_dfs ! snow mass extinction cross section (m2/kg) | ||
|
|
||
| real (kind=dbl_kind), dimension(:,:), intent(in) :: & | ||
| kaer_tab_5bd, & ! aerosol mass extinction cross section (m2/kg) |
There was a problem hiding this comment.
Be consistent with indenting
|
|
||
| logical (kind=log_kind), intent(in) :: & | ||
| use_snicar ! if true, use 5-band snicar IOPs for | ||
| ! shortwave radiative calculation of |
| ext_cff_mss_ice_dfs ! snow mass extinction cross section (m2/kg) | ||
|
|
||
| real (kind=dbl_kind), dimension(:,:), intent(in) :: & | ||
| kaer_tab_5bd, & ! aerosol mass extinction cross section (m2/kg) |
There was a problem hiding this comment.
consistent indenting: keep original style
| srftyp = 1 | ||
| call compute_dEdd(nilyr, nslyr, klev, klevp, & | ||
|
|
||
| if (use_snicar) then ! use 5-band snicar IOPs for snow |
|
|
||
| if (use_snicar) then ! use 5-band snicar IOPs for snow | ||
|
|
||
| call compute_dEdd_5bd(nilyr, nslyr, klev, klevp, & |
| fswsfc, fswint, & | ||
| fswthru, Sswabs, & | ||
| Iswabs, fswpenl, & | ||
| asm_prm_ice_drc, asm_prm_ice_dfs, & |
akturner
left a comment
There was a problem hiding this comment.
Currently doesn't run the test case without failure
| call MPAS_pool_get_array(biogeochemistry, "verticalGrid", verticalGrid) | ||
|
|
||
| ! snicar 5-band snow IOPs | ||
| call MPAS_pool_get_array(snicar_variables, "iceAsymmtryParameterDirect",iceAsymmtryParameterDirect) |
| call MPAS_pool_get_array(snicar_variables, "aerosolSingleScatterAlbedo5band", aerosolSingleScatterAlbedo5band) | ||
| call MPAS_pool_get_array(snicar_variables,"aerosolAsymmetryParameter5band", aerosolAsymmetryParameter5band) | ||
| call MPAS_pool_get_array(snicar_variables, "modalMassExtinctionCrossSection5band", modalMassExtinctionCrossSection5band) | ||
| call MPAS_pool_get_array(snicar_variables,"modalSingleScatterAlbedo5band", modalSingleScatterAlbedo5band) |
| call MPAS_pool_get_array(snicar_variables, "iceMassExtinctionCrossSectionDiffuse", iceMassExtinctionCrossSectionDiffuse) | ||
| call MPAS_pool_get_array(snicar_variables, "aerosolMassExtinctionCrossSection5band", aerosolMassExtinctionCrossSection5band) | ||
| call MPAS_pool_get_array(snicar_variables, "aerosolSingleScatterAlbedo5band", aerosolSingleScatterAlbedo5band) | ||
| call MPAS_pool_get_array(snicar_variables,"aerosolAsymmetryParameter5band", aerosolAsymmetryParameter5band) |
|
|
||
| ! snicar 5-band snow IOPs | ||
| call MPAS_pool_get_array(snicar_variables, "iceAsymmtryParameterDirect",iceAsymmtryParameterDirect) | ||
| call MPAS_pool_get_array(snicar_variables, "iceAsymmtryParameterDiffuse",iceAsymmtryParameterDiffuse) |
|
@akturner Hi, Thanks for checking it. Could you please send me the error log of your test run? There are few things to note and I noticed when testing the current code:
which I will send to you via email shortly. This file contains the new input data for new features.
while in MPAS-seaice code .../core_seaice/Registry.xml, these files are still named as
So one would need to rename these files under run directory or change the source code for MPAS-seaice to read inputs.
|
| filename_interval="none" | ||
| input_interval="initial_only" /> | ||
|
|
||
| <immutable_stream name="StandardAerosolsInput" |
There was a problem hiding this comment.
Why have these been added here? This now creates errors for the basic tests that dont involve this functionality,
There was a problem hiding this comment.
Interesting. I added this because these were added in the stream.cice file you shared with me last year, which was probably used for a more advanced version of MPAS-seaice? I have never done any tests with these since I don't have any aerosol input data, neither did I modify the codes related to these. The stream file I used also contain these (per email I sent on Oct 23rd), and I am able to run MPAS-seaice model without errors.
Would you like me to remove these for this model merge? If so, there will be no aerosol optical properties inputs for the solar radiative transfer calculation.
There was a problem hiding this comment.
Yes, please remove these. Theyre not needed for the base physics simulation.
|
In answer to your questions above:
|
…streams file and namelist for snicar_shortwave test
|
Thanks! A directory (snicar_shortwave) with streams file and namelist is added to configurations for testing snicar related features. |
| filename_interval="none" | ||
| input_interval="initial_only" /> | ||
|
|
||
| <immutable_stream name="SnicarInput" |
There was a problem hiding this comment.
This isnt needed in this configuration. Please remove it.
|
Please add a README file to the snicar_shortwave configuration describing its unique features |
…hysics add README for configuration snicar_shortwave
|
README file is added to configuration snicar_shortwave |
|
Few more modifications:
The snicar streams file should read: <immutable_stream name="StandardAerosolsInput" <immutable_stream name="SnicarInput" |
|
Thanks Adrian. These are modified. |
|
|
||
| <immutable_stream name="SnicarInput" | ||
| type="input" | ||
| filename_template="forcing/snicar_optics_4bnd_snow_and_aerosols.nc" |
There was a problem hiding this comment.
Should not this be snicar_optics_5bnd_snow_and_aerosols.nc? Currently with the files I've been provided with this configuration fails because of this misnaming. Please test additions to PR.
There was a problem hiding this comment.
You're right. Thanks for catching this typo. It is fixed.
…PAS-Dev#63) function that will completely turn off transpiration at wilting point soil moisture instead of allowing a very small transpiration.
This merge adds an optional subroutine to the snow-covered sea ice shortwave radiative transfer calculations that allows the snow to be treated the same to the land snow model (SNICAR). The same subroutine also improves the shortwave calculation of near-IR band for snow-covered sea ice with new parameterizations.