FastDataBlock#
qualtran.surface_code.FastDataBlock
View source on GitHub
|
The fast data block uses a fixed code distance and a square layout.
Inherits From: DataBlock
qualtran.surface_code.FastDataBlock(
data_d
)
The fast data block lays \(n\) qubit batches in a square grid of side length \(1 + \sqrt{2n}\) where the bottom row is an ancilla region and the top \(\sqrt{2n}x\sqrt{2n}\) region is divided into alternating data and ancilla columns.
The increased footprint is to be able to consume magic states in a single timestep.
References
Attributes
data_dThe code distance
dfor protecting the qubits in the data block.n_steps_to_consume_a_magic_stateThe number of surface code steps to consume a magic state.
We must teleport in “magic states” to do non-Clifford operations on our algorithmic data qubits. The layout of the data block can limit the number magic states consumed per unit time.
One surface code step is
data_dcycles of error correction.DataBlock imlpementation must override this method. This method is used by
self.n_cyclesto report the total number of cycles required.
Methods#
get_n_tiles
@staticmethodget_n_tiles( n_algo_qubits: int )
n_tiles
n_tiles(
n_algo_qubits: int
) -> int
The number of surface code tiles used to store a given number of algorithm qubits.
We define an “algorithm qubit” to be a qubit used in the routing of algorithm-relevant quantum data in a bloq. A physical qubit is a physical system that can encode one qubit, albeit noisily. Specific to the surface code, we define a “tile” to be the minimal area of physical qubits necessary to encode one logical qubit to a particular code distance. A tile can store an algorithm qubit, can be used for ancillary purposes like routing, or can be left idle. A tile is usually a square grid of \(2d^2\) physical qubits.
DataBlock implementations must override this method. This method is used by
self.n_phys_qubits to report the total number of physical qubits.
Args
n_algo_qubitsThe number of algorithm qubits to compute the number of tiles for.
Returns
from_error_budget
@classmethodfrom_error_budget( error_budget: float, n_algo_qubits: int, qec_scheme: 'QECScheme', phys_err_rate: float ) -> 'FastDataBlock'
__ne__
__ne__(
other
)
Check equality and either forward a NotImplemented or return the result negated.
__eq__
__eq__(
other
)
Method generated by attrs for class FastDataBlock.
View source on GitHub