• No results found

A Quantum-Assisted Algorithm for Sampling Applications in Machine Learning

N/A
N/A
Protected

Academic year: 2021

Share "A Quantum-Assisted Algorithm for Sampling Applications in Machine Learning"

Copied!
29
0
0

Loading.... (view fulltext now)

Full text

(1)

Alejandro Perdomo-Or/z

Research Scien/st, Quantum Ar/ficial Intelligence Laboratory

NASA Ames Research Center,

Moffett Field, Calif., USA

Quantum Annealing Workshop @ ICTP,

Trieste, Italy, August 24, 2016

A quantum-assisted algorithm for sampling

applications in machine learning

Collaborators:

M. Benedetti, J. Realpe-Gomez, and R. Biswas.

Funding:

Benedetti et al. PRA, 94, 022308 (arXiv:1510.07611).

(2)

2 LEARNED MODEL P ( Image ) Example application: Image reconstruction Damaged image

Unsupervised learning

(generative models)

Reconstructed image

(3)

3 Learning algorithm MODEL P ( Image ) LEARNED MODEL P ( Image ) DATASET Example application: Image reconstruction Damaged image

Unsupervised learning

(generative models)

NO LABELS

Learn the “best” model distribution that can generate the same kind of data.

Reconstructed image

(4)

4 Learning algorithm MODEL P ( Label | Image ) LEARNED MODEL P ( Label | Image )

Supervised learning

(discriminative models)

Learn the “best” model that can perform a specific task

Example application: Image recognition Predicted label Image to be recognized

61

26624 98 66 175 Labels DATASET
(5)

Outline

• Why is it hard and interesting to sample from a Boltzmann distribution? Why, in principle, is it

possible to do classical Gibbs sampling with a quantum annealer?

General BMs Deep architectures

0 1000 2000 3000 4000 5000 iteration 14 12 10 8 6 4 Lav QuALe @Te↵ QuALe @T= 0.08 QuALe @Tav⇡0.1 QuALe @T= 0.16 CD-1 CD-10 CD-100 0 100 200 300 400 500 iteration 12 11 10 9 8 7 6 Lav CD-1

QuALe with restart @ 250 QuALe @T= 0.033with restart @ 250

s

Benedetti et al. PRA, 94, 022308 (arXiv:1510.07611).

Amin. PRA, 92, 052323 (2015)

• Overcoming the “curse of limited connectivity” in hardware. How to work with general probabilistic

graphical models beyond RBM? How to cope with noisy devices and future directions.

• How to do it experimentally? Results on our quantum-assisted learning (QuALe) algorithm for

(6)

“Most of the previous work in generative models has focused on variants of

Boltzmann Machines [...] While these models are very powerful, each

iteration of training requires a computationally costly step of MCMC to

approximate derivatives of an intractable partition function (normalization

constant), making it difficult to scale them to large datasets.

Mansimov, Parisotto, Ba, Salakhutdinov, under review for ICLR 2016

Unsupervised learning relies on

sampling

“In the context of the deep learning approach to undirected modeling, it is rare

to use any approach other than Gibbs sampling. Improved sampling

techniques are one possible research frontier.

Goodfellow, Bengio, Courville, Deep Learning, book in preparation for MIT Press, 2016

“Unsupervised learning [... has] been overshadowed by the successes of

purely supervised learning. [... We] expect unsupervised learning to

become far more important in the longer term. Human and animal learning is largely unsupervised: we discover the structure of the world by observing it, not by being told the name of every object.”

LeCun, Bengio, Hinton, Deep Learning, Nature 2015

(7)

Deep Belief Networks such that RBM’s: Model: Computationally bottleneck

Training Method: Stochastic gradient ascent

Restricted Boltzmann Machines and Beyond

(8)

Foundational Theory of Quantum Annealing

Simulated Annealing

(Kirkpatrick et al., 1983)

•  Transitions between states are over the barrier and due to thermal fluctuation

•  Algorithm: Start with a high temperature. Slowly reduce the intensity of these thermal fluctuations aiming for low cost configs..

E({z}) E({z}) E({z}) Te m p er atu re Time

Quantum Annealing

(Finnila et al., 1994, Kadawaki and Nishimori, 1998, Farhi et.al., 2001)

• Transitions between states due to quantum fluctuations (tunneling)

• Algorithm: Start with large amplitude A(τ) responsible for quantum

fluctuations. Then, slowly turn it off while turning on the cost function amplitude, B(τ).

