MiseryBot
Posts: 4
Joined: Thu Mar 28, 2013 5:14 pm

Crash with "bad allocation": Is there a memory leak?

Thu Mar 28, 2013 7:20 pm

Crash with "bad allocation": Is there a memory leak?

Twice I have tried to print "Hyperboloid with base, desktop pen holder":
http://www.thingiverse.com/thing:7957

The first time, it go to 17mm. The second time I attempted to print it with "Robust lead screw and thrust collar for InMoov bicep":
http://www.thingiverse.com/thing:64410

This time it only got to 6.5mm:
Image

Here is a screen cap of the crash window:
http://ftp.hostedftp.com/~baxsie/forum/ ... cation.png

Task Manager shows ~1.3 GB allocated to S3DCreator.exe:
Image

There is 4GB in the machine, with 2GB free:
Image

I am thinking it must be some kind of a memory leak ?

Here is a zip of the .gcode file I was trying to print:
http://ftp.hostedftp.com/~baxsie/forum/ ... triple.zip
"I'm not getting older, I'm getting bitter."

Simplify3D
Site Admin
Posts: 304
Joined: Sun Feb 10, 2013 8:28 pm

Re: Crash with "bad allocation": Is there a memory leak?

Fri Mar 29, 2013 7:49 pm

MiseryBot,

Just so you know, the bad allocation error is essentially an out of memory issue. This can definitely be an issue with extremely large and complex models if the OS doesn't have enough spare memory. If you think about it, you have to render the complex mesh on screen, then render a very intensive preview simulation, and also load most of the gcode file into memory for uploading to the machine. Creator does a great job at doing all this multitasking as fast as possible, but that's still a lot of memory! We have made a consistent effort to minimize this as much as possible, but it can definitely pop up depending on the size of files you are working with and what hardware you're running on.

I looked at the STL you are working with and it creates a pretty large gcode file when sliced. It's made up of almost completely circles so it takes thousands of tiny lines to model it. For files of this size I would definitely suggest printing the gcode directly from the SD card. We're still working on making our USB communication a little more robust, so printing from the SD card will avoid any chance of the build stopping midway like it did here.

We'll get it fixed, but the SD card is definitely safer for now (and gives better quality anyways since there's less overhead!)

MiseryBot
Posts: 4
Joined: Thu Mar 28, 2013 5:14 pm

Re: Crash with "bad allocation": Is there a memory leak?

Sat Mar 30, 2013 12:41 pm

Is there a way to unload the "complex mesh on screen" and "very intensive preview simulation" and only have the "shovel the bits from gcode file to the printer" going?

I still wonder if there is a memory leak issue. The memory used climbs up during printing, even though the preview and simulation windows are idle.
"I'm not getting older, I'm getting bitter."

Simplify3D
Site Admin
Posts: 304
Joined: Sun Feb 10, 2013 8:28 pm

Re: Crash with "bad allocation": Is there a memory leak?

Sun Mar 31, 2013 8:12 am

Well the best way to do that is to simply print directly from the SD card ;) That is always a more reliable approach and doesn't rely on your CPU for all the constant communication back and forth.

We did make a few changes in version 1.0.6 that will help with this problem some. We will continue to look for ways to improve the memory footprint, but when you're dealing with massively complex models and huge gcode files, it's going to be hard to avoid. For your original question, if you stop the preview and delete the imported model, that should remove the memory associated with those tasks. But again, I suggest printing the file from the SD card if you're having issues with these big models.

Hope that helps!

Return to “Troubleshooting and Bug Reports”