-
Notifications
You must be signed in to change notification settings - Fork 7
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
Add example script #174
Add example script #174
Conversation
Codecov ReportBase: 28.98% // Head: 28.98% // No change to project coverage 👍
Additional details and impacted files@@ Coverage Diff @@
## master #174 +/- ##
=======================================
Coverage 28.98% 28.98%
=======================================
Files 93 93
Lines 3981 3981
=======================================
Hits 1154 1154
Misses 2827 2827 Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
This is much needed because we should test changes/debug directly through |
e3sm_to_cmip -i ${rgr_dir} -o $result_dir -v ${cmip_var_list} -t --tables-path ${e2c_path}/cmor/cmip6-cmor-tables/Tables -u ${metadata_path} | ||
|
||
# CMORIZE Sea-ice Monthly variables | ||
# Note the input folder for mpas sea ice files requires: |
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.
@xylar I started to understand the e2c better. would you help review if the following is accurate? Could you let me know the Constants that are required from mpaso_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.
At present, the sea-ice handlers never use constants from the mpassi_in
namelist (note: they would not use mpaso_in
as you suggested above). Presumably, the option was implemented in case they ever would need these constants as MPAS-Ocean does.
e3sm_to_cmip -s --realm SImon --var-list siconc, sitemptop, sisnmass, sitimefrac, siu, siv, sithick, sisnthick, simass --map ${e2c_path}/maps/map_EC30to60E2r2_to_cmip6_180x360_aave.20220301.nc --input-path ${model_data}/v2.mpassi_input/ --output-path ${result_dir} --user-metadata ${metadata_path} --tables-path ${e2c_path}/cmor/cmip6-cmor-tables/Tables | ||
|
||
|
||
# CMORIZE Ocean Monthly variables |
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.
@xylar Same here, would you also look at this session for MPAS ocean processing input requirement?
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 only constant needed from mpaso_in
is config_density0
:
$ cd e3sm_to_cmip/cmor_handlers
$ grep -r "namelist\["
hfsifrazil.py: config_density0 = float(namelist['config_density0'])
hfsifrazil.py: float(namelist['config_frazil_heat_of_fusion'])
msftmz.py: config_density0 = float(namelist['config_density0'])
pbo.py: config_density0 = float(namelist['config_density0'])
masso.py: config_density0 = float(namelist['config_density0'])
pso.py: config_density0 = float(namelist['config_density0'])
masscello.py: config_density0 = float(namelist['config_density0'])
This is the reference density of the ocean, used to convert from volume to mass.
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.
it looks like hfsifrazil requires both 'config_density0' and 'config_frazil_heat_of_fusion'.
@tomvothecoder Hi I think this PR should be ready to go after we get some additional input from Xylar. I think we can either setting up the integration on acme1 or lcrc. |
Sounds good @chengzhuzhang. Thanks! |
@xylar Hey Xylar, I updated the comment to provide needed constants from the mpaso namelist file. Please help review and let me know if anything that I missed...Thank you. |
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.
Looks good. A few small suggestions and answers to your questions.
# 4. A region masks file for MOC regions: EC30to60E2r2_mocBasinsAndTransects20210623.nc (Needed for variable msftmz: Ocean Meridional Overturning Mass Streamfunction) | ||
e3sm_to_cmip -s --realm Omon --var-list areacello, fsitherm, hfds, masso, mlotst, sfdsi, sob, soga, sos, sosga, tauuo, tauvo, thetaoga, tob, tos, tosga, volo, wfo, zos, thetaoga, hfsifrazil, masscello, so, thetao, thkcello, uo, vo, volcello, wo zhalfo --map ${e2c_path}/maps/map_EC30to60E2r2_to_cmip6_180x360_aave.20220301.nc --input-path ${model_data}/v2.mpaso_input/ --output-path ${result_dir} --user-metadata ${metadata_path} --tables-path ${e2c_path}/cmor/cmip6-cmor-tables/Tables | ||
|
||
exit |
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.
(not needed)
e3sm_to_cmip -i ${rgr_dir} -o $result_dir -v ${cmip_var_list} -t --tables-path ${e2c_path}/cmor/cmip6-cmor-tables/Tables -u ${metadata_path} | ||
|
||
# CMORIZE Sea-ice Monthly variables | ||
# Note the input folder for mpas sea ice files requires: |
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.
At present, the sea-ice handlers never use constants from the mpassi_in
namelist (note: they would not use mpaso_in
as you suggested above). Presumably, the option was implemented in case they ever would need these constants as MPAS-Ocean does.
e3sm_to_cmip -s --realm SImon --var-list siconc, sitemptop, sisnmass, sitimefrac, siu, siv, sithick, sisnthick, simass --map ${e2c_path}/maps/map_EC30to60E2r2_to_cmip6_180x360_aave.20220301.nc --input-path ${model_data}/v2.mpassi_input/ --output-path ${result_dir} --user-metadata ${metadata_path} --tables-path ${e2c_path}/cmor/cmip6-cmor-tables/Tables | ||
|
||
|
||
# CMORIZE Ocean Monthly variables |
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 only constant needed from mpaso_in
is config_density0
:
$ cd e3sm_to_cmip/cmor_handlers
$ grep -r "namelist\["
hfsifrazil.py: config_density0 = float(namelist['config_density0'])
hfsifrazil.py: float(namelist['config_frazil_heat_of_fusion'])
msftmz.py: config_density0 = float(namelist['config_density0'])
pbo.py: config_density0 = float(namelist['config_density0'])
masso.py: config_density0 = float(namelist['config_density0'])
pso.py: config_density0 = float(namelist['config_density0'])
masscello.py: config_density0 = float(namelist['config_density0'])
This is the reference density of the ocean, used to convert from volume to mass.
Co-authored-by: Xylar Asay-Davis <xylarstorm@gmail.com>
Co-authored-by: Xylar Asay-Davis <xylarstorm@gmail.com>
Co-authored-by: Xylar Asay-Davis <xylarstorm@gmail.com>
Co-authored-by: Xylar Asay-Davis <xylarstorm@gmail.com>
Hey @chengzhuzhang, I just got back to working on #103 and am leveraging this script to generate CMORized data. I am currently experimenting with the different blocks of code in the example script to generate each set of CMORized data. |
Hi @tomvothecoder thanks for resuming work #103, and let me know if there is any difficulty in testing the example script. |
Provide an end-to-end example script that is independent from CWL workflows.
This script serves for a few purpose:
TO DO: