Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Significant Memory Used for a total of 276 MB Images (559 frames) #6802

Open
Crear12 opened this issue Oct 19, 2023 · 2 comments
Open

Significant Memory Used for a total of 276 MB Images (559 frames) #6802

Crear12 opened this issue Oct 19, 2023 · 2 comments

Comments

@Crear12
Copy link

Crear12 commented Oct 19, 2023

ImageMagick version

7.1.1-15 Q16-HDRI aarch64

Operating system

MacOS

Operating system, version and so on

14.0

Description

I have 559 frames that I want to merge into a GIF file, each frame is less than 500 KB. The total folder size is 276 MB. It immediately eat 64GB of memory and started swapping. When I checked and stopped it, it used nearly 1 TBW for swapping.

Steps to Reproduce

I executed magick convert -delay 10 -loop 0 *.png LowH.gif to generate the GIF, it never finished and keeps swapping the memory for nearly 1TB written.

Images

Screenshot 2023-10-18 at 23 47 24 Screenshot 2023-10-18 at 23 47 59
@fmw42
Copy link

fmw42 commented Oct 19, 2023

It is not the file size that counts. Imagemagick has to decompress any compressed files when reading. It is the number of pixels in the image that determines how much space is used 8-bits per channel per pixel. So if for example you started with JPG files, they have to be decompressed a lot. If you start with PNG, even those have to be decompressed, which is what your command uses.

Note on IM 7, use magick, not magick convert (nor just convert).

@urban-warrior
Copy link
Member

Review https://imagemagick.org/script/architecture.php#tera-pixel for recommended practice when processing large images or large image sequences.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

3 participants