MCPcopy Create free account
hub / github.com/tdrussell/diffusion-pipe / __init__

Method __init__

utils/cache.py:11–18  ·  view source on GitHub ↗
(self, path: str, fingerprint: str, shard_size_gb=1)

Source from the content-addressed store, hash-verified

9
10class Cache:
11 def __init__(self, path: str, fingerprint: str, shard_size_gb=1):
12 self.path = Path(path)
13 self.fingerprint = fingerprint
14 self.metadata_db = self.path / 'metadata.db'
15 self.shard_size_gb = shard_size_gb
16 os.makedirs(self.path, exist_ok=True)
17
18 self.init()
19
20
21 def __len__(self):

Callers

nothing calls this directly

Calls 1

initMethod · 0.95

Tested by

no test coverage detected