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

Got efficiency bug in synthesis, when running a quantum circuit with a complex numerical initialization #7106

Open
TigrisCallidus opened this issue Oct 6, 2021 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@TigrisCallidus
Copy link

Information

  • Qiskit Terra version: 0.18.3 (Run a pip install qiskit --update just today)
  • Python version: 3.8.5
  • Operating system: Windows 10

What is the current behavior?

I get a warning telling me to open an issue:

"
C:\Users\USERNAME\anaconda3\lib\site-packages\qiskit\transpiler\runningpassmanager.py:166: UserWarning: Resynthesized

<qiskit.circuit.library.standard_gates.rz.RZGate object at 0x000001D5C8F1BCA0>
<qiskit.circuit.library.standard_gates.sx.SXGate object at 0x000001D5C8F1B760>
<qiskit.circuit.library.standard_gates.rz.RZGate object at 0x000001D5C8F1BC70>
<qiskit.circuit.library.standard_gates.sx.SXGate object at 0x000001D5C8F1B520>

and got

<qiskit.circuit.library.standard_gates.rz.RZGate object at 0x000001D5C71C06A0>
<qiskit.circuit.library.standard_gates.sx.SXGate object at 0x000001D5C71C0AC0>
<qiskit.circuit.library.standard_gates.rz.RZGate object at 0x000001D5C71C0DF0>
<qiskit.circuit.library.standard_gates.sx.SXGate object at 0x000001D5C71C0490>
<qiskit.circuit.library.standard_gates.rz.RZGate object at 0x000001D5C71C0610>

but the original was native (for ['id', 'rz', 'sx', 'x', 'cx', 'reset']) and the new value is longer. This indicates an efficiency bug in synthesis. Please report it by opening an issue here: https://github.com/Qiskit/qiskit-terra/issues/new/choose
new_dag = pass_.run(dag)
C:\Users\USERNAME\anaconda3\lib\site-packages\qiskit\transpiler\runningpassmanager.py:166: UserWarning: Resynthesized

<qiskit.circuit.library.standard_gates.rz.RZGate object at 0x000001D5C8F1BCA0>
<qiskit.circuit.library.standard_gates.sx.SXGate object at 0x000001D5C8F1B760>
<qiskit.circuit.library.standard_gates.rz.RZGate object at 0x000001D5C8F1BC70>
<qiskit.circuit.library.standard_gates.sx.SXGate object at 0x000001D5C8F1B520>

and got

<qiskit.circuit.library.standard_gates.rz.RZGate object at 0x000001D5C68BB820>
<qiskit.circuit.library.standard_gates.sx.SXGate object at 0x000001D5C68BB280>
<qiskit.circuit.library.standard_gates.rz.RZGate object at 0x000001D5C68BB160>
<qiskit.circuit.library.standard_gates.sx.SXGate object at 0x000001D5C68BBFD0>
<qiskit.circuit.library.standard_gates.rz.RZGate object at 0x000001D5C68BB1C0>

but the original was native (for ['id', 'rz', 'sx', 'x', 'cx', 'reset']) and the new value is longer. This indicates an efficiency bug in synthesis. Please report it by opening an issue here: https://github.com/Qiskit/qiskit-terra/issues/new/choose
new_dag = pass_.run(dag)
"

Steps to reproduce the problem

I need quite complex initialization for my circuits (interpreting data as a quantum circuit),
and need a big number of shots to make the outcome of the manipulation work.

You can reproduce the bug by running the following python file (between the "") and insert your authentification key into the placeholder INSERTAUTHKEY.

"

from qiskit import(
QuantumCircuit,
execute,
IBMQ)
#Aer)

#simulator = Aer.get_backend('qasm_simulator')

