Page 1 of 1

Erode Function Memory Limitation

Posted: 2016-07-27T02:55:50-07:00
by AndreaImage
Hi

i'm using ImageMagick to perform the Erode function on a Image
i need to limit the memory used by the process

during erosion process, due to the memory consuption, i can't do anything else (just wait...)

i'm trying to set the policy.xml to use max the 75% of the resource (modifyng the policy.xml file)

but i need some help

my pc has 8Gb of Ram and an HD of 128Gb

Code: Select all

-<policymap>

<!-- <policy domain="resource" name="temporary-path" value="/tmp"/> -->
<!-- <policy domain="resource" name="memory" value="6GiB"/> -->
<!-- <policy domain="resource" name="map" value="6GiB"/> -->
<!-- <policy domain="resource" name="width" value="100MP"/> -->
<!-- <policy domain="resource" name="height" value="100MP"/> -->
<!-- <policy domain="resource" name="area" value="1GB"/> -->
<!-- <policy domain="resource" name="disk" value="16EB"/> -->
<!-- <policy domain="resource" name="file" value="768"/> -->
<!-- <policy domain="resource" name="thread" value="4"/> -->
<!-- <policy domain="resource" name="throttle" value="0"/> -->
<!-- <policy domain="resource" name="time" value="3600"/> -->
<!-- <policy domain="system" name="precision" value="6"/> -->


<policy value="passphrase" name="shared-secret" domain="cache"/>

</policymap>
Someone can suggest which parameter has to be modify?

Thanks

Re: Erode Function Memory Limitation

Posted: 2016-07-27T06:12:56-07:00
by snibgo
I suspect you should un-comment the "memory" and "map" lines, and make both 4GiB or whatever you want.

Re: Erode Function Memory Limitation

Posted: 2016-07-27T08:22:01-07:00
by AndreaImage
thanks

it is working

which is the difference between "map" and "memory"?

thanks again

Re: Erode Function Memory Limitation

Posted: 2016-07-27T08:42:36-07:00
by snibgo
I'm not sure. The architecture document http://www.imagemagick.org/script/architecture.php says:
memory: maximum amount of memory in bytes to allocate for the pixel cache from the heap.

map: maximum amount of memory map in bytes to allocate for the pixel cache.