vortex_torch.indexer.save_load¶
Classes
|
Read back a per-page value persisted by |
|
Persist a per-page indexer value across decode steps (paired with |
- class Save[source]¶
Bases:
vOpPersist a per-page indexer value across decode steps (paired with
Load) by copying it into a preallocated cache field.- Math:
- \[O \leftarrow X\]
(a format/layout copy
RAGGED→PAGED; no arithmetic). - __init__:
Save()— no arguments.- __call__:
op(x, o, ctx=ctx)—x[S, D_0, D_1](RAGGED) is written in place into the preallocatedo(PAGED, matchingD_0/D_1). Returns nothing.- Note:
write side of the persistent-state pattern; a flow that uses
Saverequires the engine to setdisable_radix_cache=True.
- class Load[source]¶
Bases:
vOpRead back a per-page value persisted by
Save(the read side of the cross-decode-step persistent-state pattern).- Math:
- \[Y \leftarrow X\]
(a format/layout copy
PAGED→RAGGED; no arithmetic). - __init__:
Load()— no arguments.- __call__:
y = op(x, ctx=ctx)—x[S, D_0, D_1](PAGED); returns a freshly-allocatedRAGGEDview of the same inner shape.- Note:
read side of the persistent-state pattern (see
Save).