Number of concurrent convert processes Number of concurrent convert processes
 

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Main Menu

Number of concurrent convert processes

Started by hannes, August 18, 2004, 07:39:53 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

hannes

Hello

I have been searching through the documentation and the forum seeking for any possibilities to set the number of convert (ImageMagick) processes that are forked during the batch import process. My understanding is so that during import, 4-5 convert processes are created and 4-5 pictures are resized simultaniously. I haven't been able to find anything about this so I wan't to ask if this could be set somewere?

The reason I'm asking is that I've had some problems with Coppermine when importing my big pictures (~3MB JPEGs) when 4 or 5 convert processes are created at the same time, eating up my memory and leaving my machine dead slow in heavy swapping! Even on my 1GHz machine with 360 MB RAM.

kegobeer

File size isn't so much an issue as the number of pixels being manipulated.  Memory needed is calculated like this:

pixel width X pixel height X color base (RGB=3, CMYK=4)

Assuming RGB for the color base, here's memory needed for some common image sizes:

800 x 600 - 1.37 MB
1024 x 768 - 2.25 MB
1200 x 1600 - 5.49 MB

So, let's say you are batch adding 5 images, each one 1200 x 1600, using ImageMagick.  5 processes started, 5 simultaneous resize operations, each resize needed about 5.5 MB of memory....you can see why your machine bogs down.

Remember, you don't actually have 360 MB of RAM for your use: your OS eats up a bunch, other running processes need a bunch, etc.
Do not send me a private message unless I ask for one.  Make your post public so everyone can benefit.

There are no stupid questions
But there are a LOT of inquisitive idiots

Joachim Müller

it's one of the drawbacks of ImageMagick: it starts simultaneous processes when batch-adding files. GD behaves nicer and does one at a time (because it's closer integrated into PHP). I'm sorry to say, but the only solutions for your issue are: either use GD instead of ImageMagick, or batch-add less pics in one go.

GauGau

hannes

Thanks for your quick reply! My pictures are 3008x2000 pix, that gives something like 18 MB per picture. Then resizing 5 picts at one go eats up something like 90 MB! I can see why I've problems :) 

That's although strange that the number of processes cannot be set in one of ImageMagick's config files!?

I'll try GD and see how that'll work.

Thanks again!