9951 explained code solutions for 126 technologies


python-pillowHow to convert PNG to JPG


from PIL import Image

im = Image.open('image.png')
im.save('image.jpg')ctrl + c
PIL

import Pillow package modules

Image.open

open given image with Pillow

.save(

saves image under given path (format is automatically picked based on file extension)