AllenInstitute / ecephys_spike_sorting

Modules for processing extracellular electrophysiology data from Neuropixels probes
Other
109 stars 91 forks source link

Implement module to remove putative double-counted spikes #27

Closed jsiegle closed 5 years ago

jsiegle commented 5 years ago

This should run after kilosort_helper, and remove intra- and inter-unit spikes that are overlapping in space and time.

See this issue for more info: https://github.com/MouseLand/Kilosort2/issues/29

ldclaar commented 5 years ago

I have tried running phy using the files output by this module and phy gives me an AssertionError. It seems that phy asserts that spike_templates.shape == (ns,). Does it make sense to have this module output a new spike_templates.npy file? Another candidate would be template_features.npy because it also has one dimension equal to the number of spikes.

jsiegle commented 5 years ago

Good point, I will fix that.

jsiegle commented 5 years ago

@ldclaar This should be fixed in the master branch now. Can you test it out?

ldclaar commented 5 years ago

I tested it out, it works now. Thanks!