-
Notifications
You must be signed in to change notification settings - Fork 138
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
Parser: Add ability to read in generic blocks #1519
Conversation
allocate(block_ids(get_num_unique_blocks(yaml_id, parent_block_id=varlist_ids(k)))) | ||
call get_unique_block_ids(yaml_id, block_ids, parent_block_id=varlist_ids(k)) | ||
do l = 1, size(block_ids) | ||
call get_block_name(yaml_id, block_ids(l), block_name) |
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.
@J-Lentz @GFDL-Eric
This is relevant code that will be used to read the new field_table yaml format.
get_num_unique_blocks
is going to be used to get the number of unique blocks for each variable. For the example below, it will get 1 for sphum
and 2 for soa
. get_unique_block_ids
will be used to get an id for each of the blocks and that can be used to get the block name (i.e profile_type
for sphum
, and chem_param
and profile_type
for soa
) and from there, it can be read as normal ...
field_table:
- field_type: tracer
modlist:
- model_type: atmos_mod
varlist:
- variable: sphum
longname: specific humidity
units: kg/kg
profile_type:
- value: fixed
surface_value: 3.0e-06
- variable: soa
longname: SOA tracer
units: mmr
convection: all
chem_param:
- value: aerosol
profile_type:
- value: fixed
surface_value: 1.0e-32
Description
Adds three new subroutines to the parser:
These are needed in order to read the new format of the field table yaml described in #1520
Fixes #1520
How Has This Been Tested?
CI, including new test
Checklist:
make distcheck
passes