1
0
mirror of https://github.com/ciromattia/kcc synced 2026-06-23 23:04:14 +00:00

fix truncated file read (#1133)

This commit is contained in:
Alex Xu
2025-10-21 20:41:18 -07:00
committed by GitHub
parent fb9b3c676b
commit 2d288f72ea
5 changed files with 15 additions and 5 deletions
+3 -1
View File
@@ -1,8 +1,10 @@
from PIL import Image, ImageFilter, ImageOps
from PIL import Image, ImageFilter, ImageOps, ImageFile
import numpy as np
from typing import Literal
from .common_crop import threshold_from_power, group_close_values
ImageFile.LOAD_TRUNCATED_IMAGES = True
'''
Crops inter-panel empty spaces (ignores empty spaces near borders - for that use crop margins).