Neuromatch Academy Week 1 Day 1
1. Tutorial 1
Konrad Kording What model: Description of Data - No promises about meaning How Model: Mechanistic Understanding. Why Model: Which things matter, what’s optimized ecologically or evolutionarily
Steinmetz dataset: Neuropixels - rodent is moving on
- What Models
- Understand the data very well
- What is this data
- What is its type, shape?
- How can I access and load it correctly
- Our dataset is a collection of neuronal activities.
- Its an array of arrays of differing shapes. An entry in the original array represents the firing activity for a single neuron. The entries in that are interspiking time (Floats) for a single neuron.
np.ptp()
np.concatenate()
are important functions for shortening your work
Important observation: Taking an interval of say(5, 15) sec we see that the percentage of neuronal firing in this interval is same as this duration as a percentage of the experiment interval (~0.33% of 2700 sec duration) This suggests that our interval is representative: the fire rate in this interval is not much different from the entire recording.
Heavy-Tailed Distributions are seen in neuroscience where small number of neurons have extremely high number of spikes (> 120000) whereas good percentage is below mean even though its very low (~8000).
plt.eventplot()
- This is used to make a “raster” plot. Each neuron’s activity is displayed on a different line.
- The histogram in a given interval is a cumulative of a raster plot where each row is summed across. 1
- By modelling the interspiking intervals we can learn something about the biophysics of neurons.
- In a “what” model we just want to see what mathematical model fits the best, not looking at mechanistic or ecological explainability at all.
np.diff()
Is also very useful. finds discrete differences along an array.
What does it mean for a What model to be good? It should describe the data well. We don’t care about the mechanistic or ecological explanation. Check exponential, linear and inverse fits to the ISI distribution by fitting by hand.
2. Tutorial 2
Integrate and Fire (IF) model of neurons.
-This model is not enough because it doesn’t fit our data quite well.
- From a “How” perspective we see that it becomes quite regular but this is not what we see in actual physiology.
Leaky Integrate and Fire (LIF) model Balanced excitation and inhibition Random number of spikes that increase your voltage and also random spikes that decrease your voltage.
3. Tutorial 3
- We want to describe theoretically obtained interspike distribution.
- We don’t want to describe how the brain does it, but rather why doing it this way is more efficient.
- Maximize the information conveyed by the ISI distribution. Optimization problem.
What is the optimal way for a neuron to fire in order to maximize its ability to communicate information?
if Interspike duration was deterministic and same every time, no information could be conveyed across the channel, regardless of interspike time.
Theorem: Uniform distribution is the distribution with the highest entropy. Intuitively: Maximum surprise.
Proof: Follows from Jensen’s Inequality. $xlogx$ is a concave function. Consider $p_1,p_2…p_n$ such that $\sum_{i=1}^{n}p_i = 1$ $&\implies f(\sum_{i=1}^{n}p_i = 1) \geq \sum_{i=1}^{n}f(p_i)$& $&\implies $&
But uniform distribution also doesn’t fit, So we reform the optimization problem fixed on the constraint
Each neuron can only fire a limited number of times. This makes sense because energy is required for firing and refractory period.
The exponential has the highest entropy if the number of firings are constrained.
To convert histogram to PMF, just normalise by the total number of firings.