From c99e8e6c64bf82b132db9b516fa332b0b46a5e7a Mon Sep 17 00:00:00 2001 From: Maxie Bichmann Date: Fri, 3 Jul 2026 14:07:55 +0200 Subject: [PATCH 01/29] =?UTF-8?q?=F0=9F=93=A6=20Add=20more=20structure=20f?= =?UTF-8?q?or=20code=20examples/generators?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/mqt/qecc/cc_decoder/__init__.py | 6 ++--- src/mqt/qecc/cc_decoder/decoder.py | 2 +- src/mqt/qecc/cc_decoder/utils.py | 8 +++---- src/mqt/qecc/circuit_synthesis/circuits.py | 2 +- src/mqt/qecc/circuit_synthesis/cnot.py | 2 +- src/mqt/qecc/circuit_synthesis/elimination.py | 2 +- src/mqt/qecc/circuit_synthesis/encoding.py | 2 +- src/mqt/qecc/circuit_synthesis/operations.py | 4 ++-- src/mqt/qecc/circuit_synthesis/simulation.py | 2 +- .../qecc/circuit_synthesis/simulation_det.py | 2 +- src/mqt/qecc/circuit_synthesis/state_prep.py | 4 ++-- src/mqt/qecc/circuit_synthesis/strategy.py | 2 +- src/mqt/qecc/circuit_synthesis/synthesis.py | 2 +- .../qecc/circuit_synthesis/synthesis_utils.py | 2 +- .../qecc/circuit_synthesis/transvection.py | 2 +- src/mqt/qecc/circuit_synthesis/types.py | 2 +- src/mqt/qecc/codes/__init__.py | 22 +++++++++++------- src/mqt/qecc/codes/constructions/__init__.py | 8 +++++++ .../codes/{ => constructions}/bb_codes.py | 2 +- .../codes/{ => constructions}/carbon/hx.npy | Bin .../codes/{ => constructions}/carbon/hz.npy | Bin .../{ => constructions}/cc_4_8_8_d5/hx.npy | Bin .../{ => constructions}/cc_4_8_8_d5/hz.npy | Bin .../codes/{ => constructions}/color_code.py | 2 +- .../{ => constructions}/concatenation.py | 8 +++---- .../{ => constructions}/constructions.py | 2 +- .../codes/{ => constructions}/golay/hx.npy | Bin .../codes/{ => constructions}/golay/hz.npy | Bin .../{ => constructions}/hamming_15/hx.npy | Bin .../{ => constructions}/hamming_15/hz.npy | Bin .../hexagonal_color_code.py | 0 .../rotated_surface_code.py | 2 +- .../rotated_surface_d3/hx.npy | Bin .../rotated_surface_d3/hz.npy | Bin .../rotated_surface_d5/hx.npy | Bin .../rotated_surface_d5/hz.npy | Bin .../codes/{ => constructions}/shor/hx.npy | Bin .../codes/{ => constructions}/shor/hz.npy | Bin .../square_octagon_color_code.py | 0 .../codes/{ => constructions}/steane/hx.npy | Bin .../codes/{ => constructions}/steane/hz.npy | Bin .../{ => constructions}/tetrahedral/hx.npy | Bin .../{ => constructions}/tetrahedral/hz.npy | Bin src/mqt/qecc/codes/core/__init__.py | 8 +++++++ src/mqt/qecc/codes/{ => core}/css_code.py | 2 +- src/mqt/qecc/codes/{ => core}/pauli.py | 0 .../qecc/codes/{ => core}/stabilizer_code.py | 2 +- src/mqt/qecc/codes/{ => core}/symplectic.py | 0 tests/circuit_synthesis/test_circuits.py | 4 ++-- tests/circuit_synthesis/test_cnot.py | 2 +- tests/circuit_synthesis/test_elimination.py | 2 +- .../test_encoder_synthesis.py | 2 +- tests/circuit_synthesis/test_operations.py | 2 +- tests/circuit_synthesis/test_transvection.py | 4 ++-- tests/test_code.py | 6 ++--- 55 files changed, 73 insertions(+), 53 deletions(-) create mode 100644 src/mqt/qecc/codes/constructions/__init__.py rename src/mqt/qecc/codes/{ => constructions}/bb_codes.py (97%) rename src/mqt/qecc/codes/{ => constructions}/carbon/hx.npy (100%) rename src/mqt/qecc/codes/{ => constructions}/carbon/hz.npy (100%) rename src/mqt/qecc/codes/{ => constructions}/cc_4_8_8_d5/hx.npy (100%) rename src/mqt/qecc/codes/{ => constructions}/cc_4_8_8_d5/hz.npy (100%) rename src/mqt/qecc/codes/{ => constructions}/color_code.py (98%) rename src/mqt/qecc/codes/{ => constructions}/concatenation.py (97%) rename src/mqt/qecc/codes/{ => constructions}/constructions.py (98%) rename src/mqt/qecc/codes/{ => constructions}/golay/hx.npy (100%) rename src/mqt/qecc/codes/{ => constructions}/golay/hz.npy (100%) rename src/mqt/qecc/codes/{ => constructions}/hamming_15/hx.npy (100%) rename src/mqt/qecc/codes/{ => constructions}/hamming_15/hz.npy (100%) rename src/mqt/qecc/codes/{ => constructions}/hexagonal_color_code.py (100%) rename src/mqt/qecc/codes/{ => constructions}/rotated_surface_code.py (98%) rename src/mqt/qecc/codes/{ => constructions}/rotated_surface_d3/hx.npy (100%) rename src/mqt/qecc/codes/{ => constructions}/rotated_surface_d3/hz.npy (100%) rename src/mqt/qecc/codes/{ => constructions}/rotated_surface_d5/hx.npy (100%) rename src/mqt/qecc/codes/{ => constructions}/rotated_surface_d5/hz.npy (100%) rename src/mqt/qecc/codes/{ => constructions}/shor/hx.npy (100%) rename src/mqt/qecc/codes/{ => constructions}/shor/hz.npy (100%) rename src/mqt/qecc/codes/{ => constructions}/square_octagon_color_code.py (100%) rename src/mqt/qecc/codes/{ => constructions}/steane/hx.npy (100%) rename src/mqt/qecc/codes/{ => constructions}/steane/hz.npy (100%) rename src/mqt/qecc/codes/{ => constructions}/tetrahedral/hx.npy (100%) rename src/mqt/qecc/codes/{ => constructions}/tetrahedral/hz.npy (100%) create mode 100644 src/mqt/qecc/codes/core/__init__.py rename src/mqt/qecc/codes/{ => core}/css_code.py (99%) rename src/mqt/qecc/codes/{ => core}/pauli.py (100%) rename src/mqt/qecc/codes/{ => core}/stabilizer_code.py (99%) rename src/mqt/qecc/codes/{ => core}/symplectic.py (100%) diff --git a/src/mqt/qecc/cc_decoder/__init__.py b/src/mqt/qecc/cc_decoder/__init__.py index 14fab6efc..d9cb1058d 100644 --- a/src/mqt/qecc/cc_decoder/__init__.py +++ b/src/mqt/qecc/cc_decoder/__init__.py @@ -9,9 +9,9 @@ from __future__ import annotations -from ..codes.color_code import ColorCode, LatticeType -from ..codes.hexagonal_color_code import HexagonalColorCode -from ..codes.square_octagon_color_code import SquareOctagonColorCode +from ..codes.constructions.color_code import ColorCode, LatticeType +from ..codes.constructions.hexagonal_color_code import HexagonalColorCode +from ..codes.constructions.square_octagon_color_code import SquareOctagonColorCode from .comparison import tn_decoder from .utils import code_from_string diff --git a/src/mqt/qecc/cc_decoder/decoder.py b/src/mqt/qecc/cc_decoder/decoder.py index 05c304e60..2c24a0224 100644 --- a/src/mqt/qecc/cc_decoder/decoder.py +++ b/src/mqt/qecc/cc_decoder/decoder.py @@ -26,7 +26,7 @@ import numpy.typing as npt from z3 import BoolRef, ModelRef - from ..codes.color_code import ColorCode + from ..codes.constructions.color_code import ColorCode @dataclass diff --git a/src/mqt/qecc/cc_decoder/utils.py b/src/mqt/qecc/cc_decoder/utils.py index 057128185..7b0601535 100644 --- a/src/mqt/qecc/cc_decoder/utils.py +++ b/src/mqt/qecc/cc_decoder/utils.py @@ -11,12 +11,12 @@ from typing import TYPE_CHECKING -from ..codes.color_code import LatticeType -from ..codes.hexagonal_color_code import HexagonalColorCode -from ..codes.square_octagon_color_code import SquareOctagonColorCode +from ..codes.constructions.color_code import LatticeType +from ..codes.constructions.hexagonal_color_code import HexagonalColorCode +from ..codes.constructions.square_octagon_color_code import SquareOctagonColorCode if TYPE_CHECKING: - from ..codes.color_code import ColorCode + from ..codes.constructions.color_code import ColorCode def code_from_string(lattice_type: str, distance: int) -> ColorCode: diff --git a/src/mqt/qecc/circuit_synthesis/circuits.py b/src/mqt/qecc/circuit_synthesis/circuits.py index 88549ef93..55257d7f7 100644 --- a/src/mqt/qecc/circuit_synthesis/circuits.py +++ b/src/mqt/qecc/circuit_synthesis/circuits.py @@ -17,7 +17,7 @@ from qiskit.transpiler.passes import RemoveResetInZeroState from ..codes import CSSCode, StabilizerCode -from ..codes.pauli import Pauli +from ..codes.core.pauli import Pauli from .circuit_utils import compose_circuits, num_two_qubit_gates, two_qubit_gate_depth if TYPE_CHECKING: # pragma: no cover diff --git a/src/mqt/qecc/circuit_synthesis/cnot.py b/src/mqt/qecc/circuit_synthesis/cnot.py index c557b6fc1..0d062f529 100644 --- a/src/mqt/qecc/circuit_synthesis/cnot.py +++ b/src/mqt/qecc/circuit_synthesis/cnot.py @@ -18,7 +18,7 @@ import numba as nb import numpy as np -from ..codes.pauli import CheckMatrix +from ..codes.core.pauli import CheckMatrix from .elimination import ( CandidateGenerator, get_n, diff --git a/src/mqt/qecc/circuit_synthesis/elimination.py b/src/mqt/qecc/circuit_synthesis/elimination.py index a08a7f078..045285995 100644 --- a/src/mqt/qecc/circuit_synthesis/elimination.py +++ b/src/mqt/qecc/circuit_synthesis/elimination.py @@ -18,7 +18,7 @@ import numpy as np import stim -from ..codes.pauli import StabilizerTableau +from ..codes.core.pauli import StabilizerTableau from .operations import CNOT, Swap, Transvection logger = logging.getLogger(__name__) diff --git a/src/mqt/qecc/circuit_synthesis/encoding.py b/src/mqt/qecc/circuit_synthesis/encoding.py index c8a69676f..21483d93d 100644 --- a/src/mqt/qecc/circuit_synthesis/encoding.py +++ b/src/mqt/qecc/circuit_synthesis/encoding.py @@ -20,7 +20,7 @@ import z3 from ..codes import CSSCode -from ..codes.pauli import CheckMatrix, StabilizerTableau, complete_stabilizer_tableau_with_destabilizers +from ..codes.core.pauli import CheckMatrix, StabilizerTableau, complete_stabilizer_tableau_with_destabilizers from .circuits import CliffordIsometry, CNOTCircuit from .operations import CNOT from .synthesis import SynthesisConfig, synthesize_cnot, synthesize_non_css diff --git a/src/mqt/qecc/circuit_synthesis/operations.py b/src/mqt/qecc/circuit_synthesis/operations.py index 798d80c2c..3fbf293de 100644 --- a/src/mqt/qecc/circuit_synthesis/operations.py +++ b/src/mqt/qecc/circuit_synthesis/operations.py @@ -16,12 +16,12 @@ import numpy as np import stim -from ..codes.pauli import StabilizerTableau +from ..codes.core.pauli import StabilizerTableau if TYPE_CHECKING: import numpy.typing as npt - from ..codes.pauli import CheckMatrix + from ..codes.core.pauli import CheckMatrix from .types import BinaryMatrix diff --git a/src/mqt/qecc/circuit_synthesis/simulation.py b/src/mqt/qecc/circuit_synthesis/simulation.py index e227de3bc..58f8df185 100644 --- a/src/mqt/qecc/circuit_synthesis/simulation.py +++ b/src/mqt/qecc/circuit_synthesis/simulation.py @@ -32,7 +32,7 @@ import numpy.typing as npt import stim - from ..codes.css_code import CSSCode + from ..codes.core.css_code import CSSCode from .noise import NoiseModel diff --git a/src/mqt/qecc/circuit_synthesis/simulation_det.py b/src/mqt/qecc/circuit_synthesis/simulation_det.py index 6d68dc27d..1c98fc200 100644 --- a/src/mqt/qecc/circuit_synthesis/simulation_det.py +++ b/src/mqt/qecc/circuit_synthesis/simulation_det.py @@ -31,7 +31,7 @@ from qiskit.circuit import QuantumCircuit from qsample.callbacks import Callback, CallbackList # ty: ignore[unresolved-import] - from ..codes.css_code import CSSCode + from ..codes.core.css_code import CSSCode from .state_prep_det import DeterministicCorrection, DeterministicVerification diff --git a/src/mqt/qecc/circuit_synthesis/state_prep.py b/src/mqt/qecc/circuit_synthesis/state_prep.py index 6c08a7040..b74e479dc 100644 --- a/src/mqt/qecc/circuit_synthesis/state_prep.py +++ b/src/mqt/qecc/circuit_synthesis/state_prep.py @@ -19,7 +19,7 @@ import z3 from qiskit.circuit import AncillaRegister, ClassicalRegister, QuantumCircuit, QuantumRegister -from ..codes.pauli import CheckMatrix +from ..codes.core.pauli import CheckMatrix from .circuits import CNOTCircuit from .encoding import cnot_encoding_circuit from .faults import PureFaultSet, coset_leader, product_fault_set @@ -40,7 +40,7 @@ import numpy.typing as npt - from ..codes.css_code import CSSCode + from ..codes.core.css_code import CSSCode class FaultyStatePrepCircuit: diff --git a/src/mqt/qecc/circuit_synthesis/strategy.py b/src/mqt/qecc/circuit_synthesis/strategy.py index fbba770d5..d91218a1c 100644 --- a/src/mqt/qecc/circuit_synthesis/strategy.py +++ b/src/mqt/qecc/circuit_synthesis/strategy.py @@ -14,7 +14,7 @@ import ldpc.mod2.mod2_numpy as mod2 import numpy as np -from ..codes.pauli import CheckMatrix, StabilizerTableau +from ..codes.core.pauli import CheckMatrix, StabilizerTableau from .cnot import GreedyCNOTGenerator from .elimination import EliminationStrategy, ParallelFilter from .rollout import ( diff --git a/src/mqt/qecc/circuit_synthesis/synthesis.py b/src/mqt/qecc/circuit_synthesis/synthesis.py index 431a6f385..761746a68 100644 --- a/src/mqt/qecc/circuit_synthesis/synthesis.py +++ b/src/mqt/qecc/circuit_synthesis/synthesis.py @@ -12,7 +12,7 @@ from dataclasses import dataclass from typing import TYPE_CHECKING -from ..codes.pauli import CheckMatrix, StabilizerTableau +from ..codes.core.pauli import CheckMatrix, StabilizerTableau from . import strategy from .elimination import EliminationSequence, eliminate from .operations import CNOT diff --git a/src/mqt/qecc/circuit_synthesis/synthesis_utils.py b/src/mqt/qecc/circuit_synthesis/synthesis_utils.py index fa2bae7a5..9422a1db5 100644 --- a/src/mqt/qecc/circuit_synthesis/synthesis_utils.py +++ b/src/mqt/qecc/circuit_synthesis/synthesis_utils.py @@ -26,7 +26,7 @@ import numpy.typing as npt from qiskit.circuit import AncillaQubit, Clbit, Qubit - from ..codes.pauli import CheckMatrix + from ..codes.core.pauli import CheckMatrix logger = logging.getLogger(__name__) diff --git a/src/mqt/qecc/circuit_synthesis/transvection.py b/src/mqt/qecc/circuit_synthesis/transvection.py index cba4b5efd..45603d1b0 100644 --- a/src/mqt/qecc/circuit_synthesis/transvection.py +++ b/src/mqt/qecc/circuit_synthesis/transvection.py @@ -16,7 +16,7 @@ import numba as nb import numpy as np -from ..codes.pauli import StabilizerTableau +from ..codes.core.pauli import StabilizerTableau from .elimination import CandidateGenerator, EliminationSequence, get_n from .operations import PauliOperation, SingleQubitClifford, Swap, Transvection diff --git a/src/mqt/qecc/circuit_synthesis/types.py b/src/mqt/qecc/circuit_synthesis/types.py index e8ad19a95..34e691f34 100644 --- a/src/mqt/qecc/circuit_synthesis/types.py +++ b/src/mqt/qecc/circuit_synthesis/types.py @@ -9,7 +9,7 @@ from __future__ import annotations -from ..codes.pauli import CheckMatrix, StabilizerTableau +from ..codes.core.pauli import CheckMatrix, StabilizerTableau # Type alias for matrices that can be used in elimination BinaryMatrix = CheckMatrix | StabilizerTableau diff --git a/src/mqt/qecc/codes/__init__.py b/src/mqt/qecc/codes/__init__.py index 6d618b68e..a68319785 100644 --- a/src/mqt/qecc/codes/__init__.py +++ b/src/mqt/qecc/codes/__init__.py @@ -9,15 +9,19 @@ from __future__ import annotations -from .bb_codes import construct_bb_code -from .color_code import ColorCode, LatticeType -from .concatenation import ConcatenatedCode, ConcatenatedCSSCode -from .constructions import construct_iceberg_code, construct_many_hypercube_code, construct_quantum_hamming_code -from .css_code import CSSCode, InvalidCSSCodeError -from .hexagonal_color_code import HexagonalColorCode -from .rotated_surface_code import InvalidDistanceError, RotatedSurfaceCode -from .square_octagon_color_code import SquareOctagonColorCode -from .stabilizer_code import InvalidStabilizerCodeError, StabilizerCode +from .constructions.bb_codes import construct_bb_code +from .constructions.color_code import ColorCode, LatticeType +from .constructions.concatenation import ConcatenatedCode, ConcatenatedCSSCode +from .constructions.constructions import ( + construct_iceberg_code, + construct_many_hypercube_code, + construct_quantum_hamming_code, +) +from .constructions.hexagonal_color_code import HexagonalColorCode +from .constructions.rotated_surface_code import InvalidDistanceError, RotatedSurfaceCode +from .constructions.square_octagon_color_code import SquareOctagonColorCode +from .core.css_code import CSSCode, InvalidCSSCodeError +from .core.stabilizer_code import InvalidStabilizerCodeError, StabilizerCode __all__ = [ "CSSCode", diff --git a/src/mqt/qecc/codes/constructions/__init__.py b/src/mqt/qecc/codes/constructions/__init__.py new file mode 100644 index 000000000..21fcd95e4 --- /dev/null +++ b/src/mqt/qecc/codes/constructions/__init__.py @@ -0,0 +1,8 @@ +# Copyright (c) 2023 - 2026 Chair for Design Automation, TUM +# All rights reserved. +# +# SPDX-License-Identifier: MIT +# +# Licensed under the MIT License + +"""Concrete code families and construction utilities.""" diff --git a/src/mqt/qecc/codes/bb_codes.py b/src/mqt/qecc/codes/constructions/bb_codes.py similarity index 97% rename from src/mqt/qecc/codes/bb_codes.py rename to src/mqt/qecc/codes/constructions/bb_codes.py index ff5e5405f..cee8c05f3 100644 --- a/src/mqt/qecc/codes/bb_codes.py +++ b/src/mqt/qecc/codes/constructions/bb_codes.py @@ -13,7 +13,7 @@ import numpy as np -from .css_code import CSSCode, InvalidCSSCodeError +from ..core.css_code import CSSCode, InvalidCSSCodeError if TYPE_CHECKING: # pragma: no cover import numpy.typing as npt diff --git a/src/mqt/qecc/codes/carbon/hx.npy b/src/mqt/qecc/codes/constructions/carbon/hx.npy similarity index 100% rename from src/mqt/qecc/codes/carbon/hx.npy rename to src/mqt/qecc/codes/constructions/carbon/hx.npy diff --git a/src/mqt/qecc/codes/carbon/hz.npy b/src/mqt/qecc/codes/constructions/carbon/hz.npy similarity index 100% rename from src/mqt/qecc/codes/carbon/hz.npy rename to src/mqt/qecc/codes/constructions/carbon/hz.npy diff --git a/src/mqt/qecc/codes/cc_4_8_8_d5/hx.npy b/src/mqt/qecc/codes/constructions/cc_4_8_8_d5/hx.npy similarity index 100% rename from src/mqt/qecc/codes/cc_4_8_8_d5/hx.npy rename to src/mqt/qecc/codes/constructions/cc_4_8_8_d5/hx.npy diff --git a/src/mqt/qecc/codes/cc_4_8_8_d5/hz.npy b/src/mqt/qecc/codes/constructions/cc_4_8_8_d5/hz.npy similarity index 100% rename from src/mqt/qecc/codes/cc_4_8_8_d5/hz.npy rename to src/mqt/qecc/codes/constructions/cc_4_8_8_d5/hz.npy diff --git a/src/mqt/qecc/codes/color_code.py b/src/mqt/qecc/codes/constructions/color_code.py similarity index 98% rename from src/mqt/qecc/codes/color_code.py rename to src/mqt/qecc/codes/constructions/color_code.py index 1cb95c5f2..c0728fb53 100644 --- a/src/mqt/qecc/codes/color_code.py +++ b/src/mqt/qecc/codes/constructions/color_code.py @@ -14,7 +14,7 @@ import numpy as np -from .css_code import CSSCode +from ..core.css_code import CSSCode if TYPE_CHECKING: import numpy.typing as npt diff --git a/src/mqt/qecc/codes/concatenation.py b/src/mqt/qecc/codes/constructions/concatenation.py similarity index 97% rename from src/mqt/qecc/codes/concatenation.py rename to src/mqt/qecc/codes/constructions/concatenation.py index 32e147e80..07d462af8 100644 --- a/src/mqt/qecc/codes/concatenation.py +++ b/src/mqt/qecc/codes/constructions/concatenation.py @@ -14,10 +14,10 @@ import numpy as np -from .css_code import CSSCode -from .pauli import Pauli -from .stabilizer_code import InvalidStabilizerCodeError, StabilizerCode -from .symplectic import SymplecticVector +from ..core.css_code import CSSCode +from ..core.pauli import Pauli +from ..core.stabilizer_code import InvalidStabilizerCodeError, StabilizerCode +from ..core.symplectic import SymplecticVector if TYPE_CHECKING: import numpy.typing as npt diff --git a/src/mqt/qecc/codes/constructions.py b/src/mqt/qecc/codes/constructions/constructions.py similarity index 98% rename from src/mqt/qecc/codes/constructions.py rename to src/mqt/qecc/codes/constructions/constructions.py index 87ab2cef5..c4b574b44 100644 --- a/src/mqt/qecc/codes/constructions.py +++ b/src/mqt/qecc/codes/constructions/constructions.py @@ -13,7 +13,7 @@ import numpy as np -from .css_code import CSSCode +from ..core.css_code import CSSCode if TYPE_CHECKING: import numpy.typing as npt diff --git a/src/mqt/qecc/codes/golay/hx.npy b/src/mqt/qecc/codes/constructions/golay/hx.npy similarity index 100% rename from src/mqt/qecc/codes/golay/hx.npy rename to src/mqt/qecc/codes/constructions/golay/hx.npy diff --git a/src/mqt/qecc/codes/golay/hz.npy b/src/mqt/qecc/codes/constructions/golay/hz.npy similarity index 100% rename from src/mqt/qecc/codes/golay/hz.npy rename to src/mqt/qecc/codes/constructions/golay/hz.npy diff --git a/src/mqt/qecc/codes/hamming_15/hx.npy b/src/mqt/qecc/codes/constructions/hamming_15/hx.npy similarity index 100% rename from src/mqt/qecc/codes/hamming_15/hx.npy rename to src/mqt/qecc/codes/constructions/hamming_15/hx.npy diff --git a/src/mqt/qecc/codes/hamming_15/hz.npy b/src/mqt/qecc/codes/constructions/hamming_15/hz.npy similarity index 100% rename from src/mqt/qecc/codes/hamming_15/hz.npy rename to src/mqt/qecc/codes/constructions/hamming_15/hz.npy diff --git a/src/mqt/qecc/codes/hexagonal_color_code.py b/src/mqt/qecc/codes/constructions/hexagonal_color_code.py similarity index 100% rename from src/mqt/qecc/codes/hexagonal_color_code.py rename to src/mqt/qecc/codes/constructions/hexagonal_color_code.py diff --git a/src/mqt/qecc/codes/rotated_surface_code.py b/src/mqt/qecc/codes/constructions/rotated_surface_code.py similarity index 98% rename from src/mqt/qecc/codes/rotated_surface_code.py rename to src/mqt/qecc/codes/constructions/rotated_surface_code.py index ca888e2d0..0d570d151 100644 --- a/src/mqt/qecc/codes/rotated_surface_code.py +++ b/src/mqt/qecc/codes/constructions/rotated_surface_code.py @@ -13,7 +13,7 @@ import numpy as np -from .css_code import CSSCode +from ..core.css_code import CSSCode if TYPE_CHECKING: from numpy.typing import NDArray diff --git a/src/mqt/qecc/codes/rotated_surface_d3/hx.npy b/src/mqt/qecc/codes/constructions/rotated_surface_d3/hx.npy similarity index 100% rename from src/mqt/qecc/codes/rotated_surface_d3/hx.npy rename to src/mqt/qecc/codes/constructions/rotated_surface_d3/hx.npy diff --git a/src/mqt/qecc/codes/rotated_surface_d3/hz.npy b/src/mqt/qecc/codes/constructions/rotated_surface_d3/hz.npy similarity index 100% rename from src/mqt/qecc/codes/rotated_surface_d3/hz.npy rename to src/mqt/qecc/codes/constructions/rotated_surface_d3/hz.npy diff --git a/src/mqt/qecc/codes/rotated_surface_d5/hx.npy b/src/mqt/qecc/codes/constructions/rotated_surface_d5/hx.npy similarity index 100% rename from src/mqt/qecc/codes/rotated_surface_d5/hx.npy rename to src/mqt/qecc/codes/constructions/rotated_surface_d5/hx.npy diff --git a/src/mqt/qecc/codes/rotated_surface_d5/hz.npy b/src/mqt/qecc/codes/constructions/rotated_surface_d5/hz.npy similarity index 100% rename from src/mqt/qecc/codes/rotated_surface_d5/hz.npy rename to src/mqt/qecc/codes/constructions/rotated_surface_d5/hz.npy diff --git a/src/mqt/qecc/codes/shor/hx.npy b/src/mqt/qecc/codes/constructions/shor/hx.npy similarity index 100% rename from src/mqt/qecc/codes/shor/hx.npy rename to src/mqt/qecc/codes/constructions/shor/hx.npy diff --git a/src/mqt/qecc/codes/shor/hz.npy b/src/mqt/qecc/codes/constructions/shor/hz.npy similarity index 100% rename from src/mqt/qecc/codes/shor/hz.npy rename to src/mqt/qecc/codes/constructions/shor/hz.npy diff --git a/src/mqt/qecc/codes/square_octagon_color_code.py b/src/mqt/qecc/codes/constructions/square_octagon_color_code.py similarity index 100% rename from src/mqt/qecc/codes/square_octagon_color_code.py rename to src/mqt/qecc/codes/constructions/square_octagon_color_code.py diff --git a/src/mqt/qecc/codes/steane/hx.npy b/src/mqt/qecc/codes/constructions/steane/hx.npy similarity index 100% rename from src/mqt/qecc/codes/steane/hx.npy rename to src/mqt/qecc/codes/constructions/steane/hx.npy diff --git a/src/mqt/qecc/codes/steane/hz.npy b/src/mqt/qecc/codes/constructions/steane/hz.npy similarity index 100% rename from src/mqt/qecc/codes/steane/hz.npy rename to src/mqt/qecc/codes/constructions/steane/hz.npy diff --git a/src/mqt/qecc/codes/tetrahedral/hx.npy b/src/mqt/qecc/codes/constructions/tetrahedral/hx.npy similarity index 100% rename from src/mqt/qecc/codes/tetrahedral/hx.npy rename to src/mqt/qecc/codes/constructions/tetrahedral/hx.npy diff --git a/src/mqt/qecc/codes/tetrahedral/hz.npy b/src/mqt/qecc/codes/constructions/tetrahedral/hz.npy similarity index 100% rename from src/mqt/qecc/codes/tetrahedral/hz.npy rename to src/mqt/qecc/codes/constructions/tetrahedral/hz.npy diff --git a/src/mqt/qecc/codes/core/__init__.py b/src/mqt/qecc/codes/core/__init__.py new file mode 100644 index 000000000..5e2c26694 --- /dev/null +++ b/src/mqt/qecc/codes/core/__init__.py @@ -0,0 +1,8 @@ +# Copyright (c) 2023 - 2026 Chair for Design Automation, TUM +# All rights reserved. +# +# SPDX-License-Identifier: MIT +# +# Licensed under the MIT License + +"""Core representations for quantum error-correcting codes.""" diff --git a/src/mqt/qecc/codes/css_code.py b/src/mqt/qecc/codes/core/css_code.py similarity index 99% rename from src/mqt/qecc/codes/css_code.py rename to src/mqt/qecc/codes/core/css_code.py index d987cb40a..33a0823b5 100644 --- a/src/mqt/qecc/codes/css_code.py +++ b/src/mqt/qecc/codes/core/css_code.py @@ -202,7 +202,7 @@ def from_code_name(code_name: str, distance: int | None = None) -> CSSCode: code_name: The name of the code. distance: The distance of the code. """ - prefix = (Path(__file__) / "../").resolve() + prefix = (Path(__file__) / "../../constructions/").resolve() paths = { "steane": prefix / "steane/", "tetrahedral": prefix / "tetrahedral/", diff --git a/src/mqt/qecc/codes/pauli.py b/src/mqt/qecc/codes/core/pauli.py similarity index 100% rename from src/mqt/qecc/codes/pauli.py rename to src/mqt/qecc/codes/core/pauli.py diff --git a/src/mqt/qecc/codes/stabilizer_code.py b/src/mqt/qecc/codes/core/stabilizer_code.py similarity index 99% rename from src/mqt/qecc/codes/stabilizer_code.py rename to src/mqt/qecc/codes/core/stabilizer_code.py index c7f45796e..ad25764a1 100644 --- a/src/mqt/qecc/codes/stabilizer_code.py +++ b/src/mqt/qecc/codes/core/stabilizer_code.py @@ -20,7 +20,7 @@ if TYPE_CHECKING: import numpy.typing as npt - from mqt.qecc.codes.symplectic import SymplecticVector + from mqt.qecc.codes.core.symplectic import SymplecticVector class StabilizerCode: diff --git a/src/mqt/qecc/codes/symplectic.py b/src/mqt/qecc/codes/core/symplectic.py similarity index 100% rename from src/mqt/qecc/codes/symplectic.py rename to src/mqt/qecc/codes/core/symplectic.py diff --git a/tests/circuit_synthesis/test_circuits.py b/tests/circuit_synthesis/test_circuits.py index b25663c63..6aae18ebd 100644 --- a/tests/circuit_synthesis/test_circuits.py +++ b/tests/circuit_synthesis/test_circuits.py @@ -15,8 +15,8 @@ from qiskit import QuantumCircuit from mqt.qecc.circuit_synthesis.circuits import CliffordIsometry, CNOTCircuit, compose_cnot_circuits -from mqt.qecc.codes.pauli import Pauli -from mqt.qecc.codes.stabilizer_code import StabilizerCode +from mqt.qecc.codes.core.pauli import Pauli +from mqt.qecc.codes.core.stabilizer_code import StabilizerCode def test_add_cnot(): diff --git a/tests/circuit_synthesis/test_cnot.py b/tests/circuit_synthesis/test_cnot.py index fa81e84d3..4a8b6b117 100644 --- a/tests/circuit_synthesis/test_cnot.py +++ b/tests/circuit_synthesis/test_cnot.py @@ -11,7 +11,7 @@ import pytest from mqt.qecc.circuit_synthesis.synthesis import SynthesisConfig, synthesize_cnot -from mqt.qecc.codes.pauli import CheckMatrix +from mqt.qecc.codes.core.pauli import CheckMatrix @pytest.fixture diff --git a/tests/circuit_synthesis/test_elimination.py b/tests/circuit_synthesis/test_elimination.py index 1a6a79f5d..6cdd29799 100644 --- a/tests/circuit_synthesis/test_elimination.py +++ b/tests/circuit_synthesis/test_elimination.py @@ -13,7 +13,7 @@ from mqt.qecc.circuit_synthesis.elimination import EliminationSequence from mqt.qecc.circuit_synthesis.operations import CNOT, Swap, Transvection -from mqt.qecc.codes.pauli import CheckMatrix, StabilizerTableau +from mqt.qecc.codes.core.pauli import CheckMatrix, StabilizerTableau @pytest.fixture diff --git a/tests/circuit_synthesis/test_encoder_synthesis.py b/tests/circuit_synthesis/test_encoder_synthesis.py index b74566804..87ad20ad9 100644 --- a/tests/circuit_synthesis/test_encoder_synthesis.py +++ b/tests/circuit_synthesis/test_encoder_synthesis.py @@ -31,7 +31,7 @@ ) from mqt.qecc.circuit_synthesis.synthesis import SynthesisConfig from mqt.qecc.codes import CSSCode, SquareOctagonColorCode, StabilizerCode, construct_quantum_hamming_code -from mqt.qecc.codes.pauli import Pauli, StabilizerTableau +from mqt.qecc.codes.core.pauli import Pauli, StabilizerTableau @pytest.fixture diff --git a/tests/circuit_synthesis/test_operations.py b/tests/circuit_synthesis/test_operations.py index 94d495f5a..77bdae918 100644 --- a/tests/circuit_synthesis/test_operations.py +++ b/tests/circuit_synthesis/test_operations.py @@ -20,7 +20,7 @@ Swap, Transvection, ) -from mqt.qecc.codes.pauli import CheckMatrix, StabilizerTableau +from mqt.qecc.codes.core.pauli import CheckMatrix, StabilizerTableau @pytest.fixture diff --git a/tests/circuit_synthesis/test_transvection.py b/tests/circuit_synthesis/test_transvection.py index 4a3515cca..cc00ce9f8 100644 --- a/tests/circuit_synthesis/test_transvection.py +++ b/tests/circuit_synthesis/test_transvection.py @@ -14,8 +14,8 @@ from mqt.qecc.circuit_synthesis.transvection import ( reduce_with_swaps, ) -from mqt.qecc.codes.pauli import StabilizerTableau -from mqt.qecc.codes.symplectic import SymplecticMatrix +from mqt.qecc.codes.core.pauli import StabilizerTableau +from mqt.qecc.codes.core.symplectic import SymplecticMatrix @pytest.fixture diff --git a/tests/test_code.py b/tests/test_code.py index d5b74b087..644acf4c2 100644 --- a/tests/test_code.py +++ b/tests/test_code.py @@ -26,14 +26,14 @@ construct_many_hypercube_code, construct_quantum_hamming_code, ) -from mqt.qecc.codes.pauli import ( +from mqt.qecc.codes.constructions.rotated_surface_code import InvalidDistanceError, RotatedSurfaceCode +from mqt.qecc.codes.core.pauli import ( InvalidPauliError, Pauli, StabilizerTableau, complete_stabilizer_tableau_with_destabilizers, ) -from mqt.qecc.codes.rotated_surface_code import InvalidDistanceError, RotatedSurfaceCode -from mqt.qecc.codes.symplectic import SymplecticMatrix, SymplecticVector +from mqt.qecc.codes.core.symplectic import SymplecticMatrix, SymplecticVector if TYPE_CHECKING: # pragma: no cover import numpy.typing as npt From 303d6ffe6e0a29e7e6ff4bfbb2bef9e836a2efbf Mon Sep 17 00:00:00 2001 From: Maxie Bichmann Date: Thu, 9 Jul 2026 12:49:26 +0200 Subject: [PATCH 02/29] =?UTF-8?q?=F0=9F=93=A6=20factor=20out=20generation?= =?UTF-8?q?=20of=20product=20codes=20into=20central=20src/mqt/qecc/codes?= =?UTF-8?q?=20directory?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- scripts/examples/atd_example.py | 2 +- .../code_construction/code_constructor.py | 88 +------- .../sparse_code_constructor.py | 91 +-------- .../lifted_product/lp_l=16_hx.npz | Bin .../lifted_product/lp_l=16_hz.npz | Bin .../lifted_product/lp_l=21_hx.npz | Bin .../lifted_product/lp_l=21_hz.npz | Bin .../lifted_product/lp_l=30_hx.npz | Bin .../lifted_product/lp_l=30_hz.npz | Bin .../qecc/codes/constructions/product_code.py | 188 ++++++++++++++++++ 10 files changed, 193 insertions(+), 176 deletions(-) rename src/mqt/qecc/{analog_information_decoding/codes => codes/constructions}/lifted_product/lp_l=16_hx.npz (100%) rename src/mqt/qecc/{analog_information_decoding/codes => codes/constructions}/lifted_product/lp_l=16_hz.npz (100%) rename src/mqt/qecc/{analog_information_decoding/codes => codes/constructions}/lifted_product/lp_l=21_hx.npz (100%) rename src/mqt/qecc/{analog_information_decoding/codes => codes/constructions}/lifted_product/lp_l=21_hz.npz (100%) rename src/mqt/qecc/{analog_information_decoding/codes => codes/constructions}/lifted_product/lp_l=30_hx.npz (100%) rename src/mqt/qecc/{analog_information_decoding/codes => codes/constructions}/lifted_product/lp_l=30_hz.npz (100%) create mode 100644 src/mqt/qecc/codes/constructions/product_code.py diff --git a/scripts/examples/atd_example.py b/scripts/examples/atd_example.py index decf6e694..b28b0b38e 100644 --- a/scripts/examples/atd_example.py +++ b/scripts/examples/atd_example.py @@ -16,7 +16,7 @@ from mqt.qecc.analog_information_decoding.simulators.analog_tannergraph_decoding import AtdSimulator from mqt.qecc.analog_information_decoding.utils.data_utils import BpParams -code_path = "src/mqt/qecc/analog_information_decoding/codes/lifted_product/lp_l=" +code_path = "src/mqt/qecc/codes/constructions/lifted_product/lp_l=" s = np.linspace(0.10, 0.4, 11) p = 0.05 for bp_method in ["msl"]: diff --git a/src/mqt/qecc/analog_information_decoding/code_construction/code_constructor.py b/src/mqt/qecc/analog_information_decoding/code_construction/code_constructor.py index ad55e95fe..93da046d2 100644 --- a/src/mqt/qecc/analog_information_decoding/code_construction/code_constructor.py +++ b/src/mqt/qecc/analog_information_decoding/code_construction/code_constructor.py @@ -18,99 +18,15 @@ import ldpc.mod2.mod2_numpy as mod2 import numpy as np import scipy.io as sio -import scipy.sparse as scs from bposd.hgp import hgp from scipy import sparse +from ...codes.constructions.product_code import generate_3d_product_code, generate_4d_product_code + if TYPE_CHECKING: from numpy.typing import NDArray -def is_all_zeros(array: NDArray[np.int32]) -> bool: - """Check if array is all zeros.""" - return not np.any(array) - - -def run_checks_scipy( - d_1: NDArray[np.int32], d_2: NDArray[np.int32], d_3: NDArray[np.int32], d_4: NDArray[np.int32] -) -> None: - """Run checks on the boundary maps.""" - sd_1 = scs.csr_matrix(d_1) - sd_2 = scs.csr_matrix(d_2) - sd_3 = scs.csr_matrix(d_3) - sd_4 = scs.csr_matrix(d_4) - - if not ( - is_all_zeros((sd_1 * sd_2).todense() % 2) - and is_all_zeros((sd_2 * sd_3).todense() % 2) - and is_all_zeros((sd_3 * sd_4).todense() % 2) - ): - msg = "Error generating 4D code, boundary maps do not square to zero" - raise RuntimeError(msg) - - -def generate_4d_product_code( - a_1: NDArray[np.int32], a_2: NDArray[np.int32], a_3: NDArray[np.int32], p: NDArray[np.int32], checks: bool = True -) -> tuple[NDArray[np.int32], NDArray[np.int32], NDArray[np.int32], NDArray[np.int32]]: - """Generate 4D product code.""" - r, c = p.shape - id_r: NDArray[np.int32] = np.identity(r, dtype=np.int32) - id_c: NDArray[np.int32] = np.identity(c, dtype=np.int32) - id_n0: NDArray[np.int32] = np.identity(a_1.shape[0], dtype=np.int32) - id_n1: NDArray[np.int32] = np.identity(a_2.shape[0], dtype=np.int32) - id_n2: NDArray[np.int32] = np.identity(a_3.shape[0], dtype=np.int32) - id_n3: NDArray[np.int32] = np.identity(a_3.shape[1], dtype=np.int32) - - d_1: NDArray[np.int32] = np.hstack((np.kron(a_1, id_r), np.kron(id_n0, p))).astype(np.int32) - - x = np.hstack((np.kron(a_2, id_r), np.kron(id_n1, p))) - y = np.kron(a_1, id_c) - dims = (y.shape[0], x.shape[1] - y.shape[1]) - z = np.hstack((np.zeros(dims, dtype=np.int32), y)) - d_2 = np.vstack((x, z)) - - x = np.hstack((np.kron(a_3, id_r), np.kron(id_n2, p))) - y = np.kron(a_2, id_c) - dims = (y.shape[0], x.shape[1] - y.shape[1]) - z = np.hstack((np.zeros(dims, dtype=np.int32), y)) - d_3: NDArray[np.int32] = np.vstack((x, z)).astype(np.int32) - - d_4: NDArray[np.int32] = np.vstack((np.kron(id_n3, p), np.kron(a_3, id_c))) - - if checks: - run_checks_scipy(d_1, d_2, d_3, d_4) - - return d_1, d_2, d_3, d_4 - - -def generate_3d_product_code( - a_1: NDArray[np.int32], a_2: NDArray[np.int32], p: NDArray[np.int32] -) -> tuple[NDArray[np.int32], NDArray[np.int32], NDArray[np.int32]]: - """Generate 3D product code.""" - r, c = p.shape - id_r: NDArray[np.int32] = np.identity(r, dtype=np.int32) - id_c: NDArray[np.int32] = np.identity(c, dtype=np.int32) - id_n0: NDArray[np.int32] = np.identity(a_1.shape[0], dtype=np.int32) - id_n1: NDArray[np.int32] = np.identity(a_2.shape[0], dtype=np.int32) - id_n2: NDArray[np.int32] = np.identity(a_2.shape[1], dtype=np.int32) - - d_1: NDArray[np.int32] = np.hstack((np.kron(a_1, id_r), np.kron(id_n0, p))) - - x = np.hstack((np.kron(a_2, id_r), np.kron(id_n1, p))) - y = np.kron(a_1, id_c) - dims = (y.shape[0], x.shape[1] - y.shape[1]) - z = np.hstack((np.zeros(dims, dtype=np.int32), y)) - d_2: NDArray[np.int32] = np.vstack((x, z)) - - d_3: NDArray[np.int32] = np.vstack((np.kron(id_n2, p), np.kron(a_2, id_c))) - - if not (is_all_zeros(d_1 @ d_2 % 2) and is_all_zeros(d_2 @ d_3 % 2)): - msg = "Error generating 3D code, boundary maps do not square to zero" - raise RuntimeError(msg) - - return d_1, d_2, d_3 - - def create_outpath(codename: str) -> str: """Create output path for code files.""" path = f"generated_codes/{codename}/" diff --git a/src/mqt/qecc/analog_information_decoding/code_construction/sparse_code_constructor.py b/src/mqt/qecc/analog_information_decoding/code_construction/sparse_code_constructor.py index 4184b4e7f..3b362cec8 100644 --- a/src/mqt/qecc/analog_information_decoding/code_construction/sparse_code_constructor.py +++ b/src/mqt/qecc/analog_information_decoding/code_construction/sparse_code_constructor.py @@ -21,100 +21,13 @@ from scipy import sparse from scipy.sparse import coo_matrix, csr_matrix +from ...codes.constructions.product_code import generate_sparse_3d_product_code from . import code_constructor if TYPE_CHECKING: from numpy.typing import NDArray -def is_all_zeros(array: NDArray[np.int_]) -> bool: - """Check if array is all zeros.""" - return not np.any(array) - - -def sparse_all_zeros(mat: csr_matrix) -> bool: - """Check if sparse matrix is all zeros.""" - mat.data %= 2 - return bool(mat.sum() == 0) - - -def run_checks_scipy(d_1: csr_matrix, d_2: csr_matrix, d_3: csr_matrix, d_4: csr_matrix) -> None: - """Run checks on the boundary maps.""" - if not (sparse_all_zeros(d_1 @ d_2) and sparse_all_zeros(d_2 @ d_3) and sparse_all_zeros(d_3 @ d_4)): - msg = "Error generating 4D code, boundary maps do not square to zero" - raise RuntimeError(msg) - - -def generate_4d_product_code( - a_1: csr_matrix, - a_2: csr_matrix, - a_3: csr_matrix, - p: csr_matrix, - checks: bool = True, -) -> tuple[csr_matrix, csr_matrix, csr_matrix, csr_matrix]: - """Generate 4D HGP code.""" - r, c = p.shape - - id_r = sparse.identity(r, dtype=int) - id_c = sparse.identity(c, dtype=int) - id_n0 = sparse.identity(a_1.shape[0], dtype=int) - id_n1 = sparse.identity(a_2.shape[0], dtype=int) - id_n2 = sparse.identity(a_3.shape[0], dtype=int) - id_n3 = sparse.identity(a_3.shape[1], dtype=int) - - d_1 = sparse.hstack((sparse.kron(a_1, id_r), sparse.kron(id_n0, p))) - - x = sparse.hstack((sparse.kron(a_2, id_r), sparse.kron(id_n1, p))) - y = sparse.kron(a_1, id_c) - dims = (y.shape[0], x.shape[1] - y.shape[1]) - nmat = csr_matrix(np.zeros(dims)) - z = sparse.hstack((nmat, y)) - d_2 = sparse.vstack((x, z)) - - x = sparse.hstack((sparse.kron(a_3, id_r), sparse.kron(id_n2, p))) - y = sparse.kron(a_2, id_c) - dims = (y.shape[0], x.shape[1] - y.shape[1]) - mat = csr_matrix(np.zeros(dims)) - z = sparse.hstack([mat, y]) - d_3 = sparse.vstack((x, z)) - - d_4 = sparse.vstack((sparse.kron(id_n3, p), sparse.kron(a_3, id_c))) - - if checks: - run_checks_scipy(d_1, d_2, d_3, d_4) - - return d_1, d_2, d_3, d_4 - - -def generate_3d_product_code( - a_1: csr_matrix, a_2: csr_matrix, p: csr_matrix -) -> tuple[csr_matrix, csr_matrix, csr_matrix]: - """Generate 3D HGP code.""" - r, c = p.shape - - id_r = sparse.identity(r, dtype=int) - id_c = sparse.identity(c, dtype=int) - id_n0 = sparse.identity(a_1.shape[0], dtype=int) - id_n1 = sparse.identity(a_2.shape[0], dtype=int) - id_n2 = sparse.identity(a_2.shape[1], dtype=int) - - d_1 = sparse.hstack((sparse.kron(a_1, id_r), sparse.kron(id_n0, p))) - - x = sparse.hstack((sparse.kron(a_2, id_r), sparse.kron(id_n1, p))) - y = sparse.kron(a_1, id_c) - dims = (y.shape[0], x.shape[1] - y.shape[1]) - z = sparse.hstack((csr_matrix(np.zeros(dims), dtype=int), y)) - d_2 = sparse.vstack((x, z)) - - d_3 = sparse.vstack((sparse.kron(id_n2, p), sparse.kron(a_2, id_c))) - - if not (sparse_all_zeros(d_1 @ d_2) and sparse_all_zeros(d_2 @ d_3)): - msg = "Error generating 3D code, boundary maps do not square to zero" - raise RuntimeError(msg) - - return d_1, d_2, d_3 # mx, hx, hzT # hx, hzT, mzT - - def create_outpath(codename: str) -> str: """Create output path for code.""" path = f"/codes/generated_codes/{codename}/" @@ -202,7 +115,7 @@ def create_code( # Extend to 3D HGP a1 = sparse.csr_matrix(code.hx) a2 = sparse.csr_matrix(code.hz.T) - res = generate_3d_product_code(a1, a2, sparse.csr_matrix(seed_codes[2])) + res = generate_sparse_3d_product_code(a1, a2, sparse.csr_matrix(seed_codes[2])) hx, hz_t, mz_t = res hz = hz_t.transpose() diff --git a/src/mqt/qecc/analog_information_decoding/codes/lifted_product/lp_l=16_hx.npz b/src/mqt/qecc/codes/constructions/lifted_product/lp_l=16_hx.npz similarity index 100% rename from src/mqt/qecc/analog_information_decoding/codes/lifted_product/lp_l=16_hx.npz rename to src/mqt/qecc/codes/constructions/lifted_product/lp_l=16_hx.npz diff --git a/src/mqt/qecc/analog_information_decoding/codes/lifted_product/lp_l=16_hz.npz b/src/mqt/qecc/codes/constructions/lifted_product/lp_l=16_hz.npz similarity index 100% rename from src/mqt/qecc/analog_information_decoding/codes/lifted_product/lp_l=16_hz.npz rename to src/mqt/qecc/codes/constructions/lifted_product/lp_l=16_hz.npz diff --git a/src/mqt/qecc/analog_information_decoding/codes/lifted_product/lp_l=21_hx.npz b/src/mqt/qecc/codes/constructions/lifted_product/lp_l=21_hx.npz similarity index 100% rename from src/mqt/qecc/analog_information_decoding/codes/lifted_product/lp_l=21_hx.npz rename to src/mqt/qecc/codes/constructions/lifted_product/lp_l=21_hx.npz diff --git a/src/mqt/qecc/analog_information_decoding/codes/lifted_product/lp_l=21_hz.npz b/src/mqt/qecc/codes/constructions/lifted_product/lp_l=21_hz.npz similarity index 100% rename from src/mqt/qecc/analog_information_decoding/codes/lifted_product/lp_l=21_hz.npz rename to src/mqt/qecc/codes/constructions/lifted_product/lp_l=21_hz.npz diff --git a/src/mqt/qecc/analog_information_decoding/codes/lifted_product/lp_l=30_hx.npz b/src/mqt/qecc/codes/constructions/lifted_product/lp_l=30_hx.npz similarity index 100% rename from src/mqt/qecc/analog_information_decoding/codes/lifted_product/lp_l=30_hx.npz rename to src/mqt/qecc/codes/constructions/lifted_product/lp_l=30_hx.npz diff --git a/src/mqt/qecc/analog_information_decoding/codes/lifted_product/lp_l=30_hz.npz b/src/mqt/qecc/codes/constructions/lifted_product/lp_l=30_hz.npz similarity index 100% rename from src/mqt/qecc/analog_information_decoding/codes/lifted_product/lp_l=30_hz.npz rename to src/mqt/qecc/codes/constructions/lifted_product/lp_l=30_hz.npz diff --git a/src/mqt/qecc/codes/constructions/product_code.py b/src/mqt/qecc/codes/constructions/product_code.py new file mode 100644 index 000000000..2cc062fd7 --- /dev/null +++ b/src/mqt/qecc/codes/constructions/product_code.py @@ -0,0 +1,188 @@ +# Copyright (c) 2023 - 2026 Chair for Design Automation, TUM +# All rights reserved. +# +# SPDX-License-Identifier: MIT +# +# Licensed under the MIT License + +"""Package for code construction.""" + +from __future__ import annotations + +from typing import TYPE_CHECKING + +import numpy as np +import scipy.sparse as scs +from scipy import sparse +from scipy.sparse import csr_matrix + +if TYPE_CHECKING: + from numpy.typing import NDArray + + +def is_all_zeros(array: NDArray[np.int32]) -> bool: + """Check if array is all zeros.""" + return not np.any(array) + + +def sparse_all_zeros(mat: csr_matrix) -> bool: + """Check if sparse matrix is all zeros.""" + mat.data %= 2 + return bool(mat.sum() == 0) + + +def run_sparse_checks_scipy(d_1: csr_matrix, d_2: csr_matrix, d_3: csr_matrix, d_4: csr_matrix) -> None: + """Run checks on the boundary maps.""" + if not (sparse_all_zeros(d_1 @ d_2) and sparse_all_zeros(d_2 @ d_3) and sparse_all_zeros(d_3 @ d_4)): + msg = "Error generating 4D code, boundary maps do not square to zero" + raise RuntimeError(msg) + + +def run_checks_scipy( + d_1: NDArray[np.int32], d_2: NDArray[np.int32], d_3: NDArray[np.int32], d_4: NDArray[np.int32] +) -> None: + """Run checks on the boundary maps.""" + sd_1 = scs.csr_matrix(d_1) + sd_2 = scs.csr_matrix(d_2) + sd_3 = scs.csr_matrix(d_3) + sd_4 = scs.csr_matrix(d_4) + + if not ( + is_all_zeros((sd_1 * sd_2).todense() % 2) + and is_all_zeros((sd_2 * sd_3).todense() % 2) + and is_all_zeros((sd_3 * sd_4).todense() % 2) + ): + msg = "Error generating 4D code, boundary maps do not square to zero" + raise RuntimeError(msg) + + +def generate_4d_product_code( + a_1: NDArray[np.int32], a_2: NDArray[np.int32], a_3: NDArray[np.int32], p: NDArray[np.int32], checks: bool = True +) -> tuple[NDArray[np.int32], NDArray[np.int32], NDArray[np.int32], NDArray[np.int32]]: + """Generate 4D product code.""" + r, c = p.shape + id_r: NDArray[np.int32] = np.identity(r, dtype=np.int32) + id_c: NDArray[np.int32] = np.identity(c, dtype=np.int32) + id_n0: NDArray[np.int32] = np.identity(a_1.shape[0], dtype=np.int32) + id_n1: NDArray[np.int32] = np.identity(a_2.shape[0], dtype=np.int32) + id_n2: NDArray[np.int32] = np.identity(a_3.shape[0], dtype=np.int32) + id_n3: NDArray[np.int32] = np.identity(a_3.shape[1], dtype=np.int32) + + d_1: NDArray[np.int32] = np.hstack((np.kron(a_1, id_r), np.kron(id_n0, p))).astype(np.int32) + + x = np.hstack((np.kron(a_2, id_r), np.kron(id_n1, p))) + y = np.kron(a_1, id_c) + dims = (y.shape[0], x.shape[1] - y.shape[1]) + z = np.hstack((np.zeros(dims, dtype=np.int32), y)) + d_2 = np.vstack((x, z)) + + x = np.hstack((np.kron(a_3, id_r), np.kron(id_n2, p))) + y = np.kron(a_2, id_c) + dims = (y.shape[0], x.shape[1] - y.shape[1]) + z = np.hstack((np.zeros(dims, dtype=np.int32), y)) + d_3: NDArray[np.int32] = np.vstack((x, z)).astype(np.int32) + + d_4: NDArray[np.int32] = np.vstack((np.kron(id_n3, p), np.kron(a_3, id_c))) + + if checks: + run_checks_scipy(d_1, d_2, d_3, d_4) + + return d_1, d_2, d_3, d_4 + + +def generate_3d_product_code( + a_1: NDArray[np.int32], a_2: NDArray[np.int32], p: NDArray[np.int32] +) -> tuple[NDArray[np.int32], NDArray[np.int32], NDArray[np.int32]]: + """Generate 3D product code.""" + r, c = p.shape + id_r: NDArray[np.int32] = np.identity(r, dtype=np.int32) + id_c: NDArray[np.int32] = np.identity(c, dtype=np.int32) + id_n0: NDArray[np.int32] = np.identity(a_1.shape[0], dtype=np.int32) + id_n1: NDArray[np.int32] = np.identity(a_2.shape[0], dtype=np.int32) + id_n2: NDArray[np.int32] = np.identity(a_2.shape[1], dtype=np.int32) + + d_1: NDArray[np.int32] = np.hstack((np.kron(a_1, id_r), np.kron(id_n0, p))) + + x = np.hstack((np.kron(a_2, id_r), np.kron(id_n1, p))) + y = np.kron(a_1, id_c) + dims = (y.shape[0], x.shape[1] - y.shape[1]) + z = np.hstack((np.zeros(dims, dtype=np.int32), y)) + d_2: NDArray[np.int32] = np.vstack((x, z)) + + d_3: NDArray[np.int32] = np.vstack((np.kron(id_n2, p), np.kron(a_2, id_c))) + + if not (is_all_zeros(d_1 @ d_2 % 2) and is_all_zeros(d_2 @ d_3 % 2)): + msg = "Error generating 3D code, boundary maps do not square to zero" + raise RuntimeError(msg) + + return d_1, d_2, d_3 + + +def generate_sparse_4d_product_code( + a_1: csr_matrix, + a_2: csr_matrix, + a_3: csr_matrix, + p: csr_matrix, + checks: bool = True, +) -> tuple[csr_matrix, csr_matrix, csr_matrix, csr_matrix]: + """Generate 4D HGP code.""" + r, c = p.shape + + id_r = sparse.identity(r, dtype=int) + id_c = sparse.identity(c, dtype=int) + id_n0 = sparse.identity(a_1.shape[0], dtype=int) + id_n1 = sparse.identity(a_2.shape[0], dtype=int) + id_n2 = sparse.identity(a_3.shape[0], dtype=int) + id_n3 = sparse.identity(a_3.shape[1], dtype=int) + + d_1 = sparse.hstack((sparse.kron(a_1, id_r), sparse.kron(id_n0, p))) + + x = sparse.hstack((sparse.kron(a_2, id_r), sparse.kron(id_n1, p))) + y = sparse.kron(a_1, id_c) + dims = (y.shape[0], x.shape[1] - y.shape[1]) + nmat = csr_matrix(np.zeros(dims)) + z = sparse.hstack((nmat, y)) + d_2 = sparse.vstack((x, z)) + + x = sparse.hstack((sparse.kron(a_3, id_r), sparse.kron(id_n2, p))) + y = sparse.kron(a_2, id_c) + dims = (y.shape[0], x.shape[1] - y.shape[1]) + mat = csr_matrix(np.zeros(dims)) + z = sparse.hstack([mat, y]) + d_3 = sparse.vstack((x, z)) + + d_4 = sparse.vstack((sparse.kron(id_n3, p), sparse.kron(a_3, id_c))) + + if checks: + run_sparse_checks_scipy(d_1, d_2, d_3, d_4) + + return d_1, d_2, d_3, d_4 + + +def generate_sparse_3d_product_code( + a_1: csr_matrix, a_2: csr_matrix, p: csr_matrix +) -> tuple[csr_matrix, csr_matrix, csr_matrix]: + """Generate 3D HGP code.""" + r, c = p.shape + + id_r = sparse.identity(r, dtype=int) + id_c = sparse.identity(c, dtype=int) + id_n0 = sparse.identity(a_1.shape[0], dtype=int) + id_n1 = sparse.identity(a_2.shape[0], dtype=int) + id_n2 = sparse.identity(a_2.shape[1], dtype=int) + + d_1 = sparse.hstack((sparse.kron(a_1, id_r), sparse.kron(id_n0, p))) + + x = sparse.hstack((sparse.kron(a_2, id_r), sparse.kron(id_n1, p))) + y = sparse.kron(a_1, id_c) + dims = (y.shape[0], x.shape[1] - y.shape[1]) + z = sparse.hstack((csr_matrix(np.zeros(dims), dtype=int), y)) + d_2 = sparse.vstack((x, z)) + + d_3 = sparse.vstack((sparse.kron(id_n2, p), sparse.kron(a_2, id_c))) + + if not (sparse_all_zeros(d_1 @ d_2) and sparse_all_zeros(d_2 @ d_3)): + msg = "Error generating 3D code, boundary maps do not square to zero" + raise RuntimeError(msg) + + return d_1, d_2, d_3 # mx, hx, hzT # hx, hzT, mzT From 02f214e14a3cdcaf48e540e6f8d9272b5503d0ee Mon Sep 17 00:00:00 2001 From: Maxie Bichmann Date: Thu, 9 Jul 2026 14:03:36 +0200 Subject: [PATCH 03/29] =?UTF-8?q?=F0=9F=93=A6=20centralize=20hardcoded=20c?= =?UTF-8?q?ode=20instances?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../encoding_circuits/codes/css/15_1_3.txt | 15 ------------ .../encoding_circuits/codes/css/15_7_3.txt | 9 ------- .../encoding_circuits/codes/css/17_1_5.txt | 17 ------------- .../encoding_circuits/codes/css/23_1_7.txt | 23 ------------------ .../qecc/codes/constructions/bb}/108_8_10.txt | 0 .../codes/constructions/bb}/144_12_12.txt | 0 .../qecc/codes/constructions/bb}/72_12_6.txt | 0 .../qecc/codes/constructions/bb}/90_8_10.txt | 0 .../constructions/cc/hexagonal}/19_1_5.txt | 0 .../constructions/cc/hexagonal}/37_1_7.txt | 0 .../codes/constructions/cc/sqroct}/31_1_7.txt | 0 .../{cc_4_8_8_d5 => cc/sqroct/d5}/hx.npy | Bin .../{cc_4_8_8_d5 => cc/sqroct/d5}/hz.npy | Bin .../constructions/{ => cc}/steane/hx.npy | Bin .../constructions/{ => cc}/steane/hz.npy | Bin .../constructions/{ => cc}/tetrahedral/hx.npy | Bin .../constructions/{ => cc}/tetrahedral/hz.npy | Bin .../{hamming_15 => hamming/n15}/hx.npy | Bin .../{hamming_15 => hamming/n15}/hz.npy | Bin .../constructions/hamming/n31/hamming_31.txt | 0 .../qecc/codes/constructions/misc}/15_3_5.txt | 0 .../qecc/codes/constructions/misc}/30_6_5.txt | 0 .../qecc/codes/constructions/misc}/8_3_3.txt | 0 .../d3}/hx.npy | Bin .../d3}/hz.npy | Bin .../d5}/hx.npy | Bin .../d5}/hz.npy | Bin src/mqt/qecc/codes/core/css_code.py | 10 ++++---- 28 files changed, 5 insertions(+), 69 deletions(-) delete mode 100644 scripts/encoding_circuits/codes/css/15_1_3.txt delete mode 100644 scripts/encoding_circuits/codes/css/15_7_3.txt delete mode 100644 scripts/encoding_circuits/codes/css/17_1_5.txt delete mode 100644 scripts/encoding_circuits/codes/css/23_1_7.txt rename {scripts/encoding_circuits/codes/css => src/mqt/qecc/codes/constructions/bb}/108_8_10.txt (100%) rename {scripts/encoding_circuits/codes/css => src/mqt/qecc/codes/constructions/bb}/144_12_12.txt (100%) rename {scripts/encoding_circuits/codes/css => src/mqt/qecc/codes/constructions/bb}/72_12_6.txt (100%) rename {scripts/encoding_circuits/codes/css => src/mqt/qecc/codes/constructions/bb}/90_8_10.txt (100%) rename {scripts/encoding_circuits/codes/css => src/mqt/qecc/codes/constructions/cc/hexagonal}/19_1_5.txt (100%) rename {scripts/encoding_circuits/codes/css => src/mqt/qecc/codes/constructions/cc/hexagonal}/37_1_7.txt (100%) rename {scripts/encoding_circuits/codes/css => src/mqt/qecc/codes/constructions/cc/sqroct}/31_1_7.txt (100%) rename src/mqt/qecc/codes/constructions/{cc_4_8_8_d5 => cc/sqroct/d5}/hx.npy (100%) rename src/mqt/qecc/codes/constructions/{cc_4_8_8_d5 => cc/sqroct/d5}/hz.npy (100%) rename src/mqt/qecc/codes/constructions/{ => cc}/steane/hx.npy (100%) rename src/mqt/qecc/codes/constructions/{ => cc}/steane/hz.npy (100%) rename src/mqt/qecc/codes/constructions/{ => cc}/tetrahedral/hx.npy (100%) rename src/mqt/qecc/codes/constructions/{ => cc}/tetrahedral/hz.npy (100%) rename src/mqt/qecc/codes/constructions/{hamming_15 => hamming/n15}/hx.npy (100%) rename src/mqt/qecc/codes/constructions/{hamming_15 => hamming/n15}/hz.npy (100%) rename scripts/encoding_circuits/codes/css/31_21_3.txt => src/mqt/qecc/codes/constructions/hamming/n31/hamming_31.txt (100%) rename {scripts/encoding_circuits/codes/non_css => src/mqt/qecc/codes/constructions/misc}/15_3_5.txt (100%) rename {scripts/encoding_circuits/codes/css => src/mqt/qecc/codes/constructions/misc}/30_6_5.txt (100%) rename {scripts/encoding_circuits/codes/non_css => src/mqt/qecc/codes/constructions/misc}/8_3_3.txt (100%) rename src/mqt/qecc/codes/constructions/{rotated_surface_d3 => rotated_surface/d3}/hx.npy (100%) rename src/mqt/qecc/codes/constructions/{rotated_surface_d3 => rotated_surface/d3}/hz.npy (100%) rename src/mqt/qecc/codes/constructions/{rotated_surface_d5 => rotated_surface/d5}/hx.npy (100%) rename src/mqt/qecc/codes/constructions/{rotated_surface_d5 => rotated_surface/d5}/hz.npy (100%) diff --git a/scripts/encoding_circuits/codes/css/15_1_3.txt b/scripts/encoding_circuits/codes/css/15_1_3.txt deleted file mode 100644 index 8abcc8a97..000000000 --- a/scripts/encoding_circuits/codes/css/15_1_3.txt +++ /dev/null @@ -1,15 +0,0 @@ -[[1 1 1 1 1 1 1 1 0 0 0 0 0 0 0] - [0 1 1 0 1 1 0 0 1 1 0 1 1 0 0] - [0 0 1 1 0 1 1 0 0 1 1 1 0 1 0] - [0 0 0 0 1 1 1 1 0 0 0 1 1 1 1]] - -[[1 1 1 1 0 0 0 0 0 0 0 0 0 0 0] - [0 1 1 0 1 1 0 0 0 0 0 0 0 0 0] - [0 0 1 1 0 1 1 0 0 0 0 0 0 0 0] - [0 0 0 0 1 1 1 1 0 0 0 0 0 0 0] - [0 1 0 0 1 0 0 0 1 0 0 0 1 0 0] - [0 0 1 0 0 1 0 0 0 1 0 1 0 0 0] - [0 0 1 1 0 0 0 0 0 1 1 0 0 0 0] - [0 0 0 0 1 1 0 0 0 0 0 1 1 0 0] - [0 0 0 0 0 1 1 0 0 0 0 1 0 1 0] - [0 0 0 0 0 0 1 1 0 0 0 0 0 1 1]] diff --git a/scripts/encoding_circuits/codes/css/15_7_3.txt b/scripts/encoding_circuits/codes/css/15_7_3.txt deleted file mode 100644 index b2e3fe5d5..000000000 --- a/scripts/encoding_circuits/codes/css/15_7_3.txt +++ /dev/null @@ -1,9 +0,0 @@ -[[0 0 0 0 0 0 0 1 1 1 1 1 1 1 1] - [0 0 0 1 1 1 1 0 0 0 0 1 1 1 1] - [0 1 1 0 0 1 1 0 0 1 1 0 0 1 1] - [1 0 1 0 1 0 1 0 1 0 1 0 1 0 1]] - -[[0 0 0 0 0 0 0 1 1 1 1 1 1 1 1] - [0 0 0 1 1 1 1 0 0 0 0 1 1 1 1] - [0 1 1 0 0 1 1 0 0 1 1 0 0 1 1] - [1 0 1 0 1 0 1 0 1 0 1 0 1 0 1]] diff --git a/scripts/encoding_circuits/codes/css/17_1_5.txt b/scripts/encoding_circuits/codes/css/17_1_5.txt deleted file mode 100644 index e69c45080..000000000 --- a/scripts/encoding_circuits/codes/css/17_1_5.txt +++ /dev/null @@ -1,17 +0,0 @@ -[[0 0 0 0 0 1 0 0 0 1 0 1 1 0 0 0 0] - [0 0 0 0 0 0 0 0 1 0 1 0 0 1 0 1 0] - [0 0 0 1 0 0 0 1 0 0 0 0 0 0 1 0 1] - [0 0 1 0 0 0 1 0 0 0 0 0 0 0 1 0 1] - [0 0 0 0 1 1 1 1 1 0 1 1 0 0 0 0 1] - [0 1 0 0 1 0 0 0 0 0 1 0 0 1 0 0 0] - [0 0 0 0 0 0 0 0 1 1 0 1 0 0 0 1 0] - [1 0 1 1 0 0 0 0 0 0 0 0 0 0 1 0 0]] - -[[0 0 0 0 0 1 0 0 0 1 0 1 1 0 0 0 0] - [0 0 0 0 0 0 0 0 1 0 1 0 0 1 0 1 0] - [0 0 0 1 0 0 0 1 0 0 0 0 0 0 1 0 1] - [0 0 1 0 0 0 1 0 0 0 0 0 0 0 1 0 1] - [0 0 0 0 1 1 1 1 1 0 1 1 0 0 0 0 1] - [0 1 0 0 1 0 0 0 0 0 1 0 0 1 0 0 0] - [0 0 0 0 0 0 0 0 1 1 0 1 0 0 0 1 0] - [1 0 1 1 0 0 0 0 0 0 0 0 0 0 1 0 0]] diff --git a/scripts/encoding_circuits/codes/css/23_1_7.txt b/scripts/encoding_circuits/codes/css/23_1_7.txt deleted file mode 100644 index f0ce1463d..000000000 --- a/scripts/encoding_circuits/codes/css/23_1_7.txt +++ /dev/null @@ -1,23 +0,0 @@ -[[0 1 0 0 1 0 0 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 1] - [1 0 0 1 0 0 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 1 0] - [0 1 1 0 1 1 1 0 0 0 1 1 0 0 0 0 0 0 0 0 1 0 0] - [1 1 0 1 1 1 0 0 0 1 1 0 0 0 0 0 0 0 0 1 0 0 0] - [1 1 1 1 0 0 0 1 0 0 1 1 0 0 0 0 0 0 1 0 0 0 0] - [1 0 1 0 1 0 1 1 1 0 0 1 0 0 0 0 0 1 0 0 0 0 0] - [0 0 0 1 1 1 1 0 1 1 0 1 0 0 0 0 1 0 0 0 0 0 0] - [0 0 1 1 1 1 0 1 1 0 1 0 0 0 0 1 0 0 0 0 0 0 0] - [0 1 1 1 1 0 1 1 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0] - [1 1 1 1 0 1 1 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 0] - [1 0 1 0 0 1 0 0 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0]] - -[[0 1 0 0 1 0 0 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 1] - [1 0 0 1 0 0 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 1 0] - [0 1 1 0 1 1 1 0 0 0 1 1 0 0 0 0 0 0 0 0 1 0 0] - [1 1 0 1 1 1 0 0 0 1 1 0 0 0 0 0 0 0 0 1 0 0 0] - [1 1 1 1 0 0 0 1 0 0 1 1 0 0 0 0 0 0 1 0 0 0 0] - [1 0 1 0 1 0 1 1 1 0 0 1 0 0 0 0 0 1 0 0 0 0 0] - [0 0 0 1 1 1 1 0 1 1 0 1 0 0 0 0 1 0 0 0 0 0 0] - [0 0 1 1 1 1 0 1 1 0 1 0 0 0 0 1 0 0 0 0 0 0 0] - [0 1 1 1 1 0 1 1 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0] - [1 1 1 1 0 1 1 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 0] - [1 0 1 0 0 1 0 0 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0]] diff --git a/scripts/encoding_circuits/codes/css/108_8_10.txt b/src/mqt/qecc/codes/constructions/bb/108_8_10.txt similarity index 100% rename from scripts/encoding_circuits/codes/css/108_8_10.txt rename to src/mqt/qecc/codes/constructions/bb/108_8_10.txt diff --git a/scripts/encoding_circuits/codes/css/144_12_12.txt b/src/mqt/qecc/codes/constructions/bb/144_12_12.txt similarity index 100% rename from scripts/encoding_circuits/codes/css/144_12_12.txt rename to src/mqt/qecc/codes/constructions/bb/144_12_12.txt diff --git a/scripts/encoding_circuits/codes/css/72_12_6.txt b/src/mqt/qecc/codes/constructions/bb/72_12_6.txt similarity index 100% rename from scripts/encoding_circuits/codes/css/72_12_6.txt rename to src/mqt/qecc/codes/constructions/bb/72_12_6.txt diff --git a/scripts/encoding_circuits/codes/css/90_8_10.txt b/src/mqt/qecc/codes/constructions/bb/90_8_10.txt similarity index 100% rename from scripts/encoding_circuits/codes/css/90_8_10.txt rename to src/mqt/qecc/codes/constructions/bb/90_8_10.txt diff --git a/scripts/encoding_circuits/codes/css/19_1_5.txt b/src/mqt/qecc/codes/constructions/cc/hexagonal/19_1_5.txt similarity index 100% rename from scripts/encoding_circuits/codes/css/19_1_5.txt rename to src/mqt/qecc/codes/constructions/cc/hexagonal/19_1_5.txt diff --git a/scripts/encoding_circuits/codes/css/37_1_7.txt b/src/mqt/qecc/codes/constructions/cc/hexagonal/37_1_7.txt similarity index 100% rename from scripts/encoding_circuits/codes/css/37_1_7.txt rename to src/mqt/qecc/codes/constructions/cc/hexagonal/37_1_7.txt diff --git a/scripts/encoding_circuits/codes/css/31_1_7.txt b/src/mqt/qecc/codes/constructions/cc/sqroct/31_1_7.txt similarity index 100% rename from scripts/encoding_circuits/codes/css/31_1_7.txt rename to src/mqt/qecc/codes/constructions/cc/sqroct/31_1_7.txt diff --git a/src/mqt/qecc/codes/constructions/cc_4_8_8_d5/hx.npy b/src/mqt/qecc/codes/constructions/cc/sqroct/d5/hx.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/cc_4_8_8_d5/hx.npy rename to src/mqt/qecc/codes/constructions/cc/sqroct/d5/hx.npy diff --git a/src/mqt/qecc/codes/constructions/cc_4_8_8_d5/hz.npy b/src/mqt/qecc/codes/constructions/cc/sqroct/d5/hz.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/cc_4_8_8_d5/hz.npy rename to src/mqt/qecc/codes/constructions/cc/sqroct/d5/hz.npy diff --git a/src/mqt/qecc/codes/constructions/steane/hx.npy b/src/mqt/qecc/codes/constructions/cc/steane/hx.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/steane/hx.npy rename to src/mqt/qecc/codes/constructions/cc/steane/hx.npy diff --git a/src/mqt/qecc/codes/constructions/steane/hz.npy b/src/mqt/qecc/codes/constructions/cc/steane/hz.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/steane/hz.npy rename to src/mqt/qecc/codes/constructions/cc/steane/hz.npy diff --git a/src/mqt/qecc/codes/constructions/tetrahedral/hx.npy b/src/mqt/qecc/codes/constructions/cc/tetrahedral/hx.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/tetrahedral/hx.npy rename to src/mqt/qecc/codes/constructions/cc/tetrahedral/hx.npy diff --git a/src/mqt/qecc/codes/constructions/tetrahedral/hz.npy b/src/mqt/qecc/codes/constructions/cc/tetrahedral/hz.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/tetrahedral/hz.npy rename to src/mqt/qecc/codes/constructions/cc/tetrahedral/hz.npy diff --git a/src/mqt/qecc/codes/constructions/hamming_15/hx.npy b/src/mqt/qecc/codes/constructions/hamming/n15/hx.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/hamming_15/hx.npy rename to src/mqt/qecc/codes/constructions/hamming/n15/hx.npy diff --git a/src/mqt/qecc/codes/constructions/hamming_15/hz.npy b/src/mqt/qecc/codes/constructions/hamming/n15/hz.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/hamming_15/hz.npy rename to src/mqt/qecc/codes/constructions/hamming/n15/hz.npy diff --git a/scripts/encoding_circuits/codes/css/31_21_3.txt b/src/mqt/qecc/codes/constructions/hamming/n31/hamming_31.txt similarity index 100% rename from scripts/encoding_circuits/codes/css/31_21_3.txt rename to src/mqt/qecc/codes/constructions/hamming/n31/hamming_31.txt diff --git a/scripts/encoding_circuits/codes/non_css/15_3_5.txt b/src/mqt/qecc/codes/constructions/misc/15_3_5.txt similarity index 100% rename from scripts/encoding_circuits/codes/non_css/15_3_5.txt rename to src/mqt/qecc/codes/constructions/misc/15_3_5.txt diff --git a/scripts/encoding_circuits/codes/css/30_6_5.txt b/src/mqt/qecc/codes/constructions/misc/30_6_5.txt similarity index 100% rename from scripts/encoding_circuits/codes/css/30_6_5.txt rename to src/mqt/qecc/codes/constructions/misc/30_6_5.txt diff --git a/scripts/encoding_circuits/codes/non_css/8_3_3.txt b/src/mqt/qecc/codes/constructions/misc/8_3_3.txt similarity index 100% rename from scripts/encoding_circuits/codes/non_css/8_3_3.txt rename to src/mqt/qecc/codes/constructions/misc/8_3_3.txt diff --git a/src/mqt/qecc/codes/constructions/rotated_surface_d3/hx.npy b/src/mqt/qecc/codes/constructions/rotated_surface/d3/hx.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/rotated_surface_d3/hx.npy rename to src/mqt/qecc/codes/constructions/rotated_surface/d3/hx.npy diff --git a/src/mqt/qecc/codes/constructions/rotated_surface_d3/hz.npy b/src/mqt/qecc/codes/constructions/rotated_surface/d3/hz.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/rotated_surface_d3/hz.npy rename to src/mqt/qecc/codes/constructions/rotated_surface/d3/hz.npy diff --git a/src/mqt/qecc/codes/constructions/rotated_surface_d5/hx.npy b/src/mqt/qecc/codes/constructions/rotated_surface/d5/hx.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/rotated_surface_d5/hx.npy rename to src/mqt/qecc/codes/constructions/rotated_surface/d5/hx.npy diff --git a/src/mqt/qecc/codes/constructions/rotated_surface_d5/hz.npy b/src/mqt/qecc/codes/constructions/rotated_surface/d5/hz.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/rotated_surface_d5/hz.npy rename to src/mqt/qecc/codes/constructions/rotated_surface/d5/hz.npy diff --git a/src/mqt/qecc/codes/core/css_code.py b/src/mqt/qecc/codes/core/css_code.py index 33a0823b5..6dfba2a95 100644 --- a/src/mqt/qecc/codes/core/css_code.py +++ b/src/mqt/qecc/codes/core/css_code.py @@ -204,14 +204,14 @@ def from_code_name(code_name: str, distance: int | None = None) -> CSSCode: """ prefix = (Path(__file__) / "../../constructions/").resolve() paths = { - "steane": prefix / "steane/", - "tetrahedral": prefix / "tetrahedral/", + "steane": prefix / "cc/steane/", + "tetrahedral": prefix / "cc/tetrahedral/", "shor": prefix / "shor/", - "surface_3": prefix / "rotated_surface_d3/", - "surface_5": prefix / "rotated_surface_d5/", + "surface_3": prefix / "rotated_surface/d3/", + "surface_5": prefix / "rotated_surface/d5/", "golay": prefix / "golay/", "carbon": prefix / "carbon/", - "hamming": prefix / "hamming_15/", + "hamming": prefix / "hamming/n15/", } distances = { From 9a4d73568f83836d0af76ad5f71f77c55c4cd575 Mon Sep 17 00:00:00 2001 From: Maxie Bichmann Date: Thu, 9 Jul 2026 14:57:35 +0200 Subject: [PATCH 04/29] =?UTF-8?q?=F0=9F=93=A6=20separate=20code=20generato?= =?UTF-8?q?rs=20from=20hardcoded=20code=20instances?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- scripts/examples/atd_example.py | 2 +- .../qecc/codes/constructions/bb/108_8_10.txt | 109 ------------- .../qecc/codes/constructions/bb/144_12_12.txt | 145 ------------------ .../qecc/codes/constructions/bb/72_12_6.txt | 73 --------- .../qecc/codes/constructions/bb/90_8_10.txt | 91 ----------- .../constructions/cc/hexagonal/19_1_5.txt | 19 --- .../constructions/cc/hexagonal/37_1_7.txt | 37 ----- .../codes/constructions/cc/sqroct/31_1_7.txt | 31 ---- .../codes/constructions/cc/sqroct/d5/hx.npy | Bin 1216 -> 0 bytes .../codes/constructions/cc/sqroct/d5/hz.npy | Bin 1216 -> 0 bytes .../constructions/hamming/n31/hamming_31.txt | 11 -- src/mqt/qecc/codes/core/css_code.py | 8 +- .../carbon/hx.npy | Bin .../carbon/hz.npy | Bin .../{constructions => instances}/golay/hx.npy | Bin .../{constructions => instances}/golay/hz.npy | Bin .../n15 => instances/hamming_15}/hx.npy | Bin .../n15 => instances/hamming_15}/hz.npy | Bin .../lifted_product/lp_l=16_hx.npz | Bin .../lifted_product/lp_l=16_hz.npz | Bin .../lifted_product/lp_l=21_hx.npz | Bin .../lifted_product/lp_l=21_hz.npz | Bin .../lifted_product/lp_l=30_hx.npz | Bin .../lifted_product/lp_l=30_hz.npz | Bin .../misc/15_3_5.txt | 0 .../misc/30_6_5.txt | 0 .../misc/8_3_3.txt | 0 .../rotated_surface/d3/hx.npy | Bin .../rotated_surface/d3/hz.npy | Bin .../rotated_surface/d5/hx.npy | Bin .../rotated_surface/d5/hz.npy | Bin .../{constructions => instances}/shor/hx.npy | Bin .../{constructions => instances}/shor/hz.npy | Bin .../cc => instances}/steane/hx.npy | Bin .../cc => instances}/steane/hz.npy | Bin .../cc => instances}/tetrahedral/hx.npy | Bin .../cc => instances}/tetrahedral/hz.npy | Bin 37 files changed, 5 insertions(+), 521 deletions(-) delete mode 100644 src/mqt/qecc/codes/constructions/bb/108_8_10.txt delete mode 100644 src/mqt/qecc/codes/constructions/bb/144_12_12.txt delete mode 100644 src/mqt/qecc/codes/constructions/bb/72_12_6.txt delete mode 100644 src/mqt/qecc/codes/constructions/bb/90_8_10.txt delete mode 100644 src/mqt/qecc/codes/constructions/cc/hexagonal/19_1_5.txt delete mode 100644 src/mqt/qecc/codes/constructions/cc/hexagonal/37_1_7.txt delete mode 100644 src/mqt/qecc/codes/constructions/cc/sqroct/31_1_7.txt delete mode 100644 src/mqt/qecc/codes/constructions/cc/sqroct/d5/hx.npy delete mode 100644 src/mqt/qecc/codes/constructions/cc/sqroct/d5/hz.npy delete mode 100644 src/mqt/qecc/codes/constructions/hamming/n31/hamming_31.txt rename src/mqt/qecc/codes/{constructions => instances}/carbon/hx.npy (100%) rename src/mqt/qecc/codes/{constructions => instances}/carbon/hz.npy (100%) rename src/mqt/qecc/codes/{constructions => instances}/golay/hx.npy (100%) rename src/mqt/qecc/codes/{constructions => instances}/golay/hz.npy (100%) rename src/mqt/qecc/codes/{constructions/hamming/n15 => instances/hamming_15}/hx.npy (100%) rename src/mqt/qecc/codes/{constructions/hamming/n15 => instances/hamming_15}/hz.npy (100%) rename src/mqt/qecc/codes/{constructions => instances}/lifted_product/lp_l=16_hx.npz (100%) rename src/mqt/qecc/codes/{constructions => instances}/lifted_product/lp_l=16_hz.npz (100%) rename src/mqt/qecc/codes/{constructions => instances}/lifted_product/lp_l=21_hx.npz (100%) rename src/mqt/qecc/codes/{constructions => instances}/lifted_product/lp_l=21_hz.npz (100%) rename src/mqt/qecc/codes/{constructions => instances}/lifted_product/lp_l=30_hx.npz (100%) rename src/mqt/qecc/codes/{constructions => instances}/lifted_product/lp_l=30_hz.npz (100%) rename src/mqt/qecc/codes/{constructions => instances}/misc/15_3_5.txt (100%) rename src/mqt/qecc/codes/{constructions => instances}/misc/30_6_5.txt (100%) rename src/mqt/qecc/codes/{constructions => instances}/misc/8_3_3.txt (100%) rename src/mqt/qecc/codes/{constructions => instances}/rotated_surface/d3/hx.npy (100%) rename src/mqt/qecc/codes/{constructions => instances}/rotated_surface/d3/hz.npy (100%) rename src/mqt/qecc/codes/{constructions => instances}/rotated_surface/d5/hx.npy (100%) rename src/mqt/qecc/codes/{constructions => instances}/rotated_surface/d5/hz.npy (100%) rename src/mqt/qecc/codes/{constructions => instances}/shor/hx.npy (100%) rename src/mqt/qecc/codes/{constructions => instances}/shor/hz.npy (100%) rename src/mqt/qecc/codes/{constructions/cc => instances}/steane/hx.npy (100%) rename src/mqt/qecc/codes/{constructions/cc => instances}/steane/hz.npy (100%) rename src/mqt/qecc/codes/{constructions/cc => instances}/tetrahedral/hx.npy (100%) rename src/mqt/qecc/codes/{constructions/cc => instances}/tetrahedral/hz.npy (100%) diff --git a/scripts/examples/atd_example.py b/scripts/examples/atd_example.py index b28b0b38e..061a75120 100644 --- a/scripts/examples/atd_example.py +++ b/scripts/examples/atd_example.py @@ -16,7 +16,7 @@ from mqt.qecc.analog_information_decoding.simulators.analog_tannergraph_decoding import AtdSimulator from mqt.qecc.analog_information_decoding.utils.data_utils import BpParams -code_path = "src/mqt/qecc/codes/constructions/lifted_product/lp_l=" +code_path = "src/mqt/qecc/codes/instances/lifted_product/lp_l=" s = np.linspace(0.10, 0.4, 11) p = 0.05 for bp_method in ["msl"]: diff --git a/src/mqt/qecc/codes/constructions/bb/108_8_10.txt b/src/mqt/qecc/codes/constructions/bb/108_8_10.txt deleted file mode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 0 0 0 1 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 0 0 0 -0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 0 0 -0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 0 diff --git a/src/mqt/qecc/codes/constructions/bb/72_12_6.txt b/src/mqt/qecc/codes/constructions/bb/72_12_6.txt deleted file mode 100644 index b56ecba29..000000000 --- a/src/mqt/qecc/codes/constructions/bb/72_12_6.txt +++ /dev/null @@ -1,73 +0,0 @@ -0 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 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0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 0 diff --git a/src/mqt/qecc/codes/constructions/bb/90_8_10.txt b/src/mqt/qecc/codes/constructions/bb/90_8_10.txt deleted file mode 100644 index 732f4e195..000000000 --- a/src/mqt/qecc/codes/constructions/bb/90_8_10.txt +++ /dev/null @@ -1,91 +0,0 @@ -1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -0 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 -0 0 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 -0 0 0 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 -0 0 0 0 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0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 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 diff --git a/src/mqt/qecc/codes/constructions/cc/hexagonal/19_1_5.txt b/src/mqt/qecc/codes/constructions/cc/hexagonal/19_1_5.txt deleted file mode 100644 index 19eb41761..000000000 --- a/src/mqt/qecc/codes/constructions/cc/hexagonal/19_1_5.txt +++ /dev/null @@ -1,19 +0,0 @@ -[[0 0 1 0 0 1 0 0 1 1 0 0 0 0 0 0 0 0 0] - [0 0 0 0 0 0 0 0 0 0 1 0 1 0 0 0 0 1 1] - [0 0 0 0 0 0 0 0 0 0 1 1 0 1 0 0 0 0 1] - [1 1 0 0 0 0 0 0 0 0 0 0 0 0 1 1 0 0 0] - [1 1 0 1 1 0 1 0 0 0 0 0 0 0 0 0 1 0 0] - [0 0 1 0 1 0 0 0 1 0 0 0 0 0 0 0 1 0 0] - [0 1 0 0 0 0 1 1 0 0 0 0 0 0 0 1 0 0 0] - [0 0 0 1 0 0 1 1 0 0 1 1 1 0 0 0 0 0 0] - [0 0 0 1 1 0 0 0 1 1 0 1 0 1 0 0 0 0 0]] - -[[0 0 1 0 0 1 0 0 1 1 0 0 0 0 0 0 0 0 0] - [0 0 0 0 0 0 0 0 0 0 1 0 1 0 0 0 0 1 1] - [0 0 0 0 0 0 0 0 0 0 1 1 0 1 0 0 0 0 1] - [1 1 0 0 0 0 0 0 0 0 0 0 0 0 1 1 0 0 0] - [1 1 0 1 1 0 1 0 0 0 0 0 0 0 0 0 1 0 0] - [0 0 1 0 1 0 0 0 1 0 0 0 0 0 0 0 1 0 0] - [0 1 0 0 0 0 1 1 0 0 0 0 0 0 0 1 0 0 0] - [0 0 0 1 0 0 1 1 0 0 1 1 1 0 0 0 0 0 0] - [0 0 0 1 1 0 0 0 1 1 0 1 0 1 0 0 0 0 0]] diff --git a/src/mqt/qecc/codes/constructions/cc/hexagonal/37_1_7.txt b/src/mqt/qecc/codes/constructions/cc/hexagonal/37_1_7.txt deleted file mode 100644 index 3278ba412..000000000 --- a/src/mqt/qecc/codes/constructions/cc/hexagonal/37_1_7.txt +++ /dev/null @@ -1,37 +0,0 @@ -[[0 0 0 0 1 0 0 0 0 0 1 0 0 0 1 0 1 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0] - [0 0 0 0 0 1 0 0 0 0 0 0 1 0 0 1 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0] - [0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 1 1 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0] - [0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0 0 0 0 1 1] - [0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 0 0 1 0 0 1 0 0 0 0 0 0 1] - [1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 0 0 0] - [0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 1 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0] - [1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 1 0 0 1 0 0 1 0 0 0 0] - [0 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0] - [0 1 1 0 0 0 0 1 1 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0] - [0 0 0 0 1 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0] - [0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 1 1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0 0] - [1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 1 0 0 1 0 0 1 0 0 0 0] - [0 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0] - [0 1 1 0 0 0 0 1 1 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0] - [0 0 0 0 1 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0] - [0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 1 1 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0] - [1 0 0 1 0 1 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0] - [0 0 1 0 0 0 0 0 0 0 0 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0] - [0 0 0 0 0 0 0 1 0 0 0 1 0 1 0 0 0 0 0 0 0 0 1 1 0 1 0 0 0 0 0 0 0 0 0 0 0] - [0 0 0 0 0 0 0 1 1 0 0 0 0 0 1 0 1 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0 0 0 0 0] - [0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 1 0 0 1 0 0 0 0 0 0 1 1 1 0 0 0] - [0 0 0 1 0 1 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1]] diff --git a/src/mqt/qecc/codes/constructions/cc/sqroct/31_1_7.txt b/src/mqt/qecc/codes/constructions/cc/sqroct/31_1_7.txt deleted file mode 100644 index a0cb9de50..000000000 --- a/src/mqt/qecc/codes/constructions/cc/sqroct/31_1_7.txt +++ /dev/null @@ -1,31 +0,0 @@ -[[0 0 1 0 0 1 0 0 0 0 0 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 1 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0] - [0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 1] - [0 1 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 1 0 0 0 0] - [0 0 0 0 0 0 1 1 0 0 0 0 0 0 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0] - [0 0 0 0 0 0 0 0 1 1 0 0 0 0 0 0 0 0 1 0 1 0 0 0 0 0 0 0 0 0 0] - [0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 1 0 0 1 0 0 1 0 0] - [0 0 0 1 0 0 0 0 0 0 1 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0] - [0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 1 1 0 0 0] - [0 0 0 0 0 1 1 0 0 0 0 0 1 0 0 1 1 0 0 0 0 0 1 0 0 0 0 0 1 1 0] - [0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 1 0 0 0 0 1 0 0 0 0 0 0 1] - [1 0 0 1 0 0 0 1 0 0 1 0 0 0 1 0 0 0 0 0 0 1 0 0 1 0 1 0 0 0 0] - [1 0 0 0 0 0 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0] - [0 1 0 0 0 0 0 0 1 1 0 0 0 0 1 1 1 0 0 0 0 0 0 0 1 0 0 0 0 0 1] - [0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 1 0 0 0 0 0 1 0 0 0 0 0]] diff --git a/src/mqt/qecc/codes/constructions/cc/sqroct/d5/hx.npy b/src/mqt/qecc/codes/constructions/cc/sqroct/d5/hx.npy deleted file mode 100644 index bad457128478260f67986fdee87420d506bfcb65..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1216 zcmchRy$ZrG7)8_7r^ptCEKU}2cC)y2aFSpn3SuP@7wJ>@!dCPw9|V6OW;xt*LvC(W zy;!aabx~K-__zsXs?BU)8mrB=4d>vF>ozq0;pgrUeedJWoqV5%rPbrf$m&l2dIp7h zo)lkocCgP-DofA(f02DCckxj6xiWiD?%<*9b7l6R+`&WH=gRCsxr2wY|2DsS=hHrQ R4-fet8R8)x;vpX5;T^}<8?pcZ diff --git a/src/mqt/qecc/codes/constructions/cc/sqroct/d5/hz.npy b/src/mqt/qecc/codes/constructions/cc/sqroct/d5/hz.npy deleted file mode 100644 index bad457128478260f67986fdee87420d506bfcb65..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1216 zcmchRy$ZrG7)8_7r^ptCEKU}2cC)y2aFSpn3SuP@7wJ>@!dCPw9|V6OW;xt*LvC(W zy;!aabx~K-__zsXs?BU)8mrB=4d>vF>ozq0;pgrUeedJWoqV5%rPbrf$m&l2dIp7h zo)lkocCgP-DofA(f02DCckxj6xiWiD?%<*9b7l6R+`&WH=gRCsxr2wY|2DsS=hHrQ R4-fet8R8)x;vpX5;T^}<8?pcZ diff --git a/src/mqt/qecc/codes/constructions/hamming/n31/hamming_31.txt b/src/mqt/qecc/codes/constructions/hamming/n31/hamming_31.txt deleted file mode 100644 index 8e78dc66c..000000000 --- a/src/mqt/qecc/codes/constructions/hamming/n31/hamming_31.txt +++ /dev/null @@ -1,11 +0,0 @@ -[[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1] - [0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1] - [0 0 0 1 1 1 1 0 0 0 0 1 1 1 1 0 0 0 0 1 1 1 1 0 0 0 0 1 1 1 1] - [0 1 1 0 0 1 1 0 0 1 1 0 0 1 1 0 0 1 1 0 0 1 1 0 0 1 1 0 0 1 1] - [1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1]] - -[[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1] - [0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1] - [0 0 0 1 1 1 1 0 0 0 0 1 1 1 1 0 0 0 0 1 1 1 1 0 0 0 0 1 1 1 1] - [0 1 1 0 0 1 1 0 0 1 1 0 0 1 1 0 0 1 1 0 0 1 1 0 0 1 1 0 0 1 1] - [1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1]] diff --git a/src/mqt/qecc/codes/core/css_code.py b/src/mqt/qecc/codes/core/css_code.py index 6dfba2a95..681caa896 100644 --- a/src/mqt/qecc/codes/core/css_code.py +++ b/src/mqt/qecc/codes/core/css_code.py @@ -202,16 +202,16 @@ def from_code_name(code_name: str, distance: int | None = None) -> CSSCode: code_name: The name of the code. distance: The distance of the code. """ - prefix = (Path(__file__) / "../../constructions/").resolve() + prefix = (Path(__file__) / "../../instances/").resolve() paths = { - "steane": prefix / "cc/steane/", - "tetrahedral": prefix / "cc/tetrahedral/", + "steane": prefix / "steane/", + "tetrahedral": prefix / "tetrahedral/", "shor": prefix / "shor/", "surface_3": prefix / "rotated_surface/d3/", "surface_5": prefix / "rotated_surface/d5/", "golay": prefix / "golay/", "carbon": prefix / "carbon/", - "hamming": prefix / "hamming/n15/", + "hamming": prefix / "hamming_15/", } distances = { diff --git a/src/mqt/qecc/codes/constructions/carbon/hx.npy b/src/mqt/qecc/codes/instances/carbon/hx.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/carbon/hx.npy rename to src/mqt/qecc/codes/instances/carbon/hx.npy diff --git a/src/mqt/qecc/codes/constructions/carbon/hz.npy b/src/mqt/qecc/codes/instances/carbon/hz.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/carbon/hz.npy rename to src/mqt/qecc/codes/instances/carbon/hz.npy diff --git a/src/mqt/qecc/codes/constructions/golay/hx.npy b/src/mqt/qecc/codes/instances/golay/hx.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/golay/hx.npy rename to src/mqt/qecc/codes/instances/golay/hx.npy diff --git a/src/mqt/qecc/codes/constructions/golay/hz.npy b/src/mqt/qecc/codes/instances/golay/hz.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/golay/hz.npy rename to src/mqt/qecc/codes/instances/golay/hz.npy diff --git a/src/mqt/qecc/codes/constructions/hamming/n15/hx.npy b/src/mqt/qecc/codes/instances/hamming_15/hx.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/hamming/n15/hx.npy rename to src/mqt/qecc/codes/instances/hamming_15/hx.npy diff --git a/src/mqt/qecc/codes/constructions/hamming/n15/hz.npy b/src/mqt/qecc/codes/instances/hamming_15/hz.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/hamming/n15/hz.npy rename to src/mqt/qecc/codes/instances/hamming_15/hz.npy diff --git a/src/mqt/qecc/codes/constructions/lifted_product/lp_l=16_hx.npz b/src/mqt/qecc/codes/instances/lifted_product/lp_l=16_hx.npz similarity index 100% rename from src/mqt/qecc/codes/constructions/lifted_product/lp_l=16_hx.npz rename to src/mqt/qecc/codes/instances/lifted_product/lp_l=16_hx.npz diff --git a/src/mqt/qecc/codes/constructions/lifted_product/lp_l=16_hz.npz b/src/mqt/qecc/codes/instances/lifted_product/lp_l=16_hz.npz similarity index 100% rename from src/mqt/qecc/codes/constructions/lifted_product/lp_l=16_hz.npz rename to src/mqt/qecc/codes/instances/lifted_product/lp_l=16_hz.npz diff --git a/src/mqt/qecc/codes/constructions/lifted_product/lp_l=21_hx.npz b/src/mqt/qecc/codes/instances/lifted_product/lp_l=21_hx.npz similarity index 100% rename from src/mqt/qecc/codes/constructions/lifted_product/lp_l=21_hx.npz rename to src/mqt/qecc/codes/instances/lifted_product/lp_l=21_hx.npz diff --git a/src/mqt/qecc/codes/constructions/lifted_product/lp_l=21_hz.npz b/src/mqt/qecc/codes/instances/lifted_product/lp_l=21_hz.npz similarity index 100% rename from src/mqt/qecc/codes/constructions/lifted_product/lp_l=21_hz.npz rename to src/mqt/qecc/codes/instances/lifted_product/lp_l=21_hz.npz diff --git a/src/mqt/qecc/codes/constructions/lifted_product/lp_l=30_hx.npz b/src/mqt/qecc/codes/instances/lifted_product/lp_l=30_hx.npz similarity index 100% rename from src/mqt/qecc/codes/constructions/lifted_product/lp_l=30_hx.npz rename to src/mqt/qecc/codes/instances/lifted_product/lp_l=30_hx.npz diff --git a/src/mqt/qecc/codes/constructions/lifted_product/lp_l=30_hz.npz b/src/mqt/qecc/codes/instances/lifted_product/lp_l=30_hz.npz similarity index 100% rename from src/mqt/qecc/codes/constructions/lifted_product/lp_l=30_hz.npz rename to src/mqt/qecc/codes/instances/lifted_product/lp_l=30_hz.npz diff --git a/src/mqt/qecc/codes/constructions/misc/15_3_5.txt b/src/mqt/qecc/codes/instances/misc/15_3_5.txt similarity index 100% rename from src/mqt/qecc/codes/constructions/misc/15_3_5.txt rename to src/mqt/qecc/codes/instances/misc/15_3_5.txt diff --git a/src/mqt/qecc/codes/constructions/misc/30_6_5.txt b/src/mqt/qecc/codes/instances/misc/30_6_5.txt similarity index 100% rename from src/mqt/qecc/codes/constructions/misc/30_6_5.txt rename to src/mqt/qecc/codes/instances/misc/30_6_5.txt diff --git a/src/mqt/qecc/codes/constructions/misc/8_3_3.txt b/src/mqt/qecc/codes/instances/misc/8_3_3.txt similarity index 100% rename from src/mqt/qecc/codes/constructions/misc/8_3_3.txt rename to src/mqt/qecc/codes/instances/misc/8_3_3.txt diff --git a/src/mqt/qecc/codes/constructions/rotated_surface/d3/hx.npy b/src/mqt/qecc/codes/instances/rotated_surface/d3/hx.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/rotated_surface/d3/hx.npy rename to src/mqt/qecc/codes/instances/rotated_surface/d3/hx.npy diff --git a/src/mqt/qecc/codes/constructions/rotated_surface/d3/hz.npy b/src/mqt/qecc/codes/instances/rotated_surface/d3/hz.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/rotated_surface/d3/hz.npy rename to src/mqt/qecc/codes/instances/rotated_surface/d3/hz.npy diff --git a/src/mqt/qecc/codes/constructions/rotated_surface/d5/hx.npy b/src/mqt/qecc/codes/instances/rotated_surface/d5/hx.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/rotated_surface/d5/hx.npy rename to src/mqt/qecc/codes/instances/rotated_surface/d5/hx.npy diff --git a/src/mqt/qecc/codes/constructions/rotated_surface/d5/hz.npy b/src/mqt/qecc/codes/instances/rotated_surface/d5/hz.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/rotated_surface/d5/hz.npy rename to src/mqt/qecc/codes/instances/rotated_surface/d5/hz.npy diff --git a/src/mqt/qecc/codes/constructions/shor/hx.npy b/src/mqt/qecc/codes/instances/shor/hx.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/shor/hx.npy rename to src/mqt/qecc/codes/instances/shor/hx.npy diff --git a/src/mqt/qecc/codes/constructions/shor/hz.npy b/src/mqt/qecc/codes/instances/shor/hz.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/shor/hz.npy rename to src/mqt/qecc/codes/instances/shor/hz.npy diff --git a/src/mqt/qecc/codes/constructions/cc/steane/hx.npy b/src/mqt/qecc/codes/instances/steane/hx.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/cc/steane/hx.npy rename to src/mqt/qecc/codes/instances/steane/hx.npy diff --git a/src/mqt/qecc/codes/constructions/cc/steane/hz.npy b/src/mqt/qecc/codes/instances/steane/hz.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/cc/steane/hz.npy rename to src/mqt/qecc/codes/instances/steane/hz.npy diff --git a/src/mqt/qecc/codes/constructions/cc/tetrahedral/hx.npy b/src/mqt/qecc/codes/instances/tetrahedral/hx.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/cc/tetrahedral/hx.npy rename to src/mqt/qecc/codes/instances/tetrahedral/hx.npy diff --git a/src/mqt/qecc/codes/constructions/cc/tetrahedral/hz.npy b/src/mqt/qecc/codes/instances/tetrahedral/hz.npy similarity index 100% rename from src/mqt/qecc/codes/constructions/cc/tetrahedral/hz.npy rename to src/mqt/qecc/codes/instances/tetrahedral/hz.npy From 1bcce64308b416ffab1b333672a462d47d89534e Mon Sep 17 00:00:00 2001 From: Maxie Bichmann Date: Thu, 9 Jul 2026 15:09:13 +0200 Subject: [PATCH 05/29] =?UTF-8?q?=F0=9F=93=A6=20remove=20specific=20code?= =?UTF-8?q?=20constructions=20from=20infra=20class=20CSSCode?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../eval/estimate_logical_error_rate.py | 4 ++-- src/mqt/qecc/codes/core/css_code.py | 14 -------------- tests/circuit_synthesis/test_deterministic.py | 5 +++-- tests/circuit_synthesis/test_encoder_synthesis.py | 14 ++++++++++---- tests/circuit_synthesis/test_stateprep.py | 4 ++-- 5 files changed, 17 insertions(+), 24 deletions(-) diff --git a/scripts/ft_stateprep/eval/estimate_logical_error_rate.py b/scripts/ft_stateprep/eval/estimate_logical_error_rate.py index 1f057b610..a053181ce 100644 --- a/scripts/ft_stateprep/eval/estimate_logical_error_rate.py +++ b/scripts/ft_stateprep/eval/estimate_logical_error_rate.py @@ -23,7 +23,7 @@ heuristic_verification_circuit, naive_verification_circuit, ) -from mqt.qecc.codes import HexagonalColorCode, SquareOctagonColorCode +from mqt.qecc.codes import HexagonalColorCode, RotatedSurfaceCode, SquareOctagonColorCode def main() -> None: @@ -57,7 +57,7 @@ def main() -> None: code_name = args.code if "surface" in code_name: d = args.distance - code = CSSCode.from_code_name("surface", d) + code = RotatedSurfaceCode(d) code_name = f"rotated_surface_d{d}" elif "cc_4_8_8" in code_name: d = 5 diff --git a/src/mqt/qecc/codes/core/css_code.py b/src/mqt/qecc/codes/core/css_code.py index 681caa896..e7489d227 100644 --- a/src/mqt/qecc/codes/core/css_code.py +++ b/src/mqt/qecc/codes/core/css_code.py @@ -193,9 +193,6 @@ def from_code_name(code_name: str, distance: int | None = None) -> CSSCode: - [[15, 1, 3]] tetrahedral code (\"Tetrahedral\") - [[9, 1, 3]] Shore code (\"Shor\") - [[12, 2, 4]] Carbon Code (\"Carbon\") - - [[9, 1, 3]] rotated surface code (\"Surface, 3\"), also default when no distance is given - - [[25, 1, 5]] rotated surface code (\"Surface, 5\") - - [[15, 7, 3]] Hamming code (\"Hamming\") - [[23, 1, 7]] golay code (\"Golay\") Args: @@ -207,11 +204,8 @@ def from_code_name(code_name: str, distance: int | None = None) -> CSSCode: "steane": prefix / "steane/", "tetrahedral": prefix / "tetrahedral/", "shor": prefix / "shor/", - "surface_3": prefix / "rotated_surface/d3/", - "surface_5": prefix / "rotated_surface/d5/", "golay": prefix / "golay/", "carbon": prefix / "carbon/", - "hamming": prefix / "hamming_15/", } distances = { @@ -219,18 +213,10 @@ def from_code_name(code_name: str, distance: int | None = None) -> CSSCode: "tetrahedral": (7, 3), "shor": (3, 3), "golay": (7, 7), - "surface_3": (3, 3), - "surface_5": (5, 5), "carbon": (4, 4), - "hamming": (3, 3), } # X, Z distances code_name = code_name.lower() - if code_name == "surface": - if distance is None: - distance = 3 - code_name += f"_{distance}" - if code_name in paths: hx = np.load(paths[code_name] / "hx.npy") hz = np.load(paths[code_name] / "hz.npy") diff --git a/tests/circuit_synthesis/test_deterministic.py b/tests/circuit_synthesis/test_deterministic.py index 4362141d5..5b0f946ac 100644 --- a/tests/circuit_synthesis/test_deterministic.py +++ b/tests/circuit_synthesis/test_deterministic.py @@ -17,6 +17,7 @@ from mqt.qecc import CSSCode from mqt.qecc.circuit_synthesis import CNOTCircuit, DeterministicVerificationHelper, FaultyStatePrepCircuit +from mqt.qecc.codes import RotatedSurfaceCode from .utils import in_span @@ -77,7 +78,7 @@ def verified_steane_data( @pytest.fixture(scope="module") def surface_code_sp_zero() -> FaultyStatePrepCircuit: """Return a non-ft state preparation circuit for the d=3 rotated surface code.""" - surface_code = CSSCode.from_code_name("surface", 3) + surface_code = RotatedSurfaceCode(3) sp_circ = FaultyStatePrepCircuit( CNOTCircuit.from_stim_circuit( stim.Circuit( @@ -295,7 +296,7 @@ def test_surface_det_simulation( """Test simulated logical error rate for deterministic Steane state preparation.""" verify_x_opt, verify_z_opt, verify_x_global, verify_z_global = verified_surface_data - code = CSSCode.from_code_name("surface", 3) + code = RotatedSurfaceCode(3) for verify_x, verify_z in zip((verify_x_opt, verify_x_global), (verify_z_opt, verify_z_global), strict=False): simulator = NoisyDFTStatePrepSimulator( surface_code_sp_zero.circ.to_qiskit_circuit(), (verify_x, verify_z), code, err_model, True diff --git a/tests/circuit_synthesis/test_encoder_synthesis.py b/tests/circuit_synthesis/test_encoder_synthesis.py index 87ad20ad9..307b32894 100644 --- a/tests/circuit_synthesis/test_encoder_synthesis.py +++ b/tests/circuit_synthesis/test_encoder_synthesis.py @@ -30,7 +30,13 @@ synthesize_encoding_circuit, ) from mqt.qecc.circuit_synthesis.synthesis import SynthesisConfig -from mqt.qecc.codes import CSSCode, SquareOctagonColorCode, StabilizerCode, construct_quantum_hamming_code +from mqt.qecc.codes import ( + CSSCode, + RotatedSurfaceCode, + SquareOctagonColorCode, + StabilizerCode, + construct_quantum_hamming_code, +) from mqt.qecc.codes.core.pauli import Pauli, StabilizerTableau @@ -43,7 +49,7 @@ def steane_code() -> CSSCode: @pytest.fixture def surface_3() -> CSSCode: """Return the surface code.""" - return CSSCode.from_code_name("surface", 3) + return RotatedSurfaceCode(3) @pytest.fixture @@ -55,7 +61,7 @@ def tetrahedral() -> CSSCode: @pytest.fixture def hamming() -> CSSCode: """Return the Hamming code.""" - return CSSCode.from_code_name("Hamming") + return construct_quantum_hamming_code(4) @pytest.fixture @@ -372,7 +378,7 @@ def test_logical_mapping_non_css() -> None: def test_logical_mapping_css() -> None: """Test that logical to input mapping is correct for CSS codes.""" - code = CSSCode.from_code_name("Hamming") + code = construct_quantum_hamming_code(4) encoder = synthesize_encoding_circuit(code) mapping = encoder.logical_to_input_mapping(code) diff --git a/tests/circuit_synthesis/test_stateprep.py b/tests/circuit_synthesis/test_stateprep.py index 5abfba631..04f8eb39b 100644 --- a/tests/circuit_synthesis/test_stateprep.py +++ b/tests/circuit_synthesis/test_stateprep.py @@ -26,7 +26,7 @@ heuristic_verification_circuit, heuristic_verification_stabilizers, ) -from mqt.qecc.codes import SquareOctagonColorCode +from mqt.qecc.codes import RotatedSurfaceCode, SquareOctagonColorCode from .utils import eq_span, in_span @@ -55,7 +55,7 @@ def css_6_2_2_code() -> CSSCode: @pytest.fixture(scope="session") def surface_code() -> CSSCode: """Return the distance 3 rotated Surface Code.""" - return CSSCode.from_code_name("surface", 3) + return RotatedSurfaceCode(3) @pytest.fixture(scope="session") From cd401469742fc64d0218d40414a6924e481d157d Mon Sep 17 00:00:00 2001 From: Maxie Bichmann Date: Thu, 9 Jul 2026 15:25:03 +0200 Subject: [PATCH 06/29] =?UTF-8?q?=F0=9F=9B=A0=EF=B8=8F=20fix=20file=20exte?= =?UTF-8?q?nsion?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- scripts/examples/atd_example.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/scripts/examples/atd_example.py b/scripts/examples/atd_example.py index 061a75120..d506763d6 100644 --- a/scripts/examples/atd_example.py +++ b/scripts/examples/atd_example.py @@ -22,10 +22,10 @@ for bp_method in ["msl"]: for decoder in ["atd"]: for c in [16, 21, 30]: - Hx = scipy.sparse.load_npz(code_path + str(c) + "_hx.txt").toarray() - Hz = scipy.sparse.load_npz(code_path + str(c) + "_hz.txt").toarray() - Lx = scipy.sparse.load_npz(code_path + str(c) + "_lx.txt").toarray() - Lz = scipy.sparse.load_npz(code_path + str(c) + "_lz.txt").toarray() + Hx = scipy.sparse.load_npz(code_path + str(c) + "_hx.npz").toarray() + Hz = scipy.sparse.load_npz(code_path + str(c) + "_hz.npz").toarray() + Lx = scipy.sparse.load_npz(code_path + str(c) + "_lx.npz").toarray() + Lz = scipy.sparse.load_npz(code_path + str(c) + "_lz.npz").toarray() lers = [] ebs = [] for sigma in s: From 32355aedd0625303d4afbd99e04c7744322103a4 Mon Sep 17 00:00:00 2001 From: Maxie Bichmann Date: Thu, 9 Jul 2026 15:25:53 +0200 Subject: [PATCH 07/29] =?UTF-8?q?=F0=9F=93=A6=20remove=20unnecessary=20har?= =?UTF-8?q?dcoded=20code=20instances?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/mqt/qecc/codes/instances/hamming_15/hx.npy | Bin 608 -> 0 bytes src/mqt/qecc/codes/instances/hamming_15/hz.npy | Bin 608 -> 0 bytes .../codes/instances/rotated_surface/d3/hx.npy | Bin 416 -> 0 bytes .../codes/instances/rotated_surface/d3/hz.npy | Bin 416 -> 0 bytes .../codes/instances/rotated_surface/d5/hx.npy | Bin 2528 -> 0 bytes .../codes/instances/rotated_surface/d5/hz.npy | Bin 2528 -> 0 bytes 6 files changed, 0 insertions(+), 0 deletions(-) delete mode 100644 src/mqt/qecc/codes/instances/hamming_15/hx.npy delete mode 100644 src/mqt/qecc/codes/instances/hamming_15/hz.npy delete mode 100644 src/mqt/qecc/codes/instances/rotated_surface/d3/hx.npy delete mode 100644 src/mqt/qecc/codes/instances/rotated_surface/d3/hz.npy delete mode 100644 src/mqt/qecc/codes/instances/rotated_surface/d5/hx.npy delete mode 100644 src/mqt/qecc/codes/instances/rotated_surface/d5/hz.npy diff --git a/src/mqt/qecc/codes/instances/hamming_15/hx.npy b/src/mqt/qecc/codes/instances/hamming_15/hx.npy deleted file mode 100644 index eb25185f239b9d4ed6a695296e5d8080f189f09d..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 608 zcmbR27wQ`j$;eQ~P_3SlTAW;@Zl$1ZlWC!@qoAIaUsO_*m=~X4l#&V(cT3DEP6dh= zXCxM+0{I#yItqrSnmP)#3giMV1~LI7R3EuCE^7&yhf5z!oLK$n>R|d|G_~bn=AoNU GYd!!SJ{zb2 diff --git a/src/mqt/qecc/codes/instances/hamming_15/hz.npy b/src/mqt/qecc/codes/instances/hamming_15/hz.npy deleted file mode 100644 index eb25185f239b9d4ed6a695296e5d8080f189f09d..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 608 zcmbR27wQ`j$;eQ~P_3SlTAW;@Zl$1ZlWC!@qoAIaUsO_*m=~X4l#&V(cT3DEP6dh= zXCxM+0{I#yItqrSnmP)#3giMV1~LI7R3EuCE^7&yhf5z!oLK$n>R|d|G_~bn=AoNU GYd!!SJ{zb2 diff --git a/src/mqt/qecc/codes/instances/rotated_surface/d3/hx.npy b/src/mqt/qecc/codes/instances/rotated_surface/d3/hx.npy deleted file mode 100644 index 8fddc13b755dc2dceecb020662874c8a8c2f358c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 416 zcmbR27wQ`j$;eQ~P_3SlTAW;@Zl$1ZlWC!@qoAIaUsO_*m=~X4l#&V(cT3DEP6dh= zXCxM+0{I#yItrGWItsN4WCJcn1_*%BP%ZD<(JY4d) F!~stV8;1Y@ diff --git a/src/mqt/qecc/codes/instances/rotated_surface/d3/hz.npy b/src/mqt/qecc/codes/instances/rotated_surface/d3/hz.npy deleted file mode 100644 index 14ef18179171a2d9eb173e99ebca75a5094f06a4..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 416 zcmbR27wQ`j$;eQ~P_3SlTAW;@Zl$1ZlWC!@qoAIaUsO_*m=~X4l#&V(cT3DEP6dh= zXCxM+0{I#yItrGWItsN4WCJcn1_*%BP%haN%p4dEGYH0q(J*mhX_!734bunX!)TZ| Kxirii7!3eUdK-rT diff --git a/src/mqt/qecc/codes/instances/rotated_surface/d5/hx.npy b/src/mqt/qecc/codes/instances/rotated_surface/d5/hx.npy deleted file mode 100644 index b456ca4197cb780e7f90a66e31f720d4f3d04262..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2528 zcmdUqF$%&!6hxEOQ*5^iX$%M=)^>`Gg_Q)eq97)0#6~=Y7dE1=oI)+~-R7|~L-O{% zSk0H~G`S>KUxsEI{lxj{VeB*KcU3&c; Date: Thu, 9 Jul 2026 16:10:01 +0200 Subject: [PATCH 08/29] =?UTF-8?q?=F0=9F=93=A6=20add=20more=20structure=20d?= =?UTF-8?q?o=20code=20constructions?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/mqt/qecc/cc_decoder/__init__.py | 6 +++--- src/mqt/qecc/cc_decoder/decoder.py | 2 +- src/mqt/qecc/cc_decoder/utils.py | 8 ++++---- src/mqt/qecc/codes/__init__.py | 6 +++--- src/mqt/qecc/codes/constructions/color_codes/__init__.py | 8 ++++++++ .../codes/constructions/{ => color_codes}/color_code.py | 2 +- .../{ => color_codes}/hexagonal_color_code.py | 0 .../{ => color_codes}/square_octagon_color_code.py | 0 8 files changed, 20 insertions(+), 12 deletions(-) create mode 100644 src/mqt/qecc/codes/constructions/color_codes/__init__.py rename src/mqt/qecc/codes/constructions/{ => color_codes}/color_code.py (98%) rename src/mqt/qecc/codes/constructions/{ => color_codes}/hexagonal_color_code.py (100%) rename src/mqt/qecc/codes/constructions/{ => color_codes}/square_octagon_color_code.py (100%) diff --git a/src/mqt/qecc/cc_decoder/__init__.py b/src/mqt/qecc/cc_decoder/__init__.py index d9cb1058d..8eb489f0e 100644 --- a/src/mqt/qecc/cc_decoder/__init__.py +++ b/src/mqt/qecc/cc_decoder/__init__.py @@ -9,9 +9,9 @@ from __future__ import annotations -from ..codes.constructions.color_code import ColorCode, LatticeType -from ..codes.constructions.hexagonal_color_code import HexagonalColorCode -from ..codes.constructions.square_octagon_color_code import SquareOctagonColorCode +from ..codes.constructions.color_codes.color_code import ColorCode, LatticeType +from ..codes.constructions.color_codes.hexagonal_color_code import HexagonalColorCode +from ..codes.constructions.color_codes.square_octagon_color_code import SquareOctagonColorCode from .comparison import tn_decoder from .utils import code_from_string diff --git a/src/mqt/qecc/cc_decoder/decoder.py b/src/mqt/qecc/cc_decoder/decoder.py index 2c24a0224..2a7cfd013 100644 --- a/src/mqt/qecc/cc_decoder/decoder.py +++ b/src/mqt/qecc/cc_decoder/decoder.py @@ -26,7 +26,7 @@ import numpy.typing as npt from z3 import BoolRef, ModelRef - from ..codes.constructions.color_code import ColorCode + from ..codes.constructions.color_codes.color_code import ColorCode @dataclass diff --git a/src/mqt/qecc/cc_decoder/utils.py b/src/mqt/qecc/cc_decoder/utils.py index 7b0601535..77998a2f6 100644 --- a/src/mqt/qecc/cc_decoder/utils.py +++ b/src/mqt/qecc/cc_decoder/utils.py @@ -11,12 +11,12 @@ from typing import TYPE_CHECKING -from ..codes.constructions.color_code import LatticeType -from ..codes.constructions.hexagonal_color_code import HexagonalColorCode -from ..codes.constructions.square_octagon_color_code import SquareOctagonColorCode +from ..codes.constructions.color_codes.color_code import LatticeType +from ..codes.constructions.color_codes.hexagonal_color_code import HexagonalColorCode +from ..codes.constructions.color_codes.square_octagon_color_code import SquareOctagonColorCode if TYPE_CHECKING: - from ..codes.constructions.color_code import ColorCode + from ..codes.constructions.color_codes.color_code import ColorCode def code_from_string(lattice_type: str, distance: int) -> ColorCode: diff --git a/src/mqt/qecc/codes/__init__.py b/src/mqt/qecc/codes/__init__.py index a68319785..4e6b55cf8 100644 --- a/src/mqt/qecc/codes/__init__.py +++ b/src/mqt/qecc/codes/__init__.py @@ -10,16 +10,16 @@ from __future__ import annotations from .constructions.bb_codes import construct_bb_code -from .constructions.color_code import ColorCode, LatticeType +from .constructions.color_codes.color_code import ColorCode, LatticeType +from .constructions.color_codes.hexagonal_color_code import HexagonalColorCode +from .constructions.color_codes.square_octagon_color_code import SquareOctagonColorCode from .constructions.concatenation import ConcatenatedCode, ConcatenatedCSSCode from .constructions.constructions import ( construct_iceberg_code, construct_many_hypercube_code, construct_quantum_hamming_code, ) -from .constructions.hexagonal_color_code import HexagonalColorCode from .constructions.rotated_surface_code import InvalidDistanceError, RotatedSurfaceCode -from .constructions.square_octagon_color_code import SquareOctagonColorCode from .core.css_code import CSSCode, InvalidCSSCodeError from .core.stabilizer_code import InvalidStabilizerCodeError, StabilizerCode diff --git a/src/mqt/qecc/codes/constructions/color_codes/__init__.py b/src/mqt/qecc/codes/constructions/color_codes/__init__.py new file mode 100644 index 000000000..cadced227 --- /dev/null +++ b/src/mqt/qecc/codes/constructions/color_codes/__init__.py @@ -0,0 +1,8 @@ +# Copyright (c) 2023 - 2026 Chair for Design Automation, TUM +# All rights reserved. +# +# SPDX-License-Identifier: MIT +# +# Licensed under the MIT License + +"""Color codes and their constructions.""" diff --git a/src/mqt/qecc/codes/constructions/color_code.py b/src/mqt/qecc/codes/constructions/color_codes/color_code.py similarity index 98% rename from src/mqt/qecc/codes/constructions/color_code.py rename to src/mqt/qecc/codes/constructions/color_codes/color_code.py index c0728fb53..b80deb6e2 100644 --- a/src/mqt/qecc/codes/constructions/color_code.py +++ b/src/mqt/qecc/codes/constructions/color_codes/color_code.py @@ -14,7 +14,7 @@ import numpy as np -from ..core.css_code import CSSCode +from ...core.css_code import CSSCode if TYPE_CHECKING: import numpy.typing as npt diff --git a/src/mqt/qecc/codes/constructions/hexagonal_color_code.py b/src/mqt/qecc/codes/constructions/color_codes/hexagonal_color_code.py similarity index 100% rename from src/mqt/qecc/codes/constructions/hexagonal_color_code.py rename to src/mqt/qecc/codes/constructions/color_codes/hexagonal_color_code.py diff --git a/src/mqt/qecc/codes/constructions/square_octagon_color_code.py b/src/mqt/qecc/codes/constructions/color_codes/square_octagon_color_code.py similarity index 100% rename from src/mqt/qecc/codes/constructions/square_octagon_color_code.py rename to src/mqt/qecc/codes/constructions/color_codes/square_octagon_color_code.py From 1a7533e3041615823812d64b91365d5a10f4044f Mon Sep 17 00:00:00 2001 From: Maxie Bichmann Date: Thu, 9 Jul 2026 20:21:17 +0200 Subject: [PATCH 09/29] =?UTF-8?q?=F0=9F=93=A6=20Add=20basic=20tests=20to?= =?UTF-8?q?=20HGP=20codes?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../code_construction/code_constructor.py | 2 +- .../sparse_code_constructor.py | 2 +- ...uct_code.py => hypergraph_product_code.py} | 24 ++--- .../test_hypergraph_product_codes.py | 89 +++++++++++++++++++ 4 files changed, 103 insertions(+), 14 deletions(-) rename src/mqt/qecc/codes/constructions/{product_code.py => hypergraph_product_code.py} (88%) create mode 100644 tests/analog_info/test_hypergraph_product_codes.py diff --git a/src/mqt/qecc/analog_information_decoding/code_construction/code_constructor.py b/src/mqt/qecc/analog_information_decoding/code_construction/code_constructor.py index 93da046d2..3fc404134 100644 --- a/src/mqt/qecc/analog_information_decoding/code_construction/code_constructor.py +++ b/src/mqt/qecc/analog_information_decoding/code_construction/code_constructor.py @@ -21,7 +21,7 @@ from bposd.hgp import hgp from scipy import sparse -from ...codes.constructions.product_code import generate_3d_product_code, generate_4d_product_code +from ...codes.constructions.hypergraph_product_code import generate_3d_product_code, generate_4d_product_code if TYPE_CHECKING: from numpy.typing import NDArray diff --git a/src/mqt/qecc/analog_information_decoding/code_construction/sparse_code_constructor.py b/src/mqt/qecc/analog_information_decoding/code_construction/sparse_code_constructor.py index 3b362cec8..3a7fa2916 100644 --- a/src/mqt/qecc/analog_information_decoding/code_construction/sparse_code_constructor.py +++ b/src/mqt/qecc/analog_information_decoding/code_construction/sparse_code_constructor.py @@ -21,7 +21,7 @@ from scipy import sparse from scipy.sparse import coo_matrix, csr_matrix -from ...codes.constructions.product_code import generate_sparse_3d_product_code +from ...codes.constructions.hypergraph_product_code import generate_sparse_3d_product_code from . import code_constructor if TYPE_CHECKING: diff --git a/src/mqt/qecc/codes/constructions/product_code.py b/src/mqt/qecc/codes/constructions/hypergraph_product_code.py similarity index 88% rename from src/mqt/qecc/codes/constructions/product_code.py rename to src/mqt/qecc/codes/constructions/hypergraph_product_code.py index 2cc062fd7..e95d92969 100644 --- a/src/mqt/qecc/codes/constructions/product_code.py +++ b/src/mqt/qecc/codes/constructions/hypergraph_product_code.py @@ -20,25 +20,25 @@ from numpy.typing import NDArray -def is_all_zeros(array: NDArray[np.int32]) -> bool: +def _is_all_zeros(array: NDArray[np.int32]) -> bool: """Check if array is all zeros.""" return not np.any(array) -def sparse_all_zeros(mat: csr_matrix) -> bool: +def _sparse_all_zeros(mat: csr_matrix) -> bool: """Check if sparse matrix is all zeros.""" mat.data %= 2 return bool(mat.sum() == 0) -def run_sparse_checks_scipy(d_1: csr_matrix, d_2: csr_matrix, d_3: csr_matrix, d_4: csr_matrix) -> None: +def _run_sparse_checks_scipy(d_1: csr_matrix, d_2: csr_matrix, d_3: csr_matrix, d_4: csr_matrix) -> None: """Run checks on the boundary maps.""" - if not (sparse_all_zeros(d_1 @ d_2) and sparse_all_zeros(d_2 @ d_3) and sparse_all_zeros(d_3 @ d_4)): + if not (_sparse_all_zeros(d_1 @ d_2) and _sparse_all_zeros(d_2 @ d_3) and _sparse_all_zeros(d_3 @ d_4)): msg = "Error generating 4D code, boundary maps do not square to zero" raise RuntimeError(msg) -def run_checks_scipy( +def _run_checks_scipy( d_1: NDArray[np.int32], d_2: NDArray[np.int32], d_3: NDArray[np.int32], d_4: NDArray[np.int32] ) -> None: """Run checks on the boundary maps.""" @@ -48,9 +48,9 @@ def run_checks_scipy( sd_4 = scs.csr_matrix(d_4) if not ( - is_all_zeros((sd_1 * sd_2).todense() % 2) - and is_all_zeros((sd_2 * sd_3).todense() % 2) - and is_all_zeros((sd_3 * sd_4).todense() % 2) + _is_all_zeros((sd_1 * sd_2).todense() % 2) + and _is_all_zeros((sd_2 * sd_3).todense() % 2) + and _is_all_zeros((sd_3 * sd_4).todense() % 2) ): msg = "Error generating 4D code, boundary maps do not square to zero" raise RuntimeError(msg) @@ -85,7 +85,7 @@ def generate_4d_product_code( d_4: NDArray[np.int32] = np.vstack((np.kron(id_n3, p), np.kron(a_3, id_c))) if checks: - run_checks_scipy(d_1, d_2, d_3, d_4) + _run_checks_scipy(d_1, d_2, d_3, d_4) return d_1, d_2, d_3, d_4 @@ -111,7 +111,7 @@ def generate_3d_product_code( d_3: NDArray[np.int32] = np.vstack((np.kron(id_n2, p), np.kron(a_2, id_c))) - if not (is_all_zeros(d_1 @ d_2 % 2) and is_all_zeros(d_2 @ d_3 % 2)): + if not (_is_all_zeros(d_1 @ d_2 % 2) and _is_all_zeros(d_2 @ d_3 % 2)): msg = "Error generating 3D code, boundary maps do not square to zero" raise RuntimeError(msg) @@ -154,7 +154,7 @@ def generate_sparse_4d_product_code( d_4 = sparse.vstack((sparse.kron(id_n3, p), sparse.kron(a_3, id_c))) if checks: - run_sparse_checks_scipy(d_1, d_2, d_3, d_4) + _run_sparse_checks_scipy(d_1, d_2, d_3, d_4) return d_1, d_2, d_3, d_4 @@ -181,7 +181,7 @@ def generate_sparse_3d_product_code( d_3 = sparse.vstack((sparse.kron(id_n2, p), sparse.kron(a_2, id_c))) - if not (sparse_all_zeros(d_1 @ d_2) and sparse_all_zeros(d_2 @ d_3)): + if not (_sparse_all_zeros(d_1 @ d_2) and _sparse_all_zeros(d_2 @ d_3)): msg = "Error generating 3D code, boundary maps do not square to zero" raise RuntimeError(msg) diff --git a/tests/analog_info/test_hypergraph_product_codes.py b/tests/analog_info/test_hypergraph_product_codes.py new file mode 100644 index 000000000..8909c895d --- /dev/null +++ b/tests/analog_info/test_hypergraph_product_codes.py @@ -0,0 +1,89 @@ +# Copyright (c) 2023 - 2026 Chair for Design Automation, TUM +# All rights reserved. +# +# SPDX-License-Identifier: MIT +# +# Licensed under the MIT License + +"""Test product code constructions.""" + +from __future__ import annotations + +from typing import TYPE_CHECKING + +import numpy as np +import pytest +from scipy.sparse import csr_matrix + +if TYPE_CHECKING: + from numpy.typing import NDArray + +from mqt.qecc.codes.constructions.hypergraph_product_code import ( + generate_3d_product_code, + generate_4d_product_code, + generate_sparse_3d_product_code, +) + + +@pytest.fixture +def boundary_maps() -> tuple[NDArray[np.int32], NDArray[np.int32], NDArray[np.int32]]: + """Fixture for boundary maps.""" + a_1 = np.array([[1, 1]], dtype=np.int32) + a_2 = np.array([[1, 1], [1, 1]], dtype=np.int32) + p = np.array([[1, 1]], dtype=np.int32) + return a_1, a_2, p + + +def test_generate_3d_product_code( + boundary_maps: tuple[NDArray[np.int32], NDArray[np.int32], NDArray[np.int32]], +) -> None: + """Test 3D HGP code construction.""" + a_1, a_2, p = boundary_maps + d_1, d_2, d_3 = generate_3d_product_code(a_1, a_2, p) + + assert np.array_equal(d_1, np.array([[1, 1, 1, 1]], dtype=np.int32)) + assert d_2.shape == (4, 6) + assert d_3.shape == (6, 4) + assert not np.any(d_1 @ d_2 % 2) + assert not np.any(d_2 @ d_3 % 2) + + +def test_generate_sparse_3d_product_code_matches_dense( + boundary_maps: tuple[NDArray[np.int32], NDArray[np.int32], NDArray[np.int32]], +) -> None: + """Test sparse 3D HGP code construction against the dense construction.""" + a_1, a_2, p = boundary_maps + expected = generate_3d_product_code(a_1, a_2, p) + + result = generate_sparse_3d_product_code(csr_matrix(a_1), csr_matrix(a_2), csr_matrix(p)) + + for sparse_mat, dense_mat in zip(result, expected, strict=True): + assert np.array_equal(sparse_mat.toarray(), dense_mat) + + +def test_generate_4d_product_code( + boundary_maps: tuple[NDArray[np.int32], NDArray[np.int32], NDArray[np.int32]], +) -> None: + """Test 4D HGP code construction.""" + a_1, a_2, p = boundary_maps + a_3 = np.array([[1], [1]], dtype=np.int32) + + d_1, d_2, d_3, d_4 = generate_4d_product_code(a_1, a_2, a_3, p) + + assert d_1.shape == (1, 4) + assert d_2.shape == (4, 6) + assert d_3.shape == (6, 5) + assert d_4.shape == (5, 2) + assert not np.any(d_1 @ d_2 % 2) + assert not np.any(d_2 @ d_3 % 2) + assert not np.any(d_3 @ d_4 % 2) + + +def test_generate_3d_product_code_rejects_invalid_boundary_maps() -> None: + """Test that invalid boundaries are rejected.""" + a_1 = np.array([[1, 0]], dtype=np.int32) + a_2 = np.array([[1], [0]], dtype=np.int32) + p = np.array([[1]], dtype=np.int32) + + with pytest.raises(RuntimeError, match="boundary maps do not square to zero"): + generate_3d_product_code(a_1, a_2, p) From 79c3de6153a97815ead7353898177519fa57b005 Mon Sep 17 00:00:00 2001 From: Maxie Bichmann Date: Thu, 9 Jul 2026 20:39:22 +0200 Subject: [PATCH 10/29] =?UTF-8?q?=F0=9F=93=9D=20Adapt=20Analog=20Informati?= =?UTF-8?q?on=20Decoding=20Docs=20to=20refactor?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/AnalogInfo.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/AnalogInfo.md b/docs/AnalogInfo.md index e57f27ce0..75b7142b7 100644 --- a/docs/AnalogInfo.md +++ b/docs/AnalogInfo.md @@ -19,14 +19,14 @@ The {code}`results` directory contains the results used in the paper {cite:label ## Codes -The {code}`codes` directory contains the parity-check matrices of the codes used in the paper {cite:labelpar}`berent2023analog`. +The parity-check matrices of the codes used in the paper {cite:labelpar}`berent2023analog` can be found in the directory {code}`src/mqt/qecc/codes/instances/lifted_product`. Three dimensional toric codes can either be constructed with the hypergraph product construction or with a library, e.g., panqec {cite:labelpar}`huang2023panceq`. ## Code construction The {code}`code_construction` directory contains the code used to construct higher-dimensional hypergraph -product codes and used the {code}`compute_distances.sh` script to automatically compute bounds on the +product codes, utilizing the generator {code}`src/mqt/qecc/codes/constructions/hypergraph_product_code.py`, and used the {code}`compute_distances.sh` script to automatically compute bounds on the distances of the constructed codes using the GAP library QDistRnd {cite:labelpar}`pryadko2023qdistrnd`. ## Utils From 786b9aad9e2c2ff10b35a0fd92f09ced15c8605a Mon Sep 17 00:00:00 2001 From: Maxie Bichmann Date: Fri, 10 Jul 2026 08:05:37 +0200 Subject: [PATCH 11/29] =?UTF-8?q?=F0=9F=93=A6=20Add=20more=20simple=20test?= =?UTF-8?q?s=20to=204D=20HGP=20code=20construction?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../test_hypergraph_product_codes.py | 26 +++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/tests/analog_info/test_hypergraph_product_codes.py b/tests/analog_info/test_hypergraph_product_codes.py index 8909c895d..a87997ee8 100644 --- a/tests/analog_info/test_hypergraph_product_codes.py +++ b/tests/analog_info/test_hypergraph_product_codes.py @@ -22,6 +22,7 @@ generate_3d_product_code, generate_4d_product_code, generate_sparse_3d_product_code, + generate_sparse_4d_product_code, ) @@ -79,6 +80,20 @@ def test_generate_4d_product_code( assert not np.any(d_3 @ d_4 % 2) +def test_generate_sparse_4d_product_code_matches_dense( + boundary_maps: tuple[NDArray[np.int32], NDArray[np.int32], NDArray[np.int32]], +) -> None: + """Test sparse 4D HGP code construction against the dense construction.""" + a_1, a_2, p = boundary_maps + a_3 = np.array([[1], [1]], dtype=np.int32) + expected = generate_4d_product_code(a_1, a_2, a_3, p) + + result = generate_sparse_4d_product_code(csr_matrix(a_1), csr_matrix(a_2), csr_matrix(a_3), csr_matrix(p)) + + for sparse_mat, dense_mat in zip(result, expected, strict=True): + assert np.array_equal(sparse_mat.toarray(), dense_mat) + + def test_generate_3d_product_code_rejects_invalid_boundary_maps() -> None: """Test that invalid boundaries are rejected.""" a_1 = np.array([[1, 0]], dtype=np.int32) @@ -87,3 +102,14 @@ def test_generate_3d_product_code_rejects_invalid_boundary_maps() -> None: with pytest.raises(RuntimeError, match="boundary maps do not square to zero"): generate_3d_product_code(a_1, a_2, p) + + +def test_generate_4d_product_code_rejects_invalid_boundary_maps() -> None: + """Test that invalid boundaries are rejected.""" + a_1 = np.array([[1, 0]], dtype=np.int32) + a_2 = np.array([[1], [0]], dtype=np.int32) + a_3 = np.array([[1], [0]], dtype=np.int32) + p = np.array([[1]], dtype=np.int32) + + with pytest.raises(RuntimeError, match="boundary maps do not square to zero"): + generate_4d_product_code(a_1, a_2, a_3, p) From 10aee1b7cd84ea671409a998580b23cd4cc9bca1 Mon Sep 17 00:00:00 2001 From: Maxie Bichmann Date: Fri, 10 Jul 2026 17:03:15 +0200 Subject: [PATCH 12/29] =?UTF-8?q?=F0=9F=93=A6=20increase=20test=20coverage?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- tests/analog_info/test_hypergraph_product_codes.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tests/analog_info/test_hypergraph_product_codes.py b/tests/analog_info/test_hypergraph_product_codes.py index a87997ee8..30972a3c7 100644 --- a/tests/analog_info/test_hypergraph_product_codes.py +++ b/tests/analog_info/test_hypergraph_product_codes.py @@ -103,6 +103,9 @@ def test_generate_3d_product_code_rejects_invalid_boundary_maps() -> None: with pytest.raises(RuntimeError, match="boundary maps do not square to zero"): generate_3d_product_code(a_1, a_2, p) + with pytest.raises(RuntimeError, match="boundary maps do not square to zero"): + generate_sparse_3d_product_code(csr_matrix(a_1), csr_matrix(a_2), csr_matrix(p)) + def test_generate_4d_product_code_rejects_invalid_boundary_maps() -> None: """Test that invalid boundaries are rejected.""" @@ -113,3 +116,6 @@ def test_generate_4d_product_code_rejects_invalid_boundary_maps() -> None: with pytest.raises(RuntimeError, match="boundary maps do not square to zero"): generate_4d_product_code(a_1, a_2, a_3, p) + + with pytest.raises(RuntimeError, match="boundary maps do not square to zero"): + generate_sparse_4d_product_code(csr_matrix(a_1), csr_matrix(a_2), csr_matrix(a_3), csr_matrix(p)) From 6362fdd409e6586f4f0651a6333bc7052a6051ca Mon Sep 17 00:00:00 2001 From: Ludwig Schmid Date: Mon, 13 Jul 2026 09:35:44 +0200 Subject: [PATCH 13/29] =?UTF-8?q?=E2=99=BB=EF=B8=8F=20Drop=20dead=20distan?= =?UTF-8?q?ce=20parameter=20from=20CSSCode.from=5Fcode=5Fname?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit After removing the surface/hamming codes, every supported code has a fixed (x, z) distance in the lookup table, so the caller-supplied `distance` argument was never read and the "Distance is not specified" branch was unreachable (paths and distances share identical keys). Remove the vestigial parameter and simplify the control flow to a single early return. No caller passed `distance`, so there is no behavioural change for existing usage. --- src/mqt/qecc/codes/core/css_code.py | 24 +++++++++--------------- 1 file changed, 9 insertions(+), 15 deletions(-) diff --git a/src/mqt/qecc/codes/core/css_code.py b/src/mqt/qecc/codes/core/css_code.py index e7489d227..48d9a9230 100644 --- a/src/mqt/qecc/codes/core/css_code.py +++ b/src/mqt/qecc/codes/core/css_code.py @@ -185,7 +185,7 @@ def get_trivial_code(cls, n: int) -> CSSCode: return CSSCode(None, None, 1, n=n) @staticmethod - def from_code_name(code_name: str, distance: int | None = None) -> CSSCode: + def from_code_name(code_name: str) -> CSSCode: r"""Return CSSCode object for a known code. The following codes are supported: @@ -197,7 +197,6 @@ def from_code_name(code_name: str, distance: int | None = None) -> CSSCode: Args: code_name: The name of the code. - distance: The distance of the code. """ prefix = (Path(__file__) / "../../instances/").resolve() paths = { @@ -217,20 +216,15 @@ def from_code_name(code_name: str, distance: int | None = None) -> CSSCode: } # X, Z distances code_name = code_name.lower() - if code_name in paths: - hx = np.load(paths[code_name] / "hx.npy") - hz = np.load(paths[code_name] / "hz.npy") - - if code_name in distances: - x_distance, z_distance = distances[code_name] - distance = min(x_distance, z_distance) - return CSSCode(hx, hz, distance, x_distance=x_distance, z_distance=z_distance) + if code_name not in paths: + msg = f"Unknown code name: {code_name}" + raise InvalidCSSCodeError(msg) - if distance is None: - msg = f"Distance is not specified for {code_name}" - raise InvalidCSSCodeError(msg) - msg = f"Unknown code name: {code_name}" - raise InvalidCSSCodeError(msg) + hx = np.load(paths[code_name] / "hx.npy") + hz = np.load(paths[code_name] / "hz.npy") + x_distance, z_distance = distances[code_name] + distance = min(x_distance, z_distance) + return CSSCode(hx, hz, distance, x_distance=x_distance, z_distance=z_distance) @classmethod def from_file(cls, file_path: str | Path) -> CSSCode: From 644cd93a11de7c36eda98bae879b903de1901e2d Mon Sep 17 00:00:00 2001 From: Ludwig Schmid Date: Mon, 13 Jul 2026 09:36:19 +0200 Subject: [PATCH 14/29] =?UTF-8?q?=E2=9A=A1=20Build=20sparse=20zero=20block?= =?UTF-8?q?s=20without=20materializing=20dense=20arrays?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The sparse 3D/4D HGP constructors created their zero padding blocks via `csr_matrix(np.zeros(dims))`, allocating a full dense array before converting it to sparse. This defeats the purpose of the sparse code path, which exists to avoid dense allocations for large codes. Construct the zero blocks directly as sparse matrices with `csr_matrix(dims, dtype=int)`, which yields an all-zero sparse matrix of the requested shape with no intermediate dense buffer. --- src/mqt/qecc/codes/constructions/hypergraph_product_code.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/mqt/qecc/codes/constructions/hypergraph_product_code.py b/src/mqt/qecc/codes/constructions/hypergraph_product_code.py index e95d92969..b7c0cafd7 100644 --- a/src/mqt/qecc/codes/constructions/hypergraph_product_code.py +++ b/src/mqt/qecc/codes/constructions/hypergraph_product_code.py @@ -140,14 +140,14 @@ def generate_sparse_4d_product_code( x = sparse.hstack((sparse.kron(a_2, id_r), sparse.kron(id_n1, p))) y = sparse.kron(a_1, id_c) dims = (y.shape[0], x.shape[1] - y.shape[1]) - nmat = csr_matrix(np.zeros(dims)) + nmat = csr_matrix(dims, dtype=int) z = sparse.hstack((nmat, y)) d_2 = sparse.vstack((x, z)) x = sparse.hstack((sparse.kron(a_3, id_r), sparse.kron(id_n2, p))) y = sparse.kron(a_2, id_c) dims = (y.shape[0], x.shape[1] - y.shape[1]) - mat = csr_matrix(np.zeros(dims)) + mat = csr_matrix(dims, dtype=int) z = sparse.hstack([mat, y]) d_3 = sparse.vstack((x, z)) @@ -176,7 +176,7 @@ def generate_sparse_3d_product_code( x = sparse.hstack((sparse.kron(a_2, id_r), sparse.kron(id_n1, p))) y = sparse.kron(a_1, id_c) dims = (y.shape[0], x.shape[1] - y.shape[1]) - z = sparse.hstack((csr_matrix(np.zeros(dims), dtype=int), y)) + z = sparse.hstack((csr_matrix(dims, dtype=int), y)) d_2 = sparse.vstack((x, z)) d_3 = sparse.vstack((sparse.kron(id_n2, p), sparse.kron(a_2, id_c))) From ed44178fda59025f39afce98e42f8c4f1af728b8 Mon Sep 17 00:00:00 2001 From: Ludwig Schmid Date: Mon, 13 Jul 2026 09:37:09 +0200 Subject: [PATCH 15/29] =?UTF-8?q?=F0=9F=8E=A8=20Use=20int32=20consistently?= =?UTF-8?q?=20in=20sparse=20HGP=20constructors?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The sparse product-code constructors used `dtype=int` (platform- dependent width) while their dense counterparts use `np.int32`. Since all entries are binary, the width is immaterial to correctness, but aligning the sparse path on `np.int32` keeps the two implementations consistent. --- .../constructions/hypergraph_product_code.py | 28 +++++++++---------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/src/mqt/qecc/codes/constructions/hypergraph_product_code.py b/src/mqt/qecc/codes/constructions/hypergraph_product_code.py index b7c0cafd7..43ff1dbde 100644 --- a/src/mqt/qecc/codes/constructions/hypergraph_product_code.py +++ b/src/mqt/qecc/codes/constructions/hypergraph_product_code.py @@ -128,26 +128,26 @@ def generate_sparse_4d_product_code( """Generate 4D HGP code.""" r, c = p.shape - id_r = sparse.identity(r, dtype=int) - id_c = sparse.identity(c, dtype=int) - id_n0 = sparse.identity(a_1.shape[0], dtype=int) - id_n1 = sparse.identity(a_2.shape[0], dtype=int) - id_n2 = sparse.identity(a_3.shape[0], dtype=int) - id_n3 = sparse.identity(a_3.shape[1], dtype=int) + id_r = sparse.identity(r, dtype=np.int32) + id_c = sparse.identity(c, dtype=np.int32) + id_n0 = sparse.identity(a_1.shape[0], dtype=np.int32) + id_n1 = sparse.identity(a_2.shape[0], dtype=np.int32) + id_n2 = sparse.identity(a_3.shape[0], dtype=np.int32) + id_n3 = sparse.identity(a_3.shape[1], dtype=np.int32) d_1 = sparse.hstack((sparse.kron(a_1, id_r), sparse.kron(id_n0, p))) x = sparse.hstack((sparse.kron(a_2, id_r), sparse.kron(id_n1, p))) y = sparse.kron(a_1, id_c) dims = (y.shape[0], x.shape[1] - y.shape[1]) - nmat = csr_matrix(dims, dtype=int) + nmat = csr_matrix(dims, dtype=np.int32) z = sparse.hstack((nmat, y)) d_2 = sparse.vstack((x, z)) x = sparse.hstack((sparse.kron(a_3, id_r), sparse.kron(id_n2, p))) y = sparse.kron(a_2, id_c) dims = (y.shape[0], x.shape[1] - y.shape[1]) - mat = csr_matrix(dims, dtype=int) + mat = csr_matrix(dims, dtype=np.int32) z = sparse.hstack([mat, y]) d_3 = sparse.vstack((x, z)) @@ -165,18 +165,18 @@ def generate_sparse_3d_product_code( """Generate 3D HGP code.""" r, c = p.shape - id_r = sparse.identity(r, dtype=int) - id_c = sparse.identity(c, dtype=int) - id_n0 = sparse.identity(a_1.shape[0], dtype=int) - id_n1 = sparse.identity(a_2.shape[0], dtype=int) - id_n2 = sparse.identity(a_2.shape[1], dtype=int) + id_r = sparse.identity(r, dtype=np.int32) + id_c = sparse.identity(c, dtype=np.int32) + id_n0 = sparse.identity(a_1.shape[0], dtype=np.int32) + id_n1 = sparse.identity(a_2.shape[0], dtype=np.int32) + id_n2 = sparse.identity(a_2.shape[1], dtype=np.int32) d_1 = sparse.hstack((sparse.kron(a_1, id_r), sparse.kron(id_n0, p))) x = sparse.hstack((sparse.kron(a_2, id_r), sparse.kron(id_n1, p))) y = sparse.kron(a_1, id_c) dims = (y.shape[0], x.shape[1] - y.shape[1]) - z = sparse.hstack((csr_matrix(dims, dtype=int), y)) + z = sparse.hstack((csr_matrix(dims, dtype=np.int32), y)) d_2 = sparse.vstack((x, z)) d_3 = sparse.vstack((sparse.kron(id_n2, p), sparse.kron(a_2, id_c))) From cc4618cc6bdbbbb434446cfc51ed2006e169b1fa Mon Sep 17 00:00:00 2001 From: Ludwig Schmid Date: Mon, 13 Jul 2026 09:37:40 +0200 Subject: [PATCH 16/29] =?UTF-8?q?=F0=9F=A9=B9=20Make=20=5Fsparse=5Fall=5Fz?= =?UTF-8?q?eros=20non-mutating?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit `_sparse_all_zeros` reduced its argument in place via `mat.data %= 2` before summing. Despite reading like a pure predicate it mutated the caller's matrix, which is a latent hazard if the helper is ever reused on a matrix the caller still needs. Reduce mod 2 on a transient copy of the data vector instead (`not np.any(mat.data % 2)`), mirroring the dense `_is_all_zeros` helper. Behaviour is unchanged: it still reports whether the matrix is zero over GF(2). Current callers only pass throwaway boundary-map products, so there is no observable change. --- src/mqt/qecc/codes/constructions/hypergraph_product_code.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/mqt/qecc/codes/constructions/hypergraph_product_code.py b/src/mqt/qecc/codes/constructions/hypergraph_product_code.py index 43ff1dbde..f1652b682 100644 --- a/src/mqt/qecc/codes/constructions/hypergraph_product_code.py +++ b/src/mqt/qecc/codes/constructions/hypergraph_product_code.py @@ -26,9 +26,8 @@ def _is_all_zeros(array: NDArray[np.int32]) -> bool: def _sparse_all_zeros(mat: csr_matrix) -> bool: - """Check if sparse matrix is all zeros.""" - mat.data %= 2 - return bool(mat.sum() == 0) + """Check if a sparse matrix is all zeros over GF(2), without mutating it.""" + return not np.any(mat.data % 2) def _run_sparse_checks_scipy(d_1: csr_matrix, d_2: csr_matrix, d_3: csr_matrix, d_4: csr_matrix) -> None: From e8674b2132b79c1204be1c2f4c521d6c1ceb84d4 Mon Sep 17 00:00:00 2001 From: Ludwig Schmid Date: Mon, 13 Jul 2026 09:38:03 +0200 Subject: [PATCH 17/29] =?UTF-8?q?=F0=9F=93=9D=20Clean=20up=20HGP=20module?= =?UTF-8?q?=20docstring=20and=20return=20comment?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Replace the generic, inaccurate module docstring ("Package for code construction") with one that describes the module's actual contents, and fix the contradictory dual comment on the 3D return (`# mx, hx, hzT # hx, hzT, mzT`) to the correct `# hx, hz^T, mz^T`, matching how `create_code` unpacks the result. --- src/mqt/qecc/codes/constructions/hypergraph_product_code.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/mqt/qecc/codes/constructions/hypergraph_product_code.py b/src/mqt/qecc/codes/constructions/hypergraph_product_code.py index f1652b682..91839b3d8 100644 --- a/src/mqt/qecc/codes/constructions/hypergraph_product_code.py +++ b/src/mqt/qecc/codes/constructions/hypergraph_product_code.py @@ -5,7 +5,7 @@ # # Licensed under the MIT License -"""Package for code construction.""" +"""Hypergraph product code constructions (3D and 4D, dense and sparse).""" from __future__ import annotations @@ -184,4 +184,4 @@ def generate_sparse_3d_product_code( msg = "Error generating 3D code, boundary maps do not square to zero" raise RuntimeError(msg) - return d_1, d_2, d_3 # mx, hx, hzT # hx, hzT, mzT + return d_1, d_2, d_3 # hx, hz^T, mz^T From b2bbbe8d2471cc13e0870cdabe28b45c912ac816 Mon Sep 17 00:00:00 2001 From: Ludwig Schmid Date: Mon, 13 Jul 2026 09:38:30 +0200 Subject: [PATCH 18/29] =?UTF-8?q?=F0=9F=9A=9A=20Move=20HGP=20tests=20next?= =?UTF-8?q?=20to=20their=20new=20source=20location?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The 3D/4D hypergraph product code constructors moved from `analog_information_decoding` into `codes/constructions/`, but their tests were left under `tests/analog_info/`. Relocate them to `tests/codes/constructions/` so the test tree mirrors the source tree. The tests import `mqt.qecc.codes.constructions.hypergraph_product_code` absolutely, so the move is purely organizational. --- .../constructions}/test_hypergraph_product_codes.py | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename tests/{analog_info => codes/constructions}/test_hypergraph_product_codes.py (100%) diff --git a/tests/analog_info/test_hypergraph_product_codes.py b/tests/codes/constructions/test_hypergraph_product_codes.py similarity index 100% rename from tests/analog_info/test_hypergraph_product_codes.py rename to tests/codes/constructions/test_hypergraph_product_codes.py From 5e5f0255c4d2ce1451a12f9287748fde451a1e30 Mon Sep 17 00:00:00 2001 From: Ludwig Schmid Date: Mon, 13 Jul 2026 09:39:07 +0200 Subject: [PATCH 19/29] =?UTF-8?q?=F0=9F=93=9D=20Document=20the=20instances?= =?UTF-8?q?/=20directory=20layout?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The centralization introduced `codes/instances/` but left its contents undocumented, so the example codes under `misc/` (and the lifted-product matrices) were effectively orphaned - referenced nowhere and hard to discover. Add a README describing the three groups: the named CSS codes exposed via `CSSCode.from_code_name`, the pre-generated lifted-product matrices, and the `misc/` example files that demonstrate the text formats accepted by `CSSCode.from_file`. --- src/mqt/qecc/codes/instances/README.md | 41 ++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 src/mqt/qecc/codes/instances/README.md diff --git a/src/mqt/qecc/codes/instances/README.md b/src/mqt/qecc/codes/instances/README.md new file mode 100644 index 000000000..bae3007c6 --- /dev/null +++ b/src/mqt/qecc/codes/instances/README.md @@ -0,0 +1,41 @@ +# Hard-coded code instances + +This directory holds concrete quantum error-correcting code instances that ship +with the package because they cannot (easily) be generated on the fly or are +convenient to have immediately available. It is the `instances/` layer of +`mqt.qecc.codes` (see also `core/` and `constructions/`). + +## Named CSS codes + +Each of the following sub-directories stores a code as two NumPy arrays, +`hx.npy` and `hz.npy` (the X- and Z-check matrices): + +| Directory | Code | +| -------------- | --------------------------- | +| `steane/` | `[[7, 1, 3]]` Steane | +| `shor/` | `[[9, 1, 3]]` Shor | +| `tetrahedral/` | `[[15, 1, 3]]` tetrahedral | +| `carbon/` | `[[12, 2, 4]]` carbon | +| `golay/` | `[[23, 1, 7]]` Golay | + +These are the codes returned by `CSSCode.from_code_name(...)`, e.g. +`CSSCode.from_code_name("Steane")`. + +## `lifted_product/` + +Pre-generated check matrices for lifted-product codes, stored as sparse +`.npz` arrays. File names follow `lp_l=_h{x,z}.npz`. + +## `misc/` + +Example codes stored in the human-readable text formats accepted by +`CSSCode.from_file(...)`. They double as fixtures for the supported formats: + +| File | Format | +| ------------- | -------------------------------------------------- | +| `8_3_3.txt` | Pauli-string stabilizers (one per line) | +| `15_3_5.txt` | Python list notation (`[[1,0,...], ...]`) | +| `30_6_5.txt` | NumPy-array notation (space-separated `[[1 0 ...]]`)| + +File names follow the `n_k_d` convention (physical qubits, logical qubits, +distance). From 2244e711e9f141adf048d75ecec126df23bdb54c Mon Sep 17 00:00:00 2001 From: Ludwig Schmid Date: Mon, 13 Jul 2026 09:40:54 +0200 Subject: [PATCH 20/29] =?UTF-8?q?=E2=9C=85=20Add=20regression=20test=20for?= =?UTF-8?q?=20create=5Fcode's=20sparse=203D=20wiring?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The HGP builders moved into codes.constructions and create_code was rewired to call generate_sparse_3d_product_code, but nothing exercised that caller. Add a test that drives create_code end-to-end with the bposd hypergraph product and the file/subprocess side effects stubbed out, and asserts the extended code is a valid CSS code (Hx Hz^T = 0 over GF(2)). Also cover the unknown-constructor error path. --- .../test_sparse_code_constructor.py | 67 +++++++++++++++++++ 1 file changed, 67 insertions(+) create mode 100644 tests/analog_info/test_sparse_code_constructor.py diff --git a/tests/analog_info/test_sparse_code_constructor.py b/tests/analog_info/test_sparse_code_constructor.py new file mode 100644 index 000000000..999c6e7ca --- /dev/null +++ b/tests/analog_info/test_sparse_code_constructor.py @@ -0,0 +1,67 @@ +# Copyright (c) 2023 - 2026 Chair for Design Automation, TUM +# All rights reserved. +# +# SPDX-License-Identifier: MIT +# +# Licensed under the MIT License + +"""Tests for the sparse code constructor's use of the centralized HGP builder.""" + +from __future__ import annotations + +from types import SimpleNamespace +from typing import TYPE_CHECKING + +import numpy as np +import pytest +from scipy.sparse import csr_matrix + +import mqt.qecc.analog_information_decoding.code_construction.sparse_code_constructor as scc + +if TYPE_CHECKING: + from numpy.typing import NDArray + + +def test_create_code_builds_valid_css_code_via_sparse_3d(monkeypatch: pytest.MonkeyPatch) -> None: + """`create_code` must route through `generate_sparse_3d_product_code` and yield a valid CSS code. + + This pins down the wiring after the HGP builders were centralized into + `codes.constructions.hypergraph_product_code`: `create_code` extends the + seed hypergraph-product code to a 3D product code and treats the first two + returned boundary maps as the (Hx, Hz) of a CSS code. A valid CSS code + requires ``Hx @ Hz.T == 0`` over GF(2). + + The bposd hypergraph product and the file/subprocess side effects are + stubbed out so the test is deterministic and touches neither external + solvers nor the filesystem. + """ + # Stand in for the bposd hypergraph product with a fixed valid 2-complex + # (Hx @ Hz.T = 0 mod 2), so `create_code` gets well-formed boundary maps. + hx_seed = np.array([[1, 1]], dtype=np.int32) + hz_seed = np.array([[1, 1], [1, 1]], dtype=np.int32) + monkeypatch.setattr(scc, "hgp", lambda _h1, _h2: SimpleNamespace(hx=hx_seed, hz=hz_seed)) + + captured: dict[str, NDArray[np.int32]] = {} + + def _capture(hx: NDArray[np.int32], hz: NDArray[np.int32], _codename: str) -> None: + captured["hx"] = np.asarray(hx) + captured["hz"] = np.asarray(hz) + + # Redirect the terminal write step so nothing is persisted to disk. + monkeypatch.setattr(scc, "_store_code_params", _capture) + + p = csr_matrix(np.array([[1, 1]], dtype=np.int32)) + scc.create_code("hgp", [hx_seed, hz_seed, p], "unit_test_code") + + hx, hz = captured["hx"], captured["hz"] + assert hx.size > 0 + assert hx.shape[1] == hz.shape[1] + # The extended code must be a valid CSS code. + assert not np.any((hx @ hz.T) % 2) + + +def test_create_code_rejects_unknown_constructor() -> None: + """An unsupported constructor name must raise a clear error.""" + p = csr_matrix(np.array([[1, 1]], dtype=np.int32)) + with pytest.raises(ValueError, match="not implemented"): + scc.create_code("not_a_constructor", [p, p, p], "unit_test_code") From 6473c4310316dd3a04f3914960b98cc6d69f22cb Mon Sep 17 00:00:00 2001 From: Ludwig Schmid Date: Mon, 13 Jul 2026 10:00:11 +0200 Subject: [PATCH 21/29] =?UTF-8?q?=F0=9F=A9=B9=20Guard=20bposd=20import=20i?= =?UTF-8?q?n=20sparse=20code=20constructor=20test?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit `sparse_code_constructor` imports `bposd`, whose source raises a SyntaxWarning (invalid escape sequences) on Python >= 3.12. Under the project's strict ``filterwarnings = ["error"]`` this turned the test's module import into a collection error. Wrap the import in a local ``warnings.catch_warnings()`` / ``simplefilter("ignore")`` block so the test collects and runs. --- tests/analog_info/test_sparse_code_constructor.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/tests/analog_info/test_sparse_code_constructor.py b/tests/analog_info/test_sparse_code_constructor.py index 999c6e7ca..4899a4412 100644 --- a/tests/analog_info/test_sparse_code_constructor.py +++ b/tests/analog_info/test_sparse_code_constructor.py @@ -9,6 +9,7 @@ from __future__ import annotations +import warnings from types import SimpleNamespace from typing import TYPE_CHECKING @@ -16,7 +17,13 @@ import pytest from scipy.sparse import csr_matrix -import mqt.qecc.analog_information_decoding.code_construction.sparse_code_constructor as scc +# `sparse_code_constructor` imports `bposd`, whose source contains invalid escape +# sequences that raise a SyntaxWarning on Python >= 3.12. Under the project's +# ``filterwarnings = ["error"]`` config this would turn the import into a +# collection error, so suppress it while importing the module under test. +with warnings.catch_warnings(): + warnings.simplefilter("ignore") + import mqt.qecc.analog_information_decoding.code_construction.sparse_code_constructor as scc if TYPE_CHECKING: from numpy.typing import NDArray From 7372e73a68a25af5220e34f3fa3403ab516e3d8e Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 13 Jul 2026 08:05:50 +0000 Subject: [PATCH 22/29] =?UTF-8?q?=F0=9F=8E=A8=20pre-commit=20fixes?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/mqt/qecc/codes/instances/README.md | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/src/mqt/qecc/codes/instances/README.md b/src/mqt/qecc/codes/instances/README.md index bae3007c6..2ae08d32a 100644 --- a/src/mqt/qecc/codes/instances/README.md +++ b/src/mqt/qecc/codes/instances/README.md @@ -10,13 +10,13 @@ convenient to have immediately available. It is the `instances/` layer of Each of the following sub-directories stores a code as two NumPy arrays, `hx.npy` and `hz.npy` (the X- and Z-check matrices): -| Directory | Code | -| -------------- | --------------------------- | -| `steane/` | `[[7, 1, 3]]` Steane | -| `shor/` | `[[9, 1, 3]]` Shor | -| `tetrahedral/` | `[[15, 1, 3]]` tetrahedral | -| `carbon/` | `[[12, 2, 4]]` carbon | -| `golay/` | `[[23, 1, 7]]` Golay | +| Directory | Code | +| -------------- | -------------------------- | +| `steane/` | `[[7, 1, 3]]` Steane | +| `shor/` | `[[9, 1, 3]]` Shor | +| `tetrahedral/` | `[[15, 1, 3]]` tetrahedral | +| `carbon/` | `[[12, 2, 4]]` carbon | +| `golay/` | `[[23, 1, 7]]` Golay | These are the codes returned by `CSSCode.from_code_name(...)`, e.g. `CSSCode.from_code_name("Steane")`. @@ -31,11 +31,11 @@ Pre-generated check matrices for lifted-product codes, stored as sparse Example codes stored in the human-readable text formats accepted by `CSSCode.from_file(...)`. They double as fixtures for the supported formats: -| File | Format | -| ------------- | -------------------------------------------------- | -| `8_3_3.txt` | Pauli-string stabilizers (one per line) | -| `15_3_5.txt` | Python list notation (`[[1,0,...], ...]`) | -| `30_6_5.txt` | NumPy-array notation (space-separated `[[1 0 ...]]`)| +| File | Format | +| ------------ | ---------------------------------------------------- | +| `8_3_3.txt` | Pauli-string stabilizers (one per line) | +| `15_3_5.txt` | Python list notation (`[[1,0,...], ...]`) | +| `30_6_5.txt` | NumPy-array notation (space-separated `[[1 0 ...]]`) | File names follow the `n_k_d` convention (physical qubits, logical qubits, distance). From a5852237b98b919b3ef552625df2e214294e171f Mon Sep 17 00:00:00 2001 From: Ludwig Schmid Date: Mon, 13 Jul 2026 10:10:15 +0200 Subject: [PATCH 23/29] =?UTF-8?q?=F0=9F=A9=B9=20Fix=20ty=20lint=20errors?= =?UTF-8?q?=20after=20codes=20centralization?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Two issues flagged by the `ty` linter: - `examples/add_new_gate_example.py` still imported `StabilizerTableau` from the pre-refactor `mqt.qecc.codes.pauli`; point it at `mqt.qecc.codes.core.pauli` (missed in the earlier import sweep, which did not cover `examples/`). - The `create_code` regression test passed NumPy arrays where the `list[csr_matrix]` signature is expected; wrap the stubbed seed codes in `csr_matrix` to match. --- examples/add_new_gate_example.py | 2 +- tests/analog_info/test_sparse_code_constructor.py | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/examples/add_new_gate_example.py b/examples/add_new_gate_example.py index 71cb27148..6d00234df 100644 --- a/examples/add_new_gate_example.py +++ b/examples/add_new_gate_example.py @@ -29,7 +29,7 @@ SymbolicGateOperation, get_standard_clifford_gate_set, ) -from mqt.qecc.codes.pauli import StabilizerTableau +from mqt.qecc.codes.core.pauli import StabilizerTableau if TYPE_CHECKING: import numpy as np diff --git a/tests/analog_info/test_sparse_code_constructor.py b/tests/analog_info/test_sparse_code_constructor.py index 4899a4412..4ab536b79 100644 --- a/tests/analog_info/test_sparse_code_constructor.py +++ b/tests/analog_info/test_sparse_code_constructor.py @@ -58,7 +58,9 @@ def _capture(hx: NDArray[np.int32], hz: NDArray[np.int32], _codename: str) -> No monkeypatch.setattr(scc, "_store_code_params", _capture) p = csr_matrix(np.array([[1, 1]], dtype=np.int32)) - scc.create_code("hgp", [hx_seed, hz_seed, p], "unit_test_code") + # seed_codes[0:2] are consumed by the stubbed `hgp`; seed_codes[2] (`p`) drives the + # 3D extension. Pass them all as csr_matrix to match the `list[csr_matrix]` signature. + scc.create_code("hgp", [csr_matrix(hx_seed), csr_matrix(hz_seed), p], "unit_test_code") hx, hz = captured["hx"], captured["hz"] assert hx.size > 0 From 204769307871e945b53288fa35f4e0ee807eb8ee Mon Sep 17 00:00:00 2001 From: Ludwig Schmid Date: Mon, 13 Jul 2026 10:26:43 +0200 Subject: [PATCH 24/29] =?UTF-8?q?=F0=9F=90=9B=20Restore=20'hamming'=20opti?= =?UTF-8?q?on=20in=20estimate=5Flogical=5Ferror=5Frate=20script?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Removing "hamming" from `CSSCode.from_code_name` left it advertised in the script's `available_codes` while routing to `from_code_name`, so `--code hamming` now raised. Route it to `construct_quantum_hamming_code(4)` (the [[15, 7, 3]] code the removed instance provided) instead, mirroring how the `surface` case was already switched to `RotatedSurfaceCode`. --- .../ft_stateprep/eval/estimate_logical_error_rate.py | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/scripts/ft_stateprep/eval/estimate_logical_error_rate.py b/scripts/ft_stateprep/eval/estimate_logical_error_rate.py index a053181ce..1654a7406 100644 --- a/scripts/ft_stateprep/eval/estimate_logical_error_rate.py +++ b/scripts/ft_stateprep/eval/estimate_logical_error_rate.py @@ -23,7 +23,12 @@ heuristic_verification_circuit, naive_verification_circuit, ) -from mqt.qecc.codes import HexagonalColorCode, RotatedSurfaceCode, SquareOctagonColorCode +from mqt.qecc.codes import ( + HexagonalColorCode, + RotatedSurfaceCode, + SquareOctagonColorCode, + construct_quantum_hamming_code, +) def main() -> None: @@ -65,6 +70,10 @@ def main() -> None: elif "cc_6_6_6" in code_name: d = 5 code = HexagonalColorCode(d) + elif "hamming" in code_name: + # The [[15, 7, 3]] quantum Hamming code (previously a hard-coded instance, + # now generated) since it was removed from CSSCode.from_code_name. + code = construct_quantum_hamming_code(4) elif code_name in available_codes: code = CSSCode.from_code_name(code_name) else: From af0802a5749db5152169d746219bd8998010277b Mon Sep 17 00:00:00 2001 From: Ludwig Schmid Date: Mon, 13 Jul 2026 10:26:43 +0200 Subject: [PATCH 25/29] =?UTF-8?q?=F0=9F=93=9D=20Polish=20HGP=20generator?= =?UTF-8?q?=20API=20and=20docs?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Address review feedback on the centralized product-code module: - make the `checks` flag keyword-only in the 4D generators (callers already pass it by name); - expand the four public generators' docstrings to Google style with Args/Returns/Raises, documenting the boundary-map ordering; - check the 4D boundary maps via `_sparse_all_zeros` instead of densifying the products with `.todense()`. --- .../constructions/hypergraph_product_code.py | 92 +++++++++++++++++-- 1 file changed, 82 insertions(+), 10 deletions(-) diff --git a/src/mqt/qecc/codes/constructions/hypergraph_product_code.py b/src/mqt/qecc/codes/constructions/hypergraph_product_code.py index 91839b3d8..6c2a31048 100644 --- a/src/mqt/qecc/codes/constructions/hypergraph_product_code.py +++ b/src/mqt/qecc/codes/constructions/hypergraph_product_code.py @@ -46,19 +46,40 @@ def _run_checks_scipy( sd_3 = scs.csr_matrix(d_3) sd_4 = scs.csr_matrix(d_4) - if not ( - _is_all_zeros((sd_1 * sd_2).todense() % 2) - and _is_all_zeros((sd_2 * sd_3).todense() % 2) - and _is_all_zeros((sd_3 * sd_4).todense() % 2) - ): + if not (_sparse_all_zeros(sd_1 @ sd_2) and _sparse_all_zeros(sd_2 @ sd_3) and _sparse_all_zeros(sd_3 @ sd_4)): msg = "Error generating 4D code, boundary maps do not square to zero" raise RuntimeError(msg) def generate_4d_product_code( - a_1: NDArray[np.int32], a_2: NDArray[np.int32], a_3: NDArray[np.int32], p: NDArray[np.int32], checks: bool = True + a_1: NDArray[np.int32], + a_2: NDArray[np.int32], + a_3: NDArray[np.int32], + p: NDArray[np.int32], + *, + checks: bool = True, ) -> tuple[NDArray[np.int32], NDArray[np.int32], NDArray[np.int32], NDArray[np.int32]]: - """Generate 4D product code.""" + """Generate the boundary maps of a 4D hypergraph product code (dense). + + Builds the 4D chain complex from the boundary maps ``a_1, a_2, a_3`` of a + 3D input complex and a classical seed parity-check matrix ``p``. The inputs + must be compatible, i.e. consecutive maps compose to zero over GF(2). + + Args: + a_1: First boundary map of the 3D input complex. + a_2: Second boundary map of the 3D input complex. + a_3: Third boundary map of the 3D input complex. + p: Parity-check matrix of the classical seed code. + checks: If ``True``, verify that the resulting boundary maps square to + zero over GF(2). + + Returns: + The four boundary maps ``(mx, hx, hz^T, mz^T)`` of the 4D complex. + + Raises: + RuntimeError: If ``checks`` is enabled and the boundary maps do not + square to zero. + """ r, c = p.shape id_r: NDArray[np.int32] = np.identity(r, dtype=np.int32) id_c: NDArray[np.int32] = np.identity(c, dtype=np.int32) @@ -92,7 +113,23 @@ def generate_4d_product_code( def generate_3d_product_code( a_1: NDArray[np.int32], a_2: NDArray[np.int32], p: NDArray[np.int32] ) -> tuple[NDArray[np.int32], NDArray[np.int32], NDArray[np.int32]]: - """Generate 3D product code.""" + """Generate the boundary maps of a 3D hypergraph product code (dense). + + Builds the 3D chain complex from the boundary maps ``a_1, a_2`` of a 2D + input complex and a classical seed parity-check matrix ``p``. The inputs + must be compatible, i.e. ``a_1 @ a_2`` is zero over GF(2). + + Args: + a_1: First boundary map of the 2D input complex. + a_2: Second boundary map of the 2D input complex. + p: Parity-check matrix of the classical seed code. + + Returns: + The three boundary maps ``(hx, hz^T, mz^T)`` of the 3D complex. + + Raises: + RuntimeError: If the boundary maps do not square to zero over GF(2). + """ r, c = p.shape id_r: NDArray[np.int32] = np.identity(r, dtype=np.int32) id_c: NDArray[np.int32] = np.identity(c, dtype=np.int32) @@ -122,9 +159,29 @@ def generate_sparse_4d_product_code( a_2: csr_matrix, a_3: csr_matrix, p: csr_matrix, + *, checks: bool = True, ) -> tuple[csr_matrix, csr_matrix, csr_matrix, csr_matrix]: - """Generate 4D HGP code.""" + """Generate the boundary maps of a 4D hypergraph product code (sparse). + + Sparse counterpart of :func:`generate_4d_product_code`; see there for the + input requirements. + + Args: + a_1: First boundary map of the 3D input complex. + a_2: Second boundary map of the 3D input complex. + a_3: Third boundary map of the 3D input complex. + p: Parity-check matrix of the classical seed code. + checks: If ``True``, verify that the resulting boundary maps square to + zero over GF(2). + + Returns: + The four boundary maps ``(mx, hx, hz^T, mz^T)`` of the 4D complex. + + Raises: + RuntimeError: If ``checks`` is enabled and the boundary maps do not + square to zero. + """ r, c = p.shape id_r = sparse.identity(r, dtype=np.int32) @@ -161,7 +218,22 @@ def generate_sparse_4d_product_code( def generate_sparse_3d_product_code( a_1: csr_matrix, a_2: csr_matrix, p: csr_matrix ) -> tuple[csr_matrix, csr_matrix, csr_matrix]: - """Generate 3D HGP code.""" + """Generate the boundary maps of a 3D hypergraph product code (sparse). + + Sparse counterpart of :func:`generate_3d_product_code`; see there for the + input requirements. + + Args: + a_1: First boundary map of the 2D input complex. + a_2: Second boundary map of the 2D input complex. + p: Parity-check matrix of the classical seed code. + + Returns: + The three boundary maps ``(hx, hz^T, mz^T)`` of the 3D complex. + + Raises: + RuntimeError: If the boundary maps do not square to zero over GF(2). + """ r, c = p.shape id_r = sparse.identity(r, dtype=np.int32) From 3eeb5983da518bf386368a14203c5ab34455311a Mon Sep 17 00:00:00 2001 From: Ludwig Schmid Date: Mon, 13 Jul 2026 10:26:43 +0200 Subject: [PATCH 26/29] =?UTF-8?q?=F0=9F=A9=B9=20Narrow=20bposd=20import=20?= =?UTF-8?q?warning=20filter=20to=20SyntaxWarning?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Scope the suppression around the `sparse_code_constructor` import to `SyntaxWarning` only, so unrelated warnings from the import remain visible. --- tests/analog_info/test_sparse_code_constructor.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/analog_info/test_sparse_code_constructor.py b/tests/analog_info/test_sparse_code_constructor.py index 4ab536b79..df67de63e 100644 --- a/tests/analog_info/test_sparse_code_constructor.py +++ b/tests/analog_info/test_sparse_code_constructor.py @@ -22,7 +22,7 @@ # ``filterwarnings = ["error"]`` config this would turn the import into a # collection error, so suppress it while importing the module under test. with warnings.catch_warnings(): - warnings.simplefilter("ignore") + warnings.simplefilter("ignore", SyntaxWarning) import mqt.qecc.analog_information_decoding.code_construction.sparse_code_constructor as scc if TYPE_CHECKING: From bf70750a55b9ed10a23894407e869a309eabb204 Mon Sep 17 00:00:00 2001 From: Ludwig Schmid Date: Mon, 13 Jul 2026 11:06:33 +0200 Subject: [PATCH 27/29] =?UTF-8?q?=F0=9F=90=9B=20Fix=20bposd=20warning=20su?= =?UTF-8?q?ppression=20on=20Python=20<=3D=203.11?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Narrowing the filter to `SyntaxWarning` broke CI on Python 3.10/3.11: there, bposd's invalid escape sequences raise a DeprecationWarning (only 3.12+ categorizes them as SyntaxWarning), so the filter missed them and `filterwarnings = ["error"]` escalated the import to a collection error. Filter by message instead ("invalid escape sequence"), which is category-agnostic and stays narrow, so it suppresses only that warning on every supported Python version. --- tests/analog_info/test_sparse_code_constructor.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/tests/analog_info/test_sparse_code_constructor.py b/tests/analog_info/test_sparse_code_constructor.py index df67de63e..8ae4c448a 100644 --- a/tests/analog_info/test_sparse_code_constructor.py +++ b/tests/analog_info/test_sparse_code_constructor.py @@ -18,11 +18,12 @@ from scipy.sparse import csr_matrix # `sparse_code_constructor` imports `bposd`, whose source contains invalid escape -# sequences that raise a SyntaxWarning on Python >= 3.12. Under the project's -# ``filterwarnings = ["error"]`` config this would turn the import into a -# collection error, so suppress it while importing the module under test. +# sequences. These raise a DeprecationWarning (Python <= 3.11) or a SyntaxWarning +# (>= 3.12); under the project's ``filterwarnings = ["error"]`` config either would +# turn the import into a collection error. Ignore that specific warning by message +# (category-agnostic) while importing the module under test. with warnings.catch_warnings(): - warnings.simplefilter("ignore", SyntaxWarning) + warnings.filterwarnings("ignore", message="invalid escape sequence") import mqt.qecc.analog_information_decoding.code_construction.sparse_code_constructor as scc if TYPE_CHECKING: From 2f928f5febd1982b743085b408e4c138163c4711 Mon Sep 17 00:00:00 2001 From: Ludwig Schmid Date: Mon, 13 Jul 2026 13:46:22 +0200 Subject: [PATCH 28/29] =?UTF-8?q?=F0=9F=94=A5=20Remove=20accidentally=20co?= =?UTF-8?q?mmitted=20test=20artifacts?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The merge commit swept in files written to the repo root by the test suite (`res`, `results/`, `schedule_*.pkl`) via `git add -A`. The empty `res` file broke the `license-tools` pre-commit hook ("Failed to determine comment style"). Remove them and add matching `.gitignore` patterns so they cannot be re-committed. --- .gitignore | 5 +++++ res | 0 .../z-meta=false/test/per_1.000e-01_ser_1.000e-01/id_0.json | 0 .../z-meta=false/test/per_1.000e-01_ser_1.000e-01/id_0.json | 0 schedule_2026-07-13_11-40-54.pkl | 3 --- schedule_2026-07-13_11-41-11.pkl | 3 --- 6 files changed, 5 insertions(+), 6 deletions(-) delete mode 100644 res delete mode 100644 results/wer_per_round/analog_tg/single_stage=True/bias=1.0_1.0_1.0/sus_th_depth=1/x-meta=true/z-meta=false/test/per_1.000e-01_ser_1.000e-01/id_0.json delete mode 100644 results/wer_per_round/hard_syndrome/single_stage=False/bias=1.0_1.0_1.0/sus_th_depth=1/x-meta=true/z-meta=false/test/per_1.000e-01_ser_1.000e-01/id_0.json delete mode 100644 schedule_2026-07-13_11-40-54.pkl delete mode 100644 schedule_2026-07-13_11-41-11.pkl diff --git a/.gitignore b/.gitignore index 0730d1d0d..f79db28bc 100644 --- a/.gitignore +++ b/.gitignore @@ -182,3 +182,8 @@ node_modules/ wheelhouse/ pytest.ini + +# Artifacts written to the repo root by some tests/examples +/res +/results/ +/schedule_*.pkl diff --git a/res b/res deleted file mode 100644 index e69de29bb..000000000 diff --git a/results/wer_per_round/analog_tg/single_stage=True/bias=1.0_1.0_1.0/sus_th_depth=1/x-meta=true/z-meta=false/test/per_1.000e-01_ser_1.000e-01/id_0.json b/results/wer_per_round/analog_tg/single_stage=True/bias=1.0_1.0_1.0/sus_th_depth=1/x-meta=true/z-meta=false/test/per_1.000e-01_ser_1.000e-01/id_0.json deleted file mode 100644 index e69de29bb..000000000 diff --git a/results/wer_per_round/hard_syndrome/single_stage=False/bias=1.0_1.0_1.0/sus_th_depth=1/x-meta=true/z-meta=false/test/per_1.000e-01_ser_1.000e-01/id_0.json b/results/wer_per_round/hard_syndrome/single_stage=False/bias=1.0_1.0_1.0/sus_th_depth=1/x-meta=true/z-meta=false/test/per_1.000e-01_ser_1.000e-01/id_0.json deleted file mode 100644 index e69de29bb..000000000 diff --git a/schedule_2026-07-13_11-40-54.pkl b/schedule_2026-07-13_11-40-54.pkl deleted file mode 100644 index 3e5e51ffd..000000000 --- a/schedule_2026-07-13_11-40-54.pkl +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:7111e5726c71f359709d4b10e912598b7f61009947a4c7bc09bd4f9ab2e49ea7 -size 16377 diff --git a/schedule_2026-07-13_11-41-11.pkl b/schedule_2026-07-13_11-41-11.pkl deleted file mode 100644 index 816586ad0..000000000 --- a/schedule_2026-07-13_11-41-11.pkl +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:ccdf0540104990966575e5fecb1058555ea2d8eb4a4d4f2612bbe819ad1a2f2d -size 15075 From 6605b63544252fb37935574b4f8bbabdee109196 Mon Sep 17 00:00:00 2001 From: Ludwig Schmid Date: Mon, 13 Jul 2026 14:18:02 +0200 Subject: [PATCH 29/29] =?UTF-8?q?=F0=9F=90=9B=20Suppress=20bposd=20import?= =?UTF-8?q?=20warning=20by=20category,=20not=20message?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The message-based filter failed on Python 3.14: invalid escape sequences are still only a warning there, but the message wording changed ("\"\\i\" is an invalid escape sequence" instead of "invalid escape sequence '\\i'"), so the anchored message regex no longer matched and `filterwarnings = ["error"]` escalated the bposd import to a collection error. Ignore by warning category instead (DeprecationWarning on Python <= 3.11, SyntaxWarning on >= 3.12), which is robust to the wording changes. Verified the import succeeds under strict warnings on 3.10 through 3.14. --- tests/analog_info/test_sparse_code_constructor.py | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/tests/analog_info/test_sparse_code_constructor.py b/tests/analog_info/test_sparse_code_constructor.py index 8ae4c448a..613e60cb7 100644 --- a/tests/analog_info/test_sparse_code_constructor.py +++ b/tests/analog_info/test_sparse_code_constructor.py @@ -19,11 +19,13 @@ # `sparse_code_constructor` imports `bposd`, whose source contains invalid escape # sequences. These raise a DeprecationWarning (Python <= 3.11) or a SyntaxWarning -# (>= 3.12); under the project's ``filterwarnings = ["error"]`` config either would -# turn the import into a collection error. Ignore that specific warning by message -# (category-agnostic) while importing the module under test. +# (>= 3.12), and the exact message wording also changed across versions; under the +# project's ``filterwarnings = ["error"]`` config any of them would turn the import +# into a collection error. Ignore by warning category (robust across all supported +# Python versions) while importing the module under test. with warnings.catch_warnings(): - warnings.filterwarnings("ignore", message="invalid escape sequence") + warnings.simplefilter("ignore", DeprecationWarning) + warnings.simplefilter("ignore", SyntaxWarning) import mqt.qecc.analog_information_decoding.code_construction.sparse_code_constructor as scc if TYPE_CHECKING: