Commit b9d0d323 authored by Jan Klaus Rieck's avatar Jan Klaus Rieck

depthsum(): do not try to remove box_wmask if it is not there

parent 46f95321
Pipeline #3645 passed with stage
in 1 minute and 43 seconds
......@@ -996,7 +996,8 @@ def depthsum(ds, std_count=False):
std[v] = ds[v].std(**argu).where(m > 0)
count[v] = ds[v].where(m3 > 0).count(**arg_count)
# remove box_wmask again, because it is not a real wmask
ds_sel = ds_sel.reset_coords('box_wmask').drop('box_wmask')
if 'box_wmask' in ds_sel.coords:
ds_sel = ds_sel.reset_coords('box_wmask').drop('box_wmask')
return ds_sel, std, count
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment