You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@Maribaken discovered a bug when trying to process AD2CP_TIME from a SeaExplorer. This is timing from the ADCP internal clock, which can differ substantially from the SX payload clock, so it's important to carry this data forward.
These are correctly interpreted as datetimes at the raw_to_rawnc stage
but get converted to floats during raw_to_L0timeseries becoming
array([ nan, nan, 0., ..., 1990., 2020., 2050.])
The culprit is the decode_times=False kwarg in sensor = xr.open_dataset(f'{indir}/{id}-{kind}pld.nc', decode_times=False) in seaexplorer.py line 248
I think this flag is in here to force the main timestamp to be in seconds since 1970, so that the function utils.get_profiles_new works as it takes calculates a median time difference between samples in seconds.
Should I do a specific fix for the AD2CP? Are there other sensors that record internal time we need to keep? Should I try to rework utils.get_profiles_new to work with datetimes rather than seconds since 1970?
The text was updated successfully, but these errors were encountered:
Probably we should try to update it all to work properly with datetime64 objects. Probably when I wrote this, I wasn't up on how to use dataetim64 properly.
@Maribaken discovered a bug when trying to process AD2CP_TIME from a SeaExplorer. This is timing from the ADCP internal clock, which can differ substantially from the SX payload clock, so it's important to carry this data forward.
These are correctly interpreted as datetimes at the
raw_to_rawnc stage
but get converted to floats during
raw_to_L0timeseries
becomingThe culprit is the
decode_times=False
kwarg insensor = xr.open_dataset(f'{indir}/{id}-{kind}pld.nc', decode_times=False)
in seaexplorer.py line 248I think this flag is in here to force the main timestamp to be in seconds since 1970, so that the function
utils.get_profiles_new
works as it takes calculates a median time difference between samples in seconds.Should I do a specific fix for the AD2CP? Are there other sensors that record internal time we need to keep? Should I try to rework
utils.get_profiles_new
to work with datetimes rather than seconds since 1970?The text was updated successfully, but these errors were encountered: