JPSS CRIS-FSR metadata fix#950
Conversation
Greptile SummaryThis PR fixes multiple metadata errors in the
|
| Filename | Overview |
|---|---|
| earth2studio/data/jpss_cris.py | Core logic overhaul: IET→UTC anchor-based time conversion, nominal scan-angle geometry, new footprint-identity fields, sensor_indices projection, and exact-identity deduplication — all well-structured with no identified logic errors. |
| test/data/test_jpss_cris.py | Adds unit tests for IET conversion, scan-angle geometry, footprint identity propagation, source-order projection on both spectral paths, cross-granule dedup non-aliasing, and invalid sensor_indices rejection; mock HDF5 fixtures updated to carry correct anchor attributes. |
Reviews (1): Last reviewed commit: "refactor: finalize JPSS CrIS metadata ha..." | Re-trigger Greptile

Earth2Studio Pull Request
Description
Problem
JPSS_CRIStreated monotonic IET microseconds as elapsed UTC, truncated sourcetime to milliseconds, published satellite zenith as
scan_angle, discardedscan/FOR/FOV identity, and named a post-Planck brightness-temperature matrix
radiance. Its rounded time/location deduplication could also collapsedistinct source footprints.
Change
FORTimefrom IET with the paired UTC/IET beginning anchor inthe same GEO granule:
utc = beginning_utc + (FORTime - beginning_iet).the existing Arrow
timestamp[ns]field.scan_line,field_of_regard, andfield_of_viewmetadata.offset, as
scan_angle; keep sourceSatelliteZenithAngleinsatellite_za.brightness_temperature.sensor_indicesprojection in source order after full-bandapodization, but before Planck inversion and long-format expansion.
platform, variable, scan line, FOR, and FOV. No rounded geolocation is used.
Source Semantics
scan_lineis one-based and local to the source granule.field_of_regardis the one-based telescope position across a scan, 1--30.field_of_viewis the one-based detector position within a FOR, 1--9.satellite_zaremains the measured GEO satellite zenith angle.scan_angleis the nominal instrument look angle derived from FOR/FOV usingthe CrIS detector geometry documented in the
NOAA CrIS SDR ATBD
(successor to JPSS 474-00032) and implemented by
NCEP GSI
read_cris.f90.observationremains float32 brightness temperature in kelvin.Compatibility
sensor_indices=Noneis an appended optional constructor argument.scan_line,field_of_regard, andfield_of_view.scan_anglekeeps its existing nullable float32 type but now carries thecorrect nominal angle instead of satellite zenith.
Numerical Validation
Four real NOAA granules cover S-NPP, NOAA-20, and NOAA-21 across 2024--2025.
Each case projects channels
[1, 714, 1579, 2211]before long expansion.+37.0 sin all four cases0 µsin all four cases0.0 Kmaximum absolute difference0across 900 footprints0.272 µdeg3.815 µdegThe scan-angle oracle is
diag_cris-fsr_n20_ges.2024010100_control.nc4. Comparison uses the completeset of 270 unique
(Scan_Position, Scan_Angle)values, sorted within each FOR;there is no spatial or nearest-neighbor matching.
Visual Validation
Time
Scan Angle
This PR proves the metadata and API behavior it changes: IET-to-UTC time,
microsecond preservation, footprint identity, source-order projection, and
nominal scan geometry. The isolated old/new time replay proves that the time
fix does not alter sampled brightness temperatures; focused tests separately
pin projection values and ordering. It does not claim full native-to-NCEP
CrIS radiance parity, active-channel parity, QC, cloud scoring, or thinning.
Those require separate aggregate-source and selection references.
Tests
28 passed, 7 opt-in slow/network deselectedChecklist
Dependencies