From 5bc91239490163fa863434b6d55828103c2c9952 Mon Sep 17 00:00:00 2001 From: Charles Yuan Date: Tue, 27 Aug 2024 10:52:07 -0700 Subject: [PATCH] Fix `selection_registers` in `qubitization_walk_test` (#1350) --- qualtran/bloqs/for_testing/qubitization_walk_test.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/qualtran/bloqs/for_testing/qubitization_walk_test.py b/qualtran/bloqs/for_testing/qubitization_walk_test.py index a450e3ed8..d8655faeb 100644 --- a/qualtran/bloqs/for_testing/qubitization_walk_test.py +++ b/qualtran/bloqs/for_testing/qubitization_walk_test.py @@ -19,7 +19,7 @@ import scipy from numpy.typing import NDArray -from qualtran import Signature +from qualtran import BoundedQUInt, Register from qualtran.bloqs.block_encoding.lcu_block_encoding import SelectBlockEncoding from qualtran.bloqs.multiplexers.select_pauli_lcu import SelectPauliLCU from qualtran.bloqs.qubitization.qubitization_walk_operator import QubitizationWalkOperator @@ -37,12 +37,12 @@ class PrepareUniformSuperpositionTest(PrepareOracle): qlambda: float = 0.0 @cached_property - def selection_registers(self) -> Signature: - return Signature.build(selection=(self.n - 1).bit_length()) + def selection_registers(self) -> Tuple[Register, ...]: + return (Register('selection', BoundedQUInt((self.n - 1).bit_length(), self.n)),) @cached_property - def junk_registers(self) -> Signature: - return Signature.build() + def junk_registers(self) -> Tuple[Register, ...]: + return () @cached_property def l1_norm_of_coeffs(self) -> SymbolicFloat: