Answers for "get location using python"

11

python get current file location

import os
os.path.dirname(os.path.abspath(__file__))
Posted by: Guest on May-11-2020
0

find location of a class in python

import sys, os
os.path.abspath(sys.modules[LocationArtifact.__module__].__file__)
Posted by: Guest on November-20-2020

Code answers related to "get location using python"

Python Answers by Framework

Browse Popular Code Answers by Language