Generative Models for Brain Imaging - FIL | UCL
Transcript of Generative Models for Brain Imaging - FIL | UCL
Generative Models for Brain Imaging
Will Penny
Wellcome Department of Imaging Neuroscience, UCLhttp://www.fil.ion.ucl.ac.uk/~wpenny
Natural Computing Applications Forum (NCAF), ‘Cognitive Systems –from Neural Imaging to Neurocomputing’, 18-19 May, 2005,
York University, UK.
2D fMRI time-series
Time
Serial snapshotsof blood –
oxygenation levels
Time
Even without applied spatial smoothing, activation maps (and maps of eg. AR coefficients) have spatial structure
Motivation
We can increase the sensitivity of our inferences by smoothing data with Gaussian kernels (SPM2). This is worthwhile, but crude.Can we do better with a spatial model (SPM5) ?
AR(1)
Aim: For SPM5 to remove the need for spatial smoothing just as SPM2 removed the need for temporal smoothing
Contrast
β
A
q1 q2
α
W
Y
( ) ( )
( ) ( )1
1 2; ,
K
kk
k k
p p
p Ga q q
α
α α=
=
=
∏α
( ) ( )
( ) ( )( )1
11; ,
KTk
k
T T Tk k k
p p
p N α
=
−−
=
=
∏W w
w w 0 S S
u1 u2
λ
( ) ( )
( ) ( )1
1 2; ,
N
nn
n n
p p
p Ga u u
λ
λ λ=
=
=
∏λ
( )1
1 1
( ) ( )
( ) ; , ( )
P
pp
Tp p p
p p
p N β=
− −
=
=
∏A a
a a 0 S S
Y=XW+E[TxN] [TxK] [KxN] [TxN]
r1 r2
1
1 2
( ) ( )
( ) ( ; , )
P
pp
p p
p p
p Ga r r
β
β β=
=
=
∏β
0pβ →
pβ →∞
Voxel-wise AR:
Spatial pooled AR:
The Model
t
Synthetic Data 1 : from Laplacian Prior
reshape(w1,32,32)
Prior, Likelihood and PosteriorIn the prior, W factorises over k and A factorises over p:
1 2 1 2( , , , , ) ( | ) ( | , ) ( | ) ( | , )k k k p p pk p
p p p q q p p r rα α β β
= ∏ ∏W A λ α β w a
1 2( | , )nn
p u uλ ∏
The likelihood factorises over n:
( | , , ) ( | , , )n n n nn
p p λ=∏Y W A λ y w a
The posterior over W therefore does’nt factor over k or n. It is a Gaussianwith an NK-by-NK full covariance matrix. This is unwieldy to even store, let alone invert ! So exact inference is intractable.
Variational Bayes
L F KL= +
( , )( )( | )ppp
=Y θYθ Y
log ( ) log ( , ) log ( | )p p p= −Y Y θ θ Y
log ( ) ( ) log ( , ) ( ) log ( | )p q p d q p d= −∫ ∫Y θ Y θ θ θ θ Y θ
( , ) ( )log ( ) ( ) log ( ) log( ) ( | )
p qp q d q dq p
= +∫ ∫Y θ θY θ θ θ θθ θ Y
L
F
KL
Variational Bayes
( ) ( )ii
q q=∏θ θ
If you assume posterior factorises
then F can be maximised by letting
exp[ ( )]( )exp[ ( )]
ii
i i
IqI d
=∫
θθθ θ
where
/ /( ) ( ) log ( , )i i iI q p d= ∫θ θ Y θ θ
Variational Bayes
( , , , | ) ( | ) ( | ) ( | ) ( | ) ( | )k p n n nk p n
q q q q q qα β λ
= ∏ ∏ ∏W A λ α Y Y Y w Y a Y Y
In chosen approximate posterior, W and A factorise over n:
In the prior, W factorises over k and A factorises over p:
1 2 1 2( , , , , ) ( | ) ( | , ) ( | ) ( | , )k k k p p pk p
p p p q q p p r rα α β β
= ∏ ∏W A λ α β w a
1 2( | , )nn
p u uλ ∏
So, in the posterior for W we only have to store and invert N K-by-K covariance matrices.
( )ˆˆ( ) ; ,n n n nq N=w w w Σ
[ ]( )T Tdiag= ⊗B H α S S H
1,
ˆN
n ni ii i n= ≠
= − ∑r B w
( )( ) 1
Tnn n n n
n n n nn
λ
λ−
= +
= +
w Σ b r
Σ A B
( ) ( )
( ) ( )
( )
1
1
2
; ,1 1 1
2
2
K
kk
k k k k
TT Tk k k
k
k
k k k
q q
q Ga g h
Trg q
Nh q
g h
α
α α
α
=
=
=
= + +
= +
=
∏α
Σ S S w S Sw
Regression coefficients, W
Spatial precisions for W
1
2
( ) ( ; , )
1 12
2
n n n n
n
n
n
q Ga b c
Gb u
Tc u
λ λ=
= +
= +
Observation noise
AR coefficients, A
( )( )( )
1
1,
( ) ( ; , )
( )
n n n n
nn n nn
nn n n n
T Ta a
N
n ni ii i n
q N
diag
λ
λ
−
= ≠
=
= +
= +
= ⊗
= − ∑
a a m V
V C J
m V d j
J H β S S H
j J m
( )
1
1 2
1 1
2 2
1 2
( ) ( )
( ) ( ; , )
1 1 1( )2
2
P
pp
p p p p
T T Tp p p
p
p
p pp
q q
q Ga r r
Trr r
Pr r
r r
β
β β
β
=
=
=
= + +
= +
=
∏β
V S S m S Sm
Spatial precisions for A
Updating approximate posterior
y
x t
Synthetic Data 1 : from Laplacian Prior
Iteration Number
F
y
x
y
x
Least Squares VB – Laplacian Prior
`Coefficient RESELS’ = 366Coefficients = 1024
Synthetic Data II : blobs
True Smoothing
Global prior Laplacian prior
1-Specificity
Sen
sitiv
ity
Event-related fMRI: Faces versus chequerboard
Smoothing
Global prior Laplacian Prior
Event-related fMRI: Familiar faces versus unfamiliar faces
Smoothing
Global prior Laplacian Prior