Error using load_bcidat in MATLAB

Post Reply
epacheco
Posts: 7
Joined: 13 Mar 2023, 12:09

Error using load_bcidat in MATLAB

Post by epacheco » 15 Mar 2023, 00:55

Hello everyone,
I'm getting used to BCI2000 and all the readings I can load/read/use, etc. I've just learned to use the OfflineAnalysis and the [signal, parameters, stares] = load_bcidat function in MATLAB and I have a problem.
I know that I have to select the path of the file so MATLAB can read it, as well as to add the path of the functions and OfflineAnalysis, but I'm getting this error message in the command window: Unhandled exception of type util::detail::legacy_bad_alloc_impl: Out of memory.

I don't know if this is because of a bad recording or an error in the saving of the file or if the number of channels have something to do with it, or something with BCI/MATLAB but I don´t know what to do.
Hope someone can help me.

Thanks
Attachments
ERROR SHOWN IN MATLAB
ERROR SHOWN IN MATLAB
Captura.JPG (18.46 KiB) Viewed 11230 times

mellinger
Posts: 1210
Joined: 12 Feb 2003, 11:06

Re: Error using load_bcidat in MATLAB

Post by mellinger » 15 Mar 2023, 10:40

This is a Matlab exception that indicates that no memory could be allocated for the signal data in your file.
Within Matlab, a file requires a little bit more memory than its size on disk. With a 32 bit version of Matlab, the maximum file size that load_bcidat() can read is about 1.5GB.

You may get information about your Matlab version by typing "computer" into the Matlab prompt.

HTH
Jürgen

epacheco
Posts: 7
Joined: 13 Mar 2023, 12:09

Re: Error using load_bcidat in MATLAB

Post by epacheco » 15 Mar 2023, 18:02

Today I changed from computer to an older one and it worked. I'm running the program in MATLAB 2017 with BCI 3.05 version and it does not show the error out of memory. But when I try to run it in a newer version, the error is shown.
My PC, which shows the error, has MATLAB 2022a and BCI 3.05.6143. Also, I have plenty of memory, 500+ GB in my SSD, and 6+GB of RAM.

The files are 15,375 KB and 6,748 KB and the error is shown when I load the second one. As I wrote on top, in an older version of Matlab and BCI, I can use the function load_bcidat with both files.

mellinger
Posts: 1210
Joined: 12 Feb 2003, 11:06

Re: Error using load_bcidat in MATLAB

Post by mellinger » 16 Mar 2023, 12:46

Thanks for the information.
We are currently working on a new BCI2000 installer.

Post Reply

Who is online

Users browsing this forum: Google [Bot] and 15 guests