Questions tagged [qiskit]

Quantum computing framework for writing programs and applications

Qiskit is an open-source software development kit (SDK) for working with quantum computers at the level of circuits, pulses, and algorithms.

237 questions
2
votes
0 answers

Quantum amplitude encoding

I would like to perform the Quantum Fourier Transform (QFT) of a sequence of, say, 8 elements. I have then the problem of encoding the sequence of 8 elements into 3 qubits. My question is how performing this task with Qiskit. I would say that one…
Vitality
  • 20,705
  • 4
  • 108
  • 146
2
votes
1 answer

How to call EnergyInput() function in Qiskit python?

I want to implement SVM with Qiskit. I used this following code. from qiskit import Aer from qiskit.aqua.utils import split_dataset_to_data_and_labels from qiskit.aqua.input import get_input_instance from qiskit.aqua import run_algorithm n =…
Protik Nag
  • 511
  • 5
  • 20
2
votes
1 answer

What does the function state_fidelity() do in Qiskit?

I am trying to solve a system of linear equation using HHL algorithm in Qiskit. I have a problem with understanding the purpose of the following function. state_fidelity() To understand this I have followed their official documentation. But it is…
Protik Nag
  • 511
  • 5
  • 20
2
votes
1 answer

How to change input qubits (q3 and q4) in 5qubit quantum circuit

Working on a quantum using qiskit. I would want to change the input qubit q4, q3 while measuring the output q2, q1 and record the probabilities of possible outcome as far attached . Question: How do I change the input in qiskit? Already created…
arilwan
  • 3,374
  • 5
  • 26
  • 62
2
votes
1 answer

Unable to find module qiskit_aqua.algorithms

pip-install qiskit-aqua completed successfully. Following is ths stack trace: ModuleNotFoundError Traceback (most recent call last) in () 2 import sys 3 from datasets import…
Abhishek
  • 23
  • 4
1
vote
0 answers

How to Calculate the Quantum Cost of Qiskit Circuit

I want to calculate the Quantum cost of this qiskit circuit, e.g as i know x-gate has the cost 1 and there are 4 x-gate so quantum cost for x-gate will be 4. What about ccx gate? How can i calculate its cost.? circuit.x(qr[1]) …
1
vote
1 answer

Resolving deprecation warnings of Qiskit's `QuantumInstance`

This code finds the solution to the Max-Cut problem for a given graph using both classical and quantum algorithms. The Max-Cut problem is a well-known problem in computer science and combinatorial optimization, which seeks to divide the vertices of…
PapaGhost
  • 13
  • 4
1
vote
1 answer

Probelm in retreiving backend to run a repeat until success circuit on qiskit

I'm trying to run a repeat until success circuit on hardware by following instructions from qiskit tutorials. Here is the code: from qiskit_ibm_provider import IBMProvider, least_busy provider = IBMProvider() hub = "\" group =…
user237666
  • 11
  • 1
1
vote
1 answer

Incorrect results in ground state evaluation via Qiskit Nature when using Qiskit Aer Estimator

I am using the Qiskit Aer estimator in order to evaluate the ground state of molecules via qiskit nature on local simulators using vqe, with and without noise model. My results are completely off. To illustrate the problem, let me add here the…
1
vote
1 answer

How to group gates manually (and make circuit more readable)?

I'm trying to make my circuit look readable, but the gates auto-order in Qiskit QuantumCircuit shifts all gates to the left side. For example an image from qiskit documentation: It would be much better to put ancilla X gate into the first column,…
Oxoron
  • 664
  • 1
  • 7
  • 26
1
vote
3 answers

ModuleNotFoundError: No module named 'qiskit.chemistry'

Ive been trying to solve this issue but this line is causing me trouble from qiskit.chemistry.core import Hamiltonian, TransformationType I know that i have to use qiskit nature instead of qiskit chemistry but i dont know to what i have to migrade…
1
vote
2 answers

How do I use specific module in Qiskit Runtime?

I am using qiskit runtime and I need to serialize a class pass it in json format and rebuild the class once the program is uploaded. For this I wanted to use import jsonpickle which would make it very simple but if I try to import it I get the…
josetomas
  • 11
  • 1
1
vote
0 answers

How to combine two matplotlib figures as subfigures without replotting them

What i want I want to combine two matplotlib figures in one new subplot. The two figures are returned from visualization functions of libraries i don't want to or can't change myself(rebuild from source etc.). Also it should be not a hack-around but…
Henning
  • 11
  • 1
1
vote
0 answers

What's the difference between pauliOp and SparsePauliOp in Qiskit?

Recently I was building my own PauliOPerator component, but when I looked up the QIskit literature, I wondered what was the difference between PauliOPerator and SparsePauliOPerator, especially in the underlying implementation I want to know how to…
1
vote
1 answer

How do I get access to the Qiskit Slack Channel

I have been trying to join https://qiskit.slack.com but there seems to be no possible way. It sends a verification code to my email, but no matter what verification code it sends me, it will not accept it. Does someone need to send me an invitation.…
Eric Kolotyluk
  • 1,958
  • 2
  • 21
  • 30
1 2
3
15 16