OSOceanAcoustics / echopype

Enabling interoperability and scalability in ocean sonar data analysis
https://echopype.readthedocs.io/
Apache License 2.0
99 stars 76 forks source link

`apply_mask` does not interpret `NaN` correctly #1375

Closed leewujung closed 3 months ago

leewujung commented 3 months ago

Apparently right now echopype.mask.apply_mask does not interpret NaN as 0 or False in the mask production, and actually treats it as 1 or True.

This is because xr.where treat NaN in cond as True... kinda unexpected behavior.

I'll follow up with a PR to fix this.

ctuguinay commented 3 months ago

Closed by merging of #1376