Update read_kilosort_as_analyzer to allow for multiple-probes and user-defined recording#4529
Open
chrishalcrow wants to merge 8 commits into
Open
Conversation
h-mayorquin
reviewed
May 18, 2026
zm711
reviewed
Jul 8, 2026
zm711
left a comment
Member
There was a problem hiding this comment.
Couple questions @chrishalcrow.
| ---------- | ||
| folder_path : str or Path | ||
| Path to the output Phy folder (containing the params.py). | ||
| recording : BaseRecording |
Member
There was a problem hiding this comment.
Just as an FYI this breaks positional arguments for people... What is your logic for being okay with that?
| "The number of spikes does not match the number of spike locations in `spike_positions.npy`. Skipping spike locations." | ||
| ) | ||
| return | ||
| locs_np = locs_np[:num_spikes] |
Member
There was a problem hiding this comment.
How do we know this is the correct set? the problem is KS4 pads which means we have spikes both before and after the recording. So just taking 0...n_spikes means you might take some "fake" spikes at the beginning and lose "real" spikes at the end....
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR improves the
read_kilosort_as_analyzerfunction, as discussed in (#4366).The plan:
channel_map.npyfor device channel indices instead of rangeprobe.prbfile in output