MCPcopy Create free account
hub / github.com/alibaba/GraphScope / warmup

Method warmup

python/graphscope/nx/classes/cache.py:81–90  ·  view source on GitHub ↗

Warm up the iteration cache.

(self)

Source from the content-addressed store, hash-verified

79 }
80
81 def warmup(self):
82 """Warm up the iteration cache."""
83 self._len = self._graph.number_of_nodes()
84 if self._len > 1000:
85 # avoid much small graphs to compete thread resource
86 self.enable_iter_cache = True
87 self._async_fetch_node_id_cache(0)
88 self._async_fetch_succ_cache(0)
89 self._async_fetch_node_attr_cache(0)
90 self._async_fetch_succ_attr_cache(0)
91
92 # LRU Caches
93 @lru_cache(1000000)

Callers 9

clearMethod · 0.95
__init__Method · 0.45
copyMethod · 0.45
to_undirectedMethod · 0.45
to_directedMethod · 0.45
subgraphMethod · 0.45
edge_subgraphMethod · 0.45
__init__Method · 0.45
reverseMethod · 0.45

Tested by

no test coverage detected