#!/usr/bin/env python
# -*- coding: utf-8 -*-
from PIL import Image
import os
def getImgSize():
imgPath = "/home/siyin/ownCloud/小游戏/设计/填色小游戏/测试素材库/"
savaPath = "/home/siyin/ownCloud/小游戏/设计/填色小游戏/测试素材库/大图片"
listdir = (os.listdir(imgPath))
fileSizeList = []
for dir in listdir:
print dir
basePath = (imgPath + dir)
fileList = os.listdir(basePath)
for file in fileList:
fileSize = os.path.getsize(basePath + "/" + file)
fileSize/1024
print listdir
if __name__ == "__main__":
getImgSize()