A CTIVE M EASUREMENT F OR N EUROSCIENCE LCCC Focus Period on - - PowerPoint PPT Presentation

a ctive m easurement f or
SMART_READER_LITE
LIVE PREVIEW

A CTIVE M EASUREMENT F OR N EUROSCIENCE LCCC Focus Period on - - PowerPoint PPT Presentation

(Towards) A CTIVE M EASUREMENT F OR N EUROSCIENCE LCCC Focus Period on Large-Scale and Distributed Optimization June 2017 Ross Boczar PhD Student boczar@berkeley.edu B erkeley C enter for C omputational Ben Eric I maging Recht


slide-1
SLIDE 1

(Towards)

ACTIVE MEASUREMENT FOR NEUROSCIENCE


Ross Boczar PhD Student

boczar@berkeley.edu

Eric Jonas Ben Recht

Berkeley Center for
 Computational Imaging

LCCC Focus Period on Large-Scale and Distributed Optimization June 2017

slide-2
SLIDE 2

THIS TALK

  • Problem Statement
  • Motivating Science
  • Motivating Works
  • PyWren: A Shameless Plug
  • Some Things to Try
slide-3
SLIDE 3

PROBLEM STATEMENT

slide-4
SLIDE 4

PROBLEM STATEMENT

  • March 2017:
slide-5
SLIDE 5

PROBLEM STATEMENT

  • March 2017:

I have to give a talk in 3 months.

slide-6
SLIDE 6

SCIENCE

slide-7
SLIDE 7

SCIENCE

slide-8
SLIDE 8

TWO MOTIVATORS

  • We have a ton of cells, and

finite experimental time! 
 (can record from an organism for a very short period of time)

  • We now have fine-grained

control over the neurons via

  • ptogenetics — we can use

lasers to turn on and off individual cells or subpopulations of cells

How do we learn as much about the system as quickly as possible?

slide-9
SLIDE 9

SINGLE CELL 
 RESPONDING TO VISUAL INPUT

Start simple:

slide-10
SLIDE 10

MOTIVATING WORKS

Sequential Optimal Experiment Design 
 for Neurophysiological Experiments
 Lewi, Butera, and Paninski 2009 Adaptive Bayesian Methods for Closed-loop Neurophysiology
 Pillow and Park 2016

slide-11
SLIDE 11

A SIMPLE EXAMPLE

showing the adaptive measurement paradigm

slide-12
SLIDE 12

Pillow and Park 2016

trial t

  • 1. present stimulus, observe response

f(x; θ) = b + A exp ⇣ −

1 2σ2 (x − µ)2⌘

λ = f(x) p(r|x) =

1 r!λreλ.

slide-13
SLIDE 13

Pillow and Park 2016

  • 2. update posterior

L(λt|Dt) = log p(Rt|λt) = Rt> log λt − 1>λt,

Parameter space small enough to grid in this case (not typical)

Log-likelihood based on observed responses:

slide-14
SLIDE 14

Pillow and Park 2016

  • 3. maximize expected utility

Uinfomax(x|Dt) = Er,θ h log p(θ|r, x, Dt) p(θ|Dt) i =

  • “Infomax learning”

One of multiple criteria to optimize (MMSE, prediction error,…) Requires integrating over parameter and response spaces, can use MCMC / bag of samples, in this example we can numerically integrate (not typical)

slide-15
SLIDE 15
slide-16
SLIDE 16
slide-17
SLIDE 17
slide-18
SLIDE 18
slide-19
SLIDE 19
slide-20
SLIDE 20

trial t trial t+1

  • 1. present stimulus, observe response

...

  • 2. update posterior
  • 3. maximize expected utility

Pillow and Park 2016, Fig. 1

slide-21
SLIDE 21

trial t trial t+1

  • 1. present stimulus, observe response

...

  • 2. update posterior
  • 3. maximize expected utility

Pillow and Park 2016, Fig. 1

In general:

Generate the next xt in a smart, fast way Update your belief state

slide-22
SLIDE 22

ANOTHER VIEW

Lewi et al. 2009, Fig. 2

slide-23
SLIDE 23

ANOTHER VIEW

