CollectZ2ToOutputNode
class samplomatic.samplex.nodes.CollectZ2ToOutputNode(register_name: str, subsystem_idxs: Sequence[int], output_name: str, output_idxs: Sequence[str])
Bases: CollectionNode
Reads from Z2Registers and writes to SamplexOutput.
Parameters
- register_name – The name of the register to read from.
- subsystem_idxs – The subsystems to read from.
- output_name – The name of the output to write to.
- output_idxs – The indices of the output to write to.
Methods Summary
Column 1 | Column 2 |
|---|---|
collect(registers, outputs, rng) | Collect. |
get_style() | Return the style of this node when plotted. |
outputs_to() | Return the set of names of outputs this node mutates. |
reads_from() | Return a manifest of which virtual register values this node needs to read from. |
validate_and_update(register_descriptions) | Validate provided register descriptions are compatible, update with changes. |
Methods Documentation
collect
collect(registers, outputs, rng)
Collect.
Parameters
- registers – Registers to collect from.
- outputs – Where to output.
- rng – A randomness generator.
get_style
outputs_to
reads_from
validate_and_update
validate_and_update(register_descriptions)
Validate provided register descriptions are compatible, update with changes.
This method can be used by a samplex to determine when a node execution order has well-defined dependencies before sampling begins.
Parameters
register_descriptions – A map from existing register names to their size and type.
Was this page helpful?
Report a bug, typo, or request content on GitHub.