Skip to content

Use LongName for FP collection descriptions in pyrob#408

Draft
mathomp4 wants to merge 1 commit intomainfrom
feature/pyrob-fp-longname-description
Draft

Use LongName for FP collection descriptions in pyrob#408
mathomp4 wants to merge 1 commit intomainfrom
feature/pyrob-fp-longname-description

Conversation

@mathomp4
Copy link
Copy Markdown
Member

Per a request of @rlucches, for Forward Processing (-F) runs, pyrob now derives the collection description from the LongName global attribute of the netCDF file, stripping any leading 'GEOS FP ' prefix and title-casing the result.

A new --no-longname flag restores the legacy Title-based behavior for older FP (and GEOS-IT) files that predate the LongName attribute.

I tested this on a couple files:

Old behavior (--no-longname):

pyrob -F -v -H HISTORY.rc -f stdout --no-longname GEOS.fp.*.nc4
1) Collection inst1_2d_lfo_Nx (DFPI1NXLFO): Land Surface Forcings
2) Collection inst3_2d_asm_Nx (DFPI3NXASM): Single-Level Diagnostics

New default behavior (from LongName global attribute):

pyrob -F -v -H HISTORY.rc -f stdout GEOS.fp.*.nc4
1) Collection inst1_2d_lfo_Nx (DFPI1NXLFO): 2D Time-Averaged Land Surface Forcing
2) Collection inst3_2d_asm_Nx (DFPI3NXASM): 2D Assimilated State

For Forward Processing (-F) runs, pyrob now derives the collection
description from the LongName global attribute of the netCDF file,
stripping any leading 'GEOS FP ' prefix and title-casing the result.

A new --no-longname flag restores the legacy Title-based behaviour for
older FP (and GEOS-IT) files that predate the LongName attribute.
@mathomp4 mathomp4 self-assigned this Mar 13, 2026
@mathomp4 mathomp4 added the 0 diff The changes in this pull request have verified to be zero-diff with the target branch. label Mar 13, 2026
@mathomp4 mathomp4 requested a review from rlucches March 13, 2026 12:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

0 diff The changes in this pull request have verified to be zero-diff with the target branch.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant