Skip to content

The parameter “compress_level” is invalid for the APNG file extension #9299

@petercham

Description

@petercham
--------------------------------------------------------------------
Pillow 12.0.0
Python 3.12.10 | packaged by conda-forge | (main, Apr 10 2025, 22:08:16) [MSC v.1943 64 bit (AMD64)]
--------------------------------------------------------------------
Python executable is C:\Work\SD-ComfyUI\python_comfy_env\python.exe
System Python files loaded from C:\Work\SD-ComfyUI\python_comfy_env
--------------------------------------------------------------------
Python Pillow modules loaded from C:\Work\SD-ComfyUI\python_comfy_env\Lib\site-packages\PIL
Binary Pillow modules loaded from C:\Work\SD-ComfyUI\python_comfy_env\Lib\site-packages\PIL
--------------------------------------------------------------------
--- PIL CORE support ok, compiled for 12.0.0
--- TKINTER support ok, loaded 8.6
--- FREETYPE2 support ok, loaded 2.14.1
--- LITTLECMS2 support ok, loaded 2.17
--- WEBP support ok, loaded 1.6.0
--- AVIF support ok, loaded 1.3.0
--- JPEG support ok, compiled for libjpeg-turbo 3.1.2
--- OPENJPEG (JPEG2000) support ok, loaded 2.5.4
--- ZLIB (PNG/ZIP) support ok, loaded 1.3.1.zlib-ng, compiled for zlib-ng 2.2.5
--- LIBTIFF support ok, loaded 4.7.1
*** RAQM (Bidirectional Text) support not installed
*** LIBIMAGEQUANT (Quantization method) support not installed
*** XCB (X protocol) support not installed
--------------------------------------------------------------------
✅ Loaded color image: (257, 293), RGBA
✅ Loaded BW image: (257, 293), RGBA

🔧 Testing PNG format...
✅ PNG: 8/8 tests passed

🔧 Testing GIF format...
✅ GIF: 8/8 tests passed

🔧 Testing WEBP_LOSSY format...
✅ WEBP_LOSSY: 8/8 tests passed

🔧 Testing WEBP_LOSSLESS format...
✅ WEBP_LOSSLESS: 8/8 tests passed

🔧 Testing TIFF format...
✅ TIFF: 8/8 tests passed

🔧 Testing AVIF format...
✅ AVIF: 8/8 tests passed

📊 RESULTS SUMMARY:

PNG single frame:
  9: 50.5KB, Time: 0.019s, PSNR: ∞dB, MSE: 0.00
  6: 53.0KB, Time: 0.005s, PSNR: ∞dB, MSE: 0.00
  3: 56.9KB, Time: 0.003s, PSNR: ∞dB, MSE: 0.00
  0: 294.6KB, Time: 0.002s, PSNR: ∞dB, MSE: 0.00

PNG 10 frames:
  9: 417.4KB, Time: 0.044s, PSNR: ∞dB, MSE: 0.00
  6: 417.4KB, Time: 0.045s, PSNR: ∞dB, MSE: 0.00
  3: 417.4KB, Time: 0.045s, PSNR: ∞dB, MSE: 0.00
  0: 417.4KB, Time: 0.043s, PSNR: ∞dB, MSE: 0.00

GIF single frame:
  32: 12.4KB, Time: 0.002s, PSNR: 33.0dB, MSE: 32.43
  64: 16.3KB, Time: 0.001s, PSNR: 35.8dB, MSE: 16.97
  128: 16.9KB, Time: 0.002s, PSNR: 36.1dB, MSE: 15.82
  256: 17.3KB, Time: 0.002s, PSNR: 36.1dB, MSE: 15.81

GIF 10 frames:
  32: 120.5KB, Time: 0.026s, PSNR: 33.0dB, MSE: 32.43
  64: 123.6KB, Time: 0.027s, PSNR: 35.8dB, MSE: 16.97
  128: 124.2KB, Time: 0.027s, PSNR: 36.1dB, MSE: 15.82
  256: 124.6KB, Time: 0.028s, PSNR: 36.1dB, MSE: 15.81

WEBP_LOSSY single frame:
  25: 2.9KB, Time: 0.009s, PSNR: 36.4dB, MSE: 15.02
  55: 3.8KB, Time: 0.010s, PSNR: 38.1dB, MSE: 10.03
  85: 5.4KB, Time: 0.010s, PSNR: 43.8dB, MSE: 2.74
  100: 11.1KB, Time: 0.013s, PSNR: 47.7dB, MSE: 1.09

WEBP_LOSSY 10 frames:
  25: 36.7KB, Time: 0.024s, PSNR: 36.3dB, MSE: 15.37
  55: 68.1KB, Time: 0.031s, PSNR: 38.3dB, MSE: 9.61
  85: 77.3KB, Time: 0.033s, PSNR: 43.5dB, MSE: 2.91
  100: 156.8KB, Time: 0.042s, PSNR: 47.5dB, MSE: 1.16

WEBP_LOSSLESS single frame:
  0: 36.4KB, Time: 0.043s, PSNR: 52.8dB, MSE: 0.34
  33: 35.1KB, Time: 0.063s, PSNR: 52.8dB, MSE: 0.34
  67: 35.2KB, Time: 0.071s, PSNR: 52.8dB, MSE: 0.34
  100: 34.5KB, Time: 0.145s, PSNR: 52.8dB, MSE: 0.34

WEBP_LOSSLESS 10 frames:
  0: 316.2KB, Time: 0.027s, PSNR: 52.1dB, MSE: 0.40
  33: 311.8KB, Time: 0.031s, PSNR: 52.1dB, MSE: 0.40
  67: 307.4KB, Time: 0.047s, PSNR: 52.1dB, MSE: 0.40
  100: 304.5KB, Time: 0.069s, PSNR: 52.1dB, MSE: 0.40

TIFF single frame:
  lzma: 57.6KB, Time: 0.036s, PSNR: ∞dB, MSE: 0.00
  tiff_adobe_deflate: 69.8KB, Time: 0.002s, PSNR: ∞dB, MSE: 0.00
  tiff_lzw: 146.6KB, Time: 0.002s, PSNR: ∞dB, MSE: 0.00
  none: 294.3KB, Time: 0.001s, PSNR: ∞dB, MSE: 0.00

TIFF 10 frames:
  lzma: 444.1KB, Time: 0.358s, PSNR: ∞dB, MSE: 0.00
  tiff_adobe_deflate: 559.4KB, Time: 0.023s, PSNR: ∞dB, MSE: 0.00
  tiff_lzw: 1179.7KB, Time: 0.019s, PSNR: ∞dB, MSE: 0.00
  none: 2943.3KB, Time: 0.004s, PSNR: ∞dB, MSE: 0.00

AVIF single frame:
  25: 1.7KB, Time: 0.026s, PSNR: 34.8dB, MSE: 21.31
  55: 3.4KB, Time: 0.028s, PSNR: 39.8dB, MSE: 6.81
  85: 6.8KB, Time: 0.024s, PSNR: 44.2dB, MSE: 2.46
  100: 22.7KB, Time: 0.038s, PSNR: 47.5dB, MSE: 1.15

AVIF 10 frames:
  25: 7.0KB, Time: 0.106s, PSNR: 41.6dB, MSE: 4.49
  55: 10.8KB, Time: 0.097s, PSNR: 45.0dB, MSE: 2.06
  85: 22.3KB, Time: 0.112s, PSNR: 47.0dB, MSE: 1.29
  100: 40.2KB, Time: 0.119s, PSNR: 47.5dB, MSE: 1.15

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions