Unable to convert large files from SD card: Out of Memory Error
in Software
I'm trying to open a large file I recorded on the SD card during an 8 hours of sleep. In order to translate the file I know I have to open the OpenBCI GUI within processing, which works fine. I go through the steps (playback from file -- convert SD for playback), but when I select my file, I fairly quickly get the error pasted below. I went to the processing prefs and changed the "increase maximum available memory" from 256 to 1600, but it makes no difference. I HAVE succeeded in translating and opening a very small test file (maybe 5 minutes of data), so the problem seems to be simply file size. In the folder where the translated versions end up I do see files from my attempts to translate... but they are all 7.6mb. So it is as if the process starts fine, but conks out after a mere 7.6mb. Any idea of how I can fix this, or is the OpenBCI software just not suitable for large, long sleep-data files? (like, 700-800mb)?
Thanks in advance!
Here's the error
java.lang.RuntimeException: java.lang.OutOfMemoryError: Java heap space
at processing.opengl.PSurfaceJOGL$2.run(PSurfaceJOGL.java:412)
at java.lang.Thread.run(Thread.java:748)
Caused by: java.lang.OutOfMemoryError: Java heap space
at java.util.Arrays.copyOfRange(Arrays.java:3664)
at java.lang.StringBuffer.toString(StringBuffer.java:669)
at java.io.BufferedReader.readLine(BufferedReader.java:327)
at java.io.BufferedReader.readLine(BufferedReader.java:389)
at OpenBCI_GUI.convertSDFile(OpenBCI_GUI.java:7396)
at OpenBCI_GUI$ControlPanel.update(OpenBCI_GUI.java:3087)
at OpenBCI_GUI.systemUpdate(OpenBCI_GUI.java:1024)
at OpenBCI_GUI.draw(OpenBCI_GUI.java:485)
at processing.core.PApplet.handleDraw(PApplet.java:2437)
at processing.opengl.PSurfaceJOGL$DrawListener.display(PSurfaceJOGL.java:859)
at jogamp.opengl.GLDrawableHelper.displayImpl(GLDrawableHelper.java:692)
at jogamp.opengl.GLDrawableHelper.display(GLDrawableHelper.java:674)
at jogamp.opengl.GLAutoDrawableBase$2.run(GLAutoDrawableBase.java:443)
at jogamp.opengl.GLDrawableHelper.invokeGLImpl(GLDrawableHelper.java:1293)
at jogamp.opengl.GLDrawableHelper.invokeGL(GLDrawableHelper.java:1147)
at com.jogamp.newt.opengl.GLWindow.display(GLWindow.java:759)
at com.jogamp.opengl.util.AWTAnimatorImpl.display(AWTAnimatorImpl.java:81)
at com.jogamp.opengl.util.AnimatorBase.display(AnimatorBase.java:452)
at com.jogamp.opengl.util.FPSAnimator$MainTask.run(FPSAnimator.java:178)
at java.util.TimerThread.mainLoop(Timer.java:555)
at java.util.TimerThread.run(Timer.java:505)
Comments
I don't know if you resolved your problem to convert and/or play long EEG recording like sleep recording (8 hours) and manage file up to 800Mo.
In fact i succeed (after several failed attempts) by increasing the memory allocated in processing 3: you find it in file/preferences.
I increase the amount of Mo until it works and I can now say that to play a 12hours EEG recording (one channel; 250Hz) you have to set it at : 16 384MB !!!!!
but it works now !!!! this soft is really great ! (at least on a dell workstation with 16Go RAM !!)
Xav