^{1}

^{*}

^{2}

^{¤}

^{2}

^{3}

^{2}

^{1}

Current address: Salk Institute for Biological Studies, La Jolla, California, United States of America

Conceived and designed the experiments: KK RC PS KJ. Performed the experiments: KK PS. Analyzed the data: EAP KK RC. Contributed reagents/materials/analysis tools: EAP KK RC KJ LP. Wrote the paper: EAP KJ LP.

The authors have declared that no competing interests exist.

We discuss methods for fast spatiotemporal smoothing of calcium signals in dendritic trees, given single-trial, spatially localized imaging data obtained via multi-photon microscopy. By analyzing the dynamics of calcium binding to probe molecules and the effects of the imaging procedure, we show that calcium concentration can be estimated up to an affine transformation, i.e., an additive and multiplicative constant. To obtain a full spatiotemporal estimate, we model calcium dynamics within the cell using a functional approach. The evolution of calcium concentration is represented through a smaller set of hidden variables that incorporate fast transients due to backpropagating action potentials (bAPs), or other forms of stimulation. Because of the resulting state space structure, inference can be done in linear time using forward-backward maximum-a-posteriori methods. Non-negativity constraints on the calcium concentration can also be incorporated using a log-barrier method that does not affect the computational scaling. Moreover, by exploiting the neuronal tree structure we show that the cost of the algorithm is also linear in the size of the dendritic tree, making the approach applicable to arbitrarily large trees. We apply this algorithm to data obtained from hippocampal CA1 pyramidal cells with experimentally evoked bAPs, some of which were paired with excitatory postsynaptic potentials (EPSPs). The algorithm recovers the timing of the bAPs and provides an estimate of the induced calcium transient throughout the tree. The proposed methods could be used to further understand the interplay between bAPs and EPSPs in synaptic strength modification. More generally, this approach allows us to infer the concentration on intracellular calcium across the dendritic tree from noisy observations at a discrete set of points in space.

Spatiotemporal dendritic imaging data, through fluorescent calcium indicators, opens an exciting window on computations performed by single neurons at a subcellular level. However, the analysis and interpretation of such data is challenging. The measurements are noisy, intermittent in space and/or time, and depend critically on the choice of the fluorescent indicator. Consequently, analysis is typically limited to a specific branch of the dendritic tree, neglects spatiotemporal correlations between neighboring compartments, and requires averaging over multiple trials. Here we derive a model for the spatiotemporal concentration of calcium bound probe molecules. Using state-space and optimization tools we derive a fast algorithm for estimating the most likely concentration based on the given measurements obtained from a single trial, and argue that it can provide an estimate of the fast transients of the underlying calcium concentration. In particular, our algorithm estimates the timing and amplitude of calcium transients due to backpropagating action potentials. It provides a flexible approach to inferring the structure of dendritic dynamics that are important in neural computation, but are inaccessible to direct measurement with current experimental techniques.

