Skip to content

bloqade.lanes.heuristics.physical.movement.PhysicalPlacementStrategy

← Module overview

classPhysicalPlacementStrategysource

bloqade.lanes.heuristics.physical.movement.PhysicalPlacementStrategy

Bases: PlacementStrategyABC

Physical placement strategy backed by the Rust MoveSolver.

Signature
class PhysicalPlacementStrategy(arch_spec: ArchSpec = get_physical_arch_spec(), traversal: RustPlacementTraversal = (lambda: RustPlacementTraversal(strategy='entropy'))(), target_generator: TargetGeneratorABC | TargetGeneratorCallable | None = None)

Parameters

NameTypeDefaultDescription
arch_specArchSpecget_physical_arch_spec()
traversalRustPlacementTraversal(lambda: RustPlacementTraversal(strategy='entropy'))()
target_generatorTargetGeneratorABC | TargetGeneratorCallable | NoneNone

Attributes

NameTypeDefaultDescription
arch_specArchSpecfield(default_factory=get_physical_arch_spec)
traversalRustPlacementTraversalfield(default_factory=(lambda: RustPlacementTraversal(strategy='entropy')))
target_generatorTargetGeneratorABC | TargetGeneratorCallable | NoneNone

propertytrace_cz_indexsource

bloqade.lanes.heuristics.physical.movement.PhysicalPlacementStrategy.trace_cz_index

trace_cz_index: int | None
source

methodvalidate_initial_layoutsource

bloqade.lanes.heuristics.physical.movement.PhysicalPlacementStrategy.validate_initial_layout

Signature
def validate_initial_layout(initial_layout: tuple[LocationAddress, ...]) -> None

Parameters

NameTypeDescription
initial_layouttuple[LocationAddress, ...]
source

methodcz_placementssource

bloqade.lanes.heuristics.physical.movement.PhysicalPlacementStrategy.cz_placements

Signature
def cz_placements(state: AtomState, controls: tuple[int, ...], targets: tuple[int, ...], lookahead_cz_layers: tuple[tuple[tuple[int, ...], tuple[int, ...]], ...] = ()) -> AtomState

Parameters

NameTypeDefaultDescription
stateAtomStaterequired
controlstuple[int, ...]required
targetstuple[int, ...]required
lookahead_cz_layerstuple[tuple[tuple[int, ...], tuple[int, ...]], ...]()

Returns

AtomState

source

propertyrust_nodes_expanded_totalsource

bloqade.lanes.heuristics.physical.movement.PhysicalPlacementStrategy.rust_nodes_expanded_total

rust_nodes_expanded_total: int

Total Rust solver node expansions for this strategy instance.

source

propertyrust_entropy_fallback_countsource

bloqade.lanes.heuristics.physical.movement.PhysicalPlacementStrategy.rust_entropy_fallback_count

rust_entropy_fallback_count: int

Number of solved Rust entropy stages that used sequential fallback.

source

propertytraced_rust_entropy_tracesource

bloqade.lanes.heuristics.physical.movement.PhysicalPlacementStrategy.traced_rust_entropy_trace

traced_rust_entropy_trace: EntropyTrace | None
source

propertytraced_targetsource

bloqade.lanes.heuristics.physical.movement.PhysicalPlacementStrategy.traced_target

traced_target: dict[int, LocationAddress]

First candidate target for the traced CZ layer (used by visualizers).

source

propertytraced_blocked_locationssource

bloqade.lanes.heuristics.physical.movement.PhysicalPlacementStrategy.traced_blocked_locations

traced_blocked_locations: tuple[LocationAddress, ...]

Spectator atom positions for the traced CZ layer (atoms not in the active placement).

source

methodsq_placementssource

bloqade.lanes.heuristics.physical.movement.PhysicalPlacementStrategy.sq_placements

Signature
def sq_placements(state: AtomState, qubits: tuple[int, ...]) -> AtomState

Parameters

NameTypeDescription
stateAtomState
qubitstuple[int, ...]

Returns

AtomState

source

methodmeasure_placementssource

bloqade.lanes.heuristics.physical.movement.PhysicalPlacementStrategy.measure_placements

Signature
def measure_placements(state: AtomState, qubits: tuple[int, ...]) -> AtomState

Parameters

NameTypeDescription
stateAtomState
qubitstuple[int, ...]

Returns

AtomState

source