assignment 2: reverse correlation
DESCRIPTION
Assignment 2: reverse correlation. Outline. The assignment requires you to Write code to produce graphs Make observations from the graphs Draw conclusions. Coding. Coding is in MATLAB. I will provide you with templates that provide you with: A list of MATLAB functions to use - PowerPoint PPT PresentationTRANSCRIPT
![Page 1: Assignment 2: reverse correlation](https://reader036.vdocument.in/reader036/viewer/2022062501/56816750550346895ddc01b1/html5/thumbnails/1.jpg)
J. Elder PSYC 6256 Principles of Neural Coding
ASSIGNMENT 2: REVERSE CORRELATION
![Page 2: Assignment 2: reverse correlation](https://reader036.vdocument.in/reader036/viewer/2022062501/56816750550346895ddc01b1/html5/thumbnails/2.jpg)
Probability & Bayesian Inference
J. ElderPSYC 6256 Principles of Neural Coding
2
Outline The assignment requires you to
Write code to produce graphs Make observations from the graphs Draw conclusions
![Page 3: Assignment 2: reverse correlation](https://reader036.vdocument.in/reader036/viewer/2022062501/56816750550346895ddc01b1/html5/thumbnails/3.jpg)
Probability & Bayesian Inference
J. ElderPSYC 6256 Principles of Neural Coding
3
Coding Coding is in MATLAB. I will provide you with templates that
provide you with: A list of MATLAB functions to use Comments describing the flow of
operations
![Page 4: Assignment 2: reverse correlation](https://reader036.vdocument.in/reader036/viewer/2022062501/56816750550346895ddc01b1/html5/thumbnails/4.jpg)
Probability & Bayesian Inference
J. ElderPSYC 6256 Principles of Neural Coding
4
Some Coding Tips It is important that you know how to use
the debugger. Use the MATLAB Help facility. You should generally never have a loop
(or nested loop) that involves more than a few hundred iterations.
![Page 5: Assignment 2: reverse correlation](https://reader036.vdocument.in/reader036/viewer/2022062501/56816750550346895ddc01b1/html5/thumbnails/5.jpg)
Probability & Bayesian Inference
J. ElderPSYC 6256 Principles of Neural Coding
5
Dataset We will be using a portion of the Neural
Prediction Challenge Dataset Responses of V1 neurons to natural vision
movies in awake behaving macaque Both neural responses and visual stimuliare
provided Available at
http://neuralprediction.berkeley.edu/ But you can download the files you need
from the course website. We will be analyzing a particular neuron (R0221B)
![Page 6: Assignment 2: reverse correlation](https://reader036.vdocument.in/reader036/viewer/2022062501/56816750550346895ddc01b1/html5/thumbnails/6.jpg)
Probability & Bayesian Inference
J. ElderPSYC 6256 Principles of Neural Coding
6
Submission Details You will submit a short lab report on your
experiments. For each experiment, the report will
include: The code you developed The graphs you produced The observations you made The conclusions you drew
![Page 7: Assignment 2: reverse correlation](https://reader036.vdocument.in/reader036/viewer/2022062501/56816750550346895ddc01b1/html5/thumbnails/7.jpg)
Probability & Bayesian Inference
J. ElderPSYC 6256 Principles of Neural Coding
7
Graphs The graphs you produce should be as
similar as possible to mine. Make sure everything is intelligible!
![Page 8: Assignment 2: reverse correlation](https://reader036.vdocument.in/reader036/viewer/2022062501/56816750550346895ddc01b1/html5/thumbnails/8.jpg)
Probability & Bayesian Inference
J. ElderPSYC 6256 Principles of Neural Coding
8
Due Date The report is due Wed Mar 23
![Page 9: Assignment 2: reverse correlation](https://reader036.vdocument.in/reader036/viewer/2022062501/56816750550346895ddc01b1/html5/thumbnails/9.jpg)
Probability & Bayesian Inference
J. ElderPSYC 6256 Principles of Neural Coding
9
Reverse Correlation Raw stimulus response cross-correlation:
Now represent the kernel h as an m x T matrix, where
Correction for temporal stimulus bias:
Correction for spatial stimulus bias:
But this doesn’t work, because there are too many coefficients in Qss to estimate, and too little power in the high frequencies of the stimulus to estimate them.
h(x,y,τ)=
1T −τ
s(x,y,τ)r(τ+τ)τ=1
T−τ
∑
′h =hQττ−1
′h =hQss−1
m = num ber of pixels in kernelT = num ber of τim e lags in kernel
![Page 10: Assignment 2: reverse correlation](https://reader036.vdocument.in/reader036/viewer/2022062501/56816750550346895ddc01b1/html5/thumbnails/10.jpg)
Probability & Bayesian Inference
J. ElderPSYC 6256 Principles of Neural Coding
10
Solution: Regularized Inverse Use SVD decomposition:
Where U and V are orthonormal rotation matrices and S is a diagonal scaling matrix carrying the eigenvalues of Qss
The eigenvalues represent the power of the autocorrelation in each of the underlying principle directions (eigenvectors).
Qss =USVτ
![Page 11: Assignment 2: reverse correlation](https://reader036.vdocument.in/reader036/viewer/2022062501/56816750550346895ddc01b1/html5/thumbnails/11.jpg)
Probability & Bayesian Inference
J. ElderPSYC 6256 Principles of Neural Coding
11
Regularized Inverse Once the SVD decomposition is computed, taking
the inverse is easy.
However, this inverse is unreliable, because noisy eigenvalues in S near 0 result in large noisy values in S-1.
To avoid this, only take the largest eigenvalues from S, and set the remaining diagonal elements of S-1 to 0.
Qss =USVτ
Q−1ss =V S
−1U τ
![Page 12: Assignment 2: reverse correlation](https://reader036.vdocument.in/reader036/viewer/2022062501/56816750550346895ddc01b1/html5/thumbnails/12.jpg)
Probability & Bayesian Inference
J. ElderPSYC 6256 Principles of Neural Coding
12
Firing Rates
Histogram
KDE
![Page 13: Assignment 2: reverse correlation](https://reader036.vdocument.in/reader036/viewer/2022062501/56816750550346895ddc01b1/html5/thumbnails/13.jpg)
Probability & Bayesian Inference
J. ElderPSYC 6256 Principles of Neural Coding
13
Stimulus-Response Cross-Correlation
![Page 14: Assignment 2: reverse correlation](https://reader036.vdocument.in/reader036/viewer/2022062501/56816750550346895ddc01b1/html5/thumbnails/14.jpg)
Probability & Bayesian Inference
J. ElderPSYC 6256 Principles of Neural Coding
14
First-Order Temporal Autocorrelation of Stimulus
![Page 15: Assignment 2: reverse correlation](https://reader036.vdocument.in/reader036/viewer/2022062501/56816750550346895ddc01b1/html5/thumbnails/15.jpg)
Probability & Bayesian Inference
J. ElderPSYC 6256 Principles of Neural Coding
15
STRF Corrected for Temporal Bias of Stimulus
![Page 16: Assignment 2: reverse correlation](https://reader036.vdocument.in/reader036/viewer/2022062501/56816750550346895ddc01b1/html5/thumbnails/16.jpg)
Probability & Bayesian Inference
J. ElderPSYC 6256 Principles of Neural Coding
16
Unregularized Correction for Spatial Bias of Stimulus
![Page 17: Assignment 2: reverse correlation](https://reader036.vdocument.in/reader036/viewer/2022062501/56816750550346895ddc01b1/html5/thumbnails/17.jpg)
Probability & Bayesian Inference
J. ElderPSYC 6256 Principles of Neural Coding
17
Regularized Correction for Spatial Bias of Stimulus