Page 1 of 1

imagemagick command lines ignoring -limit?

Posted: 2011-02-26T17:03:38-07:00
by icewoman
I ran into problems using convert on large jp2s a shared server. So, I tried to add limits to the command lines. But they seem to be being ignored -- when I run top, I'm seeing res memory take off (to over a gig), and my percentage of use goes up to 22% :(

The following was my first command line, so I ran it from the command line (as opposed to spawning it from my web program).

I tried these:
identify -limit memory 200MiB -limit map 200MiB <filename.jp2>
identify -limit area 10mb <filename.jp2>
identify -limit area 10 <filename.jp2>

I also tried adding the following to my bash_profile & sourced it:
MAGICK_MEMORY_LIMIT=10mb
MAGICK_MAP_LIMIT=10mb

None of these seemed to change the behavior at all.

I compiled ImageMagick myself (without root even!) and included the jasper libraries to support jp2s.
ImageMagick 6.6.3-10 2010-12-18

Help?

Many thanks,

icewoman

Re: imagemagick command lines ignoring -limit?

Posted: 2011-02-26T17:10:03-07:00
by magick
Limits only affect the ImageMagick pixel cache (see http://magick.imagemagick.org/script/ar ... .php#cache). Some delegate libraries (e.g. Jasper, JPEG, TIFF) have their own memory requirements and -limit has no affect on them.

Re: imagemagick command lines ignoring -limit?

Posted: 2011-02-26T18:12:54-07:00
by icewoman
Thanks! Darn that Jasper.

Re: imagemagick command lines ignoring -limit?

Posted: 2011-07-12T10:47:06-07:00
by perlhead
magick wrote:Some delegate libraries (e.g. Jasper, JPEG, TIFF) have their own memory requirements and -limit has no affect on them.
It seems like I'm being bitten by this same issue. Is there any way to alter the behavior of those libraries (in particular, the tiff library)?