Time, τ

E({z}): Free energy Surface (cost funct.)

Final states: bit strings encoding the solution. E({z},τ=1)

{z} initialize in an easy to

prepare full quantum superposition quantum states explored by quantum tunneling E({z}, τ<1) E({z}, τ=0) {z} {z} {z}=configurations in solutions space tunneling 1 2 3 1 2 3

(9)

D-Wave System Capability

1) As a discrete optimization solver:

2) As a physical device to sample from Boltzmann distribution:

P

Boltzmann

exp[

ξ

(

s

1

,...,

s

N

) /

T

eff

]

Potential NASA applications in machine leaning (e.g., training of deep-learning networks)

Potential NASA applications: planning, scheduling, fault diagnosis, graph analysis, communication networks, etc.

QUBO: Quadratic Unconstrained Binary Optimization

(Ising model in physics jargon).

NP-hard problem

Computationally bottleneck

Our recent work: Benedetti et al. PRA, 94, 022308 (2015)

Early work:

Bian et al. 2010. The Ising model: teaching an old problem new tricks.

•  Algorithm uses the same samples that will be used for the

estimation of the gradient

•  We provide a robust algorithm to estimate the effective temperature of problem instances in quantum annealers.

Recent work:

Raymond et al. 2016. Global warming: Temperature estimation in annealers. Widely used in unsupervised learning Visible units Hidden units RBM

(10)

Why sampling from classical Gibbs?

2) As a physical device to sample from Boltzmann distribution:

P

Boltzmann

exp[

ξ

(

s

1

,...,

s

N

) /

T

eff

]

Potential NASA applications in machine leaning (e.g., training of deep-learning networks)

Amin. PRA, 92, 052323 (2015)

s T

(11)

Quantum-Assisted Learning Vs. Contrastive Divergence

0 1000 2000 3000 4000 5000 iteration 14 12 10 8 6 4 Lav QuALe @ Te↵ QuALe @ T = 0.08 QuALe @ Tav ⇡ 0.1 QuALe @ T = 0.16 CD-1 CD-10 CD-100

Benedetti et al. PRA, 94, 022308

Bars and Stripes dataset

Fisher and Igel. Pattern Recognition, 47, 25 (2014)

Embedding on the D-Wave 2X

a b e f c d g h i j m n k l o p Pixel blocks embedding a b c d e f g i j k l m n o p h (a) (b)

(12)

2370 2380 2390 2400 2410 2420 2430 2440

iteration

0

.

05

0

.

10

0

.

15

0

.

20

0

.

25

T

T

training

T

median

Non-trivial and correlated variations in the temperature

TDW2X = 0.033

(13)

Added features: Restart from CD-k

0

100

200

300

400

500

iteration

12

11

10

9

8

7

6

L

av CD-1

QuALe with restart @ 250

QuALe @ T = 0.033 with restart @ 250

(14)

Comparison with pseudo-likelihood

0

1000

2000

3000

4000

5000

iteration

12

10

8

6

4

L

av

(a)

QuALe w/ pseudo likelihood

QuALe w/ linear regression

0

1000

2000

3000

4000

5000

iteration

0.0

0.1

0.2

0.3

0.4

T

e↵

(b)

Pseudo likelihood

Linear regression

(15)

Quantum-assisted unsupervised learning on digits

Overcoming the curse of limited connectivity

7 logical (visible) variables

(16)

Quantum-assisted unsupervised learning on digits

Overcoming the curse of limited connectivity in physical devices.

42 fully-connected

logical (visible) variables

794 physical qubits

