Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

learnAndSolve8b (line 332) - Error using gpuArray/subsref Index exceeds matrix dimension. #24

Closed
JBauto opened this issue Mar 8, 2019 · 4 comments · Fixed by #595
Closed

Comments

@JBauto
Copy link

JBauto commented Mar 8, 2019

Hi,

I'm trying to get Kilosort2 to working using the classic method of scripts. For the chanMap, I'm using the same as in Kilosort1 and the config file with the new changes.

I'm running Kilosort2 as a compiled binary since it's meant to be executed in a cluster. It shouldn't be a problem since it worked fine with Kilosort1.

Here is the output of the crash,

ops =
struct with fields:
chanMap: 'neuropixPhase3A_kilosortChanMap.mat'
fbinary: '/tmp/myRun_g4_t0.imec.ap.bin'
datatype: 'bin'
NchanTOT: 385
fproc: 'temp_wh.dat'
fs: 30000
fshigh: 150
minfr_goodchannels: 0.1000
Th: [10 4]
lam: 10
AUCsplit: 0.9000
minFR: 0.0200
momentum: [20 400]
sigmaMask: 30
ThPre: 8
spkTh: -6
GPU: 1
nfilt_factor: 4
ntbuff: 64
NT: 65600
whiteningRange: 32
nSkipCov: 25
scaleproc: 200
nPCs: 3
useRAM: 0
trange: [0 Inf]

Time 0s. Determining good channels..
found 19227 threshold crossings in 29.04 seconds of data
found 55 bad channels
Time 6s. Computing whitening matrix..
Getting channel whitening matrix...
Channel-whitening filters computed.
Time 48s. Loading raw data and applying filters...
Time 51s. Finished preprocessing 14 batches.
Obtained 7 PC waveforms in 0.79 seconds
time 0.93, pre clustered 1 / 14 batches
time 0.21, compared 1 / 14 batches
time 4.91, Re-ordered 14 batches.
Time 5s. Optimizing templates ...
6.86 sec, 1 / 30 batches, 57 units, nspks: 7.9294, mu: 16.7608, nst0: 110, merges: 0.0000, 0.0000
memorized middle timepoint
reverted back to middle timepoint
Elapsed time is 10.237392 seconds.

ntot =

    9252

Error using gpuArray/subsref
Index exceeds matrix dimension.

Error in learnAndSolve8b (line 332)

Error in kilosort_main (line 78)

parallel:array:SubsrefSubscriptExceedsDim

Any idea on what's causing the error?
Thanks!

@JBauto JBauto changed the title learnAndSolve8b - Error using gpuArray/subsref Index exceeds matrix dimension. learnAndSolve8b (line 332) - Error using gpuArray/subsref Index exceeds matrix dimension. Mar 8, 2019
@marius10p
Copy link
Contributor

Hi, this likely looks like a configuration problem. Did you change NTOT?

We highly recommend starting with the GUI to make sure your data is seen correctly by Kilosort2. The GUI runs the same code, it just allows to see the formatted and pre processed data.

@JBauto
Copy link
Author

JBauto commented Mar 8, 2019

I just grabbed the StandardConfig_MOVEME.m file and added the fbinary, fproc and set NchanTOT to 385.

Running using the GUI with the same binary file and setting probe layout to neuropixPhase3A, it detects automatically 385 and, running everything in the default settings, it crashes in the same place. Preprocessing runs fine and crashes mid Spikesorting.

kilosort2

Let me know if you need anything else. Thanks!!

@marius10p
Copy link
Contributor

Is this on Neuropixels phase 3A data? Do you have the extra 385th channel? I cannot see the data in the data viewer, (there should be spikes there) so something is not working correctly on the configuration side. What software did you use for acquisition? It also looks like a very short recording (28 seconds), is that what you were trying to run?

@JBauto
Copy link
Author

JBauto commented Mar 12, 2019

Yes, its Neuropixels phase 3A data and we have the extra channel. It's a sample file that we use to verify if the compilation process went ok and it served us well with Kilosort1. Using a standard acquisition with Kilosort2 everything runs fine and the output is good.

I guess we can close this issue. Thanks for the help!

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

Successfully merging a pull request may close this issue.

2 participants