icesat2py / icepyx

Python tools for obtaining and working with ICESat-2 data
https://icepyx.readthedocs.io/en/latest/
BSD 3-Clause "New" or "Revised" License
218 stars 107 forks source link

properly apply all dimensions to deeply nested variables #623

Closed JessicaS11 closed 5 hours ago

JessicaS11 commented 2 weeks ago

In debugging #620, it turned out that variables with a fourth layer of nesting (e.g. ATL06's gt2r/land_ice_segments/geophysical/bsnow_h) were being added to the Xarray Dataset but missing some of their dimensions. This PR addresses that by adding any dimension of size 1 in the subgroup-read-in step to that variable before merging it with the multi-granule dataset. This allows per-granule datasets to be properly merged automatically (rather than icepyx returning a list of per-granule datasets).

github-actions[bot] commented 2 weeks ago

Binder :point_left: Launch a binder notebook on this branch for commit 4a2183661aa0abae1af915d1d574f1c6bc8dc961

I will automatically update this comment whenever this PR is modified

Binder :point_left: Launch a binder notebook on this branch for commit 7571adb1207d7254a79d1364a118f2448bbeb7ef

Binder :point_left: Launch a binder notebook on this branch for commit 4514fd2ca603924f391cf71fbaf1e27c4a3795b2

codecov[bot] commented 2 weeks ago

Codecov Report

Attention: Patch coverage is 0% with 1 line in your changes missing coverage. Please review.

Project coverage is 66.77%. Comparing base (50af59d) to head (4514fd2). Report is 1 commits behind head on development.

Files with missing lines Patch % Lines
icepyx/core/read.py 0.00% 1 Missing :warning:

:exclamation: There is a different number of reports uploaded between BASE (50af59d) and HEAD (4514fd2). Click for more details.

HEAD has 23 uploads less than BASE | Flag | BASE (50af59d) | HEAD (4514fd2) | |------|------|------| ||25|2|
Additional details and impacted files ```diff @@ Coverage Diff @@ ## development #623 +/- ## =============================================== - Coverage 71.81% 66.77% -5.04% =============================================== Files 38 36 -2 Lines 3136 3079 -57 Branches 426 426 =============================================== - Hits 2252 2056 -196 - Misses 774 936 +162 + Partials 110 87 -23 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.