需求:统计图像数据集下图像分辨率的分布情况,以便将图像在输入到模型之前裁剪到合适的大小 待统计的图像数据:(位于./lid/下) 代码: import os import pandas as pd from PIL import Image from collections import Counter source = './lid/' imgfile = os.listdir(source) shot_cut = [