Skip to content

Commit

Permalink
Add Nortek configuration details to dataset attributes (#106)
Browse files Browse the repository at this point in the history
* Return all attributes

* Organizing attributes by instrument

* Update test files
  • Loading branch information
jmcvey3 authored Jul 8, 2022
1 parent 574abf9 commit fc0df62
Show file tree
Hide file tree
Showing 34 changed files with 190 additions and 175 deletions.
3 changes: 3 additions & 0 deletions changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
- Bugfixes
- Added ability to detect missing timestamps in ADV data

- API/Useability
- Added classic Nortek instrument configuration details into dataset attributes

## Version 1.0.1
- Bugfixes:
- ADV and TRDI correlation and amplitude 'dir' dimension values
Expand Down
233 changes: 123 additions & 110 deletions dolfyn/io/nortek.py

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions dolfyn/tests/data/AWAC_test01.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/AWAC_test01_clean.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/AWAC_test01_earth2inst.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/AWAC_test01_earth2principal.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/AWAC_test01_inst2beam.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/AWAC_test01_ud.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/H-AWAC_test01.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/burst_mode01.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/dat_vec.mat
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/vector_data01.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/vector_data01_GN.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/vector_data01_avg.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/vector_data01_bin.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/vector_data01_rclean.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/vector_data01_rotate_earth2principal.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/vector_data01_rotate_inst2beam.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/vector_data01_rotate_inst2earth.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/vector_data01_sclean.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/vector_data01_u.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/vector_data_imu01-json.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/vector_data_imu01-json_mc.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/vector_data_imu01.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/vector_data_imu01_GN.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/vector_data_imu01_head_pitch_roll.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/vector_data_imu01_mc.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/vector_data_imu01_mcDeclin10.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/vector_data_imu01_mcsp.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/vector_data_imu01_rotate_earth2principal.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/vector_data_imu01_rotate_inst2beam.nc
Git LFS file not shown
4 changes: 2 additions & 2 deletions dolfyn/tests/data/vector_data_imu01_rotate_inst2earth.nc
Git LFS file not shown
1 change: 0 additions & 1 deletion dolfyn/tests/make_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@
# adpr.test_io_nortek(make_data=True)
# adpr.test_io_nortek2(make_data=True)
# adpr.test_nortek2_crop(make_data=True)
# io.test_save(make_data=True)
# io.test_matlab_io(make_data=True)
# io.test_debugging(make_data=True)

Expand Down
8 changes: 4 additions & 4 deletions dolfyn/tests/test_time.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@ def test_time_conversion():
dt_off = time.epoch2date(time.dt642epoch(td.time), offset_hr=-7)
t_str = time.epoch2date(time.dt642epoch(td.time), to_str=True)

assert_equal(dt[0], datetime(2012, 6, 12, 12, 0, 2, 687282))
assert_equal(dt1, [datetime(2012, 6, 12, 12, 0, 2, 687282)])
assert_equal(dt_off[0], datetime(2012, 6, 12, 5, 0, 2, 687282))
assert_equal(t_str[0], '2012-06-12 12:00:02.687282')
assert_equal(dt[0], datetime(2012, 6, 12, 12, 0, 2, 687283))
assert_equal(dt1, [datetime(2012, 6, 12, 12, 0, 2, 687283)])
assert_equal(dt_off[0], datetime(2012, 6, 12, 5, 0, 2, 687283))
assert_equal(t_str[0], '2012-06-12 12:00:02.687283')

# Validated based on data in ad2cp.index file
assert_equal(time.dt642date(dat_sig.time[0])[0],
Expand Down

0 comments on commit fc0df62

Please sign in to comment.