qc = QuantumCircuit(10,10)
qc.initialize([0.0239156556755145,0.00786341921068633,0.00786341921068633,0.00786341921068633,0.0279400457639128,0.0279400457639128,0.0159706798861084,0.0159706798861084,0.0338218446093577,0.0370916736149376,0.0370916736149376,0.0370916736149376,0.0328950424599036,0.0365670125262393,0.0365670125262393,0.0365670125262393,0.0159706798861084,0.0279400457639128,0.0429798973754556,0.0362485709679208,0.0259314054226408,0.0359273070148409,0.0436933053538568,0.0436933053538568,0.0294222198263144,0.0294222198263144,0.0194609692642965,0.0194609692642965,0.0251752247404158,0.0111205540943777,0.0111205540943777,0.0111205540943777,0.00786341921068633,0.00786341921068633,0.0239156556755145,0.00786341921068633,0.0362485709679208,0.0362485709679208,0.0279400457639128,0.0362485709679208,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0159706798861084,0.0279400457639128,0.0429798973754556,0.0429798973754556,0.0259314054226408,0.0259314054226408,0.0436933053538568,0.0359273070148409,0.0429798973754556,0.0367777751322631,0.0294222198263144,0.0367777751322631,0.0111205540943777,0.0111205540943777,0.0251752247404158,0.0111205540943777,0.0239156556755145,0.0239156556755145,0.0399024935530277,0.0328950424599036,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0370916736149376,0.0370916736149376,0.0338218446093577,0.0338218446093577,0.0399024935530277,0.0365670125262393,0.0328950424599036,0.0365670125262393,0.0362485709679208,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.00786341921068633,0.00786341921068633,0.0359273070148409,0.0259314054226408,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0111205540943777,0.0251752247404158,0.0406699194256651,0.0338218446093577,0.00786341921068633,0.00786341921068633,0.0328950424599036,0.0239156556755145,0.0429798973754556,0.0429798973754556,0.0362485709679208,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0279400457639128,0.0362485709679208,0.0429798973754556,0.0429798973754556,0.00786341921068633,0.0259314054226408,0.0359273070148409,0.0359273070148409,0.0429798973754556,0.0429798973754556,0.0367777751322631,0.0429798973754556,0.0111205540943777,0.0111205540943777,0.0338218446093577,0.0251752247404158,0.0429798973754556,0.0429798973754556,0.0298136634345013,0.0347239186602003,0.0111205540943777,0.0111205540943777,0.0111205540943777,0.0111205540943777,0.025480390093474,0.0308332269106948,0.0308332269106948,0.0308332269106948,0.0182305871806256,0.0247104114262124,0.0298136634345013,0.0298136634345013,0.0429798973754556,0.0429798973754556,0.0225859520952537,0.0308332269106948,0.0357115254610254,0.0294222198263144,0.00786341921068633,0.00786341921068633,0.0111205540943777,0.0111205540943777,0.0111205540943777,0.0111205540943777,0.0429798973754556,0.0429798973754556,0.0287579758161983,0.0388225209064403,0.0429798973754556,0.0429798973754556,0.0347239186602003,0.0429798973754556,0.0111205540943777,0.0111205540943777,0.0259314054226408,0.0259314054226408,0.00786341921068633,0.00786341921068633,0.0188558165250975,0.0188558165250975,0.00786341921068633,0.00786341921068633,0.0182305871806256,0.00786341921068633,0.0429798973754556,0.0429798973754556,0.0225859520952537,0.0374029378449717,0.0294222198263144,0.0215348598073988,0.00786341921068633,0.00786341921068633,0.0111205540943777,0.0111205540943777,0.0251752247404158,0.0111205540943777,0.0388225209064403,0.0429798973754556,0.0388225209064403,0.0429798973754556,0.0298136634345013,0.0390211028562259,0.0429798973754556,0.0429798973754556,0.0350562125021794,0.0350562125021794,0.042254446204678,0.042254446204678,0.025480390093474,0.025480390093474,0.0188558165250975,0.0188558165250975,0.0298136634345013,0.0247104114262124,0.0182305871806256,0.0247104114262124,0.0374029378449717,0.0429798973754556,0.0374029378449717,0.0429798973754556,0.00786341921068633,0.00786341921068633,0.0294222198263144,0.00786341921068633,0.0338218446093577,0.0338218446093577,0.0406699194256651,0.0406699194256651,0.0287579758161983,0.0341629138197738,0.0429798973754556,0.0429798973754556,0.0390211028562259,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0259314054226408,0.0259314054226408,0.0350562125021794,0.0350562125021794,0.00786341921068633,0.00786341921068633,0.00786341921068633,0.00786341921068633,0.0182305871806256,0.00786341921068633,0.00786341921068633,0.00786341921068633,0.0429798973754556,0.0429798973754556,0.0308332269106948,0.0429798973754556,0.0215348598073988,0.00786341921068633,0.0215348598073988,0.00786341921068633,0.0111205540943777,0.0251752247404158,0.0406699194256651,0.0338218446093577,0.0341629138197738,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.00786341921068633,0.0239156556755145,0.0399024935530277,0.0328950424599036,0.0194609692642965,0.0298136634345013,0.0436933053538568,0.0374029378449717,0.03538538600716,0.03538538600716,0.0429798973754556,0.0429798973754556,0.00786341921068633,0.0229256094931904,0.0382205849481073,0.0314536768427453,0.0436933053538568,0.0359273070148409,0.00786341921068633,0.0259314054226408,0.0436933053538568,0.0364611743612511,0.013619841324577,0.0275219666704941,0.0286232773062845,0.0414231300173075,0.0194609692642965,0.0356031442636866,0.0406699194256651,0.0338218446093577,0.0111205540943777,0.0251752247404158,0.00786341921068633,0.00786341921068633,0.0399024935530277,0.0239156556755145,0.0194609692642965,0.0374029378449717,0.0436933053538568,0.0436933053538568,0.0256316103397386,0.03538538600716,0.03538538600716,0.03538538600716,0.00786341921068633,0.00786341921068633,0.0314536768427453,0.0229256094931904,0.0436933053538568,0.0359273070148409,0.00786341921068633,0.0259314054226408,0.0436933053538568,0.0364611743612511,0.013619841324577,0.0275219666704941,0.0194609692642965,0.0414231300173075,0.0286232773062845,0.0414231300173075,0.0406699194256651,0.0338218446093577,0.0111205540943777,0.0111205540943777,0.00786341921068633,0.00786341921068633,0.0239156556755145,0.00786341921068633,0.0374029378449717,0.0436933053538568,0.0374029378449717,0.0436933053538568,0.0256316103397386,0.00786341921068633,0.00786341921068633,0.00786341921068633,0.0314536768427453,0.0229256094931904,0.00786341921068633,0.00786341921068633,0.0436933053538568,0.0359273070148409,0.00786341921068633,0.0259314054226408,0.0436933053538568,0.0436933053538568,0.013619841324577,0.0275219666704941,0.0356031442636866,0.0414231300173075,0.0286232773062845,0.0414231300173075,0.0406699194256651,0.0251752247404158,0.0111205540943777,0.0111205540943777,0.00786341921068633,0.00786341921068633,0.0328950424599036,0.0239156556755145,0.0298136634345013,0.0374029378449717,0.0436933053538568,0.0436933053538568,0.00786341921068633,0.00786341921068633,0.0256316103397386,0.0256316103397386,0.0229256094931904,0.00786341921068633,0.00786341921068633,0.00786341921068633,0.0436933053538568,0.0359273070148409,0.00786341921068633,0.0259314054226408,0.0436933053538568,0.0364611743612511,0.013619841324577,0.0275219666704941,0.0286232773062845,0.0414231300173075,0.0286232773062845,0.0414231300173075,0.0406699194256651,0.0251752247404158,0.0111205540943777,0.0111205540943777,0.0414231300173075,0.0343884140262743,0.0111205540943777,0.025480390093474,0.0256316103397386,0.0256316103397386,0.00786341921068633,0.00786341921068633,0.0374029378449717,0.0374029378449717,0.0429798973754556,0.0429798973754556,0.033129173805334,0.0387228480388311,0.0387228480388311,0.0387228480388311,0.0436933053538568,0.0362485709679208,0.0111205540943777,0.0268106844923599,0.0436933053538568,0.0362485709679208,0.0111205540943777,0.0111205540943777,0.0350562125021794,0.0259314054226408,0.0111205540943777,0.0111205540943777,0.042254446204678,0.042254446204678,0.013619841324577,0.0268106844923599,0.0343884140262743,0.025480390093474,0.0111205540943777,0.0111205540943777,0.03538538600716,0.03538538600716,0.00786341921068633,0.0256316103397386,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0436933053538568,0.0436933053538568,0.0436933053538568,0.0436933053538568,0.0436933053538568,0.0362485709679208,0.0111205540943777,0.0268106844923599,0.0436933053538568,0.0362485709679208,0.0111205540943777,0.0268106844923599,0.042254446204678,0.0350562125021794,0.0111205540943777,0.0259314054226408,0.042254446204678,0.03538538600716,0.013619841324577,0.0268106844923599,0.025480390093474,0.0111205540943777,0.025480390093474,0.0111205540943777,0.0429798973754556,0.0429798973754556,0.03538538600716,0.03538538600716,0.0374029378449717,0.0308332269106948,0.0225859520952537,0.0225859520952537,0.0387228480388311,0.033129173805334,0.0263747093836333,0.033129173805334,0.0436933053538568,0.0362485709679208,0.0111205540943777,0.0268106844923599,0.0436933053538568,0.0362485709679208,0.0111205540943777,0.0268106844923599,0.042254446204678,0.042254446204678,0.0259314054226408,0.0350562125021794,0.042254446204678,0.0268106844923599,0.013619841324577,0.013619841324577,0.0343884140262743,0.025480390093474,0.0111205540943777,0.0111205540943777,0.0429798973754556,0.03538538600716,0.0256316103397386,0.03538538600716,0.0429798973754556,0.0374029378449717,0.0374029378449717,0.0374029378449717,0.0436933053538568,0.0436933053538568,0.0387228480388311,0.0387228480388311,0.0436933053538568,0.0362485709679208,0.0111205540943777,0.0268106844923599,0.0436933053538568,0.0362485709679208,0.0111205540943777,0.0268106844923599,0.042254446204678,0.042254446204678,0.0111205540943777,0.0350562125021794,0.042254446204678,0.03538538600716,0.013619841324577,0.013619841324577,0.0414231300173075,0.0343884140262743,0.0111205540943777,0.025480390093474,0.0350562125021794,0.0259314054226408,0.0111205540943777,0.0111205540943777,0.0321824300307382,0.0321824300307382,0.0391200158155482,0.0391200158155482,0.0367777751322631,0.0436933053538568,0.0436933053538568,0.0436933053538568,0.0365670125262393,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.033129173805334,0.033129173805334,0.0399024935530277,0.0399024935530277,0.0239156556755145,0.0239156556755145,0.0239156556755145,0.0239156556755145,0.0287579758161983,0.0239156556755145,0.0239156556755145,0.0239156556755145,0.0343884140262743,0.025480390093474,0.0111205540943777,0.0111205540943777,0.042254446204678,0.0350562125021794,0.0111205540943777,0.0259314054226408,0.00786341921068633,0.0234258634528594,0.0321824300307382,0.0234258634528594,0.0436933053538568,0.0436933053538568,0.0367777751322631,0.0436933053538568,0.0429798973754556,0.0429798973754556,0.0365670125262393,0.0429798973754556,0.0111205540943777,0.0247104114262124,0.033129173805334,0.0247104114262124,0.00786341921068633,0.00786341921068633,0.00786341921068633,0.00786341921068633,0.0178015721318433,0.00786341921068633,0.00786341921068633,0.00786341921068633,0.025480390093474,0.0111205540943777,0.0111205540943777,0.0111205540943777,0.042254446204678,0.042254446204678,0.0259314054226408,0.042254446204678,0.0234258634528594,0.00786341921068633,0.00786341921068633,0.00786341921068633,0.0367777751322631,0.0283519605171722,0.0159706798861084,0.0283519605171722,0.0365670125262393,0.0365670125262393,0.0178015721318433,0.0287579758161983,0.0111205540943777,0.0111205540943777,0.0111205540943777,0.0111205540943777,0.0239156556755145,0.0287579758161983,0.0287579758161983,0.0287579758161983,0.0239156556755145,0.0239156556755145,0.0287579758161983,0.0287579758161983,0.0343884140262743,0.025480390093474,0.0111205540943777,0.0111205540943777,0.042254446204678,0.042254446204678,0.0259314054226408,0.0350562125021794,0.00786341921068633,0.00786341921068633,0.0234258634528594,0.00786341921068633,0.0436933053538568,0.0367777751322631,0.0283519605171722,0.0367777751322631,0.0429798973754556,0.0429798973754556,0.0287579758161983,0.0365670125262393,0.0111205540943777,0.0111205540943777,0.0247104114262124,0.0111205540943777,0.00786341921068633,0.00786341921068633,0.0178015721318433,0.0178015721318433,0.00786341921068633,0.00786341921068633,0.0178015721318433,0.00786341921068633,0.00786341921068633,0.0229256094931904,0.0382205849481073,0.0314536768427453,0.0209895850136816,0.0300717951903588,0.0429798973754556,0.0429798973754556,0.0362485709679208,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.00786341921068633,0.00786341921068633,0.0347239186602003,0.0286232773062845,0.00786341921068633,0.0200478635416257,0.0328950424599036,0.027239682649154,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0350562125021794,0.0298136634345013,0.0298136634345013,0.0298136634345013,0.0398055250242581,0.0356031442636866,0.0308332269106948,0.0308332269106948,0.00786341921068633,0.00786341921068633,0.0382205849481073,0.0229256094931904,0.0300717951903588,0.0370916736149376,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0362485709679208,0.0429798973754556,0.00786341921068633,0.00786341921068633,0.0286232773062845,0.0209895850136816,0.00786341921068633,0.00786341921068633,0.027239682649154,0.00786341921068633,0.0429798973754556,0.0429798973754556,0.0359273070148409,0.0359273070148409,0.0436933053538568,0.0396108758281317,0.0396108758281317,0.0396108758281317,0.0436933053538568,0.0436933053538568,0.0398055250242581,0.0398055250242581,0.0229256094931904,0.00786341921068633,0.0229256094931904,0.00786341921068633,0.0370916736149376,0.0429798973754556,0.0370916736149376,0.0429798973754556,0.0362485709679208,0.0279400457639128,0.0159706798861084,0.0159706798861084,0.0347239186602003,0.0209895850136816,0.00786341921068633,0.00786341921068633,0.0328950424599036,0.0200478635416257,0.00786341921068633,0.00786341921068633,0.0270974379145711,0.0270974379145711,0.013619841324577,0.013619841324577,0.0350562125021794,0.0396108758281317,0.0396108758281317,0.0396108758281317,0.0356031442636866,0.0356031442636866,0.0398055250242581,0.0398055250242581,0.00786341921068633,0.00786341921068633,0.0314536768427453,0.0229256094931904,0.0370916736149376,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0362485709679208,0.0279400457639128,0.0362485709679208,0.0209895850136816,0.00786341921068633,0.0209895850136816,0.00786341921068633,0.0200478635416257,0.00786341921068633,0.00786341921068633,0.00786341921068633,0.0429798973754556,0.0359273070148409,0.0270974379145711,0.0270974379145711,0.0436933053538568,0.0436933053538568,0.0436933053538568,0.0436933053538568,0.0436933053538568,0.0436933053538568,0.0436933053538568,0.0436933053538568,0.0111205540943777,0.0270974379145711,0.0443952507266942,0.0367777751322631,0.00786341921068633,0.0247104114262124,0.0414231300173075,0.0340496036888053,0.0321824300307382,0.013619841324577,0.0382205849481073,0.0321824300307382,0.0111205540943777,0.0259314054226408,0.042254446204678,0.0350562125021794,0.0429798973754556,0.0429798973754556,0.0194609692642965,0.0294222198263144,0.0399024935530277,0.0328950424599036,0.00786341921068633,0.0239156556755145,0.0263747093836333,0.0263747093836333,0.0111205540943777,0.0111205540943777,0.0429798973754556,0.0374029378449717,0.0225859520952537,0.0308332269106948,0.0111205540943777,0.0270974379145711,0.0443952507266942,0.0367777751322631,0.00786341921068633,0.0247104114262124,0.0414231300173075,0.0340496036888053,0.0382205849481073,0.013619841324577,0.0321824300307382,0.013619841324577,0.0111205540943777,0.0350562125021794,0.042254446204678,0.042254446204678,0.0429798973754556,0.0429798973754556,0.0194609692642965,0.0367777751322631,0.0399024935530277,0.0239156556755145,0.00786341921068633,0.00786341921068633,0.0356031442636866,0.0111205540943777,0.0263747093836333,0.0111205540943777,0.0429798973754556,0.0429798973754556,0.0308332269106948,0.0374029378449717,0.0111205540943777,0.0270974379145711,0.0443952507266942,0.0367777751322631,0.00786341921068633,0.00786341921068633,0.0414231300173075,0.0340496036888053,0.0321824300307382,0.013619841324577,0.0321824300307382,0.013619841324577,0.0259314054226408,0.0350562125021794,0.042254446204678,0.042254446204678,0.0429798973754556,0.0429798973754556,0.0367777751322631,0.0429798973754556,0.0239156556755145,0.00786341921068633,0.0239156556755145,0.00786341921068633,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0308332269106948,0.0374029378449717,0.0429798973754556,0.0429798973754556,0.0111205540943777,0.0270974379145711,0.0443952507266942,0.0367777751322631,0.00786341921068633,0.00786341921068633,0.0414231300173075,0.0340496036888053,0.0382205849481073,0.013619841324577,0.0321824300307382,0.013619841324577,0.0259314054226408,0.0350562125021794,0.042254446204678,0.042254446204678,0.0429798973754556,0.0429798973754556,0.0294222198263144,0.0367777751322631,0.0328950424599036,0.00786341921068633,0.00786341921068633,0.00786341921068633,0.0429798973754556,0.0356031442636866,0.0356031442636866,0.0356031442636866,0.0374029378449717,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0111205540943777,0.0268106844923599,0.0436933053538568,0.0362485709679208,0.00786341921068633,0.0251752247404158,0.042254446204678,0.0347239186602003,0.0256316103397386,0.03538538600716,0.0429798973754556,0.0429798973754556,0.0111205540943777,0.0259314054226408,0.042254446204678,0.0350562125021794,0.013619841324577,0.0270974379145711,0.0429798973754556,0.0359273070148409,0.03538538600716,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.0234258634528594,0.0111205540943777,0.0111205540943777,0.0111205540943777,0.0294222198263144,0.0215348598073988,0.00786341921068633,0.0215348598073988,0.0111205540943777,0.0268106844923599,0.0436933053538568,0.0362485709679208,0.00786341921068633,0.0251752247404158,0.042254446204678,0.0347239186602003,0.00786341921068633,0.0256316103397386,0.0429798973754556,0.03538538600716,0.0111205540943777,0.0259314054226408,0.042254446204678,0.0350562125021794,0.0270974379145711,0.0359273070148409,0.0429798973754556,0.0429798973754556,0.0256316103397386,0.03538538600716,0.0429798973754556,0.03538538600716,0.0111205540943777,0.0111205540943777,0.0111205540943777,0.0111205540943777,0.00786341921068633,0.00786341921068633,0.00786341921068633,0.00786341921068633,0.0111205540943777,0.0268106844923599,0.0436933053538568,0.0362485709679208,0.00786341921068633,0.00786341921068633,0.042254446204678,0.0347239186602003,0.00786341921068633,0.00786341921068633,0.03538538600716,0.0256316103397386,0.0259314054226408,0.0350562125021794,0.042254446204678,0.042254446204678,0.0359273070148409,0.0429798973754556,0.0429798973754556,0.0429798973754556,0.00786341921068633,0.00786341921068633,0.03538538600716,0.0256316103397386,0.0312069766174832,0.0374029378449717,0.0374029378449717,0.0374029378449717,0.0215348598073988,0.0294222198263144,0.0357115254610254,0.0357115254610254,0.0111205540943777,0.0268106844923599,0.0436933053538568,0.0362485709679208,0.00786341921068633,0.0251752247404158,0.042254446204678,0.0347239186602003,0.00786341921068633,0.00786341921068633,0.03538538600716,0.0256316103397386,0.0111205540943777,0.0350562125021794,0.042254446204678,0.042254446204678,0.0270974379145711,0.0359273070148409,0.0429798973754556,0.0429798973754556,0.00786341921068633,0.0256316103397386,0.03538538600716,0.0256316103397386,0.0111205540943777,0.0234258634528594,0.0234258634528594,0.0234258634528594,0.00786341921068633,0.00786341921068633,0.0215348598073988,0.0215348598073988],[0,1,2,3,4,5,6,7,8,9])
qc.rx(0.25, 0)
qc.rx(0.25, 1)
qc.rx(0.25, 2)
qc.rx(0.25, 3)
qc.rx(0.25, 4)
qc.rx(0.25, 5)
qc.rx(0.25, 6)
qc.rx(0.25, 7)
qc.rx(0.25, 8)
qc.rx(0.25, 9)
qc.measure([0,1,2,3,4,5,6,7,8,9], [0,1,2,3,4,5,6,7,8,9])

qcs=[qc]

numCircuits=10

for x in range(numCircuits):
qcs.append(qc.copy(str(x)))

IBMQ.enable_account('INSERTAUTHKEY')
provider = IBMQ.get_provider(hub = 'ibm-q-internal')
device = provider.get_backend('ibmq_sydney')
job = execute(qc, backend = device, shots= 8000)

#job = execute(qcs, simulator, shots=8000)

result = job.result()

IBMQ.disable_account()

for circuit in qcs:
counts=result.get_counts(circuit)
print(counts)
print("\n")

"

What is the expected behavior?

Not getting a warning telling me there is a bug I should report. (So having no efficiency bug)

Suggested solutions

No idea. (Maybe rounding too long numbers in initialization a bit could help?`)

@TigrisCallidus TigrisCallidus added the bug Something isn't working label Oct 6, 2021
@jakelishman
Copy link
Member

Thanks for the report! This particular form of efficiency bug is one we've had a couple of reports on (e.g. #7042 (comment)), and in this case, we've got a handle on it, and a fix will hopefully land in #7084, but it might not be in time for Terra 0.19.

@TigrisCallidus
Copy link
Author

Thanks for the report! This particular form of efficiency bug is one we've had a couple of reports on (e.g. #7042 (comment)), and in this case, we've got a handle on it, and a fix will hopefully land in #7084, but it might not be in time for Terra 0.19.

I was not sure if its the same issue, so thank you for the reply I am not in a hurry for a fix, so take your time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants