PILのCMYKtif画像でのみ問題が発生します。問題は、すべてが順調に進んでいるように見えることです。ファイルを読み込んで保存できますが、切り抜いて保存しようとすると、python.exeがハングします。これが私のセッションの大まかな記録です:
>>> import os
>>> from PIL import Image
>>> os.listdir(".")
['CMYK_TIFF.tif', 'GRAYSCALE_TIFF.tif', 'RGB_TIFF.tif']
>>> im = Image.open("CMYK_TIFF.tif")
>>> im
<PIL.TiffImagePlugin.TiffImageFile image mode=CMYK size=4320x3240 at 0x2630B88>
>>> points = (12, 3, 44, 88)
>>> im = im.crop(points)
>>> im
<PIL.Image._ImageCrop image mode=CMYK size=32x85 at 02630B48>
>>> im.save("new_image.tif")
この時点で、python.exeがクラッシュします。これは孤立した問題ではなく、この時点で一貫して発生します。
どんな助けでも大歓迎です!
PD:Windows 7x64OSでPython2.7.3とPIL1.1.7を使用しています。
PD2:Pythonクラッシュダンプ:
Descripción (description)
Ruta de acceso de la aplicación con errores (filepath to the application with errors): C:\Python27\python.exe
Firma del problema (problem signature)
Nombre de evento de problema (name of the event or problem): APPCRASH
Nombre de la aplicación (application name): python.exe
Versión de la aplicación (aplication version): 0.0.0.0
Marca de tiempo de la aplicación (timestamp): 4f84a524
Nombre del módulo con errores (Name of the module with errors): MSVCR90.dll
Versión del módulo con errores (version of the module with errors): 9.0.30729.6161
Marca de tiempo del módulo con errores (module timestamp): 4dace4e7
Código de excepción (exception code): c0000005
Desplazamiento de excepción (exception displacement): 000000000001e2e0
Versión del sistema operativo (OS version): 6.1.7601.2.1.0.256.48
Id. de configuración regional (regional configuration id): 11274
Información adicional 1: 3312
Información adicional 2: 3312c03e983672d704c6ef8ee1696a00
Información adicional 3: b29d
Información adicional 4: b29dcc8fc6f4d939931d139c4d9e8d31
Información adicional sobre el problema
Id. de depósito: 67567272