I am running an instance of amplitude amplification using Qiskit (v 26) on Google Colab.

The circuit is approximately 17 qubits in space and $O(ck)$ in depth where $k \in \left \{1,2,3....,22 \right \}$ and $c\approx120$.
k is related to the number of amplifications in Amplitude Amplification

I've already gotten results when $k < 15$, but for any other case I seem to get an "out of memory" problem (i've got approximately 27 RAM on my colab notebook)

Are there any good options on simulating such circuit on qiskit while keeping the limit on memory at bay?

I am working towards simply running each amplification separately, save the statevector on memory, and recycle the circuit over and over until I get the k amplifications. Are there any other options (maybe possibly within Qiskit)?

  • $\begingroup$ Hello, did you try to play with the different kind of simulation? For example, the simulators available on the cloud and the ones available via Aer $\endgroup$
    – Lena
    Jul 16 at 13:23
  • 1
    $\begingroup$ Thank you! Yes, I tried that way but seems depth was causing some trouble as well. On side news I was able to run my code successfully by just evolving my statevector by parts (1 amplification at a time) and keeping the evolution of my statevector on memory. :) $\endgroup$ Jul 16 at 20:58

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.