diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 984c81b..b7a0121 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -38,7 +38,7 @@ jobs: - name: Install Deps run: make install - name: Downgrade Qiskit - run: venv/bin/pip install qiskit==0.41.1 + run: venv/bin/pip install qiskit==0.43.0 - name: Install and Run Tests run: make unit-tests lint: diff --git a/MANIFEST.in b/MANIFEST.in new file mode 100644 index 0000000..a58b9c5 --- /dev/null +++ b/MANIFEST.in @@ -0,0 +1,3 @@ +include LICENSE +include README.md +include qiskit_alice_bob_provider/local/resources/*.json diff --git a/README.md b/README.md index 719258b..63ce606 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,7 @@ pip install qiskit-alice-bob-provider `pip` will handle installing all the python dependencies automatically and you will always install the latest (and well-tested) version. -## Use your Alice & Bob API key +## Remote execution on Alice & Bob QPUs: use your API key To obtain an API key, please [contact Alice & Bob](https://alice-bob.com/contact/). @@ -29,7 +29,7 @@ Where `MY_API_KEY` is your API key to the Alice & Bob API. ```python print(ab.backends()) -backend = ab.get_backend('SINGLE_CAT_SIMULATOR') +backend = ab.get_backend('SINGLE_CAT') ``` The backend can then be used like a regular Qiskit backend: @@ -45,3 +45,61 @@ job = execute(c, backend) res = job.result() print(res.get_counts()) ``` + +## Local simulation of cat quit processors + +This project contains multiple simulators of multi cat qubit processors. + +```python +from qiskit_alice_bob_provider import AliceBobLocalProvider +from qiskit import QuantumCircuit, execute, transpile + +provider = AliceBobLocalProvider() +print(provider.backends()) +# PHYSICAL_CATS_6, PHYSICAL_CATS_40, LESCANNE_2020 +``` + +The `PHYSICAL_CATS` backends are theoretical models of quantum processors made +up of physical cat qubits. +They can be used to study the properties of error correction codes implemented +with physical cat qubits, for different hardware performance levels +(see the parameters of class `PhysicalCatProcessor`). + +The `LESCANNE_2020` backend is an interpolated model simulating the processor +used in the [seminal paper](https://arxiv.org/pdf/1907.11729.pdf) by Raphaël +Lescanne in 2020. +This interpolated model is configured to act as a digital twin of the cat qubit +used in this paper. +It does not represent the current performance of Alice & Bob's cat qubits. + +The example below schedules and simulates a Bell state preparation circuit on +a `PHYSICAL_CATS_6` processor, for different values of parameters `alpha` and +`kappa_2`. + +```python +from qiskit_alice_bob_provider import AliceBobLocalProvider +from qiskit import QuantumCircuit, execute, transpile + +provider = AliceBobLocalProvider() + +circ = QuantumCircuit(2, 2) +circ.initialize('0+') +circ.cx(0, 1) +circ.measure(0, 0) +circ.measure(1, 1) + +# Default 6-qubit QPU with the ratio of memory dissipation rates set to +# k1/k2=1e-5 and cat amplitude alpha set to 4. +backend = provider.get_backend('PHYSICAL_CATS_6') + +print(transpile(circ, backend).draw()) +# *Displays a timed and scheduled circuit* + +print(execute(circ, backend, shots=100000).result().get_counts()) +# {'11': 49823, '00': 50177} + +# Changing the cat amplitude from 4 (default) to 2 and k1/k2 to 1e-2. +backend = provider.get_backend('PHYSICAL_CATS_6', alpha=2, kappa_2=1e4) +print(execute(circ, backend, shots=100000).result().get_counts()) +# {'01': 557, '11': 49422, '10': 596, '00': 49425} +``` diff --git a/pyproject.toml b/pyproject.toml index 627a3aa..1062a72 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -31,9 +31,11 @@ urls = {Homepage = "https://github.com/Alice-Bob-SW/qiskit-alice-bob-provider", requires-python = ">=3.7" dependencies = [ "requests", - "qiskit-terra>=0.22.0", # first version with backend transpiler plugins + "qiskit-terra>=0.24.0", # required for correct handling of durations + "qiskit-aer", "qiskit-qir-alice-bob-fork==0.3.2b0", - "tenacity" + "tenacity", + "pydantic>=2.0" ] [project.optional-dependencies] @@ -57,6 +59,7 @@ dev = [ [project.entry-points."qiskit.transpiler.translation"] state_preparation = "qiskit_alice_bob_provider.translation_plugin:StatePreparationPlugin" +local_state_preparation = "qiskit_alice_bob_provider.local.translation_plugin:LocalStatePreparationPlugin" [tool.setuptools.packages.find] include = ["qiskit_alice_bob_provider*"] @@ -73,6 +76,8 @@ line_length = 79 module = [ "setuptools", "qiskit.*", - "qiskit_qir.*" + "qiskit_qir.*", + "qiskit_aer.*", + "scipy.*" ] ignore_missing_imports = true diff --git a/qiskit_alice_bob_provider/__init__.py b/qiskit_alice_bob_provider/__init__.py index d5969d6..ce5c042 100644 --- a/qiskit_alice_bob_provider/__init__.py +++ b/qiskit_alice_bob_provider/__init__.py @@ -16,4 +16,5 @@ # flake8: noqa: F401 +from .local import AliceBobLocalProvider from .provider import AliceBobProvider diff --git a/qiskit_alice_bob_provider/custom_instructions.py b/qiskit_alice_bob_provider/custom_instructions.py index 3c8ff10..de42b8e 100644 --- a/qiskit_alice_bob_provider/custom_instructions.py +++ b/qiskit_alice_bob_provider/custom_instructions.py @@ -16,7 +16,7 @@ from typing import Optional -from qiskit.circuit import Instruction, InstructionSet, QuantumCircuit +from qiskit.circuit import Instruction, InstructionSet, QuantumCircuit, Reset from qiskit.circuit.equivalence_library import SessionEquivalenceLibrary from qiskit.circuit.quantumcircuit import ClbitSpecifier, QubitSpecifier @@ -47,3 +47,16 @@ def _measure_x( SessionEquivalenceLibrary.add_equivalence( _measure_x_inst, _measure_x_inst.definition ) + + +# Add an equivalent from Reset to Initialize('0'). This is useful in the case +# of the local provider. +# Although we may want to preserve the Reset instruction for a future behavior +# not yet implemented (e.g., resetting to the void state of the cavity in +# case of cat qubits, which is not how the logical |0> state is encoded), users +# are used to use Reset to actually say Initialize('0'). +# That's what this equivalence rule does. If it causes trouble in the future, +# it may be removed. +_c = QuantumCircuit(1, 0) +_c.initialize('0', 0) +SessionEquivalenceLibrary.add_equivalence(Reset(), _c) diff --git a/qiskit_alice_bob_provider/ensure_preparation_pass.py b/qiskit_alice_bob_provider/ensure_preparation_pass.py index aeb74a2..5ccc956 100644 --- a/qiskit_alice_bob_provider/ensure_preparation_pass.py +++ b/qiskit_alice_bob_provider/ensure_preparation_pass.py @@ -14,11 +14,17 @@ # limitations under the License. ############################################################################## -from qiskit.circuit import Qubit, Reset +from typing import Callable + +from qiskit.circuit import Instruction, Qubit, Reset from qiskit.dagcircuit import DAGCircuit, DAGInNode, DAGOpNode from qiskit.transpiler import TransformationPass +def _reset_prep() -> Instruction: + return Reset() + + class EnsurePreparationPass(TransformationPass): """ A transpilation pass that ensures there is a state preparation at the @@ -47,6 +53,12 @@ class EnsurePreparationPass(TransformationPass): from Qiskit to QIR. """ + def __init__( + self, prep_instruction: Callable[[], Instruction] = _reset_prep + ): + super().__init__() + self._prep = prep_instruction + def run(self, dag: DAGCircuit) -> DAGCircuit: preparations = {'reset', 'initialize', 'state_preparation'} for node in dag.topological_nodes(): @@ -62,7 +74,7 @@ def run(self, dag: DAGCircuit) -> DAGCircuit: new_dag = DAGCircuit() new_dag.add_qubits(successor.qargs) new_dag.add_clbits(successor.cargs) - new_dag.apply_operation_back(Reset(), qargs=(node.wire,)) + new_dag.apply_operation_back(self._prep(), qargs=(node.wire,)) new_dag.apply_operation_back( successor.op, qargs=successor.qargs, diff --git a/qiskit_alice_bob_provider/job.py b/qiskit_alice_bob_provider/job.py index 21983a0..37fd68d 100644 --- a/qiskit_alice_bob_provider/job.py +++ b/qiskit_alice_bob_provider/job.py @@ -71,7 +71,7 @@ def __init__( self._backend_v2 = backend self._api_client = api_client self._circuit = circuit - self._last_response: Optional[dict] = None + self._last_response: Optional[Dict] = None self._status: Optional[JobStatus] = None self._counts: Optional[Dict[str, int]] = None self._files: Dict[str, _DownloadedFile] = {} diff --git a/qiskit_alice_bob_provider/local/__init__.py b/qiskit_alice_bob_provider/local/__init__.py new file mode 100644 index 0000000..7974c7f --- /dev/null +++ b/qiskit_alice_bob_provider/local/__init__.py @@ -0,0 +1,19 @@ +############################################################################## +# Copyright 2023 Alice & Bob +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +############################################################################## + +# flake8: noqa: F401 + +from .provider import AliceBobLocalProvider diff --git a/qiskit_alice_bob_provider/local/backend.py b/qiskit_alice_bob_provider/local/backend.py new file mode 100644 index 0000000..2203e32 --- /dev/null +++ b/qiskit_alice_bob_provider/local/backend.py @@ -0,0 +1,190 @@ +############################################################################## +# Copyright 2023 Alice & Bob +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +############################################################################## + +from typing import List, Optional, Union + +from qiskit import QuantumCircuit, execute +from qiskit.providers import BackendV2, Options +from qiskit.transpiler import PassManager, Target +from qiskit_aer import AerSimulator +from qiskit_aer.backends.aerbackend import AerBackend + +from ..processor.description import ProcessorDescription +from .job import ProcessorSimulationJob +from .quantum_errors import build_quantum_error_passes +from .readout_errors import build_readout_noise_model +from .target import processor_to_target + + +class ProcessorSimulator(BackendV2): + """A Qiskit backend enabling transpilation to and simulation of an + arbitrary quantum processor (QPU), as described by a ProcessorDescription + instance. + + Although the ProcessorDescription class provides a richer representation + of a QPU than Qiskit's Target and NoiseModel can, the ProcessorSimulator + class should feel like any other Qiskit backend. + + ``` + from qiskit import QuantumCircuit + from qiskit_alice_bob_provider.local import ProcessorSimulator + from qiskit_alice_bob_provider.physical_cat import PhysicalCatProcessor + + + circ = QuantumCircuit(2, 2) + # Building the circuit.... + + processor = PhysicalCatProcessor() + backend = ProcessorSimulator(processor) + + # Transpile and schedule the circuit + transpiled = transpile(circ, backend) + + # Simulate the circuit + backend.run(transpiled) + + # Do both steps in one: + execute(circ, backend) + ``` + """ + + def __init__( + self, + processor: ProcessorDescription, + execution_backend: AerBackend = AerSimulator(), + name: Optional[str] = None, + ): + """A Qiskit backend enabling transpilation to and simulation of an + arbitrary quantum processor, as described by a ProcessorDescription + instance. + + Args: + processor (ProcessorDescription): the description of the quantum + processor to simulate + execution_backend (AerBackend, optional): the Qiskit simulator used + in the background for simulation. Defaults to AerSimulator(). + name (Optional[str], optional): an optional name for the backend. + """ + super().__init__(name=name, backend_version=1) + self._execution_backend = execution_backend + self._target = processor_to_target(processor) + self._noise_pass_manager = PassManager( + build_quantum_error_passes(processor) + ) + self._noise_model = build_readout_noise_model(processor) + + @property + def target(self) -> Target: + """The Qiskit Target representing the QPU associated to this backend + (ProcessorSimulator) for the Qiskit transpiler. + + Warning: the Qiskit Target does not accurately describe a QPU like + a ProcessorDescription does. Due to its implementation, it suffers + multiple limitations and should not be trusted. + In this backend, we only use it as a vessel to provide the Qiskit + transpiler with a custom implementation of InstructionDurations. + To learn more about the limitations of Qiskit Targets, please read + the docstring of :func:`processor_to_target`.""" + return self._target + + @classmethod + def _default_options(cls) -> Options: + return AerSimulator().options + + @property + def options(self): + """Return the options of the underlying execution backend. + + The execution backend is AerSimulator unless otherwise specified. + """ + return self._execution_backend.options + + def set_options(self, **fields): + """Set the options fields of the underlying execution backend. + + The execution backend is AerSimulator unless otherwise specified. + """ + self._execution_backend.set_options(**fields) + + def __repr__(self) -> str: + return f'' + + @property + def max_circuits(self) -> Optional[int]: + return None + + def run( + self, run_input: Union[QuantumCircuit, List[QuantumCircuit]], **options + ) -> ProcessorSimulationJob: + """Simulate the execution of one or multiple circuits on a QPU. + + Note that these circuits should be already transpiled and scheduled, + otherwise the simulation results will be meaningless. + To do so, either apply function :func:`transpile` to the circuits or + use :func:`execute` instead of calling `ProcessorSimulator.run` + directly. + + Args: + run_input (Union[QuantumCircuit, List[QuantumCircuit]]): one or + multiple circuits to simulate. + **options: additional arguments are interpreted as options for + the underlying execution backend, usually an instance of + AerSimulator. + """ + if isinstance(run_input, QuantumCircuit): + circuits = [run_input] + else: + circuits = run_input + + # This step inserts all the quantum errors Kraus maps into the + # circuits. + noisy_circuits = self._noise_pass_manager.run(circuits) + + # Instructions that cannot be simulated remain in the circuit after + # the previous step. For example: Initialize(+), MeasureX(). + # Decomposing the circuits ensures those instructions are decomposed + # into smaller instructions that the simulator can work with. + # Note: this will cause instructions that may not be in the processor + # instruction set to appear. This is not an issue though, because at + # this stage the noise has already been inserted and all + # transformations done by the Qiskit transpiler don't change the + # simulation results. + decomposed = [c.decompose() for c in noisy_circuits] + + job = execute( + experiments=decomposed, + backend=self._execution_backend, + noise_model=self._noise_model, + **options, + ) + + return ProcessorSimulationJob( + backend=self, + wrapped_job=job, + circuits=circuits, + noisy_circuits=noisy_circuits, + ) + + def get_scheduling_stage_plugin(self) -> str: + """Indicate to the Qiskit transpiler that the transpiled circuit should + additionally be scheduled (with the 'asap' method). + """ + return 'asap' + + def get_translation_stage_plugin(self): + """This hook tells Qiskit to run the transpilation passes contained + in local.translation_plugin.LocalStatePreparationPlugin""" + return 'local_state_preparation' diff --git a/qiskit_alice_bob_provider/local/coupling_maps.py b/qiskit_alice_bob_provider/local/coupling_maps.py new file mode 100644 index 0000000..08f757e --- /dev/null +++ b/qiskit_alice_bob_provider/local/coupling_maps.py @@ -0,0 +1,51 @@ +############################################################################## +# Copyright 2023 Alice & Bob +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +############################################################################## + +from typing import List, Tuple + + +def bidirect_map(map: List[Tuple[int, int]]) -> List[Tuple[int, int]]: + """From a coupling map where edges flow in one direction only, add + edges pointing in the opposite direction.""" + out = [] + for i, j in map: + out.append((i, j)) + out.append((j, i)) + return out + + +def circular_map(n_qubits: int) -> List[Tuple[int, int]]: + """A bidirected coupling map where qubits form a circle""" + return bidirect_map([(i, (i + 1) % n_qubits) for i in range(n_qubits)]) + + +def _rect_index(width: int, i: int, j: int) -> int: + return i * width + j + + +def rectangular_map(height: int, width: int) -> List[Tuple[int, int]]: + """A bidrected coupling map where qubits are aligned on a grid""" + map = [] + for i in range(height): + for j in range(width): + here = _rect_index(width, i, j) + if i + 1 < height: + below = _rect_index(width, i + 1, j) + map.append((here, below)) + if j + 1 < width: + right = _rect_index(width, i, j + 1) + map.append((here, right)) + return bidirect_map(map) diff --git a/qiskit_alice_bob_provider/local/instruction_durations.py b/qiskit_alice_bob_provider/local/instruction_durations.py new file mode 100644 index 0000000..85f0f2a --- /dev/null +++ b/qiskit_alice_bob_provider/local/instruction_durations.py @@ -0,0 +1,205 @@ +############################################################################## +# Copyright 2023 Alice & Bob +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +############################################################################## + +import warnings +from typing import Any, Dict, Iterable, List, Optional, Tuple, Union + +from qiskit.circuit import Barrier, Delay, Instruction, Parameter, Qubit +from qiskit.transpiler.instruction_durations import ( + InstructionDurations, + InstructionDurationsType, +) + +from ..processor.description import ProcessorDescription +from .proc_to_qiskit import processor_to_qiskit_instruction + + +class ProcessorInstructionDurations(InstructionDurations): + """A more flexible version of InstructionDurations. + + InstructionDurations stores a duration for every supported combination of + instruction (a name), qubits, and params. In this sense, it is some kind of + fancy dict. + + This makes it impossible to represent a continuous relation between + parameters and duration. For instance, InstructionDurations cannot + represent a rotation around the Z-axis rz(theta) whose duration + continuously depends on the angle theta. + + ProcessorInstructionDurations on the other hand accepts any parameter in + :method:`ProcessorInstructionDurations.get` and forwards the requested + parameters to the underlying ProcessorDuration. + """ + + def __init__(self, processor: ProcessorDescription): + super().__init__(instruction_durations=None, dt=processor.clock_cycle) + self._proc = processor + self._qiskit_to_proc_mapping = _from_qiskit_to_proc_instructions( + processor + ) + + def get( + self, + inst: Union[str, Instruction], + qubits: Union[int, List[int], Qubit, List[Qubit]], + unit: str = 'dt', + parameters: Optional[List[float]] = None, + ) -> float: + """Get the duration of the instruction with the name, qubits, and + parameters. + + Instructions may have a parameter-dependent durations + + Args: + inst: An instruction or its name to be queried. + qubits: Qubits or its indices that the instruction acts on. + unit: The unit of duration to be returned. It must be 's' or 'dt'. + parameters: The value of the parameters of the desired instruction. + + Returns: + float: The duration of the instruction on the qubits. + + Raises: + TranspilerError: No duration is defined for the instruction. + """ + if isinstance(inst, Barrier): + return 0 + elif isinstance(inst, Delay): + with warnings.catch_warnings(): + warnings.simplefilter('ignore') + converted = self._convert_unit(inst.duration, inst.unit, unit) + if converted == 0: + warnings.warn( + ( + f'Duration is rounded to {converted} [dt] from' + f' {inst.duration} [{inst.unit}]' + ), + UserWarning, + ) + return converted + + if isinstance(inst, Instruction): + inst_name = inst.name + else: + inst_name = inst + + if isinstance(qubits, (int, Qubit)): + qubits = [qubits] + + if isinstance(qubits[0], Qubit): + # This explicit for loop pleases mypy (as opposed to a + # for-comprehension). + new_qubits = [] + for q in qubits: + assert isinstance(q, Qubit) + new_qubits.append(q.index) + qubits = new_qubits + + if parameters is None and isinstance(inst, Instruction): + parameters = inst.params + + with warnings.catch_warnings(): + # We expect some rounding when going from s to dt, so we simply + # ignore those. + warnings.simplefilter('ignore') + return self._get(inst_name, qubits, unit, parameters) + + def _get( + self, + name: str, + qubits: List[int], + to_unit: str, + parameters: Optional[Iterable[float]] = None, + ) -> float: + if name == 'barrier': + return 0 + + parameters = list(parameters) if parameters else [] + + try: + candidate_instructions = self._qiskit_to_proc_mapping[ + (name, tuple(qubits)) + ] + except KeyError as e: + raise ValueError( + _instruction_not_found(name, qubits, parameters) + ) from e + + for instr, proc_instr_name in candidate_instructions: + if _have_same_params( + requested=parameters, definition=instr.params + ): + applied_instr = self._proc.apply_instruction( + name=proc_instr_name, + qubits=tuple(qubits), + params=parameters, + ) + return self._convert_unit(applied_instr.duration, 's', to_unit) + + raise ValueError(_instruction_not_found(name, qubits, parameters)) + + def update( + self, + inst_durations: Optional[InstructionDurationsType], + dt: float = None, # type: ignore + ): + """ProcessorInstructionDurations does not support updating its content + like InstructionDurations. It is not a dict.""" + return NotImplementedError() + + +def _instruction_not_found( + name: str, qubits: List[int], parameters: List[float] +) -> str: + return ( + f'The processor does not support instruction "{name}" on qubits' + f' {qubits} with params "{parameters}"' + ) + + +_InstructionDict = Dict[ + Tuple[str, Tuple[int, ...]], List[Tuple[Instruction, str]] +] + + +def _from_qiskit_to_proc_instructions( + processor: ProcessorDescription, +) -> _InstructionDict: + """Create a dict mapping (Qiskit instruction name, qubits) to + (Qiskit instruction, proc instruction name). + """ + out: _InstructionDict = {} + for instr in processor.all_instructions(): + qiskit_instr = processor_to_qiskit_instruction(instr) + key = (str(qiskit_instr.name), instr.qubits) + if key not in out: + out[key] = [] + out[key].append((qiskit_instr, instr.name)) + return out + + +def _have_same_params(requested: List[Any], definition: List[Any]) -> bool: + """Compare the parameters provided by the Qiskit instruction in the circuit + with the parameters of a reference Qiskit instruction.""" + if len(requested) != len(definition): + return False + for req, def_ in zip(requested, definition): + if isinstance(def_, Parameter): + continue + if req == def_: + continue + return False + return True diff --git a/qiskit_alice_bob_provider/local/job.py b/qiskit_alice_bob_provider/local/job.py new file mode 100644 index 0000000..6b9b071 --- /dev/null +++ b/qiskit_alice_bob_provider/local/job.py @@ -0,0 +1,69 @@ +############################################################################## +# Copyright 2023 Alice & Bob +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +############################################################################## + +from typing import List + +from qiskit import QuantumCircuit +from qiskit.providers import JobV1 +from qiskit.providers.backend import Backend +from qiskit.result import Result +from qiskit_aer.jobs import AerJob + + +class ProcessorSimulationJob(JobV1): + """A wrapper for AerJobs containing different versions of the input + circuits (with and without noise). + + This is mainly useful for debugging purpose.""" + + def __init__( + self, + backend: Backend, + wrapped_job: AerJob, + circuits: List[QuantumCircuit], + noisy_circuits: List[QuantumCircuit], + **kwargs, + ) -> None: + super().__init__(backend, wrapped_job.job_id(), **kwargs) + self._circuits = circuits + self._noisy_circuits = noisy_circuits + self._wrapped_job = wrapped_job + + def submit(self): + return self._wrapped_job.submit() + + def result(self) -> Result: + return self._wrapped_job.result() + + def cancel(self): + return self._wrapped_job.cancel() + + def status(self): + return self._wrapped_job.status() + + def circuits(self) -> List[QuantumCircuit]: + """Return the list of QuantumCircuit augmented with the quantum noise + instructions.""" + return self._circuits + + def noisy_circuits(self) -> List[QuantumCircuit]: + """Return the list of QuantumCircuit augmented with the quantum noise + instructions.""" + return self._noisy_circuits + + @property + def wrapped_job(self) -> AerJob: + return self._wrapped_job diff --git a/qiskit_alice_bob_provider/local/proc_to_qiskit.py b/qiskit_alice_bob_provider/local/proc_to_qiskit.py new file mode 100644 index 0000000..fd215e3 --- /dev/null +++ b/qiskit_alice_bob_provider/local/proc_to_qiskit.py @@ -0,0 +1,67 @@ +############################################################################## +# Copyright 2023 Alice & Bob +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +############################################################################## + +from typing import Dict, List + +from qiskit.circuit import Delay, Instruction, Measure, Parameter +from qiskit.circuit.library.standard_gates import ( + get_standard_gate_name_mapping, +) +from qiskit.extensions.quantum_initializer import Initialize + +from ..custom_instructions import MeasureX +from ..processor.description import InstructionProperties + + +def processor_to_qiskit_instruction( + proc_instruction: InstructionProperties, +) -> Instruction: + """Convert a procession instruction into its Qiskit implementation. + + If a new processor instruction cannot be straightforwardly mapped to a + Qiskit instruction, it must be explicitly added in this function.""" + params = (Parameter(p) for p in proc_instruction.params) + if proc_instruction.name == 'delay': + return Delay(*params) + elif proc_instruction.name in _known_preparations: + return Initialize(proc_instruction.name[1], *params) + elif proc_instruction.name in _known_measurements: + return _known_measurements[proc_instruction.name](*params) + elif proc_instruction.name in _known_rotations: + return _known_rotations[proc_instruction.name](*params) + elif proc_instruction.name in _known_no_arg_unitaries: + return _known_no_arg_unitaries[proc_instruction.name](*params) + else: + raise NotImplementedError( + f'Unsupported "{proc_instruction.name}" processor instruction' + ' found, cannot convert to a Qiskit instruction' + ) + + +_standard_gates = get_standard_gate_name_mapping() +_known_no_arg_unitaries: Dict[str, type] = { + name: inst.__class__ + for name, inst in _standard_gates.items() + if len(inst.params) == 0 +} +_known_rotations: Dict[str, type] = { + name: _standard_gates[name].__class__ for name in ['rx', 'ry', 'rz'] +} +_known_preparations: List[str] = ['p0', 'p+', 'p1', 'p-'] +_known_measurements: Dict[str, type] = { + 'mz': Measure, + 'mx': MeasureX, +} diff --git a/qiskit_alice_bob_provider/local/provider.py b/qiskit_alice_bob_provider/local/provider.py new file mode 100644 index 0000000..2f14a40 --- /dev/null +++ b/qiskit_alice_bob_provider/local/provider.py @@ -0,0 +1,133 @@ +############################################################################## +# Copyright 2023 Alice & Bob +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +############################################################################## + +from functools import partial +from pathlib import Path +from typing import Callable, Dict, List, Optional, Tuple + +from qiskit.providers import BackendV2, ProviderV1 + +from ..processor.interpolated_cat import InterpolatedCatProcessor +from ..processor.physical_cat import PhysicalCatProcessor +from ..processor.serialization.model import SerializedProcessor +from .backend import ProcessorSimulator +from .coupling_maps import circular_map, rectangular_map + +_PARENT_DIR = Path(__file__).parent + + +class AliceBobLocalProvider(ProviderV1): + """Class listing a number of preset backends simulating cat qubit based + quantum processors. + + Simulations will run locally on the machine where the backend is invoked. + """ + + def __init__(self) -> None: + self._backends: List[ProcessorSimulator] = [] + self._backend_builders: Dict[ + str, Callable[..., ProcessorSimulator] + ] = {} + self._backend_builders['PHYSICAL_CATS_6'] = partial( + self.build_physical_backend, + n_qubits=6, + coupling_map=circular_map(6), + name='PHYSICAL_CATS_6', + ) + self._backend_builders['PHYSICAL_CATS_40'] = partial( + self.build_physical_backend, + n_qubits=40, + coupling_map=rectangular_map(5, 8), + name='PHYSICAL_CATS_40', + ) + self._backend_builders['LESCANNE_2020'] = partial( + self.build_from_serialized, + file_path=str(_PARENT_DIR / 'resources' / 'lescanne_2020.json'), + name='LESCANNE_2020', + ) + self._backends = [func() for func in self._backend_builders.values()] + + # pylint: disable=arguments-differ + def backends(self, name: Optional[str] = None) -> List[BackendV2]: + """Return a list of backends. + + Args: + name (str): if provided, only backends with this name will be + returned (there should be only one such backend). + + Returns: + List[BackendV2]: the list of maching backends. + """ + if name: + return [ + backend for backend in self._backends if backend.name == name + ] + return self._backends + + # pylint: disable=signature-differs + def get_backend(self, name: str, **processor_kwargs) -> ProcessorSimulator: + return self._backend_builders[name](**processor_kwargs) + + # pylint: disable=too-many-arguments + def build_physical_backend( + self, + n_qubits: int = 5, + kappa_1: float = 100, + kappa_2: float = 10_000_000, + alpha: float = 4, + clock_cycle: float = 1e-9, + coupling_map: Optional[List[Tuple[int, int]]] = None, + name: Optional[str] = None, + ) -> ProcessorSimulator: + """Build a backend simulating a quantum processor made of physical cat + qubits. + + Please refer to the docstring of ``PhysicalCatProcessor`` to learn more + about the arguments. + """ + return ProcessorSimulator( + processor=PhysicalCatProcessor( + n_qubits=n_qubits, + kappa_1=kappa_1, + kappa_2=kappa_2, + alpha=alpha, + clock_cycle=clock_cycle, + coupling_map=coupling_map, + ), + name=name, + ) + + def build_from_serialized( + self, + file_path: str, + clock_cycle: float = 1e-9, + alpha: float = 2, + name: Optional[str] = None, + ) -> ProcessorSimulator: + """Build a backend simulating a cat qubit based quantum processor + described in a serialized format in a json file. + + See file ``lescanne_2020.json`` in this package as an example.""" + with open(file_path, encoding='utf-8') as f: + serialized = SerializedProcessor.model_validate_json(f.read()) + return ProcessorSimulator( + processor=InterpolatedCatProcessor( + serialized_processor=serialized, + clock_cycle=clock_cycle, + alpha=alpha, + ), + name=name, + ) diff --git a/qiskit_alice_bob_provider/local/quantum_errors.py b/qiskit_alice_bob_provider/local/quantum_errors.py new file mode 100644 index 0000000..7ef809d --- /dev/null +++ b/qiskit_alice_bob_provider/local/quantum_errors.py @@ -0,0 +1,284 @@ +############################################################################## +# Copyright 2023 Alice & Bob +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +############################################################################## + +from typing import Callable, Dict, List, Optional + +from qiskit.circuit import Delay, Instruction, QuantumCircuit +from qiskit.circuit.equivalence_library import ( + EquivalenceLibrary, + SessionEquivalenceLibrary, +) +from qiskit.circuit.library import IGate +from qiskit.dagcircuit import DAGCircuit +from qiskit.extensions.quantum_initializer import Initialize +from qiskit.quantum_info import Chi +from qiskit.transpiler import TransformationPass +from qiskit_aer.noise import LocalNoisePass, pauli_error + +from ..processor.description import InstructionProperties, ProcessorDescription +from ..processor.utils import chi_to_pauli_errors, is_diagonal +from .proc_to_qiskit import processor_to_qiskit_instruction + + +def build_quantum_error_passes( + processor: ProcessorDescription, +) -> List[TransformationPass]: + """From the description of a processor, build transpilation passes + that insert quantum noise instructions representing the imperfection of the + quantum processor. + + Note that the readout errors are not inserted by these transpilation + passes. Readout errors are handled separately and are contined in the + simulation NoiseModel. + """ + + passes = [_AddMeasureMarkerPass()] + for instruction in processor.all_instructions(): + pass_ = _transpilation_pass_from_instruction(processor, instruction) + if pass_ is not None: + passes.append(pass_) + + return passes + + +class _MeasureMarkerGate(IGate): + """A virtual gate that is inserted before every measure instruction. + + Since a LocalNoisePass cannot act on a measure instruction, we insert + marker gates before measure instructions, and then insert the measure + instruction's quantum error after the marker gate. This is a trick that we + may not need in the future, depending on the evolution of Qiskit.""" + + def __init__(self, name: str, label: Optional[str] = None): + super().__init__(label=label) + self.name = name + + def add_equivalence(self, library: EquivalenceLibrary) -> None: + """Add an implementation of this marker gate to an equivalence library + so that qiskit_aer can interpret the marker gate""" + circuit = QuantumCircuit(1, 0) + circuit.id(0) + library.add_equivalence(self, circuit) + + +class _MxMarkerGate(_MeasureMarkerGate): + """A virtual gate that is inserted before every MeasureX""" + + def __init__(self, label: Optional[str] = None): + super().__init__(name='measure_x_marker', label=label) + + +class _MzMarkerGate(_MeasureMarkerGate): + """A virtual gate that is inserted before every MeasureZ""" + + def __init__(self, label: Optional[str] = None): + super().__init__(name='measure_z_marker', label=label) + + +_marker_gate_types: Dict[str, type] = { + 'measure': _MzMarkerGate, + 'measure_x': _MxMarkerGate, +} + + +# These equivalences are added so that qiskit_aer can interpret the marker +# gates. +for marker_gate_type in _marker_gate_types.values(): + marker_gate_type().add_equivalence(SessionEquivalenceLibrary) + + +class _AddMeasureMarkerPass(TransformationPass): + """A transpilation pass that inserts a virtual marker gate before every + measure instruction. + + Since a LocalNoisePass cannot act on a measure instruction, we insert + marker gates before measure instructions, and then insert the measure + instruction's quantum error after the marker gate. This is a trick that we + may not need in the future, depending on the evolution of Qiskit.""" + + def run(self, dag: DAGCircuit) -> DAGCircuit: + marked_instructions = set(_marker_gate_types.keys()) + for node in dag.topological_op_nodes(): + if node.name not in marked_instructions: + continue + new_dag = DAGCircuit() + new_dag.add_qubits(node.qargs) + new_dag.add_clbits(node.cargs) + marker_class = _marker_gate_types[node.name] + new_dag.apply_operation_back(marker_class(), qargs=node.qargs) + new_dag.apply_operation_back( + node.op, qargs=node.qargs, cargs=node.cargs + ) + dag.substitute_node_with_dag(node, new_dag) + return dag + + +# The signature of the kind of functions accepted by qiskit_aer's +# LocalNoisePass. +_Pass = Callable[[Instruction, List[int]], Optional[Instruction]] + + +def _transpilation_pass_from_instruction( + processor: ProcessorDescription, + instruction: InstructionProperties, +) -> Optional[LocalNoisePass]: + """From an instruction defined in the processor, create a + LocalNoisePass inserting quantum noise after occurrences of the + instruction in question.""" + + qiskit_instruction = processor_to_qiskit_instruction(instruction) + + if qiskit_instruction.name in _marker_gate_types: + return LocalNoisePass( + _pass_factory( + processor=processor, + instr_properties=instruction, + ), + op_types=[_marker_gate_types[qiskit_instruction.name]], + method='append', + ) + + else: + return LocalNoisePass( + _pass_factory( + processor=processor, + instr_properties=instruction, + ), + op_types=[qiskit_instruction.__class__], + method='append', + ) + + +def _pass_factory( + processor: ProcessorDescription, instr_properties: InstructionProperties +) -> _Pass: + """Build a Qiskit transpiler pass function for a given processor + instruction.""" + + # Parameters need to be adapted to the processor params format. + # Some instruction types must have their params handled in a specific way + # (e.g., Delay, Initialize). + param_handler_func = _param_handler_factory(processor, instr_properties) + + def _pass( + instruction: Instruction, qubits: List[int] + ) -> Optional[Instruction]: + if tuple(qubits) != instr_properties.qubits: + # if qubits don't match, insert nothing in circuit + return None + + params = param_handler_func(instruction) + if params is None: + # if params don't match (e.g., Initialize(+) when we're testing + # for Initialize(0)), insert nothing in circuit + return None + + chi_matrix = processor.apply_instruction( + name=instr_properties.name, + qubits=instr_properties.qubits, + params=params, + ).quantum_errors + if chi_matrix is None: + # if there is no quantum noise for this instruction, insert nothing + # in circuit + return None + if is_diagonal(chi_matrix): + # if the matrix is diagonal, insert the noise as Pauli errors + # rather than as a Chi/Kraus instruction. + # This allows the user to use a Clifford simulator like + # "stabilizer". + pauli_errors = chi_to_pauli_errors(chi_matrix) + error_instr = pauli_error( + list(pauli_errors.items()) + ).to_instruction() + else: + n_qubits = len(instr_properties.qubits) + # It is unclear why the 2**n_qubits is needed in the Qiskit + # implementation of Chi matrices. + error_instr = Chi(chi_matrix * (2**n_qubits)).to_instruction() + + # We wrap the error instruction into a sub-circuit so that we can give + # it a human-friendly name. + # This is useful for debugging purposes. This does not affect + # simulation performance because the wrapping sub-circuit is transpiled + # away later right before simulation. + # Can't we just rename the error instruction itself? No because it + # needs to have the name "kraus" for Qiskit Aer to understand what thi + # is. + wrapper_circ = QuantumCircuit( + error_instr.num_qubits, + error_instr.num_clbits, + name=f'{instr_properties.name}_error', + ) + wrapper_circ.append( + error_instr, wrapper_circ.qubits, wrapper_circ.clbits + ) + + return wrapper_circ.to_instruction() + + return _pass + + +# A function that inspects an instruction in a Qiskit circuit and transforms +# its params to be compatible with the processor format. +# If the return value is None, it means the params do not match the +# requirements for the ongoing transpilation pass (e.g., reading Initialize(+) +# when testing for Initialize(0)). +_ParamHandler = Callable[[Instruction], Optional[List]] + + +def _param_handler_factory( + processor: ProcessorDescription, instr_properties: InstructionProperties +) -> _ParamHandler: + # For a given processor instruction, we compute a reference Qiskit + # instruction. During the pass, we'll compare instructions in the circuit + # with this reference instruction. + reference = processor_to_qiskit_instruction(instr_properties) + + if isinstance(reference, Initialize): + + def _handle_initialize_params( + requested: Instruction, + ) -> Optional[List]: + if ( + len(requested.params) != 1 + or requested.params[0] != reference.params[0] + ): + return None + return [] + + return _handle_initialize_params + elif isinstance(reference, Delay): + + def _handle_delay_params(requested: Instruction) -> Optional[List]: + multipliers = { + 's': 1, + 'ms': 1e-3, + 'us': 1e-6, + 'ns': 1e-9, + 'ps': 1e-12, + 'dt': processor.clock_cycle, + } + duration_s = requested.duration * multipliers[requested.unit] + return [duration_s] + + return _handle_delay_params + else: + + def _handle_regular_params(requested: Instruction) -> Optional[List]: + return requested.params + + return _handle_regular_params diff --git a/qiskit_alice_bob_provider/local/readout_errors.py b/qiskit_alice_bob_provider/local/readout_errors.py new file mode 100644 index 0000000..5971019 --- /dev/null +++ b/qiskit_alice_bob_provider/local/readout_errors.py @@ -0,0 +1,68 @@ +############################################################################## +# Copyright 2023 Alice & Bob +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +############################################################################## + +import warnings +from typing import Optional, Set, Tuple + +from qiskit_aer.noise import NoiseModel, ReadoutError + +from ..processor.description import ProcessorDescription + + +def build_readout_noise_model( + proc: ProcessorDescription, +) -> Optional[NoiseModel]: + """A noise model describing only readout errors: the errors happening + during a measurement of the qubit state. + + All other errors ("quantum errors") are described as transpilation passes. + See module `quantum_errors.py`. + + A readout error is the probability that the qubit is in state 0 and that + the measurement device returns 1, or 1 -> 0, + ->- , - -> +, etc. + + Known limitation: Qiskit only supports one readout error per qubit. That's + because Qiskit assumes there is only one type of measurement per qubit + (measurement in the z-basis). For a cat, we can measure in the z and x + basis, so we would need to assign two readout errors per qubit. This is + impossible in the current state of Qiskit. + """ + + qiskit_noise_model = NoiseModel() + qubits_with_readout_error: Set[Tuple[int, ...]] = set() + + for instr in proc.all_instructions(): + if instr.readout_errors is None: + continue + p_1_given_0, p_0_given_1 = instr.readout_errors + error = ReadoutError( + [[1 - p_1_given_0, p_1_given_0], [p_0_given_1, 1 - p_0_given_1]] + ) + if instr.qubits in qubits_with_readout_error: + warnings.warn( + UserWarning( + f'Qubit(s) {instr.qubits} already contain a readout error,' + ' cannot add another one. The readout error of instruction' + f' {instr.name} will be ignored.' + ) + ) + else: + qiskit_noise_model.add_readout_error( + error=error, qubits=instr.qubits + ) + qubits_with_readout_error.add(instr.qubits) + + return qiskit_noise_model diff --git a/qiskit_alice_bob_provider/local/resources/lescanne_2020.json b/qiskit_alice_bob_provider/local/resources/lescanne_2020.json new file mode 100644 index 0000000..164dab4 --- /dev/null +++ b/qiskit_alice_bob_provider/local/resources/lescanne_2020.json @@ -0,0 +1,9928 @@ +{ + "metadata": { + "schema_version": "v2", + "generated_at": "Sat Sep 09 15:57:24 2023", + "name": "lescanne_2020" + }, + "instructions": [ + { + "name": "z", + "qubits": [ + [ + 0 + ] + ], + "free_params": [ + "nbar" + ], + "fixed_params": { + "mem_kappa_1ph_MHz": 0.053, + "mem_kappa_2ph_MHz": 0.04, + "truncature": 40.0, + "num_time_steps": 1000.0 + }, + "interpolation_points": [ + { + "pauli_probabilities": [ + 0.4402188697123621, + 0.07673550330570585, + 0.072237490214745, + 0.410808136767187 + ], + "duration": 3.7940853998330623e-6, + "params": { + "nbar": 0.8 + } + }, + { + "pauli_probabilities": [ + 0.4803467375761946, + 0.047163052126134974, + 0.04561244931387405, + 0.4268777609837963 + ], + "duration": 2.7148265172691835e-6, + "params": { + "nbar": 1.0 + } + }, + { + "pauli_probabilities": [ + 0.5111067276282741, + 0.028916426428354687, + 0.028721733481841344, + 0.43125511246152975 + ], + "duration": 2.065238504474334e-6, + "params": { + "nbar": 1.2 + } + }, + { + "pauli_probabilities": [ + 0.5543452439541414, + 0.010910147658835051, + 0.011306788844427186, + 0.4234378195425963 + ], + "duration": 1.341411757311416e-6, + "params": { + "nbar": 1.6 + } + }, + { + "pauli_probabilities": [ + 0.5833662647879851, + 0.0041683473963773175, + 0.004444920367157422, + 0.40802046744848014 + ], + "duration": 9.598361200530487e-7, + "params": { + "nbar": 2.0 + } + }, + { + "pauli_probabilities": [ + 0.6049050319637641, + 0.0016172486481974449, + 0.0017564184748486982, + 0.39172130091318974 + ], + "duration": 7.301720756406826e-7, + "params": { + "nbar": 2.4 + } + }, + { + "pauli_probabilities": [ + 0.6139564586563832, + 0.0010129940075149898, + 0.001107258297682783, + 0.3839232890384191 + ], + "duration": 6.475630510100543e-7, + "params": { + "nbar": 2.6 + } + }, + { + "pauli_probabilities": [ + 0.6367871384504658, + 0.0002538314507503534, + 0.00028089741912167357, + 0.36267813267966226 + ], + "duration": 4.742606749791328e-7, + "params": { + "nbar": 3.2 + } + }, + { + "pauli_probabilities": [ + 0.6464731441130338, + 0.00012825988465589688, + 0.00014245804112762535, + 0.3532561379611827 + ], + "duration": 4.1461023233265363e-7, + "params": { + "nbar": 3.5 + } + }, + { + "pauli_probabilities": [ + 0.6608060058767964, + 0.000041586332771864377, + 0.00004637761851801001, + 0.33910603017191376 + ], + "duration": 3.3935331465864793e-7, + "params": { + "nbar": 4.0 + } + }, + { + "pauli_probabilities": [ + 0.6733689945792822, + 0.000013646768183551659, + 0.000015257214945187056, + 0.32660210143758905 + ], + "duration": 2.843958874231255e-7, + "params": { + "nbar": 4.5 + } + }, + { + "pauli_probabilities": [ + 0.6845388961116873, + 4.523390056363137e-6, + 5.065303991950517e-6, + 0.3154515151942644 + ], + "duration": 2.4282146558931605e-7, + "params": { + "nbar": 5.0 + } + }, + { + "pauli_probabilities": [ + 0.6906830235783471, + 2.341717706531916e-6, + 2.6240239126921683e-6, + 0.30931201068003367 + ], + "duration": 2.2249911000356e-7, + "params": { + "nbar": 5.3 + } + }, + { + "pauli_probabilities": [ + 0.7001323835674031, + 7.863618683150052e-7, + 8.818627198655528e-7, + 0.2998659482080086 + ], + "duration": 1.943569576261009e-7, + "params": { + "nbar": 5.8 + } + }, + { + "pauli_probabilities": [ + 0.7103572139747492, + 2.1416805260162055e-7, + 2.4031644847985306e-7, + 0.2896423315407498 + ], + "duration": 1.67676469663927e-7, + "params": { + "nbar": 6.4 + } + }, + { + "pauli_probabilities": [ + 0.7210122459601656, + 4.746565500599967e-8, + 5.327534820610821e-8, + 0.2789876532988312 + ], + "duration": 1.435008783921373e-7, + "params": { + "nbar": 7.1 + } + } + ] + }, + { + "name": "rz", + "qubits": [ + [ + 0 + ] + ], + "free_params": [ + "nbar", + "angle" + ], + "fixed_params": { + "mem_kappa_1ph_MHz": 0.053, + "mem_kappa_2ph_MHz": 0.04, + "truncature": 40.0, + "num_time_steps": 1000.0 + }, + "interpolation_points": [ + { + "pauli_probabilities": [ + 0.4381173795925033, + 0.07753080095311407, + 0.07307580245004999, + 0.4112760170043326 + ], + "duration": 3.832026253831393e-6, + "params": { + "nbar": 0.8, + "angle": -3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.4615864548100308, + 0.06922037546120353, + 0.06461415519605858, + 0.40457901453270706 + ], + "duration": 3.448823628448254e-6, + "params": { + "nbar": 0.8, + "angle": -2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.49046665788521737, + 0.06024271054532168, + 0.05627427488448161, + 0.39301635668497936 + ], + "duration": 3.065621003065114e-6, + "params": { + "nbar": 0.8, + "angle": -2.5384068641005526 + } + }, + { + "pauli_probabilities": [ + 0.5253841346346299, + 0.05058125586307945, + 0.04821444000609397, + 0.37582016949619673 + ], + "duration": 2.6824183776819754e-6, + "params": { + "nbar": 0.8, + "angle": -2.2211060060879837 + } + }, + { + "pauli_probabilities": [ + 0.5668910155554028, + 0.04036293442684244, + 0.04053600118292519, + 0.35221004883482954 + ], + "duration": 2.2992157522988357e-6, + "params": { + "nbar": 0.8, + "angle": -1.9038051480754146 + } + }, + { + "pauli_probabilities": [ + 0.6154983039422495, + 0.029934469219298272, + 0.03323861730991693, + 0.32132860952853526 + ], + "duration": 1.9160131269156963e-6, + "params": { + "nbar": 0.8, + "angle": -1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.6717737080394597, + 0.019914842937543347, + 0.026201535280622006, + 0.282109913742375 + ], + "duration": 1.5328105015325574e-6, + "params": { + "nbar": 0.8, + "angle": -1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.7365336137144006, + 0.011170361320632103, + 0.019233563489747772, + 0.23306246147521953 + ], + "duration": 1.1496078761494176e-6, + "params": { + "nbar": 0.8, + "angle": -0.9519025740377072 + } + }, + { + "pauli_probabilities": [ + 0.8111489853521809, + 0.004642946426553796, + 0.012237126094248702, + 0.17197094212701658 + ], + "duration": 7.664052507662787e-7, + "params": { + "nbar": 0.8, + "angle": -0.6346017160251383 + } + }, + { + "pauli_probabilities": [ + 0.8979074340101302, + 0.000978891060277114, + 0.0054969154425001405, + 0.09561675948709253 + ], + "duration": 3.832026253831396e-7, + "params": { + "nbar": 0.8, + "angle": -0.31730085801256935 + } + }, + { + "pauli_probabilities": [ + 1.0, + 0.0, + 0.0, + 0.0 + ], + "duration": 0.0, + "params": { + "nbar": 0.8, + "angle": 0.0 + } + }, + { + "pauli_probabilities": [ + 0.8979074340082737, + 0.0009788910621344044, + 0.005496915440642618, + 0.09561675948894932 + ], + "duration": 3.8320262538313903e-7, + "params": { + "nbar": 0.8, + "angle": 0.3173008580125689 + } + }, + { + "pauli_probabilities": [ + 0.811148985366202, + 0.004642946371293522, + 0.012237126149508937, + 0.17197094211299557 + ], + "duration": 7.664052507662781e-7, + "params": { + "nbar": 0.8, + "angle": 0.6346017160251378 + } + }, + { + "pauli_probabilities": [ + 0.7365336137665168, + 0.011170361270064525, + 0.019233563540396632, + 0.23306246142302206 + ], + "duration": 1.1496078761494172e-6, + "params": { + "nbar": 0.8, + "angle": 0.9519025740377067 + } + }, + { + "pauli_probabilities": [ + 0.6717737081160575, + 0.019914842860945563, + 0.02620153535721979, + 0.2821099136657772 + ], + "duration": 1.5328105015325574e-6, + "params": { + "nbar": 0.8, + "angle": 1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.6154983039070885, + 0.02993446925445934, + 0.03323861727475586, + 0.32132860956369635 + ], + "duration": 1.9160131269156963e-6, + "params": { + "nbar": 0.8, + "angle": 1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.5668910154871944, + 0.040362934445540996, + 0.040536001146719056, + 0.3522100489205455 + ], + "duration": 2.2992157522988352e-6, + "params": { + "nbar": 0.8, + "angle": 1.9038051480754143 + } + }, + { + "pauli_probabilities": [ + 0.5253841346058811, + 0.0505812556704942, + 0.04821444023777748, + 0.37582016948584723 + ], + "duration": 2.6824183776819746e-6, + "params": { + "nbar": 0.8, + "angle": 2.2211060060879833 + } + }, + { + "pauli_probabilities": [ + 0.49046665823545954, + 0.06024271044437763, + 0.0562742749646239, + 0.39301635635553894 + ], + "duration": 3.0656210030651135e-6, + "params": { + "nbar": 0.8, + "angle": 2.538406864100552 + } + }, + { + "pauli_probabilities": [ + 0.461586455212887, + 0.06922037505834733, + 0.06461415559891479, + 0.40457901412985087 + ], + "duration": 3.448823628448254e-6, + "params": { + "nbar": 0.8, + "angle": 2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.43811738038984593, + 0.07753080015577155, + 0.07307580324739252, + 0.41127601620699006 + ], + "duration": 3.832026253831393e-6, + "params": { + "nbar": 0.8, + "angle": 3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.47813488671499793, + 0.04771213997375571, + 0.04629077932592166, + 0.42786219398532466 + ], + "duration": 2.741974782441875e-6, + "params": { + "nbar": 1.0, + "angle": -3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.5026065613056906, + 0.042102091940889506, + 0.039477918490894846, + 0.41581342826252504 + ], + "duration": 2.467777304197688e-6, + "params": { + "nbar": 1.0, + "angle": -2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.5320776379697323, + 0.03627714611960037, + 0.03290432895674299, + 0.3987408869539244 + ], + "duration": 2.1935798259535e-6, + "params": { + "nbar": 1.0, + "angle": -2.5384068641005526 + } + }, + { + "pauli_probabilities": [ + 0.5669098306495284, + 0.030159957949424818, + 0.02680855428355794, + 0.3761216571174889 + ], + "duration": 1.919382347709313e-6, + "params": { + "nbar": 1.0, + "angle": -2.2211060060879837 + } + }, + { + "pauli_probabilities": [ + 0.6074019411550111, + 0.02377997594637256, + 0.021372129259775857, + 0.3474459536388404 + ], + "duration": 1.645184869465125e-6, + "params": { + "nbar": 1.0, + "angle": -1.9038051480754146 + } + }, + { + "pauli_probabilities": [ + 0.6538447016371282, + 0.01734146731305972, + 0.016657033988017215, + 0.3121567970617949 + ], + "duration": 1.3709873912209375e-6, + "params": { + "nbar": 1.0, + "angle": -1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.7066208150453985, + 0.011255132263407493, + 0.01257332832139574, + 0.2695507243697982 + ], + "duration": 1.0967899129767502e-6, + "params": { + "nbar": 1.0, + "angle": -1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.7663532491747906, + 0.006088684056090414, + 0.008915765156750508, + 0.21864230161236847 + ], + "duration": 8.225924347325624e-7, + "params": { + "nbar": 1.0, + "angle": -0.9519025740377072 + } + }, + { + "pauli_probabilities": [ + 0.8340809771298914, + 0.0024009978119103673, + 0.00549730774305841, + 0.15802071731513978 + ], + "duration": 5.483949564883751e-7, + "params": { + "nbar": 1.0, + "angle": -0.6346017160251383 + } + }, + { + "pauli_probabilities": [ + 0.9113656769043024, + 0.0004679975619211916, + 0.0023649582060329723, + 0.08580136732774352 + ], + "duration": 2.7419747824418776e-7, + "params": { + "nbar": 1.0, + "angle": -0.31730085801256935 + } + }, + { + "pauli_probabilities": [ + 1.0, + 0.0, + 0.0, + 0.0 + ], + "duration": 0.0, + "params": { + "nbar": 1.0, + "angle": 0.0 + } + }, + { + "pauli_probabilities": [ + 0.9113656769010057, + 0.0004679975652172926, + 0.002364958202737185, + 0.08580136733103988 + ], + "duration": 2.7419747824418733e-7, + "params": { + "nbar": 1.0, + "angle": 0.3173008580125689 + } + }, + { + "pauli_probabilities": [ + 0.83408097712536, + 0.002400997816442969, + 0.00549730773852585, + 0.1580207173196712 + ], + "duration": 5.483949564883747e-7, + "params": { + "nbar": 1.0, + "angle": 0.6346017160251378 + } + }, + { + "pauli_probabilities": [ + 0.7663532491644778, + 0.006088684066403275, + 0.00891576514643757, + 0.21864230162268133 + ], + "duration": 8.225924347325621e-7, + "params": { + "nbar": 1.0, + "angle": 0.9519025740377067 + } + }, + { + "pauli_probabilities": [ + 0.7066208150453296, + 0.011255132263476459, + 0.012573328321326774, + 0.26955072436986716 + ], + "duration": 1.0967899129767502e-6, + "params": { + "nbar": 1.0, + "angle": 1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.6538447016424493, + 0.017341467307738594, + 0.01665703399333834, + 0.31215679705647376 + ], + "duration": 1.3709873912209375e-6, + "params": { + "nbar": 1.0, + "angle": 1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.6074019411521532, + 0.023779975949230543, + 0.021372129256917873, + 0.3474459536416984 + ], + "duration": 1.6451848694651248e-6, + "params": { + "nbar": 1.0, + "angle": 1.9038051480754143 + } + }, + { + "pauli_probabilities": [ + 0.5669098306691094, + 0.030159957947993095, + 0.026808554282366857, + 0.3761216571005307 + ], + "duration": 1.9193823477093124e-6, + "params": { + "nbar": 1.0, + "angle": 2.2211060060879833 + } + }, + { + "pauli_probabilities": [ + 0.5320776380186893, + 0.03627714607064327, + 0.03290432900570008, + 0.3987408869049673 + ], + "duration": 2.1935798259534995e-6, + "params": { + "nbar": 1.0, + "angle": 2.538406864100552 + } + }, + { + "pauli_probabilities": [ + 0.5026065614333124, + 0.042102091813267704, + 0.03947791861851665, + 0.4158134281349033 + ], + "duration": 2.467777304197688e-6, + "params": { + "nbar": 1.0, + "angle": 2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.47813488680438465, + 0.04771213988436904, + 0.046290779415308334, + 0.427862193895938 + ], + "duration": 2.741974782441875e-6, + "params": { + "nbar": 1.0, + "angle": 3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.5088746294715252, + 0.029273682248321102, + 0.029238589555682766, + 0.4326130987244709 + ], + "duration": 2.085890889519077e-6, + "params": { + "nbar": 1.2, + "angle": -3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.5333958010028949, + 0.025682885279822612, + 0.024088892868861414, + 0.4168324208484211 + ], + "duration": 1.8773018005671696e-6, + "params": { + "nbar": 1.2, + "angle": -2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.5624943190253373, + 0.022046939616551565, + 0.019247423426638825, + 0.3962113179314723 + ], + "duration": 1.6687127116152615e-6, + "params": { + "nbar": 1.2, + "angle": -2.5384068641005526 + } + }, + { + "pauli_probabilities": [ + 0.5964255922016677, + 0.01826281105467816, + 0.014939085836042358, + 0.3703725109076118 + ], + "duration": 1.4601236226633542e-6, + "params": { + "nbar": 1.2, + "angle": -2.2211060060879837 + } + }, + { + "pauli_probabilities": [ + 0.6354118072770283, + 0.014316307810500731, + 0.01132028324150129, + 0.3389516016709697 + ], + "duration": 1.2515345337114463e-6, + "params": { + "nbar": 1.2, + "angle": -1.9038051480754146 + } + }, + { + "pauli_probabilities": [ + 0.6796952168655305, + 0.010333534654973683, + 0.008424328482892788, + 0.30154691999660305 + ], + "duration": 1.0429454447595386e-6, + "params": { + "nbar": 1.2, + "angle": -1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.729616320245994, + 0.006593806218484001, + 0.006141027424150422, + 0.25764884611137157 + ], + "duration": 8.34356355807631e-7, + "params": { + "nbar": 1.2, + "angle": -1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.785708341461782, + 0.003474679355247356, + 0.0042582874621575496, + 0.2065586917208131 + ], + "duration": 6.25767266855723e-7, + "params": { + "nbar": 1.2, + "angle": -0.9519025740377072 + } + }, + { + "pauli_probabilities": [ + 0.8487773021763213, + 0.0013173744095745655, + 0.002576681855762655, + 0.14732864155834147 + ], + "duration": 4.171781779038155e-7, + "params": { + "nbar": 1.2, + "angle": -0.6346017160251383 + } + }, + { + "pauli_probabilities": [ + 0.9198828162485678, + 0.00024158724449898728, + 0.0010691124763669477, + 0.07880648403056623 + ], + "duration": 2.085890889519079e-7, + "params": { + "nbar": 1.2, + "angle": -0.31730085801256935 + } + }, + { + "pauli_probabilities": [ + 1.0, + 0.0, + 0.0, + 0.0 + ], + "duration": 0.0, + "params": { + "nbar": 1.2, + "angle": 0.0 + } + }, + { + "pauli_probabilities": [ + 0.9198828162464334, + 0.00024158724663385714, + 0.0010691124742320778, + 0.07880648403270063 + ], + "duration": 2.0858908895190758e-7, + "params": { + "nbar": 1.2, + "angle": 0.3173008580125689 + } + }, + { + "pauli_probabilities": [ + 0.8487773021752828, + 0.0013173744106129478, + 0.002576681854724155, + 0.14732864155938008 + ], + "duration": 4.1717817790381516e-7, + "params": { + "nbar": 1.2, + "angle": 0.6346017160251378 + } + }, + { + "pauli_probabilities": [ + 0.7857083414783097, + 0.003474679338719451, + 0.004258287478684864, + 0.20655869170428603 + ], + "duration": 6.257672668557228e-7, + "params": { + "nbar": 1.2, + "angle": 0.9519025740377067 + } + }, + { + "pauli_probabilities": [ + 0.7296163203038682, + 0.006593806160609733, + 0.0061410274820246896, + 0.2576488460534973 + ], + "duration": 8.34356355807631e-7, + "params": { + "nbar": 1.2, + "angle": 1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.6796952169965433, + 0.01033353452396093, + 0.008424328613905541, + 0.30154691986559023 + ], + "duration": 1.0429454447595386e-6, + "params": { + "nbar": 1.2, + "angle": 1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.6354118075158429, + 0.01431630759261535, + 0.011320283458633024, + 0.3389516014329087 + ], + "duration": 1.251534533711446e-6, + "params": { + "nbar": 1.2, + "angle": 1.9038051480754143 + } + }, + { + "pauli_probabilities": [ + 0.5964255924985808, + 0.018262810740640213, + 0.01493908615145307, + 0.3703725106093258 + ], + "duration": 1.4601236226633538e-6, + "params": { + "nbar": 1.2, + "angle": 2.2211060060879833 + } + }, + { + "pauli_probabilities": [ + 0.5624943193531786, + 0.02204693940176897, + 0.019247423638915715, + 0.3962113176061367 + ], + "duration": 1.6687127116152613e-6, + "params": { + "nbar": 1.2, + "angle": 2.538406864100552 + } + }, + { + "pauli_probabilities": [ + 0.533395801193464, + 0.025682885089253524, + 0.024088893059430502, + 0.41683242065785203 + ], + "duration": 1.8773018005671696e-6, + "params": { + "nbar": 1.2, + "angle": 2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.5088746297518969, + 0.029273681967949446, + 0.029238589836054422, + 0.43261309844409923 + ], + "duration": 2.085890889519077e-6, + "params": { + "nbar": 1.2, + "angle": 3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.5521465121327324, + 0.01105222443888005, + 0.011568561974331648, + 0.42523270145405595 + ], + "duration": 1.35482587488453e-6, + "params": { + "nbar": 1.6, + "angle": -3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.5760731720218089, + 0.009657198542336567, + 0.009001523468846504, + 0.405268105967008 + ], + "duration": 1.2193432873960772e-6, + "params": { + "nbar": 1.6, + "angle": -2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.6039603780843286, + 0.008286266742801312, + 0.006696211143646996, + 0.38105714402922314 + ], + "duration": 1.083860699907624e-6, + "params": { + "nbar": 1.6, + "angle": -2.5384068641005526 + } + }, + { + "pauli_probabilities": [ + 0.6360180614157327, + 0.006858685929174974, + 0.004775699943896446, + 0.3523475527111959 + ], + "duration": 9.483781124191712e-7, + "params": { + "nbar": 1.6, + "angle": -2.2211060060879837 + } + }, + { + "pauli_probabilities": [ + 0.6724513814140398, + 0.005349623804447463, + 0.003306230991121581, + 0.3188927637903912 + ], + "duration": 8.12895524930718e-7, + "params": { + "nbar": 1.6, + "angle": -1.9038051480754146 + } + }, + { + "pauli_probabilities": [ + 0.7134907344082895, + 0.0038129840654529843, + 0.002271770107168219, + 0.2804245114190893 + ], + "duration": 6.77412937442265e-7, + "params": { + "nbar": 1.6, + "angle": -1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.7594249319682751, + 0.0023776716076382813, + 0.0015745230263050653, + 0.23662287339778154 + ], + "duration": 5.419303499538121e-7, + "params": { + "nbar": 1.6, + "angle": -1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.8106261416558542, + 0.0012080241784097581, + 0.0010709120485550036, + 0.18709492211718104 + ], + "duration": 4.0644776246535897e-7, + "params": { + "nbar": 1.6, + "angle": -0.9519025740377072 + } + }, + { + "pauli_probabilities": [ + 0.8675427855555755, + 0.00043340439476154157, + 0.0006384778263837796, + 0.1313853322232792 + ], + "duration": 2.7096517497690603e-7, + "params": { + "nbar": 1.6, + "angle": -0.6346017160251383 + } + }, + { + "pauli_probabilities": [ + 0.9306125024669436, + 0.00007280191058985043, + 0.000248553282459962, + 0.06906614234000658 + ], + "duration": 1.3548258748845312e-7, + "params": { + "nbar": 1.6, + "angle": -0.31730085801256935 + } + }, + { + "pauli_probabilities": [ + 1.0, + 0.0, + 0.0, + 0.0 + ], + "duration": 0.0, + "params": { + "nbar": 1.6, + "angle": 0.0 + } + }, + { + "pauli_probabilities": [ + 0.9306125024657883, + 0.00007280191174526625, + 0.0002485532813041927, + 0.06906614234116226 + ], + "duration": 1.354825874884529e-7, + "params": { + "nbar": 1.6, + "angle": 0.3173008580125689 + } + }, + { + "pauli_probabilities": [ + 0.8675427855551294, + 0.0004334043952079008, + 0.0006384778259373026, + 0.13138533222372534 + ], + "duration": 2.709651749769058e-7, + "params": { + "nbar": 1.6, + "angle": 0.6346017160251378 + } + }, + { + "pauli_probabilities": [ + 0.8106261416550091, + 0.0012080241792543174, + 0.001070912047710446, + 0.18709492211802614 + ], + "duration": 4.064477624653588e-7, + "params": { + "nbar": 1.6, + "angle": 0.9519025740377067 + } + }, + { + "pauli_probabilities": [ + 0.7594249319692855, + 0.002377671606627856, + 0.0015745230273154906, + 0.23662287339677118 + ], + "duration": 5.419303499538121e-7, + "params": { + "nbar": 1.6, + "angle": 1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.7134907344109017, + 0.003812984062840713, + 0.0022717701097804905, + 0.28042451141647706 + ], + "duration": 6.77412937442265e-7, + "params": { + "nbar": 1.6, + "angle": 1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.6724513814174755, + 0.005349623801011761, + 0.003306230994556735, + 0.3188927637869559 + ], + "duration": 8.128955249307179e-7, + "params": { + "nbar": 1.6, + "angle": 1.9038051480754143 + } + }, + { + "pauli_probabilities": [ + 0.6360180614195718, + 0.00685868592533606, + 0.004775699947734731, + 0.3523475527073573 + ], + "duration": 9.48378112419171e-7, + "params": { + "nbar": 1.6, + "angle": 2.2211060060879833 + } + }, + { + "pauli_probabilities": [ + 0.6039603780955771, + 0.008286266745731252, + 0.006696211140716936, + 0.38105714401797475 + ], + "duration": 1.0838606999076237e-6, + "params": { + "nbar": 1.6, + "angle": 2.538406864100552 + } + }, + { + "pauli_probabilities": [ + 0.5760731720260135, + 0.009657198538131958, + 0.009001523473051113, + 0.40526810596280344 + ], + "duration": 1.2193432873960772e-6, + "params": { + "nbar": 1.6, + "angle": 2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.5521465121370357, + 0.011052224434576737, + 0.011568561978634961, + 0.42523270144975267 + ], + "duration": 1.35482587488453e-6, + "params": { + "nbar": 1.6, + "angle": 3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.5811907160079401, + 0.004224028069705012, + 0.004564023590433291, + 0.4100212323319215 + ], + "duration": 9.69434481253579e-7, + "params": { + "nbar": 2.0, + "angle": -3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.604703921117048, + 0.0036864819897084256, + 0.003410131585338581, + 0.38819946530790506 + ], + "duration": 8.724910331282213e-7, + "params": { + "nbar": 2.0, + "angle": -2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.6317667644467845, + 0.003167950480194995, + 0.0024076428205741544, + 0.36265764225244634 + ], + "duration": 7.755475850028631e-7, + "params": { + "nbar": 2.0, + "angle": -2.5384068641005526 + } + }, + { + "pauli_probabilities": [ + 0.662576583747502, + 0.0026241427102758337, + 0.0016097316777704553, + 0.3331895418644517 + ], + "duration": 6.786041368775054e-7, + "params": { + "nbar": 2.0, + "angle": -2.2211060060879837 + } + }, + { + "pauli_probabilities": [ + 0.697327034853904, + 0.002040675502374339, + 0.0010374355827411615, + 0.2995948540609804 + ], + "duration": 5.816606887521475e-7, + "params": { + "nbar": 2.0, + "angle": -1.9038051480754146 + } + }, + { + "pauli_probabilities": [ + 0.7362202190251412, + 0.0014417085543151267, + 0.0006703713192854066, + 0.2616677011012582 + ], + "duration": 4.847172406267895e-7, + "params": { + "nbar": 2.0, + "angle": -1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.779475627919429, + 0.000884546836305069, + 0.0004515417538019169, + 0.21918828349046393 + ], + "duration": 3.877737925014317e-7, + "params": { + "nbar": 2.0, + "angle": -1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.8273275013051463, + 0.00043820730421375594, + 0.0003083249501108787, + 0.17192596644052904 + ], + "duration": 2.908303443760737e-7, + "params": { + "nbar": 2.0, + "angle": -0.9519025740377072 + } + }, + { + "pauli_probabilities": [ + 0.8799956409440551, + 0.00015142321486619288, + 0.000184272219752468, + 0.11966866362132622 + ], + "duration": 1.9388689625071584e-7, + "params": { + "nbar": 2.0, + "angle": -0.6346017160251383 + } + }, + { + "pauli_probabilities": [ + 0.9376036453259989, + 0.000023958571924269374, + 0.0000679339457026367, + 0.06230446215637414 + ], + "duration": 9.6943448125358e-8, + "params": { + "nbar": 2.0, + "angle": -0.31730085801256935 + } + }, + { + "pauli_probabilities": [ + 1.0, + 0.0, + 0.0, + 0.0 + ], + "duration": 0.0, + "params": { + "nbar": 2.0, + "angle": 0.0 + } + }, + { + "pauli_probabilities": [ + 0.9376036453235459, + 0.000023958574377723582, + 0.00006793394324914324, + 0.062304462158827234 + ], + "duration": 9.694344812535784e-8, + "params": { + "nbar": 2.0, + "angle": 0.3173008580125689 + } + }, + { + "pauli_probabilities": [ + 0.8799956409421411, + 0.0001514232167800281, + 0.00018427221783886834, + 0.11966866362323997 + ], + "duration": 1.9388689625071568e-7, + "params": { + "nbar": 2.0, + "angle": 0.6346017160251378 + } + }, + { + "pauli_probabilities": [ + 0.8273275013011404, + 0.00043820730821998765, + 0.0003083249461046859, + 0.1719259664445349 + ], + "duration": 2.9083034437607357e-7, + "params": { + "nbar": 2.0, + "angle": 0.9519025740377067 + } + }, + { + "pauli_probabilities": [ + 0.7794756279147639, + 0.0008845468409702912, + 0.0004515417491366947, + 0.21918828349512914 + ], + "duration": 3.877737925014317e-7, + "params": { + "nbar": 2.0, + "angle": 1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.73622021901998, + 0.0014417085594764208, + 0.0006703713141241125, + 0.26166770110641946 + ], + "duration": 4.847172406267895e-7, + "params": { + "nbar": 2.0, + "angle": 1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.6973270348655309, + 0.0020406754907466894, + 0.001037435594367948, + 0.2995948540493544 + ], + "duration": 5.816606887521474e-7, + "params": { + "nbar": 2.0, + "angle": 1.9038051480754143 + } + }, + { + "pauli_probabilities": [ + 0.6625765837561297, + 0.002624142701647655, + 0.0016097316863994183, + 0.33318954185582317 + ], + "duration": 6.786041368775053e-7, + "params": { + "nbar": 2.0, + "angle": 2.2211060060879833 + } + }, + { + "pauli_probabilities": [ + 0.6317667644533931, + 0.0031679504734352074, + 0.002407642827333707, + 0.36265764224583796 + ], + "duration": 7.75547585002863e-7, + "params": { + "nbar": 2.0, + "angle": 2.538406864100552 + } + }, + { + "pauli_probabilities": [ + 0.6047039211222895, + 0.0036864819844667643, + 0.003410131590580242, + 0.3881994653026634 + ], + "duration": 8.724910331282213e-7, + "params": { + "nbar": 2.0, + "angle": 2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.581190716076556, + 0.004224028001089188, + 0.004564023659049115, + 0.41002123226330567 + ], + "duration": 9.69434481253579e-7, + "params": { + "nbar": 2.0, + "angle": 3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.6027310426894734, + 0.0016392957326653444, + 0.0018078686467547394, + 0.39382179293110653 + ], + "duration": 7.374737963970894e-7, + "params": { + "nbar": 2.4, + "angle": -3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.626090508550381, + 0.0014292162247712228, + 0.0013137371355896336, + 0.37116653808925826 + ], + "duration": 6.637264167573805e-7, + "params": { + "nbar": 2.4, + "angle": -2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.6526797292694906, + 0.001229378843492048, + 0.0008943688022007676, + 0.34519652308481663 + ], + "duration": 5.899790371176716e-7, + "params": { + "nbar": 2.4, + "angle": -2.5384068641005526 + } + }, + { + "pauli_probabilities": [ + 0.6826756137049563, + 0.0010184618460637215, + 0.0005710280745802744, + 0.31573489637439967 + ], + "duration": 5.162316574779627e-7, + "params": { + "nbar": 2.4, + "angle": -2.2211060060879837 + } + }, + { + "pauli_probabilities": [ + 0.7162468193210063, + 0.0007896718395778819, + 0.0003494087617782998, + 0.28261410007763743 + ], + "duration": 4.4248427783825364e-7, + "params": { + "nbar": 2.4, + "angle": -1.9038051480754146 + } + }, + { + "pauli_probabilities": [ + 0.7535563402952503, + 0.000553765334572711, + 0.00021654477228231356, + 0.24567334959789466 + ], + "duration": 3.687368981985447e-7, + "params": { + "nbar": 2.4, + "angle": -1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.7947595966825812, + 0.00033543906646196287, + 0.00014440517349040725, + 0.20476055907746638 + ], + "duration": 2.9498951855883583e-7, + "params": { + "nbar": 2.4, + "angle": -1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.8399922792243584, + 0.00016302154788002388, + 0.00010025477905214133, + 0.1597444444487095 + ], + "duration": 2.212421389191268e-7, + "params": { + "nbar": 2.4, + "angle": -0.9519025740377072 + } + }, + { + "pauli_probabilities": [ + 0.8893386503891023, + 0.00005478700139158546, + 0.000060467732977627516, + 0.1105460948765285 + ], + "duration": 1.4749475927941792e-7, + "params": { + "nbar": 2.4, + "angle": -0.6346017160251383 + } + }, + { + "pauli_probabilities": [ + 0.9427656181138289, + 8.296626453363229e-6, + 0.000021389113664681747, + 0.05720469614605311 + ], + "duration": 7.374737963970901e-8, + "params": { + "nbar": 2.4, + "angle": -0.31730085801256935 + } + }, + { + "pauli_probabilities": [ + 1.0, + 0.0, + 0.0, + 0.0 + ], + "duration": 0.0, + "params": { + "nbar": 2.4, + "angle": 0.0 + } + }, + { + "pauli_probabilities": [ + 0.9427656181120011, + 8.296628281372271e-6, + 0.000021389111836476462, + 0.057204696147881096 + ], + "duration": 7.374737963970889e-8, + "params": { + "nbar": 2.4, + "angle": 0.3173008580125689 + } + }, + { + "pauli_probabilities": [ + 0.889338650387334, + 0.00005478700316054164, + 0.000060467731208592836, + 0.11054609487829697 + ], + "duration": 1.4749475927941778e-7, + "params": { + "nbar": 2.4, + "angle": 0.6346017160251378 + } + }, + { + "pauli_probabilities": [ + 0.8399922792222952, + 0.00016302154994333353, + 0.0001002547769885963, + 0.15974444445077285 + ], + "duration": 2.2124213891912672e-7, + "params": { + "nbar": 2.4, + "angle": 0.9519025740377067 + } + }, + { + "pauli_probabilities": [ + 0.7947595966792903, + 0.00033543906975285983, + 0.00014440517019951029, + 0.2047605590807573 + ], + "duration": 2.9498951855883583e-7, + "params": { + "nbar": 2.4, + "angle": 1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.7535563403006708, + 0.0005537653291523181, + 0.00021654477770270643, + 0.24567334959247422 + ], + "duration": 3.687368981985447e-7, + "params": { + "nbar": 2.4, + "angle": 1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.7162468193246192, + 0.0007896718359667286, + 0.00034940876538906056, + 0.282614100074025 + ], + "duration": 4.424842778382536e-7, + "params": { + "nbar": 2.4, + "angle": 1.9038051480754143 + } + }, + { + "pauli_probabilities": [ + 0.6826756137070178, + 0.0010184618440022663, + 0.0005710280766412976, + 0.3157348963723386 + ], + "duration": 5.162316574779626e-7, + "params": { + "nbar": 2.4, + "angle": 2.2211060060879833 + } + }, + { + "pauli_probabilities": [ + 0.6526797292710813, + 0.001229378841901138, + 0.0008943688037917957, + 0.3451965230832258 + ], + "duration": 5.899790371176715e-7, + "params": { + "nbar": 2.4, + "angle": 2.538406864100552 + } + }, + { + "pauli_probabilities": [ + 0.6260905085519031, + 0.0014292162232490775, + 0.001313737137111779, + 0.37116653808773603 + ], + "duration": 6.637264167573805e-7, + "params": { + "nbar": 2.4, + "angle": 2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.6027310426910162, + 0.00163929573112254, + 0.001807868648297544, + 0.39382179292956376 + ], + "duration": 7.374737963970894e-7, + "params": { + "nbar": 2.4, + "angle": 3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.6117795838014803, + 0.0010269362700973525, + 0.0011407370591144201, + 0.3860527428693079 + ], + "duration": 6.540386815201549e-7, + "params": { + "nbar": 2.6, + "angle": -3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.635108468146407, + 0.0008948064519048784, + 0.0008202981392615227, + 0.36317642726242655 + ], + "duration": 5.886348133681395e-7, + "params": { + "nbar": 2.6, + "angle": -2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.6615270341080101, + 0.0007698557695321635, + 0.0005508100142983044, + 0.3371523001081595 + ], + "duration": 5.232309452161239e-7, + "params": { + "nbar": 2.6, + "angle": -2.5384068641005526 + } + }, + { + "pauli_probabilities": [ + 0.6912001387050494, + 0.0006376459560139521, + 0.0003455825817307947, + 0.3078166327572059 + ], + "duration": 4.578270770641085e-7, + "params": { + "nbar": 2.6, + "angle": -2.2211060060879837 + } + }, + { + "pauli_probabilities": [ + 0.7242822075288654, + 0.0004936525180610409, + 0.00020739024134227186, + 0.2750167497117313 + ], + "duration": 3.924232089120929e-7, + "params": { + "nbar": 2.6, + "angle": -1.9038051480754146 + } + }, + { + "pauli_probabilities": [ + 0.7609170382833909, + 0.0003450169570775244, + 0.00012672403108319663, + 0.23861122072844843 + ], + "duration": 3.2701934076007746e-7, + "params": { + "nbar": 2.6, + "angle": -1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.8012330899750644, + 0.00020783960779274972, + 0.00008453551770415594, + 0.19847453489943873 + ], + "duration": 2.61615472608062e-7, + "params": { + "nbar": 2.6, + "angle": -1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.8453295266630465, + 0.00010019670847371123, + 0.00005929220065118802, + 0.15451098442782862 + ], + "duration": 1.9621160445604643e-7, + "params": { + "nbar": 2.6, + "angle": -0.9519025740377072 + } + }, + { + "pauli_probabilities": [ + 0.8932456383131238, + 0.00003328729444467616, + 0.00003593874347799949, + 0.10668513564895354 + ], + "duration": 1.30807736304031e-7, + "params": { + "nbar": 2.6, + "angle": -0.6346017160251383 + } + }, + { + "pauli_probabilities": [ + 0.9449024435986072, + 4.9507397887474174e-6, + 0.000012518461809734297, + 0.05508008719979435 + ], + "duration": 6.540386815201555e-8, + "params": { + "nbar": 2.6, + "angle": -0.31730085801256935 + } + }, + { + "pauli_probabilities": [ + 1.0, + 0.0, + 0.0, + 0.0 + ], + "duration": 0.0, + "params": { + "nbar": 2.6, + "angle": 0.0 + } + }, + { + "pauli_probabilities": [ + 0.9449024435969238, + 4.950741472033334e-6, + 0.000012518460126683924, + 0.0550800872014775 + ], + "duration": 6.540386815201545e-8, + "params": { + "nbar": 2.6, + "angle": 0.3173008580125689 + } + }, + { + "pauli_probabilities": [ + 0.8932456383111991, + 0.00003328729636930991, + 0.000035938741553208765, + 0.1066851356508784 + ], + "duration": 1.308077363040309e-7, + "params": { + "nbar": 2.6, + "angle": 0.6346017160251378 + } + }, + { + "pauli_probabilities": [ + 0.8453295266612684, + 0.00010019671025157336, + 0.000059292198873247366, + 0.15451098442960676 + ], + "duration": 1.9621160445604635e-7, + "params": { + "nbar": 2.6, + "angle": 0.9519025740377067 + } + }, + { + "pauli_probabilities": [ + 0.8012330899713979, + 0.00020783961145922884, + 0.00008453551403767682, + 0.19847453490310524 + ], + "duration": 2.61615472608062e-7, + "params": { + "nbar": 2.6, + "angle": 1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.7609170382766139, + 0.0003450169638544808, + 0.00012672402430624025, + 0.23861122073522534 + ], + "duration": 3.2701934076007746e-7, + "params": { + "nbar": 2.6, + "angle": 1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.7242822075204736, + 0.0004936525264552259, + 0.0002073902329479295, + 0.27501674972012324 + ], + "duration": 3.9242320891209287e-7, + "params": { + "nbar": 2.6, + "angle": 1.9038051480754143 + } + }, + { + "pauli_probabilities": [ + 0.6912001387019784, + 0.0006376459590853596, + 0.00034558257865942624, + 0.30781663276027676 + ], + "duration": 4.578270770641084e-7, + "params": { + "nbar": 2.6, + "angle": 2.2211060060879833 + } + }, + { + "pauli_probabilities": [ + 0.6615270341035662, + 0.0007698557739761546, + 0.0005508100098543131, + 0.33715230011260344 + ], + "duration": 5.232309452161238e-7, + "params": { + "nbar": 2.6, + "angle": 2.538406864100552 + } + }, + { + "pauli_probabilities": [ + 0.6351084681582594, + 0.0008948064400525051, + 0.0008202981511138959, + 0.3631764272505742 + ], + "duration": 5.886348133681395e-7, + "params": { + "nbar": 2.6, + "angle": 2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.61177958382491, + 0.0010269362466676169, + 0.0011407370825441557, + 0.3860527428458782 + ], + "duration": 6.540386815201549e-7, + "params": { + "nbar": 2.6, + "angle": 3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.6346014478044808, + 0.0002574135104906801, + 0.0002899652252199763, + 0.36485117345980855 + ], + "duration": 4.790032817289241e-7, + "params": { + "nbar": 3.2, + "angle": -3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.6578659480341367, + 0.00022390250691551263, + 0.00020383556453345568, + 0.3417063138944143 + ], + "duration": 4.3110295355603177e-7, + "params": { + "nbar": 3.2, + "angle": -2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.6838574214893313, + 0.00019264994240878686, + 0.0001328759500777779, + 0.31581705261818216 + ], + "duration": 3.8320262538313924e-7, + "params": { + "nbar": 3.2, + "angle": -2.5384068641005526 + } + }, + { + "pauli_probabilities": [ + 0.7127046954545122, + 0.00015938476959376354, + 0.00008033221084106142, + 0.2870555875650529 + ], + "duration": 3.3530229721024693e-7, + "params": { + "nbar": 3.2, + "angle": -2.2211060060879837 + } + }, + { + "pauli_probabilities": [ + 0.7445216182583874, + 0.00012284548116266977, + 0.00004635276848964366, + 0.2553091834919603 + ], + "duration": 2.8740196903735446e-7, + "params": { + "nbar": 3.2, + "angle": -1.9038051480754146 + } + }, + { + "pauli_probabilities": [ + 0.7794026961917857, + 0.00008509648780136186, + 0.000027694167677315754, + 0.2204845131527356 + ], + "duration": 2.3950164086446204e-7, + "params": { + "nbar": 3.2, + "angle": -1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.8174149186906144, + 0.00005054754811088793, + 0.000018727586457344688, + 0.18251580617481733 + ], + "duration": 1.9160131269156967e-7, + "params": { + "nbar": 3.2, + "angle": -1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.8585831055373097, + 0.000023884207222281794, + 0.000013537337936415524, + 0.1413794729175316 + ], + "duration": 1.437009845186772e-7, + "params": { + "nbar": 3.2, + "angle": -0.9519025740377072 + } + }, + { + "pauli_probabilities": [ + 0.9028649749204003, + 7.713360082211104e-6, + 8.305768095632571e-6, + 0.09711900595142187 + ], + "duration": 9.580065634578484e-8, + "params": { + "nbar": 3.2, + "angle": -0.6346017160251383 + } + }, + { + "pauli_probabilities": [ + 0.9501106943270032, + 1.0977561619891977e-6, + 2.8088747830982245e-6, + 0.04988539904205164 + ], + "duration": 4.790032817289245e-8, + "params": { + "nbar": 3.2, + "angle": -0.31730085801256935 + } + }, + { + "pauli_probabilities": [ + 1.0, + 0.0, + 0.0, + 0.0 + ], + "duration": 0.0, + "params": { + "nbar": 3.2, + "angle": 0.0 + } + }, + { + "pauli_probabilities": [ + 0.9501106943264387, + 1.0977567263466845e-6, + 2.8088742189370054e-6, + 0.04988539904261602 + ], + "duration": 4.790032817289238e-8, + "params": { + "nbar": 3.2, + "angle": 0.3173008580125689 + } + }, + { + "pauli_probabilities": [ + 0.9028649749198215, + 7.713360660849952e-6, + 8.305767516993723e-6, + 0.09711900595200057 + ], + "duration": 9.580065634578476e-8, + "params": { + "nbar": 3.2, + "angle": 0.6346017160251378 + } + }, + { + "pauli_probabilities": [ + 0.8585831055363127, + 0.00002388420821938179, + 0.000013537336939315522, + 0.14137947291852865 + ], + "duration": 1.4370098451867715e-7, + "params": { + "nbar": 3.2, + "angle": 0.9519025740377067 + } + }, + { + "pauli_probabilities": [ + 0.8174149186900503, + 0.000050547548674925246, + 0.000018727585893307373, + 0.18251580617538143 + ], + "duration": 1.9160131269156967e-7, + "params": { + "nbar": 3.2, + "angle": 1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.7794026961907781, + 0.00008509648880908522, + 0.00002769416666959239, + 0.2204845131537433 + ], + "duration": 2.3950164086446204e-7, + "params": { + "nbar": 3.2, + "angle": 1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.744521618256789, + 0.00012284548276141478, + 0.00004635276689105564, + 0.2553091834935586 + ], + "duration": 2.874019690373544e-7, + "params": { + "nbar": 3.2, + "angle": 1.9038051480754143 + } + }, + { + "pauli_probabilities": [ + 0.7127046954524205, + 0.00015938477168561465, + 0.00008033220874889633, + 0.287055587567145 + ], + "duration": 3.353022972102468e-7, + "params": { + "nbar": 3.2, + "angle": 2.2211060060879833 + } + }, + { + "pauli_probabilities": [ + 0.6838574214872649, + 0.0001926499444759781, + 0.0001328759480105081, + 0.3158170526202486 + ], + "duration": 3.832026253831392e-7, + "params": { + "nbar": 3.2, + "angle": 2.538406864100552 + } + }, + { + "pauli_probabilities": [ + 0.6578659480322866, + 0.0002239025087655771, + 0.0002038355626833912, + 0.3417063138962644 + ], + "duration": 4.3110295355603177e-7, + "params": { + "nbar": 3.2, + "angle": 2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.6346014478027402, + 0.00025741351223121763, + 0.0002899652234794388, + 0.36485117346154916 + ], + "duration": 4.790032817289241e-7, + "params": { + "nbar": 3.2, + "angle": 3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.6442860605625352, + 0.00013008731194901645, + 0.00014716121161657787, + 0.3554366909138992 + ], + "duration": 4.1875633465598013e-7, + "params": { + "nbar": 3.5, + "angle": -3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.6674995162322723, + 0.00011307543416151751, + 0.00010261437256648568, + 0.33228479396099964 + ], + "duration": 3.7688070119038217e-7, + "params": { + "nbar": 3.5, + "angle": -2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.6932854309587348, + 0.00009728856050790302, + 0.00006619468938164894, + 0.3065510857913756 + ], + "duration": 3.3500506772478405e-7, + "params": { + "nbar": 3.5, + "angle": -2.5384068641005526 + } + }, + { + "pauli_probabilities": [ + 0.7217564359375825, + 0.00008043862098543894, + 0.000039512065472609793, + 0.2781236133759595 + ], + "duration": 2.9312943425918614e-7, + "params": { + "nbar": 3.5, + "angle": -2.2211060060879837 + } + }, + { + "pauli_probabilities": [ + 0.7530088890138271, + 0.00006187166385101335, + 0.00002252079459870649, + 0.24690671852772317 + ], + "duration": 2.512538007935881e-7, + "params": { + "nbar": 3.5, + "angle": -1.9038051480754146 + } + }, + { + "pauli_probabilities": [ + 0.7871177309755685, + 0.000042694504480334346, + 0.000013405896131198596, + 0.21282616862381998 + ], + "duration": 2.0937816732799006e-7, + "params": { + "nbar": 3.5, + "angle": -1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.8241279824378628, + 0.00002521154366355605, + 9.160189113136077e-6, + 0.1758376458293605 + ], + "duration": 1.6750253386239208e-7, + "params": { + "nbar": 3.5, + "angle": -1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.8640408605390744, + 0.000011814387654295793, + 6.7088595253686405e-6, + 0.13594061621374592 + ], + "duration": 1.25626900396794e-7, + "params": { + "nbar": 3.5, + "angle": -0.9519025740377072 + } + }, + { + "pauli_probabilities": [ + 0.9067917376707999, + 3.771440237243213e-6, + 4.133625626201664e-6, + 0.09320035726333664 + ], + "duration": 8.375126693119604e-8, + "params": { + "nbar": 3.5, + "angle": -0.6346017160251383 + } + }, + { + "pauli_probabilities": [ + 0.9522162623920513, + 5.271505431252953e-7, + 1.386030813812534e-6, + 0.047781824426591846 + ], + "duration": 4.187563346559805e-8, + "params": { + "nbar": 3.5, + "angle": -0.31730085801256935 + } + }, + { + "pauli_probabilities": [ + 1.0, + 0.0, + 0.0, + 0.0 + ], + "duration": 0.0, + "params": { + "nbar": 3.5, + "angle": 0.0 + } + }, + { + "pauli_probabilities": [ + 0.9522162623921471, + 5.271504473487355e-7, + 1.386030909353578e-6, + 0.047781824426496255 + ], + "duration": 4.1875633465597986e-8, + "params": { + "nbar": 3.5, + "angle": 0.3173008580125689 + } + }, + { + "pauli_probabilities": [ + 0.9067917376711963, + 3.7714398410256634e-6, + 4.1336260224192155e-6, + 0.09320035726294035 + ], + "duration": 8.375126693119597e-8, + "params": { + "nbar": 3.5, + "angle": 0.6346017160251378 + } + }, + { + "pauli_probabilities": [ + 0.8640408605403608, + 0.000011814386367911764, + 6.708860811988182e-6, + 0.13594061621245934 + ], + "duration": 1.2562690039679396e-7, + "params": { + "nbar": 3.5, + "angle": 0.9519025740377067 + } + }, + { + "pauli_probabilities": [ + 0.8241279824405275, + 0.000025211540998803776, + 9.160191777888353e-6, + 0.17583764582669575 + ], + "duration": 1.6750253386239208e-7, + "params": { + "nbar": 3.5, + "angle": 1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.7871177309821497, + 0.00004269449789915582, + 0.000013405902712377123, + 0.2128261686172388 + ], + "duration": 2.0937816732799006e-7, + "params": { + "nbar": 3.5, + "angle": 1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.7530088890230954, + 0.00006187165458306705, + 0.00002252080386649579, + 0.24690671851845508 + ], + "duration": 2.51253800793588e-7, + "params": { + "nbar": 3.5, + "angle": 1.9038051480754143 + } + }, + { + "pauli_probabilities": [ + 0.7217564359483726, + 0.00008043861019621303, + 0.00003951207626171795, + 0.2781236133651695 + ], + "duration": 2.9312943425918604e-7, + "params": { + "nbar": 3.5, + "angle": 2.2211060060879833 + } + }, + { + "pauli_probabilities": [ + 0.6932854309601759, + 0.00009728854014124673, + 0.00006619470974830521, + 0.3065510857899345 + ], + "duration": 3.35005067724784e-7, + "params": { + "nbar": 3.5, + "angle": 2.538406864100552 + } + }, + { + "pauli_probabilities": [ + 0.6674995162441312, + 0.00011307542230271624, + 0.00010261438442528695, + 0.33228479394914084 + ], + "duration": 3.7688070119038217e-7, + "params": { + "nbar": 3.5, + "angle": 2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.6442860605740606, + 0.00013008730042369902, + 0.0001471612231418953, + 0.35543669090237384 + ], + "duration": 4.1875633465598013e-7, + "params": { + "nbar": 3.5, + "angle": 3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.65862231418785, + 0.0000421854018791075, + 0.000047953644350176615, + 0.3412875467659207 + ], + "duration": 3.427468478052344e-7, + "params": { + "nbar": 4.0, + "angle": -3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.6817065438176195, + 0.000036644640141381306, + 0.00003308197653582118, + 0.3182237295657032 + ], + "duration": 3.08472163024711e-7, + "params": { + "nbar": 4.0, + "angle": -2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.7071379040574707, + 0.00003153159880248693, + 0.000021049299347173173, + 0.2928095150443797 + ], + "duration": 2.741974782441875e-7, + "params": { + "nbar": 4.0, + "angle": -2.5384068641005526 + } + }, + { + "pauli_probabilities": [ + 0.7350056276429959, + 0.000026046466665861825, + 0.000012361640657985605, + 0.26495596424968015 + ], + "duration": 2.399227934636641e-7, + "params": { + "nbar": 4.0, + "angle": -2.2211060060879837 + } + }, + { + "pauli_probabilities": [ + 0.7653815083456287, + 0.000019973749458734066, + 6.9465782061936966e-6, + 0.23459157132670638 + ], + "duration": 2.0564810868314063e-7, + "params": { + "nbar": 4.0, + "angle": -1.9038051480754146 + } + }, + { + "pauli_probabilities": [ + 0.7983143509670291, + 0.000013705236417462022, + 4.134489570926894e-6, + 0.20166780930698253 + ], + "duration": 1.713734239026172e-7, + "params": { + "nbar": 4.0, + "angle": -1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.8338217576839722, + 8.024156376314251e-6, + 2.8784347063645483e-6, + 0.16616733972494518 + ], + "duration": 1.3709873912209377e-7, + "params": { + "nbar": 4.0, + "angle": -1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.8718779564969736, + 3.7155750494273888e-6, + 2.147450659891639e-6, + 0.12811618047731704 + ], + "duration": 1.028240543415703e-7, + "params": { + "nbar": 4.0, + "angle": -0.9519025740377072 + } + }, + { + "pauli_probabilities": [ + 0.9123959833266442, + 1.16648096853106e-6, + 1.3296453442101488e-6, + 0.08760152054704312 + ], + "duration": 6.854936956104689e-8, + "params": { + "nbar": 4.0, + "angle": -0.6346017160251383 + } + }, + { + "pauli_probabilities": [ + 0.9552021060876578, + 1.5886045885653136e-7, + 4.4163937155751023e-7, + 0.04479729341251182 + ], + "duration": 3.427468478052347e-8, + "params": { + "nbar": 4.0, + "angle": -0.31730085801256935 + } + }, + { + "pauli_probabilities": [ + 1.0, + 0.0, + 0.0, + 0.0 + ], + "duration": 0.0, + "params": { + "nbar": 4.0, + "angle": 0.0 + } + }, + { + "pauli_probabilities": [ + 0.9552021060874025, + 1.588607140985547e-7, + 4.416391162762354e-7, + 0.044797293412767114 + ], + "duration": 3.427468478052342e-8, + "params": { + "nbar": 4.0, + "angle": 0.3173008580125689 + } + }, + { + "pauli_probabilities": [ + 0.9123959833268875, + 1.1664807253871322e-6, + 1.3296455873933319e-6, + 0.0876015205467997 + ], + "duration": 6.854936956104683e-8, + "params": { + "nbar": 4.0, + "angle": 0.6346017160251378 + } + }, + { + "pauli_probabilities": [ + 0.871877956497473, + 3.715574550048645e-6, + 2.147451159270382e-6, + 0.1281161804768176 + ], + "duration": 1.0282405434157026e-7, + "params": { + "nbar": 4.0, + "angle": 0.9519025740377067 + } + }, + { + "pauli_probabilities": [ + 0.8338217576842706, + 8.0241560777992e-6, + 2.8784350048795994e-6, + 0.1661673397246467 + ], + "duration": 1.3709873912209377e-7, + "params": { + "nbar": 4.0, + "angle": 1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.7983143509678308, + 0.000013705235615796057, + 4.134490372592858e-6, + 0.20166780930618083 + ], + "duration": 1.713734239026172e-7, + "params": { + "nbar": 4.0, + "angle": 1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.7653815083461672, + 0.00001997374892011705, + 6.946578744810713e-6, + 0.2345915713261678 + ], + "duration": 2.056481086831406e-7, + "params": { + "nbar": 4.0, + "angle": 1.9038051480754143 + } + }, + { + "pauli_probabilities": [ + 0.7350056276434818, + 0.000026046466182607126, + 0.000012361641141318827, + 0.26495596424919426 + ], + "duration": 2.3992279346366405e-7, + "params": { + "nbar": 4.0, + "angle": 2.2211060060879833 + } + }, + { + "pauli_probabilities": [ + 0.7071379040577388, + 0.00003153159853427754, + 0.00002104929961538256, + 0.2928095150441115 + ], + "duration": 2.7419747824418744e-7, + "params": { + "nbar": 4.0, + "angle": 2.538406864100552 + } + }, + { + "pauli_probabilities": [ + 0.6817065438177654, + 0.000036644639995543754, + 0.00003308197668165873, + 0.31822372956555733 + ], + "duration": 3.08472163024711e-7, + "params": { + "nbar": 4.0, + "angle": 2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.6586223141880649, + 0.00004218540166411094, + 0.000047953644565173174, + 0.3412875467657057 + ], + "duration": 3.427468478052344e-7, + "params": { + "nbar": 4.0, + "angle": 3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.671194892228491, + 0.000013844365288869758, + 0.000015787345191688642, + 0.3287754760610284 + ], + "duration": 2.8723984629735673e-7, + "params": { + "nbar": 4.5, + "angle": -3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.6941011308960607, + 0.000012025430139962591, + 0.000010799783281739584, + 0.3058760438905175 + ], + "duration": 2.5851586166762113e-7, + "params": { + "nbar": 4.5, + "angle": -2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.7191623701512777, + 0.000010351517225101127, + 6.797835779744972e-6, + 0.2808204804957174 + ], + "duration": 2.2979187703788538e-7, + "params": { + "nbar": 4.5, + "angle": -2.5384068641005526 + } + }, + { + "pauli_probabilities": [ + 0.7464486881903492, + 8.545038132854415e-6, + 3.942891351623818e-6, + 0.25353882388016635 + ], + "duration": 2.0106789240814975e-7, + "params": { + "nbar": 4.5, + "angle": -2.2211060060879837 + } + }, + { + "pauli_probabilities": [ + 0.7760123936163884, + 6.53587727468402e-6, + 2.1948112667308494e-6, + 0.2239788756950702 + ], + "duration": 1.7234390777841405e-7, + "params": { + "nbar": 4.5, + "angle": -1.9038051480754146 + } + }, + { + "pauli_probabilities": [ + 0.8078826283789636, + 4.463047520990558e-6, + 1.3114065607526726e-6, + 0.19211159716695464 + ], + "duration": 1.4361992314867837e-7, + "params": { + "nbar": 4.5, + "angle": -1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.8420578794134623, + 2.59407436092338e-6, + 9.300361902317054e-7, + 0.15793859647598646 + ], + "duration": 1.1489593851894271e-7, + "params": { + "nbar": 4.5, + "angle": -1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.8784955522893122, + 1.1890787600752167e-6, + 7.043215420089547e-7, + 0.12150255431038576 + ], + "duration": 8.617195388920701e-8, + "params": { + "nbar": 4.5, + "angle": -0.9519025740377072 + } + }, + { + "pauli_probabilities": [ + 0.9170975516415394, + 3.6805582489714905e-7, + 4.374523546613093e-7, + 0.08290164285028107 + ], + "duration": 5.744796925947136e-8, + "params": { + "nbar": 4.5, + "angle": -0.6346017160251383 + } + }, + { + "pauli_probabilities": [ + 0.9576906137719269, + 4.902878216251967e-8, + 1.443846163052435e-7, + 0.04230919281467466 + ], + "duration": 2.8723984629735702e-8, + "params": { + "nbar": 4.5, + "angle": -0.31730085801256935 + } + }, + { + "pauli_probabilities": [ + 1.0, + 0.0, + 0.0, + 0.0 + ], + "duration": 0.0, + "params": { + "nbar": 4.5, + "angle": 0.0 + } + }, + { + "pauli_probabilities": [ + 0.957690613771501, + 4.9029207868966487e-8, + 1.4438419067730055e-7, + 0.04230919281510048 + ], + "duration": 2.8723984629735655e-8, + "params": { + "nbar": 4.5, + "angle": 0.3173008580125689 + } + }, + { + "pauli_probabilities": [ + 0.9170975516413169, + 3.680560472206972e-7, + 4.3745213265178174e-7, + 0.08290164285050328 + ], + "duration": 5.744796925947131e-8, + "params": { + "nbar": 4.5, + "angle": 0.6346017160251378 + } + }, + { + "pauli_probabilities": [ + 0.8784955522893784, + 1.1890786945684787e-6, + 7.043216072801801e-7, + 0.12150255431031975 + ], + "duration": 8.617195388920698e-8, + "params": { + "nbar": 4.5, + "angle": 0.9519025740377067 + } + }, + { + "pauli_probabilities": [ + 0.8420578794136324, + 2.594074190859864e-6, + 9.300363602952214e-7, + 0.15793859647581637 + ], + "duration": 1.1489593851894271e-7, + "params": { + "nbar": 4.5, + "angle": 1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.8078826283735987, + 4.463052885972685e-6, + 1.311401195770546e-6, + 0.19211159717231957 + ], + "duration": 1.4361992314867837e-7, + "params": { + "nbar": 4.5, + "angle": 1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.776012393602914, + 6.535890748404294e-6, + 2.1947977928928237e-6, + 0.2239788757085448 + ], + "duration": 1.7234390777841402e-7, + "params": { + "nbar": 4.5, + "angle": 1.9038051480754143 + } + }, + { + "pauli_probabilities": [ + 0.7464486881762757, + 8.54505220635466e-6, + 3.94287727816282e-6, + 0.25353882389423976 + ], + "duration": 2.010678924081497e-7, + "params": { + "nbar": 4.5, + "angle": 2.2211060060879833 + } + }, + { + "pauli_probabilities": [ + 0.7191623701297187, + 0.00001035153878501231, + 6.797814219951557e-6, + 0.28082048051727626 + ], + "duration": 2.2979187703788535e-7, + "params": { + "nbar": 4.5, + "angle": 2.538406864100552 + } + }, + { + "pauli_probabilities": [ + 0.6941011308725953, + 0.000012025453605382947, + 0.000010799759816319228, + 0.30587604391398293 + ], + "duration": 2.5851586166762113e-7, + "params": { + "nbar": 4.5, + "angle": 2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.6711948922043707, + 0.000013844389409276216, + 0.000015787321071282184, + 0.3287754760851488 + ], + "duration": 2.8723984629735673e-7, + "params": { + "nbar": 4.5, + "angle": 3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.6823790307021245, + 4.588926524758751e-6, + 5.244487883647676e-6, + 0.31761113588346707 + ], + "duration": 2.4524968024520916e-7, + "params": { + "nbar": 5.0, + "angle": -3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.7050713648965011, + 3.987897188478967e-6, + 3.5626162675814574e-6, + 0.2949210845900428 + ], + "duration": 2.2072471222068827e-7, + "params": { + "nbar": 5.0, + "angle": -2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.7297531908656177, + 3.435059560085341e-6, + 2.222427950015274e-6, + 0.2702411516468722 + ], + "duration": 1.9619974419616732e-7, + "params": { + "nbar": 5.0, + "angle": -2.5384068641005526 + } + }, + { + "pauli_probabilities": [ + 0.7564790418563041, + 2.8343643448543477e-6, + 1.2760871195185162e-6, + 0.24351684769223148 + ], + "duration": 1.7167477617164645e-7, + "params": { + "nbar": 5.0, + "angle": -2.2211060060879837 + } + }, + { + "pauli_probabilities": [ + 0.7852858664261039, + 2.163190724536241e-6, + 7.055105674968172e-7, + 0.2147112648726041 + ], + "duration": 1.471498081471255e-7, + "params": { + "nbar": 5.0, + "angle": -1.9038051480754146 + } + }, + { + "pauli_probabilities": [ + 0.8161880148889158, + 1.4709858691370765e-6, + 4.2397974836022056e-7, + 0.18381009014546668 + ], + "duration": 1.2262484012260458e-7, + "params": { + "nbar": 5.0, + "angle": -1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.8491705838363188, + 8.496248050450956e-7, + 3.059640318690251e-7, + 0.15082826057484428 + ], + "duration": 9.809987209808369e-8, + "params": { + "nbar": 5.0, + "angle": -1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.8841805543889252, + 3.860643856983315e-7, + 2.3459264610941384e-7, + 0.11581882495404305 + ], + "duration": 7.357490407356274e-8, + "params": { + "nbar": 5.0, + "angle": -0.9519025740377072 + } + }, + { + "pauli_probabilities": [ + 0.9211150485613788, + 1.1804448463398844e-7, + 1.459978354345328e-7, + 0.07888468739630111 + ], + "duration": 4.904993604904184e-8, + "params": { + "nbar": 5.0, + "angle": -0.6346017160251383 + } + }, + { + "pauli_probabilities": [ + 0.9598059373522059, + 1.5427246879309603e-8, + 4.795514338946196e-8, + 0.040193999265403846 + ], + "duration": 2.4524968024520938e-8, + "params": { + "nbar": 5.0, + "angle": -0.31730085801256935 + } + }, + { + "pauli_probabilities": [ + 1.0, + 0.0, + 0.0, + 0.0 + ], + "duration": 0.0, + "params": { + "nbar": 5.0, + "angle": 0.0 + } + }, + { + "pauli_probabilities": [ + 0.9598059373518755, + 1.542757712774048e-8, + 4.7954813376545206e-8, + 0.04019399926573397 + ], + "duration": 2.4524968024520902e-8, + "params": { + "nbar": 5.0, + "angle": 0.3173008580125689 + } + }, + { + "pauli_probabilities": [ + 0.9211150485610557, + 1.180448078500484e-7, + 1.4599751233622916e-7, + 0.07888468739662402 + ], + "duration": 4.9049936049041803e-8, + "params": { + "nbar": 5.0, + "angle": 0.6346017160251378 + } + }, + { + "pauli_probabilities": [ + 0.8841805543886904, + 3.860646202646677e-7, + 2.3459241142532144e-7, + 0.11581882495427792 + ], + "duration": 7.357490407356271e-8, + "params": { + "nbar": 5.0, + "angle": 0.9519025740377067 + } + }, + { + "pauli_probabilities": [ + 0.8491705838361769, + 8.496249468746614e-7, + 3.0596389003945924e-7, + 0.1508282605749861 + ], + "duration": 9.809987209808369e-8, + "params": { + "nbar": 5.0, + "angle": 1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.8161880148887358, + 1.470986049102976e-6, + 4.2397956839432103e-7, + 0.18381009014564664 + ], + "duration": 1.2262484012260458e-7, + "params": { + "nbar": 5.0, + "angle": 1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.7852858664254054, + 2.1631914231516314e-6, + 7.055098689991847e-7, + 0.21471126487330244 + ], + "duration": 1.4714980814712548e-7, + "params": { + "nbar": 5.0, + "angle": 1.9038051480754143 + } + }, + { + "pauli_probabilities": [ + 0.7564790418555275, + 2.8343651227678547e-6, + 1.2760863416835156e-6, + 0.24351684769300802 + ], + "duration": 1.716747761716464e-7, + "params": { + "nbar": 5.0, + "angle": 2.2211060060879833 + } + }, + { + "pauli_probabilities": [ + 0.7297531908647487, + 3.4350604292613316e-6, + 2.2224270808392827e-6, + 0.27024115164774126 + ], + "duration": 1.961997441961673e-7, + "params": { + "nbar": 5.0, + "angle": 2.538406864100552 + } + }, + { + "pauli_probabilities": [ + 0.7050713648958034, + 3.987897886198248e-6, + 3.562615569862177e-6, + 0.2949210845907405 + ], + "duration": 2.2072471222068827e-7, + "params": { + "nbar": 5.0, + "angle": 2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.6823790307017303, + 4.588926918926392e-6, + 5.244487489480035e-6, + 0.31761113588386125 + ], + "duration": 2.4524968024520916e-7, + "params": { + "nbar": 5.0, + "angle": 3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.6885333427208822, + 2.3755941654381546e-6, + 2.7177203356334697e-6, + 0.3114615639646167 + ], + "duration": 2.247241011035956e-7, + "params": { + "nbar": 5.3, + "angle": -3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.7110851363908051, + 2.0654459262384687e-6, + 1.8393400227091542e-6, + 0.2889109588232459 + ], + "duration": 2.0225169099323604e-7, + "params": { + "nbar": 5.3, + "angle": -2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.7355377313700415, + 1.7800062870073028e-6, + 1.1419609061666502e-6, + 0.2644593466627653 + ], + "duration": 1.7977928088287646e-7, + "params": { + "nbar": 5.3, + "angle": -2.5384068641005526 + } + }, + { + "pauli_probabilities": [ + 0.7619377877919742, + 1.4684913999215153e-6, + 6.522246113828088e-7, + 0.23806009149201446 + ], + "duration": 1.5730687077251692e-7, + "params": { + "nbar": 5.3, + "angle": -2.2211060060879837 + } + }, + { + "pauli_probabilities": [ + 0.7903146503109624, + 1.1194596284140751e-6, + 3.594166493339895e-7, + 0.20968387081275985 + ], + "duration": 1.3483446066215734e-7, + "params": { + "nbar": 5.3, + "angle": -1.9038051480754146 + } + }, + { + "pauli_probabilities": [ + 0.8206756067448342, + 7.595347429767401e-7, + 2.1683333460142747e-7, + 0.17932341688708825 + ], + "duration": 1.123620505517978e-7, + "params": { + "nbar": 5.3, + "angle": -1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.8529997240164173, + 4.372164619848478e-7, + 1.580225868838767e-7, + 0.14699968074453384 + ], + "duration": 8.988964044143825e-8, + "params": { + "nbar": 5.3, + "angle": -1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.887229815179584, + 1.9773678698102325e-7, + 1.219454461735644e-7, + 0.11276986513818282 + ], + "duration": 6.741723033107867e-8, + "params": { + "nbar": 5.3, + "angle": -0.9519025740377072 + } + }, + { + "pauli_probabilities": [ + 0.9232620154680491, + 6.006389270633692e-8, + 7.59560746362182e-8, + 0.07673784851198351 + ], + "duration": 4.494482022071912e-8, + "params": { + "nbar": 5.3, + "angle": -0.6346017160251383 + } + }, + { + "pauli_probabilities": [ + 0.9609323910291184, + 7.77171610809914e-9, + 2.488389479661171e-8, + 0.039067576315270636 + ], + "duration": 2.2472410110359578e-8, + "params": { + "nbar": 5.3, + "angle": -0.31730085801256935 + } + }, + { + "pauli_probabilities": [ + 1.0, + 0.0, + 0.0, + 0.0 + ], + "duration": 0.0, + "params": { + "nbar": 5.3, + "angle": 0.0 + } + }, + { + "pauli_probabilities": [ + 0.9609323910296744, + 7.771160270114938e-9, + 2.488445087010982e-8, + 0.03906757631471447 + ], + "duration": 2.2472410110359545e-8, + "params": { + "nbar": 5.3, + "angle": 0.3173008580125689 + } + }, + { + "pauli_probabilities": [ + 0.923262015467757, + 6.006418514725801e-8, + 7.59557823523061e-8, + 0.07673784851227555 + ], + "duration": 4.494482022071909e-8, + "params": { + "nbar": 5.3, + "angle": 0.6346017160251378 + } + }, + { + "pauli_probabilities": [ + 0.8872298151792634, + 1.977371077102776e-7, + 1.2194512544431e-7, + 0.11276986513850351 + ], + "duration": 6.741723033107864e-8, + "params": { + "nbar": 5.3, + "angle": 0.9519025740377067 + } + }, + { + "pauli_probabilities": [ + 0.8529997240160221, + 4.37216857229885e-7, + 1.5802219163883954e-7, + 0.14699968074492903 + ], + "duration": 8.988964044143825e-8, + "params": { + "nbar": 5.3, + "angle": 1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.8206756067449195, + 7.595346576563276e-7, + 2.168334199218399e-7, + 0.17932341688700293 + ], + "duration": 1.123620505517978e-7, + "params": { + "nbar": 5.3, + "angle": 1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.7903146503110571, + 1.1194595334381012e-6, + 3.594167440744491e-7, + 0.20968387081266543 + ], + "duration": 1.3483446066215734e-7, + "params": { + "nbar": 5.3, + "angle": 1.9038051480754143 + } + }, + { + "pauli_probabilities": [ + 0.7619377877921837, + 1.468491191104897e-6, + 6.522248201601757e-7, + 0.23806009149180501 + ], + "duration": 1.573068707725169e-7, + "params": { + "nbar": 5.3, + "angle": 2.2211060060879833 + } + }, + { + "pauli_probabilities": [ + 0.7355377313698268, + 1.7800065011324002e-6, + 1.1419606921985618e-6, + 0.2644593466629798 + ], + "duration": 1.797792808828764e-7, + "params": { + "nbar": 5.3, + "angle": 2.538406864100552 + } + }, + { + "pauli_probabilities": [ + 0.7110851363898023, + 2.065446929077997e-6, + 1.839339019869626e-6, + 0.2889109588242487 + ], + "duration": 2.0225169099323604e-7, + "params": { + "nbar": 5.3, + "angle": 2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.688533342720309, + 2.375594738677529e-6, + 2.7177197623940954e-6, + 0.31146156396519 + ], + "duration": 2.247241011035956e-7, + "params": { + "nbar": 5.3, + "angle": 3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.6980016347485332, + 7.976723505194098e-7, + 9.13799257494285e-7, + 0.30199665377985885 + ], + "duration": 1.9630052720236187e-7, + "params": { + "nbar": 5.8, + "angle": -3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.7203055669174379, + 6.942619419073114e-7, + 6.150344847839504e-7, + 0.27969312378613553 + ], + "duration": 1.766704744821257e-7, + "params": { + "nbar": 5.8, + "angle": -2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.7443773392277997, + 5.988934565030053e-7, + 3.791212728514756e-7, + 0.2556216827574709 + ], + "duration": 1.570404217618895e-7, + "params": { + "nbar": 5.8, + "angle": -2.5384068641005526 + } + }, + { + "pauli_probabilities": [ + 0.7702524993919371, + 4.940098466363206e-7, + 2.1482221033608778e-7, + 0.22974679177600593 + ], + "duration": 1.3741036904165332e-7, + "params": { + "nbar": 5.8, + "angle": -2.2211060060879837 + } + }, + { + "pauli_probabilities": [ + 0.7979498917912179, + 3.759522485031853e-7, + 1.178428211877446e-7, + 0.2020496144137124 + ], + "duration": 1.1778031632141713e-7, + "params": { + "nbar": 5.8, + "angle": -1.9038051480754146 + } + }, + { + "pauli_probabilities": [ + 0.8274673828862855, + 2.5422080909648577e-7, + 7.157443236009878e-8, + 0.17253229131847309 + ], + "duration": 9.815026360118094e-8, + "params": { + "nbar": 5.8, + "angle": -1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.8587764608378429, + 1.4559959741211875e-7, + 5.29611760787453e-8, + 0.14122334060138364 + ], + "duration": 7.852021088094476e-8, + "params": { + "nbar": 5.8, + "angle": -1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.8918154040048191, + 6.538864550344519e-8, + 4.1254996348284754e-8, + 0.10818448935153907 + ], + "duration": 5.889015816070856e-8, + "params": { + "nbar": 5.8, + "angle": -0.9519025740377072 + } + }, + { + "pauli_probabilities": [ + 0.9264806739546421, + 1.9672033877758994e-8, + 2.57149616065094e-8, + 0.07351928065836244 + ], + "duration": 3.926010544047238e-8, + "params": { + "nbar": 5.8, + "angle": -0.6346017160251383 + } + }, + { + "pauli_probabilities": [ + 0.9626161696540549, + 2.51732278850109e-9, + 8.377147191907014e-9, + 0.037383819451475064 + ], + "duration": 1.9630052720236206e-8, + "params": { + "nbar": 5.8, + "angle": -0.31730085801256935 + } + }, + { + "pauli_probabilities": [ + 1.0, + 0.0, + 0.0, + 0.0 + ], + "duration": 0.0, + "params": { + "nbar": 5.8, + "angle": 0.0 + } + }, + { + "pauli_probabilities": [ + 0.9626161696544207, + 2.5169569304068713e-9, + 8.377512971496631e-9, + 0.03738381945110947 + ], + "duration": 1.9630052720236176e-8, + "params": { + "nbar": 5.8, + "angle": 0.3173008580125689 + } + }, + { + "pauli_probabilities": [ + 0.9264806739540934, + 1.9672582533818546e-8, + 2.5714412675683794e-8, + 0.07351928065891145 + ], + "duration": 3.926010544047235e-8, + "params": { + "nbar": 5.8, + "angle": 0.6346017160251378 + } + }, + { + "pauli_probabilities": [ + 0.8918154040044606, + 6.538900421142744e-8, + 4.12546376403025e-8, + 0.10818448935189756 + ], + "duration": 5.889015816070853e-8, + "params": { + "nbar": 5.8, + "angle": 0.9519025740377067 + } + }, + { + "pauli_probabilities": [ + 0.8587764608360218, + 1.4560141857223745e-7, + 5.29593549186266e-8, + 0.1412233406032048 + ], + "duration": 7.852021088094476e-8, + "params": { + "nbar": 5.8, + "angle": 1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.8274673828804682, + 2.542266263069415e-7, + 7.156861514964304e-8, + 0.17253229132429038 + ], + "duration": 9.815026360118094e-8, + "params": { + "nbar": 5.8, + "angle": 1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.7979498917854746, + 3.75957992270883e-7, + 1.1783707694901993e-7, + 0.20204961441945618 + ], + "duration": 1.1778031632141712e-7, + "params": { + "nbar": 5.8, + "angle": 1.9038051480754143 + } + }, + { + "pauli_probabilities": [ + 0.770252499384699, + 4.940170849728118e-7, + 2.1481497199959653e-7, + 0.2297467917832441 + ], + "duration": 1.374103690416533e-7, + "params": { + "nbar": 5.8, + "angle": 2.2211060060879833 + } + }, + { + "pauli_probabilities": [ + 0.7443773392192305, + 5.989020262758937e-7, + 3.7911270319634427e-7, + 0.25562168276604 + ], + "duration": 1.5704042176188946e-7, + "params": { + "nbar": 5.8, + "angle": 2.538406864100552 + } + }, + { + "pauli_probabilities": [ + 0.7203055669077645, + 6.942716152203348e-7, + 6.15024811470927e-7, + 0.27969312379580885 + ], + "duration": 1.766704744821257e-7, + "params": { + "nbar": 5.8, + "angle": 2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.6980016347477733, + 7.976731103454083e-7, + 9.137984976682865e-7, + 0.3019966537806187 + ], + "duration": 1.9630052720236187e-7, + "params": { + "nbar": 5.8, + "angle": 3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.7082513780074386, + 2.1722098487211802e-7, + 2.491450517802529e-7, + 0.2917481556265247 + ], + "duration": 1.6935323436056625e-7, + "params": { + "nbar": 6.4, + "angle": -3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.730244237348395, + 1.8935136379991672e-7, + 1.667150924564597e-7, + 0.26975540658514874 + ], + "duration": 1.5241791092450965e-7, + "params": { + "nbar": 6.4, + "angle": -2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.7538659549957833, + 1.635603764267481e-7, + 1.019817207265164e-7, + 0.2461337794621195 + ], + "duration": 1.35482587488453e-7, + "params": { + "nbar": 6.4, + "angle": -2.5384068641005526 + } + }, + { + "pauli_probabilities": [ + 0.7791414474191631, + 1.3491219101253878e-7, + 5.730232100515231e-8, + 0.2208583603663249 + ], + "duration": 1.185472640523964e-7, + "params": { + "nbar": 6.4, + "angle": -2.2211060060879837 + } + }, + { + "pauli_probabilities": [ + 0.8060798141940767, + 1.0249273898778467e-7, + 3.1290157204686516e-8, + 0.1939200520230271 + ], + "duration": 1.0161194061633976e-7, + "params": { + "nbar": 6.4, + "angle": -1.9038051480754146 + } + }, + { + "pauli_probabilities": [ + 0.8346705971816282, + 6.906448907484615e-8, + 1.9152991507656657e-8, + 0.16532931460089123 + ], + "duration": 8.467661718028313e-8, + "params": { + "nbar": 6.4, + "angle": -1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.864879181746425, + 3.934479248541902e-8, + 1.4405302717410366e-8, + 0.13512076450347982 + ], + "duration": 6.774129374422651e-8, + "params": { + "nbar": 6.4, + "angle": -1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.8966411430834222, + 1.7537251600737012e-8, + 1.1325433215117081e-8, + 0.10335882805389296 + ], + "duration": 5.080597030816987e-8, + "params": { + "nbar": 6.4, + "angle": -0.9519025740377072 + } + }, + { + "pauli_probabilities": [ + 0.9298553249555307, + 5.21528869080313e-9, + 7.058849716210037e-9, + 0.07014466277033088 + ], + "duration": 3.3870646872113254e-8, + "params": { + "nbar": 6.4, + "angle": -0.6346017160251383 + } + }, + { + "pauli_probabilities": [ + 0.9643754387312359, + 6.429764038659976e-10, + 2.2817258450345668e-9, + 0.03562455834406186 + ], + "duration": 1.693532343605664e-8, + "params": { + "nbar": 6.4, + "angle": -0.31730085801256935 + } + }, + { + "pauli_probabilities": [ + 1.0, + 0.0, + 0.0, + 0.0 + ], + "duration": 0.0, + "params": { + "nbar": 6.4, + "angle": 0.0 + } + }, + { + "pauli_probabilities": [ + 0.9643754387307218, + 6.434905603783285e-10, + 2.2812116885222357e-9, + 0.03562455834457595 + ], + "duration": 1.6935323436056614e-8, + "params": { + "nbar": 6.4, + "angle": 0.3173008580125689 + } + }, + { + "pauli_probabilities": [ + 0.9298553249550473, + 5.215772225347642e-9, + 7.0583661816655255e-9, + 0.07014466277081433 + ], + "duration": 3.387064687211323e-8, + "params": { + "nbar": 6.4, + "angle": 0.6346017160251378 + } + }, + { + "pauli_probabilities": [ + 0.8966411430830385, + 1.7537635941340465e-8, + 1.1325048403485909e-8, + 0.10335882805427715 + ], + "duration": 5.080597030816985e-8, + "params": { + "nbar": 6.4, + "angle": 0.9519025740377067 + } + }, + { + "pauli_probabilities": [ + 0.8648791817455717, + 3.934564591984006e-8, + 1.4404449282989326e-8, + 0.1351207645043332 + ], + "duration": 6.774129374422651e-8, + "params": { + "nbar": 6.4, + "angle": 1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.834670597178501, + 6.906761622857338e-8, + 1.9149864353929427e-8, + 0.1653293146040184 + ], + "duration": 8.467661718028313e-8, + "params": { + "nbar": 6.4, + "angle": 1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.8060798141871449, + 1.0249967164562084e-7, + 3.1283224350588785e-8, + 0.1939200520299591 + ], + "duration": 1.0161194061633974e-7, + "params": { + "nbar": 6.4, + "angle": 1.9038051480754143 + } + }, + { + "pauli_probabilities": [ + 0.7791414474127248, + 1.3491862924601172e-7, + 5.729588253616546e-8, + 0.22085836037276335 + ], + "duration": 1.1854726405239637e-7, + "params": { + "nbar": 6.4, + "angle": 2.2211060060879833 + } + }, + { + "pauli_probabilities": [ + 0.7538659549941491, + 1.6356201097814131e-7, + 1.0198008621437547e-7, + 0.24613377946375375 + ], + "duration": 1.3548258748845296e-7, + "params": { + "nbar": 6.4, + "angle": 2.538406864100552 + } + }, + { + "pauli_probabilities": [ + 0.7302442373410256, + 1.8935873330452553e-7, + 1.667077229518509e-7, + 0.2697554065925182 + ], + "duration": 1.5241791092450965e-7, + "params": { + "nbar": 6.4, + "angle": 2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.7082513780036143, + 2.172248093000327e-7, + 2.491412273523382e-7, + 0.29174815563034906 + ], + "duration": 1.6935323436056625e-7, + "params": { + "nbar": 6.4, + "angle": 3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.7189371878040118, + 4.8131083951790706e-8, + 5.5263583906014347e-8, + 0.28106270880132034 + ], + "duration": 1.4493588717605867e-7, + "params": { + "nbar": 7.1, + "angle": -3.173008580125691 + } + }, + { + "pauli_probabilities": [ + 0.7405593693882639, + 4.205420870632399e-8, + 3.6742468028907695e-8, + 0.2594405518150593 + ], + "duration": 1.3044229845845282e-7, + "params": { + "nbar": 7.1, + "angle": -2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.7636712111194455, + 3.638939846385712e-8, + 2.2281398652130303e-8, + 0.23632873020975742 + ], + "duration": 1.1594870974084693e-7, + "params": { + "nbar": 7.1, + "angle": -2.5384068641005526 + } + }, + { + "pauli_probabilities": [ + 0.7882880910705273, + 3.0020275551767895e-8, + 1.2387765886352017e-8, + 0.21171186652143126 + ], + "duration": 1.0145512102324108e-7, + "params": { + "nbar": 7.1, + "angle": -2.2211060060879837 + } + }, + { + "pauli_probabilities": [ + 0.8144106820139871, + 2.2767590906827363e-8, + 6.7042840914108986e-9, + 0.18558928851413792 + ], + "duration": 8.696153230563521e-8, + "params": { + "nbar": 7.1, + "angle": -1.9038051480754146 + } + }, + { + "pauli_probabilities": [ + 0.8420217626789663, + 1.529276543262901e-8, + 4.101923816455592e-9, + 0.15797821792634448 + ], + "duration": 7.246794358802933e-8, + "params": { + "nbar": 7.1, + "angle": -1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.8710823958209355, + 8.676727547292334e-9, + 3.097239850943828e-9, + 0.1289175924050971 + ], + "duration": 5.797435487042348e-8, + "params": { + "nbar": 7.1, + "angle": -1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.901527352856416, + 3.8453930742882324e-9, + 2.422789349511771e-9, + 0.09847264087540147 + ], + "duration": 4.34807661528176e-8, + "params": { + "nbar": 7.1, + "angle": -0.9519025740377072 + } + }, + { + "pauli_probabilities": [ + 0.9332596618566066, + 1.1143426092846252e-9, + 1.4782006528823542e-9, + 0.06674033555085013 + ], + "duration": 2.898717743521174e-8, + "params": { + "nbar": 7.1, + "angle": -0.6346017160251383 + } + }, + { + "pauli_probabilities": [ + 0.9661441649445215, + 7.757842800009389e-11, + 4.3757879927654296e-10, + 0.03385583454032132 + ], + "duration": 1.4493588717605881e-8, + "params": { + "nbar": 7.1, + "angle": -0.31730085801256935 + } + }, + { + "pauli_probabilities": [ + 1.0, + 0.0, + 0.0, + 0.0 + ], + "duration": 0.0, + "params": { + "nbar": 7.1, + "angle": 0.0 + } + }, + { + "pauli_probabilities": [ + 0.96614416494421, + 7.788974923020871e-11, + 4.372676350556713e-10, + 0.03385583454063268 + ], + "duration": 1.4493588717605858e-8, + "params": { + "nbar": 7.1, + "angle": 0.3173008580125689 + } + }, + { + "pauli_probabilities": [ + 0.9332596618565986, + 1.1143506864057798e-9, + 1.4781922617427e-9, + 0.06674033555085845 + ], + "duration": 2.8987177435211716e-8, + "params": { + "nbar": 7.1, + "angle": 0.6346017160251378 + } + }, + { + "pauli_probabilities": [ + 0.9015273528565013, + 3.845307988732117e-9, + 2.422874435067886e-9, + 0.09847264087531632 + ], + "duration": 4.348076615281758e-8, + "params": { + "nbar": 7.1, + "angle": 0.9519025740377067 + } + }, + { + "pauli_probabilities": [ + 0.8710823958210657, + 8.676597353098468e-9, + 3.0973700451376934e-9, + 0.12891759240496686 + ], + "duration": 5.797435487042348e-8, + "params": { + "nbar": 7.1, + "angle": 1.2692034320502765 + } + }, + { + "pauli_probabilities": [ + 0.8420217626787823, + 1.529294942181684e-8, + 4.101739827267763e-9, + 0.15797821792652844 + ], + "duration": 7.246794358802933e-8, + "params": { + "nbar": 7.1, + "angle": 1.5865042900628454 + } + }, + { + "pauli_probabilities": [ + 0.8144106820132657, + 2.276831220518545e-8, + 6.703562793052812e-9, + 0.18558928851485923 + ], + "duration": 8.69615323056352e-8, + "params": { + "nbar": 7.1, + "angle": 1.9038051480754143 + } + }, + { + "pauli_probabilities": [ + 0.7882880910703253, + 3.0020477900732014e-8, + 1.23875636158925e-8, + 0.2117118665216332 + ], + "duration": 1.0145512102324107e-7, + "params": { + "nbar": 7.1, + "angle": 2.2211060060879833 + } + }, + { + "pauli_probabilities": [ + 0.7636712111182333, + 3.6390610070498115e-8, + 2.2280187791283226e-8, + 0.23632873021096884 + ], + "duration": 1.1594870974084692e-7, + "params": { + "nbar": 7.1, + "angle": 2.538406864100552 + } + }, + { + "pauli_probabilities": [ + 0.7405593693859405, + 4.2056532108654746e-8, + 3.6740144626576936e-8, + 0.2594405518173828 + ], + "duration": 1.3044229845845282e-7, + "params": { + "nbar": 7.1, + "angle": 2.855707722113122 + } + }, + { + "pauli_probabilities": [ + 0.7189371878019464, + 4.8133149463351966e-8, + 5.5261518394453086e-8, + 0.2810627088033858 + ], + "duration": 1.4493588717605867e-7, + "params": { + "nbar": 7.1, + "angle": 3.173008580125691 + } + } + ] + }, + { + "name": "delay", + "qubits": [ + [ + 0 + ] + ], + "free_params": [ + "nbar", + "gate_duration_s" + ], + "fixed_params": { + "mem_kappa_1ph_MHz": 0.053, + "mem_kappa_2ph_MHz": 0.04, + "truncature": 40.0, + "num_time_steps": 1000.0 + }, + "interpolation_points": [ + { + "pauli_probabilities": [ + 0.9987153811718764, + 0.00009454500306244062, + 0.00009454500306244062, + 0.0010955288219986759 + ], + "duration": 7.943282347242822e-9, + "params": { + "nbar": 0.8, + "gate_duration_s": 7.943282347242822e-9 + } + }, + { + "pauli_probabilities": [ + 0.9985120823924629, + 0.000060169139605825706, + 0.00006016913960579795, + 0.0013675793283254578 + ], + "duration": 7.943282347242822e-9, + "params": { + "nbar": 1.0, + "gate_duration_s": 7.943282347242822e-9 + } + }, + { + "pauli_probabilities": [ + 0.998294166471156, + 0.00004052366606122071, + 0.00004052366606122071, + 0.001624786196721545 + ], + "duration": 7.943282347242822e-9, + "params": { + "nbar": 1.2, + "gate_duration_s": 7.943282347242822e-9 + } + }, + { + "pauli_probabilities": [ + 0.9978315396197515, + 0.00002836725600169343, + 0.00002836725600169343, + 0.0021117258682452067 + ], + "duration": 7.943282347242822e-9, + "params": { + "nbar": 1.6, + "gate_duration_s": 7.943282347242822e-9 + } + }, + { + "pauli_probabilities": [ + 0.9973703008828678, + 0.000015275076300586, + 0.000015275076300558244, + 0.0025991489645309784 + ], + "duration": 7.943282347242822e-9, + "params": { + "nbar": 2.0, + "gate_duration_s": 7.943282347242822e-9 + } + }, + { + "pauli_probabilities": [ + 0.9969022408468282, + 9.456109668098955e-6, + 9.456109668098955e-6, + 0.003078846933835533 + ], + "duration": 7.943282347242822e-9, + "params": { + "nbar": 2.4, + "gate_duration_s": 7.943282347242822e-9 + } + }, + { + "pauli_probabilities": [ + 0.9966683074739888, + 6.619314323857983e-6, + 6.619314323857983e-6, + 0.003318453897363405 + ], + "duration": 7.943282347242822e-9, + "params": { + "nbar": 2.6, + "gate_duration_s": 7.943282347242822e-9 + } + }, + { + "pauli_probabilities": [ + 0.9959611558790837, + 4.137091991096575e-6, + 4.137091991096575e-6, + 0.00403056993693407 + ], + "duration": 7.943282347242822e-9, + "params": { + "nbar": 3.2, + "gate_duration_s": 7.943282347242822e-9 + } + }, + { + "pauli_probabilities": [ + 0.9956075466875662, + 3.3096790698350365e-6, + 3.3096790698350365e-6, + 0.004385833954294122 + ], + "duration": 7.943282347242822e-9, + "params": { + "nbar": 3.5, + "gate_duration_s": 7.943282347242822e-9 + } + }, + { + "pauli_probabilities": [ + 0.995017854609501, + 2.8368704567960368e-6, + 2.8368704567960368e-6, + 0.004976471649585479 + ], + "duration": 7.943282347242822e-9, + "params": { + "nbar": 4.0, + "gate_duration_s": 7.943282347242822e-9 + } + }, + { + "pauli_probabilities": [ + 0.9944287470880697, + 2.4822634101806518e-6, + 2.4822634101806518e-6, + 0.005566288385109974 + ], + "duration": 7.943282347242822e-9, + "params": { + "nbar": 4.5, + "gate_duration_s": 7.943282347242822e-9 + } + }, + { + "pauli_probabilities": [ + 0.9938402626867882, + 2.206457581727106e-6, + 2.2064575816993504e-6, + 0.006155324398048473 + ], + "duration": 7.943282347242822e-9, + "params": { + "nbar": 5.0, + "gate_duration_s": 7.943282347242822e-9 + } + }, + { + "pauli_probabilities": [ + 0.9934874592658904, + 2.0903287207829635e-6, + 2.0903287207829635e-6, + 0.006508360076667968 + ], + "duration": 7.943282347242822e-9, + "params": { + "nbar": 5.3, + "gate_duration_s": 7.943282347242822e-9 + } + }, + { + "pauli_probabilities": [ + 0.9928999048522318, + 2.005871333532472e-6, + 2.005871333532472e-6, + 0.007096083405101095 + ], + "duration": 7.943282347242822e-9, + "params": { + "nbar": 5.8, + "gate_duration_s": 7.943282347242822e-9 + } + }, + { + "pauli_probabilities": [ + 0.9921957764247676, + 1.8912505480583874e-6, + 1.8912505480306319e-6, + 0.007800441074136272 + ], + "duration": 7.943282347242822e-9, + "params": { + "nbar": 6.4, + "gate_duration_s": 7.943282347242822e-9 + } + }, + { + "pauli_probabilities": [ + 0.9913755171257367, + 1.8052849243832547e-6, + 1.8052849243832547e-6, + 0.008620872304414523 + ], + "duration": 7.943282347242822e-9, + "params": { + "nbar": 7.1, + "gate_duration_s": 7.943282347242822e-9 + } + }, + { + "pauli_probabilities": [ + 0.9971825209903602, + 0.00020759027659886242, + 0.00020759027659886242, + 0.0024022984564421035 + ], + "duration": 1.744482698999256e-8, + "params": { + "nbar": 0.8, + "gate_duration_s": 1.744482698999256e-8 + } + }, + { + "pauli_probabilities": [ + 0.9967376477107905, + 0.00013212285502395282, + 0.00013212285502392507, + 0.00299810657916158 + ], + "duration": 1.744482698999256e-8, + "params": { + "nbar": 1.0, + "gate_duration_s": 1.744482698999256e-8 + } + }, + { + "pauli_probabilities": [ + 0.9962609858372331, + 0.00008898837771459389, + 0.00008898837771459389, + 0.0035610374073376527 + ], + "duration": 1.744482698999256e-8, + "params": { + "nbar": 1.2, + "gate_duration_s": 1.744482698999256e-8 + } + }, + { + "pauli_probabilities": [ + 0.9952497170959083, + 0.00006229519086450863, + 0.00006229519086450863, + 0.004625692522362668 + ], + "duration": 1.744482698999256e-8, + "params": { + "nbar": 1.6, + "gate_duration_s": 1.744482698999256e-8 + } + }, + { + "pauli_probabilities": [ + 0.9942426754404279, + 0.00003354549340991997, + 0.00003354549340991997, + 0.0056902335727523345 + ], + "duration": 1.744482698999256e-8, + "params": { + "nbar": 2.0, + "gate_duration_s": 1.744482698999256e-8 + } + }, + { + "pauli_probabilities": [ + 0.9932218288284462, + 0.000020766788611792375, + 0.00002076678861176462, + 0.006736637594330214 + ], + "duration": 1.744482698999256e-8, + "params": { + "nbar": 2.4, + "gate_duration_s": 1.744482698999256e-8 + } + }, + { + "pauli_probabilities": [ + 0.9927120568731949, + 0.000014536933163722399, + 0.000014536933163722399, + 0.007258869260477668 + ], + "duration": 1.744482698999256e-8, + "params": { + "nbar": 2.6, + "gate_duration_s": 1.744482698999256e-8 + } + }, + { + "pauli_probabilities": [ + 0.9911727393007801, + 9.085682287385266e-6, + 9.085682287385266e-6, + 0.008809089334645082 + ], + "duration": 1.744482698999256e-8, + "params": { + "nbar": 3.2, + "gate_duration_s": 1.744482698999256e-8 + } + }, + { + "pauli_probabilities": [ + 0.9904039891015408, + 7.268572246171834e-6, + 7.268572246171834e-6, + 0.009581473753966896 + ], + "duration": 1.744482698999256e-8, + "params": { + "nbar": 3.5, + "gate_duration_s": 1.744482698999256e-8 + } + }, + { + "pauli_probabilities": [ + 0.9891234340438892, + 6.230217721087117e-6, + 6.230217721059361e-6, + 0.01086410552066866 + ], + "duration": 1.744482698999256e-8, + "params": { + "nbar": 4.0, + "gate_duration_s": 1.744482698999256e-8 + } + }, + { + "pauli_probabilities": [ + 0.9878459685928714, + 5.451448996940389e-6, + 5.451448996912633e-6, + 0.01214312850913471 + ], + "duration": 1.744482698999256e-8, + "params": { + "nbar": 4.5, + "gate_duration_s": 1.744482698999256e-8 + } + }, + { + "pauli_probabilities": [ + 0.9865716705237932, + 4.845738311998193e-6, + 4.845738311998193e-6, + 0.013418637999582733 + ], + "duration": 1.744482698999256e-8, + "params": { + "nbar": 5.0, + "gate_duration_s": 1.744482698999256e-8 + } + }, + { + "pauli_probabilities": [ + 0.9858085830711858, + 4.590701795148533e-6, + 4.590701795120777e-6, + 0.014182235525223935 + ], + "duration": 1.744482698999256e-8, + "params": { + "nbar": 5.3, + "gate_duration_s": 1.744482698999256e-8 + } + }, + { + "pauli_probabilities": [ + 0.984539191328615, + 4.405220528524989e-6, + 4.405220528524989e-6, + 0.015451998230328001 + ], + "duration": 1.744482698999256e-8, + "params": { + "nbar": 5.8, + "gate_duration_s": 1.744482698999256e-8 + } + }, + { + "pauli_probabilities": [ + 0.9830203291048578, + 4.153495732239776e-6, + 4.153495732239776e-6, + 0.016971363903677678 + ], + "duration": 1.744482698999256e-8, + "params": { + "nbar": 6.4, + "gate_duration_s": 1.744482698999256e-8 + } + }, + { + "pauli_probabilities": [ + 0.9812542366918688, + 3.96470196875609e-6, + 3.96470196875609e-6, + 0.0187378339041937 + ], + "duration": 1.744482698999256e-8, + "params": { + "nbar": 7.1, + "gate_duration_s": 1.744482698999256e-8 + } + }, + { + "pauli_probabilities": [ + 0.9938304411625334, + 0.0004556778825807184, + 0.0004556778825807184, + 0.005258203072305179 + ], + "duration": 3.831186849557293e-8, + "params": { + "nbar": 0.8, + "gate_duration_s": 3.831186849557293e-8 + } + }, + { + "pauli_probabilities": [ + 0.9928611294675609, + 0.0002900730130046547, + 0.0002900730130046547, + 0.006558724506429775 + ], + "duration": 3.831186849557293e-8, + "params": { + "nbar": 1.0, + "gate_duration_s": 3.831186849557293e-8 + } + }, + { + "pauli_probabilities": [ + 0.9918234994455826, + 0.0001953923206876873, + 0.0001953923206876873, + 0.007785715913042002 + ], + "duration": 3.831186849557293e-8, + "params": { + "nbar": 1.2, + "gate_duration_s": 3.831186849557293e-8 + } + }, + { + "pauli_probabilities": [ + 0.989625273304556, + 0.00013679066474125978, + 0.00013679066474125978, + 0.010101145365961517 + ], + "duration": 3.831186849557293e-8, + "params": { + "nbar": 1.6, + "gate_duration_s": 3.831186849557293e-8 + } + }, + { + "pauli_probabilities": [ + 0.9874419221383534, + 0.00007366581474677059, + 0.00007366581474674283, + 0.01241074623215313 + ], + "duration": 3.831186849557293e-8, + "params": { + "nbar": 2.0, + "gate_duration_s": 3.831186849557293e-8 + } + }, + { + "pauli_probabilities": [ + 0.9852338110283021, + 0.00004560520708085658, + 0.00004560520708085658, + 0.014674978557536189 + ], + "duration": 3.831186849557293e-8, + "params": { + "nbar": 2.4, + "gate_duration_s": 3.831186849557293e-8 + } + }, + { + "pauli_probabilities": [ + 0.9841332551912615, + 0.00003192451855629774, + 0.00003192451855629774, + 0.01580289577162594 + ], + "duration": 3.831186849557293e-8, + "params": { + "nbar": 2.6, + "gate_duration_s": 3.831186849557293e-8 + } + }, + { + "pauli_probabilities": [ + 0.9808178435523186, + 0.00001995330186388422, + 0.00001995330186388422, + 0.01914224984395363 + ], + "duration": 3.831186849557293e-8, + "params": { + "nbar": 3.2, + "gate_duration_s": 3.831186849557293e-8 + } + }, + { + "pauli_probabilities": [ + 0.979166727685278, + 0.000015962768898175606, + 0.00001596276889814785, + 0.020801346776925606 + ], + "duration": 3.831186849557293e-8, + "params": { + "nbar": 3.5, + "gate_duration_s": 3.831186849557293e-8 + } + }, + { + "pauli_probabilities": [ + 0.976423147869538, + 0.00001368243574526029, + 0.000013682435745232535, + 0.023549487258971574 + ], + "duration": 3.831186849557293e-8, + "params": { + "nbar": 4.0, + "gate_duration_s": 3.831186849557293e-8 + } + }, + { + "pauli_probabilities": [ + 0.9736947325841522, + 0.00001197217222992375, + 0.000011972172229895994, + 0.026281323071388002 + ], + "duration": 3.831186849557293e-8, + "params": { + "nbar": 4.5, + "gate_duration_s": 3.831186849557293e-8 + } + }, + { + "pauli_probabilities": [ + 0.9709815816843239, + 0.00001064195918420996, + 0.00001064195918420996, + 0.028997134397307667 + ], + "duration": 3.831186849557293e-8, + "params": { + "nbar": 5.0, + "gate_duration_s": 3.831186849557293e-8 + } + }, + { + "pauli_probabilities": [ + 0.9693609251230333, + 0.000010081867363204156, + 0.0000100818673631764, + 0.030618911142240385 + ], + "duration": 3.831186849557293e-8, + "params": { + "nbar": 5.3, + "gate_duration_s": 3.831186849557293e-8 + } + }, + { + "pauli_probabilities": [ + 0.9666716961955419, + 9.674527068820327e-6, + 9.674527068792571e-6, + 0.0333089547503205 + ], + "duration": 3.831186849557293e-8, + "params": { + "nbar": 5.8, + "gate_duration_s": 3.831186849557293e-8 + } + }, + { + "pauli_probabilities": [ + 0.9634650221081842, + 9.121707036208182e-6, + 9.121707036208182e-6, + 0.03651673447774334 + ], + "duration": 3.831186849557293e-8, + "params": { + "nbar": 6.4, + "gate_duration_s": 3.831186849557293e-8 + } + }, + { + "pauli_probabilities": [ + 0.9597515192107184, + 8.70709120953661e-6, + 8.707091209508855e-6, + 0.040231066606862514 + ], + "duration": 3.831186849557293e-8, + "params": { + "nbar": 7.1, + "gate_duration_s": 3.831186849557293e-8 + } + }, + { + "pauli_probabilities": [ + 0.9865373719408466, + 0.0009996569111557774, + 0.0009996569111557774, + 0.011463314236841882 + ], + "duration": 8.413951416451964e-8, + "params": { + "nbar": 0.8, + "gate_duration_s": 8.413951416451964e-8 + } + }, + { + "pauli_probabilities": [ + 0.984445354739848, + 0.0006366086420994954, + 0.0006366086420994677, + 0.014281427975953137 + ], + "duration": 8.413951416451964e-8, + "params": { + "nbar": 1.0, + "gate_duration_s": 8.413951416451964e-8 + } + }, + { + "pauli_probabilities": [ + 0.9822103458822569, + 0.0004289148782103125, + 0.0004289148782103125, + 0.016931824361322567 + ], + "duration": 8.413951416451964e-8, + "params": { + "nbar": 1.2, + "gate_duration_s": 8.413951416451964e-8 + } + }, + { + "pauli_probabilities": [ + 0.9774903776180521, + 0.00030031773879651835, + 0.00030031773879651835, + 0.021908986904354777 + ], + "duration": 8.413951416451964e-8, + "params": { + "nbar": 1.6, + "gate_duration_s": 8.413951416451964e-8 + } + }, + { + "pauli_probabilities": [ + 0.972829083947411, + 0.0001617544064498877, + 0.0001617544064498877, + 0.026847407239689314 + ], + "duration": 8.413951416451964e-8, + "params": { + "nbar": 2.0, + "gate_duration_s": 8.413951416451964e-8 + } + }, + { + "pauli_probabilities": [ + 0.9681390544053179, + 0.00010014602448030208, + 0.00010014602448030208, + 0.03166065354572156 + ], + "duration": 8.413951416451964e-8, + "params": { + "nbar": 2.4, + "gate_duration_s": 8.413951416451964e-8 + } + }, + { + "pauli_probabilities": [ + 0.9658112056246777, + 0.00007010643014263018, + 0.00007010643014260243, + 0.03404858151503701 + ], + "duration": 8.413951416451964e-8, + "params": { + "nbar": 2.6, + "gate_duration_s": 8.413951416451964e-8 + } + }, + { + "pauli_probabilities": [ + 0.9588348302377282, + 0.00004381882300003026, + 0.00004381882300003026, + 0.041077532116271714 + ], + "duration": 8.413951416451964e-8, + "params": { + "nbar": 3.2, + "gate_duration_s": 8.413951416451964e-8 + } + }, + { + "pauli_probabilities": [ + 0.9553818327257204, + 0.000035055672871708854, + 0.000035055672871708854, + 0.04454805592853622 + ], + "duration": 8.413951416451964e-8, + "params": { + "nbar": 3.5, + "gate_duration_s": 8.413951416451964e-8 + } + }, + { + "pauli_probabilities": [ + 0.9496751760839344, + 0.000030048020575573764, + 0.00003004802057554601, + 0.050264727874914455 + ], + "duration": 8.413951416451964e-8, + "params": { + "nbar": 4.0, + "gate_duration_s": 8.413951416451964e-8 + } + }, + { + "pauli_probabilities": [ + 0.9440389011022288, + 0.00002629221551828098, + 0.00002629221551828098, + 0.05590851446673473 + ], + "duration": 8.413951416451964e-8, + "params": { + "nbar": 4.5, + "gate_duration_s": 8.413951416451964e-8 + } + }, + { + "pauli_probabilities": [ + 0.9384725266434804, + 0.000023370994793048272, + 0.000023370994793048272, + 0.061480731366933605 + ], + "duration": 8.413951416451964e-8, + "params": { + "nbar": 5.0, + "gate_duration_s": 8.413951416451964e-8 + } + }, + { + "pauli_probabilities": [ + 0.935165762573525, + 0.00002214099690636684, + 0.000022140996906339083, + 0.06478995543266233 + ], + "duration": 8.413951416451964e-8, + "params": { + "nbar": 5.3, + "gate_duration_s": 8.413951416451964e-8 + } + }, + { + "pauli_probabilities": [ + 0.9297086970118154, + 0.000021246449187384275, + 0.000021246449187384275, + 0.07024881008980993 + ], + "duration": 8.413951416451964e-8, + "params": { + "nbar": 5.8, + "gate_duration_s": 8.413951416451964e-8 + } + }, + { + "pauli_probabilities": [ + 0.9232506393502473, + 0.000020032415020049266, + 0.000020032415020049266, + 0.07670929581971253 + ], + "duration": 8.413951416451964e-8, + "params": { + "nbar": 6.4, + "gate_duration_s": 8.413951416451964e-8 + } + }, + { + "pauli_probabilities": [ + 0.9158383402300858, + 0.000019121885525302806, + 0.00001912188552527505, + 0.08412341599886355 + ], + "duration": 8.413951416451964e-8, + "params": { + "nbar": 7.1, + "gate_duration_s": 8.413951416451964e-8 + } + }, + { + "pauli_probabilities": [ + 0.9708463534954134, + 0.0021901710862997636, + 0.002190171086299736, + 0.024773304331987128 + ], + "duration": 1.8478497974222906e-7, + "params": { + "nbar": 0.8, + "gate_duration_s": 1.8478497974222906e-7 + } + }, + { + "pauli_probabilities": [ + 0.9664249143157277, + 0.0013959741526853586, + 0.0013959741526853309, + 0.03078313737890151 + ], + "duration": 1.8478497974222906e-7, + "params": { + "nbar": 1.0, + "gate_duration_s": 1.8478497974222906e-7 + } + }, + { + "pauli_probabilities": [ + 0.9617217541753418, + 0.0009410050712116147, + 0.0009410050712116147, + 0.036396235682235045 + ], + "duration": 1.8478497974222906e-7, + "params": { + "nbar": 1.2, + "gate_duration_s": 1.8478497974222906e-7 + } + }, + { + "pauli_probabilities": [ + 0.9518574161519249, + 0.0006590760637995852, + 0.0006590760637995852, + 0.04682443172047601 + ], + "duration": 1.8478497974222906e-7, + "params": { + "nbar": 1.6, + "gate_duration_s": 1.8478497974222906e-7 + } + }, + { + "pauli_probabilities": [ + 0.9422376311211511, + 0.0003551032945036392, + 0.00035510329450361144, + 0.057052162289841585 + ], + "duration": 1.8478497974222906e-7, + "params": { + "nbar": 2.0, + "gate_duration_s": 1.8478497974222906e-7 + } + }, + { + "pauli_probabilities": [ + 0.932666720821083, + 0.00021988536285710847, + 0.00021988536285710847, + 0.06689350845320274 + ], + "duration": 1.8478497974222906e-7, + "params": { + "nbar": 2.4, + "gate_duration_s": 1.8478497974222906e-7 + } + }, + { + "pauli_probabilities": [ + 0.9279597175187042, + 0.0001539400685641179, + 0.0001539400685641179, + 0.07173240234416761 + ], + "duration": 1.8478497974222906e-7, + "params": { + "nbar": 2.6, + "gate_duration_s": 1.8478497974222906e-7 + } + }, + { + "pauli_probabilities": [ + 0.9140120288337793, + 0.00009622365421277368, + 0.00009622365421277368, + 0.08579552385779518 + ], + "duration": 1.8478497974222906e-7, + "params": { + "nbar": 3.2, + "gate_duration_s": 1.8478497974222906e-7 + } + }, + { + "pauli_probabilities": [ + 0.9072013325128466, + 0.00007698188670379746, + 0.00007698188670379746, + 0.09264470371374575 + ], + "duration": 1.8478497974222906e-7, + "params": { + "nbar": 3.5, + "gate_duration_s": 1.8478497974222906e-7 + } + }, + { + "pauli_probabilities": [ + 0.8960785062551144, + 0.00006598592580478457, + 0.00006598592580478457, + 0.10378952189327595 + ], + "duration": 1.8478497974222906e-7, + "params": { + "nbar": 4.0, + "gate_duration_s": 1.8478497974222906e-7 + } + }, + { + "pauli_probabilities": [ + 0.8852572981244812, + 0.00005773863764213516, + 0.00005773863764213516, + 0.11462722460023456 + ], + "duration": 1.8478497974222906e-7, + "params": { + "nbar": 4.5, + "gate_duration_s": 1.8478497974222906e-7 + } + }, + { + "pauli_probabilities": [ + 0.8747303037348648, + 0.0000513238920345771, + 0.0000513238920345771, + 0.12516704848106608 + ], + "duration": 1.8478497974222906e-7, + "params": { + "nbar": 5.0, + "gate_duration_s": 1.8478497974222906e-7 + } + }, + { + "pauli_probabilities": [ + 0.8685516854779726, + 0.00004862289726254021, + 0.000048622897262512454, + 0.13135106872750238 + ], + "duration": 1.8478497974222906e-7, + "params": { + "nbar": 5.3, + "gate_duration_s": 1.8478497974222906e-7 + } + }, + { + "pauli_probabilities": [ + 0.8584771735054826, + 0.00004665851909566032, + 0.00004665851909566032, + 0.14142950945632615 + ], + "duration": 1.8478497974222906e-7, + "params": { + "nbar": 5.8, + "gate_duration_s": 1.8478497974222906e-7 + } + }, + { + "pauli_probabilities": [ + 0.8467510113529464, + 0.00004399255260464918, + 0.00004399255260464918, + 0.15316100354184425 + ], + "duration": 1.8478497974222906e-7, + "params": { + "nbar": 6.4, + "gate_duration_s": 1.8478497974222906e-7 + } + }, + { + "pauli_probabilities": [ + 0.8335534440921154, + 0.00004199305907601203, + 0.00004199305907601203, + 0.1663625697897326 + ], + "duration": 1.8478497974222906e-7, + "params": { + "nbar": 7.1, + "gate_duration_s": 1.8478497974222906e-7 + } + }, + { + "pauli_probabilities": [ + 0.9379018187299606, + 0.0047848076895551095, + 0.0047848076895551095, + 0.052528565890929135 + ], + "duration": 4.058198942243799e-7, + "params": { + "nbar": 0.8, + "gate_duration_s": 4.058198942243799e-7 + } + }, + { + "pauli_probabilities": [ + 0.9289821694909166, + 0.003055566604306087, + 0.003055566604306059, + 0.06490669730047119 + ], + "duration": 4.058198942243799e-7, + "params": { + "nbar": 1.0, + "gate_duration_s": 4.058198942243799e-7 + } + }, + { + "pauli_probabilities": [ + 0.9195830470907378, + 0.002061959265064306, + 0.002061959265064306, + 0.07629303437913365 + ], + "duration": 4.058198942243799e-7, + "params": { + "nbar": 1.2, + "gate_duration_s": 4.058198942243799e-7 + } + }, + { + "pauli_probabilities": [ + 0.9001583653382483, + 0.0014451636021208525, + 0.0014451636021208247, + 0.09695130745751004 + ], + "duration": 4.058198942243799e-7, + "params": { + "nbar": 1.6, + "gate_duration_s": 4.058198942243799e-7 + } + }, + { + "pauli_probabilities": [ + 0.8817354497355103, + 0.0007792060203281326, + 0.0007792060203281326, + 0.11670613822383344 + ], + "duration": 4.058198942243799e-7, + "params": { + "nbar": 2.0, + "gate_duration_s": 4.058198942243799e-7 + } + }, + { + "pauli_probabilities": [ + 0.8638504555491693, + 0.00048265241446371343, + 0.00048265241446371343, + 0.13518423962190323 + ], + "duration": 4.058198942243799e-7, + "params": { + "nbar": 2.4, + "gate_duration_s": 4.058198942243799e-7 + } + }, + { + "pauli_probabilities": [ + 0.8552310681570918, + 0.0003379546124769317, + 0.0003379546124769317, + 0.1440930226179543 + ], + "duration": 4.058198942243799e-7, + "params": { + "nbar": 2.6, + "gate_duration_s": 4.058198942243799e-7 + } + }, + { + "pauli_probabilities": [ + 0.8303102565885023, + 0.00021127520348948603, + 0.00021127520348948603, + 0.16926719300451876 + ], + "duration": 4.058198942243799e-7, + "params": { + "nbar": 3.2, + "gate_duration_s": 4.058198942243799e-7 + } + }, + { + "pauli_probabilities": [ + 0.8184983942913964, + 0.00016903445153007568, + 0.00016903445153007568, + 0.18116353680554353 + ], + "duration": 4.058198942243799e-7, + "params": { + "nbar": 3.5, + "gate_duration_s": 4.058198942243799e-7 + } + }, + { + "pauli_probabilities": [ + 0.7997029120592766, + 0.00014489367192577207, + 0.00014489367192574432, + 0.2000073005968719 + ], + "duration": 4.058198942243799e-7, + "params": { + "nbar": 4.0, + "gate_duration_s": 4.058198942243799e-7 + } + }, + { + "pauli_probabilities": [ + 0.7820128314035655, + 0.00012678655640949166, + 0.00012678655640949166, + 0.21773359548361548 + ], + "duration": 4.058198942243799e-7, + "params": { + "nbar": 4.5, + "gate_duration_s": 4.058198942243799e-7 + } + }, + { + "pauli_probabilities": [ + 0.7653645247797559, + 0.00011270233712468158, + 0.00011270233712468158, + 0.23441007054599472 + ], + "duration": 4.058198942243799e-7, + "params": { + "nbar": 5.0, + "gate_duration_s": 4.058198942243799e-7 + } + }, + { + "pauli_probabilities": [ + 0.7558491559809914, + 0.00010677190203431386, + 0.00010677190203431386, + 0.24393730021493995 + ], + "duration": 4.058198942243799e-7, + "params": { + "nbar": 5.3, + "gate_duration_s": 4.058198942243799e-7 + } + }, + { + "pauli_probabilities": [ + 0.7407374150834227, + 0.00010245876993142389, + 0.00010245876993142389, + 0.25905766737671443 + ], + "duration": 4.058198942243799e-7, + "params": { + "nbar": 5.8, + "gate_duration_s": 4.058198942243799e-7 + } + }, + { + "pauli_probabilities": [ + 0.7237776891156026, + 0.00009660511443311537, + 0.00009660511443310149, + 0.2760291006555312 + ], + "duration": 4.058198942243799e-7, + "params": { + "nbar": 6.4, + "gate_duration_s": 4.058198942243799e-7 + } + }, + { + "pauli_probabilities": [ + 0.7054933929992333, + 0.00009221478282622764, + 0.00009221478282622764, + 0.29432217743511424 + ], + "duration": 4.058198942243799e-7, + "params": { + "nbar": 7.1, + "gate_duration_s": 4.058198942243799e-7 + } + }, + { + "pauli_probabilities": [ + 0.8723047591048592, + 0.01038813213660758, + 0.010388132136607553, + 0.10691897662192565 + ], + "duration": 8.912509381337459e-7, + "params": { + "nbar": 0.8, + "gate_duration_s": 8.912509381337459e-7 + } + }, + { + "pauli_probabilities": [ + 0.8561043737864931, + 0.006661540016830475, + 0.006661540016830475, + 0.13057254617984593 + ], + "duration": 8.912509381337459e-7, + "params": { + "nbar": 1.0, + "gate_duration_s": 8.912509381337459e-7 + } + }, + { + "pauli_probabilities": [ + 0.8393704481150324, + 0.004506094223261453, + 0.004506094223261453, + 0.15161736343844467 + ], + "duration": 8.912509381337459e-7, + "params": { + "nbar": 1.2, + "gate_duration_s": 8.912509381337459e-7 + } + }, + { + "pauli_probabilities": [ + 0.8058344550101217, + 0.0031628613155893215, + 0.0031628613155893215, + 0.18783982235869967 + ], + "duration": 8.912509381337459e-7, + "params": { + "nbar": 1.6, + "gate_duration_s": 8.912509381337459e-7 + } + }, + { + "pauli_probabilities": [ + 0.7759477904881422, + 0.001708082306351194, + 0.001708082306351194, + 0.22063604489915545 + ], + "duration": 8.912509381337459e-7, + "params": { + "nbar": 2.0, + "gate_duration_s": 8.912509381337459e-7 + } + }, + { + "pauli_probabilities": [ + 0.7484346115276526, + 0.0010587647061044286, + 0.0010587647061044148, + 0.24944785906013855 + ], + "duration": 8.912509381337459e-7, + "params": { + "nbar": 2.4, + "gate_duration_s": 8.912509381337459e-7 + } + }, + { + "pauli_probabilities": [ + 0.7357605457679308, + 0.000741606973150094, + 0.000741606973150094, + 0.26275624028576905 + ], + "duration": 8.912509381337459e-7, + "params": { + "nbar": 2.6, + "gate_duration_s": 8.912509381337459e-7 + } + }, + { + "pauli_probabilities": [ + 0.7009844103214089, + 0.00046376251289852177, + 0.00046376251289853565, + 0.2980880646527941 + ], + "duration": 8.912509381337459e-7, + "params": { + "nbar": 3.2, + "gate_duration_s": 8.912509381337459e-7 + } + }, + { + "pauli_probabilities": [ + 0.6855494943865704, + 0.00037107888565378333, + 0.0003710788856537972, + 0.313708347842122 + ], + "duration": 8.912509381337459e-7, + "params": { + "nbar": 3.5, + "gate_duration_s": 8.912509381337459e-7 + } + }, + { + "pauli_probabilities": [ + 0.6623369837226375, + 0.0003181013576944447, + 0.0003181013576944447, + 0.3370268135619736 + ], + "duration": 8.912509381337459e-7, + "params": { + "nbar": 4.0, + "gate_duration_s": 8.912509381337459e-7 + } + }, + { + "pauli_probabilities": [ + 0.6420226026201068, + 0.0002783608335301946, + 0.0002783608335301946, + 0.35742067571283287 + ], + "duration": 8.912509381337459e-7, + "params": { + "nbar": 4.5, + "gate_duration_s": 8.912509381337459e-7 + } + }, + { + "pauli_probabilities": [ + 0.6242464424050653, + 0.00024744716397270827, + 0.00024744716397270827, + 0.3752586632669893 + ], + "duration": 8.912509381337459e-7, + "params": { + "nbar": 5.0, + "gate_duration_s": 8.912509381337459e-7 + } + }, + { + "pauli_probabilities": [ + 0.6146634866445129, + 0.0002344297371970963, + 0.00023442973719708937, + 0.3848676538810929 + ], + "duration": 8.912509381337459e-7, + "params": { + "nbar": 5.3, + "gate_duration_s": 8.912509381337459e-7 + } + }, + { + "pauli_probabilities": [ + 0.6002950074615355, + 0.00022496209156997599, + 0.00022496209156996905, + 0.39925506835532454 + ], + "duration": 8.912509381337459e-7, + "params": { + "nbar": 5.8, + "gate_duration_s": 8.912509381337459e-7 + } + }, + { + "pauli_probabilities": [ + 0.5854089440045895, + 0.00021211256990286143, + 0.00021211256990286143, + 0.4141668308556048 + ], + "duration": 8.912509381337459e-7, + "params": { + "nbar": 6.4, + "gate_duration_s": 8.912509381337459e-7 + } + }, + { + "pauli_probabilities": [ + 0.570803820631879, + 0.00020247499484970372, + 0.00020247499484971065, + 0.4287912293784216 + ], + "duration": 8.912509381337459e-7, + "params": { + "nbar": 7.1, + "gate_duration_s": 8.912509381337459e-7 + } + }, + { + "pauli_probabilities": [ + 0.7556913659238558, + 0.022248717713155147, + 0.022248717713155147, + 0.19981119864983388 + ], + "duration": 1.9573417814876578e-6, + "params": { + "nbar": 0.8, + "gate_duration_s": 1.9573417814876578e-6 + } + }, + { + "pauli_probabilities": [ + 0.732745336812781, + 0.014397154225306491, + 0.014397154225306463, + 0.23846035473660612 + ], + "duration": 1.9573417814876578e-6, + "params": { + "nbar": 1.0, + "gate_duration_s": 1.9573417814876578e-6 + } + }, + { + "pauli_probabilities": [ + 0.7099678653167236, + 0.009789609306046845, + 0.009789609306046831, + 0.27045291607118277 + ], + "duration": 1.9573417814876578e-6, + "params": { + "nbar": 1.2, + "gate_duration_s": 1.9573417814876578e-6 + } + }, + { + "pauli_probabilities": [ + 0.6668608499677392, + 0.006893676621698472, + 0.006893676621698486, + 0.31935179678886383 + ], + "duration": 1.9573417814876578e-6, + "params": { + "nbar": 1.6, + "gate_duration_s": 1.9573417814876578e-6 + } + }, + { + "pauli_probabilities": [ + 0.6336456859434259, + 0.0037359233153446414, + 0.0037359233153446414, + 0.3588824674258848 + ], + "duration": 1.9573417814876578e-6, + "params": { + "nbar": 2.0, + "gate_duration_s": 1.9573417814876578e-6 + } + }, + { + "pauli_probabilities": [ + 0.606303476330267, + 0.0023193430747545096, + 0.002319343074754482, + 0.38905783752022394 + ], + "duration": 1.9573417814876578e-6, + "params": { + "nbar": 2.4, + "gate_duration_s": 1.9573417814876578e-6 + } + }, + { + "pauli_probabilities": [ + 0.5949608866931719, + 0.001625808611983172, + 0.001625808611983165, + 0.40178749608286174 + ], + "duration": 1.9573417814876578e-6, + "params": { + "nbar": 2.6, + "gate_duration_s": 1.9573417814876578e-6 + } + }, + { + "pauli_probabilities": [ + 0.5668882931550105, + 0.0010173731150568133, + 0.0010173731150568133, + 0.43107696061487577 + ], + "duration": 1.9573417814876578e-6, + "params": { + "nbar": 3.2, + "gate_duration_s": 1.9573417814876578e-6 + } + }, + { + "pauli_probabilities": [ + 0.5561235285878727, + 0.0008142302477843928, + 0.0008142302477844032, + 0.4422480109165585 + ], + "duration": 1.9573417814876578e-6, + "params": { + "nbar": 3.5, + "gate_duration_s": 1.9573417814876578e-6 + } + }, + { + "pauli_probabilities": [ + 0.5417532222818645, + 0.0006980742029753066, + 0.0006980742029752962, + 0.4568506293121849 + ], + "duration": 1.9573417814876578e-6, + "params": { + "nbar": 4.0, + "gate_duration_s": 1.9573417814876578e-6 + } + }, + { + "pauli_probabilities": [ + 0.5310396492678473, + 0.000610921637925723, + 0.0006109216379256988, + 0.46773850745630124 + ], + "duration": 1.9573417814876578e-6, + "params": { + "nbar": 4.5, + "gate_duration_s": 1.9573417814876578e-6 + } + }, + { + "pauli_probabilities": [ + 0.5230547185447412, + 0.0005431152462507527, + 0.0005431152462507249, + 0.4758590509627574 + ], + "duration": 1.9573417814876578e-6, + "params": { + "nbar": 5.0, + "gate_duration_s": 1.9573417814876578e-6 + } + }, + { + "pauli_probabilities": [ + 0.5192718269916619, + 0.0005145596714446095, + 0.0005145596714445921, + 0.479699053665449 + ], + "duration": 1.9573417814876578e-6, + "params": { + "nbar": 5.3, + "gate_duration_s": 1.9573417814876578e-6 + } + }, + { + "pauli_probabilities": [ + 0.5142584199200855, + 0.0004937899275768449, + 0.0004937899275768431, + 0.4847540002247608 + ], + "duration": 1.9573417814876578e-6, + "params": { + "nbar": 5.8, + "gate_duration_s": 1.9573417814876578e-6 + } + }, + { + "pauli_probabilities": [ + 0.5099060010685963, + 0.0004655996523562156, + 0.0004655996523562078, + 0.4891627996266913 + ], + "duration": 1.9573417814876578e-6, + "params": { + "nbar": 6.4, + "gate_duration_s": 1.9573417814876578e-6 + } + }, + { + "pauli_probabilities": [ + 0.5064314936393608, + 0.00044445485576644983, + 0.0004444548557664407, + 0.4926795966491063 + ], + "duration": 1.9573417814876578e-6, + "params": { + "nbar": 7.1, + "gate_duration_s": 1.9573417814876578e-6 + } + }, + { + "pauli_probabilities": [ + 0.5914139372356122, + 0.046276697907961586, + 0.0462766979079616, + 0.31603266694846466 + ], + "duration": 4.298662347082272e-6, + "params": { + "nbar": 0.8, + "gate_duration_s": 4.298662347082272e-6 + } + }, + { + "pauli_probabilities": [ + 0.5758539077584917, + 0.03053375870291452, + 0.0305337587029145, + 0.3630785748356794 + ], + "duration": 4.298662347082272e-6, + "params": { + "nbar": 1.0, + "gate_duration_s": 4.298662347082272e-6 + } + }, + { + "pauli_probabilities": [ + 0.5612037455021874, + 0.020997455496714564, + 0.020997455496714557, + 0.39680134350438345 + ], + "duration": 4.298662347082272e-6, + "params": { + "nbar": 1.2, + "gate_duration_s": 4.298662347082272e-6 + } + }, + { + "pauli_probabilities": [ + 0.5341835742052616, + 0.014890478206626343, + 0.01489047820662634, + 0.43603546938148563 + ], + "duration": 4.298662347082272e-6, + "params": { + "nbar": 1.6, + "gate_duration_s": 4.298662347082272e-6 + } + }, + { + "pauli_probabilities": [ + 0.5211656935618387, + 0.008131477171188667, + 0.008131477171188645, + 0.4625713520957839 + ], + "duration": 4.298662347082272e-6, + "params": { + "nbar": 2.0, + "gate_duration_s": 4.298662347082272e-6 + } + }, + { + "pauli_probabilities": [ + 0.5124249538699355, + 0.005065434039260856, + 0.005065434039260852, + 0.4774441780515428 + ], + "duration": 4.298662347082272e-6, + "params": { + "nbar": 2.4, + "gate_duration_s": 4.298662347082272e-6 + } + }, + { + "pauli_probabilities": [ + 0.5099573987056156, + 0.0035566761857081033, + 0.0035566761857080964, + 0.4829292489229682 + ], + "duration": 4.298662347082272e-6, + "params": { + "nbar": 2.6, + "gate_duration_s": 4.298662347082272e-6 + } + }, + { + "pauli_probabilities": [ + 0.5040048239838317, + 0.00222889127258455, + 0.002228891272584549, + 0.4915373934709991 + ], + "duration": 4.298662347082272e-6, + "params": { + "nbar": 3.2, + "gate_duration_s": 4.298662347082272e-6 + } + }, + { + "pauli_probabilities": [ + 0.5024490617251761, + 0.0017847084614386905, + 0.0017847084614386888, + 0.4939815213519465 + ], + "duration": 4.298662347082272e-6, + "params": { + "nbar": 3.5, + "gate_duration_s": 4.298662347082272e-6 + } + }, + { + "pauli_probabilities": [ + 0.5006912140884487, + 0.0015305322844631735, + 0.0015305322844631764, + 0.49624772134262496 + ], + "duration": 4.298662347082272e-6, + "params": { + "nbar": 4.0, + "gate_duration_s": 4.298662347082272e-6 + } + }, + { + "pauli_probabilities": [ + 0.4998261716546808, + 0.0013397293574130072, + 0.0013397293574129998, + 0.4974943696304932 + ], + "duration": 4.298662347082272e-6, + "params": { + "nbar": 4.5, + "gate_duration_s": 4.298662347082272e-6 + } + }, + { + "pauli_probabilities": [ + 0.4994206015496563, + 0.001191225788772023, + 0.0011912257887720101, + 0.49819694687279964 + ], + "duration": 4.298662347082272e-6, + "params": { + "nbar": 5.0, + "gate_duration_s": 4.298662347082272e-6 + } + }, + { + "pauli_probabilities": [ + 0.4992868650794735, + 0.001128671440602217, + 0.0011286714406022191, + 0.4984557920393221 + ], + "duration": 4.298662347082272e-6, + "params": { + "nbar": 5.3, + "gate_duration_s": 4.298662347082272e-6 + } + }, + { + "pauli_probabilities": [ + 0.49913489270466227, + 0.0010831674912381453, + 0.0010831674912381295, + 0.4986987723128614 + ], + "duration": 4.298662347082272e-6, + "params": { + "nbar": 5.8, + "gate_duration_s": 4.298662347082272e-6 + } + }, + { + "pauli_probabilities": [ + 0.4990791870607031, + 0.001021398823342376, + 0.0010213988233423732, + 0.4988780152926121 + ], + "duration": 4.298662347082272e-6, + "params": { + "nbar": 6.4, + "gate_duration_s": 4.298662347082272e-6 + } + }, + { + "pauli_probabilities": [ + 0.49906572185822584, + 0.0009750622637047185, + 0.0009750622637046957, + 0.49898415361436477 + ], + "duration": 4.298662347082272e-6, + "params": { + "nbar": 7.1, + "gate_duration_s": 4.298662347082272e-6 + } + }, + { + "pauli_probabilities": [ + 0.4389204364442516, + 0.0905216590430397, + 0.09052165904303969, + 0.38003624546966897 + ], + "duration": 9.440608762859225e-6, + "params": { + "nbar": 0.8, + "gate_duration_s": 9.440608762859225e-6 + } + }, + { + "pauli_probabilities": [ + 0.45451049966244406, + 0.06219919289619508, + 0.06219919289619508, + 0.4210911145451658 + ], + "duration": 9.440608762859225e-6, + "params": { + "nbar": 1.0, + "gate_duration_s": 9.440608762859225e-6 + } + }, + { + "pauli_probabilities": [ + 0.4656729457214124, + 0.04381054452556283, + 0.04381054452556282, + 0.446705965227462 + ], + "duration": 9.440608762859225e-6, + "params": { + "nbar": 1.2, + "gate_duration_s": 9.440608762859225e-6 + } + }, + { + "pauli_probabilities": [ + 0.4715129782598956, + 0.03154171556457407, + 0.03154171556457405, + 0.46540359061095626 + ], + "duration": 9.440608762859225e-6, + "params": { + "nbar": 1.6, + "gate_duration_s": 9.440608762859225e-6 + } + }, + { + "pauli_probabilities": [ + 0.4834724574232072, + 0.01751147930454223, + 0.01751147930454222, + 0.48150458396770834 + ], + "duration": 9.440608762859225e-6, + "params": { + "nbar": 2.0, + "gate_duration_s": 9.440608762859225e-6 + } + }, + { + "pauli_probabilities": [ + 0.4893269912042014, + 0.010989941208618202, + 0.010989941208618209, + 0.4886931263785622 + ], + "duration": 9.440608762859225e-6, + "params": { + "nbar": 2.4, + "gate_duration_s": 9.440608762859225e-6 + } + }, + { + "pauli_probabilities": [ + 0.4924351957598764, + 0.007744677414652621, + 0.007744677414652623, + 0.49207544941081843 + ], + "duration": 9.440608762859225e-6, + "params": { + "nbar": 2.6, + "gate_duration_s": 9.440608762859225e-6 + } + }, + { + "pauli_probabilities": [ + 0.49516393683616644, + 0.004868945724269249, + 0.004868945724269241, + 0.4950981717152951 + ], + "duration": 9.440608762859225e-6, + "params": { + "nbar": 3.2, + "gate_duration_s": 9.440608762859225e-6 + } + }, + { + "pauli_probabilities": [ + 0.4961112569088253, + 0.0039028024411150767, + 0.003902802441115072, + 0.49608313820894456 + ], + "duration": 9.440608762859225e-6, + "params": { + "nbar": 3.5, + "gate_duration_s": 9.440608762859225e-6 + } + }, + { + "pauli_probabilities": [ + 0.49665439979097226, + 0.0033490118600204197, + 0.003349011860020401, + 0.4966475764889869 + ], + "duration": 9.440608762859225e-6, + "params": { + "nbar": 4.0, + "gate_duration_s": 9.440608762859225e-6 + } + }, + { + "pauli_probabilities": [ + 0.49706797660855917, + 0.0029328512648877296, + 0.002932851264887709, + 0.49706632086166536 + ], + "duration": 9.440608762859225e-6, + "params": { + "nbar": 4.5, + "gate_duration_s": 9.440608762859225e-6 + } + }, + { + "pauli_probabilities": [ + 0.4973915154769283, + 0.002608685415380356, + 0.0026086854153803685, + 0.49739111369231104 + ], + "duration": 9.440608762859225e-6, + "params": { + "nbar": 5.0, + "gate_duration_s": 9.440608762859225e-6 + } + }, + { + "pauli_probabilities": [ + 0.4975280185740759, + 0.0024720673199429655, + 0.0024720673199429555, + 0.4975278467860381 + ], + "duration": 9.440608762859225e-6, + "params": { + "nbar": 5.3, + "gate_duration_s": 9.440608762859225e-6 + } + }, + { + "pauli_probabilities": [ + 0.49762735952275083, + 0.0023726613203475682, + 0.002372661320347552, + 0.497627317836554 + ], + "duration": 9.440608762859225e-6, + "params": { + "nbar": 5.8, + "gate_duration_s": 9.440608762859225e-6 + } + }, + { + "pauli_probabilities": [ + 0.49776231448850206, + 0.0022376893218184228, + 0.00223768932181842, + 0.49776230686786105 + ], + "duration": 9.440608762859225e-6, + "params": { + "nbar": 6.4, + "gate_duration_s": 9.440608762859225e-6 + } + }, + { + "pauli_probabilities": [ + 0.49786358847862544, + 0.002136412046134456, + 0.002136412046134434, + 0.49786358742910564 + ], + "duration": 9.440608762859225e-6, + "params": { + "nbar": 7.1, + "gate_duration_s": 9.440608762859225e-6 + } + }, + { + "pauli_probabilities": [ + 0.34414035738331983, + 0.15685430031576197, + 0.15685430031576197, + 0.3421510419851562 + ], + "duration": 0.00002073321573485954, + "params": { + "nbar": 0.8, + "gate_duration_s": 0.00002073321573485954 + } + }, + { + "pauli_probabilities": [ + 0.3836639510747111, + 0.11662274013519175, + 0.11662274013519175, + 0.3830905686549054 + ], + "duration": 0.00002073321573485954, + "params": { + "nbar": 1.0, + "gate_duration_s": 0.00002073321573485954 + } + }, + { + "pauli_probabilities": [ + 0.4138315184325607, + 0.08625111486923907, + 0.08625111486923906, + 0.4136662518289612 + ], + "duration": 0.00002073321573485954, + "params": { + "nbar": 1.2, + "gate_duration_s": 0.00002073321573485954 + } + }, + { + "pauli_probabilities": [ + 0.4359186191936206, + 0.06408824574350559, + 0.0640882457435056, + 0.4359048893193682 + ], + "duration": 0.00002073321573485954, + "params": { + "nbar": 1.6, + "gate_duration_s": 0.00002073321573485954 + } + }, + { + "pauli_probabilities": [ + 0.4631459875939443, + 0.03685458272529405, + 0.036854582725294044, + 0.46314484695546754 + ], + "duration": 0.00002073321573485954, + "params": { + "nbar": 2.0, + "gate_duration_s": 0.00002073321573485954 + } + }, + { + "pauli_probabilities": [ + 0.47649696115820084, + 0.023503086222281668, + 0.02350308622228167, + 0.47649686639723576 + ], + "duration": 0.00002073321573485954, + "params": { + "nbar": 2.4, + "gate_duration_s": 0.00002073321573485954 + } + }, + { + "pauli_probabilities": [ + 0.4833058508299113, + 0.016694162826613845, + 0.016694162826613845, + 0.483305823516861 + ], + "duration": 0.00002073321573485954, + "params": { + "nbar": 2.6, + "gate_duration_s": 0.00002073321573485954 + } + }, + { + "pauli_probabilities": [ + 0.48943134589353543, + 0.010568654433475601, + 0.0105686544334756, + 0.48943134523951337 + ], + "duration": 0.00002073321573485954, + "params": { + "nbar": 3.2, + "gate_duration_s": 0.00002073321573485954 + } + }, + { + "pauli_probabilities": [ + 0.49150871478642033, + 0.008491285264182337, + 0.00849128526418233, + 0.491508714685215 + ], + "duration": 0.00002073321573485954, + "params": { + "nbar": 3.5, + "gate_duration_s": 0.00002073321573485954 + } + }, + { + "pauli_probabilities": [ + 0.49270386515393805, + 0.0072961348483189, + 0.007296134848318897, + 0.4927038651494241 + ], + "duration": 0.00002073321573485954, + "params": { + "nbar": 4.0, + "gate_duration_s": 0.00002073321573485954 + } + }, + { + "pauli_probabilities": [ + 0.4936041077051251, + 0.006395892294975547, + 0.00639589229497553, + 0.4936041077049238 + ], + "duration": 0.00002073321573485954, + "params": { + "nbar": 4.5, + "gate_duration_s": 0.00002073321573485954 + } + }, + { + "pauli_probabilities": [ + 0.4943066043065023, + 0.00569339569350211, + 0.005693395693502107, + 0.4943066043064934 + ], + "duration": 0.00002073321573485954, + "params": { + "nbar": 5.0, + "gate_duration_s": 0.00002073321573485954 + } + }, + { + "pauli_probabilities": [ + 0.49460299807899255, + 0.005397001921008184, + 0.005397001921008171, + 0.4946029980789911 + ], + "duration": 0.00002073321573485954, + "params": { + "nbar": 5.3, + "gate_duration_s": 0.00002073321573485954 + } + }, + { + "pauli_probabilities": [ + 0.4948187830171161, + 0.0051812169828839415, + 0.005181216982883929, + 0.494818783017116 + ], + "duration": 0.00002073321573485954, + "params": { + "nbar": 5.8, + "gate_duration_s": 0.00002073321573485954 + } + }, + { + "pauli_probabilities": [ + 0.495111938518774, + 0.004888061481226003, + 0.004888061481226003, + 0.495111938518774 + ], + "duration": 0.00002073321573485954, + "params": { + "nbar": 6.4, + "gate_duration_s": 0.00002073321573485954 + } + }, + { + "pauli_probabilities": [ + 0.49533203548925764, + 0.004667964510742417, + 0.004667964510742417, + 0.4953320354892576 + ], + "duration": 0.00002073321573485954, + "params": { + "nbar": 7.1, + "gate_duration_s": 0.00002073321573485954 + } + }, + { + "pauli_probabilities": [ + 0.27859431610815477, + 0.2214062679475383, + 0.2214062679475383, + 0.2785931479967687 + ], + "duration": 0.000045533741044262486, + "params": { + "nbar": 0.8, + "gate_duration_s": 0.000045533741044262486 + } + }, + { + "pauli_probabilities": [ + 0.3129066063429544, + 0.18709343167170583, + 0.18709343167170583, + 0.31290653031363397 + ], + "duration": 0.000045533741044262486, + "params": { + "nbar": 1.0, + "gate_duration_s": 0.000045533741044262486 + } + }, + { + "pauli_probabilities": [ + 0.3487114474137716, + 0.15128855506050343, + 0.15128855506050343, + 0.34871144246522157 + ], + "duration": 0.000045533741044262486, + "params": { + "nbar": 1.2, + "gate_duration_s": 0.000045533741044262486 + } + }, + { + "pauli_probabilities": [ + 0.3804485508966351, + 0.11955144911384694, + 0.11955144911384694, + 0.3804485508756711 + ], + "duration": 0.000045533741044262486, + "params": { + "nbar": 1.6, + "gate_duration_s": 0.000045533741044262486 + } + }, + { + "pauli_probabilities": [ + 0.4261263035322491, + 0.07387369646779529, + 0.07387369646779529, + 0.4261263035321603 + ], + "duration": 0.000045533741044262486, + "params": { + "nbar": 2.0, + "gate_duration_s": 0.000045533741044262486 + } + }, + { + "pauli_probabilities": [ + 0.45126724046901134, + 0.048732759530988864, + 0.04873275953098885, + 0.4512672404690109 + ], + "duration": 0.000045533741044262486, + "params": { + "nbar": 2.4, + "gate_duration_s": 0.000045533741044262486 + } + }, + { + "pauli_probabilities": [ + 0.4647945051454667, + 0.03520549485453319, + 0.0352054948545332, + 0.46479450514546683 + ], + "duration": 0.000045533741044262486, + "params": { + "nbar": 2.6, + "gate_duration_s": 0.000045533741044262486 + } + }, + { + "pauli_probabilities": [ + 0.477374618127437, + 0.022625381872563022, + 0.022625381872563022, + 0.477374618127437 + ], + "duration": 0.000045533741044262486, + "params": { + "nbar": 3.2, + "gate_duration_s": 0.000045533741044262486 + } + }, + { + "pauli_probabilities": [ + 0.4817296405002318, + 0.01827035949976813, + 0.01827035949976813, + 0.48172964050023187 + ], + "duration": 0.000045533741044262486, + "params": { + "nbar": 3.5, + "gate_duration_s": 0.000045533741044262486 + } + }, + { + "pauli_probabilities": [ + 0.4842555741040786, + 0.015744425895921427, + 0.015744425895921427, + 0.4842555741040786 + ], + "duration": 0.000045533741044262486, + "params": { + "nbar": 4.0, + "gate_duration_s": 0.000045533741044262486 + } + }, + { + "pauli_probabilities": [ + 0.4861680768443124, + 0.013831923155687681, + 0.013831923155687681, + 0.4861680768443123 + ], + "duration": 0.000045533741044262486, + "params": { + "nbar": 4.5, + "gate_duration_s": 0.000045533741044262486 + } + }, + { + "pauli_probabilities": [ + 0.48766636732837987, + 0.012333632671620132, + 0.012333632671620132, + 0.48766636732837987 + ], + "duration": 0.000045533741044262486, + "params": { + "nbar": 5.0, + "gate_duration_s": 0.000045533741044262486 + } + }, + { + "pauli_probabilities": [ + 0.4883000667303832, + 0.011699933269616769, + 0.011699933269616769, + 0.48830006673038323 + ], + "duration": 0.000045533741044262486, + "params": { + "nbar": 5.3, + "gate_duration_s": 0.000045533741044262486 + } + }, + { + "pauli_probabilities": [ + 0.48876200003865455, + 0.011237999961345474, + 0.011237999961345474, + 0.48876200003865455 + ], + "duration": 0.000045533741044262486, + "params": { + "nbar": 5.8, + "gate_duration_s": 0.000045533741044262486 + } + }, + { + "pauli_probabilities": [ + 0.48939034209909016, + 0.010609657900909897, + 0.010609657900909897, + 0.4893903420990901 + ], + "duration": 0.000045533741044262486, + "params": { + "nbar": 6.4, + "gate_duration_s": 0.000045533741044262486 + } + }, + { + "pauli_probabilities": [ + 0.48986268357311324, + 0.010137316426886811, + 0.010137316426886811, + 0.4898626835731132 + ], + "duration": 0.000045533741044262486, + "params": { + "nbar": 7.1, + "gate_duration_s": 0.000045533741044262486 + } + }, + { + "pauli_probabilities": [ + 0.2521373273699683, + 0.24786267263007847, + 0.24786267263007847, + 0.25213732736987476 + ], + "duration": 0.0001, + "params": { + "nbar": 0.8, + "gate_duration_s": 0.0001 + } + }, + { + "pauli_probabilities": [ + 0.2620752498104326, + 0.23792475018956746, + 0.23792475018956746, + 0.2620752498104324 + ], + "duration": 0.0001, + "params": { + "nbar": 1.0, + "gate_duration_s": 0.0001 + } + }, + { + "pauli_probabilities": [ + 0.2824806520762648, + 0.21751934792373515, + 0.21751934792373515, + 0.2824806520762648 + ], + "duration": 0.0001, + "params": { + "nbar": 1.2, + "gate_duration_s": 0.0001 + } + }, + { + "pauli_probabilities": [ + 0.3099127591104439, + 0.19008724088955606, + 0.19008724088955606, + 0.30991275911044397 + ], + "duration": 0.0001, + "params": { + "nbar": 1.6, + "gate_duration_s": 0.0001 + } + }, + { + "pauli_probabilities": [ + 0.3658423423077939, + 0.1341576576922062, + 0.1341576576922062, + 0.3658423423077938 + ], + "duration": 0.0001, + "params": { + "nbar": 2.0, + "gate_duration_s": 0.0001 + } + }, + { + "pauli_probabilities": [ + 0.4052862894038629, + 0.09471371059613712, + 0.09471371059613712, + 0.4052862894038629 + ], + "duration": 0.0001, + "params": { + "nbar": 2.4, + "gate_duration_s": 0.0001 + } + }, + { + "pauli_probabilities": [ + 0.4291328276434474, + 0.07086717235655268, + 0.07086717235655268, + 0.4291328276434473 + ], + "duration": 0.0001, + "params": { + "nbar": 2.6, + "gate_duration_s": 0.0001 + } + }, + { + "pauli_probabilities": [ + 0.45298408653765865, + 0.04701591346234127, + 0.04701591346234127, + 0.45298408653765876 + ], + "duration": 0.0001, + "params": { + "nbar": 3.2, + "gate_duration_s": 0.0001 + } + }, + { + "pauli_probabilities": [ + 0.4616204312226535, + 0.038379568777346496, + 0.038379568777346496, + 0.4616204312226535 + ], + "duration": 0.0001, + "params": { + "nbar": 3.5, + "gate_duration_s": 0.0001 + } + }, + { + "pauli_probabilities": [ + 0.4667194749375454, + 0.0332805250624546, + 0.0332805250624546, + 0.4667194749375454 + ], + "duration": 0.0001, + "params": { + "nbar": 4.0, + "gate_duration_s": 0.0001 + } + }, + { + "pauli_probabilities": [ + 0.4706242256461488, + 0.029375774353851136, + 0.029375774353851136, + 0.47062422564614886 + ], + "duration": 0.0001, + "params": { + "nbar": 4.5, + "gate_duration_s": 0.0001 + } + }, + { + "pauli_probabilities": [ + 0.4737098292035924, + 0.026290170796407553, + 0.026290170796407553, + 0.47370982920359245 + ], + "duration": 0.0001, + "params": { + "nbar": 5.0, + "gate_duration_s": 0.0001 + } + }, + { + "pauli_probabilities": [ + 0.47502190656306476, + 0.02497809343693519, + 0.02497809343693519, + 0.4750219065630648 + ], + "duration": 0.0001, + "params": { + "nbar": 5.3, + "gate_duration_s": 0.0001 + } + }, + { + "pauli_probabilities": [ + 0.4759809755738207, + 0.024019024426179397, + 0.024019024426179397, + 0.4759809755738206 + ], + "duration": 0.0001, + "params": { + "nbar": 5.8, + "gate_duration_s": 0.0001 + } + }, + { + "pauli_probabilities": [ + 0.47728911071917834, + 0.02271088928082174, + 0.02271088928082174, + 0.47728911071917823 + ], + "duration": 0.0001, + "params": { + "nbar": 6.4, + "gate_duration_s": 0.0001 + } + }, + { + "pauli_probabilities": [ + 0.4782751790705655, + 0.021724820929434424, + 0.021724820929434424, + 0.4782751790705656 + ], + "duration": 0.0001, + "params": { + "nbar": 7.1, + "gate_duration_s": 0.0001 + } + }, + { + "pauli_probabilities": [ + 0.25000717962154506, + 0.24999282037845502, + 0.24999282037845502, + 0.25000717962154495 + ], + "duration": 0.00021961736002054367, + "params": { + "nbar": 0.8, + "gate_duration_s": 0.00021961736002054367 + } + }, + { + "pauli_probabilities": [ + 0.2503218690162875, + 0.24967813098371253, + 0.24967813098371253, + 0.25032186901628745 + ], + "duration": 0.00021961736002054367, + "params": { + "nbar": 1.0, + "gate_duration_s": 0.00021961736002054367 + } + }, + { + "pauli_probabilities": [ + 0.252827729177199, + 0.24717227082280097, + 0.24717227082280097, + 0.25282772917719903 + ], + "duration": 0.00021961736002054367, + "params": { + "nbar": 1.2, + "gate_duration_s": 0.00021961736002054367 + } + }, + { + "pauli_probabilities": [ + 0.26084896908674715, + 0.23915103091325285, + 0.23915103091325285, + 0.26084896908674715 + ], + "duration": 0.00021961736002054367, + "params": { + "nbar": 1.6, + "gate_duration_s": 0.00021961736002054367 + } + }, + { + "pauli_probabilities": [ + 0.2961592147240846, + 0.20384078527591537, + 0.20384078527591537, + 0.29615921472408463 + ], + "duration": 0.00021961736002054367, + "params": { + "nbar": 2.0, + "gate_duration_s": 0.00021961736002054367 + } + }, + { + "pauli_probabilities": [ + 0.337852912341692, + 0.1621470876583079, + 0.1621470876583079, + 0.3378529123416921 + ], + "duration": 0.00021961736002054367, + "params": { + "nbar": 2.4, + "gate_duration_s": 0.00021961736002054367 + } + }, + { + "pauli_probabilities": [ + 0.37022957632709264, + 0.12977042367290728, + 0.12977042367290728, + 0.37022957632709275 + ], + "duration": 0.00021961736002054367, + "params": { + "nbar": 2.6, + "gate_duration_s": 0.00021961736002054367 + } + }, + { + "pauli_probabilities": [ + 0.4082102352096857, + 0.09178976479031423, + 0.09178976479031423, + 0.4082102352096858 + ], + "duration": 0.00021961736002054367, + "params": { + "nbar": 3.2, + "gate_duration_s": 0.00021961736002054367 + } + }, + { + "pauli_probabilities": [ + 0.42337068403214295, + 0.07662931596785696, + 0.07662931596785696, + 0.42337068403214306 + ], + "duration": 0.00021961736002054367, + "params": { + "nbar": 3.5, + "gate_duration_s": 0.00021961736002054367 + } + }, + { + "pauli_probabilities": [ + 0.4326774139640197, + 0.06732258603598029, + 0.06732258603598029, + 0.4326774139640197 + ], + "duration": 0.00021961736002054367, + "params": { + "nbar": 4.0, + "gate_duration_s": 0.00021961736002054367 + } + }, + { + "pauli_probabilities": [ + 0.43998387836246033, + 0.060016121637539666, + 0.060016121637539666, + 0.43998387836246033 + ], + "duration": 0.00021961736002054367, + "params": { + "nbar": 4.5, + "gate_duration_s": 0.00021961736002054367 + } + }, + { + "pauli_probabilities": [ + 0.44586813044620177, + 0.054131869553798145, + 0.054131869553798145, + 0.4458681304462019 + ], + "duration": 0.00021961736002054367, + "params": { + "nbar": 5.0, + "gate_duration_s": 0.00021961736002054367 + } + }, + { + "pauli_probabilities": [ + 0.44839991162646897, + 0.05160008837353108, + 0.05160008837353108, + 0.4483999116264689 + ], + "duration": 0.00021961736002054367, + "params": { + "nbar": 5.3, + "gate_duration_s": 0.00021961736002054367 + } + }, + { + "pauli_probabilities": [ + 0.4502617379419469, + 0.04973826205805304, + 0.04973826205805304, + 0.45026173794194696 + ], + "duration": 0.00021961736002054367, + "params": { + "nbar": 5.8, + "gate_duration_s": 0.00021961736002054367 + } + }, + { + "pauli_probabilities": [ + 0.45281647931522073, + 0.04718352068477935, + 0.04718352068477935, + 0.4528164793152206 + ], + "duration": 0.00021961736002054367, + "params": { + "nbar": 6.4, + "gate_duration_s": 0.00021961736002054367 + } + }, + { + "pauli_probabilities": [ + 0.4547539004541856, + 0.04524609954581446, + 0.04524609954581446, + 0.4547539004541855 + ], + "duration": 0.00021961736002054367, + "params": { + "nbar": 7.1, + "gate_duration_s": 0.00021961736002054367 + } + }, + { + "pauli_probabilities": [ + 0.2500000000265017, + 0.24999999997349825, + 0.24999999997349825, + 0.25000000002650175 + ], + "duration": 0.0004823178482239299, + "params": { + "nbar": 0.8, + "gate_duration_s": 0.0004823178482239299 + } + }, + { + "pauli_probabilities": [ + 0.2500001123118194, + 0.24999988768818052, + 0.24999988768818052, + 0.2500001123118195 + ], + "duration": 0.0004823178482239299, + "params": { + "nbar": 1.0, + "gate_duration_s": 0.0004823178482239299 + } + }, + { + "pauli_probabilities": [ + 0.250013276490035, + 0.249986723509965, + 0.249986723509965, + 0.25001327649003496 + ], + "duration": 0.0004823178482239299, + "params": { + "nbar": 1.2, + "gate_duration_s": 0.0004823178482239299 + } + }, + { + "pauli_probabilities": [ + 0.2502544135829696, + 0.24974558641703037, + 0.24974558641703037, + 0.2502544135829696 + ], + "duration": 0.0004823178482239299, + "params": { + "nbar": 1.6, + "gate_duration_s": 0.0004823178482239299 + } + }, + { + "pauli_probabilities": [ + 0.2561185407211296, + 0.2438814592788704, + 0.2438814592788704, + 0.2561185407211296 + ], + "duration": 0.0004823178482239299, + "params": { + "nbar": 2.0, + "gate_duration_s": 0.0004823178482239299 + } + }, + { + "pauli_probabilities": [ + 0.27514626205995363, + 0.22485373794004643, + 0.22485373794004643, + 0.2751462620599536 + ], + "duration": 0.0004823178482239299, + "params": { + "nbar": 2.4, + "gate_duration_s": 0.0004823178482239299 + } + }, + { + "pauli_probabilities": [ + 0.3000856608785438, + 0.19991433912145612, + 0.19991433912145612, + 0.3000856608785439 + ], + "duration": 0.0004823178482239299, + "params": { + "nbar": 2.6, + "gate_duration_s": 0.0004823178482239299 + } + }, + { + "pauli_probabilities": [ + 0.34152682213347996, + 0.15847317786652, + 0.15847317786652, + 0.34152682213348 + ], + "duration": 0.0004823178482239299, + "params": { + "nbar": 3.2, + "gate_duration_s": 0.0004823178482239299 + } + }, + { + "pauli_probabilities": [ + 0.36189912966433635, + 0.1381008703356636, + 0.1381008703356636, + 0.3618991296643364 + ], + "duration": 0.0004823178482239299, + "params": { + "nbar": 3.5, + "gate_duration_s": 0.0004823178482239299 + } + }, + { + "pauli_probabilities": [ + 0.37551627361438067, + 0.12448372638561933, + 0.12448372638561933, + 0.37551627361438067 + ], + "duration": 0.0004823178482239299, + "params": { + "nbar": 4.0, + "gate_duration_s": 0.0004823178482239299 + } + }, + { + "pauli_probabilities": [ + 0.38680596493752517, + 0.11319403506247483, + 0.11319403506247483, + 0.38680596493752517 + ], + "duration": 0.0004823178482239299, + "params": { + "nbar": 4.5, + "gate_duration_s": 0.0004823178482239299 + } + }, + { + "pauli_probabilities": [ + 0.3962843305858239, + 0.10371566941417601, + 0.10371566941417601, + 0.396284330585824 + ], + "duration": 0.0004823178482239299, + "params": { + "nbar": 5.0, + "gate_duration_s": 0.0004823178482239299 + } + }, + { + "pauli_probabilities": [ + 0.40046912591644146, + 0.09953087408355846, + 0.09953087408355846, + 0.40046912591644157 + ], + "duration": 0.0004823178482239299, + "params": { + "nbar": 5.3, + "gate_duration_s": 0.0004823178482239299 + } + }, + { + "pauli_probabilities": [ + 0.4035876128849831, + 0.09641238711501679, + 0.09641238711501679, + 0.40358761288498324 + ], + "duration": 0.0004823178482239299, + "params": { + "nbar": 5.8, + "gate_duration_s": 0.0004823178482239299 + } + }, + { + "pauli_probabilities": [ + 0.4079234759419781, + 0.09207652405802186, + 0.09207652405802186, + 0.40792347594197814 + ], + "duration": 0.0004823178482239299, + "params": { + "nbar": 6.4, + "gate_duration_s": 0.0004823178482239299 + } + }, + { + "pauli_probabilities": [ + 0.4112555134048883, + 0.08874448659511164, + 0.08874448659511164, + 0.41125551340488836 + ], + "duration": 0.0004823178482239299, + "params": { + "nbar": 7.1, + "gate_duration_s": 0.0004823178482239299 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.0010592537251772876, + "params": { + "nbar": 0.8, + "gate_duration_s": 0.0010592537251772876 + } + }, + { + "pauli_probabilities": [ + 0.2500000000000029, + 0.24999999999999714, + 0.24999999999999714, + 0.2500000000000029 + ], + "duration": 0.0010592537251772876, + "params": { + "nbar": 1.0, + "gate_duration_s": 0.0010592537251772876 + } + }, + { + "pauli_probabilities": [ + 0.250000000102238, + 0.24999999989776198, + 0.24999999989776198, + 0.25000000010223805 + ], + "duration": 0.0010592537251772876, + "params": { + "nbar": 1.2, + "gate_duration_s": 0.0010592537251772876 + } + }, + { + "pauli_probabilities": [ + 0.25000006700554667, + 0.24999993299445333, + 0.24999993299445333, + 0.25000006700554667 + ], + "duration": 0.0010592537251772876, + "params": { + "nbar": 1.6, + "gate_duration_s": 0.0010592537251772876 + } + }, + { + "pauli_probabilities": [ + 0.2500723207161504, + 0.24992767928384957, + 0.24992767928384957, + 0.25007232071615043 + ], + "duration": 0.0010592537251772876, + "params": { + "nbar": 2.0, + "gate_duration_s": 0.0010592537251772876 + } + }, + { + "pauli_probabilities": [ + 0.2516118709094237, + 0.24838812909057623, + 0.24838812909057623, + 0.2516118709094238 + ], + "duration": 0.0010592537251772876, + "params": { + "nbar": 2.4, + "gate_duration_s": 0.0010592537251772876 + } + }, + { + "pauli_probabilities": [ + 0.2573200354237476, + 0.24267996457625243, + 0.24267996457625243, + 0.25732003542374754 + ], + "duration": 0.0010592537251772876, + "params": { + "nbar": 2.6, + "gate_duration_s": 0.0010592537251772876 + } + }, + { + "pauli_probabilities": [ + 0.27751365216206914, + 0.22248634783793084, + 0.22248634783793084, + 0.2775136521620692 + ], + "duration": 0.0010592537251772876, + "params": { + "nbar": 3.2, + "gate_duration_s": 0.0010592537251772876 + } + }, + { + "pauli_probabilities": [ + 0.2927786027814945, + 0.20722139721850547, + 0.20722139721850547, + 0.29277860278149453 + ], + "duration": 0.0010592537251772876, + "params": { + "nbar": 3.5, + "gate_duration_s": 0.0010592537251772876 + } + }, + { + "pauli_probabilities": [ + 0.3050499695737321, + 0.19495003042626796, + 0.19495003042626796, + 0.30504996957373204 + ], + "duration": 0.0010592537251772876, + "params": { + "nbar": 4.0, + "gate_duration_s": 0.0010592537251772876 + } + }, + { + "pauli_probabilities": [ + 0.3165127568363961, + 0.18348724316360385, + 0.18348724316360385, + 0.3165127568363961 + ], + "duration": 0.0010592537251772876, + "params": { + "nbar": 4.5, + "gate_duration_s": 0.0010592537251772876 + } + }, + { + "pauli_probabilities": [ + 0.3270544515047813, + 0.17294554849521876, + 0.17294554849521876, + 0.32705445150478124 + ], + "duration": 0.0010592537251772876, + "params": { + "nbar": 5.0, + "gate_duration_s": 0.0010592537251772876 + } + }, + { + "pauli_probabilities": [ + 0.3319784982669618, + 0.16802150173303818, + 0.16802150173303818, + 0.3319784982669618 + ], + "duration": 0.0010592537251772876, + "params": { + "nbar": 5.3, + "gate_duration_s": 0.0010592537251772876 + } + }, + { + "pauli_probabilities": [ + 0.335756137695409, + 0.164243862304591, + 0.164243862304591, + 0.335756137695409 + ], + "duration": 0.0010592537251772876, + "params": { + "nbar": 5.8, + "gate_duration_s": 0.0010592537251772876 + } + }, + { + "pauli_probabilities": [ + 0.34116288452008603, + 0.15883711547991394, + 0.15883711547991394, + 0.34116288452008603 + ], + "duration": 0.0010592537251772876, + "params": { + "nbar": 6.4, + "gate_duration_s": 0.0010592537251772876 + } + }, + { + "pauli_probabilities": [ + 0.34544049706171265, + 0.15455950293828744, + 0.15455950293828744, + 0.34544049706171254 + ], + "duration": 0.0010592537251772876, + "params": { + "nbar": 7.1, + "gate_duration_s": 0.0010592537251772876 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.0023263050671536237, + "params": { + "nbar": 0.8, + "gate_duration_s": 0.0023263050671536237 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.0023263050671536237, + "params": { + "nbar": 1.0, + "gate_duration_s": 0.0023263050671536237 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.0023263050671536237, + "params": { + "nbar": 1.2, + "gate_duration_s": 0.0023263050671536237 + } + }, + { + "pauli_probabilities": [ + 0.2500000000000009, + 0.24999999999999908, + 0.24999999999999908, + 0.25000000000000094 + ], + "duration": 0.0023263050671536237, + "params": { + "nbar": 1.6, + "gate_duration_s": 0.0023263050671536237 + } + }, + { + "pauli_probabilities": [ + 0.25000000423048707, + 0.249999995769513, + 0.249999995769513, + 0.25000000423048696 + ], + "duration": 0.0023263050671536237, + "params": { + "nbar": 2.0, + "gate_duration_s": 0.0023263050671536237 + } + }, + { + "pauli_probabilities": [ + 0.25000386349811277, + 0.2499961365018872, + 0.2499961365018872, + 0.2500038634981128 + ], + "duration": 0.0023263050671536237, + "params": { + "nbar": 2.4, + "gate_duration_s": 0.0023263050671536237 + } + }, + { + "pauli_probabilities": [ + 0.2501072181959958, + 0.24989278180400426, + 0.24989278180400426, + 0.25010721819599574 + ], + "duration": 0.0023263050671536237, + "params": { + "nbar": 2.6, + "gate_duration_s": 0.0023263050671536237 + } + }, + { + "pauli_probabilities": [ + 0.25196401731868057, + 0.24803598268131943, + 0.24803598268131943, + 0.25196401731868057 + ], + "duration": 0.0023263050671536237, + "params": { + "nbar": 3.2, + "gate_duration_s": 0.0023263050671536237 + } + }, + { + "pauli_probabilities": [ + 0.25517731098147833, + 0.2448226890185217, + 0.2448226890185217, + 0.25517731098147833 + ], + "duration": 0.0023263050671536237, + "params": { + "nbar": 3.5, + "gate_duration_s": 0.0023263050671536237 + } + }, + { + "pauli_probabilities": [ + 0.25900849449321395, + 0.24099150550678605, + 0.24099150550678605, + 0.25900849449321395 + ], + "duration": 0.0023263050671536237, + "params": { + "nbar": 4.0, + "gate_duration_s": 0.0023263050671536237 + } + }, + { + "pauli_probabilities": [ + 0.2636478170248229, + 0.23635218297517707, + 0.23635218297517707, + 0.26364781702482293 + ], + "duration": 0.0023263050671536237, + "params": { + "nbar": 4.5, + "gate_duration_s": 0.0023263050671536237 + } + }, + { + "pauli_probabilities": [ + 0.26885310289032716, + 0.2311468971096729, + 0.2311468971096729, + 0.2688531028903271 + ], + "duration": 0.0023263050671536237, + "params": { + "nbar": 5.0, + "gate_duration_s": 0.0023263050671536237 + } + }, + { + "pauli_probabilities": [ + 0.27160054923495514, + 0.22839945076504486, + 0.22839945076504486, + 0.27160054923495514 + ], + "duration": 0.0023263050671536237, + "params": { + "nbar": 5.3, + "gate_duration_s": 0.0023263050671536237 + } + }, + { + "pauli_probabilities": [ + 0.27384698560758125, + 0.22615301439241878, + 0.22615301439241878, + 0.2738469856075812 + ], + "duration": 0.0023263050671536237, + "params": { + "nbar": 5.8, + "gate_duration_s": 0.0023263050671536237 + } + }, + { + "pauli_probabilities": [ + 0.27727395677189515, + 0.22272604322810477, + 0.22272604322810477, + 0.27727395677189526 + ], + "duration": 0.0023263050671536237, + "params": { + "nbar": 6.4, + "gate_duration_s": 0.0023263050671536237 + } + }, + { + "pauli_probabilities": [ + 0.28016366726879505, + 0.2198363327312049, + 0.2198363327312049, + 0.2801636672687951 + ], + "duration": 0.0023263050671536237, + "params": { + "nbar": 7.1, + "gate_duration_s": 0.0023263050671536237 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.005108969774506924, + "params": { + "nbar": 0.8, + "gate_duration_s": 0.005108969774506924 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.005108969774506924, + "params": { + "nbar": 1.0, + "gate_duration_s": 0.005108969774506924 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.005108969774506924, + "params": { + "nbar": 1.2, + "gate_duration_s": 0.005108969774506924 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.005108969774506924, + "params": { + "nbar": 1.6, + "gate_duration_s": 0.005108969774506924 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.005108969774506924, + "params": { + "nbar": 2.0, + "gate_duration_s": 0.005108969774506924 + } + }, + { + "pauli_probabilities": [ + 0.2500000000067957, + 0.24999999999320424, + 0.24999999999320424, + 0.2500000000067958 + ], + "duration": 0.005108969774506924, + "params": { + "nbar": 2.4, + "gate_duration_s": 0.005108969774506924 + } + }, + { + "pauli_probabilities": [ + 0.2500000100449722, + 0.24999998995502784, + 0.24999998995502784, + 0.2500000100449722 + ], + "duration": 0.005108969774506924, + "params": { + "nbar": 2.6, + "gate_duration_s": 0.005108969774506924 + } + }, + { + "pauli_probabilities": [ + 0.2500059627343929, + 0.2499940372656071, + 0.2499940372656071, + 0.2500059627343929 + ], + "duration": 0.005108969774506924, + "params": { + "nbar": 3.2, + "gate_duration_s": 0.005108969774506924 + } + }, + { + "pauli_probabilities": [ + 0.25005011230429597, + 0.2499498876957041, + 0.2499498876957041, + 0.2500501123042959 + ], + "duration": 0.005108969774506924, + "params": { + "nbar": 3.5, + "gate_duration_s": 0.005108969774506924 + } + }, + { + "pauli_probabilities": [ + 0.25016913343296165, + 0.24983086656703835, + 0.24983086656703835, + 0.25016913343296165 + ], + "duration": 0.005108969774506924, + "params": { + "nbar": 4.0, + "gate_duration_s": 0.005108969774506924 + } + }, + { + "pauli_probabilities": [ + 0.25042115628105655, + 0.2495788437189434, + 0.2495788437189434, + 0.2504211562810566 + ], + "duration": 0.005108969774506924, + "params": { + "nbar": 4.5, + "gate_duration_s": 0.005108969774506924 + } + }, + { + "pauli_probabilities": [ + 0.25085626774552194, + 0.249143732254478, + 0.249143732254478, + 0.250856267745522 + ], + "duration": 0.005108969774506924, + "params": { + "nbar": 5.0, + "gate_duration_s": 0.005108969774506924 + } + }, + { + "pauli_probabilities": [ + 0.25115441993533383, + 0.24884558006466614, + 0.24884558006466614, + 0.2511544199353339 + ], + "duration": 0.005108969774506924, + "params": { + "nbar": 5.3, + "gate_duration_s": 0.005108969774506924 + } + }, + { + "pauli_probabilities": [ + 0.251434599029274, + 0.24856540097072596, + 0.24856540097072596, + 0.25143459902927406 + ], + "duration": 0.005108969774506924, + "params": { + "nbar": 5.8, + "gate_duration_s": 0.005108969774506924 + } + }, + { + "pauli_probabilities": [ + 0.2519266358870941, + 0.24807336411290595, + 0.24807336411290595, + 0.251926635887094 + ], + "duration": 0.005108969774506924, + "params": { + "nbar": 6.4, + "gate_duration_s": 0.005108969774506924 + } + }, + { + "pauli_probabilities": [ + 0.25240354069805515, + 0.2475964593019449, + 0.2475964593019449, + 0.2524035406980551 + ], + "duration": 0.005108969774506924, + "params": { + "nbar": 7.1, + "gate_duration_s": 0.005108969774506924 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.01122018454301963, + "params": { + "nbar": 0.8, + "gate_duration_s": 0.01122018454301963 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.01122018454301963, + "params": { + "nbar": 1.0, + "gate_duration_s": 0.01122018454301963 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.01122018454301963, + "params": { + "nbar": 1.2, + "gate_duration_s": 0.01122018454301963 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.01122018454301963, + "params": { + "nbar": 1.6, + "gate_duration_s": 0.01122018454301963 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.01122018454301963, + "params": { + "nbar": 2.0, + "gate_duration_s": 0.01122018454301963 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.01122018454301963, + "params": { + "nbar": 2.4, + "gate_duration_s": 0.01122018454301963 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.24999999999999997, + 0.24999999999999997, + 0.25 + ], + "duration": 0.01122018454301963, + "params": { + "nbar": 2.6, + "gate_duration_s": 0.01122018454301963 + } + }, + { + "pauli_probabilities": [ + 0.25000000001762546, + 0.24999999998237457, + 0.24999999998237457, + 0.2500000000176254 + ], + "duration": 0.01122018454301963, + "params": { + "nbar": 3.2, + "gate_duration_s": 0.01122018454301963 + } + }, + { + "pauli_probabilities": [ + 0.2500000018901646, + 0.24999999810983542, + 0.24999999810983542, + 0.2500000018901646 + ], + "duration": 0.01122018454301963, + "params": { + "nbar": 3.5, + "gate_duration_s": 0.01122018454301963 + } + }, + { + "pauli_probabilities": [ + 0.2500000273341385, + 0.24999997266586152, + 0.24999997266586152, + 0.25000002733413845 + ], + "duration": 0.01122018454301963, + "params": { + "nbar": 4.0, + "gate_duration_s": 0.01122018454301963 + } + }, + { + "pauli_probabilities": [ + 0.2500002027027859, + 0.24999979729721417, + 0.24999979729721417, + 0.25000020270278583 + ], + "duration": 0.01122018454301963, + "params": { + "nbar": 4.5, + "gate_duration_s": 0.01122018454301963 + } + }, + { + "pauli_probabilities": [ + 0.2500009630446356, + 0.24999903695536435, + 0.24999903695536435, + 0.25000096304463565 + ], + "duration": 0.01122018454301963, + "params": { + "nbar": 5.0, + "gate_duration_s": 0.01122018454301963 + } + }, + { + "pauli_probabilities": [ + 0.2500018561336199, + 0.2499981438663801, + 0.2499981438663801, + 0.25000185613361986 + ], + "duration": 0.01122018454301963, + "params": { + "nbar": 5.3, + "gate_duration_s": 0.01122018454301963 + } + }, + { + "pauli_probabilities": [ + 0.25000299126524395, + 0.249997008734756, + 0.249997008734756, + 0.250002991265244 + ], + "duration": 0.01122018454301963, + "params": { + "nbar": 5.8, + "gate_duration_s": 0.01122018454301963 + } + }, + { + "pauli_probabilities": [ + 0.2500057163252256, + 0.24999428367477433, + 0.24999428367477433, + 0.25000571632522567 + ], + "duration": 0.01122018454301963, + "params": { + "nbar": 6.4, + "gate_duration_s": 0.01122018454301963 + } + }, + { + "pauli_probabilities": [ + 0.25000929102081937, + 0.24999070897918066, + 0.24999070897918066, + 0.2500092910208193 + ], + "duration": 0.01122018454301963, + "params": { + "nbar": 7.1, + "gate_duration_s": 0.01122018454301963 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.02464147308281276, + "params": { + "nbar": 0.8, + "gate_duration_s": 0.02464147308281276 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.02464147308281276, + "params": { + "nbar": 1.0, + "gate_duration_s": 0.02464147308281276 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.02464147308281276, + "params": { + "nbar": 1.2, + "gate_duration_s": 0.02464147308281276 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.02464147308281276, + "params": { + "nbar": 1.6, + "gate_duration_s": 0.02464147308281276 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.02464147308281276, + "params": { + "nbar": 2.0, + "gate_duration_s": 0.02464147308281276 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.02464147308281276, + "params": { + "nbar": 2.4, + "gate_duration_s": 0.02464147308281276 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.02464147308281276, + "params": { + "nbar": 2.6, + "gate_duration_s": 0.02464147308281276 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.02464147308281276, + "params": { + "nbar": 3.2, + "gate_duration_s": 0.02464147308281276 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.02464147308281276, + "params": { + "nbar": 3.5, + "gate_duration_s": 0.02464147308281276 + } + }, + { + "pauli_probabilities": [ + 0.2500000000000002, + 0.24999999999999986, + 0.24999999999999986, + 0.2500000000000001 + ], + "duration": 0.02464147308281276, + "params": { + "nbar": 4.0, + "gate_duration_s": 0.02464147308281276 + } + }, + { + "pauli_probabilities": [ + 0.25000000000001044, + 0.2499999999999895, + 0.2499999999999895, + 0.2500000000000105 + ], + "duration": 0.02464147308281276, + "params": { + "nbar": 4.5, + "gate_duration_s": 0.02464147308281276 + } + }, + { + "pauli_probabilities": [ + 0.2500000000003215, + 0.24999999999967848, + 0.24999999999967848, + 0.2500000000003215 + ], + "duration": 0.02464147308281276, + "params": { + "nbar": 5.0, + "gate_duration_s": 0.02464147308281276 + } + }, + { + "pauli_probabilities": [ + 0.25000000000135847, + 0.24999999999864156, + 0.24999999999864156, + 0.2500000000013584 + ], + "duration": 0.02464147308281276, + "params": { + "nbar": 5.3, + "gate_duration_s": 0.02464147308281276 + } + }, + { + "pauli_probabilities": [ + 0.25000000000387423, + 0.24999999999612577, + 0.24999999999612577, + 0.25000000000387423 + ], + "duration": 0.02464147308281276, + "params": { + "nbar": 5.8, + "gate_duration_s": 0.02464147308281276 + } + }, + { + "pauli_probabilities": [ + 0.25000000001606526, + 0.24999999998393477, + 0.24999999998393477, + 0.2500000000160652 + ], + "duration": 0.02464147308281276, + "params": { + "nbar": 6.4, + "gate_duration_s": 0.02464147308281276 + } + }, + { + "pauli_probabilities": [ + 0.2500000000466833, + 0.24999999995331665, + 0.24999999995331665, + 0.2500000000466833 + ], + "duration": 0.02464147308281276, + "params": { + "nbar": 7.1, + "gate_duration_s": 0.02464147308281276 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.054116952654646264, + "params": { + "nbar": 0.8, + "gate_duration_s": 0.054116952654646264 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.054116952654646264, + "params": { + "nbar": 1.0, + "gate_duration_s": 0.054116952654646264 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.054116952654646264, + "params": { + "nbar": 1.2, + "gate_duration_s": 0.054116952654646264 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.054116952654646264, + "params": { + "nbar": 1.6, + "gate_duration_s": 0.054116952654646264 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.054116952654646264, + "params": { + "nbar": 2.0, + "gate_duration_s": 0.054116952654646264 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.054116952654646264, + "params": { + "nbar": 2.4, + "gate_duration_s": 0.054116952654646264 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.054116952654646264, + "params": { + "nbar": 2.6, + "gate_duration_s": 0.054116952654646264 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.054116952654646264, + "params": { + "nbar": 3.2, + "gate_duration_s": 0.054116952654646264 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.054116952654646264, + "params": { + "nbar": 3.5, + "gate_duration_s": 0.054116952654646264 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.054116952654646264, + "params": { + "nbar": 4.0, + "gate_duration_s": 0.054116952654646264 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.054116952654646264, + "params": { + "nbar": 4.5, + "gate_duration_s": 0.054116952654646264 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.054116952654646264, + "params": { + "nbar": 5.0, + "gate_duration_s": 0.054116952654646264 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.054116952654646264, + "params": { + "nbar": 5.3, + "gate_duration_s": 0.054116952654646264 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.054116952654646264, + "params": { + "nbar": 5.8, + "gate_duration_s": 0.054116952654646264 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.054116952654646264, + "params": { + "nbar": 6.4, + "gate_duration_s": 0.054116952654646264 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.054116952654646264, + "params": { + "nbar": 7.1, + "gate_duration_s": 0.054116952654646264 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.11885022274370165, + "params": { + "nbar": 0.8, + "gate_duration_s": 0.11885022274370165 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.11885022274370165, + "params": { + "nbar": 1.0, + "gate_duration_s": 0.11885022274370165 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.11885022274370165, + "params": { + "nbar": 1.2, + "gate_duration_s": 0.11885022274370165 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.11885022274370165, + "params": { + "nbar": 1.6, + "gate_duration_s": 0.11885022274370165 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.11885022274370165, + "params": { + "nbar": 2.0, + "gate_duration_s": 0.11885022274370165 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.11885022274370165, + "params": { + "nbar": 2.4, + "gate_duration_s": 0.11885022274370165 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.11885022274370165, + "params": { + "nbar": 2.6, + "gate_duration_s": 0.11885022274370165 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.11885022274370165, + "params": { + "nbar": 3.2, + "gate_duration_s": 0.11885022274370165 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.11885022274370165, + "params": { + "nbar": 3.5, + "gate_duration_s": 0.11885022274370165 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.11885022274370165, + "params": { + "nbar": 4.0, + "gate_duration_s": 0.11885022274370165 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.11885022274370165, + "params": { + "nbar": 4.5, + "gate_duration_s": 0.11885022274370165 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.11885022274370165, + "params": { + "nbar": 5.0, + "gate_duration_s": 0.11885022274370165 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.11885022274370165, + "params": { + "nbar": 5.3, + "gate_duration_s": 0.11885022274370165 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.11885022274370165, + "params": { + "nbar": 5.8, + "gate_duration_s": 0.11885022274370165 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.11885022274370165, + "params": { + "nbar": 6.4, + "gate_duration_s": 0.11885022274370165 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.11885022274370165, + "params": { + "nbar": 7.1, + "gate_duration_s": 0.11885022274370165 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.2610157215682533, + "params": { + "nbar": 0.8, + "gate_duration_s": 0.2610157215682533 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.2610157215682533, + "params": { + "nbar": 1.0, + "gate_duration_s": 0.2610157215682533 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.2610157215682533, + "params": { + "nbar": 1.2, + "gate_duration_s": 0.2610157215682533 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.2610157215682533, + "params": { + "nbar": 1.6, + "gate_duration_s": 0.2610157215682533 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.2610157215682533, + "params": { + "nbar": 2.0, + "gate_duration_s": 0.2610157215682533 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.2610157215682533, + "params": { + "nbar": 2.4, + "gate_duration_s": 0.2610157215682533 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.2610157215682533, + "params": { + "nbar": 2.6, + "gate_duration_s": 0.2610157215682533 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.2610157215682533, + "params": { + "nbar": 3.2, + "gate_duration_s": 0.2610157215682533 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.2610157215682533, + "params": { + "nbar": 3.5, + "gate_duration_s": 0.2610157215682533 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.2610157215682533, + "params": { + "nbar": 4.0, + "gate_duration_s": 0.2610157215682533 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.2610157215682533, + "params": { + "nbar": 4.5, + "gate_duration_s": 0.2610157215682533 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.2610157215682533, + "params": { + "nbar": 5.0, + "gate_duration_s": 0.2610157215682533 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.2610157215682533, + "params": { + "nbar": 5.3, + "gate_duration_s": 0.2610157215682533 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.2610157215682533, + "params": { + "nbar": 5.8, + "gate_duration_s": 0.2610157215682533 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.2610157215682533, + "params": { + "nbar": 6.4, + "gate_duration_s": 0.2610157215682533 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.2610157215682533, + "params": { + "nbar": 7.1, + "gate_duration_s": 0.2610157215682533 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.5732358369467707, + "params": { + "nbar": 0.8, + "gate_duration_s": 0.5732358369467707 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.5732358369467707, + "params": { + "nbar": 1.0, + "gate_duration_s": 0.5732358369467707 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.5732358369467707, + "params": { + "nbar": 1.2, + "gate_duration_s": 0.5732358369467707 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.5732358369467707, + "params": { + "nbar": 1.6, + "gate_duration_s": 0.5732358369467707 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.5732358369467707, + "params": { + "nbar": 2.0, + "gate_duration_s": 0.5732358369467707 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.5732358369467707, + "params": { + "nbar": 2.4, + "gate_duration_s": 0.5732358369467707 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.5732358369467707, + "params": { + "nbar": 2.6, + "gate_duration_s": 0.5732358369467707 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.5732358369467707, + "params": { + "nbar": 3.2, + "gate_duration_s": 0.5732358369467707 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.5732358369467707, + "params": { + "nbar": 3.5, + "gate_duration_s": 0.5732358369467707 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.5732358369467707, + "params": { + "nbar": 4.0, + "gate_duration_s": 0.5732358369467707 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.5732358369467707, + "params": { + "nbar": 4.5, + "gate_duration_s": 0.5732358369467707 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.5732358369467707, + "params": { + "nbar": 5.0, + "gate_duration_s": 0.5732358369467707 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.5732358369467707, + "params": { + "nbar": 5.3, + "gate_duration_s": 0.5732358369467707 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.5732358369467707, + "params": { + "nbar": 5.8, + "gate_duration_s": 0.5732358369467707 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.5732358369467707, + "params": { + "nbar": 6.4, + "gate_duration_s": 0.5732358369467707 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 0.5732358369467707, + "params": { + "nbar": 7.1, + "gate_duration_s": 0.5732358369467707 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 1.2589254117941673, + "params": { + "nbar": 0.8, + "gate_duration_s": 1.2589254117941673 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 1.2589254117941673, + "params": { + "nbar": 1.0, + "gate_duration_s": 1.2589254117941673 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 1.2589254117941673, + "params": { + "nbar": 1.2, + "gate_duration_s": 1.2589254117941673 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 1.2589254117941673, + "params": { + "nbar": 1.6, + "gate_duration_s": 1.2589254117941673 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 1.2589254117941673, + "params": { + "nbar": 2.0, + "gate_duration_s": 1.2589254117941673 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 1.2589254117941673, + "params": { + "nbar": 2.4, + "gate_duration_s": 1.2589254117941673 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 1.2589254117941673, + "params": { + "nbar": 2.6, + "gate_duration_s": 1.2589254117941673 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 1.2589254117941673, + "params": { + "nbar": 3.2, + "gate_duration_s": 1.2589254117941673 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 1.2589254117941673, + "params": { + "nbar": 3.5, + "gate_duration_s": 1.2589254117941673 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 1.2589254117941673, + "params": { + "nbar": 4.0, + "gate_duration_s": 1.2589254117941673 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 1.2589254117941673, + "params": { + "nbar": 4.5, + "gate_duration_s": 1.2589254117941673 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 1.2589254117941673, + "params": { + "nbar": 5.0, + "gate_duration_s": 1.2589254117941673 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 1.2589254117941673, + "params": { + "nbar": 5.3, + "gate_duration_s": 1.2589254117941673 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 1.2589254117941673, + "params": { + "nbar": 5.8, + "gate_duration_s": 1.2589254117941673 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 1.2589254117941673, + "params": { + "nbar": 6.4, + "gate_duration_s": 1.2589254117941673 + } + }, + { + "pauli_probabilities": [ + 0.25, + 0.25, + 0.25, + 0.25 + ], + "duration": 1.2589254117941673, + "params": { + "nbar": 7.1, + "gate_duration_s": 1.2589254117941673 + } + } + ] + }, + { + "name": "mz", + "qubits": [ + [ + 0 + ] + ], + "free_params": [], + "fixed_params": {}, + "interpolation_points": [ + { + "duration": 0.0, + "params": {} + } + ], + "readout_errors": [ + 0.02, + 0.06 + ] + }, + { + "name": "mx", + "qubits": [ + [ + 0 + ] + ], + "free_params": [], + "fixed_params": {}, + "interpolation_points": [ + { + "duration": 0.0, + "params": {} + } + ] + }, + { + "name": "p0", + "qubits": [ + [ + 0 + ] + ], + "free_params": [], + "fixed_params": {}, + "interpolation_points": [ + { + "duration": 0.0, + "params": {} + } + ] + }, + { + "name": "p1", + "qubits": [ + [ + 0 + ] + ], + "free_params": [], + "fixed_params": {}, + "interpolation_points": [ + { + "duration": 0.0, + "params": {} + } + ] + }, + { + "name": "p+", + "qubits": [ + [ + 0 + ] + ], + "free_params": [], + "fixed_params": {}, + "interpolation_points": [ + { + "duration": 0.0, + "params": {} + } + ] + }, + { + "name": "p-", + "qubits": [ + [ + 0 + ] + ], + "free_params": [], + "fixed_params": {}, + "interpolation_points": [ + { + "duration": 0.0, + "params": {} + } + ] + } + ] +} diff --git a/qiskit_alice_bob_provider/local/target.py b/qiskit_alice_bob_provider/local/target.py new file mode 100644 index 0000000..80f5604 --- /dev/null +++ b/qiskit_alice_bob_provider/local/target.py @@ -0,0 +1,97 @@ +############################################################################## +# Copyright 2023 Alice & Bob +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +############################################################################## + +from typing import Dict, List, Tuple + +from qiskit.circuit import Instruction +from qiskit.transpiler import Target + +from ..processor.description import ProcessorDescription +from .instruction_durations import ProcessorInstructionDurations +from .proc_to_qiskit import processor_to_qiskit_instruction + + +def processor_to_target(processor: ProcessorDescription) -> Target: + """Create a Qiskit Target from a ProcessorDescription + + A ProcessorDescription is the description of the properties of a quantum + processor. In this regard, a processor has the same function as a Qiskit + Target. + + Please note that the Qiskit target produced by this function does not fully + represent the array of operations available on the processor. + + This is because, contrary to what is advertised in the Target documentation + at https://qiskit.org/documentation/stubs/qiskit.transpiler.Target.html, + the Qiskit transpiler expects the names of instructions in a Target to be + listed under their Qiskit operation names. Otherwise they won't be taken + into account and used by some transpilation passes who have a basis_gates + argument like UnrollCustomDefinitions. + + This is not a problem for scheduling because durations are obtained from + the richer ProcessorInstructionDurations class which derives from + InstructionDurations. + This might be an issue for other types of transpilation passes. + + Here's a concrete example of this loss of information: + + If an Alice & Bob processor implements the following instructions: + * p0, which translates to Initialize(0) + * p+, which translates to Initialize (+) + * rz, which translates to RzGate(Parameter('angle')) + * rzpio2, which translates to RzGate(np.pi/2) + + Then the corresponding Qiskit Target will contain the following + instructions: + * 'initialize' --> Initialize(0) + * 'rz' --> RzGate(Parameter('angle')) + + This loss of information cannot be avoided because Qiskit identifies + instructions by their names for simplicity. + + The last instruction (rzpio2) is a made-up example for the sake of clarity. + """ + target = Target(dt=processor.clock_cycle) + + # qiskit name -> supported qubit combinations + qubits: Dict[str, List[Tuple[int, ...]]] = {} + + # Qiskit name -> a given Qiskit implementation of this instruction + # As a consequence, if two proc instructions are implemented using the same + # Qiskit implementation, they will conflict here. This is not an issue + # though, because the Qiskit Target's instructions are only used for + # gate basis conversion. + example_instructions: Dict[str, Instruction] = {} + + for instruction in processor.all_instructions(): + qiskit_instr = processor_to_qiskit_instruction(instruction) + name = qiskit_instr.name + example_instructions[name] = qiskit_instr + if name not in qubits: + qubits[name] = [] + qubits[name].append(instruction.qubits) + + for name, qiskit_instr in example_instructions.items(): + properties = {qbts: None for qbts in qubits[name]} + target.add_instruction( + instruction=qiskit_instr, + properties=properties, + name=qiskit_instr.name, + ) + target._instruction_durations = ( # pylint: disable=protected-access + ProcessorInstructionDurations(processor=processor) + ) + return target diff --git a/qiskit_alice_bob_provider/local/translation_plugin.py b/qiskit_alice_bob_provider/local/translation_plugin.py new file mode 100644 index 0000000..cff55f3 --- /dev/null +++ b/qiskit_alice_bob_provider/local/translation_plugin.py @@ -0,0 +1,167 @@ +############################################################################## +# Copyright 2023 Alice & Bob +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +############################################################################## + +import numpy as np +from qiskit.dagcircuit import DAGCircuit +from qiskit.extensions.quantum_initializer import Initialize +from qiskit.transpiler import ( + PassManager, + PassManagerConfig, + TransformationPass, + TranspilerError, +) +from qiskit.transpiler.preset_passmanagers.common import ( + generate_translation_passmanager, +) +from qiskit.transpiler.preset_passmanagers.plugin import PassManagerStagePlugin + +from ..ensure_preparation_pass import EnsurePreparationPass + + +class IntToLabelInitializePass(TransformationPass): + """ + A transpilation pass that transforms intializations using integers into + intializations using labels. + + Example: + ``` + circ = QuantumCircuit(2) + circ.initialize(2) + transpiled = pm.run(circ) + print(circ) + # ┌────────────────┐ + # q_0: ┤0 ├ + # │ Initialize(2) │ + # q_1: ┤1 ├ + # └────────────────┘ + print(transpiled) + # ┌──────────────────┐ + # q_0: ┤0 ├ + # │ Initialize(1,0) │ + # q_1: ┤1 ├ + # └──────────────────┘ + ``` + """ + + def run(self, dag: DAGCircuit) -> DAGCircuit: + for node in dag.topological_op_nodes(): + if node.name != 'initialize': + continue + assert isinstance(node.op, Initialize) + params = node.op.params + if len(params) > 1: + if isinstance(params[0], str): + continue + raise TranspilerError( + 'State vectors are not supported as input of initialize' + f' (params are {params}). Please use string labels like' + ' Initialize("+")' + ) + assert len(params) == 1 + if not isinstance(params[0], (int, float, complex)): + continue + integer_state = int(np.real(params[0])) + label_state = f'{integer_state:0{int(node.op.num_qubits)}b}' + dag.substitute_node( + node, + Initialize(label_state), + ) + return dag + + +class BreakDownInitializePass(TransformationPass): + """ + A transpilation pass that transforms label, multi-qubit initializations + into label, single-qubit initializations. + + Example: + ``` + circ = QuantumCircuit(2) + circ.initialize('10') + transpiled = pm.run(circ) + print(circ) + # ┌──────────────────┐ + # q_0: ┤0 ├ + # │ Initialize(1,0) │ + # q_1: ┤1 ├ + # └──────────────────┘ + print(transpiled) + # ┌───────────────┐ + # q_0: ┤ Initialize(0) ├ + # ├───────────────┤ + # q_1: ┤ Initialize(1) ├ + # └───────────────┘ + ``` + """ + + def run(self, dag: DAGCircuit) -> DAGCircuit: + for node in dag.topological_op_nodes(): + if node.name != 'initialize': + continue + assert isinstance(node.op, Initialize) + params = node.op.params + assert len(params) > 0 + if not isinstance(params[0], str): + raise TranspilerError( + 'At this stage in the transpilation process, only label' + f' initializations should exist (params are {params})' + ) + new_dag = DAGCircuit() + new_dag.add_qubits(node.qargs) + new_dag.add_clbits(node.cargs) + for index, state in enumerate(params[::-1]): + new_dag.apply_operation_back( + Initialize(state), qargs=(node.qargs[index],) + ) + dag.substitute_node_with_dag(node, new_dag) + return dag + + +class LocalStatePreparationPlugin(PassManagerStagePlugin): + """A pass manager meant to be used as a translation plugin that ensures + all qubits are initialized with a known state among 0, 1, +, -. + """ + + def pass_manager( + self, + pass_manager_config: PassManagerConfig, + optimization_level=None, + ) -> PassManager: + custom_pm = PassManager() + custom_pm.append(EnsurePreparationPass(lambda: Initialize('0'))) + custom_pm.append(IntToLabelInitializePass()) + custom_pm.append(BreakDownInitializePass()) + + default_pm = generate_translation_passmanager( + target=pass_manager_config.target, + basis_gates=pass_manager_config.basis_gates, + method='translator', + approximation_degree=pass_manager_config.approximation_degree, + coupling_map=pass_manager_config.coupling_map, + backend_props=pass_manager_config.backend_properties, + unitary_synthesis_method=( + pass_manager_config.unitary_synthesis_method + ), + unitary_synthesis_plugin_config=( + pass_manager_config.unitary_synthesis_plugin_config + ), + hls_config=pass_manager_config.hls_config, + ) + for passes in default_pm.passes(): + for p in passes.values(): + custom_pm.append(p) + + return custom_pm diff --git a/qiskit_alice_bob_provider/processor/__init__.py b/qiskit_alice_bob_provider/processor/__init__.py new file mode 100644 index 0000000..2c2e1e5 --- /dev/null +++ b/qiskit_alice_bob_provider/processor/__init__.py @@ -0,0 +1,26 @@ +############################################################################## +# Copyright 2023 Alice & Bob +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +############################################################################## + +"""This module contains the ProcessorDescription, an interface to represent +the behavior of a quantum processor (QPU) at the gate level. + +This interface does not depend on Qiskit, and thus could be used to provide +information about a QPU to another quantum computing framework. + +Additionally, this interface is finer-grained than a Qiskit target, since it +can represent instructions with noise and duration continuously dependent on +the instruction parameters. +""" diff --git a/qiskit_alice_bob_provider/processor/description.py b/qiskit_alice_bob_provider/processor/description.py new file mode 100644 index 0000000..ac8e87a --- /dev/null +++ b/qiskit_alice_bob_provider/processor/description.py @@ -0,0 +1,109 @@ +############################################################################## +# Copyright 2023 Alice & Bob +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +############################################################################## + +from abc import ABC, abstractmethod +from dataclasses import dataclass +from typing import Iterator, List, Optional, Tuple + +import numpy as np + + +@dataclass +class InstructionProperties: + """The description of an instruction available on the processor.""" + + # The name and identifier of the instruction type + name: str + + # The qubits on which this instruction can be applied. + # The combination (name, qubits) completely identifies the instruction. + qubits: Tuple[int, ...] + + # The names of the parameters of the instruction + params: List[str] + + # The readout assignment errors of a measurement instruction. + # A value of [0.01, 0.02] is understood as P(read 1 | qubit in 0) = 0.01 + # and P(read 0 | qubit in 1) = 0.02. + # Use this attribute when the readout errors are independent of the + # instruction params. If param-dependent readout errors are found in + # AppliedInstruction, they should take precedence. + readout_errors: Optional[List[float]] = None + + +@dataclass +class AppliedInstruction: + """The behavior of the instruction when applied with a given set of + parameters.""" + + # The duration of the instruction. Always in seconds. + duration: float + + # The quantum noise of the instruction represented as a quantum process + # tomography chi matrix. Refer to + # https://qiskit.org/documentation/stubs/qiskit.quantum_info.Chi.html + quantum_errors: Optional[np.ndarray] + + # The readout assignment errors of a measurement instruction. + # A value of [0.01, 0.02] is understood as P(read 1 | qubit in 0) = 0.01 + # and P(read 0 | qubit in 1) = 0.02. + # Use this attribute when the readout errors depend on the + # instruction params. They should take precedence over param-independent + # readout errors found in InstructionProperties. + readout_errors: Optional[List[float]] + + +class ProcessorDescription(ABC): + """An interface to represent the behavior of a quantum processor (QPU) at + the gate level. + + This interface does not depend on Qiskit, and thus could be used to provide + information about a QPU to another quantum computing framework. + + Additionally, this interface is finer-grained than a Qiskit Target, since + it can represent instructions with noise and duration continuously + dependent on the instruction parameters. + """ + + @abstractmethod + def all_instructions(self) -> Iterator[InstructionProperties]: + """Return all instructions available on the processor. + + If an instruction is available on multiple qubit combinations, it will + be listed once per qubit combination. + """ + + @abstractmethod + def apply_instruction( + self, name: str, qubits: Tuple[int, ...], params: List[float] + ) -> AppliedInstruction: + """For a given instruction, return the instruction duration and noise. + + If the instruction is not found (as represented by the combination of + an instruction name and a tuple of qubits), the call will raise an + exception. + """ + + # The clock cycle duration in the same time unit as other durations + # in the ProcessorDescription (usually seconds). + # + # Note that the ProcessorDescription does not return durations in + # multiples of the clock cyle and accepts durations (e.g., for delay) + # that are not multiples of clock cycle. + # + # If respecting the clock cycle is important, it is up to the user (e.g., + # the Qiskit transpiler) to clip durations to clock cycle multiples. + clock_cycle: float diff --git a/qiskit_alice_bob_provider/processor/interpolated_cat.py b/qiskit_alice_bob_provider/processor/interpolated_cat.py new file mode 100644 index 0000000..d5b9dd9 --- /dev/null +++ b/qiskit_alice_bob_provider/processor/interpolated_cat.py @@ -0,0 +1,82 @@ +############################################################################## +# Copyright 2023 Alice & Bob +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +############################################################################## + +from typing import Dict, Iterator, List, Tuple + +import numpy as np + +from qiskit_alice_bob_provider.processor.description import ( + AppliedInstruction, + InstructionProperties, +) + +from .description import ProcessorDescription +from .serialization.interpolate import InterpolatedProcessor +from .serialization.model import SerializedInstruction, SerializedProcessor + + +class InterpolatedCatProcessor(ProcessorDescription): + """A type of processor description built from a serialized representation + of the processor behavior. + + Compared to the more generic class ``InterpolatedProcessor``, + ``InterpolatedCatProcessor`` is tailored to cat qubit based processors. + In particular, it automatically injects alpha/nbar before the interpolation + step. + """ + + def __init__( + self, + serialized_processor: SerializedProcessor, + clock_cycle: float = 1e-9, + alpha: float = 2, + ) -> None: + self._interpolated_processor = InterpolatedProcessor( + serialized_processor, clock_cycle=clock_cycle + ) + self.clock_cycle = clock_cycle + self._alpha = alpha + self._instructions: Dict[ + Tuple[str, Tuple[int, ...]], SerializedInstruction + ] = {} + for instr in serialized_processor.instructions: + for qubits in instr.qubits: + self._instructions[(instr.name, tuple(qubits))] = instr + + def all_instructions(self) -> Iterator[InstructionProperties]: + for instr in self._interpolated_processor.all_instructions(): + yield InstructionProperties( + name=instr.name, + qubits=instr.qubits, + params=[p for p in instr.params if p != 'nbar'], + readout_errors=instr.readout_errors, + ) + + def apply_instruction( + self, name: str, qubits: Tuple[int, ...], params: List[float] + ) -> AppliedInstruction: + instr = self._instructions[(name, qubits)] + idx = 0 + new_params = [] + for param_name in instr.free_params: + if param_name == 'nbar': + new_params.append(np.abs(self._alpha) ** 2) + else: + new_params.append(params[idx]) + idx += 1 + return self._interpolated_processor.apply_instruction( + name, qubits, new_params + ) diff --git a/qiskit_alice_bob_provider/processor/physical_cat.py b/qiskit_alice_bob_provider/processor/physical_cat.py new file mode 100644 index 0000000..a41cf30 --- /dev/null +++ b/qiskit_alice_bob_provider/processor/physical_cat.py @@ -0,0 +1,285 @@ +############################################################################## +# Copyright 2023 Alice & Bob +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +############################################################################## + +from itertools import product +from typing import Iterator, List, Optional, Tuple + +import numpy as np + +from .description import ( + AppliedInstruction, + InstructionProperties, + ProcessorDescription, +) +from .utils import full_flip_error, pauli_errors_to_chi + + +class PhysicalCatProcessor(ProcessorDescription): + """A description of a quantum processor made of physical cat qubits. + + All cat qubits are assumed to have the same physical properties, entirely + controlled by the following quantities: + * kappa_1 in Hz, the one-photon dissipation rate of the memory + * kappa_2 in Hz, the two-photon dissipation rate of the memory + * alpha (unitless), the amplitude of the cat state or coherent state in the + memory. The average number of photons in the memory is equal to + |alpha|^2. + + Note that on an actual chip, kappa_1 and kappa_2 depend on the architecture + and cannot be changed. The amplitude alpha however can be adjusted by the + operator of the chip. + + The formulas for gate times and error models used in this description are + taken from different sources referenced in the code below. + """ + + def __init__( # pylint: disable=too-many-arguments + self, + n_qubits: int = 5, + kappa_1: float = 100, + kappa_2: float = 10_000_000, + alpha: float = 4, + clock_cycle: float = 1e-9, + coupling_map: Optional[List[Tuple[int, int]]] = None, + ): + self._n_qubits = n_qubits + if alpha < 2.0: + raise ValueError( + 'The amplitude alpha should be a float between 2.0 and 20.0' + ) + if kappa_1 < 10: + raise ValueError( + 'The one-photon dissipation rate kappa_1 (Hz) should be a' + ' float greater than 10' + ) + if kappa_1 / kappa_2 < 1e-7 or kappa_1 / kappa_2 > 1e-1: + raise ValueError( + 'The ratio kappa_1 / kappa_2 should be between 1e-7 and 1e-1' + ) + self._kappa_1 = kappa_1 + self._kappa_2 = kappa_2 + self._alpha = alpha + self.clock_cycle = clock_cycle + if coupling_map is None: + # All-to-all coupling map + coupling_map = list( + (a, b) + for a, b in product(range(n_qubits), range(n_qubits)) + if a != b + ) + else: + # A basic check of the validity of the coupling map + for a, b in coupling_map: + if a < 0 or b < 0 or a >= n_qubits or b >= n_qubits or a == b: + raise ValueError( + f'Coupling map contains an invalid pair ({a}, {b})' + f' for a processor with {n_qubits} qubits.' + ) + self._coupling_map = coupling_map + + def all_instructions(self) -> Iterator[InstructionProperties]: + for i in range(self._n_qubits): + yield InstructionProperties( + name='delay', params=['duration'], qubits=(i,) + ) + yield InstructionProperties( + name='rz', params=['angle'], qubits=(i,) + ) + for inst in ['x', 'z', 'p0', 'p1', 'p+', 'p-', 'mx', 'mz']: + yield InstructionProperties(name=inst, params=[], qubits=(i,)) + for i, j in self._coupling_map: + yield InstructionProperties(name='cx', params=[], qubits=(i, j)) + + def apply_instruction( + self, name: str, qubits: Tuple[int, ...], params: List[float] + ) -> AppliedInstruction: + if name == 'mx': + duration, errors = _mx_error( + k1=self._kappa_1, k2=self._kappa_2, alpha=self._alpha + ) + elif name == 'mz': + duration, errors = _mz_error(alpha=self._alpha) + elif name == 'delay': + assert len(params) == 1 + duration = params[0] + errors = _idle_error( + k1=self._kappa_1, alpha=self._alpha, t=duration + ) + elif name in ['p+', 'p-']: + duration, errors = _prep_plus_error( + k1=self._kappa_1, k2=self._kappa_2, alpha=self._alpha + ) + elif name in ['p0', 'p1']: + duration, errors = _prep_0_error( + k2=self._kappa_2, alpha=self._alpha + ) + elif name == 'x': + duration, errors = _x_error( + k1=self._kappa_1, k2=self._kappa_2, alpha=self._alpha + ) + elif name == 'rz': + assert len(params) == 1 + duration, errors = _rz_error( + k1=self._kappa_1, + k2=self._kappa_2, + alpha=self._alpha, + theta=params[0], + ) + elif name == 'z': + duration, errors = _rz_error( + k1=self._kappa_1, + k2=self._kappa_2, + alpha=self._alpha, + theta=np.pi, + ) + elif name == 'cx': + duration, errors = _cx_error( + k1=self._kappa_1, k2=self._kappa_2, alpha=self._alpha + ) + else: + raise ValueError(f'Unknown instruction name "{name}"') + try: + quantum_errors = pauli_errors_to_chi(errors) + except ValueError as e: + raise ValueError( + f'The parameters of the processor (alpha={self._alpha}, ' + f'kappa_1={self._kappa_1}, kappa_2={self._kappa_2}) led to ' + f'inconsistent error probabilities for instruction "{name}"' + ) from e + return AppliedInstruction( + duration=duration, + quantum_errors=quantum_errors, + readout_errors=None, + ) + + +def _idle_error(k1, alpha, t): + # [LES-HOUCHES] https://arxiv.org/pdf/2203.03222.pdf + # The prefactor 1.1e-3 was chosen to match the alpha**2=8 point of the blue + # curve in Fig. 7, p. 29: + # The total bitflip probability (px+py) must be 1e-11 for alpha**2=8, + # k1/k2=1e-2, t=1/k2. + alpha_n = np.abs(alpha) + bit_flip = 0.5 * 1.1e-3 * alpha_n**2 * k1 * np.exp(-2 * alpha_n**2) * t + phase_flip = k1 * alpha_n**2 * t + x, y, z = full_flip_error([bit_flip, bit_flip, phase_flip]) + return { + 'X': x, + 'Y': y, + 'Z': z, + } + + +def _prep_plus_error(k1, k2, alpha): + # [AB-SHOR] https://arxiv.org/pdf/2302.06639v1.pdf + # Page 25 + t = 1.0 / k2 + errors = {'Z': np.abs(alpha) ** 2 * k1 * t} + return t, errors + + +def _prep_0_error(k2, alpha): + # [AWS-2022] https://arxiv.org/pdf/2012.04108.pdf + # Table II, p. 17 + alpha_n = np.abs(alpha) + t = 0.1 / k2 / alpha_n**2 + errors = {'X': 0.39 * np.exp(-4 * alpha_n**2)} + return t, errors + + +def _x_error(k1, k2, alpha): + t = 1.0 / k2 + return t, _idle_error(k1, np.abs(alpha), t) + + +def _mx_error(k1, k2, alpha): + # [AB-SHOR] https://arxiv.org/pdf/2302.06639v1.pdf + # Page 25 + t = 1.0 / k2 + errors = { + 'Z': np.abs(alpha) ** 2 * k1 * t, + } + return t, errors + + +def _mz_error(alpha): + # [AWS-2022] https://arxiv.org/pdf/2012.04108.pdf + # Eq. 38, p. 18 + t = 850e-9 + errors = { + 'X': np.exp(-1.5 - 0.9 * np.abs(alpha) ** 2), + } + return t, errors + + +def _rz_error(k1, k2, alpha, theta): + # [JEREMIE] https://hal.science/tel-03509305/document + # p. 65 + # (Careful, there is an error in the formula: it should be |theta| instead + # of sqrt(theta).) + alpha_n = np.abs(alpha) + t = 0.25 * np.abs(theta) / (alpha_n**3 * np.sqrt(k1 * k2)) + x, y, z = full_flip_error( + [ + 0, + 0, + np.abs(theta) / (2 * alpha_n) * np.sqrt(k1 / k2), + ] + ) + errors = { + 'X': x, + 'Y': y, + 'Z': z, + } + return t, errors + + +def _cx_error(k1, k2, alpha): + # [AB-SHOR] https://arxiv.org/pdf/2302.06639v1.pdf + # Page 25 + alpha_n = np.abs(alpha) + t = 1 / k2 + zi_error = alpha_n**2 * k1 * t + np.pi**2 / 64 / alpha_n**2 / k2 / t + zz_error = 0.5 * alpha_n**2 * k1 * t + + # The prefactor 2631 was chosen so that the total probability of bit flip + # is equal to 0.5exp(-2alpha**2) with alpha**2=19 and k1/k2=1e-5. + # This is to match Eq. D8, p. 26. + xi_error = ( + 2631 * alpha_n**2 * k1 * np.exp(-2 * np.abs(alpha_n) ** 2) * t / 6 + ) + + # This is acceptable because this error is 100x smaller than XI. + iy_error = 0 + + errors = { + 'IZ': zi_error, + 'ZZ': zz_error, + 'ZI': zz_error, + 'IX': xi_error, + 'XX': xi_error, + 'XI': xi_error, + 'IY': xi_error, + 'XY': xi_error, + 'XZ': xi_error, + 'YI': iy_error, + 'YY': iy_error, + 'YX': iy_error, + 'ZX': iy_error, + 'ZY': iy_error, + 'YZ': iy_error, + } + return t, errors diff --git a/qiskit_alice_bob_provider/processor/serialization/__init__.py b/qiskit_alice_bob_provider/processor/serialization/__init__.py new file mode 100644 index 0000000..e8abfde --- /dev/null +++ b/qiskit_alice_bob_provider/processor/serialization/__init__.py @@ -0,0 +1,22 @@ +############################################################################## +# Copyright 2023 Alice & Bob +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +############################################################################## + +"""This module contains tools to build a ProcessorDescription from a serialized +representation of a quantum processor. + +Instruction duration and quantum errors are interpolated from the data points +present in the serialized representation. +""" diff --git a/qiskit_alice_bob_provider/processor/serialization/interpolate.py b/qiskit_alice_bob_provider/processor/serialization/interpolate.py new file mode 100644 index 0000000..b81aea6 --- /dev/null +++ b/qiskit_alice_bob_provider/processor/serialization/interpolate.py @@ -0,0 +1,204 @@ +############################################################################## +# Copyright 2023 Alice & Bob +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +############################################################################## + +from enum import Enum +from typing import Callable, Dict, Iterator, List, Optional, Tuple, Union + +import numpy as np +from scipy import interpolate + +from qiskit_alice_bob_provider.processor.description import ( + AppliedInstruction, + InstructionProperties, +) + +from ..description import ProcessorDescription +from .model import SerializedInstruction, SerializedProcessor + +# A function that is the output of an interpolation method. +# In this context, interpolation is used to obtain estimates of quantum +# errors and instruction durations for parameter values that were not in the +# generated simulation data. +# For instance, we may have simulated errors for the values 3 and 4 of nbar. +# This interpolation function will be able to generate an error estimate for +# nbar=3.5. +Interpolator = Callable[[Union[float, List[float], np.ndarray]], np.ndarray] + + +class InterpolatedProcessor(ProcessorDescription): + """A type of processor description built from a serialized representation + of the processor behavior. + """ + + def __init__( + self, + serialized_processor: SerializedProcessor, + clock_cycle: float = 1e-9, + ) -> None: + self.clock_cycle = clock_cycle + self._instructions: Dict[ + Tuple[str, Tuple[int, ...]], SerializedInstruction + ] = {} + self._pauli_interp: Dict[ + Tuple[str, Tuple[int, ...]], Optional[Interpolator] + ] = {} + self._duration_interp: Dict[ + Tuple[str, Tuple[int, ...]], Interpolator + ] = {} + for instr in serialized_processor.instructions: + pauli_interp = _build_interpolator(instr, _InterpolatedField.PAULI) + duration_interp = _build_interpolator( + instr, _InterpolatedField.DURATION + ) + assert duration_interp is not None + for qubits in instr.qubits: + key = (instr.name, tuple(qubits)) + if key in self._instructions: + raise ValueError( + 'An instruction already exist in the serialized' + ' processor model for the combination (instruction =' + f' {instr.name}, qubits = {qubits})' + ) + self._instructions[key] = instr + self._pauli_interp[key] = pauli_interp + self._duration_interp[key] = duration_interp + + def all_instructions(self) -> Iterator[InstructionProperties]: + for (name, qubits), instr in self._instructions.items(): + yield InstructionProperties( + name=name, + qubits=qubits, + params=instr.free_params, + readout_errors=instr.readout_errors, + ) + + def apply_instruction( + self, name: str, qubits: Tuple[int, ...], params: List[float] + ) -> AppliedInstruction: + pauli_interp = self._pauli_interp[(name, qubits)] + duration_interp = self._duration_interp[(name, qubits)] + instr = self._instructions[(name, qubits)] + quantum = ( + None if pauli_interp is None else np.diag(pauli_interp(params)) + ) + return AppliedInstruction( + duration=float(duration_interp(params)[0]), + quantum_errors=quantum, + readout_errors=instr.readout_errors, + ) + + +class InterpolationError(Exception): + """An error happening when the user requested a parameter (rotation angle, + gate duration, nbar) that is outside the range provided by the noise model. + """ + + +class _InterpolatedField(Enum): + PAULI = 'PAULI' + DURATION = 'DURATION' + + +def _build_interpolator( + instruction: SerializedInstruction, field: _InterpolatedField +) -> Optional[Interpolator]: + """From the quantum errors of an instruction, build an interpolator + function able to estimate Pauli error probabilities and the instruction + duration at parameter values not present in the input data. + + This interpolator will raise an error if interpolation was impossible. This + happens if the requested point is outside the convex hull.""" + if len(instruction.free_params) == 0: + point = instruction.interpolation_points[0] + constant = ( + point.pauli_probabilities + if field is _InterpolatedField.PAULI + else [point.duration] + ) + if constant is None: + return None + + def constant_interpolator( + # Can't use "_" because this would cause mypy to not understand + # that this function is an Interpolator. + # pylint: disable=unused-argument + x: Union[float, List[float], np.ndarray] + ) -> np.ndarray: + return np.array(constant) + + return constant_interpolator + + params, values = _build_interpolation_matrices(instruction, field) + if params.shape[0] == 0: + return None + + # When params are of very different magnitudes (e.g., nbar between 1 and + # 100 and a gate duration around 1e-7), the interpolation is skewed. + # The rescaling below mitigates this effect. + mean = np.mean(params, axis=0) + std = np.std(params, axis=0) + # The next line is not really useful since scipy will refuse to build + # an interpolator anyway if one coordinate has a constant value. + std[std == 0] = 1 + rescaled_params = (params - mean) / std + + if params.shape[1] == 1: + scipy_interpolator = interpolate.interp1d( + np.squeeze(rescaled_params), values, axis=0 + ) + else: + scipy_interpolator = interpolate.LinearNDInterpolator( + rescaled_params, values + ) + + def protected_interpolator( + x: Union[float, List[float], np.ndarray] + ) -> np.ndarray: + error_message = ( + f'Could not interpolate requested point ({x}) because it is ' + f'out of the convex hull (instruction "{instruction.name}")' + ) + try: + y = scipy_interpolator((x - mean) / std) + except ValueError as e: + raise InterpolationError(error_message) from e + if np.isnan(np.sum(y)): + raise InterpolationError(error_message) + return np.atleast_1d(np.squeeze(y)) + + return protected_interpolator + + +def _build_interpolation_matrices( + instruction: SerializedInstruction, field: _InterpolatedField +) -> Tuple[np.ndarray, np.ndarray]: + """From the interpolation data points of a processor instruction, build + matrices of the appropriate shape (Pauli error probs + duration) for use + with scipy.interpolate functions.""" + x, y = [], [] + for point in instruction.interpolation_points: + x_row = [] + for param in instruction.free_params: + x_row.append(point.params[param]) + value = ( + point.pauli_probabilities + if field is _InterpolatedField.PAULI + else [point.duration] + ) + if value is not None: + x.append(x_row) + y.append(value) + return (np.array(x), np.array(y)) diff --git a/qiskit_alice_bob_provider/processor/serialization/model.py b/qiskit_alice_bob_provider/processor/serialization/model.py new file mode 100644 index 0000000..660b64a --- /dev/null +++ b/qiskit_alice_bob_provider/processor/serialization/model.py @@ -0,0 +1,100 @@ +############################################################################## +# Copyright 2023 Alice & Bob +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +############################################################################## + +from typing import Dict, List, Optional + +from pydantic import BaseModel + + +class ProcessorMetadata(BaseModel): + """Information about the processor model for debugging purposes""" + + schema_version: str + generated_at: str + name: str + + +class InterpolationPoint(BaseModel): + """A description of the quantum noise and the instruction duration when + the instruction is applied with a given set of parameters. + + Note that this representation can only describe Pauli errors, not general + quantum process tomography Chi matrices.""" + + # The probabilities of Pauli errors (the diagonal of a quantum process + # tomography Chi matrix). The values should sum up to one. + # Indices should with the first qubit to the right. + # Example for one qubit: I, X, Y, Z + # Example for two qubits: II, IX, IY, IZ, XI, ... + pauli_probabilities: Optional[List[float]] = None + + # The duration of the instruction + duration: float + + # The parameters for which the above Pauli error probabilities and duration + # are valid. Example parameters: nbar, gate_duration_ns (for delay), angle + # (for a rotation). + params: Dict[str, float] + + +class SerializedInstruction(BaseModel): + """The serialized representation of a given instruction""" + + # The name of the instruction: x, z, rz, mx, mz, delay, p0, p+, ... + name: str + + # The indices of qubits this noise model is applicable to. + # To support multi-qubit instructions like cx (CNOT), this is a list of + # lists. + # Example: noise model for x gate on qubits 1, 3, 5: [[1], [3], [5]] + # Example: noise model for cx gate on qubits 1-2, 3-4: [[1, 2], [3, 4]] + qubits: List[List[int]] + + # The parameters for which this noise model provides a grid of values. + # The parameters names in the InterpolationPoint.params dictionary must + # also appear in free_params. + # Example for a rotation around the y-basis: ['angle', 'nbar'] + # Example for a delay instruction: ['gate_duration_ns', 'nbar'] + # Example for a x gate: ['nbar'] + free_params: List[str] + + # The list of parameters that were used in the simulation that generated + # this noise model. This dictionary is here for debugging purposes only. + fixed_params: Dict[str, float] + + # A list of objects representing the quantum noise and the instruction + # duration when the instruction is applied with a given set of parameters. + interpolation_points: List[InterpolationPoint] + + # Probability of reading an incorrect value when measuring the state of + # a qubit. Only measurement instructions (mz and mx) should contain the + # readout attribute. + # It is assumed that the readout errors are independent of the free params. + # Format: [P(1|0), P(0|1)]. + # Example: ideal = no readout noise = [0.0, 0.0] + readout_errors: Optional[List[float]] = None + + +class SerializedProcessor(BaseModel): + """A representation of the properties of a processor serialized in a static + file. + + In practice, the instruction duration, quantum errors, and readout errors + will be interpolated between the data points given by the serialized + representation.""" + + metadata: ProcessorMetadata + instructions: List[SerializedInstruction] diff --git a/qiskit_alice_bob_provider/processor/utils.py b/qiskit_alice_bob_provider/processor/utils.py new file mode 100644 index 0000000..0f6f30b --- /dev/null +++ b/qiskit_alice_bob_provider/processor/utils.py @@ -0,0 +1,151 @@ +############################################################################## +# Copyright 2023 Alice & Bob +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +############################################################################## + +from typing import Dict, List, Union + +import numpy as np + + +def pauli_errors_to_chi(pauli_errors: Dict[str, float]) -> np.ndarray: + """Convert a collection of Pauli errors into a quantum process tomography + Chi matrix. + + https://qiskit.org/documentation/stubs/qiskit.quantum_info.Chi.html + + Args: + pauli_errors (Dict[str, float]): a dict of Pauli errors where the key + is the type of Pauli error as a string (e.g., 'I', 'X', 'XI', 'XZX') + and the value is the probability of this Pauli error. + The "no error" case (e.g., 'I', 'II', 'III', etc) should not be + provided as it will be computed automatically by difference. + + + Returns: + np.ndarray: a quantum process tomography Chi matrix. The Qiskit link + above is a good description of a Chi matrix. + """ + some_pauli_label = next(iter(pauli_errors)) + n_qubits = len(some_pauli_label) + diag = np.zeros(shape=(4**n_qubits,), dtype=float) + for pauli_label, prob in pauli_errors.items(): + diag[pauli_label_to_index(pauli_label)] = prob + + # Computation of the probability of the "no error" case by difference + diag[0] = 1.0 - np.sum(diag[1:]) + + # Sanity check that all probabilities are between 0 and 1 + try: + assert np.all(diag >= 0) + except AssertionError as e: + raise ValueError( + 'Pauli error probabilities are not in [0, 1] or sum up to more' + f' than 1. Probabilities: {pauli_errors}' + ) from e + + return np.diag(diag) + + +def is_diagonal(m: np.ndarray) -> bool: + """Test if a matrix is diagonal""" + return np.count_nonzero(m - np.diag(np.diag(m))) == 0 + + +def chi_to_pauli_errors(chi: np.ndarray) -> Dict[str, float]: + """Convert a quantum process tomography Chi matrix into a collection of + Pauli errors. + + https://qiskit.org/documentation/stubs/qiskit.quantum_info.Chi.html + + Args: + chi (np.ndarray): a quantum process tomography Chi matrix. The Qiskit + link above is a good description of a Chi matrix. + + Returns: + np.ndarray: a quantum process tomography Chi matrix. The Qiskit link + above is a good description of a Chi matrix. + Dict[str, float]: a dict of Pauli errors where the key + is the type of Pauli error as a string (e.g., 'I', 'X', 'XI', 'XZX') + and the value is the probability of this Pauli error. + """ + n_qubits = int(np.round(np.log(chi.shape[0]) / np.log(4))) + out = {} + chi_diag = np.diag(chi) + indices = np.nonzero(chi_diag)[0] + for idx in indices: + out[index_to_pauli_label(n_qubits=n_qubits, index=idx)] = chi_diag[idx] + return out + + +def pauli_label_to_index(pauli_str: str) -> int: + label_to_int = dict(zip('IXYZ', range(4))) + sum = 0 + for i, c in enumerate(pauli_str[::-1]): + try: + sum += label_to_int[c] * (4**i) + except KeyError as e: + raise ValueError( + f'Unrecognized Pauli error label "{pauli_str}"' + ) from e + return sum + + +def index_to_pauli_label(n_qubits: int, index: int) -> str: + paulis = 'IXYZ' + label = '' + for i in reversed(range(n_qubits)): + factor = 4**i + term = index // factor + label += paulis[term] + index -= term * factor + return label + + +def full_flip_error( + linearized_probs: Union[np.ndarray, List[float], List[List[float]]] +) -> np.ndarray: + """The general formula for the probabilities of Pauli errors from their + linearized versions in the region close to 0. + + Assume pX ~ rX * t, pY ~ rY * t, and pZ ~ rZ * t when t close to 0. + + Since Pauli errors combine in the following ways: X then Y is equivalent to + Z, X then Z to Y, etc, + it follows that we can build a system of first-order linear differential + equations relating pX(t), pX'(t), pY(t), pY'(t), pZ(t), pZ'(t). + + Solving it, we get the following formula for pX: + pX(t) = 0.25 * (1 + exp(- 2 * (rY + rZ) * t) + - exp(- 2 * (rX + rZ) * t) + - exp(- 2 * (rX + rY) * t)) + and symmetric formulas for pY and pZ. + + This function implements these formulas.""" + linearized_probs = np.atleast_2d(linearized_probs) + exps = np.exp( + -2 + * ( + np.roll(linearized_probs, 1, axis=1) + + np.roll(linearized_probs, 2, axis=1) + ) + ) + return np.clip( + 0.25 + * np.squeeze( + 1 + exps - np.roll(exps, 1, axis=1) - np.roll(exps, 2, axis=1) + ), + 0, + 1, + ) diff --git a/tests/local/__init__.py b/tests/local/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/tests/local/processor_fixture.py b/tests/local/processor_fixture.py new file mode 100644 index 0000000..cdfad6d --- /dev/null +++ b/tests/local/processor_fixture.py @@ -0,0 +1,203 @@ +from itertools import product +from typing import Iterator, List, Tuple + +from qiskit.quantum_info.operators import Chi +from qiskit_aer.noise import amplitude_damping_error + +from qiskit_alice_bob_provider.processor.description import ( + AppliedInstruction, + InstructionProperties, + ProcessorDescription, +) +from qiskit_alice_bob_provider.processor.utils import pauli_errors_to_chi + + +class SimpleProcessor(ProcessorDescription): + def __init__(self, clock_cycle: float = 1): + self.clock_cycle = clock_cycle + + def all_instructions(self) -> Iterator[InstructionProperties]: + for i, j in product(range(3), range(3)): + if i != j: + yield InstructionProperties( + name='cx', params=[], qubits=(i, j) + ) + for i in range(3): + yield InstructionProperties(name='h', params=[], qubits=(i,)) + yield InstructionProperties( + name='rz', params=['angle'], qubits=(i,) + ) + yield InstructionProperties(name='x', params=[], qubits=(i,)) + if i != 2: + yield InstructionProperties(name='y', params=[], qubits=(i,)) + yield InstructionProperties(name='p+', params=[], qubits=(i,)) + yield InstructionProperties(name='p0', params=[], qubits=(i,)) + yield InstructionProperties(name='p1', params=[], qubits=(i,)) + yield InstructionProperties(name='mx', params=[], qubits=(i,)) + yield InstructionProperties(name='mz', params=[], qubits=(i,)) + yield InstructionProperties( + name='delay', params=['duration'], qubits=(i,) + ) + + def apply_instruction( # pylint: disable=too-many-return-statements + self, name: str, qubits: Tuple[int, ...], params: List[float] + ) -> AppliedInstruction: + if name == 'delay': + return AppliedInstruction( + duration=params[0], + quantum_errors=pauli_errors_to_chi({'Z': 1.0}), + readout_errors=None, + ) + elif name == 'x': + return AppliedInstruction( + duration=1e7, + quantum_errors=None, + readout_errors=None, + ) + elif name == 'y': + return AppliedInstruction( + duration=1e7, + quantum_errors=pauli_errors_to_chi({'Z': 1.0}), + readout_errors=None, + ) + elif name == 'rz': + return AppliedInstruction( + duration=params[0] * 1e6, + quantum_errors=pauli_errors_to_chi({'X': 1.0}), + readout_errors=None, + ) + elif name == 'mz': + return AppliedInstruction( + duration=1e5, + quantum_errors=pauli_errors_to_chi({'Z': 1.0}), + readout_errors=None, + ) + elif name == 'mx': + return AppliedInstruction( + duration=1e4, + quantum_errors=pauli_errors_to_chi({'Z': 1.0}), + readout_errors=None, + ) + elif name == 'p0': + return AppliedInstruction( + duration=1e3, + quantum_errors=pauli_errors_to_chi({'X': 1.0}), + readout_errors=None, + ) + elif name == 'p1': + return AppliedInstruction( + duration=1e3, + quantum_errors=pauli_errors_to_chi({'X': 1.0}), + readout_errors=None, + ) + elif name == 'p+': + return AppliedInstruction( + duration=1e2, + quantum_errors=pauli_errors_to_chi({'Z': 1.0}), + readout_errors=None, + ) + elif name == 'cx': + return AppliedInstruction( + duration=1e1, + quantum_errors=pauli_errors_to_chi({'IX': 1.0}), + readout_errors=None, + ) + elif name == 'h': + m = Chi(amplitude_damping_error(0.1)).data * 0.5 + return AppliedInstruction( + duration=1e0, + quantum_errors=m, + readout_errors=None, + ) + raise NotImplementedError() + + +class ReadoutErrorProcessor(ProcessorDescription): + def __init__(self, clock_cycle: float = 1): + self.clock_cycle = clock_cycle + + def all_instructions(self) -> Iterator[InstructionProperties]: + for i in range(2): + yield InstructionProperties(name='p+', params=[], qubits=(i,)) + yield InstructionProperties(name='p-', params=[], qubits=(i,)) + yield InstructionProperties( + name='mx', params=[], qubits=(0,), readout_errors=[1, 0] + ) + yield InstructionProperties( + name='mx', params=[], qubits=(1,), readout_errors=[0, 1] + ) + + def apply_instruction( + self, name: str, qubits: Tuple[int, ...], params: List[float] + ) -> AppliedInstruction: + if name == 'mx': + return AppliedInstruction( + duration=1e4, + quantum_errors=None, + readout_errors=None, + ) + elif name in {'p+', 'p-'}: + return AppliedInstruction( + duration=1e2, + quantum_errors=None, + readout_errors=None, + ) + raise NotImplementedError() + + +class ConflictingReadoutErrorsProcessor(ProcessorDescription): + def __init__(self, clock_cycle: float = 1): + self.clock_cycle = clock_cycle + + def all_instructions(self) -> Iterator[InstructionProperties]: + yield InstructionProperties(name='p+', params=[], qubits=(0,)) + yield InstructionProperties(name='p-', params=[], qubits=(0,)) + yield InstructionProperties( + name='mx', params=[], qubits=(0,), readout_errors=[1, 0] + ) + yield InstructionProperties( + name='mz', params=[], qubits=(0,), readout_errors=[0, 1] + ) + + def apply_instruction( + self, name: str, qubits: Tuple[int, ...], params: List[float] + ) -> AppliedInstruction: + if name == 'mx': + return AppliedInstruction( + duration=1e4, + quantum_errors=None, + readout_errors=None, + ) + elif name in {'p+', 'p-'}: + return AppliedInstruction( + duration=1e2, + quantum_errors=None, + readout_errors=None, + ) + raise NotImplementedError() + + +class OneQubitProcessor(ProcessorDescription): + def __init__(self, clock_cycle: float = 1): + self.clock_cycle = clock_cycle + + def all_instructions(self) -> Iterator[InstructionProperties]: + yield InstructionProperties(name='p+', params=[], qubits=(0,)) + yield InstructionProperties(name='mx', params=[], qubits=(0,)) + + def apply_instruction( + self, name: str, qubits: Tuple[int, ...], params: List[float] + ) -> AppliedInstruction: + if name == 'mx': + return AppliedInstruction( + duration=1e4, + quantum_errors=None, + readout_errors=None, + ) + elif name == 'p+': + return AppliedInstruction( + duration=1e2, + quantum_errors=pauli_errors_to_chi({'Z': 1.0}), + readout_errors=None, + ) + raise NotImplementedError() diff --git a/tests/local/test_backend.py b/tests/local/test_backend.py new file mode 100644 index 0000000..f7337ad --- /dev/null +++ b/tests/local/test_backend.py @@ -0,0 +1,68 @@ +from typing import List + +from qiskit import QuantumCircuit, execute, transpile +from qiskit.extensions.quantum_initializer import Initialize + +from qiskit_alice_bob_provider.local.backend import ProcessorSimulator +from qiskit_alice_bob_provider.processor.physical_cat import ( + PhysicalCatProcessor, +) + +from .processor_fixture import SimpleProcessor + + +def _check_initialize(circuit: QuantumCircuit, expected: str) -> None: + initializes = circuit.get_instructions('initialize') + assert len(initializes) == 1 + assert isinstance(initializes[0].operation, Initialize) + params = initializes[0].operation.params + assert params == list(expected) + + +def _check_initializes(circuit: QuantumCircuit, expected: List[str]) -> None: + initializes = circuit.get_instructions('initialize') + assert len(initializes) == len(expected) + for initialize in initializes: + assert len(initialize.qubits) == 1 + qubit = circuit.find_bit(initialize.qubits[0]).index + assert isinstance(initialize.operation, Initialize) + assert initialize.operation.params[0] == expected[qubit] + + +def test_set_execution_backend_options() -> None: + circ = QuantumCircuit(1, 1) + circ.initialize('+') + circ.measure_x(0, 0) + backend = ProcessorSimulator(PhysicalCatProcessor()) + backend.set_options(shots=7) + assert backend.options['shots'] == 7 + assert sum(execute(circ, backend).result().get_counts().values()) == 7 + + +def test_translation_plugin() -> None: + backend = ProcessorSimulator(SimpleProcessor(1)) + + # if Initialize('+'), do nothing + circ = QuantumCircuit(1) + circ.initialize('+') + transpiled = transpile(circ, backend) + _check_initialize(transpiled, '+') + + # if no reset / initialize, add Initialize('0') + circ = QuantumCircuit(1) + circ.x(0) + transpiled = transpile(circ, backend) + _check_initialize(transpiled, '0') + + # if reset, convert to Intialize('0') + circ = QuantumCircuit(1) + circ.reset(0) + transpiled = transpile(circ, backend) + _check_initialize(transpiled, '0') + + # if reset, convert to Intialize('0') + circ = QuantumCircuit(3) + circ.initialize(2, [0, 1]) + circ.reset(2) + transpiled = transpile(circ, backend) + _check_initializes(transpiled, ['0', '1', '0']) diff --git a/tests/local/test_coupling_maps.py b/tests/local/test_coupling_maps.py new file mode 100644 index 0000000..0c986c3 --- /dev/null +++ b/tests/local/test_coupling_maps.py @@ -0,0 +1,29 @@ +from qiskit_alice_bob_provider.local.coupling_maps import ( + bidirect_map, + circular_map, + rectangular_map, +) + + +def test_bidirect_map() -> None: + map = bidirect_map([(0, 1), (3, 4)]) + assert (0, 1) in map + assert (1, 0) in map + assert (3, 4) in map + assert (4, 3) in map + + +def test_circular_map() -> None: + map = circular_map(3) + assert len(map) == 6 + assert (0, 1) in map + assert (1, 0) in map + assert (1, 2) in map + assert (2, 1) in map + assert (2, 0) in map + assert (0, 2) in map + + +def test_rectangular_map() -> None: + map = rectangular_map(2, 3) + assert len(map) == (1 * 3 + 2 * 2) * 2 diff --git a/tests/local/test_instruction_durations.py b/tests/local/test_instruction_durations.py new file mode 100644 index 0000000..063d18f --- /dev/null +++ b/tests/local/test_instruction_durations.py @@ -0,0 +1,114 @@ +# pylint: disable=redefined-outer-name + +from typing import Iterator, List, Tuple + +import pytest +from qiskit.circuit import Barrier, Delay +from qiskit.circuit.library import CCXGate, RXGate, XGate + +from qiskit_alice_bob_provider.local.instruction_durations import ( + ProcessorInstructionDurations, +) +from qiskit_alice_bob_provider.processor.description import ( + AppliedInstruction, + InstructionProperties, + ProcessorDescription, +) + + +class _TestProcessor(ProcessorDescription): + def __init__(self, clock_cycle: float): + self.clock_cycle = clock_cycle + self._delay_qubits: List[Tuple[int, ...]] = [(0,), (1,)] + self._ccx_qubits: List[Tuple[int, ...]] = [(0, 1, 2), (0, 2, 1)] + self._rx_qubits: List[Tuple[int, ...]] = [(2,)] + + def all_instructions(self) -> Iterator[InstructionProperties]: + for tup in self._delay_qubits: + yield InstructionProperties( + name='delay', params=['duration'], qubits=tup + ) + for tup in self._ccx_qubits: + yield InstructionProperties(name='ccx', params=[], qubits=tup) + for tup in self._rx_qubits: + yield InstructionProperties( + name='rx', params=['angle'], qubits=tup + ) + + def apply_instruction( + self, name: str, qubits: Tuple[int, ...], params: List[float] + ) -> AppliedInstruction: + if name == 'delay': + return AppliedInstruction( + duration=params[0], quantum_errors=None, readout_errors=None + ) + elif name == 'ccx': + if qubits == self._ccx_qubits[0]: + return AppliedInstruction( + duration=0.1, quantum_errors=None, readout_errors=None + ) + else: + return AppliedInstruction( + duration=0.2, quantum_errors=None, readout_errors=None + ) + elif name == 'rx': + if qubits == self._rx_qubits[0]: + return AppliedInstruction( + duration=params[0] * 2, + quantum_errors=None, + readout_errors=None, + ) + raise NotImplementedError() + + +@pytest.fixture +def instr_dur() -> ProcessorInstructionDurations: + return ProcessorInstructionDurations(_TestProcessor(1e-3)) + + +def test_bad_input(instr_dur: ProcessorInstructionDurations) -> None: + with pytest.raises(ValueError): # bad instruction + instr_dur.get(inst=XGate(), qubits=0) + with pytest.raises(ValueError): # bad qubits + instr_dur.get(inst=CCXGate(), qubits=(0, 1, 3)) + + +def test_instruction_as_string( + instr_dur: ProcessorInstructionDurations, +) -> None: + assert instr_dur.get(inst='ccx', qubits=(0, 1, 2), unit='s') == 0.1 + + +def test_barrier( + instr_dur: ProcessorInstructionDurations, +) -> None: + assert instr_dur.get(inst='barrier', qubits=(0, 1, 2), unit='s') == 0.0 + assert instr_dur.get(inst=Barrier(3), qubits=(0, 1, 2), unit='s') == 0.0 + + +def test_qubits_forwarded_to_processor( + instr_dur: ProcessorInstructionDurations, +) -> None: + assert instr_dur.get(inst=CCXGate(), qubits=(0, 1, 2), unit='s') == 0.1 + assert instr_dur.get(inst=CCXGate(), qubits=(0, 2, 1), unit='s') == 0.2 + + +def test_time_unit_conversion( + instr_dur: ProcessorInstructionDurations, +) -> None: + assert instr_dur.get(inst=Delay(2, 's'), qubits=(0,), unit='s') == 2 + assert instr_dur.get(inst=Delay(2, 'dt'), qubits=(0,), unit='s') == 2e-3 + assert instr_dur.get(inst=Delay(2, 'dt'), qubits=(0,), unit='dt') == 2 + with pytest.warns(UserWarning): + assert instr_dur.get(inst=Delay(2, 'us'), qubits=(0,), unit='dt') == 0 + assert instr_dur.get(inst=Delay(2000, 'us'), qubits=(0,), unit='dt') == 2 + + +def test_instruction_with_params_not_delay( + instr_dur: ProcessorInstructionDurations, +) -> None: + assert ( + instr_dur.get(inst=RXGate(0.2), qubits=2, parameters=[0.3], unit='s') + == 0.6 + ) + assert instr_dur.get(inst=RXGate(0.2), qubits=2, unit='s') == 0.4 diff --git a/tests/local/test_proc_to_qiskit.py b/tests/local/test_proc_to_qiskit.py new file mode 100644 index 0000000..55ffbdd --- /dev/null +++ b/tests/local/test_proc_to_qiskit.py @@ -0,0 +1,93 @@ +import pytest +from qiskit.circuit import Delay, Instruction, Parameter +from qiskit.circuit.library import CXGate, RYGate, XGate +from qiskit.extensions.quantum_initializer import Initialize + +from qiskit_alice_bob_provider.custom_instructions import MeasureX +from qiskit_alice_bob_provider.local.proc_to_qiskit import ( + processor_to_qiskit_instruction, +) +from qiskit_alice_bob_provider.processor.description import ( + InstructionProperties, +) + + +def _compare_instructions(computed: Instruction, expected: Instruction): + ref_type = type(expected) + assert isinstance(computed, ref_type) + assert len(expected.params) == len(computed.params) + for ref_p, computed_p in zip(expected.params, computed.params): + assert isinstance(computed_p, type(ref_p)) + if isinstance(ref_p, Parameter): + assert ref_p.name == computed_p.name + else: + assert ref_p == computed_p + + +def test_compare_instructions() -> None: + with pytest.raises(AssertionError): + _compare_instructions(Delay(Parameter('foo')), Delay(Parameter('bar'))) + with pytest.raises(AssertionError): + _compare_instructions(Delay(23), Delay(Parameter('bar'))) + with pytest.raises(AssertionError): + _compare_instructions(Delay(Parameter('bar')), Delay(23)) + with pytest.raises(AssertionError): + _compare_instructions(Delay(24), Delay(23)) + with pytest.raises(AssertionError): + _compare_instructions(XGate(), Delay(Parameter('bar'))) + + +def test_delay() -> None: + _compare_instructions( + computed=processor_to_qiskit_instruction( + InstructionProperties('delay', (0,), ['foo']) + ), + expected=Delay(Parameter('foo')), + ) + + +def test_initialize() -> None: + _compare_instructions( + computed=processor_to_qiskit_instruction( + InstructionProperties('p+', (0,), []) + ), + expected=Initialize('+'), + ) + + +def test_measure() -> None: + _compare_instructions( + computed=processor_to_qiskit_instruction( + InstructionProperties('mx', (0,), []) + ), + expected=MeasureX(), + ) + + +def test_rotation() -> None: + _compare_instructions( + computed=processor_to_qiskit_instruction( + InstructionProperties('ry', (0,), ['bar']) + ), + expected=RYGate(Parameter('bar')), + ) + + +def test_no_arg_unitaries() -> None: + _compare_instructions( + computed=processor_to_qiskit_instruction( + InstructionProperties('x', (0,), []) + ), + expected=XGate(), + ) + _compare_instructions( + computed=processor_to_qiskit_instruction( + InstructionProperties('cx', (0,), []) + ), + expected=CXGate(), + ) + + +def test_unsupported() -> None: + with pytest.raises(NotImplementedError): + processor_to_qiskit_instruction(InstructionProperties('u', (0,), [])) diff --git a/tests/local/test_provider.py b/tests/local/test_provider.py new file mode 100644 index 0000000..d57caa1 --- /dev/null +++ b/tests/local/test_provider.py @@ -0,0 +1,10 @@ +from qiskit_alice_bob_provider.local.provider import AliceBobLocalProvider + + +def test_get_backends() -> None: + ab = AliceBobLocalProvider() + ab.backends() + assert ab.get_backend('PHYSICAL_CATS_6').name == 'PHYSICAL_CATS_6' + backends = ab.backends('PHYSICAL_CATS_6') + assert len(backends) == 1 + assert ab.get_backend('PHYSICAL_CATS_6').name == backends[0].name diff --git a/tests/local/test_quantum_errors.py b/tests/local/test_quantum_errors.py new file mode 100644 index 0000000..a9b982d --- /dev/null +++ b/tests/local/test_quantum_errors.py @@ -0,0 +1,83 @@ +from qiskit import QuantumCircuit +from qiskit.transpiler import PassManager + +from qiskit_alice_bob_provider.local.quantum_errors import ( + build_quantum_error_passes, +) + +from .processor_fixture import SimpleProcessor + + +def test_noise_not_on_all_qubits() -> None: + circ = QuantumCircuit(3) + for i in range(3): + circ.y(i) + pm = PassManager(build_quantum_error_passes(SimpleProcessor())) + transpiled = pm.run(circ) + + # Y noise was only activated on qubits 0 and 1 + y_errors = transpiled.get_instructions('y_error') + assert len(y_errors) == 2 + qubits = {circ.find_bit(e.qubits[0])[0] for e in y_errors} + assert qubits == {0, 1} + + +def test_noise_on_initialize() -> None: + circ = QuantumCircuit(3) + circ.initialize('+', 0) + circ.initialize('-', 1) + circ.initialize('0', 2) + pm = PassManager(build_quantum_error_passes(SimpleProcessor())) + transpiled = pm.run(circ) + + for label, n_qubits, index in [ + ('p+_error', 1, 0), + ('p-_error', 0, 0), + ('p0_error', 1, 2), + ('p1_error', 0, 0), + ]: + errors = transpiled.get_instructions(label) + assert len(errors) == n_qubits + if n_qubits == 1: + qubit = circ.find_bit(errors[0].qubits[0]).index + assert qubit == index + + +def test_noise_on_mx() -> None: + circ = QuantumCircuit(3, 3) + circ.measure_x(0, 0) + circ.measure_x(1, 1) + circ.measure(2, 2) + pm = PassManager(build_quantum_error_passes(SimpleProcessor())) + transpiled = pm.run(circ) + + # Only qubits 0 and 1 had a measure in the x basis + mx_errors = transpiled.get_instructions('mx_error') + assert len(mx_errors) == 2 + qubits = {circ.find_bit(e.qubits[0])[0] for e in mx_errors} + assert qubits == {0, 1} + + +def test_pass_with_none_chi_matrix() -> None: + circ = QuantumCircuit(10) + circ.x(0) + pm = PassManager(build_quantum_error_passes(SimpleProcessor())) + transpiled = pm.run(circ) + assert len(transpiled.get_instructions('x_error')) == 0 + + +def test_chi_vs_pauli_errors() -> None: + # Circuit with diagonal chi matrix -> quantum channel of Pauli errors + circ = QuantumCircuit(10) + circ.y(0) + pm = PassManager(build_quantum_error_passes(SimpleProcessor())) + transpiled = pm.run(circ) + assert len(transpiled.decompose().get_instructions('quantum_channel')) == 1 + + # Circuit with nonè diagonal chi matrix -> Kraus map + circ = QuantumCircuit(10) + circ.h(0) + pm = PassManager(build_quantum_error_passes(SimpleProcessor())) + transpiled = pm.run(circ) + print(transpiled.decompose()) + assert len(transpiled.decompose().get_instructions('kraus')) == 1 diff --git a/tests/local/test_readout_errors.py b/tests/local/test_readout_errors.py new file mode 100644 index 0000000..a64b5f2 --- /dev/null +++ b/tests/local/test_readout_errors.py @@ -0,0 +1,46 @@ +import pytest +from qiskit import QuantumCircuit, execute + +from qiskit_alice_bob_provider.local.backend import ProcessorSimulator + +from .processor_fixture import ( + ConflictingReadoutErrorsProcessor, + ReadoutErrorProcessor, +) + + +def test_one_readout_error() -> None: + proc = ReadoutErrorProcessor() + backend = ProcessorSimulator(processor=proc) + + circ = QuantumCircuit(2, 2) + circ.initialize('++') + circ.measure_x(0, 0) + circ.measure_x(1, 1) + counts = execute(circ, backend, shots=1).result().get_counts() + assert counts.keys() == {'01'} + + circ = QuantumCircuit(2, 2) + circ.initialize('--') + circ.measure_x(0, 0) + circ.measure_x(1, 1) + counts = execute(circ, backend, shots=1).result().get_counts() + assert counts.keys() == {'01'} + + +def test_conflicting_readout_errors() -> None: + proc = ConflictingReadoutErrorsProcessor() + with pytest.warns(UserWarning): + backend = ProcessorSimulator(processor=proc) + + circ = QuantumCircuit(1, 1) + circ.initialize('+') + circ.measure_x(0, 0) + counts = execute(circ, backend, shots=1).result().get_counts() + assert counts.keys() == {'1'} + + circ = QuantumCircuit(1, 1) + circ.initialize('-') + circ.measure_x(0, 0) + counts = execute(circ, backend, shots=1).result().get_counts() + assert counts.keys() == {'1'} diff --git a/tests/local/test_scheduling.py b/tests/local/test_scheduling.py new file mode 100644 index 0000000..26242e6 --- /dev/null +++ b/tests/local/test_scheduling.py @@ -0,0 +1,64 @@ +from typing import Iterator, Tuple + +import pytest +from qiskit import QuantumCircuit, transpile +from qiskit.extensions.quantum_initializer import Initialize + +from qiskit_alice_bob_provider.local.backend import ProcessorSimulator + +from .processor_fixture import SimpleProcessor + + +def gen_circuits() -> Iterator[Tuple[str, QuantumCircuit, int]]: + circ = QuantumCircuit(2, 2) + circ.initialize('0', 0) + circ.initialize('+', 1) + circ.x(0) + circ.rz(11, 1) + circ.cx(0, 1) + circ.measure(0, 0) + circ.measure_x(1, 1) + yield ('qubits_competing_for_duration', circ, 11100110) + + sub_sub_circ = QuantumCircuit(2, 0) + sub_sub_circ.x(0) + sub_sub_circ.rz(11, 1) + sub_circ = QuantumCircuit(2, 0) + sub_circ.append(sub_sub_circ.to_instruction(), [1, 0]) + circ = QuantumCircuit(2, 2) + circ.initialize('0', 0) + circ.initialize('+', 1) + circ.append(sub_circ.to_instruction(), [1, 0]) + circ.cx(0, 1) + circ.measure(0, 0) + circ.measure_x(1, 1) + yield ('sub_circuits', circ, 11100110) + + +@pytest.mark.parametrize('tup', gen_circuits()) +def test_circuit(tup: Tuple[str, QuantumCircuit, int]) -> None: + _, circ, expected_duration = tup + backend = ProcessorSimulator(SimpleProcessor(1)) + transpiled = transpile(circ, backend) + try: + assert transpiled.duration == expected_duration + except AssertionError: + print('==== Original circuit ====') + print(circ) + print('==== Transpiled circuit ====') + print(transpiled) + raise + + +def test_reset_to_initialize() -> None: + circ = QuantumCircuit(1, 0) + circ.reset(0) + backend = ProcessorSimulator(SimpleProcessor(1)) + transpiled = transpile(circ, backend) + initializes = transpiled.get_instructions('initialize') + print(circ) + print(transpiled) + assert len(initializes) == 1 + assert isinstance(initializes[0].operation, Initialize) + assert initializes[0].operation.params[0] == '0' + assert len(transpiled.get_instructions('reset')) == 0 diff --git a/tests/local/test_simulation.py b/tests/local/test_simulation.py new file mode 100644 index 0000000..2c30b1b --- /dev/null +++ b/tests/local/test_simulation.py @@ -0,0 +1,181 @@ +from typing import Iterator, List, Set, Tuple + +import numpy as np +import pytest +from qiskit import QuantumCircuit, execute +from qiskit_aer.backends import AerSimulator +from qiskit_aer.noise import NoiseModel, pauli_error + +from qiskit_alice_bob_provider.local.backend import ProcessorSimulator +from qiskit_alice_bob_provider.local.job import ProcessorSimulationJob +from qiskit_alice_bob_provider.processor.description import ( + AppliedInstruction, + InstructionProperties, + ProcessorDescription, +) +from qiskit_alice_bob_provider.processor.interpolated_cat import ( + InterpolatedCatProcessor, +) +from qiskit_alice_bob_provider.processor.serialization.model import ( + SerializedProcessor, +) +from qiskit_alice_bob_provider.processor.utils import pauli_errors_to_chi + +from .processor_fixture import OneQubitProcessor, SimpleProcessor + + +def gen_circuits() -> Iterator[Tuple[str, QuantumCircuit, Set[str]]]: + circ = QuantumCircuit(2, 2) + circ.initialize('0', 0) + circ.initialize('+', 1) + circ.x(0) + circ.cx(0, 1) + circ.measure(0, 0) + circ.measure_x(1, 1) + yield ('everything_circuit', circ, {'11'}) + + +@pytest.mark.parametrize('tup', gen_circuits()) +def test_circuit(tup: Tuple[str, QuantumCircuit, Set[str]]) -> None: + _, circ, expected_keys = tup + backend = ProcessorSimulator(SimpleProcessor()) + job: ProcessorSimulationJob = execute(circ, backend) + result = job.result() + try: + assert result.get_counts().keys() == expected_keys + except AssertionError: + print('==== Original circuit ====') + print(circ) + print('==== Scheduled circuit ====') + print(job.circuits()[0]) + print('==== Noisy circuit ====') + print(job.noisy_circuits()[0]) + raise + + +def test_multiple_experiments() -> None: + circ1 = QuantumCircuit(1, 1) + circ1.x(0) + circ1.measure(0, 0) + circ2 = QuantumCircuit(1, 1) + circ2.initialize('+') + circ2.measure_x(0, 0) + backend = ProcessorSimulator(SimpleProcessor()) + job: ProcessorSimulationJob = execute([circ1, circ2], backend) + result = job.result() + assert len(result.get_counts()) == 2 + + +def test_non_default_shots() -> None: + circ = QuantumCircuit(1, 1) + circ.x(0) + circ.measure(0, 0) + shots = 5 + backend = ProcessorSimulator(SimpleProcessor()) + job: ProcessorSimulationJob = execute(circ, backend, shots=shots) + result = job.result() + assert sum(result.get_counts().values()) == shots + + +class _CXProcessor(ProcessorDescription): + clock_cycle = 1 + + def all_instructions(self) -> Iterator[InstructionProperties]: + for i in range(2): + yield InstructionProperties(name='p0', params=[], qubits=(i,)) + yield InstructionProperties(name='mz', params=[], qubits=(i,)) + yield InstructionProperties(name='cx', params=[], qubits=(0, 1)) + yield InstructionProperties(name='cx', params=[], qubits=(1, 0)) + + def apply_instruction( + self, name: str, qubits: Tuple[int, ...], params: List[float] + ) -> AppliedInstruction: + if name == 'cx': + return AppliedInstruction( + duration=self.clock_cycle, + quantum_errors=pauli_errors_to_chi({'IX': 1.0}), + readout_errors=None, + ) + return AppliedInstruction( + duration=self.clock_cycle, + quantum_errors=None, + readout_errors=None, + ) + + +def gen_circuits_ordering() -> Iterator[Tuple[str, QuantumCircuit]]: + circ = QuantumCircuit(2, 2) + circ.cx(0, 1) + circ.measure(0, 0) + circ.measure(1, 1) + yield ('01_circuit', circ) + + circ = QuantumCircuit(2, 2) + circ.cx(1, 0) + circ.measure(0, 0) + circ.measure(1, 1) + yield ('10_circuit', circ) + + +@pytest.mark.parametrize('tup', gen_circuits_ordering()) +def test_qubit_ordering(tup: Tuple[str, QuantumCircuit]) -> None: + _, circ = tup + aer = AerSimulator() + nm = NoiseModel() + nm.add_all_qubit_quantum_error(pauli_error([('IX', 1.0)]), 'cx') + aer_counts = execute(circ, aer, noise_model=nm).result().get_counts() + backend = ProcessorSimulator(_CXProcessor()) + proc_counts = execute(circ, backend).result().get_counts() + try: + assert aer_counts == proc_counts + except AssertionError: + print(circ) + + +def test_interpolated_cat() -> None: + with open( + 'tests/processor/serialization/data/all_types.json', + encoding='utf-8', + ) as f: + ser = SerializedProcessor.model_validate_json(f.read()) + proc = InterpolatedCatProcessor(ser, alpha=np.sqrt(5)) + backend = ProcessorSimulator(proc) + + circ = QuantumCircuit(2, 2) + circ.initialize('+', 0) + circ.initialize('0', 1) + circ.x(0) + circ.delay(800, 0, unit='s') + circ.y(0) + circ.rz(1.57, 0) + circ.cx(0, 1) + circ.measure_x(0, 0) + circ.measure(0, 1) + + job = execute(circ, backend) + assert isinstance(job, ProcessorSimulationJob) + noisy_circ = job.noisy_circuits()[0] + + assert len(noisy_circ.get_instructions('p0_error')) == 1 + assert len(noisy_circ.get_instructions('p+_error')) == 1 + assert len(noisy_circ.get_instructions('mx_error')) == 1 + assert len(noisy_circ.get_instructions('x_error')) == 1 + assert len(noisy_circ.get_instructions('y_error')) == 0 + assert len(noisy_circ.get_instructions('rz_error')) == 1 + assert len(noisy_circ.get_instructions('cx_error')) == 1 + assert len(noisy_circ.get_instructions('mx_error')) == 1 + assert len(noisy_circ.get_instructions('mz_error')) == 1 + assert len(noisy_circ.get_instructions('delay')) == 1 + + # The next lines test that we can simulate without errors + job.result().get_counts() + + +def test_no_delay() -> None: + """This test makes sure that quantum errors get inserted even when there + are no delay in the circuit after scheduling.""" + backend = ProcessorSimulator(OneQubitProcessor()) + circ = QuantumCircuit(1, 1) + circ.initialize('+') + circ.measure_x(0, 0) + assert execute(circ, backend, shots=1).result().get_counts() == {'1': 1} diff --git a/tests/local/test_target.py b/tests/local/test_target.py new file mode 100644 index 0000000..881f690 --- /dev/null +++ b/tests/local/test_target.py @@ -0,0 +1,44 @@ +from typing import Iterator, List, Tuple + +from qiskit_alice_bob_provider.local.instruction_durations import ( + ProcessorInstructionDurations, +) +from qiskit_alice_bob_provider.local.target import processor_to_target +from qiskit_alice_bob_provider.processor.description import ( + AppliedInstruction, + InstructionProperties, + ProcessorDescription, +) + + +class _TestProcessor(ProcessorDescription): + def __init__(self, clock_cycle: float): + self.clock_cycle = clock_cycle + + def all_instructions(self) -> Iterator[InstructionProperties]: + yield InstructionProperties( + name='delay', params=['duration'], qubits=(0,) + ) + yield InstructionProperties( + name='delay', params=['duration'], qubits=(1,) + ) + yield InstructionProperties(name='ccx', params=[], qubits=(0, 1, 2)) + yield InstructionProperties(name='ccx', params=[], qubits=(0, 2, 1)) + + def apply_instruction( + self, name: str, qubits: Tuple[int, ...], params: List[float] + ) -> AppliedInstruction: + raise NotImplementedError() + + +def test_target_from_processor() -> None: + clock_cycle = 3 + target = processor_to_target(_TestProcessor(clock_cycle)) + assert target.dt == clock_cycle + assert target.instruction_supported('delay', qargs=(0,)) + assert target.instruction_supported('delay', qargs=(1,)) + assert not target.instruction_supported('delay', qargs=(2,)) + assert target.instruction_supported('ccx', qargs=(0, 1, 2)) + assert target.instruction_supported('ccx', qargs=(0, 2, 1)) + assert not target.instruction_supported('ccx', qargs=(3, 4, 5)) + assert isinstance(target.durations(), ProcessorInstructionDurations) diff --git a/tests/local/test_translation_plugin.py b/tests/local/test_translation_plugin.py new file mode 100644 index 0000000..71b63f5 --- /dev/null +++ b/tests/local/test_translation_plugin.py @@ -0,0 +1,73 @@ +from typing import List + +import pytest +from qiskit import QuantumCircuit +from qiskit.extensions.quantum_initializer import Initialize +from qiskit.transpiler import PassManager, TranspilerError + +from qiskit_alice_bob_provider.local.translation_plugin import ( + BreakDownInitializePass, + IntToLabelInitializePass, +) + + +def _check_initialize(circuit: QuantumCircuit, expected: str) -> None: + initializes = circuit.get_instructions('initialize') + assert len(initializes) == 1 + assert isinstance(initializes[0].operation, Initialize) + params = initializes[0].operation.params + assert params == list(expected) + + +def test_int_to_label() -> None: + pm = PassManager([IntToLabelInitializePass()]) + + # int(2) should map to '10' + circ = QuantumCircuit(2) + circ.initialize(2) + transpiled = pm.run(circ) + _check_initialize(transpiled, '10') + + # a string label should pass unchanged + circ = QuantumCircuit(2) + circ.initialize('+0') + transpiled = pm.run(circ) + _check_initialize(transpiled, '+0') + + # a state vector should fail + circ = QuantumCircuit(2) + circ.initialize([1, 0, 0, 0]) + with pytest.raises(TranspilerError): + pm.run(circ) + + +def _check_initializes(circuit: QuantumCircuit, expected: List[str]) -> None: + initializes = circuit.get_instructions('initialize') + assert len(initializes) == len(expected) + for initialize in initializes: + assert len(initialize.qubits) == 1 + qubit = circuit.find_bit(initialize.qubits[0]).index + assert isinstance(initialize.operation, Initialize) + assert initialize.operation.params[0] == expected[qubit] + + +def test_break_down() -> None: + pm = PassManager([BreakDownInitializePass()]) + + # Initialize('10') is broken down into '0' on qubit 0, '1' on qubit 1 + circ = QuantumCircuit(2) + circ.initialize('10') + transpiled = pm.run(circ) + _check_initializes(transpiled, ['0', '1']) + + # Initialize('+') is broken down into '1' on qubit 0 + circ = QuantumCircuit(2) + circ.initialize('+', 0) + transpiled = pm.run(circ) + _check_initializes(transpiled, ['+']) + + # fails on int + circ = QuantumCircuit(2) + circ.initialize(2) + with pytest.raises(TranspilerError): + pm.run(circ) diff --git a/tests/processor/__init__.py b/tests/processor/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/tests/processor/serialization/__init__.py b/tests/processor/serialization/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/tests/processor/serialization/data/1d_instruction.json b/tests/processor/serialization/data/1d_instruction.json new file mode 100644 index 0000000..b633b29 --- /dev/null +++ b/tests/processor/serialization/data/1d_instruction.json @@ -0,0 +1,24 @@ +{ + "name": "rz", + "qubits": [[0]], + "free_params": ["nbar"], + "fixed_params": { + "foo": 42 + }, + "interpolation_points": [ + { + "pauli_probabilities": [0.92, 0.05, 0.00, 0.03], + "duration": 1e-4, + "params": { + "nbar": 4 + } + }, + { + "pauli_probabilities": [0.81, 0.1, 0.02, 0.07], + "duration": 1e-5, + "params": { + "nbar": 6 + } + } + ] +} diff --git a/tests/processor/serialization/data/2d_instruction.json b/tests/processor/serialization/data/2d_instruction.json new file mode 100644 index 0000000..9b3e8db --- /dev/null +++ b/tests/processor/serialization/data/2d_instruction.json @@ -0,0 +1,42 @@ +{ + "name": "rz", + "qubits": [[0]], + "free_params": ["nbar", "angle"], + "fixed_params": { + "foo": 42 + }, + "interpolation_points": [ + { + "pauli_probabilities": [0.92, 0.05, 0.01, 0.02], + "duration": 2e-4, + "params": { + "nbar": 4, + "angle": 0 + } + }, + { + "pauli_probabilities": [0.94, 0.01, 0.02, 0.03], + "duration": 3e-4, + "params": { + "nbar": 4, + "angle": 3.14 + } + }, + { + "pauli_probabilities": [0.94, 0.02, 0.02, 0.02], + "duration": 4e-4, + "params": { + "nbar": 6, + "angle": 0 + } + }, + { + "pauli_probabilities": [0.94, 0.03, 0.02, 0.01], + "duration": 5e-4, + "params": { + "nbar": 6, + "angle": 3.14 + } + } + ] +} diff --git a/tests/processor/serialization/data/all_types.json b/tests/processor/serialization/data/all_types.json new file mode 100644 index 0000000..b9dacb5 --- /dev/null +++ b/tests/processor/serialization/data/all_types.json @@ -0,0 +1,389 @@ +{ + "metadata": { + "schema_version": "str", + "generated_at": "str", + "name": "str" + }, + "instructions": [ + { + "name": "x", + "qubits": [ + [ + 0 + ] + ], + "free_params": [ + "nbar" + ], + "fixed_params": { + "foo": 42 + }, + "interpolation_points": [ + { + "pauli_probabilities": [ + 0.92, + 0.05, + 0.01, + 0.02 + ], + "duration": 1e-4, + "params": { + "nbar": 4 + } + }, + { + "pauli_probabilities": [ + 0.94, + 0.01, + 0.02, + 0.03 + ], + "duration": 1e-4, + "params": { + "nbar": 6 + } + } + ] + }, + { + "name": "y", + "qubits": [ + [ + 0 + ] + ], + "free_params": [], + "fixed_params": { + "foo": 42 + }, + "interpolation_points": [ + { + "duration": 1e-4, + "params": {} + } + ] + }, + { + "name": "rz", + "qubits": [ + [ + 0 + ] + ], + "free_params": [ + "nbar", + "angle" + ], + "fixed_params": { + "foo": 42 + }, + "interpolation_points": [ + { + "pauli_probabilities": [ + 0.92, + 0.05, + 0.01, + 0.02 + ], + "duration": 1e-4, + "params": { + "nbar": 4, + "angle": 0 + } + }, + { + "pauli_probabilities": [ + 0.94, + 0.01, + 0.02, + 0.03 + ], + "duration": 1e-4, + "params": { + "nbar": 4, + "angle": 3.14 + } + }, + { + "pauli_probabilities": [ + 0.94, + 0.02, + 0.02, + 0.02 + ], + "duration": 1e-4, + "params": { + "nbar": 6, + "angle": 0 + } + }, + { + "pauli_probabilities": [ + 0.94, + 0.03, + 0.02, + 0.01 + ], + "duration": 1e-4, + "params": { + "nbar": 6, + "angle": 3.14 + } + } + ] + }, + { + "name": "delay", + "qubits": [ + [ + 0 + ] + ], + "free_params": [ + "nbar", + "gate_duration_ns" + ], + "fixed_params": { + "foo": 42 + }, + "interpolation_points": [ + { + "pauli_probabilities": [ + 0.85, + 0.05, + 0.04, + 0.06 + ], + "duration": 1e-4, + "params": { + "nbar": 6, + "gate_duration_ns": 1000 + } + }, + { + "pauli_probabilities": [ + 0.94, + 0.01, + 0.02, + 0.03 + ], + "duration": 1e-4, + "params": { + "nbar": 6, + "gate_duration_ns": 100 + } + }, + { + "pauli_probabilities": [ + 0.94, + 0.01, + 0.02, + 0.03 + ], + "duration": 1e-4, + "params": { + "nbar": 3, + "gate_duration_ns": 1000 + } + } + ] + }, + { + "name": "p+", + "qubits": [ + [ + 0 + ], + [ + 1 + ] + ], + "free_params": [ + "nbar" + ], + "fixed_params": { + "foo": 42 + }, + "interpolation_points": [ + { + "pauli_probabilities": [ + 0.98, + 0.0, + 0.0, + 0.02 + ], + "duration": 1e-4, + "params": { + "nbar": 4 + } + }, + { + "pauli_probabilities": [ + 0.97, + 0.0, + 0.0, + 0.03 + ], + "duration": 1e-4, + "params": { + "nbar": 6 + } + } + ] + }, + { + "name": "p0", + "qubits": [ + [ + 1 + ] + ], + "free_params": [ + "nbar" + ], + "fixed_params": { + "foo": 42 + }, + "interpolation_points": [ + { + "pauli_probabilities": [ + 0.98, + 0.0, + 0.0, + 0.02 + ], + "duration": 1e-4, + "params": { + "nbar": 4 + } + }, + { + "pauli_probabilities": [ + 0.97, + 0.0, + 0.0, + 0.03 + ], + "duration": 1e-4, + "params": { + "nbar": 6 + } + } + ] + }, + { + "name": "mx", + "qubits": [ + [ + 0 + ], + [ + 1 + ] + ], + "free_params": [ + "nbar" + ], + "fixed_params": { + "foo": 42 + }, + "interpolation_points": [ + { + "pauli_probabilities": [ + 0.92, + 0.04, + 0.02, + 0.02 + ], + "duration": 1e-4, + "params": { + "nbar": 4 + } + }, + { + "pauli_probabilities": [ + 0.93, + 0.01, + 0.03, + 0.03 + ], + "duration": 1e-4, + "params": { + "nbar": 6 + } + } + ], + "readout_errors": [ + 0.1, + 0.2 + ] + }, + { + "name": "mz", + "qubits": [ + [ + 0 + ], + [ + 1 + ] + ], + "free_params": [], + "fixed_params": { + "foo": 42 + }, + "interpolation_points": [ + { + "pauli_probabilities": [ + 0.92, + 0.04, + 0.02, + 0.02 + ], + "duration": 1e-4, + "params": {} + } + ], + "readout_errors": [ + 0.1, + 0.2 + ] + }, + { + "name": "cx", + "qubits": [ + [ + 0, 1 + ] + ], + "free_params": [], + "fixed_params": { + "foo": 42 + }, + "interpolation_points": [ + { + "pauli_probabilities": [ + 0.7, + 0.02, + 0.02, + 0.02, + 0.02, + 0.02, + 0.02, + 0.02, + 0.02, + 0.02, + 0.02, + 0.02, + 0.02, + 0.02, + 0.02, + 0.02 + ], + "duration": 1e-3, + "params": {} + } + ] + } + ] +} diff --git a/tests/processor/serialization/data/duplicate_instructions.json b/tests/processor/serialization/data/duplicate_instructions.json new file mode 100644 index 0000000..cabd1f2 --- /dev/null +++ b/tests/processor/serialization/data/duplicate_instructions.json @@ -0,0 +1,89 @@ +{ + "metadata": { + "schema_version": "str", + "generated_at": "str", + "name": "str" + }, + "instructions": [ + { + "name": "x", + "qubits": [ + [ + 0 + ] + ], + "free_params": [ + "nbar" + ], + "fixed_params": { + "foo": 42 + }, + "interpolation_points": [ + { + "pauli_probabilities": [ + 0.92, + 0.05, + 0.01, + 0.02 + ], + "duration": 1e-4, + "params": { + "nbar": 4 + } + }, + { + "pauli_probabilities": [ + 0.94, + 0.01, + 0.02, + 0.03 + ], + "duration": 1e-4, + "params": { + "nbar": 6 + } + } + ] + }, + { + "name": "x", + "qubits": [ + [ + 0 + ] + ], + "free_params": [ + "nbar" + ], + "fixed_params": { + "foo": 42 + }, + "interpolation_points": [ + { + "pauli_probabilities": [ + 0.92, + 0.05, + 0.01, + 0.02 + ], + "duration": 1e-4, + "params": { + "nbar": 4 + } + }, + { + "pauli_probabilities": [ + 0.94, + 0.01, + 0.02, + 0.03 + ], + "duration": 1e-4, + "params": { + "nbar": 6 + } + } + ] + } + ] +} diff --git a/tests/processor/serialization/data/no_quantum.json b/tests/processor/serialization/data/no_quantum.json new file mode 100644 index 0000000..8ed52e8 --- /dev/null +++ b/tests/processor/serialization/data/no_quantum.json @@ -0,0 +1,35 @@ +{ + "metadata": { + "schema_version": "str", + "generated_at": "str", + "name": "str" + }, + "instructions": [ + { + "name": "x", + "qubits": [ + [ + 0 + ] + ], + "free_params": ["nbar"], + "fixed_params": { + "foo": 42 + }, + "interpolation_points": [ + { + "duration": 1e-4, + "params": { + "nbar": 4 + } + }, + { + "duration": 1e-5, + "params": { + "nbar": 6 + } + } + ] + } + ] +} diff --git a/tests/processor/serialization/data/one_point.json b/tests/processor/serialization/data/one_point.json new file mode 100644 index 0000000..9bb9504 --- /dev/null +++ b/tests/processor/serialization/data/one_point.json @@ -0,0 +1,33 @@ +{ + "metadata": { + "schema_version": "str", + "generated_at": "str", + "name": "str" + }, + "instructions": [ + { + "name": "x", + "qubits": [ + [ + 0 + ] + ], + "free_params": [], + "fixed_params": { + "foo": 42 + }, + "interpolation_points": [ + { + "pauli_probabilities": [ + 0.92, + 0.05, + 0.01, + 0.02 + ], + "duration": 1e-4, + "params": {} + } + ] + } + ] +} diff --git a/tests/processor/serialization/data/one_point_no_quantum.json b/tests/processor/serialization/data/one_point_no_quantum.json new file mode 100644 index 0000000..bd8761d --- /dev/null +++ b/tests/processor/serialization/data/one_point_no_quantum.json @@ -0,0 +1,27 @@ +{ + "metadata": { + "schema_version": "str", + "generated_at": "str", + "name": "str" + }, + "instructions": [ + { + "name": "x", + "qubits": [ + [ + 0 + ] + ], + "free_params": [], + "fixed_params": { + "foo": 42 + }, + "interpolation_points": [ + { + "duration": 1e-4, + "params": {} + } + ] + } + ] +} diff --git a/tests/processor/serialization/test_interpolation.py b/tests/processor/serialization/test_interpolation.py new file mode 100644 index 0000000..e97044e --- /dev/null +++ b/tests/processor/serialization/test_interpolation.py @@ -0,0 +1,157 @@ +import numpy as np +import pytest + +from qiskit_alice_bob_provider.processor.serialization.interpolate import ( + InterpolatedProcessor, + InterpolationError, + _build_interpolator, + _InterpolatedField, +) +from qiskit_alice_bob_provider.processor.serialization.model import ( + SerializedInstruction, + SerializedProcessor, +) + + +def test_1d_pauli_interpolation() -> None: + with open( + 'tests/processor/serialization/data/1d_instruction.json', + encoding='utf-8', + ) as f: + instr = SerializedInstruction.model_validate_json(f.read()) + pauli_interp = _build_interpolator(instr, _InterpolatedField.PAULI) + assert pauli_interp is not None + + # one of the points in the simulated data + assert list(pauli_interp(4)) == pytest.approx([0.92, 0.05, 0.0, 0.03]) + + # point within the interval + assert list(pauli_interp(5)) == pytest.approx([0.865, 0.075, 0.01, 0.05]) + + # point out of the interval + with pytest.raises(InterpolationError): + pauli_interp([7]) + + +def test_1d_duration_interpolation() -> None: + with open( + 'tests/processor/serialization/data/1d_instruction.json', + encoding='utf-8', + ) as f: + instr = SerializedInstruction.model_validate_json(f.read()) + duration_interp = _build_interpolator(instr, _InterpolatedField.DURATION) + assert duration_interp is not None + + # one of the points in the simulated data + assert list(duration_interp(4)) == pytest.approx([1e-4]) + + # point within the interval + assert list(duration_interp(5)) == pytest.approx([5.5e-5]) + + # point out of the interval + with pytest.raises(InterpolationError): + duration_interp([7]) + + +def test_nd_pauli_interpolation() -> None: + with open( + 'tests/processor/serialization/data/2d_instruction.json', + encoding='utf-8', + ) as f: + instr = SerializedInstruction.model_validate_json(f.read()) + pauli_interp = _build_interpolator(instr, _InterpolatedField.PAULI) + assert pauli_interp is not None + + # one of the points in the simulated data + # the other in the convex hull + for p in [pauli_interp([6, 1.57]), pauli_interp([5, 1.3])]: + assert len(p) == 4 + assert sum(p) == pytest.approx(1.0) + + # point out of the convex hull + with pytest.raises(InterpolationError): + pauli_interp([42, 42.0]) + + +def test_nd_duration_interpolation() -> None: + with open( + 'tests/processor/serialization/data/2d_instruction.json', + encoding='utf-8', + ) as f: + instr = SerializedInstruction.model_validate_json(f.read()) + duration_interp = _build_interpolator(instr, _InterpolatedField.DURATION) + assert duration_interp is not None + + # one of the points in the simulated data + # the other in the convex hull + for p in [duration_interp([6, 1.57]), duration_interp([5, 1.3])]: + assert len(p) == 1 + + # point out of the convex hull + with pytest.raises(InterpolationError): + duration_interp([42, 42.0]) + + +def test_interpolated_processor_duplicate_instructions() -> None: + with open( + 'tests/processor/serialization/data/duplicate_instructions.json', + encoding='utf-8', + ) as f: + ser = SerializedProcessor.model_validate_json(f.read()) + with pytest.raises(ValueError): + InterpolatedProcessor(ser) + + +def test_interpolated_processor_one_point_no_quantum() -> None: + with open( + 'tests/processor/serialization/data/one_point_no_quantum.json', + encoding='utf-8', + ) as f: + ser = SerializedProcessor.model_validate_json(f.read()) + proc = InterpolatedProcessor(ser) + applied = proc.apply_instruction('x', (0,), []) + assert applied.duration == 1e-4 + assert applied.quantum_errors is None + + +def test_interpolated_processor_one_point() -> None: + with open( + 'tests/processor/serialization/data/one_point.json', + encoding='utf-8', + ) as f: + ser = SerializedProcessor.model_validate_json(f.read()) + proc = InterpolatedProcessor(ser) + applied = proc.apply_instruction('x', (0,), []) + assert applied.duration == 1e-4 + assert applied.quantum_errors is not None + assert list(np.diag(applied.quantum_errors)) == pytest.approx( + [0.92, 0.05, 0.01, 0.02] + ) + + +def test_interpolated_processor_no_quantum() -> None: + with open( + 'tests/processor/serialization/data/no_quantum.json', + encoding='utf-8', + ) as f: + ser = SerializedProcessor.model_validate_json(f.read()) + proc = InterpolatedProcessor(ser) + applied = proc.apply_instruction('x', (0,), [5]) + assert applied.duration == 5.5e-5 + assert applied.quantum_errors is None + + +def test_interpolated_processor_all_types() -> None: + with open( + 'tests/processor/serialization/data/all_types.json', + encoding='utf-8', + ) as f: + ser = SerializedProcessor.model_validate_json(f.read()) + proc = InterpolatedProcessor(ser) + list(proc.all_instructions()) + applied = proc.apply_instruction('delay', (0,), [5, 500]) + assert applied.quantum_errors is not None + assert applied.readout_errors is None + applied = proc.apply_instruction('mx', (0,), [5]) + assert applied.quantum_errors is not None + assert applied.readout_errors is not None diff --git a/tests/processor/test_interpolated_cat.py b/tests/processor/test_interpolated_cat.py new file mode 100644 index 0000000..9ef011a --- /dev/null +++ b/tests/processor/test_interpolated_cat.py @@ -0,0 +1,35 @@ +import numpy as np + +from qiskit_alice_bob_provider.processor.interpolated_cat import ( + InterpolatedCatProcessor, +) +from qiskit_alice_bob_provider.processor.serialization.model import ( + SerializedProcessor, +) + + +def test_apply_instruction() -> None: + with open( + 'tests/processor/serialization/data/all_types.json', + encoding='utf-8', + ) as f: + ser = SerializedProcessor.model_validate_json(f.read()) + proc = InterpolatedCatProcessor(ser, alpha=np.sqrt(5)) + applied = proc.apply_instruction('delay', (0,), [500]) + assert applied.quantum_errors is not None + assert applied.readout_errors is None + applied = proc.apply_instruction('mx', (0,), []) + assert applied.quantum_errors is not None + assert applied.readout_errors is not None + + +def test_all_instructions() -> None: + with open( + 'tests/processor/serialization/data/all_types.json', + encoding='utf-8', + ) as f: + ser = SerializedProcessor.model_validate_json(f.read()) + proc = InterpolatedCatProcessor(ser, alpha=np.sqrt(5)) + list(proc.all_instructions()) + instr = next(i for i in proc.all_instructions() if i.name == 'mx') + assert instr.readout_errors is not None diff --git a/tests/processor/test_physical_cat.py b/tests/processor/test_physical_cat.py new file mode 100644 index 0000000..8f4247f --- /dev/null +++ b/tests/processor/test_physical_cat.py @@ -0,0 +1,79 @@ +import numpy as np +import pytest + +from qiskit_alice_bob_provider.processor.physical_cat import ( + PhysicalCatProcessor, +) +from qiskit_alice_bob_provider.processor.utils import pauli_label_to_index + + +def test_bad_coupling_map() -> None: + with pytest.raises(ValueError): + PhysicalCatProcessor(coupling_map=[(0, 0)]) + with pytest.raises(ValueError): + PhysicalCatProcessor(n_qubits=2, coupling_map=[(0, 2)]) + with pytest.raises(ValueError): + PhysicalCatProcessor(n_qubits=2, coupling_map=[(2, 0)]) + with pytest.raises(ValueError): + PhysicalCatProcessor(n_qubits=2, coupling_map=[(0, -2)]) + with pytest.raises(ValueError): + PhysicalCatProcessor(n_qubits=2, coupling_map=[(-2, 0)]) + + +def test_cx_prefactor() -> None: + proc = PhysicalCatProcessor( + kappa_1=100, kappa_2=10_000_000, alpha=np.sqrt(19) + ) + ret = proc.apply_instruction('cx', (0, 1), []) + terms = ['IX', 'XX', 'XI', 'IY', 'XY', 'XZ'] + s = -np.infty + assert ret.quantum_errors is not None + for term in terms: + idx = pauli_label_to_index(term) + s = np.logaddexp(s, np.log(ret.quantum_errors[idx, idx])) + assert np.exp(s) == pytest.approx(0.5 * np.exp(-2 * 19)) + + +def test_idle_prefactor() -> None: + proc = PhysicalCatProcessor(kappa_1=100, kappa_2=10_000, alpha=np.sqrt(8)) + ret = proc.apply_instruction('delay', (0,), [1e-4]) + terms = ['X', 'Y'] + s = -np.infty + assert ret.quantum_errors is not None + for term in terms: + idx = pauli_label_to_index(term) + s = np.logaddexp(s, np.log(ret.quantum_errors[idx, idx])) + assert np.exp(s) == pytest.approx(1e-11) + + +def test_parameter_validation() -> None: + with pytest.raises(ValueError): + PhysicalCatProcessor(alpha=-3) + with pytest.raises(ValueError): + PhysicalCatProcessor(kappa_1=2) + with pytest.raises(ValueError): + PhysicalCatProcessor(kappa_1=100, kappa_2=100_000_000_000) + PhysicalCatProcessor(kappa_1=10) + PhysicalCatProcessor(kappa_1=10, kappa_2=10_000) + PhysicalCatProcessor(alpha=2) + + +def test_unrealistic_probabilities() -> None: + proc = PhysicalCatProcessor(kappa_1=10_000, alpha=400) + with pytest.raises(ValueError): + proc.apply_instruction('cx', (0, 1), []) + + +def test_all_instructions() -> None: + proc = PhysicalCatProcessor() + proc.apply_instruction('mx', (0,), []) + proc.apply_instruction('mz', (0,), []) + proc.apply_instruction('delay', (0,), [1e-4]) + proc.apply_instruction('p+', (0,), []) + proc.apply_instruction('p-', (0,), []) + proc.apply_instruction('p0', (0,), []) + proc.apply_instruction('p1', (0,), []) + proc.apply_instruction('x', (0,), []) + proc.apply_instruction('rz', (0,), [1.57]) + proc.apply_instruction('z', (0,), []) + proc.apply_instruction('cx', (0, 1), []) diff --git a/tests/processor/test_utils.py b/tests/processor/test_utils.py new file mode 100644 index 0000000..c19bc33 --- /dev/null +++ b/tests/processor/test_utils.py @@ -0,0 +1,102 @@ +import numpy as np +import pytest + +from qiskit_alice_bob_provider.processor.utils import ( + full_flip_error, + index_to_pauli_label, + pauli_errors_to_chi, + pauli_label_to_index, +) + + +def test_1_qubit_gate() -> None: + d = {'X': 0.3, 'Y': 0.2, 'Z': 0.4} + chi = pauli_errors_to_chi(d) + diag = np.diag(chi) + + # Check Pauli errors + assert diag[0] == pytest.approx(0.1) + assert diag[1] == pytest.approx(0.3) + assert diag[2] == pytest.approx(0.2) + assert diag[3] == pytest.approx(0.4) + + # Check off-diagonals are all zeros + for i in range(chi.shape[0]): + chi[i, i] = 0 + assert np.all(chi == 0) + + +def test_2_qubit_gate() -> None: + d = { + 'XI': 0.3, + 'IY': 0.2, + 'ZY': 0.4, + 'II': 0.2 # II is wrong but this should not matter because it is + # recomputed anyway by pauli_errors_to_chi + } + chi = pauli_errors_to_chi(d) + diag = np.diag(chi) + + # Check Pauli errors + assert diag[0] == pytest.approx(0.1) + assert diag[4] == pytest.approx(0.3) + assert diag[2] == pytest.approx(0.2) + assert diag[14] == pytest.approx(0.4) + + # Check off-diagonals are all zeros + for i in range(chi.shape[0]): + chi[i, i] = 0 + assert np.all(chi == 0) + + +def test_bad_probabilities() -> None: + with pytest.raises(ValueError): + pauli_errors_to_chi({'XI': 0.5, 'ZY': 0.6}) + with pytest.raises(ValueError): + pauli_errors_to_chi({'XI': 0.5, 'ZY': -0.1}) + + +def test_bad_label() -> None: + with pytest.raises(ValueError): + pauli_errors_to_chi({'A': 0.2}) + + +@pytest.mark.parametrize('label', ['ZI', 'YYZ', 'I', 'XZX']) +def test_label_conversion(label: str) -> None: + n_qubits = len(label) + assert label == index_to_pauli_label(n_qubits, pauli_label_to_index(label)) + + +def test_flip_error() -> None: + # extreme case: one of rx * t, ry * t, rz * t is large, + # the two others are zero + for idx in range(3): + input, output = [0.0] * 3, [0.0] * 3 + input[idx] = 1e10 + output[idx] = 0.5 + assert np.array_equiv(full_flip_error(input), output) + + # extreme case: t is 0 + assert np.array_equiv(full_flip_error([0.0, 0.0, 0.0]), [0, 0, 0]) + + # extreme case: all are large + assert np.array_equiv( + full_flip_error([1e10, 1e10, 1e10]), [0.25, 0.25, 0.25] + ) + + input_2d = [ + [1e10, 0, 0], + [0, 1e10, 0], + ] + output_2d = [ + [0.5, 0, 0], + [0, 0.5, 0], + ] + assert np.array_equiv(full_flip_error(input_2d), output_2d) + + # extreme case: all are very small, they don't influence each other + input = [1e-12, 1e-13, 1e-14] + expected = [1e-12, 1e-13, 1e-14] + out = full_flip_error(input) + for i in range(3): + assert out[i] == pytest.approx(expected[i])