OSOceanAcoustics / echopype

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

Empty water_level_draft in EK80 environment datagram #184

Closed Chuck-A closed 4 years ago

Chuck-A commented 4 years ago

After commenting out time format error from issue #182 I had the following error when parsing a Saildrone file:

File "/Users/charles.anderson/opt/miniconda3/lib/python3.7/site-packages/echopype/convert/ek80.py", line 270, in _set_platform_dict out_dict['water_level'] = self.environment['water_level_draft'] KeyError: 'water_level_draft'

leewujung commented 4 years ago

@Chuck-A I think a quick fix could be to set it to NaN and spit out an warning to let user know that it is empty.

Could you give that a try? Thanks!

Chuck-A commented 4 years ago

Will do :)

On Thu, Jul 23, 2020 at 12:17 PM Wu-Jung Lee notifications@github.com wrote:

@Chuck-A https://github.com/Chuck-A I think a quick fix could be to set it to NaN and spit out an warning to let user know that it is empty.

Could you give that a try? Thanks!

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/OSOceanAcoustics/echopype/issues/184#issuecomment-663158047, or unsubscribe https://github.com/notifications/unsubscribe-auth/AHEQUKFCITKLUO4CUIPFK4DR5B5EHANCNFSM4PF7KCBA .

-- Chuck Anderson Fisheries Acoustic Data Manager NOAA National Centers for Environmental Information (NCEI) formerly NOAA’s National Geophysical Data Center Cooperative Institute for Research in Environmental Sciences (CIRES) at University of Colorado at Boulder 325 Broadway, E/NE42 Boulder, Colorado 80305-3328 Tel: 303-497-4742; Fax: 303-497-6513

leewujung commented 4 years ago

Thanks! Just to add more info: @doron2402 said that -1.9 m was what Saildrone had.

I think this calls for a method for user to set this before conversion, so that the .nc or .zarr would have that info included.

leewujung commented 4 years ago

This was addressed in #187 .