if sys.platform == 'win32':
    subprocess.Popen(['start', d], shell=True)
elif sys.platform == 'darwin':
    subprocess.Popen(['open', d])
Is there a cross-platform way to open a file browser in Python?