Skip to content

Commit

Permalink
Remove redundant else statement.
Browse files Browse the repository at this point in the history
  • Loading branch information
JoeZiminski committed Nov 6, 2023
1 parent 3712da0 commit 266be6f
Showing 1 changed file with 12 additions and 12 deletions.
24 changes: 12 additions & 12 deletions src/spikeinterface/sortingcomponents/motion_interpolation.py
Original file line number Diff line number Diff line change
Expand Up @@ -386,18 +386,18 @@ def get_traces(self, start_frame, end_frame, channel_indices):
"time_vector for InterpolateMotionRecording do not work because temporal_bins start from 0"
)
# times = np.asarray(self.time_vector[start_frame:end_frame])
else:
if start_frame is None:
start_frame = 0
if end_frame is None:
end_frame = self.get_num_samples()

times = np.arange((end_frame or self.get_num_samples()) - (start_frame or 0), dtype="float64")
times /= self.sampling_frequency
t0 = start_frame / self.sampling_frequency
# if self.t_start is not None:
# t0 = t0 + self.t_start
times += t0

if start_frame is None:
start_frame = 0
if end_frame is None:
end_frame = self.get_num_samples()

times = np.arange((end_frame or self.get_num_samples()) - (start_frame or 0), dtype="float64")
times /= self.sampling_frequency
t0 = start_frame / self.sampling_frequency
# if self.t_start is not None:
# t0 = t0 + self.t_start
times += t0

traces = self.parent_recording_segment.get_traces(start_frame, end_frame, channel_indices=slice(None))

Expand Down

0 comments on commit 266be6f

Please sign in to comment.