MCPcopy Index your code
hub / github.com/VisionXLab/OF-Diff / create_model

Function create_model

cldm/model.py:41–45  ·  view source on GitHub ↗
(config_path)

Source from the content-addressed store, hash-verified

39
40
41def create_model(config_path):
42 config = OmegaConf.load(config_path)
43 model = instantiate_from_config(config.model).cpu()
44 print(f'Loaded model config from [{config_path}]')
45 return model
46
47def compare_weights(state_dict, layer1_name, layer2_name):
48 if layer1_name not in state_dict:

Callers 1

add_control.pyFile · 0.90

Calls 2

instantiate_from_configFunction · 0.90
loadMethod · 0.80

Tested by

no test coverage detected