python路径相关操作 #获取当前文件所在目录filedir = __file__ print os.path.dirname(filedir)#获取文件名print os.path.basename(filedir)