How to set the current working directory?
Try os.chdir
os.chdir(path)
Change the current working directory to path. Availability: Unix, Windows.
Perhaps this is what you are looking for:
import os
os.chdir(default_path)
import os
print os.getcwd() # Prints the current working directory
To set the working directory:
os.chdir('c:\\Users\\uname\\desktop\\python') # Provide the new path here