geoschem / geos-chem

GEOS-Chem "Science Codebase" repository. Contains GEOS-Chem science routines, run directory generation scripts, and interface code. This repository is used as a submodule within the GCClassic and GCHP wrappers, as well as in other modeling contexts (external ESMs).
http://geos-chem.org
Other
168 stars 165 forks source link

[FEATURE REQUEST] Add surface pressure to any HISTORY diagnostic with 3-D fields #635

Open ltmurray opened 3 years ago

ltmurray commented 3 years ago

If we add PS to each output file (like we do with AREA), then we have everything we need to calculate vertical altitudes/pressures for any output file (useful for plotting/regridding) without having to separately archive LevelEdgeDiags. I believe including PS is also part of the CF metadata specifications for that reason.

yantosca commented 3 years ago

Thanks @ltmurray. I think the best way to proceed would be to add Met_PS to each collection in HISTORY.rc. This will let us be consistent with both GCC and GCHP.

We can update the HISTORY templates for the 13.0.0 final release.

ltmurray commented 3 years ago

Thanks, Bob! If we use the convention of naming the variable "ps" with a "standard_name" of "surface_air_pressure" per the CF guidelines, then the output files will be compatible with the majority of third-party software packages that process atmospheric model output (e.g., CDO, NCO, NCL, etc.)

yantosca commented 3 years ago

There would be no way to do that in GCHP unless we update the History component in MAPL. We could do it in GCC with a little coding. You can write a python script to change the names & attributes very easily though.

ltmurray commented 3 years ago

Unfortunately, GEOS does not follow international standards like most climate models (at least, without an extra post-processing step). I would strongly recommend that GCC at least natively output in CF compliant format.

yantosca commented 3 years ago

Thanks @ltmurray. Maybe I can make the GCC code modification in GC 13.1.0 (or if there is a patch version before that). Since we are trying to close out the benchmarks, we are trying not to touch the code too much right now.

An alternative would be to add a script in OutputDir to rename the the variable and attributes to make them CF-compliant for PS. That's an easy stopgap fix.

ltmurray commented 3 years ago

13.1 is fine — it's certainly not a requirement, just a nice feature to have.

lizziel commented 3 years ago

It is possible in GCHP to provide an alias to a MAPL export variable in HISTORY.rc for use in a file. It is a feature of MAPL that we have not used before to avoid confusion. To do this you simply add a comma after the gridded component name in a collection.fields line and then the alias in quotes, followed by another comma. See also page 32 of the very outdated draft MAPL User Guide. An official User Guide was never issued.

We could output pressure using a CF-compliant name, or any other outputs. We should definitely add this to our documentation for GCHP History.

ltmurray commented 3 years ago

@lizziel Cool!