赞
踩
设图片在image文件夹下,path="image/" os.path.join(path)#image/
os.listdir(path)#['0.jpg', '1.jpg'] image下的图片名称列表
[os.path.join(path,f) for f in os.listdir(path) if f.endswith(".jpg")]#['image/0.jpg', 'image/1.jpg']
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。