csn-le / wave_clus

A fast and unsupervised algorithm for spike detection and sorting using wavelets and super-paramagnetic clustering
121 stars 65 forks source link

simple example using Simulator database #215

Closed ljylxl closed 2 years ago

ljylxl commented 2 years ago

Hi, Thank you for sharing this spikes sorting code. I am trying to figure out fulfilling a simple scenario: I have the code GUI ready. I have the Simulator database ready in directory 'E:\SpikeSorting\WaveClus3\wave_clus-database\Simulator'. In GUI I clicked "load data" and find one of the .mat file to load. I got the error: Error using readInData (line 128) File type '.mat' isn't supported.

I also tried to load the data in the other way: To use the batch functions, type Get_spikes('filename.ext'), where .ext is a file extension (eg. .mat), for the spike detection; this will save a file filename_spikes.mat in the current directory. Subsequently, run Do_clustering('filename_spikes.mat') to do the sorting. You can process multiple files at once or specific channels of multiple files.

Similar error.

Would you please explain these two issues and let me know how to use it in a right way? Thank you

ferchaure commented 2 years ago

Hi, did you add all to the matlab path with all the sub-folders?

ljylxl commented 2 years ago

addpath('E:\SpikeSorting\WaveClus3\wave_clus-database\Simulator') Hi, I did the "addpath" as shown above. and re "load data"

Error using readInData (line 128) File type '.mat' isn't supported

ferchaure commented 2 years ago

For the installation of waveclus, did you added to the path all the sub-folders of waveclus?

ljylxl commented 2 years ago

addpath('E:\SpikeSorting\WaveClus3\wave_clus-master') This is what I did, do you mean that each sub-folder needs to be added? e.g., 'E:\SpikeSorting\WaveClus3\wave_clus-master\figs' or 'E:\SpikeSorting\WaveClus3\wave_clus-master\SPC'?

ferchaure commented 2 years ago

yes, you can do it easily from a Matlab buttom or using addpath(genpath('E:\SpikeSorting\WaveClus3\wave_clus-master')) Remember to remove the hidden folder .git from wave_clus-master if you do that (otherwise you will add a lot of git folders to your path).

ljylxl commented 2 years ago

OK. it works now. Thank you