Skip to content

Commit

Permalink
Merge pull request #2102 from alejoe91/fix-openephys.multi-shank
Browse files Browse the repository at this point in the history
Fix grouping of OpenEphys NPIX
  • Loading branch information
samuelgarcia authored Oct 16, 2023
2 parents 6b04e29 + 9addc57 commit 05419fc
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion examples/modules_gallery/qualitymetrics/plot_4_curation.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,4 +61,4 @@

curated_sorting = sorting.select_units(keep_unit_ids)
print(curated_sorting)
se.NpzSortingExtractor.write_sorting(curated_sorting, 'curated_sorting.pnz')
se.NpzSortingExtractor.write_sorting(curated_sorting, 'curated_sorting.npz')
5 changes: 4 additions & 1 deletion src/spikeinterface/extractors/neoextractors/openephys.py
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,10 @@ def __init__(
probe = None

if probe is not None:
self = self.set_probe(probe, in_place=True)
if probe.shank_ids is not None:
self.set_probe(probe, in_place=True, group_mode="by_shank")
else:
self.set_probe(probe, in_place=True)
probe_name = probe.annotations["probe_name"]
# load num_channels_per_adc depending on probe type
if "2.0" in probe_name:
Expand Down

0 comments on commit 05419fc

Please sign in to comment.