📅  最后修改于: 2022-03-11 14:45:57.743000             🧑  作者: Mango
import PIL
import os
import os.path
from PIL import Image
f = r'c://Users/xx/Desktop/imagetest'
for file in os.listdir(f):
f_img = f+"/"+file
img = Image.open(f_img)
img = img.resize((2296,1724))
img.save(f_img)