Skip to content

bloqade.pyqrack.reg.PyQrackQubit

← Module overview

classPyQrackQubitsource

bloqade.pyqrack.reg.PyQrackQubit

Bases: Qubit

The runtime representation of a qubit reference.

Signature
class PyQrackQubit(addr: int, sim_reg: QrackSimulator, state: QubitState)

Parameters

NameTypeDescription
addrint
sim_regQrackSimulator
stateQubitState

Attributes

NameTypeDescription
addrintThe address of this qubit in the quantum register.
sim_regQrackSimulatorThe register of the simulator.
stateQubitStateThe state of the qubit (active/lost)

methodis_activesource

bloqade.pyqrack.reg.PyQrackQubit.is_active

def is_active() -> bool

Check if the qubit is active.

Returns True if the qubit is active, False otherwise.

Returns

bool

source

methoddropsource

bloqade.pyqrack.reg.PyQrackQubit.drop

def drop()

Drop the qubit in-place.

source