MCPcopy Create free account
hub / github.com/MegEngine/MegEngine / _check_dependencies

Function _check_dependencies

imperative/python/megengine/hub/hub.py:68–78  ·  view source on GitHub ↗
(module: types.ModuleType)

Source from the content-addressed store, hash-verified

66
67
68def _check_dependencies(module: types.ModuleType) -> None:
69 if not hasattr(module, HUBDEPENDENCY):
70 return
71
72 dependencies = getattr(module, HUBDEPENDENCY)
73 if not dependencies:
74 return
75
76 missing_deps = [m for m in dependencies if not check_module_exists(m)]
77 if len(missing_deps):
78 raise RuntimeError("Missing dependencies: {}".format(", ".join(missing_deps)))
79
80
81def _init_hub(

Callers 1

loadFunction · 0.85

Calls 3

check_module_existsFunction · 0.85
joinMethod · 0.80
formatMethod · 0.45

Tested by

no test coverage detected