Skip to content
This repository has been archived by the owner on May 4, 2023. It is now read-only.

overclustering and missing spikes #208

Open
paul-aparicio opened this issue Mar 9, 2022 · 3 comments
Open

overclustering and missing spikes #208

paul-aparicio opened this issue Mar 9, 2022 · 3 comments

Comments

@paul-aparicio
Copy link

Hello!

I am using waveclus to sort data from a 96 channel blackrock Utah array through spikeinterface with the default parameters (though I turn off the filtering as the data has been pre-filtered) and I was hoping you might have some advice on two issues I am having.

(1) I seem to get way too many clusters (300-400), so I was wondering if you had any suggestions on which parameters I might work with to most effectively reduce the numbers of clusters I find. (2) I have been seeing this issue where clear large spikes are being skipped. I post here some examples. There is a very distinct cluster (red in the scatter plot top right) that seems to drop out during the recording (red dots in the amplitude view plot).

Screenshot from 2022-03-09 10-18-59

The trace view shows the waveforms over a small time window in one of the active time windows and you can clearly see that there are two events from the red cluster around a middle event that was not detected by waveclus at all (its the probe marked #6).
Screenshot from 2022-03-09 10-17-57

I see similar missed events during the drop out periods when I randomly scroll through the time series. some examaples here:
Screenshot from 2022-03-09 10-21-02

Screenshot from 2022-03-09 10-14-59

Maybe I have to change the stdmax parameter?

Thank you for any help,
Paul

@ferchaure
Copy link
Member

Hi Paul, cool I never saw that gui with waveclus results, that is really cool

  1. How are you processing the channels? each individually, all together or by groups? you can try increasing the min_clus parameter.
  2. Increasing stdmax could be an option. The alternative could be change 'keep_good_only' to false and look if the spikes is been detected but not assigned to a cluster. In this last case increasing 'template_sdnum' will help, if that neuron is really stable and the unsorted ones are just a bit different.

Remember that wave_clus is not design to handle a high number of channels, I would recommend to sort each channel individually and then check for collisions. Maybe a previous deteccion is hiding (in the refractory period) the big spike

@paul-aparicio
Copy link
Author

Thanks for your response! (1) I am processing the channels using median referencing (across all the channels) and then filtering with the spikeinterface tools. When I use waveclus, its done separately for each electrode as they are 400um apart on a utah array (so no interaction expected). I will try the min_clus parameter. (2) It looks like keep_good_only isn't a parameter option for spikeinterface. I will try running it matlab to try out your suggestion.

Thanks for the help!
paul

@ferchaure
Copy link
Member

(1) Your pipeline looks fine, if the channels are good ~3.5 classes per channel doesn't sound so crazy . Maybe check the waveforms channel by channel just to see if maybe a few have overclustering that can be manually fix.
(2) keep_good_only is a parameter only in the spikeinterface wrapper (if True it removes the unsorted spikes class, class 0 in the matlab file).

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants