(path, **kwargs)
| 130 | |
| 131 | @staticmethod |
| 132 | def load(path, **kwargs): |
| 133 | if ".ini" in path: |
| 134 | path = path[:-4] |
| 135 | if not os.path.exists(path) and os.path.exists(path + ".ini"): |
| 136 | # get realpath |
| 137 | conf = configparser.ConfigParser() |
| 138 | conf.read(path + ".ini") |
| 139 | path = conf["Link"]["ceph"] |
| 140 | return PetrelHelper._petrel_helper.load_pretrain(path, **kwargs) |
| 141 | |
| 142 | def save_checkpoint(self, model, path): |
| 143 | if "s3://" not in path: |
no test coverage detected