Closed enomis-dev closed 3 months ago
Does Image.reduce
work?
So the Image.reduce
code to scale an image down by half would be
from PIL import Image
with Image.open("/Tests/images/hopper.png") as im:
reduced_image = im.reduce(2)
Nice, thank you for answer, reduce does exactly that! I'll close the isssue.
Hi! Often working with images it is common to specify the scale factor to downsample/upsample the images preserving the aspect ratio. I was wondering if it could be possible to include a scale factor as input param of the resize method.
Today I achieve this by doing the following:
Perhaps, it could be interesting to have this directly inside the resize method. I leave a simple PR in case you like the addition. Wdyt?