fhelium.backend.ckks.tables
Tensor views used by complete hybrid CKKS key-switch implementations.
KeySwitchTables
class View source
python
KeySwitchTables(rns_context: RnsContext, ntt_context: NttContext | None, moddown_p_drop_inverses_montgomery_by_depth: tuple[torch.Tensor, ...], galois_generator: int = 3)1
Own the tables used by hybrid CKKS key switching.
Attributes
| Name | Type | Default/value |
|---|---|---|
rns_context | RnsContext | |
ntt_context | NttContext | None | |
moddown_p_drop_inverses_montgomery_by_depth | tuple[torch.Tensor, ...] | |
galois_generator | int | 3 |
p_inverse_montgomery | torch.Tensor | field(init=False, repr=False, compare=False) |
device
property
python
device: torch.device1
moddown_tables
property
python
moddown_tables: tuple[torch.Tensor, ...]1
Return the depth-indexed P-drop inverse tables read by ModDown.
tensor_operands
method
python
def tensor_operands(depth: int) -> tuple[dict[str, torch.Tensor], dict[str, object]]: ...1
Expose the existing key-switch tables and static digit ranges.
Returned data can populate ordinary Program Tensor placeholders. No execution resource object is needed to consume these table views.