using multiple CPU/cores

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
yeupou
Posts: 1
Joined: 2012-05-18T04:43:31-07:00
Authentication code: 13

using multiple CPU/cores

Post by yeupou »

Hello,

$ convert --version
Version: ImageMagick 6.7.4-0 2012-04-16 Q16 http://www.imagemagick.org
Copyright: Copyright (C) 1999-2011 ImageMagick Studio LLC
Features: OpenMP

I'm using convert to build animated GIF (yeah, I know, kind of 1990's). This work fine except that I'm using a multicore computer and seems to me it goes slower than it should:
- only one core appeared to be used, at 100%
- the CPU frequency is not at it's maximum

I did `export MAGICK_THREAD_LIMIT=4` beforehand, it did not help.

I searched on the website. Maybe I missed something obvious, is there any pointer ?

(I found viewtopic.php?f=1&t=9104&start=0 unconclusive)
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: using multiple CPU/cores

Post by fmw42 »

depending upon the machine and operation you want to do, sometimes turning off OpenMP (or set the threads to 1) will work faster that with multiple threads.
User avatar
anthony
Posts: 8883
Joined: 2004-05-31T19:27:03-07:00
Authentication code: 8675308
Location: Brisbane, Australia

Re: using multiple CPU/cores

Post by anthony »

GIF is also a very hard format to generate as it has VERY limited colors.

See IM Examples, Color Optimizations
http://www.imagemagick.org/Usage/anim_opt/#color_opt

Also see Video to GIF for a specific example of the problems faced.
http://www.imagemagick.org/Usage/video/#gif
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
Post Reply