Answers for "PIL rotate image"

0

PIL rotate image

img = Image.open(r"C:\Users\Admin\Pictures\network.PNG")
  
# rotating a image 90 deg counter clockwise
rot_img = img.rotate(90, PIL.Image.NEAREST, expand = 1)
Posted by: Guest on July-11-2021
5

pil crop image

im = Image.open('image.jpg') 
im = im.crop((left, top, right, bottom))  # coordinates of the crop
Posted by: Guest on October-17-2020
2

pil resize image

im = Image.open('image.jpg')  
im = im.resize((w, h))
Posted by: Guest on October-17-2020

Python Answers by Framework

Browse Popular Code Answers by Language