renamed functions, and made use of 'os.path.join, etc..'