I sometimes get the following error message when I'm running CMC:
java.lang.OutOfMemoryError: Java heap space
Is there anything I can do to stop this from happening?
Thanks
Out of memory error
- Ayman Habib
- Posts: 2244
- Joined: Fri Apr 01, 2005 12:24 pm
RE: Out of memory error
Hi Moe,
Due to very fine sampling while running CMC, this can happen. One solution is to increase the heap-size used by the GUI (which I can explain if you're interested), but another possible solution that reduces the memory requirements significantly is to run CMC from the command line (as in cmc -S setup_file.xml).
Please check the user guide for details if you haven't done that before and let us know if you have any questions.
Good luck,
-Ayman
Due to very fine sampling while running CMC, this can happen. One solution is to increase the heap-size used by the GUI (which I can explain if you're interested), but another possible solution that reduces the memory requirements significantly is to run CMC from the command line (as in cmc -S setup_file.xml).
Please check the user guide for details if you haven't done that before and let us know if you have any questions.
Good luck,
-Ayman
- Chris Zirker
- Posts: 44
- Joined: Tue Mar 03, 2009 11:09 am
RE: Out of memory error
I get heap memory errors regularly when using the plot tools (I use it to export data sometimes and make very large plots). I would be very interested to know how to increase the heap size used by the GUI.
- Ayman Habib
- Posts: 2244
- Joined: Fri Apr 01, 2005 12:24 pm
RE: Out of memory error
Hi Chris,
In the file etc/opensim.conf you can modify the command line options given on the line:
default_options="-J-Xms24m -J-Xmx64m ...."
Try changing this line to
default_options="-J-Xms48m -J-Xmx128m ...."
or something similar depending on your machine.
-Ayman
In the file etc/opensim.conf you can modify the command line options given on the line:
default_options="-J-Xms24m -J-Xmx64m ...."
Try changing this line to
default_options="-J-Xms48m -J-Xmx128m ...."
or something similar depending on your machine.
-Ayman
- Moe Curtin
- Posts: 43
- Joined: Fri Oct 02, 2009 5:40 am
RE: Out of memory error
Thanks a million Ayman!
- Stefan Schaffelhofer
- Posts: 1
- Joined: Thu Mar 29, 2012 4:37 pm
Re: Out of memory error
Dear Ayman,
I also get the same "out of memory error" when I run IK with the GUI. Are the changes of the opensim.conf affecting the IK running the GUI or from the command line? Could you tell a bit more about the heap size? What is it's maximum value?
You mentioned fine sampling rates could cause this problem. I'm using a sampling rate of 50 Hz over 4000 seconds (200000 samples). After 7% of processing the simulation I get this error. Is there a limited length of the TRC-file or a critical sampling rate?
I would be greatful to receive an answer.
Thanks -Stefan
I also get the same "out of memory error" when I run IK with the GUI. Are the changes of the opensim.conf affecting the IK running the GUI or from the command line? Could you tell a bit more about the heap size? What is it's maximum value?
You mentioned fine sampling rates could cause this problem. I'm using a sampling rate of 50 Hz over 4000 seconds (200000 samples). After 7% of processing the simulation I get this error. Is there a limited length of the TRC-file or a critical sampling rate?
I would be greatful to receive an answer.
Thanks -Stefan