Variance adaptation in navigational decision making
 Cited 3
 Views 1,061
 Annotations
Abstract
Sensory systems relay information about the world to the brain, which enacts behaviors through motor outputs. To maximize information transmission, sensory systems discard redundant information through adaptation to the mean and variance of the environment. The behavioral consequences of sensory adaptation to environmental variance have been largely unexplored. Here, we study how larval fruit flies adapt sensorymotor computations underlying navigation to changes in the variance of visual and olfactory inputs. We show that variance adaptation can be characterized by rescaling of the sensory input and that for both visual and olfactory inputs, the temporal dynamics of adaptation are consistent with optimal variance estimation. In multisensory contexts, larvae adapt independently to variance in each sense, and portions of the navigational pathway encoding mixed odor and light signals are also capable of variance adaptation. Our results suggest multiplication as a mechanism for odorlight integration.
https://doi.org/10.7554/eLife.37945.001Introduction
The world is not fixed but instead varies dramatically on multiple time scales, for example from cloudy to sunny, day to night, or summer to winter; and contexts: from sun to shade, or burrowing to walking. Nervous systems must respond appropriately in varied environments while obeying biophysical constraints and minimizing energy expenditure (Niven and Laughlin, 2008). Sensory systems use strategies at all levels of organization, from subcellular to networklevel structures, to detect and transmit relevant information about the world to the rest of the brain, often operating near the limits imposed by their physical properties (Bialek, 1987; Niven and Laughlin, 2008).
One strategy to maximize the conveyance of sensory information is to reduce redundancy by filtering out predictable portions of sensory inputs (Barlow, 1961; Attneave, 1954; Srinivasan et al., 1982). Early evidence of efficiency in the way sensory neurons encode environmental information was found in the large monopolar cells of the blowfly retina, whose responses to intensity changes were found to be optimally matched to the range of stimuli encountered in the fly's natural environment (Laughlin, 1981). If neurons' responses are indeed tuned to a specific environmental distribution of inputs, then when environmental conditions change, the neurons' coding must adapt to the new environment’s statistics to maintain an efficient representation of the world (Tkačik and Bialek, 2016; Maravall, 2013).
A rich field of study has explored adaptation of neural coding to the statistics, particularly the mean and variance, of sensory stimuli (Wark et al., 2007). Variance adaptation has been measured across diverse organisms in visual, auditory, olfactory, and mechanosensory systems and in deeper brain regions (Brenner et al., 2000; Fairhall et al., 2001; Kvale and Schreiner, 2004; Dean et al., 2005; Nagel and Doupe, 2006; Dahmen et al., 2010; Maravall et al., 2007; De Baene et al., 2007; Wen et al., 2009; GorurShandilya et al., 2017; Clemens et al., 2018; Smirnakis et al., 1997; Gollisch and Meister, 2010; Clifford et al., 2007; Liu et al., 2016; Kim and Rieke, 2001) pointing to a potentially universal function implemented by a broad range of mechanisms.
Classic experiments in blowfly H1 neurons showed that variance adaptation in the firing rate maximized information transmission (Brenner et al., 2000; Fairhall et al., 2001). Because the role of these neurons is to transmit information, we can say this adaptation is ‘optimal,’ in a welldefined theoretical sense. It is less clear how to test for optimality in the adaptation of behaviors to changes in environmental variance.
If the brain enacts behavior based on rescaled sensory input, one might expect that these behaviors should also adapt to stimulus variance. In rhesus monkeys performing an eye pursuit task (Liu et al., 2016), adaptation to variance was observed in both the firing rates of MT neurons, maximizing information transmission, and in the ultimate eye movements, minimizing tracking errors, showing that efficiency in neural coding has observable effects on behavioral responses.
On the other hand, animals choose behaviors to achieve an end goal. For general sensorydriven behaviors, this goal, for example flying in a straight line or moving toward a potential food source, does not require maximizing the transmission of information about the stimulus to an observer of the behavior. In these cases, it might be adaptive for the brain to restore some or all information about environmental variance before choosing which behaviors to express.
To explore the role of variance adaptation in a general sensory information processing task, we studied how Drosophila larvae adapt their navigational decisions to variance in visual and olfactory stimuli. Navigation requires the larva to transform sensory information into motor output decisions in order to move to more favorable locations, and the larva’s navigational strategies have been characterized for a variety of sensory modalities (GomezMarin and Louis, 2012; Gershow et al., 2012; GomezMarin and Louis, 2012; GomezMarin et al., 2011; Kane et al., 2013; Lahiri et al., 2011; Louis et al., 2008; Luo et al., 2010; Sawin et al., 1994). Drosophila larvae move in a series of relatively straight runs interspersed with reorienting turns. A key element of the larva’s navigational strategy is the decision to turn, that is to cease forward movement and execute a reorientation maneuver to select a new direction for the next run. This decision can be modeled as the output of a LinearNonlinearPoisson (LNP) cascade and characterized through reverse correlation (Gepner et al., 2015; HernandezNunez et al., 2015; Aljadeff et al., 2016; Parnas et al., 2013; Schwartz et al., 2006; Chichilnisky, 2001).
In this work, we investigate how the navigational decision to turn adapts to the variance of sensory input by characterizing how changes in stimulus variance lead to changes in LNP model parameters. We show that larvae adapt to the variance of visual stimuli and of olfactory inputs processed by a range of olfactoryreceptor neurons. We find that adaptation can be characterized as a rescaling of the input by a factor that changes with the variance of the stimulus. We show that the timescales of turnrate adaptation are asymmetric with respect to the direction of variance switches and are consistent with optimal estimation of environmental variance (Wark et al., 2009; DeWeese and Zador, 1998). We find that in a multisensory context, adaptation is implemented independently on visual and olfactory inputs and also in the pathway that processes combined odor and light signals. We propose that multisensory integration may result from multiplication of signals from odor and light channels.
Results
As a model for how organisms adapt their behavioral responses to changes in environmental variance, we explored visual and olfactory decision making by larval Drosophila. In previous work, we modeled the larva’s decision to turn (stopping a run in order to pick a new heading direction) as the output of a LinearNonlinearPoisson (LNP) cascade (Figure 1a). This model took as its input the derivative of stimulus intensity, and we used reversecorrelation to find the LNP model parameters (Figure 1b).
In this work, we extended the analysis to ask how larvae adapt their responses to changes in the variance of the input stimuli. We again provided visual stimuli through blue LED illumination and fictive olfactory stimuli through red LED activation of CsChrimson expressed in sensory neurons. The illumination was spatially uniform and temporally fluctuating, with derivatives randomly drawn from normal distributions. The variance of these normal distributions dictated the amplitude of temporal fluctuations. We changed the variance of these distributions (Figure 1c), and studied the resulting changes in the behavioral response as measured by changes in the LN model parameters (Figure 1d,e).
There is a subtle difference between stimulus and model input. For instance, in work on adaptation in blowfly H1 (Brenner et al., 2000; Fairhall et al., 2001), the stimulus was light reflected from a pattern of black and white stripes, while the model input was the horizontal velocity of this pattern. The experimenters then measured adaptation to the variance of this input.
In our experiments, the stimulus was projected light whose intensity varied in a Brownian random walk. The model input was the timederivative of the stimulus intensity. This has two important advantages. First, it provides a mean zero input that is uncorrelated on all time scales, simplifying analysis and interpretation. Second, when we change the variance of the input, we change the statistics of how quickly the light level changes, but we do not change the mean or variance of the light intensity itself, eliminating potential confounds due to adaptation to overall light intensity.
Larvae adapt their turnrate to the variance in visual and olfactory sensory inputs
We first asked whether larvae adapt their behavior to changes in the variance of sensory input and if so, how. In one set of experiments, we presented wildtype larvae with blue light whose intensity derivatives were randomly drawn from normal distributions with low or high variance. In another set of experiments, we used a fictive olfactory stimulus generated by red light activation of CsChrimson expressed in Or42a sensory neurons.
In both sets of experiments, the environment switched between low and high variance $({\sigma}_{high}^{2}=9{\sigma}_{low}^{2})$ every 60 s. We expected that following a switch in variance, larvae would require some time to adapt their behaviors. We therefore discarded the first 15 s (this amount of time is justified later) following each transition and analyzed the larvae’s responses separately in low and high variance contexts.
In the LNP framework, adaptation to variance could take two forms  a change in the shape of the linear filter kernel (Kim and Rieke, 2001; Baccus and Meister, 2002), representing a change in the temporal dynamics of the response, and/or a change in the shape of the nonlinear function, representing a change in the strength of the response to a particular pattern of sensory input. Both forms of adaptation have been reported in sensory neurons (Wark et al., 2007; Maravall, 2013). In adult Drosophila, ORN firing rates adapt to variance of both natural and optogenetic inputs through a change in the nonlinearity (GorurShandilya et al., 2017).
We first examined the shape of the filter kernel. To find the kernel, we calculated the 'turntriggered average’ (Gepner et al., 2015), the average input preceding a turn, at both low and high variance. Given an uncorrelated input and a large number of turns, the kernel is proportional to the turntriggered average (Chichilnisky, 2001), but the constant of proportionality is unknown and can be absorbed into the nonlinear stage. We therefore scaled both the low and high variance turntriggered averages to have the same peak value. We found that for both visual and fictive olfactory stimuli, the scaled turntriggered averages were nearly identical at low and high variance (Figure 1d), although at low variance, the averages had a slightly longer ‘shoulder’ 3–4 s prior to the eventual turn.
As the kernel shape did not strongly depend on the input variance, we first used the turntriggered average for all data to estimate a single kernel for both low and high variance. We scaled this kernel so that the filter output had variance one in the lowvariance condition. We then calculated the rate function at low and high variance to determine whether the magnitude of the larva’s response to stimulus changes adapted to environmental variance (Figure 1—figure supplement 1). We found that for both visual and fictive olfactory stimuli the rate function (Figure 1e) was steeper at low variance than high variance, indicating a more sensitive response to the same input in the low variance context.
We then asked whether it might be more appropriate to use separate filters for low and high variance stimuli. We separately convolved the high and low variance stimuli with filters derived from the high and low variance turntriggered averages (Figure 1d) and again calculated nonlinear rate functions at high (Figure 1—figure supplement 2a,c) and low (Figure 1—figure supplement 2b,d) variance. These rate functions were nearly identical to those we found using a single shared kernel. Thus, the different slopes of the rate functions at high and low variance (Figure 1e) are not due to mismatches in temporal dynamics between the filter derived from the pooled data and the variancespecific filters.
As it had little effect on the extracted rate functions and greatly simplified analysis, we used a single filter derived from pooled data in the remainder of our work.
Larvae adapt to variance by rescaling the input
A larger response to the same input in a low variance context indicates variance adaptation. Several functional forms of adaptation have been proposed and measured. Rescaling the sensory input (input rescaling) by its standard deviation maximizes information transmission and has been observed in blowfly H1 neurons (Brenner et al., 2000) and in salamander retina (Kim and Rieke, 2001; Kim and Rieke, 2003), equivalently characterized as a change in amplitude of the linear filter kernel. On the other hand, many biophysically plausible models of variance adaptation (Ozuysal and Baccus, 2012) function by rescaling the output of a nonlinear function or by the summation of saturating nonlinear functions of correlated input (Nemenman, 2012; Nemenman, 2010; Borst et al., 2005).
We asked whether the adaptation we observed in the nonlinear rate function could be better described as an input or output rescaling. We used maximum likelihood estimation to find the best fit model of each form for the entire visual or olfactory data set and measured the improvement compared to the bestfit model without rescaling (Figure 2a,d). We found that an input rescaling far better described the adaptation than an output rescaling, a straightforward consequence of the high and low variance rate functions having the same nonzero output at zero stimulus input. We therefore also considered whether recentering followed by rescaling of the output could describe the adaptation, but again found that input rescaling better described the adaptation.
Next we asked whether the models differed in their abilities to predict held out test data. We fit each model to a subset of 14 out of 17 experiments and found the likelihood of the data in the held out three experiments given the fit model. For each permutation of fit and test data, we calculated the improvement in the log likelihood of the test data compared to the predictions of a null model without rescaling. As with the fits to the entire data set, we found that the input rescaling model was better at predicting held out data than either output rescaling model, in the aggregate (Figure 2b,e) and on a trialbytrial basis (Figure 2c,f).
Asymmetric rates of variance adaptation to a variety of sensory inputs
Having found that larvae adapt to the variance of visual stimuli and of optogenetically induced activity in the Or42a receptor neuron, we next explored the timescales and generality of the adaptation. We expected that following a change in environmental variance, larvae would require some time to adapt their responses, a process that could be described by adding time dependence to the nonlinear rate function. Since we found that adaptation was best described as a rescaling of the input to a nonlinear function, we modeled the timevariation of the rate function as a timevarying input rescaling
where $x$ is the output of the linear filter stage and ${\lambda}_{0},b,c$ are constants to be determined.
To find the time scales of turnrate adaptation to abrupt changes in sensory input variance, we decreased the period of the variance switching experiments to 40 s to increase the number of transitions. To test the generality of adaptation, we explored the visual response, activation of neurons that produce attractive responses (Or42a, Or42b), and activation of neurons that produce aversive responses (Or59a, Or35a, Gr21a). We found that in all cases, the linear filters were nearly the same at high and low variances and that the slope of the nonlinear rate function adapted to variance (Figure 3a,b).
We then estimated the timevarying input rescaling $\alpha (t)$ (Figure 3c). We found that for all inputs this scaling factor decreased suddenly following a step increase in variance but increased more gradually following a step decrease. This is consistent with the response of an optimal variance estimator (DeWeese and Zador, 1998).
We asked whether the temporal dynamics in our estimate of $\alpha (t)$ arose from the larva’s behavior or from the estimation process itself. To control for the latter possibility, for each set of experiments, we developed a control model in which ${\alpha}_{control}$ switched instantly along with the variance while all other parameters of the model were unchanged. We used this control model to generate a fictional set of turn responses to the same input stimulus, matching the number of experiments and larvae to the original data set. We passed this fictive data set through our estimator and recovered ${\alpha}_{control}(t)$ (Figure 3c, gray line). We found that, the estimator always reported a sharp and symmetric transition in ${\alpha}_{control}$. Therefore the observed slower adaptation of $\alpha $ to variance decreases does not result from the estimation process.
Variance adaptation under different stimulus statistics
In these experiments, we chose a stimulus whose derivatives at all time points were uncorrelated random gaussian variables. The trace of light intensity vs. time was therefore a Brownian random walk with reflecting boundary conditions, and changing the variance of the derivatives was equivalent to changing the diffusion constant (Figure 4—figure supplement 1a,b). An advantage of this stimulus is that the light levels themselves are uniformly distributed over the entire range, for both low and high variance conditions (Figure 4—figure supplement 1c), so that adaptation to variance cannot be explained, for instance, as due to saturation of channels or receptors at high light intensities.
It is also possible to perform behavioral reverse correlation using a stimulus with uncorrelated random values (HernandezNunez et al., 2015). We wondered whether we would also observe variance adaptation using such a stimulus. We exposed Berlin wild type larvae to a blue light stimulus with random intensity updated every 0.25 s. The mean of the intensities was constant, but the variance switched periodically (${\sigma}_{high}^{2}=9{\sigma}_{low}^{2}$). When the variance of the intensities switched so did the variance of the derivatives (Figure 4—figure supplement 1gi,k). While the intensities were uncorrelated on all time scales (Figure 4—figure supplement 1j), subsequent changes in intensity were strongly anticorrelated (Figure 4—figure supplement 1i).
We first considered a stimulus whose variance changed every 60 s. We analyzed the responses as we did for the analogous visual experiments of Figure 1. The linear filter, found as the mean subtracted and scaled turntriggered average, encoded the same temporal dynamics at low and high variance (Figure 4a). The nonlinear rate function was steeper in the low variance condition (Figure 4—figure supplement 1b) indicating variance adaptation. We then examined the temporal dynamics of adaptation using a stimulus whose variance switched every 20 s (in analogy to Figure 3) and found a faster adaptation to an increase in variance than a decrease (Figure 4c). These results all agreed with those of our experiments using uncorrelated stimulus derivatives.
Larvae adapt to variance through a simple rule
Although the temporal dynamics of the input rescaling are consistent with an optimal estimate of the variance, it is not straightforward to test whether the observed $\alpha (t)$ truly reflects an optimal estimate. When the spike rate of a neuron adapts to environmental variance, there is a sound theoretical reason to believe it does so to maximize information transmission (Brenner et al., 2000; Tkačik and Bialek, 2016) and therefore that $\alpha \propto 1/\sigma$. However, for behavior, it is not clear if there is a theoretically optimal relation between $\alpha $ and ${\sigma}^{2}$.
We therefore sought to experimentally determine the relation chosen by the larva between input rescaling and observed variance. To do this, we slowly varied the stimulus variance in time in a triangular pattern and continuously monitored the scaling parameter $\alpha (t)$ (Figure 5a). If the variance changed slowly enough, the larva would be constantly adapted and the input rescaling $\alpha (t)$ could be taken to be a function of the variance ${\sigma}^{2}(t)$ at that time point only.
We related $\alpha (t)$, the timevarying rescaling parameter averaged over many cycles (colored lines, Figure 5a) to $\sigma (t)$, the cycle averaged stimulus standard deviation (black line, Figure 5a) to calculate $\alpha (\sigma )$ (Figure 5b). We estimated $\alpha (\sigma )$ using the full data set and separately for periods of increasing and decreasing variance. If the larvae were not continuously adapted to the variance, we would expect to see different estimates of $\alpha $ during the rising and falling phases, due to hysteresis. We found the same scaling vs. variance curve for the rising and falling phases, indicating that our measured $\alpha (\sigma )$ represented the larva’s adapted rescaling law.
To analytically describe the larva’s rescaling rule, we began with the input rescaling that maximizes information rescaling: $\alpha \propto 1/\sigma $. To better fit the data, we considered the possibility that the total variance might be due to both sensory input and other intrinsic noise sources: ${\sigma}_{total}^{2}={\sigma}^{2}+{\sigma}_{0}^{2}$, where ${\sigma}^{2}$ is the variance we introduce through the sensory input and ${\sigma}_{0}^{2}$, the intrinsic noise, is a fit parameter.
The solid line in Figure 5b shows the best fit to the data of this rescaling model
This model can be interpreted as an attempt at ‘optimal’ rescaling in the presence of intrinsic noise ${\sigma}_{0}^{2}$ and/or as an adaptation to prevent large behavioral responses to minute changes in an otherwise static environment.
Adaptation is consistent with an optimal variance estimate
Now that we could relate $\alpha (t)$, the measured input rescaling, to the larva’s internal estimate of variance, we asked whether the larva’s estimate of variance made the best use of sensory input. We constructed an optimal Bayes estimator that periodically sampled the input stimulus and assumed that environmental variance changed diffusively. The variance estimator has two free parameters. One, $\tau $, represents a prior assumption of the timescale on which the variance is expected to fluctuate; the other, $\mathrm{\Delta}t$, represents the frequency with which the estimator receives new measurements. Measuring more often leads to faster adaptation.
We fed our experimental stimulus into this estimator to determine what an observer would determine the best estimate of the variance to be at each time in the experiment. This variance estimate depended on the stimulus history and the parameters $\tau $ and $\mathrm{\Delta}t$.
We then calculated the appropriate input rescaling using Equation 3 and found the parameters of the static rate function that maximized the loglikelihood (Materials and methods) of the observed sequence of turns:
with
and dt = $1/20$ second, the interval at which we sampled the behavioral state.
From these calculations, we found the values of $\tau $ and $\mathrm{\Delta}t$ that maximized the likelihood of the data: For visual response these were $\mathrm{\Delta}t=0.85\pm .07$ s and $\tau =6\pm 2.5$ s, and for Or42a activation, these were $\mathrm{\Delta}t=.7\pm .15$ s and $\tau =11\pm 5$ s (95$\%$ confidence intervals, dotted white regions in Figure 6a).
We then compared the predicted rescaling vs. cycle time for the best fit model to the observed rescaling (Figure 6b) and found close agreement between the predicted and measured rescalings. When we compared the predictions produced by estimators with the same value of $\tau $ but different values of $\mathrm{\Delta}t$, we found substantial disagreement between the predicted and measured rescalings (Figure 6b). Thus, the larva’s adaptation to environmental variance is consistent with an optimal estimate of that variance and indicates an input sampling rate of ~ 1.2–1.5 Hz.
Larvae adapt to variance at multiple levels in the navigational pathway
Previously, we studied how larvae combine visual and olfactory information to make navigational decisions. We found that in response to multisensory input, the turn rate was a function of a single linear combination of filtered odor and light signals (Gepner et al., 2015). We also found that larvae used quantitatively the same linear combination of light and odor to make decisions controlling turn size and turn direction, suggesting that light and olfactory signals are combined early in the navigational pathway. Here, we asked whether adaptation to environmental variance occurs upstream or downstream of this combination.
To determine the locus of variance adaptation, we presented visual and olfactory white noise inputs simultaneously. The inputs were uncorrelated with themselves or each other; one input remained at constant variance while the other periodically switched between low and high variance. We analyzed the resulting behavior assuming that the turn rate was a nonlinear function of a linear combination of filtered light (${x}_{L}$) and odor (${x}_{o}$), each of which was subject to independent input rescaling
If the larva adapted to variance in each sense individually, we would expect that only the stimulus whose variance was changing would be subject to adaptation, for example for changing odor variance, we would expect $\alpha $ to vary in time and $\beta $ to be constant. On the other hand, if the larva adapted to the variance of, and hence rescaled, the combined odor and light input, we would expect that whether the odor or light were switching variance, both $\alpha $ and $\beta $ would change. We found that only the response to the switching stimulus adapted, while for the fixedvariance stimulus, the turnrate remained constant (Figure 7), indicating that variance adaptation is accomplished on a unisensory basis and prior to multisensory combination.
Note that we have simplified the rate function to be an exponential of a linear (rather than quadratic) function of ${x}_{o}$ and ${x}_{L}$. This choice is motivated in the next section, but the same conclusion  that larvae adapt to variance on a unisensory basis  is reached if a quadratic combination of odor and light is used instead.
We next asked whether variance adaptation was a unique feature of the sensory systems or a more general feature of the navigational circuit. To probe whether variance adaptation can occur in the portion of the navigational circuit that processes combined odor and light information, we presented larvae with visual and olfactory stimuli of fixed variance, but changed the variance of the combined input.
To create a stimulus with constant unisensory variance but changing multisensory variance, we presented random white noise visual and olfactory stimuli of constant variance but altered the correlation between them. In the ‘high variance’ condition, changes in odor and light were negatively correlated (correlation coefficient = −0.8), so unfavorable decreases in odor coordinated with unfavorable increases in light. In the ‘low variance’ condition, changes in odor and light were positively correlated (correlation coefficient = +0.8), so that favorable increases in odor were coupled with unfavorable increases in light. A circuit element that received only light or odor inputs would be unable to distinguish between the ‘high’ and ‘low’ variance conditions, but an element that received a sum of light and odor inputs would observe a much more dynamic environment in the ‘high variance’ condition.
To analyze these experiments, we created a rotated coordinate system based on ${x}_{o}$ and ${x}_{L}$, the outputs of the odor and light filters (Gepner et al., 2015) (Figure 8—figure supplement 1),
$\theta $ is a parameter that controls the weighting of odor and light along the two axes of the rotated coordinate system. We constructed the stimulus so that for $\theta ={45}^{\circ}$, $u$ and $v$ were uncorrelated, and had oppositely changing variances with ${\sigma}_{high}^{2}=9{\sigma}_{low}^{2}$. We then analyzed the resulting behavior as before, assuming the turn rate was a nonlinear function of $u$ and $v$, each of which was subject to independent input rescaling
As in our previous work (Gepner et al., 2015), we found a value of $\theta $ (${38}^{\circ}$) for which $b\approx 0$ for the entire data set. For this value of $\theta $, $b\approx 0$ in both the low and high variance conditions.
Because $v$ had negligible influence on the turn decision, there was no way to determine ${\alpha}_{v}$. We found that ${\alpha}_{u}$ varied with time, increasing when the variance of $u$ was lower, although the adaptation was less pronounced than for the unisensory variance changes (Figure 7). This adaptation must be implemented by circuit elements that have access to both light and odor inputs, showing that elements of the navigational circuit well downstream of the sensory periphery also have the ability to adapt to variance.
Input rescaling likely occurs near the sensory periphery; sensespecific variance adaptation suggests multiplication as a mechanism for multisensory integration
When presented with both light and fictive odor cues, larvae adapt to the variance of each sense individually prior to multisensory combination (Figure 7). We previously found that larvae linearly combine odor and light stimuli to make navigational decisions (Gepner et al., 2015). Taken together, these results require a form of variance adaptation that preserves linearity.
Measurement of variance is an inherently nonlinear computation, and we are not aware of any biophysical model of variance adaptation that preserves a linear representation of the stimulus. Adaptation to variance can be achieved by rescaling the output of a rectifying nonlinearity (Ozuysal and Baccus, 2012) or by summation of saturating nonlinearities with correlated inputs (Nemenman, 2012; Borst et al., 2005). A modified HodgkinHuxley model of salamander retinal ganglion cells (Kim and Rieke, 2003; Kim and Rieke, 2001) showed that scaling of the linear filter (equivalent to scaling the input to the nonlinear function) resulted from adaptation of slow Na+ channels to the mean firing rate of the neuron. While this model linearly rescales the filter, it requires feedback from the nonlinear output of the neuron.
Rectified signals encoding opposite polarities can be combined to produce a linear response (Werblin, 2010; Molnar et al., 2009), but there is no evidence of such competing pathways in the larva’s olfactory system. The adult fly adapts to variance beginning in the olfactory receptor neurons themselves (GorurShandilya et al., 2017), making it further unlikely that variance adaptation in the larva is accomplished through rescaling of downstream opponent pathways.
How does the larva adapt to variance through a nonlinear process, prior to apparently combining sensory signals linearly? We can resolve this puzzle by changing our model of multisensory integration. In our previous work (Gepner et al., 2015), we considered a model in which odor and light turning decisions were mediated by entirely separate pathways, both modeled as LNP processes (Figure 8a).
This model would be easy to reconcile with modalityspecific variance adaptation, but it was far less consistent with our observations of larvae’s responses to multisensory input than a competing model (Figure 8b) that described the twoinput rate function ${\lambda}_{2}({x}_{o},{x}_{L})$ as a oneinput function of a linear combination of odor and light
While this model makes predictions that are consistent with our multisensory white noise and step experiments, to be consistent with our multisensory variance adaptation experiments, it requires an unknown form of variance adaptation that preserves linearity.
We propose an alternate model (Figure 8c), that the twoinput rate function might be the product of two unisensory rate functions, as recently found in human psychophysical experiments (Parise and Ernst, 2016).
Multiplicative multisensory integration would allow unisensory adaptation to variance through a rectifying nonlinearity while preserving a fundamental feature we observed in multisensory decision making, the ability of favorable changes in one stimulus modality to compensate for unfavorable changes in the other.
In this work and previously (Gepner et al., 2015), we modeled the rate function as an exponential of a polynomial function of the filtered input. For a linear polynomial, there is no difference between adding odor and light inputs prior to the exponential nonlinearity and multiplying two exponential functions
In analyzing the multisensory experiments of Figure 7, we therefore modeled the rate as an exponential of a linear combination of odor and light, to avoid favoring one model of integration over the other.
For exponentials of a quadratic polynomial, like the 'ratioofgaussians’ (Pillow and Simoncelli, 2006) we used previously, there are quantitative differences between adding the rate function inputs and multiplying rate function outputs, but these can be small, especially if the polynomials are nearly linear over the range of inputs provided in the experiment. We reanalyzed the data of Gepner et al. (2015) to determine if multiplicative integration could describe the results as well. While the two models made very similar predictions, we found that for both white noise (Figure 8—figure supplement 1) and step experiments (Figure 8—figure supplement 2), the multiplicative model produced a statistically significantly better fit to the data than did the early linear combination model, even after accounting for the different number of model parameters. The multiplicative model also better predicted heldout data. Thus, the multiplicative model is at least as explanatory as the early linear combination model for multisensory experiments with constant variance inputs, and it can be reconciled more easily with our finding that larvae adapt to the variance of a sensory input prior to multisensory combination. Taken together, these results suggest multiplication as a mechanism for multisensory integration.
Larvae adapt to variance of natural odor backgrounds
In all experiments presented so far, we explored variance adaptation using blue light to present a natural visual stimulus and red light to create fictive olfactory stimuli via optogenetic activation of sensory neurons. Although adaptation to variance of blue light clearly represents a natural response of the visual system, we might wonder to what extent adaptation to variance of fictive stimuli reflects particular properties of the optogenetic channel or peculiarities in fictive rather than natural sensory transduction. We therefore sought to directly measure whether larvae adapt to variance in a natural odor environment.
Although it is difficult to 'flicker’ an odor across an extended arena with the speed and precision required for reverse correlation, it is more straightforward to create an odor background of known variance, even if the actual gas concentrations at any particular point in space and time are unknown. We placed larvae in a flow chamber with a constant stream of carrier air and a varying amount of carbon dioxide injected at the inlet. The resulting concentration fluctuations propagated across the arena while being attenuated somewhat by diffusive mixing. Because the flow was laminar, the entire system could be described by linear equations, and the average fluctuation of carbon dioxide at any point in the arena was therefore linearly dependent on the magnitude of the fluctuations at the inlet. We varied the concentration of CO${}_{2}$ at the inlet in a sinusoidal pattern
In all our experiments, $\mu $, the mean concentration, was $5\%$, and $\tau $, the period of oscillation was 20 s. In the low variance condition, $A$, the amplitude of the oscillation was $1\%$, while in the high variance condition $A=4\%$. In both conditions, we presented identical red light inputs of constant variance to larvae expressing CsChrimson in CO${}_{2}$ receptor neurons. We then asked whether the larva’s response to the fictive stimulus depended on the variance in the background concentration of natural carbon dioxide.
Using our standard reversecorrelation analysis, we extracted the linear kernel (which was the same in both low and high variance conditions) and nonlinear rate function. We found that the rate function was steeper in the low variance context (${\alpha}_{high}/{\alpha}_{low}=1.56\pm 0.07$), indicating that a fluctuating background of CO${}_{2}$ reduces the larva’s sensitivity to optogenetic activation of the CO${}_{2}$ receptor neurons (Figure 9a).
We next asked whether changing the background variance of CO${}_{2}$ would influence the response of the larva to activation of the Or42a receptor neuron, which does not respond to carbon dioxide. We found that a higher variance CO${}_{2}$ reduced the response of larvae to activation of the Or42a receptor neurons (${\alpha}_{high}/{\alpha}_{low}=1.35\pm 0.05$), but this effect was less pronounced than for activation of the CO${}_{2}$ receptor neurons (Figure 9a).
While it is sensible that variation in CO${}_{2}$ levels should affect the sensitivity of the larva to optogenetic perturbation of the CO${}_{2}$ receptor neuron, it is somewhat surprising that CO${}_{2}$ variation altered the response to perturbation of an olfactory neuron that does not respond to CO${}_{2}$. This effect might be due to interactions between the Gr21a and Or42a neurons or pathways, for example lateral presynaptic inhibition (Olsen and Wilson, 2008). Or the variation in response to optogenetic activation of the sensory neurons we measured could be due to other effects than variance adaptation for example, a mathematical result of combining an oscillating signal with white noise prior to a rectifying nonlinearity.
Larvae did not modify their visual sensitivity in response to changes in fictive odor variance (Figure 7). We therefore expected that if the effect we observed were due to variance adaptation, it would be absent for white noise visual stimuli combined with natural odor backgrounds. Indeed, when we presented larvae with white noise visual stimuli in a fluctuating CO${}_{2}$ background, we found that the visual response was insensitive to the magnitude of the fluctuations (Figure 9b).
Discussion
In behavioral reverse correlation experiments, we analyzed the output of the entire sensory motor pathway using techniques developed to characterize sensory coding. Despite measuring a behavioral output rather than neural activity in early sensory neurons, we resolved features previously described in sensory systems, including adaptation to variance by inputrescaling, temporal dynamics of adaptation consistent with optimal variance estimators, and stimulusspecific variance adaptation.
Rates of adaptation suggest that sensory input filters are matched to motor output timescales
In LNP model fits to the reversecorrelation experiments, we found that the convolution kernels for visual and fictive olfactory stimuli have very similar shapes, suggesting that both visual and olfactory stimuli are low passed to the same temporal resolution (Gepner et al., 2015). This was somewhat puzzling. In a natural environment and close to surfaces, we would expect that light levels could change much faster than could odor concentrations, whose kinetics would be determined by diffusion and laminar flow. Shouldn’t the larva therefore process light information faster than odor information?
One resolution to this puzzle is that in behavioral reverse correlation we are not directly measuring the sensory response, but instead the sensory response convolved with the larva’s motor output and further limited by the temporal resolution of our video analysis. Therefore, the measured shape of the filter could simply reflect the latency in the motor output pathway or in our analysis software.
But there are reasons to believe that the filter kernels reflect the true temporal dynamics of the sensory systems. The decision to cease a run and end a turn is a navigational response to stimulus changes generated by larva’s movement through the environment. For this decision, the larva should seek sensory input that changes at the frequency of its own peristaltic movement, and this time scale should be the same for light and odor.
More generally, there is little value in making a decision faster than it can be implemented by the motor output pathway and a cost (less accuracy) to higher bandwidth measurements. These arguments would suggest that the timescales measured in reverse correlation should be similar to the actual timescales of the sensory neuron filters. Indeed, electrophysiological (Schulze et al., 2015; GorurShandilya et al., 2017) and optical (Si et al., 2017) recordings in olfactory sensory neurons reveal that these neurons filter odor inputs with similar dynamics to those observed in our behavioral reverse correlation experiments.
Variance adaptation provides an independent measure of the bandwidth of the sensory input process. The time it takes larvae to adapt following a switch from high to low variance is long compared to the latencies of the motor output pathway and our analysis software, and, if the larvae’s estimates of variance are optimal, determined by the input sampling rate. If light and odor were sampled at different rates, we would expect different rates of adaptation following a switch to low variance. In fact, we see the same rates of adaptation for both light and odor, and these rates are consistent with an optimal estimator sampling the stimulus at a similar frequency to the bandwidth of the convolution kernels. These suggest that sensory input is indeed filtered to match the frequency of the larva’s own motion.
If the bandwidth of the filter kernels is set by the speed of the larva’s own motion and not the temporal dynamics of the environment per se, this would also explain why the temporal structures of the kernels do not adapt to changes in variance (Figure 1d, Figure 3a).
Conclusion
In this study, we used behavioral reverse correlation to measure adaptation to environmental variance in a complete sensorymotor transformation. We found that larvae adapted to the variance of visual and fictive olfactory stimuli, that the rate of adaptation was consistent with an optimal estimate of the variance, and that larvae adapted to the variance in each sensory input individually. These results suggest a novel model of multisensory integration in the larva: multiplication of nonlinear representations of sensory input rather than addition of linear representations.
While variance adaptation has been well studied in early sensory neurons, the study of variance adaptation in complete sensorymotor transformations is in its early stages. This work contributes a study of variance adaptation in a navigational decisionmaking task as well as behavioral analysis of multisensory variance adaptation. Because the larva is transparent and amenable to genetic manipulation, the methods we developed here can be applied to optogenetic manipulation of interneurons as well, to understand whether variance adaptation to neural activity is a general feature of neural circuits or specific to early sensory inputs.
Changing the variance of background CO${}_{2}$ levels changes the larva’s response to activation of the CO${}_{2}$ receptor neuron but not its response to activation of the photoreceptors, suggesting that variance adaptation to a natural stimulus coupled with optogenetic activation of putative intermediate interneurons might be used to trace the flow of information through neural circuits.
Materials and methods
Fly strains
Request a detailed protocolThe following strains were used: Berlin wild type (gift of Justin Blau), w1118;; 20XUASCsChrimsonmVenus (Bloomington Stock 55136, gift of Vivek Jayaraman and Julie Simpson, Janelia Research Campus), w*;;Gr21aGal4 (Bloomington stock 23890), w*;;Or42aGal4 (Bloomington stock 9969), w*;;Or42bGal4 (Bloomington stock 9972), w*;;Or35aGal4 (Bloomington stock 9968), w*;;Or59aGal4 (Bloomington stock 9989)
Crosses
Request a detailed protocolAbout 50 virgin female UASCsChrimson flies were crossed with about 25 males of the selected Gal4 line. F1 progeny of both sexes were used for experiments.
Larva collection
Request a detailed protocolFlies were placed in 60 mm embryocollection cages (59–100 , Genessee Scientific) and allowed to lay eggs for 3 hr at 25C on enriched food media ('NutriFly German Food,' Genesee Scientific). For all experiments except the Berlin response to blue light (top rows of Figure 1d,e; Figure 2a,b; top row of Figure 3; top row of Figure 5; left column of Figure 6), the food was supplemented with 0.1 mM alltransretinal (ATR, Sigma Aldrich R2500), and cages were kept in the dark during egg laying. When eggs were not being collected for experiments, flies were kept on plain food at 20C.
Petri dishes containing eggs and larvae were kept at 25C (ATR +plates were wrapped in foil) for 48–60 hr. Second instar larvae were separated from the food using 30$\%$ sucrose solution and washed in deionized water. Larval stage was verified by size and spiracle morphology. Preparations for experiments were carried out in a dark room, under dim red (for phototaxis experiments) or blue (for CsChrimson experiments) illumination. Prior to beginning experiments, larvae were dark adapted on a clean 2.5$\%$ agar surface for a minimum of 10 min.
Behavioral experiments
Request a detailed protocolApproximately 40–50 larvae were placed on a darkened agar surface for behavioral experiments (as in Gepner et al., 2015). The agar surface resided in a 23 cm square dish (Corning BioAssay Dish $\mathrm{\#}$431111, Fisher Scientific, Pittsburgh, PA), containing 2.5$\%$ (wt/vol) bacteriological grade agar (Apex, cat $\mathrm{\#}$20–274, Genesee Scientific) and 0.75$\%$ (wt/vol) activated charcoal (DARCO G60, Fisher Scientific). The charcoal darkened the agar and improved contrast in our darkfield imaging setup. The plate was placed in a darkened enclosure and larvae were observed under strobed 850 nm infrared illumination (ODL300–850, Smart Vision Lights, Muskegon, MI) using a 4 MP global shutter CMOS camera (Basler acA204090umNIR, Graftek Imaging) operating at 20 fps and a 35 mm focal length lens (Fujinon CF35HA1, B$\&$H Photo, New York, NY), and equipped with an IRpass filter (Hoya R72, Edmund Optics). A microcontroller (Teensy ++2.0, PJRC, Sherwood, OR) coordinated the infrared strobe and control of the stimulus light source, so stimulus presentation and images could be aligned to within the width of the strobe window (2–5 ms). Videos were recorded using custom software written in LABVIEW and analyzed using the MAGAT analyzer software package (Gershow et al., 2012; https://github.com/samuellab/MAGATAnalyzerMatlabAnalysis). Further analysis was carried out using custom MATLAB scripts. Table 1 gives the number of experiments, animals, turns, and head sweeps analyzed for each experimental condition.
To determine the number of experiments to perform, we did a backoftheenvelope calculation, assuming that we would find the timevarying rate function by histogram division, and set 30 experiments as the target for the visual switching experiment of Figure 3. When we actually analyzed the data using more sophisticated methods, we found that fewer experiments would yield adequate signal to noise. We then aimed for at least 10 experiments for each condition, although we did more or (in one instance) fewer depending on the fecundity of the flies. For Figure 9, only a single constant rate function is extracted using all the available data, so fewer experiments could be performed in each condition.
All replicates are biological replicates, except for the jackknife predictions of heldout data in Figure 2 and Figure 8—figure supplement 1 and bootstrapping to produce the shaded error regions on the turntriggered averages.
Stimuli
Light intensity
Request a detailed protocolStimuli were provided by changing the intensity of blue (central wavelength $\lambda =447.5$ nm) and red ($\lambda =655$ nm) lights on a custombuilt LED board (Gepner et al., 2015) for visual and fictive olfactory signals respectively. The red light intensity varied from 0 to $900\frac{\mu W}{c{m}^{2}}$. For unisensory visual experiments, the blue light intensity varied from 0 to $50\frac{\mu W}{c{m}^{2}}$. For multisensory experiments (Figure 7), the blue light intensity varied from 0 to $3\frac{\mu W}{c{m}^{2}}$.
Light sequences
Request a detailed protocolLight levels were specified by values between 0 (off) and 255 (maximum intensity). These values changed according to a Brownian random walk (Gepner et al., 2015), whose derivatives on all time scales are independent identically distributed Gaussian variables.
The light level was set by pulse width modulation and updated every $1/120$ s. ${I}_{j}$ represents the intensity at time ${t}_{j}=j/120$. For all experiments except those of Figure 7 (bottom row), sequences of light levels were generated according to these rules:
where $N(0,\sigma )$ was a Gaussian random variable with mean $0$ and variance ${\sigma}^{2}$. The sequence was generated in floating point (i.e. noninteger values were allowed) and converted to integers for output.
We analyzed behavioral responses to light intensity derivatives, so the input variance was dictated by ${\sigma}^{2}$. For lowvariance conditions, ${\sigma}^{2}=1$ and for the high variance condition ${\sigma}^{2}=9$. In the experiments displayed in the top two rows of Figure 7, the nonswitching stimulus was generated with ${\sigma}^{2}=4$, although the same conclusions were reached when the nonswitching stimulus was generated with ${\sigma}^{2}=1$ or $9$. In Figure 9, ${\sigma}^{2}=9$ for all stimuli.
Sequences were not reused within an experimental group but might be reused between groups.
For multimodal experiments in Figure 7 (top and middle), independent sequences were used for each stimulus.
For the experiments with uncorrelated blue light intensities (Figure 4), a new light level was selected every 0.25 s. In the low variance condition, these were drawn from a normal distribution with mean 128 and standard deviation 17. In the high variance condition, the distribution had mean 128 and standard deviation 51. Out of range values (below 0 or above 255) were adjusted to 0 or 255 appropriately.
Correlated multisensory sequences
Request a detailed protocolFor multimodal experiments in Figure 7 (bottom), we generated two correlated Brownian sequences ${I}^{o}$ and ${I}^{l}$:
where ${s}^{o}$ and ${s}^{l}$ were normally distributed with mean 0 and individual variances ${\sigma}^{2}$.
The correlation coefficient of the odor and light inputs, $c$, is given by
In previous work, we found that larvae respond to a single combination of filtered odor and light inputs
We did not know a priori the exact value of $\theta $ we would find in a variance switching experiment, so we created a stimulus that would have a comparable switch in variance ${\sigma}_{high}^{2}=9{\sigma}_{low}^{2}$ for $\theta ={45}^{\circ}$.
The variance of $u=\frac{1}{\sqrt{2}}({s}^{o}+{s}^{l})$ is
so to change the variance between ${\sigma}_{u}^{2}=9$ and ${\sigma}_{u}^{2}=1$, we periodically changed the lightodor correlation coefficient between a positive and negative value: $c=\pm 0.8$, and set ${\sigma}^{2}=5$.
To generate this signal, we chose
where $c=0.8$ and ${x}_{1}$, ${x}_{2}$, and ${x}_{3}$ are three different and uncorrelated Gaussian random variables with mean $0$ and variance ${\sigma}^{2}=5$. Keeping in mind that the odor kernel has opposite sign to the light kernel, the high variance condition is when $c=0.8:\phantom{\rule{thinmathspace}{0ex}}{s}^{l}=\sqrt{1c}\ast {x}_{2}\sqrt{c}\ast {x}_{3}$ and the low variance condition is when $c=+0.8$
Natural carbon dioxide background
Request a detailed protocolReverse correlation experiments of Figure 9 were conducted in a laminar flow chamber with a glass lid through which the behavioral arena could be observed. Mass Flow Controllers (AAlborg) were controlled via Labview to generate a sinusoidally varying CO${}_{2}$ concentration via mixing of pure CO${}_{2}$ and filtered compressed air. Air flow was fixed at 4 L/min and CO${}_{2}$ flow varied sinusoidally, with a period of 20 s, either between 0.12 and 0.22 L/min or between 0 and 0.35 L/min, respectively for low and high variance experiments.
Data extraction
Request a detailed protocolVideos of behaving larvae were recorded using LabView software into a compressed image format (mmf) that discards the stationary background (Gershow et al., 2012; Kane et al., 2013). These videos were processed using computer vision software (written in C++ using the openCV library) to find the position and posture (head, tail, midpoint, and midline) of each larva and to assemble these into tracks, each following the movement of a single larva through time. These tracks were analyzed by Matlab software to identify behaviors, especially runs, turns, and head sweeps.
The sequence of light intensities presented to the larvae was stored with the video recordings and used for reversecorrelation analysis.
Data analysis
For all experiments, we discarded the first 60 s of data to let the larvae’s response to a novel environment dissipate. We use $\lambda (x)$ to indicate a static rate function that does not contain a variance adaptation term and $r(x),r(x,t)$ to indicate full rate functions that include variance adaptation.
Kernels and rate functions
Request a detailed protocolWe calculated kernels and rate functions separately for low and high variance by pooling together all the data from low variance and high variance contexts. In Figure 1 and Figure 2, we discarded the first 15 s from each cycle. In Figures 3 and 7, we discarded the first 10 s from each cycle.
Filters (Figures 1d, 3a and 4a): Filters, or kernels, were calculated as the ’turntriggered’ average signal for each set of experiments (Gepner et al., 2015). That is, we extracted the sequences of lightintensity derivatives, in bins of 0.1 s, surrounding every turn, and averaged them together. We scaled the low and high variance average signals to have the same maximum value.
For experiments with random intensities (Figure 4), we subtracted the mean of the stimulus from the turntriggered average prior to scaling. To remove artifacts associated with the 4 Hz update rate, we low passed the turntriggered averages using a Gaussian filter with $\sigma =0.25$s.
To calculate the shaded error regions, we adopted a bootstrapping approach (Zhou et al., 2018). For each set of experiments (e.g. the 17 blue light experiments of Figure 1):
We generated a resampled data set by randomly selecting experiments and larvae with replacement
we selected, with replacement, a random subset of equal length. For example, if there were four experiments, a valid subset might be (1,1,3,2)
For each experiment in this subset, we selected, with replacement, a random subset of individual larvae.
We calculated the turntriggered average of this resampled data set to create a single bootstrapped average.
We repeated the above steps 100 times
The shaded error region is the standard deviation at each time bin of the 100 bootstrapped averages.
Compared to simply calculating the standard error of the mean for each time bin, this approach respects the possibility of correlated sources of noise in the experiments.
Direct estimation of turn rates (Figures 1e, 3b, 7 and 9): The turn rates (in $mi{n}^{1}$), were calculated from the data as:
where $\mathrm{\Delta}t=\frac{1}{20}s$ was the sampling period. ${N}_{turn}({x}_{f})$ is the number of turns observed with the filtered signal ${x}_{f}$ within one of the $n=8$ bins containing ${x}_{f}.{N}_{run}({x}_{f})$ is the total number of data points where the filtered signal was in the histogram bin and larvae were in runs and thus capable of initiating turns.
Maximum likelihood estimation of static turn rates
Request a detailed protocolFor Figures 1e, 3b and 9, we separately fit high and low variance rate functions to exponentials of quadratics:
with ${\lambda}_{0}^{(h)},{\lambda}_{0}^{(l)}$, ${b}^{(h)},{b}^{(l)}$, and ${c}^{(h)},{c}^{(l)}$ as independent parameters.
The probability of observing at least one turn in an interval $\mathrm{\Delta}t$ given an underlying turn rate $r$ is $1{e}^{r\mathrm{\Delta}t}$. In the limit of short $\mathrm{\Delta}t$ this reduces to $r\mathrm{\Delta}t$. The probability of not observing a turn in the same interval is ${e}^{r\mathrm{\Delta}t}$.
For a model of the turn rate, the loglikelihood of the data given that model is therefore
where $x$ is the filtered signal, $r(x)$ is the turn rate predicted by the model, and $\mathrm{\Delta}t=\frac{1}{20}s$ is the sampling rate in our experiments. ${\sum}_{noturn}$ is a sum over all points when larvae were in runs and thus capable of initiating turns.
We used the MATLAB function fminunc to find the parameters that maximize this log likelihood.
Figure 7b,c were fit in the same fashion but for exponentials of linear functions ($c\equiv 0$).
Comparison of rescaling models (Figure 2)
Request a detailed protocolFor the experiments in Figure 1d–e, we model the rate function as: $\lambda (x)={\lambda}_{0}\mathrm{exp}(bx+c{x}^{2})$, and ask if adaptation is better characterized by:
an input rescaling:
$r(t,x)=\lambda (\alpha (t)\cdot x)$an output rescaling:
$r(t,x)=\alpha (t)\cdot \lambda (x)$or a ’recentered’ output rescaling (where the basal rate is adjusted after rescaling):
$r(t,x)=\alpha (t)\cdot (\lambda (x){\lambda}_{0})+{\lambda}_{0}$
For each model, we fit low and highvariance rate functions simultaneously (excluding the first 15 s of each cycle) by minimizing the negativeloglikelihood. We set ${\alpha}_{high}=1$ and thus have four fit parameters for each model (${\lambda}_{0}$, $b$, $c$, and ${\alpha}_{low}$). We plot the resulting low and highvariance rate functions for each model (Figure 2a,d), and also fit the data to a null model with no adaptation (only three fit parameters: ${\lambda}_{0}$, $b$, $c$), for which the low and highvariance rate functions are identical. We find that the input rescaling is the best model of the larvae’s turnrate adaptation.
We then fit a subset (14/17 experiments) of the data to each model and find how well each one predicts the remainder of the data (3/17 experiments). By permuting the fitted and tested portions of the data, we find jackknife estimates of the loglikelihood of the testdata given the fit rate function (mean and standard error shown in Figure 2b,e). We then compare the input and recentered output models directly, showing the histogram of loglikelihoods for all different permutations of fitted and tested portions (Figure 2c,f).
In Figure 2b,c 20/680 and in Figure 2d,f 97/680 jackknives resulted in the recentered output model producing a negative rate for some of the test data. These were excluded from analysis.
Assuming the entirety of a test data set is generated by the same process, we would expect that the loglikelihood of that data set given any model would be proportional to the length of the data set. To normalize out the effects of fluctuations in the number of animalminutes in the heldout data sets, we therefore normalized the loglikelihood
where $L{L}_{j}$ is the likelihood of the test data in the ${j}^{th}$ jackknife, ${T}_{j}$ is the total observation time in the ${j}^{th}$ test data set, and $\u27e8T\u27e9=\frac{1}{N}{\sum}_{j=1}^{N}{T}_{j}$.
Bayes information criterion
Request a detailed protocolThe Bayes Information Criterion (BIC) is defined as
BIC is closely related to the Aikake Information Criterion (AIC) but more strongly favors models with fewer parameters. $\mathrm{\Delta}BIC<10$ strongly favors the more negative model (roughly equivalent to $p<0.01$).
We chose ${n}_{data}$, the sample size to be the total number of larvaseconds. If we had chosen ${n}_{data}$ to be the total number of larvae, $\mathrm{\Delta}BIC$ would shift to favor models with more parameters by about seven per extra parameter. If we had chosen ${n}_{data}$ to be the total number images of individual larva analyzed, then $\mathrm{\Delta}BIC$ would shift to favor models with fewer parameters by 3 ($\mathrm{log}20$) per extra parameter. Neither of these changes would have affected which model fits were preferred or the significance of the differences between models.
Calculation of $\alpha (t)$ (Figures 3c, 5a and 7a)
Request a detailed protocolFor unisensory experiments (Figures 3c and 5a), we characterized adaptation of the turn rate as an input rescaling:
where $x$ is the (convolved) stimulus value, and $\lambda $ is a fixed nonlinear function:
Our goal is to find the values of ${\lambda}_{0}$ , $b$, $c$, and $\alpha (t)$ that maximize the probability of the data and a prior probability that constrains the smoothness of $\alpha $. We grouped all experiments together and found a single $\alpha (t)$ for each time point between 60 s and 20 min; we did not use any prior knowledge of variance switching times in the extraction of bestfit parameters. We use an iterative process to find the best fit model parameters.
First, we assume that $\alpha \equiv 1$, ignoring adaptation to variance, and calculate the best fit parameters of a static rate function, $\lambda (x)={\lambda}_{0}\mathrm{exp}(bx+c{x}^{2})$, using maximum likelihood estimation described above.
Next, we calculate the timevarying scaling parameter $\alpha (t)$. At each time point ${t}_{i}$, we use Bayes’ rule to calculate the probability of a given value of $\alpha $
In the LNP formulation, we assume that turns are generated by a memoryless Poisson process, so we simplify $P(dat{a}_{i}dat{a}_{j<i},{\alpha}_{i})=P(dat{a}_{i}{\alpha}_{i})$. We assume that the prior probability ${\alpha}_{i}$ of alpha depends only on ${\alpha}_{i1}$, so $P({\alpha}_{i}{\alpha}_{j<i})=P({\alpha}_{i}{\alpha}_{i1})$. We can then write
where $P({\alpha}_{i1}dat{a}_{j<i})$ is the distribution of $\alpha $ values at the previous time step, and $P(dat{a}_{i}{\alpha}_{i})$ is the likelihood of seeing the observed turn times, $dat{a}_{i}$, given that they are generated by a Poisson process with a mean rate ${r}_{i}$:
where ${r}_{i}(x)=\lambda ({\alpha}_{i}x)$, using the fixed static rate function calculated previously. For $P({\alpha}_{i}{\alpha}_{i1})$, we chose a Gaussian prior
$\mathrm{\Delta}t$ is the timestep of the fitting routine and $\tau $ controls the smoothness of our estimate of $\alpha .\mathrm{\Delta}t=0.1s$ in Figure 3c and $\mathrm{\Delta}t=1s$ in Figure 5a, and with $\tau =5s$ for both.
Using this formulation, we calculate the most likely value of ${\alpha}_{i}$ at each time point ${t}_{i}$ ($\alpha (t)$) and the uncertainty in this estimate ($\sigma (t)$). We use the new values of $\alpha (t)$ to find new best fit parameters of the static rate function and iterate the process until the loglikehood converges.
Finally, to describe how $\alpha $ varies in response to changes in variance, we calculated an appropriately weighted average over cycle time. Call the time of the start of each cycle (e.g. switch to low variance) ${t}_{k}^{switch}$, then
To verify that the asymmetry in the timescales behavior is not an artifact of our analysis, we generate artificial turndecisions from a ratefunction that switches instantaneously when the variance switches. We then estimate the corresponding scaling factors for these new data and find that our estimator tracks the adaptation equally quickly for upward and downward switches (black curves in Figure 3c).
For multisensory experiments (Figure 7a), the rate is modeled as
Two dimensional, ($\alpha ,\beta $) distributions are calculated at each time step:
with
The prior is now a twodimensional Gaussian:
where
and $\mathrm{\Sigma}$ is the determinant of $\mathrm{\Sigma}$.
$\mathrm{\Delta}t=0.1$s ${\tau}_{\alpha}={\tau}_{\beta}=5$s, and ${\tau}_{\alpha \beta}=0$ so that no correlation between changes in $\alpha $ and $\beta $ was introduced in our prior expectation.
To find $\alpha (t)$ and $\beta (t)$, we marginalize the (${\alpha}_{i},{\beta}_{i}$) distribution at each time step and calculated the most likely value and uncertainty of $\alpha $ and $\beta $ separately.
For the correlated stimuli (Figure 7a, bottom row), we first looked for an angle $\theta $ such that the rate function could be characterized by a linear combination of filtered odor and light inputs, $u=(\mathrm{cos}(\theta ){x}_{o}+\mathrm{sin}(\theta ){x}_{l})$ (Gepner et al., 2015). We thus looked for a model of the form:
where ${\alpha}_{u}$ described the rescaling from high to low variance. We fit low and highvariance rate functions simultaneously (excluding the first 10 s of each cycle) by minimizing the negativeloglikelihood. We set ${\alpha}_{u,high}=1$ and thus have four fit parameters (${\lambda}_{0}$, $a$, $\theta $, and ${\alpha}_{u,low}$). In this way we found $\theta \approx {38}^{\circ}$.
Using this value of $\theta $, we then fit the data to the twocoordinates model:
with $u$ defined above, $v$ the coordinate orthogonal to $u:v=(\mathrm{sin}(\theta ){x}_{o}+\mathrm{cos}(\theta ){x}_{l})$. There, we found $b\approx 0$.
We could then use the onecoordinate model (Equation 51) and the iterative procedure described earlier in this section (Equation 40) to calculate ${\alpha}_{u}(t)$ using ${\tau}_{u}=5s$ for the correlation time of the prior distribution (Figure 7a, bottom row).
Bayesianoptimal estimates of the stimulus variance (Figure 6)
Request a detailed protocolWe calculate Bayesianoptimal estimates of the stimulus variance (DeWeese and Zador, 1998):
${s}_{i}$ = $I({t}_{i})I({t}_{i1})$ is the total change in light level over the sampling interval and forms the input to the estimator. ${\sigma}_{i}$ is the estimate of the standard deviation of the light level changes and is the output of the model. We have replaced $P({s}_{i}{s}_{j<i})$ with $P({s}_{i})$ because stimulus samples are uncorrelated.
The sampling time, $\mathrm{\Delta}t$, determines the rate at which the estimator picks out samples from the stimulus ensemble to make estimates of the variance. The estimator requires a prior model of how environmental variance changes with time. We chose a diffusive prior, parameterized by a correlation time $\tau $:
Decreasing $\tau $ increases the speed at which the estimator responds to changes in variance at the cost of decreasing stability during periods of constant variance. In the absence of measurement noise, decreasing $\mathrm{\Delta}t$ strictly improves the performance of the estimator, increasing response speed and stability.
To determine the values of $\mathrm{\Delta}t$ and $\tau $ that were most consistent with the larva’s behavior, we estimated the stimulus variance using a series of estimators with different choices of $\mathrm{\Delta}t$ and $\tau $. For each such estimate of the signal variance:
we calculated a mapping from variance to rescaling parameter using the relation:
with ${\sigma}_{0}$ taken from the switching experiments of Figure 3 and ${\alpha}_{0}$ chosen to enforce $\u27e8\alpha (t)\u27e9=1$.
For each set of $\mathrm{\Delta}t$, $\tau $, we now had a predicted rescaling for each time point in the experiments: ${\alpha}_{opt}(t)$. To compare these predictions to the data, we found the loglikelihood of the observed sequence of data given the rate $r(t,x)=\lambda ({\alpha}_{opt}(t)\cdot x(t))$, with the parameters of the static rate function $\lambda (x)={\lambda}_{0}\mathrm{exp}(bx+c{x}^{2})$ found separately for each set of $\mathrm{\Delta}t$, $\tau $ by maximumlikelihoodestimation.
New methods developed
Request a detailed protocolBehavioral reverse correlation using visual and optogenetic stimulation follows previous work (Gepner et al., 2015; HernandezNunez et al., 2015). Behavioral analysis software was developed in Gershow et al. (2012). New to this work are: presentation of stimuli with changing variance; analysis of adaptation to variance, including estimation of the timevarying rescaling parameter, estimation of the rescaling parameter vs. variance, and comparison of the adaptation with predictions of a Bayes estimator; combination of optogenetic and visual manipulation with fluctuating CO_{2} background; multisensory variance adaptation including the use of correlated stimuli of constant variance to produce a multisensory signal with changing variance.
References
 1

2
Some informational aspects of visual perceptionPsychological Review 61:183–193.https://doi.org/10.1037/h0054663
 3

4
Possible Principles Underlying the Transformation of Sensory MessagesCambridge, MA: MIT Press.

5
Physical limits to sensation and perceptionAnnual Review of Biophysics and Biophysical Chemistry 16:455–478.https://doi.org/10.1146/annurev.bb.16.060187.002323
 6
 7

8
A simple white noise analysis of neuronal light responsesNetwork: Computation in Neural Systems 12:199–213.https://doi.org/10.1080/713663221

9
Fast intensity adaptation enhances the encoding of sound in DrosophilaNature Communications, 9, 10.1038/s41467017024539.

10
Visual adaptation: neural, psychological and computational aspectsVision Research 47:3125–3131.https://doi.org/10.1016/j.visres.2007.08.023
 11

12
Properties of shape tuning of macaque inferior temporal neurons examined using rapid serial visual presentationJournal of Neurophysiology 97:2900–2916.https://doi.org/10.1152/jn.00741.2006

13
Neural population coding of sound level adapts to stimulus statisticsNature Neuroscience 8:1684–1689.https://doi.org/10.1038/nn1541

14
Asymmetric dynamics in optimal variance adaptationNeural Computation 10:1179–1202.https://doi.org/10.1162/089976698300017403
 15
 16

17
Controlling airborne cues to study small animal navigationNature Methods 9:290–296.https://doi.org/10.1038/nmeth.1853
 18

19
Active sampling and decision making in Drosophila chemotaxisNature Communications 2:441.https://doi.org/10.1038/ncomms1455

20
Active sensation during orientation behavior in the Drosophila larva: more sense than luckCurrent Opinion in Neurobiology 22:208–215.https://doi.org/10.1016/j.conb.2011.11.008
 21
 22
 23

24
Temporal contrast adaptation in the input and output signals of salamander retinal ganglion cellsThe Journal of Neuroscience 21:287–299.https://doi.org/10.1523/JNEUROSCI.210100287.2001

25
Slow Na+ inactivation and variance adaptation in salamander retinal ganglion cellsThe Journal of Neuroscience : The Official Journal of the Society for Neuroscience 23:1506–1516.https://doi.org/10.1523/JNEUROSCI.230401506.2003

26
Shortterm adaptation of auditory receptive fields to dynamic stimuliJournal of Neurophysiology 91:604–612.https://doi.org/10.1152/jn.00484.2003
 27

28
A simple coding procedure enhances a neuron's information capacityZeitschrift Für Naturforschung C 36:910–912.https://doi.org/10.1515/znc198191040

29
Efficient sensory cortical coding optimizes pursuit eye movementsNature Communications 7:12759.https://doi.org/10.1038/ncomms12759

30
Bilateral olfactory sensory input enhances chemotaxis behaviorNature Neuroscience 11:187–199.https://doi.org/10.1038/nn2031

31
Navigational decision making in Drosophila thermotaxisJournal of Neuroscience 30:4261–4272.https://doi.org/10.1523/JNEUROSCI.409009.2010
 32

33
Principles of Neural Coding357–378, Adaptation and sensory coding, Principles of Neural Coding, United States, CRC press.

34
Crossover inhibition in the retina: circuitry that compensates for nonlinear rectifying synaptic transmissionJournal of Computational Neuroscience 27:569–590.https://doi.org/10.1007/s1082700901706
 35
 36
 37

38
Energy limitation as a selective pressure on the evolution of sensory systemsJournal of Experimental Biology 211:1792–1804.https://doi.org/10.1242/jeb.017574
 39
 40

41
Correlation detection as a general mechanism for multisensory integrationNature Communications 7:11543.https://doi.org/10.1038/ncomms11543
 42
 43
 44
 45
 46
 47
 48

49
Predictive coding: a fresh view of inhibition in the retinaProceedings of the Royal Society B: Biological Sciences 216:427–459.https://doi.org/10.1098/rspb.1982.0085

50
Information processing in living systemsAnnual Review of Condensed Matter Physics 7:89–117.https://doi.org/10.1146/annurevconmatphys031214014803

51
Sensory adaptationCurrent Opinion in Neurobiology 17:423–429.https://doi.org/10.1016/j.conb.2007.07.001
 52

53
Dynamic range adaptation to sound level statistics in the auditory nerveJournal of Neuroscience 29:13797–13808.https://doi.org/10.1523/JNEUROSCI.561008.2009
 54
 55
Decision letter

Ronald L CalabreseSenior and Reviewing Editor; Emory University, United States
In the interests of transparency, eLife includes the editorial decision letter and accompanying author responses. A lightly edited version of the letter sent to the authors after peer review is shown, indicating the most substantive concerns; minor comments are not usually included.
Thank you for submitting your article "Variance Adaptation in Navigational Decision Making" for consideration by eLife. Your article has been reviewed by 2 peer reviewers, and the evaluation has been overseen by a Reviewing Editor and Eve Marder as the Senior Editor. The reviewers have opted to remain anonymous.
The reviewers have discussed the reviews with one another and the Reviewing Editor has drafted this decision to help you prepare a revised submission.
Summary:
Gepner et al. present data showing that larval navigational behavior adapts to the variance of various stimuli. They use optical stimuli to probe visual pathways naturally and olfactory pathways via channelrhodopsin; both pathways show contrast adaptation, but not crossadaptation between the two pathways. (A very elegant experiment with correlated vs. uncorrelated noise between the two channels showed some mild interactions.) They measure the timescale of the adaptation and show that the different kinetics for adapting to contrast increments vs. decrements are consistent with an optimal detection theory. The authors also used a more natural stimulus paradigm to show that this sort of adaptation is not purely a function of their artificial stimuli.
Throughout, the authors fit their data to a variety of models. They showed that their data were best explained by input rescaling, that their data were consistent with a model in which a Bayes' optimal estimate of variance occurs on timescales of ~1s, and that signals are combined with a potentially multiplicative interaction.
The experiments are well done and the analysis is convincing.
Essential revisions:
Two major concerns arose in consultation:
1) The protocol for contrast adaptation looks different from the classical ones in the field, and reviewer #1, point 1 requests clarification and a new experiment that should be doable in a short time.
2) We would like to see a quantification of how filter shape depends on stimulus variance, and reviewer #2, point 1 provides details of the analyses needed.
Reviewer #1:
1) If I understand it correctly, the change in stimulus variance is related to a change in correlation time of the light intensity, rather than in its variance about a mean, in order to get the derivatives to scale as intended. Does this cause any problems? What if you just do it the naïve way, by scaling the entire light intensity trace contrast, so that the derivatives and deviations both scale up? Is the answer the same? I think this is potentially important because contrast adaptation is crucially dependent on the timescale on which one computes contrast, and by changing the timescale of the stimulus correlations, one might change regimes. (As an extreme case, if fluctuations were made incredibly slow, one would presumably begin to measure adaptation to the mean, rather than to the contrast.)
2) The authors frame the adaptation as rescaling the nonlinearity, but what if adaptation rescales the linear filter amplitude. These are mathematically equivalent, and if you do the rescaling of the linear filter amplitude, then the Figure 8B model seems like it could be reconciled with the independent adaptation of the two channels. Is this a problem for excluding Figure 8B for this reason?
3) The multiplicative model is different from additive in the case of polynomial terms of order >1 in the exponential. However, if you expand everything in Taylor series, is the multiplication just allowing a few more higher order interactions between the terms? The relative coefficients of those higher order terms is restricted by this multiplication step. But what happens if you fit models that just allow uptocubic interactions between the x_{O} and x_{L} filtered terms before applying the exponential? (This would be a nonlinear interaction before applying the second nonlinearity.) Can you do better than multiplication? If so, would that imply that there's some kind of nonlinear summation of the terms with potentially small nonlinearities that is in fact the best fit? Or is multiplicative really a better model because it requires fewer fitting terms? A BIC evaluation seems like it could resolve this.
Reviewer #2:
1) A major point of confusion for me was that the authors claim that the linear filters are conserved across different values of stimulus variance. Unless I missed it, there is no quantification of this (except for the claim of 'having established that the kernel shape did not depend on the input variance', subsection “Larvae Adapt Their TurnRate to the Variance in Visual and Olfactory Sensory Inputs”), and the figures shown (Figure 1D, Figure 3A) suggest that there actually is a consistent effect of increasing variance on filter shape – namely the relative height of the left shoulder of the filter. While this is not a qualitative change in filter shape, it does change to what extent larvae take into account information about the stimulus further away from the turn. Hence, I would like to see a quantification of how filter shape depends on stimulus variance (e.g., by plotting f_hi vs f_low – if filter shape is preserved across variances, all points should be close to the diagonal – it looks as if filter values close to the peak will lie on the diagonal, but filter values around 6 to 4 seconds prior to the turn should lie off diagonal). Using the actual filter shape for each variance, rather than the filter derived from pooled data, might affect (in both directions) the reported effects of variance on the shape of the nonlinearity.
2) There were also some issues with the writing. For example, the abstract is lacking a description of the niche this work aims to fill, and a statement on the general relevance of the findings – as another example, the authors don't example why it is interesting that multisensory integration involves a multiplicative step and what the implication is for behavior. I also often had to go back to their previous paper (Gepner et al., 2015) and dig into the details of their model or look up details on the coordinate transform (see comment below). The rationale for each plot is not made sufficiently clear to the reader. It would help if the authors show more raw data to provide an intuition for the derived plots – e.g., what happens to animal turning following the switch in variance from low to high or high to low (such as in Figure 3)?
https://doi.org/10.7554/eLife.37945.019Author response
[…] Essential revisions:
Two major concerns arose in consultation:
1) The protocol for contrast adaptation looks different from the classical ones in the field, and reviewer #1, point 1 requests clarification and a new experiment that should be doable in a short time.
2) We would like to see a quantification of how filter shape depends on stimulus variance, and reviewer #2, point 1 provides details of the analyses needed.
We thank the reviewers for their positive assessment of our work and their valuable suggestions. Our pointbypoint responses follow.
Reviewer #1:
1) If I understand it correctly, the change in stimulus variance is related to a change in correlation time of the light intensity, rather than in its variance about a mean, in order to get the derivatives to scale as intended. Does this cause any problems? What if you just do it the naïve way, by scaling the entire light intensity trace contrast, so that the derivatives and deviations both scale up? Is the answer the same? I think this is potentially important because contrast adaptation is crucially dependent on the timescale on which one computes contrast, and by changing the timescale of the stimulus correlations, one might change regimes. (As an extreme case, if fluctuations were made incredibly slow, one would presumably begin to measure adaptation to the mean, rather than to the contrast.)
In all the experiments presented in the initial submission of our paper, the light intensity obeys a random walk. In a random walk without boundary conditions, the correlation time is infinite, because the average (and most probable) future location is always the current location.
Our led output levels are bounded below by 0 and above by a maximum output level, so the intensity obeys the statistics of a random walk with reflecting boundary conditions. In this case, there is a finite correlation time, which depends on the diffusion constant and the boundary conditions. In the high variance condition, the correlation time is ~12 seconds and in the low variance condition the correlation time is approximately 104 seconds (Figure 4—figure supplement 1D).
We observe adaptation to high variance almost immediately after the switch, while adaptation to low variance occurs over about 10 seconds. Both of these are much faster than the correlation time of the stimulus in their respective conditions.
We initially chose to use a stimulus with uncorrelated derivatives rather than uncorrelated values because previous work has shown that the derivative of the stimulus is more salient to larva than its value, and also to align with our previous work. With uncorrelated derivatives, the light intensities themselves are the same in high and low variance conditions – both span the entire range from 0 to max intensity. In an uncorrelated value stimulus, the high variance condition necessarily includes higher light intensities than are sampled in the low variance condition (compare Figure 4—figure supplement 1C and J). As a result, we worried that adaptation to high variance might be interpreted as due to effects associated with high light intensities, e.g. saturation of receptors or ion channels.
The reviewer’s questions about the structure of our stimulus are well thought out and likely quite common, and we welcome the opportunity to address them in depth in this response letter. We also now include a short discussion and a new Figure 4—figure supplement 1, which shows the stimulus and help visualize what happens when the variance changes.
As the reviewer requested, we also carried out an experiment in which light levels were randomly selected from a normal distribution with constant mean and changing variance. We analyzed these in the LNP framework with the kernel computed from the “turntriggeredaverage” stimulus value, and we recapitulated the results from the uncorrelated derivative experiments: larvae adapt to variance via a rescaling of the nonlinear function, and they adapt more quickly to increases of variance than decreases. These results are shown in new Figure 4.
2) The authors frame the adaptation as rescaling the nonlinearity, but what if adaptation rescales the linear filter amplitude. These are mathematically equivalent, and if you do the rescaling of the linear filter amplitude, then the Figure 8B model seems like it could be reconciled with the independent adaptation of the two channels. Is this a problem for excluding Figure 8B for this reason?
We agree that rescaling the kernel and rescaling the input to the nonlinear function are completely equivalent. We also agree that formally, the Figure 8B model works if you are able to rescale the kernel while preserving the linearity of its output. While this is mathematically simple, it is difficult to understand how this might be achieved in a biological system.
Measuring the variance of a signal requires a nonlinear computation, and both spiking and synaptic transmission rectify, so it is natural that biophysical models of adaptation take advantage of these nonlinearities. For instance, Kim and Rieke, (2003) show how an apparent linear rescaling of the filter results from biophysical nonlinearities, including spiking. The LNK model (Ozuysal and Baccus, 2012) accomplishes variance adaptation using a kinetics block following a rectifying nonlinearity. In both of these cases, the LN cascade takes place within a single neuron. Similarly, the Somponlinsky model (Borst et al., 2005) requires a saturating nonlinearity. We are not aware of any mechanistic model of variance adaptation that does not require a nonlinear transformation of the input.
Our finding (Gepner, Mihovilovic and Skanata, 2015) that larvae linearly combine odor and light signals (Figure 8B, this work) requires that these signals be transmitted linearly from the sensory peripheries to some part of the brain responsible for multisensory combination. Because it is difficult to send both positive and negative signals through the same synaptic pathway, this was already somewhat puzzling. But one might, for instance, imagine that for both light and odor, 0 change was represented by a significant amount of excitation which was then balanced by tonic inhibition at the point of combination.
Now we have added the finding that adaptation to variance is upstream of multisensory combination. While one can imagine more elaborate arrangements that would allow the framework of Figure 8B to accommodate variance adaptations, we do not know how variance adaptation might be achieved while preserving linearity. And because variance measurement requires a nonlinear computation, the most parsimonious explanation is that feedback from the rectifying nonlinearity already present in our model should be used to achieve adaptation.
In summary, there is nothing mathematically wrong with this extension of the Figure 8b model to accommodate variance adaptation. But we believe that rescaling the light and odor kernels in response to changes in variance, linearly combining the odor and light filter outputs, and then using that linear combination as the input to a rectifying nonlinearity is biologically implausible. Hence, we sought an alternate model that was more biologically plausible while remaining at least as accurate mathematically.
We have rewritten the discussion of the combination models (which has been moved to the Results section, per reviewer 2’s suggestion) to clarify these points.
3) The multiplicative model is different from additive in the case of polynomial terms of order >1 in the exponential. However, if you expand everything in Taylor series, is the multiplication just allowing a few more higher order interactions between the terms? The relative coefficients of those higher order terms is restricted by this multiplication step. But what happens if you fit models that just allow uptocubic interactions between the x_{O} and x_{L} filtered terms before applying the exponential? (This would be a nonlinear interaction before applying the second nonlinearity.) Can you do better than multiplication? If so, would that imply that there's some kind of nonlinear summation of the terms with potentially small nonlinearities that is in fact the best fit? Or is multiplicative really a better model because it requires fewer fitting terms? A BIC evaluation seems like it could resolve this.
We believe (see discussion above) that the multiplicative model (Figure 8C), is more biologically plausible than the linear combination model (Figure 8B) in the face of our finding that larvae adapt to the variance of each sense individually (Figure 7). For consistency, we felt it was also important to show that the multiplicative model was at least as explanatory of our previous experiments as the linear combination model.
When we reexamined the data from Gepner, Mihovilovic and Skanata et al. using the multiplicative combination model, we found that it increased the likelihood of that data given the bestfit model by a statistically significant amount compared to the best fit linear combination model. However, if one looks at the actual predictions made by these two models (Figure 8—figure supplement 1B, Figure 8—figure supplement 2), there are only minute differences. It would be possible, especially with more data, to compare these two models at higher polynomial orders, but presumably the bestfit rate functions would remain quite similar. Our goal was to show that the multiplicative model could explain our past data; we believe the current analysis satisfies this goal and hence have not extended the analysis to higher orders.
Reviewer #2:
1) A major point of confusion for me was that the authors claim that the linear filters are conserved across different values of stimulus variance. […] Hence, I would like to see a quantification of how filter shape depends on stimulus variance (e.g., by plotting f_hi vs f_low – if filter shape is preserved across variances, all points should be close to the diagonal – it looks as if filter values close to the peak will lie on the diagonal, but filter values around 6 to 4 seconds prior to the turn should lie off diagonal). Using the actual filter shape for each variance, rather than the filter derived from pooled data, might affect (in both directions) the reported effects of variance on the shape of the nonlinearity.
We have added bootstrapped error bars to the recovered turn triggered averages. We have also reanalyzed the data of Figure 1 using different filter shapes for the low and high variance conditions (Figure 1—figure supplement 2). The derived rate functions are identical within the precision of our measurement. Specifically, using a variancespecific kernel would not change the ratefunction presented in Figure 1E.
We estimate the timevarying rescaling parameter(s) (Figure 3, Figure 4, Figure 5 and Figure 7) with maximum likelihood estimation on the static rate function parameters and temporal sequence of rescaling parameter(s). To perform this estimate, we use the precomputed convolved stimulus as the input to the nonlinear function. It would be computationally challenging to extend our approach to include a timevarying filter on the raw stimulus input. We would not want to use precomputed low and high variance kernels separately on the low and high variance portions of the stimulus, because an important feature of our analysis is that rescaling emerges from fitting the observed turn rate to the input stimulus without any precomputation of the variance.
Figure—figure supplement 2 now shows an analysis of Figure 1 data using separate high and low variance kernels. We have rewritten subsection “Larvae Adapt Their TurnRate to the Variance in Visual and Olfactory Sensory Inputs” to remove the claim that the linear filter is the same at high and low variance and instead to emphasize that the most dramatic effect is the rescaling of the nonlinear function.
2) There were also some issues with the writing. For example, the abstract is lacking a description of the niche this work aims to fill, and a statement on the general relevance of the findings – as another example, the authors don't example why it is interesting that multisensory integration involves a multiplicative step and what the implication is for behavior. I also often had to go back to their previous paper (Gepner et al., 2015) and dig into the details of their model or look up details on the coordinate transform (see comment below). The rationale for each plot is not made sufficiently clear to the reader. It would help if the authors show more raw data to provide an intuition for the derived plots – e.g., what happens to animal turning following the switch in variance from low to high or high to low (such as in Figure 3)?
We have edited the abstract and introduction to improve readability. We added Figure 1—figure supplement 1 to sketch how we extract high and low variance turn rates from the applied stimulus and observed behavioral raster.
https://doi.org/10.7554/eLife.37945.020Article and author information
Author details
Funding
National Institutes of Health (1DP2EB022359)
 Jason Wolk
 Marc Gershow
National Science Foundation (1455015)
 Ruben Gepner
 Jason Wolk
 Marc Gershow
Alfred P. Sloan Foundation
 Marc Gershow
National Institutes of Health (R90DA043849)
 Sophie Dvali
The funders had no role in study design, data collection and interpretation, or the decision to submit the work for publication.
Acknowledgements
We thank Ilya Nemenman for discussions at the Aspen Center for Physics and KITP summer programs on behavior. This work was supported by NIH grant 1DP2EB022359, NSF grant 1455015, and a Sloan Research Fellowship.
Senior and Reviewing Editor
 Ronald L Calabrese, Emory University, United States
Publication history
 Received: April 28, 2018
 Accepted: October 29, 2018
 Version of Record published: November 27, 2018 (version 1)
Copyright
© 2018, Gepner et al.
This article is distributed under the terms of the Creative Commons Attribution License, which permits unrestricted use and redistribution provided that the original author and source are credited.
Metrics

 1,061
 Page views

 133
 Downloads

 3
 Citations
Article citation count generated by polling the highest count across the following sources: Crossref, PubMed Central, Scopus.