读取文件夹里的文件路径 import os # 父文件夹/5个子文件夹/n个文件 path = '/Users/Desktop/CEC' root = os.listdir(path) # 采用listdir来读取所有文件 subFilesPath = [] filePath = [] for file_ in root: if os.