Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SDS-1118] Qiskit 1 support #168

Merged
merged 2 commits into from
Apr 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docs/examples/grover_algorithm_qi.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
"from qiskit import transpile, QuantumCircuit, QuantumRegister, ClassicalRegister\n",
"from qiskit_aer import Aer\n",
"from qiskit.providers.basic_provider import BasicProvider\n",
"from qiskit.tools.visualization import circuit_drawer, plot_histogram\n",
"from qiskit.visualization import circuit_drawer, plot_histogram\n",
"from IPython.display import display, Math, Latex\n",
"\n",
"from quantuminspire.credentials import get_authentication\n",
Expand Down
2 changes: 1 addition & 1 deletion docs/examples/qi-performance-test.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
"from IPython.display import display\n",
"\n",
"from qiskit import QuantumCircuit, ClassicalRegister, QuantumRegister, transpile\n",
"from qiskit.tools.visualization import plot_histogram, circuit_drawer\n",
"from qiskit.visualization import plot_histogram, circuit_drawer\n",
"\n",
"from quantuminspire.credentials import get_authentication\n",
"from quantuminspire.qiskit import QI\n",
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ def get_long_description():
install_requires=['coverage>=4.5.1', 'matplotlib>=2.1', 'pylatexenc', 'coreapi>=2.3.3', 'numpy>=1.20', 'jupyter',
'nbimporter', 'qilib', 'setuptools'],
extras_require={
"qiskit": ["qiskit>=0.46,<1.0", "qiskit-aer"],
"qiskit": ["qiskit>=1.0", "qiskit-aer"],
"projectq": ["projectq>=0.8.0"],
"dev": ["pytest>=3.3.1", "pylint", "mypy>=0.670"],
"rtd": ["sphinx", "sphinx_rtd_theme", "nbsphinx", "sphinx-automodapi", "recommonmark"],
Expand Down
2 changes: 1 addition & 1 deletion src/quantuminspire/version.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = '2.2.2'
__version__ = '2.3.0'
12 changes: 0 additions & 12 deletions src/tests/quantuminspire/qiskit/test_circuit_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -293,24 +293,12 @@ def test_generate_cqasm_correct_output_reset_qubits(self):
self.assertTrue('prep_z q[1]\nprep_z q[2]\n' in result)

def test_generate_cqasm_correct_output_identity(self):
qc = QuantumCircuit(2, 2)
qc.i(0)
result = self._generate_cqasm_from_circuit(qc)
self.assertTrue('I q[0]\n' in result)

qc = QuantumCircuit(2, 2)
qc.id(0)
result = self._generate_cqasm_from_circuit(qc)
self.assertTrue('I q[0]\n' in result)

def test_generate_cqasm_correct_output_conditional_identity(self):
q = QuantumRegister(8, "q")
c = ClassicalRegister(8, "c")
qc = QuantumCircuit(q, c, name="test")
qc.i(0).c_if(c, 14)
result = self._generate_cqasm_from_circuit(qc)
self.assertTrue('not b[0,4,5,6,7]\nC-I b[0,1,2,3,4,5,6,7], q[0]\nnot b[0,4,5,6,7]\n' in result)

q = QuantumRegister(8, "q")
c = ClassicalRegister(8, "c")
qc = QuantumCircuit(q, c, name="test")
Expand Down