mirror of
https://github.com/zama-ai/concrete.git
synced 2026-01-13 14:58:01 -05:00
1.8 KiB
1.8 KiB
module concrete.compiler.key_set_cache
KeySetCache.
Cache for keys to avoid generating similar keys multiple times.
class KeySetCache
KeySetCache is a cache for KeySet to avoid generating similar keys multiple times.
Keys get cached and can be later used instead of generating a new keyset which can take a lot of time.
method __init__
__init__(keyset_cache: KeySetCache)
Wrap the native Cpp object.
Args:
keyset_cache(_KeySetCache): object to wrap
Raises:
TypeError: if keyset_cache is not of type _KeySetCache
method new
new(cache_path: str) → KeySetCache
Build a KeySetCache located at cache_path.
Args:
cache_path(str): path to the cache
Raises:
TypeError: if the path is not of type str.
Returns: KeySetCache