MCPcopy
hub / github.com/ModelTC/LightLLM / load

Method load

lightllm/utils/petrel_helper.py:132–140  ·  view source on GitHub ↗
(path, **kwargs)

Source from the content-addressed store, hash-verified

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:

Callers 15

get_config_jsonFunction · 0.80
_tensor_copy_3dimFunction · 0.80
load_pkMethod · 0.80
load_jsonMethod · 0.80
download_jsonMethod · 0.80
load_pretrainMethod · 0.80
load_configFunction · 0.80
preloadMethod · 0.80
bytes2tensorFunction · 0.80

Calls 3

existsMethod · 0.80
load_pretrainMethod · 0.80
readMethod · 0.45

Tested by

no test coverage detected