Answers for "get path of current executing file python"

2

python get path of current file

import pathlib
pathlib.Path(__file__).parent.absolute()
Posted by: Guest on April-04-2020
0

getting the current executing file's path python

import inspect, os.path

filename = inspect.getframeinfo(inspect.currentframe()).filename
path     = os.path.dirname(os.path.abspath(filename))
Posted by: Guest on July-22-2021

Code answers related to "get path of current executing file python"

Python Answers by Framework

Browse Popular Code Answers by Language