New image and color management library for Python 2+3

Jan Riechers janpeterr at freenet.de
Sun Aug 19 13:35:54 EDT 2012


On 14.08.2012 21:22, Christian Heimes wrote:
> Hello fellow Pythonistas,
>
>
> Performance
> ===========
>
> smc.freeimage with libjpeg-turbo read JPEGs about three to six times
> faster than PIL and writes JPEGs more than five times faster.
>
[....]
>
> Python 2.7.3
> read / write cycles: 300
> test image: 1210x1778 24bpp JPEG (pon.jpg)
> platform: Ubuntu 12.04 X86_64
> hardware: Intel Xeon hexacore W3680 at 3.33GHz with 24 GB RAM
>
> smc.freeimage, FreeImage 3.15.3 standard
>   - read JPEG 12.857 sec
>   - read JPEG 6.629 sec (resaved)
>   - write JPEG 21.817 sec
> smc.freeimage, FreeImage 3.15.3 with jpeg turbo
>   - read JPEG 9.297 sec
>   - read JPEG 3.909 sec (resaved)
>   - write JPEG 5.857 sec
>   - read LZW TIFF 17.947 sec
>   - read biton G4 TIFF 2.068 sec
>   - resize 3.850 sec (box)
>   - resize 5.022 sec (bilinear)
>   - resize 7.942 sec (bspline)
>   - resize 7.222 sec (bicubic)
>   - resize 7.941 sec (catmull rom spline)
>   - resize 10.232 sec (lanczos3)
>   - tiff numpy.asarray() with bytescale() 0.006 sec
>   - tiff load + numpy.asarray() with bytescale() 18.043 sec
> PIL 1.1.7
>   - read JPEG 30.389 sec
>   - read JPEG 23.118 sec (resaved)
>   - write JPEG 34.405 sec
>   - read LZW TIFF 21.596 sec
>   - read biton G4 TIFF: decoder group4 not available
>   - resize 0.032 sec (nearest)
>   - resize 1.074 sec (bilinear)
>   - resize 2.924 sec (bicubic)
>   - resize 8.056 sec (antialias)
>   - tiff scipy fromimage() with bytescale() 1.165 sec
>   - tiff scipy imread() with bytescale() 22.939 sec
>
>
>
> Christian
>

Hello Christian,

I'm sorry for getting out of your initial question/request, but did you 
try out ImageMagick before making use of FreeImage - do you even perhaps 
can deliver a comparison between your project and ImageMagick (if 
regular Python is used)?

I ask cause:
Im in the process of creating a web-app which also requires image 
processing and just switching from PIL (because it is unfortunately not 
that quick as it should be) to ImageMagick and the speeds are much 
better compared to it, but I didn't take measurements of that.

Can you perhaps test your solution with ImageMagick (as it is used 
widely) it would be interesting so. :)

But no offence by that and respect for you work so!

Jan



More information about the Python-list mailing list