How do we train this 794 qubit problem? (How do we analyze the (Gibbs) samples from this physical model?

Benedetti et al. In preparation.

Immediate solution: Keep an eye on a paper coming out with a new gray-model approach for training noisy QA.

(17)

Quantum-assisted unsupervised learning on digits

OptDigits Datasets

Dataset: Optical Recognition of Handwritten Digits (OptDigits)

8x8 7x6 7x6, binarized

(18)

Quantum-assisted unsupervised learning on digits

OptDigits Datasets

(19)

Quantum-assisted unsupervised learning on digits

Dataset: Optical Recognition of Handwritten Digits (OptDigits)

corrupted original

(20)

Quantum-assisted unsupervised learning on digits

Dataset: Optical Recognition of Handwritten Digits (OptDigits)

corrupted original

•  Experimental realization of quantum-assisted learning algorithm on 794 qubits, for a 42 fully-connected model.

•  Fully unsupervised learning and generative model on a digit.

After 1

learning iter.

(21)

Quantum-assisted unsupervised learning on digits

Dataset: Optical Recognition of Handwritten Digits (OptDigits)

corrupted original

•  Experimental realization of quantum-assisted learning algorithm on 794 qubits, for a 42 fully-connected model.

•  Fully unsupervised learning and generative model on a digit.

After 1

learning iter.

After 100 learning iters.

(22)

Quantum-assisted unsupervised learning on digits

Dataset: Optical Recognition of Handwritten Digits (OptDigits)

corrupted original

•  Experimental realization of quantum-assisted learning algorithm on 794 qubits, for a 42 fully-connected model.

•  Fully unsupervised learning and generative model on a digit.

After 1 learning iter. After 100 learning iters. After 1000 learning iters. After 6000 learning iters.

(23)

Quantum-assisted unsupervised learning on digits

Dataset: Optical Recognition of Handwritten Digits (OptDigits)

corrupted original

•  Experimental realization of quantum-assisted learning algorithm on 794 qubits, for a 42 fully-connected model.

•  Fully unsupervised learning and generative model on a digit.

After 1 learning iter. After 100 learning iters. After 1000 learning iters. After 6000 learning iters.

(24)

Quantum-assisted unsupervised learning on digits

46 fully-connected

logical (visible) variables

917 physical qubits

Are the results from this training on 917 qubit experiment meaningful? Is the model capable of generating digits, as expected?

42 for pixels + 4 to one-hot encode the class (only digits 1-4)

Overcoming the curse of limited connectivity in hardware.

(25)

Quantum-assisted unsupervised learning on digits

Human or (quantum) machine? (Turing test)

Benedetti et al. In preparation. Dataset: Optical Recognition of Handwritten Digits (OptDigits)

(26)

Quantum-assisted unsupervised learning on digits

(quantum) machine Human

Human or (quantum) machine? (Turing test)

Dataset: Optical Recognition of Handwritten Digits (OptDigits) Benedetti et al. In preparation.

•  Experimental realization of quantum-assisted learning algorithm on 917 qubits, for a 46 fully-connected model.

(27)

Quantum-assisted unsupervised: artificial model

0 50 100 150 200 Epoch 30 25 20 15 10 5 0 Fav (b)

Exact gradient - logical graph QA - physical graph 0 200 400 600 800 1000 1200 1400 Epoch 30 25 20 15 10 5 0 Fav (a) Training set SA - logical graph QA - physical graph

Benedetti et al. In preparation.

Reference model: Ising spin glass with 20 fully-connected spins (10 instances).

(28)

Numerical simulations show that main limitation of current quantum annealers for Boltzmann machines applications is its sparse connectivity.

Extensions to deep learning architectures.

Possible further boosting protocols by considering models to account explicitly for the noise in the quantum device.

Ongoing research directions

General BMs

Deep architectures

Inference by using quantum distributions, such as those coming from future generation quantum computing technologies.

How “Boltzmannian” need the samples to be for QuALE to work.

Is quantum tunneling, or any other quantum computational resource, relevant for machine learning/sampling applications? Can it be any faster than MCMC? Is it possible to achieve quantum supremacy in this domain?

(29)

References

Related documents

- The pooled PD assigned to a credit risk bucket. A PD associated with an individual obligor is a metric of the probability that this obligor will default during a one-year

Getting Started With Corporate Actions ISO 20022 Announcements Messaging 45 Starting with the Message Usage Guideline for announcements, the Event Level Message

The goal of this book is to explore numerous strate- gies and activities that support all students in understanding basic addition and subtraction math facts and committing those

Time evolution of the probability of marketability as a function of the number of days of storage (DOS), as affected by the Tribelli XL ® pepper cultivars (‘43’, ‘Spiker’

The App Checker consists of three sets of questions and offers frameworks for (1) a focused search for a suitable mobile medical app, (2) an appraisal of the reliability and

According to Blair, Chen &amp; Hagt (2006), Malacca Strait Council need to be an organization that is not only managing issues of safety on navigation but also on the economy

- vast landslides with high, steep head scarps in the upper part of slopes, complex relief of the landslide body and screes (L4 type),.. - vast landslides with head scarps

Lynx kill rates on sheep was consequently low in the reindeer husbandry area (1.2 sheep/30 days), similar to kill rates observed in areas with high roe deer densities in southern