Awesome-Python-Scripts/Image_Compressor/Image_Compressor.py
Akshath fdf0ccb570 Revert "Resolving conflict"
This reverts commit a0d4e04a3c.
2023-10-25 10:14:56 +05:30

12 lines
286 B
Python

import PIL
from PIL import Image
from tkinter.filedialog import *
file_path=askopenfilenames()
img = PIL.Image.open(file_path)
myHeight,myWidth = img.size
img=img.resize((myHeight,myWidth),PIL.Image.ANTILIAS)
save_path=asksaveasfile()
img.save(save_path+"_compressed.JPG")