Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw

Re: Re: Re: Perl::Magick maxes my systems processor usage

by BrowserUk (Patriarch)
on May 08, 2003 at 20:47 UTC ( #256677=note: print w/replies, xml ) Need Help??

in reply to Re: Re: Perl::Magick maxes my systems processor usage
in thread Perl::Magick maxes my systems processor usage

I can't really comment as I gave up trying to get Image::Magik going on my machine after 3 attempts. I rarely have the need to automate image stuff, and have (what I consider) to be superior tools available for doing this sort of thing manually.

(If you've never seen the performance and tightness of the Xara graphics tools, particularly Xara X, take a look, they have free demos available for download. Note:Just a very satisfied user. No commercial or personal relationships with the company.)

Anyway, my speculation would be that at some point, the image matrices in Image::Magic are stored and manipulated using perl array's, possibly they are expanded on demand rather than preallocated and it is the repeated, incremental increase in the size of these arrays that is responsible for the memory (TIFFs can be very memory hungry) consumption, and consequently the cpu consumption.

Manipulating large, but relatively static chunks of binary image data is one of the few applications where perl's arrays aren't really of benefit.

Examine what is said, not who speaks.
"Efficiency is intelligent laziness." -David Dunham
"When I'm working on a problem, I never think about beauty. I think only how to solve the problem. But when I have finished, if the solution is not beautiful, I know it is wrong." -Richard Buckminster Fuller
  • Comment on Re: Re: Re: Perl::Magick maxes my systems processor usage

Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://256677]
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others cooling their heels in the Monastery: (4)
As of 2023-12-02 04:47 GMT
Find Nodes?
    Voting Booth?
    What's your preferred 'use VERSION' for new CPAN modules in 2023?

    Results (13 votes). Check out past polls.