1. NodeBox 1
    1. Homepage
    2. NodeBox 3Node-based app for generative design and data visualization
    3. NodeBox OpenGLHardware-accelerated cross-platform graphics library
    4. NodeBox 1Generate 2D visuals using Python code (Mac OS X only)
  2. Gallery
  3. Documentation
  4. Forum
  5. Blog

crash when generating multiple pages

Posted by Julian. on Sep 13, 2011

Hi there,

I'm currently struggling with a NodeBox script, which is crashing when generating more than a certain amount of images. The script reads a textfile, that lists 100.000 images and then arranges 600 of them in a grid. I'm iterating with PAGENUM, no problem there. But after 40-50 images one of the following errors occur:

NodeBox[24616]	NodeBox Error
An unexpected error has occurred during execution of the main script
AttributeError: 'NoneType' object has no attribute 'representationUsingType_properties_'
or
NodeBox[24690]	*** -[NSAutoreleasePool release]: This pool has already been released, do not drain it (double release).
reading in Console
[0x0-0x17e47e3].net.nodebox.NodeBox[24690]	MemoryError: NSMallocException - Attempt to allocate 16777216 bytes for NS/CFData failed
and when starting to generate multiple images
NodeBox[24749]	*** -[NSAutoreleasePool release]: This pool has already been released, do not drain it (double release).
Any idea how to analyze this problem or getting to the bottom of it?

All the best, Julian.


 
Posted by Karsten Wolf on Sep 14, 2011

You most probably ran out of memory. Nodebox runs in 32-bit and has a 4GB limit. IIRC CoreImage has a memory leak in Nodebox.

Look at Nodebox running either with top in Terminal or with the Activity Monitor app. If your machine has less than 4GB RAM you'll notice a sluggish performance after it runs some time because memory is paged out.

This line gives it
NSMallocException - Attempt to allocate 16777216 bytes for NS/CFData failed

-karsten