I would like to see what is the best way to determine the current script directory in Python.
I discovered that, due to the many ways of calling Python code, it is ha
This should work in most cases:
import os,sys dirname=os.path.dirname(os.path.realpath(sys.argv[0]))