AON20 SADCP Processing Steps ============================ LAST CHANGED : 2020/11/01 15:53:57 CRUISE NAME(S) : SKQ202014S CRUISE DATES : 2020/10/16 01:04:14 to 2020/10/16 01:06:20 SHIP NAME : unspecified PORTS : unspecified CHIEF SCIENTIST : unspecified DATABASE NAME : a_skq DATA FILES : skq2020_289_03852.raw to skq2020_305_54995.raw STATUS : to do done ------ ----------- averaged [ ] loaded [ ] NOTE: heading correction instrument exists NOTE: time-dependent heading corrections applied IN the ensembles (see cal/rotate/ens_hcorr.ang) check heading correction [ ] calibration [ ] edited [ ] re-check heading correction [ ] check editing [ ] figures [ ] INSTRUMENT : wh300 ACQUISITION : PROGRAM : uhdas PROCESSING: : python LOGGING : PARAMETERS : BT : bottom track mode (on or off) SI : sampling interval or averaging period for ensemble (sec) NB : number of bins BL : bin length (m) TD : transducer depth (m) BK : blanking length (m) HO : heading offset applied by DAS (deg) HB : heading bias (deg) CRPH : compensation for roll-pitch-heading, 1:on, 0:off) yy/mm/dd hh:mm:ss BT SI NB BL TD BK HO HB CRPH 2020/10/16 01:06:12 on 120 70 2 7 2 44.93 0.00 0001 2020/10/18 03:06:14 on 120 70 2 7 2 44.93 0.00 0001 2020/10/18 04:53:23 off 120 70 2 7 2 44.93 0.00 0001 2020/10/18 14:53:22 off 120 70 2 7 2 44.93 0.00 0001 2020/10/19 20:53:23 off 120 70 2 7 2 44.93 0.00 0001 2020/10/20 06:53:22 off 120 70 2 7 2 44.93 0.00 0001 2020/10/21 02:53:22 off 120 70 2 7 2 44.93 0.00 0001 2020/10/21 23:50:29 off 120 70 2 7 2 44.93 0.00 0001 2020/10/22 09:50:29 off 120 70 2 7 2 44.93 0.00 0001 2020/10/23 05:50:30 off 120 70 2 7 2 44.93 0.00 0001 2020/10/23 15:50:30 off 120 70 2 7 2 44.93 0.00 0001 2020/10/24 11:50:30 off 120 70 2 7 2 44.93 0.00 0001 2020/10/26 13:50:30 off 120 70 2 7 2 44.93 0.00 0001 2020/10/31 13:43:37 off 120 70 2 7 2 44.93 0.00 0001 2020/10/31 23:43:37 off 120 70 2 7 2 44.93 0.00 0001 HEADING : PRIMARY : heading from gyro1 CORRECTION : heading correction from seapath NOTE: time-dependent heading corrections applied IN the ensembles (see cal/rotate/ens_hcorr.ang) POSITIONS : gps positions from seapath CALIBRATION : (check original processing parameters) additional rotation 0 final transducer angle is: (original transducer angle) - (rotate_angle) applied scale factor 1 additional scale factor (none) COMMENTS : gaps in heading correction? scattering layers? bubbles? underway bias? PROCESSOR : D. Torres --- processing parameters ---------- ## (determined from "sonar"): model = wh ## (determined from "sonar"): frequency = 300 ## (determined from "sonar"): instname = wh300 ## (determined from "sonar"): pingtype = bb beamangle 20 cruisename SKQ202014S datatype uhdas ens_len 120 fixfile a_skq.gps frequency 300 hcorr_inst seapath instname wh300 model wh pingtype bb proc_engine python ref_method refsm refuv_smoothwin 3 refuv_source nav sonar wh300 txy_file a_skq.agt xducer_dx 2 xducer_dy 22 yearbase 2020 Instrument setup AON20 project collected shipboard ADCP from R/V Sikuliaq survey. The instruments we used are Teledyne RDI 300 kHz Workhorse ADCP and a Teledyne RDI 75 kHz Ocean Surveyor ADCP. This log describes the processing for cruise A Determine time ranges. Using showdb and dataviewer.py. Part 1 ADCP Start_date_time Decimal_Day End_date_time Decimal_day WH300 2020/10/16 01:06:12 209.0460 2020/10/27 16:07:55 300.6722 Part 2 ADCP Start_date_time Decimal_Day End_date_time Decimal_day WH300 2020/10/29 11:43:37 302.4886 2020/11/01 15:54:00 305.6625 The next Part 3 is from when I started a new cruise. That processing steps for that part will be discussed in another document. Part 3 - Cruise B ADCP Start_date_time Decimal_Day End_date_time Decimal_day WH300 2020/11/04 05:44:06 308.2390 ... still going .... Actual processing steps ======================= - The WH300 ADCP is mounted on a centerboard that can be raised or lowered. In the lowered position, the ADCP depth is ? below the hull depth of ?. With ADCP blanking distance set at ?, that puts center of Bin 1 at ?. > cd SKQ202014S_A/proc > tarcopy wh300 /media/sf_vmraw/SKQ14S_A_postproc > cd wh300 > cat cruise_info.txt >> ../process_wh300.txt # This file > To take a quick look at the data > quick_mplplots.py --yearbase 2020 --plots2run all --noshow This created plots but crashed due to too many plots. so tried... > quick_mplplots.py --yearbase 2020 --plots2run btcal:wtcal --noshow > quick_mplplots.py --yearbase 2020 --plots2run btcal:wtcal I confirmed what I already knew about different parts needing calibration. That you can't tell much from these plots. The water track cal sort of shows a change in the phase angle towards the end. - On another note, I confirmed I can use rotate to just rotate part of the data with one correction and rotate again on another part of the data. After running those quick_mplplots, I saw they updated the btcaluv.out file. Go do BT cal cd cal/botmtrk To do 1st part of cal on part A1 > lst_btrk lst_btrk_partA1.tmp > refabsbt refabsbt_partA1.tmp First problem I see is with output file sizes. a_skq_partA1.btm : 289.0 - 290.755, 1040 lines a_skq_orig.btm: 289.0 - 305, 1091 lines from this, it seems to me the output file sizes of refabsbt should be similar with the orig slightly bigger. But the orig is way bigger. a_skq_partA1.ref - 289.0 - 290.7, size 92400, 1232 lines a_skq_orig.ref - 289.0 - 305.66, size 760801, 10144 lines Noteworthy but moving on. Now run Btplot_script.py > cp Btplot_script.py Btplot_script_orig.py > vi Btplot_script.py > vi Btplot_script.py > vi Btplot_script.py > cp Btplot_script.py Btplot_partA1.py > python Btplot_partA1.py Created btcal_partA1.png and added to btcaluv.out WH300_partA1 bottomtrack calibration Time range 289.05 to 290.76 Calculation done at Sat Nov 7 09:35:37 2020 step: 1 min_depth: 20 max_depth: 1000 min_speed: 1.0 m/s max_sig: 2.5 std devs max_gap: 0.10 minutes tol_dt: 0.02 (fraction) unedited: 1030 points edited: 954 points, 1.0 min speed, 2.5 max dev median mean std amplitude 0.9878 0.9880 0.0054 phase -0.0513 -0.0453 0.0697 As expected, changed phase very little but non-zero. Old value was amplitude 0.9880 0.9886 0.0060 phase -0.0494 -0.0425 0.0716 - Now lets try water track cal. - First, just installed vim because vi was driving me nuts. > sudo apt-get install vim login: adcpproc pass: codas3 Next I need to run timslip. Problem is there does not seem to be a way to run timslip on a specific time range. I tried entering a time range with same syntax as lst_btrk.tmp but that did not work. So to trick timslip, I editted > cp a_skq.agt a_skq_orig.agt > cp a_skq.nav a_skq_orig.nav > cp a_skq.agt a_skq_partA1.agt > cp a_skq.nav a_skq_partA1.nav I chopped off the back end of these files to only leave the time range of partA1. Turns out I probably did not have to do that because the next step (actual cal) does allow time ranges (dd=) SO new cal is: WH300_partA1 watertrack calibration ## Time range 289.21 to 300.45 Calculation done at Sat Nov 7 10:33:52 2020 delta-u min = -100.00, max = 100.00 delta-v min = -100.00, max = 100.00 clip_amp = 0.04, clip_ph = 3.0 clip_dt = 60, clip_var = 0.050 Number of edited points: 32 out of 34 amp = 0.9954 + -0.0004 (t - 297.3) phase = -0.15 + -0.0524 (t - 297.3) median mean std amplitude 0.9980 0.9954 0.0109 phase -0.1675 -0.1530 0.4095 nav - pc 0.0000 0.1875 2.1013 var 0.0010 0.0012 0.0018 min var 0.0010 0.0010 0.0012 delta-u -0.2100 -0.3184 2.2953 delta-v 0.5300 0.3456 3.3536 Final BT and WT results for partA1 BT median mean std amplitude 0.9878 0.9880 0.0054 phase -0.0513 -0.0453 0.0697 WT median mean std amplitude 0.9980 0.9954 0.0109 phase -0.1675 -0.1530 0.4095 Based on this, BT looks way better. So I will use phase = -0.05, amp = 0.9980 for partA1 Next comes part A2 Created lst_btrk_partA2.tmp control file with time range for part A2. Created a_skq_partA2.btm Lot smaller than partA1. Next edited refabsbt_partA2.tmp and created a_skq_partA2.ref Next did the actual cal with Btplot_partA2.py This added an entry to btcaluv.out WH300_partA2 bottomtrack calibration Time range 303.11 to 305.66 Calculation done at Sat Nov 7 21:01:38 2020 step: 1 min_depth: 20 max_depth: 1000 min_speed: 1.0 m/s max_sig: 2.5 std devs max_gap: 0.10 minutes tol_dt: 0.02 (fraction) unedited: 47 points edited: 42 points, 1.0 min speed, 2.5 max dev median mean std amplitude 1.0024 1.0022 0.0029 phase 0.0000 -0.0137 0.1570 Next WT cal Created timslip_partA2.tmp This time using the full .agt and .nav files. This time I did WT cals for 5 7 9 window sizes, just for kicks. > timslip timslip_5_partA2.tmp > timslip timslip_7_partA2.tmp > timslip timslip_9_partA2.tmp I tried setting a time range with Wtplot_5_partA2.py but that failed. Could not get the syntax right for ddrange. Si I am redoing timslip with the trick I did above. Used ...partA2.agt and ...partA2.nav in nav folder WH300_partA2_5 watertrack calibration ## Time range 302.57 to 305.47 Calculation done at Sat Nov 7 23:23:38 2020 delta-u min = -100.00, max = 100.00 delta-v min = -100.00, max = 100.00 clip_amp = 0.04, clip_ph = 3.0 clip_dt = 60, clip_var = 0.050 Number of edited points: 14 out of 24 amp = 1.0049 + 0.0032 (t - 304.4) phase = -0.28 + 0.0790 (t - 304.4) median mean std amplitude 1.0020 1.0049 0.0163 phase -0.3450 -0.2824 0.7302 nav - pc 0.5000 0.4286 2.7094 var 0.0010 0.0014 0.0015 min var 0.0010 0.0011 0.0014 delta-u -1.3450 -0.6921 2.4532 delta-v 0.8650 0.3543 2.2574 WH300_partA2_7 watertrack calibration ## Time range 302.57 to 305.47 Calculation done at Sat Nov 7 23:26:34 2020 delta-u min = -100.00, max = 100.00 delta-v min = -100.00, max = 100.00 clip_amp = 0.04, clip_ph = 3.0 clip_dt = 60, clip_var = 0.050 Number of edited points: 7 out of 13 amp = 1.0003 + -0.0009 (t - 304.4) phase = -0.91 + 0.0378 (t - 304.4) median mean std amplitude 0.9990 1.0003 0.0191 phase -0.6450 -0.9087 1.1450 nav - pc 1.0000 1.4286 2.8200 var 0.0010 0.0020 0.0017 min var 0.0010 0.0014 0.0013 delta-u 0.3500 0.3014 2.2265 delta-v 1.7400 0.9571 2.1665 WH300_partA2_9 watertrack calibration ## Time range 302.57 to 305.47 Calculation done at Sat Nov 7 23:29:35 2020 delta-u min = -100.00, max = 100.00 delta-v min = -100.00, max = 100.00 clip_amp = 0.04, clip_ph = 3.0 clip_dt = 60, clip_var = 0.050 Number of edited points: 3 out of 5 amp = 1.0080 + 0.0003 (t - 303.9) phase = -0.96 + 0.4098 (t - 303.9) median mean std amplitude 1.0100 1.0080 0.0035 phase -1.2790 -0.9597 0.6835 nav - pc 0.0000 0.0000 2.0000 var 0.0010 0.0007 0.0006 min var 0.0010 0.0007 0.0006 delta-u 1.3900 1.3767 0.9601 delta-v -1.2100 -1.0400 0.6616 Final Results WT nrefs 5 7 9 mean(std) amplitude 1.0049(0.0163) 1.0003(0.0191) 1.0080(0.0035) phase -0.2824(0.7302) -0.9087(1.1450) -0.9597(0.6835) pts used/ 14/24 7/13 3/5 total number BT median mean std pts_used/Tot amplitude 1.0024 1.0022 0.0029 42/47 phase 0.0000 -0.0137 0.1570 Rotation Went ahead and rotated all of Part A with same angle 0.05 and amplitude = 1.00 > rotate rotate_partA.cnt - This had the effect of applying a constant offset to Ancillary 2 variables (showdb: 16: 38) watrk_hd_misalign : 0.0861208 deg botrk_hd_misalign : 0.0861208 deg These variables change with each ensemble. Not sure about that. Ask Jules. - Now I want to change the default PG threshold from 50% to 20% for whole cruise. I saw that 50% was too tight and was flagging good data. - I am supposed to set pgmin = 20 in dbinfo.txt. But dbinfo.txt does not have pgmin variable. So I am adding it just in case. > setflags clearflags_partA.tmp Should I have set set_range_bit? Starting gautoedit (See wierd errors when starting below) > gautoedit.py & [2] 25548 codaspy:(edit)$ importing numpy version 1.8.2 /usr/lib/pymodules/python2.7/matplotlib/__init__.py:1173: UserWarning: This call to matplotlib.use() has no effect because the backend has already been chosen; matplotlib.use() must be called *before* pylab, matplotlib.pyplot, or matplotlib.backends is imported for the first time. warnings.warn(_use_error_msg) importing matplotlib version 1.3.1 in Q_mpl - In gautoedit, the PG threshold reads 50 but I confirmed it is 20. Just the label did not get updated. I can increase the threshold to 30 and it flags more stuff so I know it is working correctly. When I "Apply editing" the new bins flagged by increasing PG do get edited in the database as more bad bins. There is no way to really tell except that Jules says so. Good enough for me. Went through all the cruise with gautoedit. A good step for me was every 0.4 days. Now I tried > quick_adcp.py --steps2rerun --apply_edit:navsteps:calib --auto sys.argv = /usr/local/currents/bin/quick_adcp.py --steps2rerun --apply_edit:navsteps:calib --auto found dbinfo.txt: use values if otherwise unspecified found dbname a_skq using (xducer_dx, xducer_dy) (2.000, 22.000) fix file is a_skq.gps reflayer: ref_method = refsm reflayer: refuv_source = nav reflayer: refuv_smoothwin = 3 importing numpy version 1.8.2 importing matplotlib version 1.3.1 found steps2rerun: --apply_edit:navsteps:calib Traceback (most recent call last): File "/usr/local/currents/bin/quick_adcp.py", line 10, in quick_adcp(sys.argv[1:]) File "/usr/local/lib/python2.7/dist-packages/pycurrents/adcp/quick_adcp.py", line 983, in quick_adcp raise quickFatalError(msg) pycurrents.adcp.quick_setup.quickFatalError: steps2rerun should come from: rotate:find_pflags:apply_edit:navsteps:calib:matfiles option "--apply_edit" not matched OOps. I had a typo. It was bad in the manual. http://localhost/adcp/programs/adcp_doc/codas_doc/edit_doc/index.html but correct here http://localhost/adcp/programs/adcp_doc/codas_doc/CODAS_quickdoc.html#accessing-the-database Says > quick_adcp.py --steps2rerun --apply_edit:navsteps:calib --auto but it should be > quick_adcp.py --steps2rerun apply_edit:navsteps:calib --auto That worked. Next, update matfiles > quick_adcp.py --steps2rerun matfiles --auto