-
Notifications
You must be signed in to change notification settings - Fork 203
Reduction in Ocean and Sea Ice Output #4200
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
base: develop
Are you sure you want to change the base?
Reduction in Ocean and Sea Ice Output #4200
Conversation
|
GFS forecast tested with archiving changes. New interpolated_zgrid file needed, and is at gaeac6:/gpfs/f6/sfs-emc/scratch/Neil.Barton/CODE/gw_ocnice_products_NeilBarton-NOAA/fix/interpolate_zgrid_30L.nc |
parm/post/oceanice_products_gfs.yaml
Outdated
| copy: | ||
| - ["{{ EXECgfs }}/ocnicepost.x", "{{ DATA }}/"] | ||
| - ["{{ PARMgfs }}/post/ocnicepost.nml.jinja2", "{{ DATA }}/"] | ||
| {% if write_grib2 and write_netcdf %} |
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.
Shouldn't this be or instead of and?
Also, shouldn't the ocnicepost.nml.jinja2 file be conditioned based on the if-block?
I think the reason it it outside because the yaml wants atleast one item in the copy block.
In that case, the copy block itself should be conditioned on the if statement, no?
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.
yes, I uploaded the change
parm/post/oceanice_products_gfs.yaml
Outdated
| - ["{{ DATA }}/ocean_subset.nc", "{{ COMOUT_OCEAN_NETCDF }}/{{ RUN }}.t{{ current_cycle | strftime('%H') }}z.tripolar.f{{ '%03d' % forecast_hour }}.nc"] | ||
| - ["{{ DATA }}/ocean_subset.nc", "{{ COMOUT_OCEAN_NETCDF }}/native/{{ RUN }}.t{{ current_cycle | strftime('%H') }}z.native.f{{ '%03d' % forecast_hour }}.nc"] | ||
| - ["{{ DATA }}/ocean_compressed.nc", "{{ COMIN_OCEAN_HISTORY }}/{{ RUN }}.t{{ current_cycle | strftime('%H') }}z.{{ interval }}hr_avg.f{{ '%03d' % forecast_hour }}.nc"] | ||
| {% if write_grib2 %} |
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.
Where is the data from write_netcdf being copied to?
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.
I don't know. I don't think it was defined in the yaml file before my edits.
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.
Correct. The requirement was to provide grib2 output to the users. The netcdf was considered as an intermediate by-product of ocnicepost.x
write_netcdf=True is only needed if we are going to ever give out interpolated netcdf products.
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.
reminder that we need to add the section when write_netcdf = True to copy the interpolated netcdf files
| - ["{{ DATA }}/ice_subset.nc", "{{ COMOUT_ICE_NETCDF }}/native/{{ RUN }}.t{{ current_cycle | strftime('%H') }}z.native.f{{ '%03d' % forecast_hour }}.nc"] | ||
| - ["{{ DATA }}/ice_compressed.nc", "{{ COMIN_ICE_HISTORY }}/{{ RUN }}.t{{ current_cycle | strftime('%H') }}z.{{ interval }}hr_avg.f{{ '%03d' % forecast_hour }}.nc"] | ||
| {% for grid in product_grids %} | ||
| {% if write_grib2 %} |
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.
Shouldn't the interpolated output data from write_netcdf=True be copied to COMOUT_ICE_NETCDF/grid?
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.
same as above
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.
same reminder as above.
| # save subsetted variables to a new netcdf file | ||
| ds_subset.to_netcdf(output_file) | ||
| # save subsetted variables to a new netcdf file and compress | ||
| default_compression = {"zlib": True, "complevel": 8} |
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.
This should be configured in the oceanice_products.yaml
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 compression level? or to compress or not?
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.
both.
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.
namelist options added
parm/post/oceanice_products_sfs.yaml
Outdated
| copy: | ||
| - ["{{ DATA }}/ice_subset.nc", "{{ COMOUT_ICE_NETCDF }}/native/{{ RUN }}.t{{ current_cycle | strftime('%H') }}z.tripolar.f{{ '%03d' % forecast_hour }}.nc"] | ||
| - ["{{ DATA }}/ice_subset.nc", "{{ COMOUT_ICE_NETCDF }}/native/{{ RUN }}.t{{ current_cycle | strftime('%H') }}z.native.f{{ '%03d' % forecast_hour }}.nc"] | ||
| - ["{{ DATA }}/ice_compressed.nc", "{{ COMIN_ICE_HISTORY }}/{{ RUN }}.t{{ current_cycle | strftime('%H') }}z.{{ interval }}hr_avg.f{{ '%03d' % forecast_hour }}.nc"] |
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.
Over-writing model history output?
I don't think this should be allowed because it looses provenance. Perhaps consider the model to write out compressed output in the first place.
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.
I don't think NCO would accept that. I don't think we can overwrite what's in COM right?
Would it be possible to just compress what we subset in the product directory ?
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.
Compression to the products is included in this PR. Compression for the history files can be removed.
The model uses pnetcdf2, which to my knowledge cannot be compressed.
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.
compression of history files removed
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.
Still see the compressed files are overwriting history files.
Co-authored-by: Rahul Mahajan <aerorahul@users.noreply.github.com>
Co-authored-by: Rahul Mahajan <aerorahul@users.noreply.github.com>
parm/archive/ocean_native.yaml.j2
Outdated
| @@ -1,10 +1,7 @@ | |||
| ocean_native: | |||
| {% set NET = NET %} | |||
| {% set FREQ = FHOUT_ICE_GFS %} | |||
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.
Why is this FHOUT_ICE_GFS? Should it be FHOUT_OCN_GFS (if that exists)?
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.
changed with update. This was a copy from the other file
…orkflow into ocnice_products
Co-authored-by: Rahul Mahajan <aerorahul@users.noreply.github.com>
Removed unnecessary variables from the subset list in oceanice_products_gfs.yaml. remove duplicate variables
parm/archive/ocean_native.yaml.j2
Outdated
| name: "OCEAN_NATIVE" | ||
| target: "{{ ATARDIR }}/{{ cycle_YMDH }}/ocean_native_subset.tar" | ||
| required: | ||
| {% for fhr in range(FHOUT_ICE_GFS, FHMAX_GFS + FHOUT_ICE_GFS, FHOUT_ICE_GFS) %} |
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.
Shouldn't these be FHOUT_OCN_GFS?
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.
yes, change uploaded
| write_grib2: True | ||
| write_netcdf: False | ||
| write_grib2: {{ write_grib2 }} | ||
| write_netcdf: {{ write_netcdf }} |
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.
This should stay False. When this is True, the program will run and create the interpolated netcdf files, but they remain in DATA, which gets removed when the job ends.
| write_netcdf: {{ write_netcdf }} | |
| write_netcdf: False |
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.
these variables are now defined in https://github.com/NeilBarton-NOAA/global-workflow/blob/ocnice_products/dev/parm/config/gfs/config.oceanice_products
Co-authored-by: Rahul Mahajan <aerorahul@users.noreply.github.com>
Co-authored-by: Rahul Mahajan <aerorahul@users.noreply.github.com>
parm/post/oceanice_products_gfs.yaml
Outdated
| copy: | ||
| - ["{{ EXECgfs }}/ocnicepost.x", "{{ DATA }}/"] | ||
| - ["{{ PARMgfs }}/post/ocnicepost.nml.jinja2", "{{ DATA }}/"] | ||
| {% if write_grib2 %} |
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.
These are needed when write_netcdf = True as well.
parm/post/oceanice_products_gfs.yaml
Outdated
| - ["{{ DATA }}/ocean_subset.nc", "{{ COMOUT_OCEAN_NETCDF }}/{{ RUN }}.t{{ current_cycle | strftime('%H') }}z.tripolar.f{{ '%03d' % forecast_hour }}.nc"] | ||
| - ["{{ DATA }}/ocean_subset.nc", "{{ COMOUT_OCEAN_NETCDF }}/native/{{ RUN }}.t{{ current_cycle | strftime('%H') }}z.native.f{{ '%03d' % forecast_hour }}.nc"] | ||
| - ["{{ DATA }}/ocean_compressed.nc", "{{ COMIN_OCEAN_HISTORY }}/{{ RUN }}.t{{ current_cycle | strftime('%H') }}z.{{ interval }}hr_avg.f{{ '%03d' % forecast_hour }}.nc"] | ||
| {% if write_grib2 %} |
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.
reminder that we need to add the section when write_netcdf = True to copy the interpolated netcdf files
| - ["{{ DATA }}/ice_subset.nc", "{{ COMOUT_ICE_NETCDF }}/native/{{ RUN }}.t{{ current_cycle | strftime('%H') }}z.native.f{{ '%03d' % forecast_hour }}.nc"] | ||
| - ["{{ DATA }}/ice_compressed.nc", "{{ COMIN_ICE_HISTORY }}/{{ RUN }}.t{{ current_cycle | strftime('%H') }}z.{{ interval }}hr_avg.f{{ '%03d' % forecast_hour }}.nc"] | ||
| {% for grid in product_grids %} | ||
| {% if write_grib2 %} |
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.
same reminder as above.
parm/post/oceanice_products_sfs.yaml
Outdated
| copy: | ||
| - ["{{ DATA }}/ocean_subset.nc", "{{ COMOUT_OCEAN_NETCDF }}/native/{{ RUN }}.t{{ current_cycle | strftime('%H') }}z.tripolar.f{{ '%03d' % forecast_hour }}.nc"] | ||
| - ["{{ DATA }}/ocean_subset.nc", "{{ COMOUT_OCEAN_NETCDF }}/native/{{ RUN }}.t{{ current_cycle | strftime('%H') }}z.native.f{{ '%03d' % forecast_hour }}.nc"] | ||
| - ["{{ DATA }}/ocean_compressed.nc", "{{ COMIN_OCEAN_HISTORY }}/{{ RUN }}.t{{ current_cycle | strftime('%H') }}z.{{ interval }}hr_avg.f{{ '%03d' % forecast_hour }}.nc"] |
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.
Should not overwrite model output.
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.
removed
| {% if write_netcdf %} | ||
| - "{{ COMOUT_OCEAN_NETCDF }}/{{ grid }}" | ||
| {% endif %} |
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.
write_netcdf = False. This section is irrelevant.
| {% if write_netcdf %} | ||
| - "{{ COMOUT_ICE_NETCDF }}/{{ grid }}" | ||
| {% endif %} |
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.
This section is irrelevant because write_netcdf = False
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.
added write_netcdf: {{ write_netcdf }}
sfs products are requested as lat/lon as netCDF
parm/post/oceanice_products_sfs.yaml
Outdated
| copy: | ||
| - ["{{ DATA }}/ice_subset.nc", "{{ COMOUT_ICE_NETCDF }}/native/{{ RUN }}.t{{ current_cycle | strftime('%H') }}z.tripolar.f{{ '%03d' % forecast_hour }}.nc"] | ||
| - ["{{ DATA }}/ice_subset.nc", "{{ COMOUT_ICE_NETCDF }}/native/{{ RUN }}.t{{ current_cycle | strftime('%H') }}z.native.f{{ '%03d' % forecast_hour }}.nc"] | ||
| - ["{{ DATA }}/ice_compressed.nc", "{{ COMIN_ICE_HISTORY }}/{{ RUN }}.t{{ current_cycle | strftime('%H') }}z.{{ interval }}hr_avg.f{{ '%03d' % forecast_hour }}.nc"] |
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.
Still see the compressed files are overwriting history files.
…orkflow into ocnice_products
Description
Addressing
NOAA-EMC/GFS#37
NOAA-EMC/GFS#36
NOAA-EMC/GFS#4
#4163
Reducing the I/O burden by reducing the number of variables, layers, and adding compression.
Also adds archiving for native subsets
Type of change
Change characteristics
How has this been tested?
Tested using C192mx025 SFS forecasts. This will be a draft until GFS testing can be done.
Checklist