import os checkpoints_dir = os.path.abspath(os.path.join(os.path.dirname(__file__), '..', '..', 'checkpoints')) print(checkpoints_dir)