os 가져오기 A = os.path.join(os.path.dirname(__file__), "..") B = os.path.dirname(os.path.dirname(__file__), "..") path.realpath(__file__)) C = os.path.abspath(os.path.dirname(__file__))
저는 보통 이것들을 실제 경로와 연결합니다. 그러나 런타임에 경로를 결정하는 이러한 명령문에는 이유가 있으며 os.path
모듈을 사용하기 시작할 수 있도록 정말 이해하고 싶습니다.