WobbleTest¶
- class HSTB.kluster.modules.wobble.WobbleTest(fqpr)¶
Bases:
objectImplementation of ‘Dynamic Motion Residuals in Swath Sonar Data: Ironing out the Creases’ using Kluster processed multibeam data.
http://www.omg.unb.ca/omg/papers/Lect_26_paper_ihr03.pdf
WobbleTest will generate the high pass filtered mean depth and ping-wise slope, and build the correlation plots as described in the paper.
test = r”C:data_dirkluster_converted”fq = fqpr_convenience.reload_data(test)fq.subset_by_time(mintime, maxtime) # subset by the time of interest, will make this a bit fasterwb = WobbleTest(fq)wb.generate_starting_data()wb.plot_correlation_table()Methods Summary
generate_starting_data([filter_rugged])Use the depthoffset (an output from kluster svcorrect) and corr_pointing_angle (an output from kluster get_beam_pointing_vectors to build the highpass filtered slope and depth.
plot_allowable_percent_deviation([subplot])Plot the correlation plot between ping time and percent deviation in the ping slope linear regression.
plot_attitude_latency([subplot, add_regression])Plot to determine the attitude latency either in the POSMV initial processing or the transmission to the sonar.
plot_attitude_scaling_one([subplot, ...])This plot (as well as the trimmed plot scaling_two) deal with identifying:plot_attitude_scaling_two([subplot, ...])See attitude_scaling_one, same concept.
Use the class methods for generating each plot and build a grid of plots.
plot_heave_sound_speed_one([subplot, ...])Plot to find error associated with heaving through sound speed layers.
plot_heave_sound_speed_two([subplot, ...])See plot_heave_sound_speed_one.
plot_x_lever_arm_error([subplot, add_regression])Plot to find the x lever arm error, which is determined by looking at the correlation between filtered depth and pitch.
plot_y_lever_arm_error([subplot, add_regression])Plot to find the y lever arm error, which is determined by looking at the correlation between filtered depth and roll.
plot_yaw_alignment([subplot, add_regression])Plot to determine the misalignment between roll/pitch and heading.
Methods Documentation
- generate_starting_data(filter_rugged=False)¶
Use the depthoffset (an output from kluster svcorrect) and corr_pointing_angle (an output from kluster get_beam_pointing_vectors to build the highpass filtered slope and depth.
High pass filter window is based on the maximum period across all attitude signals (self.max_period).
- Parameters
filter_rugged (
bool) – if True, will filter out data that has percent deviation greater than 5
- plot_allowable_percent_deviation(subplot=None)¶
Plot the correlation plot between ping time and percent deviation in the ping slope linear regression. Percent deviation here is related to the standard error of the y in the regression. Include bounds for invalid data in the plot as a filled in red area. According to source paper, greater than 5% should be rejected.
Need to include segment identification in final version for exluding greater than 5%
- Parameters
subplot (
Optional[subplot]) – pyplot AxesSubplot instance to add to, if None will generate new instance
- plot_attitude_latency(subplot=None, add_regression=True)¶
Plot to determine the attitude latency either in the POSMV initial processing or the transmission to the sonar. We use roll just because it is the most sensitive, most easy to notice. It’s a linear tilt we are looking for, so the timing latency would be equal to the slope of the regression of roll rate vs ping slope.
If you add_regression, you can get the slope that equates to the latency adjustment
slope of regression = ping slope (deg) / roll rate (deg/s) = latency (s)
- Parameters
subplot (
Optional[subplot]) – pyplot AxesSubplot instance to add to, if None will generate new instanceadd_regression (
bool) – bool, if True, will include a regression line
- plot_attitude_scaling_one(subplot=None, add_regression=True)¶
- This plot (as well as the trimmed plot scaling_two) deal with identifying:1. sensor scaling issues (should not be present in modern systems I think)2. rolling with imperfect sound speed (probably more likely)
Focusing on the second one:
When the soundspeed at the face is incorrect, roll angles will introduce steering angle error, so your beampointingangle will be off. As the roll changes, the error will change, making this a dynamic error that is correlated with roll.
We aren’t going to make up some kind of time series bpa corrector for this error, so if you have this, i believe you are just screwed.
- Parameters
subplot (
Optional[subplot]) – pyplot AxesSubplot instance to add to, if None will generate new instanceadd_regression (
bool) – bool, if True, will include a regression line
- plot_attitude_scaling_two(subplot=None, add_regression=True)¶
See attitude_scaling_one, same concept. We have two plots for a good reason. If you are trying to differentiate between 1. and 2., do the following: | - if scaling_one and scaling_two have your artifact, its probably a scaling issue | - otherwise, if the plots are different, it most likely is the sound speed one. Inner swath and outer swath | will differ as the swath is curved
- Parameters
subplot (
Optional[subplot]) – pyplot AxesSubplot instance to add to, if None will generate new instanceadd_regression (
bool) – bool, if True, will include a regression line
- plot_correlation_table()¶
Use the class methods for generating each plot and build a grid of plots. The table allows the user to view multiple results at once, to determine the appropriate course of action.
- plot_heave_sound_speed_one(subplot=None, add_regression=True)¶
Plot to find error associated with heaving through sound speed layers. For flat face sonar that are mostly level while receiving, this affect should be minimal. If I’m understanding this correctly, it’s because the system is actively steering the beams using the surface sv sensor. For barrel arrays, there is no active beam steering so there will be an error in the beam angles.
- Parameters
subplot (
Optional[subplot]) – pyplot AxesSubplot instance to add to, if None will generate new instanceadd_regression (
bool) – bool, if True, will include a regression line
- plot_heave_sound_speed_two(subplot=None, add_regression=True)¶
See plot_heave_sound_speed_one. There are two plots for the port/starboard swaths. You need two as the swath artifact is a smile/frown, so the two plots should be mirror images if the artifact exists. A full swath analysis would not show this.
- Parameters
subplot (
Optional[subplot]) – pyplot AxesSubplot instance to add to, if None will generate new instanceadd_regression (
bool) – bool, if True, will include a regression line
- plot_x_lever_arm_error(subplot=None, add_regression=True)¶
Plot to find the x lever arm error, which is determined by looking at the correlation between filtered depth and pitch. X lever arm error affects the induced heave by the following equation:
Induced Heave Error = -(x_error) * sin(pitch) + (y_error) * sin(roll) * cos(pitch) + (z_error) * (1 - cos(roll) * cos(pitch))
Or in isolating the x
Induced Heave Error = -x_error * sin(pitch)
- Parameters
subplot (
Optional[subplot]) – pyplot AxesSubplot instance to add to, if None will generate new instanceadd_regression (
bool) – bool, if True, will include a regression line
- plot_y_lever_arm_error(subplot=None, add_regression=True)¶
Plot to find the y lever arm error, which is determined by looking at the correlation between filtered depth and roll. Y lever arm error affects the induced heave by the following equation:
- Induced Heave Error = -(x_error) * sin(pitch) + (y_error) * sin(roll) * cos(pitch) +
(z_error) * (1 - cos(roll) * cos(pitch))
or in isloating the y
Induced Heave Error (y) = y_error * sin(roll) * cos(pitch)
- Parameters
subplot (
Optional[subplot]) – pyplot AxesSubplot instance to add to, if None will generate new instanceadd_regression (
bool) – bool, if True, will include a regression line
- plot_yaw_alignment(subplot=None, add_regression=True)¶
Plot to determine the misalignment between roll/pitch and heading. For us, the POSMV is a tightly coupled system that provides these three data streams, so there really shouldn’t be any yaw misalignment with roll/pitch.
- Parameters
subplot (
Optional[subplot]) – pyplot AxesSubplot instance to add to, if None will generate new instanceadd_regression (
bool) – bool, if True, will include a regression line