Lewi et al. 2009, Fig. 2

slide-24
SLIDE 24

CURRENT APPROACH

  • More complicated example: Lewi-09 (visual receptive fields)
  • Laplace approximation for belief state (2nd order statistics) gives

a compact representation for the parameter distribution

slide-25
SLIDE 25

CURRENT APPROACH

  • Have to solve high-dimensional non-convex optimization and/or

integration to solve for the next x — have to grid or sample based on heuristics (i.i.d. is bad!)

  • Drawbacks: Curse of dimensionality, problems with EM /

MCMC sampling, certain ops can get computationally (and financially!) expensive, would like to deal with more complicated models, …

slide-26
SLIDE 26

CURRENT APPROACH

  • Would like a lot of cores now, suitable for prototyping and

exploration for these computationally intensive tasks, many of which are “embarrassingly parallel”

slide-27
SLIDE 27

PYWREN: A POSSIBLE (PARTIAL) PANACEA

slide-28
SLIDE 28

Why is there no “cloud button”?

PREVIOUSLY, AT COMP IMAGING LUNCH

slide-29
SLIDE 29

My background: formerly mostly controls, now mostly ML and optimization

slide-30
SLIDE 30

Eric: How do you get busy physicists and electrical engineers to give up Matlab?

My background: formerly mostly controls, now mostly ML and optimization

slide-31
SLIDE 31

“Most wrens are small and rather inconspicuous, except for their loud and often complex songs.”

PyWren

pywren.io

slide-32
SLIDE 32

PYWREN: THE API

slide-33
SLIDE 33

USING “SERVERLESS INFRASTRUCTURE”

slide-34
SLIDE 34

Powered by Continuum Analytics +

slide-35
SLIDE 35

(Leptotyphlops carlae)

Start Delete non-AVX2 MKL strip shared libs conda clean eliminate pkg delete pyc 977 MB

1205MB 441MB

946 MB 670 MB 510MB Want our runtime to include

slide-36
SLIDE 36
  • 300 seconds 


single-core (AVX2)

  • 512 MB in /tmp
  • 1.5GB RAM
  • Python, Java, Node

AWS LAMBDA

slide-37
SLIDE 37
  • 300 seconds 


single-core (AVX2)

  • 512 MB in /tmp
  • 1.5GB RAM
  • Python, Java, Node

AWS LAMBDA

slide-38
SLIDE 38

LAMBDA SCALABILITY

slide-39
SLIDE 39

SOME THINGS TO TRY

slide-40
SLIDE 40

MPC-INSPIRED SEARCH

hyperparams

Current parameter distribution

slide-41
SLIDE 41

MPC-INSPIRED SEARCH

hyperparams

Current parameter distribution Possible sample locations x1 x2 x3 x4

slide-42
SLIDE 42

MPC-INSPIRED SEARCH

hyperparams

Current parameter distribution Possible sample locations Dream about the future x1 x2 x3 x4

slide-43
SLIDE 43

MPC-INSPIRED SEARCH

hyperparams

Current parameter distribution Possible sample locations n-step evaluation Dream about the future x1 x2 x3 x4

slide-44
SLIDE 44

MPC-INSPIRED SEARCH

hyperparams

Current parameter distribution x2

slide-45
SLIDE 45

FUNCTION APPROXIMATION

  • Use Lambda services to generate rollouts to learn

policies:

π1(x1:t, r1:t ; ˆ b(θ)t−1) → ˆ b(θ)t

Belief update function

π2(x1:t, r1:t ; ˆ b(θ)t) → xt+1

Adaptive measurement function

slide-46
SLIDE 46

FUNCTION APPROXIMATION

  • Fit with ML / adaptive control / reinforcement

learning / deep learning technique based on problem

slide-47
SLIDE 47

FUNCTION APPROXIMATION

  • Fit with ML / adaptive control / reinforcement

learning / deep learning technique based on problem

  • An aside: DFO works again! 


http://www.argmin.net/2017/04/03/evolution/

slide-48
SLIDE 48

THANKS!

  • Here all month :)
  • boczar@berkeley.edu
  • pywren.io
  • http://www.argmin.net/2017/04/03/evolution/