MCPcopy Index your code
hub / github.com/dmlc/dgl / _init_api

Function _init_api

python/dgl/_ffi/function.py:289–302  ·  view source on GitHub ↗

Initialize api for a given module name namespace : str The namespace of the source registry target_module_name : str The target module name if different from namespace

(namespace, target_module_name=None)

Source from the content-addressed store, hash-verified

287
288
289def _init_api(namespace, target_module_name=None):
290 """Initialize api for a given module name
291
292 namespace : str
293 The namespace of the source registry
294
295 target_module_name : str
296 The target module name if different from namespace
297 """
298 target_module_name = target_module_name if target_module_name else namespace
299 if namespace.startswith("dgl."):
300 return _init_api_prefix(target_module_name, namespace[4:])
301 else:
302 return _init_api_prefix(target_module_name, namespace)
303
304
305def _init_api_prefix(module_name, prefix):

Callers 15

graph_index.pyFile · 0.85
global_config.pyFile · 0.85
_sparse_ops.pyFile · 0.85
random.pyFile · 0.85
partition.pyFile · 0.85
traversal.pyFile · 0.85
ndarray.pyFile · 0.85
heterograph.pyFile · 0.85
subgraph.pyFile · 0.85
randomwalks.pyFile · 0.85
labor.pyFile · 0.85

Calls 1

_init_api_prefixFunction · 0.85

Tested by

no test coverage detected