Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion src/spikeinterface/generation/hybrid_tools.py
Original file line number Diff line number Diff line change
Expand Up @@ -399,8 +399,10 @@ def generate_hybrid_recording(
probe = recording.get_probe()
num_segments = recording.get_num_segments()
dtype = recording.dtype
durations = np.array([recording.get_duration(segment_index) for segment_index in range(num_segments)])
num_samples = np.array([recording.get_num_samples(segment_index) for segment_index in range(num_segments)])
# since the recording can have timestamps with some small gaps, we use the number of samples to compute
# the duration used for the sorting generation
durations = num_samples / sampling_frequency
channel_locations = probe.contact_positions

assert (
Expand Down