print image

This commit is contained in:
Martin Quarda 2024-05-09 17:12:34 +02:00
parent 3f5e2e93a3
commit 58a72782d6

View File

@ -4,6 +4,7 @@ import PIL.Image
photos = glob.glob('photos/*.jpg')
for image in photos:
print(image)
img = PIL.Image.open(image)
img.save(image.replace('.jpg', '.webp'))
ratio = 200/max(img.height, img.width)