def METHOD_NAME(self, output_dir):
    if not os.path.exists(output_dir):
        os.makedirs(output_dir)
    file_path = os.path.join(output_dir, 'sanas.checkpoints')
    scene = dict()
    for key in self.__dict__:
        if key in ['_checkpoints']:
            continue
        scene[key] = self.__dict__[key]
    with open(file_path, 'w') as f:
        json.dump(scene, f)