PIL resize

发布时间 2023-04-23 21:11:55作者: 西北逍遥

PIL resize

 

from PIL import Image

# Open the image
img = Image.open("20230222100736979.jpg")

# Resize the image
img = img.resize((img.width*2, img.height*2), resample=Image.BICUBIC)

# Save the modified image
img.save("20230222100736979_2.jpg")

  

 

#####################