os模块 # 作用与文件路径创建文件拼接路径等等 import os 1. os.path.abspath(__file__) # 找到当前执行当前代码文件的文件路径 2.os.path.dirname( os.path.abspath(__file__)) # 找到当前执行文件的父级路径