8000 Implement logical hadamard transition for the fixed bulk convention · Issue #561 · tqec/tqec · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
Implement logical hadamard transition for the fixed bulk convention #561
@nelimee

Description

@nelimee

Is your feature request related to a problem? Please describe.

The Hadamard junction is not implemented for the fixed bulk convention.

Describe the solution you'd like

Implement the following method

def _get_temporal_hadamard_pipe_block(self, spec: PipeSpec) -> Block:
"""Returns the block to implement a
Hadamard temporal junction.
Note:
This method performs the Hadamard transition at the end of the
layer that appear first (i.e., temporally before the other, or in
other words the one with a lower Z index).
Args:
spec: description of the pipe that should be implemented by this
method. Should be a Hadamard temporal pipe.
Raises:
AssertionError: if the provided ``pipe`` is not a temporal pipe, or
if it is not a Hadamard transition.
Returns:
the block to implement the provided
``spec``.
"""
raise NotImplementedError()

and the two following branches

case Direction3D.X, True:
# Hadamard pipe in the X direction.
top_left_basis = spec.pipe_kind.get_basis_along(
Direction3D.Y, at_head=True
)
return (
lambda r,
m: self._generator.get_spatial_vertical_hadamard_plaquettes(
top_left_basis == Basis.Z, r, m
)
)

case Direction3D.Y, True:
# Hadamard pipe in the Y direction.
top_left_basis = spec.pipe_kind.get_basis_along(
Direction3D.X, at_head=True
)
return (
lambda r,
m: self._generator.get_spatial_horizontal_hadamard_plaquettes(
top_left_basis == Basis.Z, r, m
)
)

Metadata

Metadata

Assignees

Labels

backendIssue pertaining to the Python backend (tqec package)enhancementNew feature or request, may not be in the task flowgood first issueGood for newcomers

Projects

Status

No status

Relationships

None yet

Development

No branches or pull requests

Issue actions

    0