The problem of understanding the mechanisms that govern the change in strength of a synapse remains a key problem in cellular neuroscience. Fluorescence microscopy provides a way to examine aspects of the structure and specifically the function of living cells that are inaccessible to direct electrical recording. The experimenter performs optical recordings after delivering fluorescent probe molecules that translate a biological or biochemical signal into an optical output (for reviews see

The development of fast scanning multi-photon microscopy techniques has revealed that intracellular calcium concentrations play an important role in the interplay between backpropagating action potentials (bAPs) and excitatory post-synaptic potentials (EPSPs) that mediate synaptic changes through spike-timing dependent plasticity (STDP). However, the available experimental techniques still lead to noisy and spatiotemporally-subsampled observations of the true underlying calcium signals. Therefore we must use statistical methods to infer the details of the calcium transients from observed data. However, optimal spatiotemporal smoothing of the calcium profile on a dendritic tree given localized noisy measurements remains a difficult computational problem due to the high dimensionality (in terms of number of compartments) and complex structure of dendritic trees.

In this paper we present a general methodology for fast spatio-temporal smoothing of calcium signals on dendritic trees, based on single-trial experiments. We take a functional approach according to which the evolution of calcium concentration on the whole tree is determined from a smaller set of hidden variables. These govern the temporal dynamics of the calcium bound probe molecules, at small but overlapping regions of the tree, and incorporate possible concentration “bumps” due to bAPs, EPSPs or external stimulation. These bumps in the hidden states are in general rapidly increasing and slowly decreasing, and model the corresponding spatially localized bumps in probe molecule concentration due to rapid calcium transients. The calcium measurements are then expressed as linear noisy measurements of the hidden variables. Our problem then reduces to the maximum a-posteriori space-time estimation of these hidden states. Using a standard state-space approach we formulate our problem as one of optimization that can be efficiently solved if the state-transition and measurement-noise distributions are log-concave in the hidden states. In this case the problem can be solved with a cost that scales linearly with

Although related, the problem that we deal with in this paper is different from the one of extracting spikes from mesoscopic fluorescence recordings. In the latter, the data consists of images taken at a low rate from a population of neurons, and the goal is to extract a set of spike times. Several methods have been developed for this problem, such as template matching

We will consider data obtained by measurements of probe fluorescence obtained with fast random-access multi-photon (RAMP) microscopy

Measurements of the light intensity emitted by calcium sensitive dyes at discrete points in space and time can be used to infer the evolving concentration of calcium across the dendritic tree. Here we provide a description of an experimental situation suited for this approach, and show how it leads to a statistical model that can be used to estimate the calcium signal.

Although the statistical methods we present are general, we demonstrate them in the context of a particular experiment. It has been assumed that action potentials that backpropagate from the soma into the dendritic tree play an important role in learning

A: Experimental protocol. In the first protocol 10 spikes were initiated at the soma 500 ms after the start of the recording with a frequency of 10 Hz. In the second protocol, the last action potential was preceded by a series of 3 EPSPs evoked at the dendrites, starting 50 ms before the last spike at a frequency of 50 Hz. B: The relationship between membrane potential and fluorescence. Changes in membrane potential affect the rate of

Each evoked AP backpropagated into the dendritic tree. These bAPs resulted in a transient increase in intracellular calcium concentration, which has been previously shown to result from increased conductance through voltage-dependent calcium channels

Recordings were performed using 3D RAMP microscopy, which uses acousto-optic deflectors (AODs) for high-speed recording within a volume of live brain tissue

The concentration of calcium-bound probe molecules can be used as a proxy for the concentration of calcium in the system. A simplified reaction scheme describing calcium binding is shown in

The light intensity emitted at location

Assuming that probe molecules are conserved locally, i.e.,

The fast calcium signals in the tree, in our case, are due to a bAP that results in a transient increase in the concentration of bound probe molecules. High affinity calcium dyes, such as the Oregon Green BAPTA-1 (OGB-1) used here, bind calcium with a very fast onset and also have a much slower dissociation rate. Neglecting spatial correlations and diffusion terms, we can model the bound probe molecule dynamics as

This baseline probe molecule concentration typically varies across the cell and is difficult to control

Based on the above discussion, we make an important conclusion: The

The signal,

Using Eq. (4) for the dynamics of relative bound probe molecules in the presence of incoming calcium spikes, we have that

More generally, the timing of the APs may not be known or not the same for all the locations in the tree and must be inferred from the bound probe molecule trace. This is a challenging problem in itself

To address the issue of spatial correlations, we model the relative concentration of bound probe molecules at location

As the spline basis functions are typically defined on a line, here we use a suitable generalization to trees. Splines are defined on subdomains of the tree defined by the cell shape. This tree therefore needs to be partitioned. We chose to define the partition using the topological distance from the soma, i.e., the distance from the soma along the tree. Thus all points that lie within a given distance from the center of a spline function belong to the same subdomain. Picking this distance is important because a very large/small value can lead to significant under/over-fitting of the data. In the Results section where we apply our algorithm to experimental data, we propose a data-driven method for determining this parameter.

We discretize the cell into

We assume the same temporal dynamics as in Eq. (2), but now for the weight variables

There are two essential differences between the model described here by Eqs. (8)–(12) and the motivating model described in Eq. (7): estimation of spike times, and incorporation of spatial correlations. In the present model the input,

We use a Bayesian approach, and start by specifying a prior distribution on

Now taking into account the dynamics of probe molecules (see Eqs. (1),(4) and (5)), the emitted light intensity can be written as

We have access to

After discretizing time, Eqs. (8) and Eq. (14), correspond to the state-space model

We emphasize again that Eq. (14) provides a biophysically inspired statistical model. As earlier, we aim to approximate a signal proportional to the bound calcium concentration across the dendritic tree. Note that certain parameters in the model such as the time constant

We would like to compute the maximum a-posteriori (MAP) estimate of the relative spatiotemporal concentration of calcium-bound probe molecules

Additionally, since the calcium concentration is nonnegative, we have to ensure that all the activation variables, as well as the bumps

In the Supporting Information we describe the technical details of a fast method for the solution of Eq. (17). Briefly, we construct a log-barrier method for the incorporation of the non-negativity constraints

We discuss a particular example of choices for the prior and noise likelihoods that are realistic and also ensure log-concavity. As a first example, we consider the case where the

The prior on

A reasonable intuitive choice for the bump prior would be a marked point process

Putting everything together we seek the MAP estimate

We demonstrate our approach using data generated by numerically simulating calcium transients on a dendritic tree, and then continue with the analysis of experimental data.

We apply the developed methodology on a reconstructed dendritic tree from a rat CA1 pyramidal cell. The tree was discretized in

A: True calcium traces of a simulated experiment. Three bAPs were simulated at timesteps 20, 50 and 66. B: Measurement locations and values at each timestep. The dark pixels correspond to locations that were not measured at the specific timestep. C: Inferred weights of the hidden states

Estimated transient due to the second bAP in the simulated experiment. A: True bound probe molecule transients. The transient occurs in the whole tree with an amplitude that decreases with the distance from the soma. B: Noisy measurements and their locations at the time of the bAP. C: Estimated transients. D: Ampltiude error (true - estimated). The amplitude is mostly underestimated due to the bias-variance trade-off. The colorbars for the first and third columns are the same.

Sample code to generate

We also tested the effect of the minimum topological distance between imaged positions. We used the same setup as above, but imaged the signal at 100 locations at every time step. Additionally, at each repetition we imposed a minimal topological distance between the imaged locations. Since the units are arbitrary here the exact results are not reported. However, for small values of the minimal distance the error grows slowly with the minimal separation between the imaged locations. Large errors are observed when the minimal distance between imaged locations becomes comparable or larger than the distance between centers of the interpolating spline functions. In the next section we present an adaptive method of determining the smoothing spline basis based on the locations of the measured locations.

The algorithm was tested on calcium imaging data from a CA1 pyramidal neuron obtained with a fast three dimensional optical scanner. The details of the scanner are given in

A: Tree projected in the x-y plane and measurement locations. Each compartment is also color-coded according to its distance from the soma. The different colors in the measurement locations correspond to the different imaging sessions. Right: Detailed subtrees in three dimensions for the three different imaging sessions. B: Subtree A, recording locations in the apical tuft. C: Subtree B, recording locations around the apical dendrites. D: Subtree C, recording locations around the soma and basal dendrites. All the units are in

For each pair of imaging data we estimated one set of model parameters, so that the results of the imaging algorithm on the two different protocols could be compared. The measured data was normalized using the

Our model has several parameters that have to be estimated before we apply our smoothing algorithm. These are the baseline probe molecules concentration, the time constant of calcium unbinding and the noise statistics. Below we describe simple heuristic methods to estimate the model parameters. In practice more sophisticated and powerful methods can be developed such as Monte Carlo estimation methods (e.g. via the Expectation Maximization algorithm)

The baseline fluorophore concentration

Next, the decay constant of the recorded signal,

The state transition (amplitude) prior was considered to be an exponential distribution, as discussed in the Methods section. There a marked point process with rate

Finally, the noise likelihood at each measurement location was assumed to be independent and Gaussian with zero mean, and variance estimated directly from the measurement traces. To find the noise statistics we subtracted the filtered traces

For each subfigure: First column: Raw data

The first row (A) of

Detailed probe molecule traces for one location of each subtree (marked with the blue electrodes on the right columns) and profile of the amplitude of the last transient inferred in the whole subtree. A: Detailed measured and inferred trace for the whole length of the experiment at the marked location of subtree B. At each of the other rows: Detailed measured data and smoothed traces (

In some cases, there are also a few spikes detected outside the

A possible solution to prevent such spikes would be to set the spike rate outside the excitation window to a very low value. However this led to overfitting in the amplitude of the spikes in the interval

From

As an additional test of the robustness of our results we examined how removing measurements from selected locations affects the inferred traces. In

A: Locations of the omitted imaged sites and relative error between “full” and “cross-validated” results along the tree. B–D: Comparison of the “full” traces (blue) with the cross-validated traces at the omitted locations. The colors of the “cross-validated” traces are in correspondence with the colors of the fictional electrodes in panel A. The algorithm can predict the traces at left out imaging sites that are located in the middle of dendritic branches by interpolating the results from neighboring measured locations. However the traces of omitted compartments located at the end of branches cannot be inferred.

The results shown in

Finally, we examined the effect of the temporal sampling rate, by applying our algorithm to a subsampled version of the data. In

A and D: Inferred traces using all the data for subtree B under the bAP protocol. B and E: Inferred traces after

We finally applied our algorithm to simulated data in a dendritic tree receiving multiple synaptic input from both excitatory and inhibitory presynaptic neurons. (These simulations are necessarily somewhat underconstrained, since the spatiotemporal structure and effect of in-vivo inputs is only beginning to be characterized

A: Morphology of the CA1 neuron in the x-y axis. B: Voltage trace at the soma. 80 synaptic events were simulated and the neuron produced 10 action potentials. Neuron model and code adapted from

Every

A: Spatiotemporal voltage profile. B: Bound probe molecule profile: C: Measurement locations and values at each timestep (dark grey corresponds to locations that were not imaged at each timestep). D: Estimated bound probe molecule profile. The algorithm estimates satisfactorily the general behavior of the bound probe molecule concentration profile.

We presented a statistical model for spatiotemporal calcium estimation (up to an affine transformation) given single-trial, spatially localized, noisy imaging measurements. We showed that our algorithm can infer the timing of bAPs and provide estimates about the amplitude of the transients that they initiate. Although the optical measurements come from a small subset of the neuron's compartments the algorithm estimates the full spatiotemporal calcium profile. Moreover, it runs with complexity that scales linearly both with the length of the experiment and the size of the tree, and as a result it can be used in arbitrarily long experiments and large dendritic trees. Our full spatiotemporal smoothing algorithm therefore enables the study of selective propagation of bAPs into specific dendrites, and of the effects of calcium as a coincidence indicator between bAPs and EPSPs. Although the focus of this study was the study of the interactions between bAPs and known EPSP stimulation, we also tested the generality of our algorithm by applying it to a conductance based neuron driven by random (unobserved) synaptic inputs. More generally, our algorithm opens up the possibility of single-trial analysis of spatiotemporal calcium dynamics imaged on large dendritic trees, and could therefore potentially lead to a better understanding of these complex dynamics.

To obtain a relatively simple model and an efficient inference algorithm, we had to make a number of assumptions. For example, we employed a functional approach by assuming that the relative bound probe molecule concentration can be spatially approximated by a sum of smooth spline functions on the tree. This is reasonable since calcium diffuses locally through the dendritic tree. We assumed that the baseline fluorescence is constant before and after the spike stimulation. While this is true in general, we observed that in some locations (and especially the ones in the main dendritic trunk), the baseline can change significantly after the excitation, leading to the inferred spikes outside the excitation window, as discussed in the Results. The model also relies on the assumption that the bound probe molecules do not saturate during repetitive excitation, and that the rate of calcium unbinding remains constant. Analysis shows that the amplitude of the transients in general decreases as more spikes are applied. This has been reported in many studies (e.g.

Apart from constructing a spatial basis for the relative bound probe molecules, we also tried the same approach on the un-normalized, raw bound probe molecule measurements. However, we noticed that in this case the required dimension

Our model, so far, assumes only temporal dependencies on the hidden activation states

The prior on the transient amplitude used in our model was very simple. It reflected only the knowledge of the interval over which the bAPs were initiated and their rate, but not the exact timing of the bAPs and other qualitative characteristics of the evoked transients. A more sophisticated prior can be chosen that exploits several characteristics of the bAPs. For example, the exact knowledge of the bAP timings can be incorporated to a greater extent by manipulating the time varying spike rate so that it becomes high in the time windows when we expect spikes, and low elsewhere. Moreover, at the dendrites, the amplitude of spikes usually decreases with the distance from the soma. In our approach “we let the data speak”, i.e., we determine the prior of the spike amplitude from the recordings as we discussed in the Results section. However, we can further impose a decreasing amplitude constraint as a regularizer to further promote this behavior, to better deal with the case where individual dendrites are very sparsely imaged. In matrix-vector notation this can be written as

One natural question is whether the full spatiotemporal profile of calcium concentration can also be estimated. Our model promotes the inference of sparse events; this sparse regularization is necessary to avoid overfitting artifacts given our undersampled measurements. These sparse events, in turn, are interpreted as indicators of calcium concentration transients which are assumed to be instantaneous. As a result, due to these simplifications the detailed calcium dynamics cannot easily be inferred from our algorithm at its current form; see the Methods section for further discussion. Additional constraints on the model (e.g., a modification of the prior based on some knowledge of synaptic input locations) could improve this estimation, but this remains a direction for future work.

A final interesting question concerns the design of an optimal path for measuring at different locations across the tree. In our dataset the set of imaged sites was chosen by the experimenter and held fixed for each imaging session. Such an approach is suboptimal since it leaves many sites unrecorded and also neglects the spatial correlations along the tree. A heuristic method was presented in

Description of the log-barrier method for the fast solution of our MAP estimation problem.

(PDF)

We thank T. Machado and P. Kaifosh for helpful discussions that improved the presentation of the paper.