[Image-SIG] Regarding image compression
jwt at onjapan.net
Tue Aug 4 07:19:15 CEST 2009
On 2009-07-28 02:52, Tejovathi P wrote:
> I have a JPEG image of size 25KB and I want to compress it to 15KB, But
> I want to keep the original height and width same and reduce the size of
> the image. Is there any easy way to achieve this? Please let me know.
You can try adjusting the 'quality' keyword argument of the save()
method to save space.
im = Image.open('original.jpg')
I don't know of a way to hit your 15KB target in a single shot, but
would try various quality settings until your size target is achieved.
More information about the Image-SIG