Reset tracker frames after each mode
This commit is contained in:
parent
574f4a615d
commit
459a8dc2a3
1 changed files with 3 additions and 1 deletions
|
|
@ -54,6 +54,8 @@ class JPEGSharpnessMonitor:
|
||||||
# Make timestamp absolute Unix time
|
# Make timestamp absolute Unix time
|
||||||
self.jpeg_times.append(frame.time)
|
self.jpeg_times.append(frame.time)
|
||||||
self.jpeg_sizes.append(frame.size)
|
self.jpeg_sizes.append(frame.size)
|
||||||
|
# Clear frame data for this move from the stream
|
||||||
|
self.camera.stream.reset_tracking()
|
||||||
|
|
||||||
# Index of the data for this movement
|
# Index of the data for this movement
|
||||||
data_index = len(self.stage_positions) - 2
|
data_index = len(self.stage_positions) - 2
|
||||||
|
|
@ -62,7 +64,7 @@ class JPEGSharpnessMonitor:
|
||||||
return data_index, final_z_position
|
return data_index, final_z_position
|
||||||
|
|
||||||
def move_data(self, istart, istop=None):
|
def move_data(self, istart, istop=None):
|
||||||
"Extract sharpness as a function of (interpolated) z"
|
"""Extract sharpness as a function of (interpolated) z"""
|
||||||
if istop is None:
|
if istop is None:
|
||||||
istop = istart + 2
|
istop = istart + 2
|
||||||
jpeg_times = np.array(self.jpeg_times)
|
jpeg_times = np.array(self.jpeg_times)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue