TransWikia.com

CSV files cut results short in ibm-q-experience?

Quantum Computing Asked on November 20, 2021

I have noticed that the csv files exported for results don’t have the resolution to correctly describe the output states for larger sets of qubits. It looks like it only exports numbers up to 15 digits long without cutting them. For example, if I try to get results on 17 qubits, it doesn’t carry the information about the last two numbers, so when I change the format to “custom”, in Excel, with 17 0’s, and I have done a circuit with qubits 0, 1, 15 and 16 in superposition and the rest left as 0, there will be, for example, 4 results at the end listed as “11000000000000000”.

Has this been addressed before? Am I doing something wrong? Is there a solution?

One Answer

I think the problem you are experiencing comes from Excel and not IBM Quantum Experience. Check this explanation, it explains why the bug you have happens, and ways to work around it.
Hope this will help :)

Edit : I think I found another workaround to your problem. Try this and tell me if this works for you:

  1. Download the CSV file but don't touch it yet.
  2. Open a new Excel file.
  3. Click the "Data" tab, then click on "Get data" on the upper left, then "From file", then "From text/CSV".
  4. Choose your CSV file you want to download.
  5. Normally, at this point you should have a window popping to your screen, and at the bottom of it 3 buttons, "Load", "Transform data", and "Cancel". Click on "Transform data".
  6. Select the first column (the one with all the states) then click on the "Transform" tag at the top of the window, you should have an option right below "Data type : Decimal number". Click on this and select "Text". Click on "File" and select "Close and load".

When I do this, the sheet downloads well and I have the full state written without the bug you mentioned. Does this work for you?

Answered by Lena on November 20, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP