Quantum Computing in the NISQ era - Alba Cervera-Lierta

46
Quantum Computing in the NISQ era Alba Cervera-Lierta University of Toronto UCL Quantum Technologies Winter School 2020

Transcript of Quantum Computing in the NISQ era - Alba Cervera-Lierta

Page 1: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Quantum Computing in the NISQ era

Alba Cervera-Lierta

University of Toronto

UCL Quantum Technologies Winter School 2020

Page 2: Quantum Computing in the NISQ era - Alba Cervera-Lierta

The MatterLab

Alán Aspuru-Guzik

https://www.matter.toronto.edu/

Our MissionTo accelerate the discovery of new chemicals and materials that are useful to society by means of new technologies such as quantum computing, machine learning, and automation.

Page 3: Quantum Computing in the NISQ era - Alba Cervera-Lierta

The Quantum MatterLab

https://www.matter.toronto.edu/

Postdocs

PhD students

+ visitors and undergrad

Page 4: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Brief introduction to quantum computing

NISQ vs Fault-Tolerant QC

Variational Quantum Algorithms

A tool for NISQ: Tequila

A NISQ example: Meta-VQE

Comments and Remarks

Outlook

Slides will be availableat

albacl.github.io/talk/

Page 5: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Brief story of Quantum Computing

The “Quantum Bible”:

“Quantum Computation and Quantum Information”, Michael A. Nielsen & Isaac L. Chuang

Practical approach:

Qiskit and Pennylane quantum algorithm tutorials

More learning resources (books, blogs, courses, …):

https://qosf.org/learn_quantum/

Page 6: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Brief history of quantum mechanics

Prenatal

1900-1930

Infancy

1930-1950

Childhood

1950-1980

Adolescence

1980-2000

Youth

2000-

First applications:e.g. nuclear energy,…

Quantum theorybirth (1900)Postulates (1926)

Transistor (1947), Solar Cells (1954), GPS (1955), Laser (1960), MRI (1971), …

First Quantum chips (2005), Quantum teleportation withsatellites (2017),Quantum advantage (2019)

Q Turing Machine, Quantum simulation (1980), Shor algorithm(1994), CNOT (1995), Bose-Einstein condensate (1997)

Quantum 1.0 Quantum 2.0

Quantum Computing in the NISQ era, Alba Cervera-Lierta, UCL Quantum Tech Winter School 2020.

Page 7: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Quantum 2.0

Ap

plic

ati

on

sT

he

ore

tic

al

fra

me

wo

rk

Quantum Information

Quantum Communication

sQuantum Cryptography

Quantum Computing

Quantum Sensing

Quantum Mechanics

Information Theory

Quantum Simulation

Quantum Metrology

Quantum Computing in the NISQ era, Alba Cervera-Lierta, UCL Quantum Tech Winter School 2020.

Page 8: Quantum Computing in the NISQ era - Alba Cervera-Lierta

What is a quantum computer

HARDWARE

Qubits

SOFTWARE

Instructions

Result

QuantumClassic

A device capable of processing data in a quantum mechanical form.A device that uses the properties of quantum mechanics to process data.

Quantum Computing in the NISQ era, Alba Cervera-Lierta, UCL Quantum Tech Winter School 2020.

Page 9: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Why do we need a quantum computer

Quantum

Quantum

Quantum Not Quantum

Powerful, but NotQuantum

MareNostrum supercomputer (BSC)

Quantum Computing in the NISQ era, Alba Cervera-Lierta, UCL Quantum Tech Winter School 2020.

Page 10: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Why do we need a quantum computer

I therefore believe it’s true that with a suitable class of quantum machines you could imitate any quantum system, including the physical world.

–Richard P. Feynman,“Simulating physics with computers”, 1982.

Quantum Computing in the NISQ era, Alba Cervera-Lierta, UCL Quantum Tech Winter School 2020.

Page 11: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Why do we need a quantum computer

“Quantum supremacy using a programmable superconducting processor”, Nature 574, 505–510(2019)

“Quantum computational advantage using photons”, Science eabe8770 (2020)

Less time… and less energy!

Quantum Computing in the NISQ era, Alba Cervera-Lierta, UCL Quantum Tech Winter School 2020.

Page 12: Quantum Computing in the NISQ era - Alba Cervera-Lierta

How does it work

0 1

Bit

𝝍

Qubit

|𝜓 = 𝛼 |0 + 𝛽 |1

|𝜓 = 𝛼 |00 + 𝛽 |01 + 𝛾 |10 + 𝛿 |11

entanglement

|𝜓 ≠ |𝜓 1⨂ |𝜓 2

Quantum Computing in the NISQ era, Alba Cervera-Lierta, UCL Quantum Tech Winter School 2020.

Page 13: Quantum Computing in the NISQ era - Alba Cervera-Lierta

A new paradigm in computation

A single operation (logic gate) affects all posible qubit states.

CNOT

|𝒙

|𝒚

|𝒙

|𝒙 ⊕ 𝒚

𝒙 𝒚 𝒙⨁𝒚

0 0 0

0 1 1

1 0 1

1 1 0

|𝜓0 = 𝛼 |00 + 𝛽 |01 + 𝛾 |10 + 𝛿 |11

𝐶𝑁𝑂𝑇|𝜓0 = 𝛼 |00 + 𝛽 |01 + 𝛾 |11 + 𝛿 |10

4 “sums” with a single physical operation!

Quantum Computing in the NISQ era, Alba Cervera-Lierta, UCL Quantum Tech Winter School 2020.

Page 14: Quantum Computing in the NISQ era - Alba Cervera-Lierta

How does it work

Groundstate

|0 |1

Excitedstate

Qubit: physical system that 1) is quantum and 2) have two well-defined states

Example: atomic orbitals Example: superconducting circuit(transmon qubit)

Quantum Computing in the NISQ era, Alba Cervera-Lierta, UCL Quantum Tech Winter School 2020.

Page 15: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Who is building a quantum computer

More information: https://quantumcomputingreport.com/… and many more!

Software

Page 16: Quantum Computing in the NISQ era - Alba Cervera-Lierta

NISQ vs Fault-Tolerant

NISQ = Noisy Intermediate Scale Quantum

Page 17: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Experimental challenges

• Scalability: how to design and construct milion-qubit chips

• Qubits are not perfect, they are “noisy”

Whichtechnology?

- Superconducting circuits- Ion traps- Photons- NV- centers- …

Quantum error correction codes

Noise-resistant algoritms(variational algorithms)

“Fault-tolerant” quantum computation

Noisy Intermediate Scale quantum computation (NISQ)

Quantum Computing in the NISQ era, Alba Cervera-Lierta, UCL Quantum Tech Winter School 2020.

Page 18: Quantum Computing in the NISQ era - Alba Cervera-Lierta

NISQ vs Fault-Tolerant

Image: “Quantum computing: near- and far-term opportunities”, Ewan Munro, Medium @quantum_wa

Who lives in the Fortress?

- Factorization algorithm- Grover search algorithm- …

Who lives in the Plains?

- Variational Quantum Eigensolver- QAOA- …

Noisy

Qubits

Logical

Qubits

~1000 noisy qubits/logical qubit

Quantum Computing in the NISQ era, Alba Cervera-Lierta, UCL Quantum Tech Winter School 2020.

Page 19: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Noisy Intermediate Scale Quantum computation

A few qubits(~100)

Noise

Decoherence

Classicaloptimizers

Different qubitsarchitectures

Something useful:

Quantum advantage

Quantum McGyver carrying a quantum advantage experiment

Quantum Computing in the NISQ era, Alba Cervera-Lierta, UCL Quantum Tech Winter School 2020.

Page 20: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Variational Quantum Algorithms

Hybrid Quantum-ClassicalAlgorithms

A.K.A.

Page 21: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Variational Quantum Eigensolver

A. Peruzzo, J. McClean, P. Shadbolt, M.-H.Yung, X.-Q. Zhou, P. J. Love, A. Aspuru-Guzik , J. L. O’Brien, Nature Comm. 5, 4213 (2014)

Bond dissociation curve of the He–H+ molecule.

Hamiltonian that can be written with Pauli strings

Quantum circuit that generates the ground stateof that Hamiltonian

Outputs of thequantum computer

e.g. Hartree-Fock

Unitary operation, e.g. Cluster operator

GOAL: find |𝝍that minimizes

Quantum Computing in the NISQ era, Alba Cervera-Lierta, UCL Quantum Tech Winter School 2020.

Page 22: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Variational Quantum Algorithm

Example: VQE, QAOA, …

Quantum circuitthat depend on

𝜽

Expectedvalue

𝜓 𝐻 𝜓

𝐦𝐢𝐧𝜽𝑬 𝜽New 𝜃

Output

|𝜓

Obs. Operator𝐻

Firstapproximationto the quantum state solution

|𝜓0

𝑬𝟎 + 𝝐

Variational principle: E = 𝜓 𝐻 𝜓 ≥ 𝐸0Classical part

Quantum Computing in the NISQ era, Alba Cervera-Lierta, UCL Quantum Tech Winter School 2020.

Page 23: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Why Variational Quantum Algorithms?

Exponentially big Hamiltonians can be represented with a polynomial number of terms that can be obtained efficiently from a quantum computer.

𝐻 = 2𝑛 × 2𝑛 matrix 𝐻 = 𝑃𝑜𝑙𝑦(𝑛) expectation values

To compute those expectation values, we need to first prepare the ground state |𝜓

1. Initial state that you know how to prepare and it’s as closer as posible to the solution (e.g. Hartree-Fock state)

2. Design a unitary operation (a.k.a. quantum circuit) that transforms that state into the ground state.

a) Use a circuit ansatz that depend on some parameters

b) Find the correct parameters by optimizing a Loss function, e.g. the expected value of the Hamiltonian

(variational principle).

Quantum Computing in the NISQ era, Alba Cervera-Lierta, UCL Quantum Tech Winter School 2020.

Page 24: Quantum Computing in the NISQ era - Alba Cervera-Lierta

A tool for the NISQ era: Tequila

HARDWARE

Qubits

SOFTWARE

Instructions

Result

QuantumClassic

Page 25: Quantum Computing in the NISQ era - Alba Cervera-Lierta

The golden era of quantum languages…

Qibo

And manymore…

https://github.com/aspuru-guzik-group/tequila

Page 26: Quantum Computing in the NISQ era - Alba Cervera-Lierta

The golden era of quantum languages…

…and quantum software tools…

Qibo

And manymore…

Mitiq

And manymore…

https://github.com/aspuru-guzik-group/tequila

Page 27: Quantum Computing in the NISQ era - Alba Cervera-Lierta

The golden era of quantum languages…

…and quantum software tools…

…plus classical tools for the NISQ era

Qibo

And manymore…

Mitiq

And manymore…

And manymore…

https://github.com/aspuru-guzik-group/tequila

Page 28: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Which language should I use?

What if I want to run the same code in

different quantum computers?

What if the language doesn’t contain

the features that I need?

Qibo

Mitiq

https://github.com/aspuru-guzik-group/tequila

Page 29: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Unification, standarization, acceleration

A quantum language to simplify andaccelerate implementation of new ideas forquantum algorithms.

https://github.com/aspuru-guzik-group/tequila

Code

https://github.com/aspuru-guzik-group/tequila

Page 30: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Noisy Intermediate Scale Quantum computation

What can we do with a few qubits

How can we deal with the noise What can we do with a few noisy qubits

Hybrid quantum-classical algorithms Variational algorithms

Applications: chemistry, QML, etc require the knowledge of the classical techniques

to compare and test

https://github.com/aspuru-guzik-group/tequila

Many quantum computers in development; need to benchmark, compare and test.

Page 31: Quantum Computing in the NISQ era - Alba Cervera-Lierta

NISQ software players

Quantum backends

Real (experiments) Simulators

Classical tools

OptimizersGradient methods

CompChem…

Abstractmanipulation

WavefunctionsQuantum gate

definitionNoise models

https://github.com/aspuru-guzik-group/tequila

Page 32: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Tequila API

https://github.com/aspuru-guzik-group/tequila

Objective function

f E Θ

Hamiltonian H

Operator

Quantum Circuit

𝑈 Θ

State

Ansatz

Expectation values

E Θ = 𝐻 𝑈 Θ

Pauli strings

- Wave-function- Draw circuit- Define gates

from Hermitianoperators

Options

- Noise- Sampling

Options

Molecule

Quantum backend(simulator or real)

Optimizer

- Method- Method options- Gradient- Initial values- …

Page 33: Quantum Computing in the NISQ era - Alba Cervera-Lierta

NISQ algorithm example:the Meta-VQE

Page 34: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Variational Quantum Eigensolver

A. Peruzzo, J. McClean, P. Shadbolt, M.-H.Yung, X.-Q. Zhou, P. J. Love, A. Aspuru-Guzik , J. L. O’Brien, Nature Comm. 5, 4213 (2014)

Bond dissociation curve of the He–H+ molecule.

GOAL: find |𝝍that minimizes

Find the atomicseparation that

minimizes the energy

min 𝐻(𝑅)

Page 35: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Pros and cons VQA

To obtain this you need to scan from 0

to 300.

Each blue point is a VQE, that is, youhave to prepare, run and optimize thequantum circuit.

Can we avoid to compute theseuninteresting points?

Quantum Computing in the NISQ era, Alba Cervera-Lierta, UCL Quantum Tech Winter School 2020.

Page 36: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Parameterized Hamiltonian 𝐻 𝜆

Training points: 𝜆𝑖 for 𝑖 = 1,… ,𝑀

Loss function with all 𝐻( 𝜆𝑖)

ACL, J. S. Kottmann and A. Aspuru-Guzik, arXiv:2009.13545 [quant-ph] (2020)

The Meta-VQE

See also: K. Mitarai, T. Yan, K. Fujii, Phys. Rev. Applied 11, 044087 (2019)

Output: 𝜱𝒐𝒑𝒕 and 𝜣𝒐𝒑𝒕

Page 37: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Option 1: run the circuit with test 𝜆 and obtain the g.s. energy profile.

Option 2: use Φ𝑜𝑝𝑡 and Θ𝑜𝑝𝑡 as starting point of a standard VQE optimization (opt-meta-VQE)

The Meta-VQE

ACL, J. S. Kottmann and A. Aspuru-Guzik, arXiv:2009.13545 [quant-ph] (2020)

Page 38: Quantum Computing in the NISQ era - Alba Cervera-Lierta

1D XXZ spin chain

14 qubits simulation, 𝜆 = 0.75

Linear encoding: 𝑅𝑧(𝑤1𝜟 + 𝜙1)𝑅𝑦(𝑤2𝜟+ 𝜙2)⨂

Processing layer: 𝑅𝑧(𝜃1)𝑅𝑦(𝜃2)⨂

Results 2 encoding + 2 processing layers

AlternatingCNOT

Meta-VQE: encoding & processing layers. Loss function with test points.GA-VQE: standard VQE (only procesinglayers) with test points lossfunction.Opt-meta-VQE: VQE optimization with opt. meta-VQE parameters as starting point. Single minimization per parameter.Opt-GA-VQE: standard VQE optimizationwith opt. GA-VQE parametersas starting point. Single minimization per parameter.

Legend

Hamiltonianparameter

Product state g.s. (easy to find)

Entangled g.s.

ACL, J. S. Kottmann and A. Aspuru-Guzik, arXiv:2009.13545 [quant-ph] (2020)

AlternatingCNOT

𝐻 =

𝑖=1

𝑛

𝜎𝑖𝑥 𝜎𝑖+1𝑥 + 𝜎𝑖

𝑦𝜎𝑖+1𝑦+ ∆𝜎𝑖

𝑧𝜎𝑖+1𝑧 + 𝜆𝜎𝑖

𝑧

Page 39: Quantum Computing in the NISQ era - Alba Cervera-Lierta

𝐻4 molecule

𝐻4 molecule in 8 spin-orbitals (STO-3G basis set)

Ansatz: k-UpCCGSD (k=2 for these results)

Linear encoding: 𝜃 = 𝛼 + 𝑑𝛽

Non-linear encoding: 𝜃 = 𝛼𝑒𝛽(𝛾−𝑑) + 𝛿 (floating Gaussians)

Meta-VQE: Linear encoding. Loss function withtest points.Opt-meta-VQE: VQE optimization with opt. meta-VQE parameters as starting point. Single minimization per parameter.nl-meta-VQE:non-linear encoding meta-VQE.Opt-nl-meta-VQE:VQE optimization with opt. nl-meta-VQE parameters as starting point.VQE0:standard VQE optimized model starting from the Hartree-Fockconfiguration

Legend

Hamiltonian Parameter(intermolecular distance)

ACL, J. S. Kottmann and A. Aspuru-Guzik, arXiv:2009.13545 [quant-ph] (2020)

Page 40: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Single transmon

Single transmon simulation using QCAD mapping

Ansatz: 1 encoding + 1 processing layers + 1 final layer of 𝑅𝑥𝑅𝑧

Layer: 𝑅𝑥𝑅𝑧+ all connected 𝑋𝑋 gates

Parameters of 𝑋𝑋 gates are the same in all layers (same entanglement gate)

Linear encoding: 𝑅𝑥(𝑤1𝒇 + 𝜙1)𝑅𝑧(𝑤2𝒇 + 𝜙2)

Meta-VQE: Linear encoding. Loss functionwith test points.Opt-meta-VQE: VQE optimization with opt. meta-VQE parameters as starting point. Single minimization per parameter.VQE:Standard VQE. 2 processinglayers. Result of previousminimization as initial point of thenext one.VQE enc:Same as VQE but including anencoding layer.

Legend

Hamiltonian Parameter (flux)

ACL, J. S. Kottmann and A. Aspuru-Guzik, arXiv:2009.13545 [quant-ph] (2020)

Kyaw, Menke, Sim, Sawaya, Oliver, Guerreschi, Aspuru-Guzik, arXiV:2006.03070 (2020)

Page 41: Quantum Computing in the NISQ era - Alba Cervera-Lierta

The Meta-VQE

Some conclusions:

- Meta-VQE can be used to scan over Hamiltonian parameteres to find the energy interestingregions.

- We can use its parameter solution to run a more precise algorithm such as opt-meta-VQE orstandard VQE.

- The encoding strategy in VQE-type algorithms might be useful to guide the optimizationtowards the solution.

- Careful with QPT: the ground state changes so the unitary circuit (the encoding and processing parameters used) will change in the different phase areas.

https://github.com/aspuru-guzik-group/Meta-VQE

Code

ACL, J. S. Kottmann and A. Aspuru-Guzik, arXiv:2009.13545 [quant-ph] (2020)

Page 42: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Comments and Remarks

Page 43: Quantum Computing in the NISQ era - Alba Cervera-Lierta

The end of classical computing?

1. We can’t simulate classically more tan ~50 qubits (not even with a supercomputer!)

2. Simulation of quantum phenomena is exponentially costly for a classical computer.

3. Many interesting physical systems (molecules, phases of matter,…) are quantum.

4. Quantum computers are controlled with classical computers.

5. Pre- and post-processing of quantum data is classical.

6. We don’t have a quantum algorithm for each open problem, but do we need them?

Quantum Computing in the NISQ era, Alba Cervera-Lierta, UCL Quantum Tech Winter School 2020.

Page 44: Quantum Computing in the NISQ era - Alba Cervera-Lierta

The needs in NISQ era

1. What can we do with ~100 noisy qubits?

2. Variational Quantum Algorithms are theoretically resistant to smallamount of noise

3. Rethink and adapt algorithms to VQA

4. We need tools for running those algorithms: error mitigationtechniques, programming languages,…

5. What are the limits in NISQ computers? (e.g. what’s the biggestmolecule that we can simulate?)

Quantum Computing in the NISQ era, Alba Cervera-Lierta, UCL Quantum Tech Winter School 2020.

Page 45: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Quantum calling

New quantum algorithms: variational or fault-tolerant.

New applications: chemistry, materials, finance, optimization problems, biology, physics,…

Architectures: superconducting circuits, trapped ions, photons,…

Quantum control: reduce noise, error correction, gate fidelities,…

Quantum-classical interface: programming languages, …

Computational complexity: what kind of problems can we solve and how.

Quantum Computing in the NISQ era, Alba Cervera-Lierta, UCL Quantum Tech Winter School 2020.

Page 46: Quantum Computing in the NISQ era - Alba Cervera-Lierta

Thanks!Questions?

Alba Cervera-Lierta

University of TorontoSlides: albacl.github.io/talk/

@albaclierta