Kilosort icon indicating copy to clipboard operation
Kilosort copied to clipboard

FEATURE: Correcting for misaligned spikes within units

Open dimokaramanlis opened this issue 10 months ago • 3 comments

Feature you'd like to see:

Hi Marius and KS team,

we have been testing KS4 with NP1.0 probes and we are extremely happy with the results so far.

However, sometimes units seem to contain spike times that are misaligned in respect to their corresponding waveforms, typically forming bimodal distributions in feature spaces. See example below:

misaligned_spikes

Default parameters were used. I guess this bug arises during the merging step.

While for most analyses these small differences in timing don't matter, it can be helpful to have aligned waveforms for calculating average spike shapes for feature extraction (e.g., peak-to-trough times).

Best, Dimos

Additional Context

No response

dimokaramanlis avatar Apr 12 '24 07:04 dimokaramanlis

I also see this misalignment in many of my units, giving two well separated clusters misaligned_spikes

hemant22 avatar Apr 12 '24 20:04 hemant22

Hi, I would like to add the same thing. This is happening with Kilosort 4, I would say in my case it happens around 5% of the times. Here is an example:

image

JuanPimientoCaicedo avatar May 09 '24 14:05 JuanPimientoCaicedo

Thanks for the extra examples! We're working on a fix.

jacobpennington avatar May 09 '24 17:05 jacobpennington