diff --git a/.pylintrc b/.pylintrc index aa3c5a2..e0bbf47 100644 --- a/.pylintrc +++ b/.pylintrc @@ -543,11 +543,3 @@ max-statements=50 # Minimum number of public methods for a class (see R0903). min-public-methods=2 - - -[EXCEPTIONS] - -# Exceptions that will emit a warning when being caught. Defaults to -# "BaseException, Exception". -overgeneral-exceptions=BaseException, - Exception diff --git a/pyproject.toml b/pyproject.toml index 74a79dd..4bfb339 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -26,7 +26,7 @@ requires-python = ">=3.8" dependencies = [ "mapomatic==0.9", "qiskit-aer", - "qiskit==0.42.1", + "qiskit==0.46.0", ] [project.optional-dependencies] diff --git a/qiskit_research/utils/backend.py b/qiskit_research/utils/backend.py index ba77859..d32c48b 100644 --- a/qiskit_research/utils/backend.py +++ b/qiskit_research/utils/backend.py @@ -10,10 +10,8 @@ """Utilities for dealing with backends.""" - from typing import Optional -from qiskit import BasicAer from qiskit.providers import Backend, Provider from qiskit_aer import AerSimulator @@ -26,6 +24,4 @@ def get_backend( return provider.get_backend(name) if name == "aer_simulator": return AerSimulator(seed_simulator=seed_simulator) - if name == "statevector_simulator": - return BasicAer.get_backend("statevector_simulator") raise ValueError("The given name does not match any supported backends.") diff --git a/qiskit_research/utils/dynamical_decoupling.py b/qiskit_research/utils/dynamical_decoupling.py index c71d10f..547a510 100644 --- a/qiskit_research/utils/dynamical_decoupling.py +++ b/qiskit_research/utils/dynamical_decoupling.py @@ -13,31 +13,29 @@ from __future__ import annotations from enum import Enum - from typing import Iterable, List, Optional, Sequence, Union +import numpy as np from qiskit import QuantumCircuit, pulse from qiskit.circuit import Gate, Qubit from qiskit.circuit.delay import Delay -from qiskit.circuit.library import XGate, YGate, UGate, U3Gate +from qiskit.circuit.library import U3Gate, UGate, XGate, YGate from qiskit.circuit.reset import Reset from qiskit.converters import circuit_to_dag from qiskit.dagcircuit import DAGCircuit, DAGInNode, DAGNode, DAGOpNode from qiskit.providers.backend import Backend from qiskit.pulse import Drag, Waveform from qiskit.qasm import pi -from qiskit.quantum_info import OneQubitEulerDecomposer +from qiskit.synthesis import OneQubitEulerDecomposer from qiskit.transpiler import InstructionDurations from qiskit.transpiler.basepasses import BasePass from qiskit.transpiler.exceptions import TranspilerError from qiskit.transpiler.instruction_durations import InstructionDurationsType -from qiskit.transpiler.passes import PadDynamicalDecoupling, Optimize1qGates +from qiskit.transpiler.passes import Optimize1qGates, PadDynamicalDecoupling from qiskit.transpiler.passes.scheduling import ALAPScheduleAnalysis from qiskit.transpiler.passes.scheduling.scheduling.base_scheduler import BaseScheduler -import numpy as np - -from qiskit_research.utils.gates import XmGate, XpGate, YmGate, YpGate, PiPhiGate +from qiskit_research.utils.gates import PiPhiGate, XmGate, XpGate, YmGate, YpGate from qiskit_research.utils.periodic_dynamical_decoupling import ( PeriodicDynamicalDecoupling, ) diff --git a/qiskit_research/utils/pulse_scaling.py b/qiskit_research/utils/pulse_scaling.py index d217ecf..7d74627 100644 --- a/qiskit_research/utils/pulse_scaling.py +++ b/qiskit_research/utils/pulse_scaling.py @@ -264,6 +264,7 @@ def run(self, dag: DAGCircuit) -> DAGCircuit: return dag +# pylint: disable-next=too-many-ancestors class SECRCalibrationBuilder(RZXCalibrationBuilderNoEcho): """ Creates calibrations for SECRGate(theta) by stretching and compressing