Logarithmic coding leads to adaptive stabilization in the
presence of sensorimotor delays

Leonardo Demarchi, Georges Debrégeas, Antoine Hubert, Thomas Panier, Ghislaine Morvan-Dubois, Volker Bormuth, Georges Debrégeas

► To cite this version:

Leonardo Demarchi, Georges Debrégeas, Antoine Hubert, Thomas Panier, Ghislaine Morvan-Dubois, et al.. Logarithmic coding leads to adaptive stabilization in the presence of sensorimotor delays. Proceedings of the National Academy of Sciences of the United States of America, 2025, 122 (43), 10.1073/pnas.2510385122/-/DCSupplemental.. hal-05404954

HAL Id: hal-05404954

https://hal.science/hal-05404954v1

Submitted on 8 Dec 2025

**HAL** is a multi-disciplinary open access
archive for the deposit and dissemination of sci-
entific research documents, whether they are pub-
lished or not. The documents may come from
teaching and research institutions in France or
abroad, or from public or private research centers.

L'archive ouverte pluridisciplinaire HAL, est
destinée au dépôt et à la diffusion de documents
scientifiques de niveau recherche, publiés ou non,
émanant des établissements d'enseignement et de
recherche français ou étrangers, des laboratoires
publics ou privés.

<figure><img src="image_1.png" /></figure>

Distributed under a Creative Commons Attribution 4.0 International License
<figure><img src="image_2.png" /></figure>

# Logarithmic coding leads to adaptive stabilization in the presence of sensorimotor delays

Leonardo Demarchi<sup>a,b</sup> <sup>1</sup>, Monica Coraggioso<sup>a,b</sup>, Antoine Hubert<sup>a,b</sup>, Thomas Panier<sup>a,b</sup> <sup>1</sup>, Ghislaine Morvan-Dubois<sup>a,b</sup> <sup>1</sup>, Volker Bormuth<sup>a,b</sup>, and Georges Debrégeas<sup>a,b,1</sup> <sup>1</sup>

Affiliations are included on p. 8.

Edited by Emery Brown, Massachusetts General Hospital, Boston, MA; received April 28, 2025; accepted September 24, 2025

Animals respond to sensory stimuli with motor actions, which in turn generate new sensory inputs. This sensorimotor loop is constrained by time delays that impose a trade-off between responsiveness and stability. Additionally, as the relationship between a motor command and the corresponding sensory feedback is context-dependent, the response must be adapted in real time. It is generally believed that this adaptation process relies on an internal model that is continuously updated through prediction error minimization. Here, we experimentally reveal an alternative strategy based on a simpler feedback mechanism that does not require any internal model. We developed a virtual reality system for the miniature transparent fish *Danionella cerebrum* that enables in vivo brain-wide imaging during fictive navigation. By systematically manipulating the feedback parameters, we dissected the motor control process that allows the animal to stabilize its position using optic flow. The sensorimotor loop can be fully described by a single delay differential equation, whose solutions quantitatively capture the observed behavior across all experimental conditions. Both behavioral and neural data indicate that the observed adaptive response arises from logarithmic nonlinearities at the sensory (Weber–Fechner law) and motor (Henneman’s size principle) ends. These fundamental properties of the nervous system, conserved across species and sensory modalities, have traditionally been interpreted in terms of efficient coding. Our findings unveil a distinct functional role for such nonlinear transformations: ensuring stability in sensorimotor control despite inherent delays and sensory uncertainty.

sensorimotor control | *Danionella cerebrum* | optical flow stabilization | whole-brain imaging | delay-induced oscillations

Animals continuously interact with their environment through sensorimotor loops. These dynamic processes are inherently constrained by finite time delays and noise in the sensory and motor systems which can lead to instability (1, 2). Moreover, the relationship between motor commands and the resulting sensory feedback is not fixed but rather depends on the state of both the body and the external world. For a given context, there exists an optimal response function that maximizes behavioral performance (3). As the context varies, animals need to adapt their response in a flexible manner (4).

A key example is optic flow navigation, where animals use visual cues to estimate their motion in order to maintain an intended trajectory (5, 6). This behavior is ubiquitous among motile species, but it is particularly important for flying and swimming animals, which can be easily thrown off course by external currents. For translational motion, the relationship between the animal speed and the retinal optic flow is ambiguous, as it depends on the distance of the animal from the surrounding objects, a parameter that varies in time and cannot be directly sensed by the animal (7).

To cope with such challenges, some animals use forward models to internally predict the sensory consequences of their motor commands, thereby distinguishing them from external perturbations (4, 8, 9). These internal models may be either hardwired or constantly updated by minimizing prediction errors, enabling the system to adapt to a changing context through motor learning. Moreover, predictive processing can help mitigate the destabilizing effects of feedback delays. Although internal models provide a powerful framework for efficient motor control (10–12), it remains unclear whether simpler mechanisms are employed by animals to address the same challenges.

We address this question using the miniature freshwater fish *Danionella cerebrum*, a recently introduced model vertebrate whose size and transparency enables in vivo whole-brain imaging across all developmental stages (13, 14). We first use a virtual reality system to dissect the sensorimotor computation at play during optic flow navigation. We then

## Significance

Animal movement is shaped by the continuous interaction between motor actions and sensory feedback. This process is challenging due to time delays, which can have destabilizing effects, and the constantly varying relationship between motor commands and sensory feedback. Identifying adaptive strategies that ensure both stability and performance, and their implementation in the brain, remains a central challenge in neuroscience. We address this by simultaneously monitoring behavior and brain activity in the miniature transparent fish *Danionella cerebrum* during visually guided navigation in a virtual reality system. Using a dynamical systems approach, we find that their adaptive response arises from nonlinear encoding of both sensory and motor information, revealing a distinct functional role for these fundamental properties of the nervous system.

Author contributions: L.D., M.C., A.H., T.P., G.M.-D., V.B., and G.D. designed research; L.D. performed research; L.D., M.C., A.H., T.P., G.M.-D., V.B., and G.D. contributed new reagents/analytic tools; L.D. analyzed data; and L.D., M.C., A.H., T.P., G.M.-D., V.B., and G.D. wrote the paper.

The authors declare no competing interest.

This article is a PNAS Direct Submission.

Copyright © 2025 the Author(s). Published by PNAS. This open access article is distributed under Creative Commons Attribution License 4.0 (CC BY).

¹To whom correspondence may be addressed. Email: georges.debregeas@sorbonne-universite.fr

This article contains supporting information online at https://www.pnas.org/lookup/suppl/doi:10.1073/pnas.2510385122/-/DCSupplemental.

Published October 23, 2025.
<figure><img src="image_3.png" /><figcaption>**Fig. 1.** Virtual reality system. (A) Schematic of the experimental setup. Fish are head-tethered in agarose. Their tail movements are video-monitored and a projector displays a visual pattern on the opaque bottom of the tank. Brain-imaging can be simultaneously performed using a light-sheet microscope. (B) Snapshot of a fictively swimming fish. From successive tail profiles (red line), we extract the fictive speed *V*, and angular velocity *Ω* which are used to compute the translational and rotational feedback flow rates *αV* and *βΩ*, respectively. We additionally simulate an external current with flow rate *ω*<sub>ext</sub>. (Scale bar, 1 mm.)</figcaption></figure>

use whole-brain imaging to probe the dynamics of the neuronal
population engaged in this process.

Results

**Stabilization of Visual Flows in a Virtual Reality System.** The fish were head-tethered using agarose, then placed in a virtual-reality setup that comprised a camera to monitor tail movement, a projector to display visual patterns beneath the animal, and a light-sheet microscope for brain imaging (Fig. 1A, *Materials and Methods*). Experiments were performed on two-week-old danionella, which, unlike zebrafish larvae, exhibit continuous swimming in both freely moving and head-tethered configurations, with a quasi-constant tail-beat frequency of ≈16 Hz (15). Using a fluid dynamics model calibrated against freely swimming recordings, we inferred the fictive forward speed *V* and angular velocity of the fish in real-time from the video-monitored tail movement (16, 17) (Fig. 1B, *Materials and Methods*). These values were used to compute the visual feedback, i.e., the translational and rotational velocity of the projected pattern to induce the illusion of self-motion in the fish.

In the real world, a movement of the fish at a certain speed corresponds, from the animal's egocentric perspective, to an opposite movement of the environment with the same speed. However, what the animal actually perceives is the resulting optic flow on its retina, which only depends on the ratio between the speed and the distance of the surrounding objects. For a pattern moving at speed *v*, the optic flow is characterized by the rate *ω* = *v*/*h*, where *h* is the pattern distance, which in our case is 5 mm (Fig. 2A). We implemented the feedback by translating the pattern backward, resulting in a flow rate *αV*, where the feedback gain *α* can be interpreted as the inverse of the pattern distance in the virtual environment. Note that the ambiguity in relating optic flow and self-motion is specific to translational movement: the angular velocity can be directly inferred from the rotational optic flow. We implemented rotational feedback by rotating the pattern with angular velocity *βΩ*, where a rotational feedback gain *β* = 1 corresponds to freely swimming conditions.

We elicited an optomotor response by translating the pattern
in a certain direction with an imposed rate ω<sub>ext</sub>, simulating an
external current dragging the fish in the opposite direction (18).
The fish responded to such a stimulus by actively turning to
align with the fictive current (Movie S1). Here we focus on

the case where the external current starts off directed along
the fish heading direction, corresponding to a fictive backward
movement. If the fish remains approximately aligned with the
current then the optic flow is directed along the fish heading
with net rate ω = ω<sub>ext</sub> − αV.

The absence of visual feedback (α = 0, open-loop) rapidly
induces the fish to give up and stop swimming. Otherwise (α > 0,
closed-loop), they can keep swimming for sustained periods of
time and adapt their swimming speed to match external and
feedback flow rates such that V ≃ V* = ωext/α (Fig. 2B and
Movies S2 and S3). Equivalently, this means that their position
in the virtual space remains approximately constant.

We assessed the robustness of this behavior by presenting fish
with external currents of varying optic flow rate ω<sub>ext</sub> and for
different values of the feedback gain α, in randomized trials lasting
30 s. We considered three experimental paradigms (Fig. 2C):
fixed external flow rate (varying α with fixed ω<sub>ext</sub>), fixed pattern
distance (varying ω<sub>ext</sub> with fixed α), fixed current speed (varying
ω<sub>ext</sub> and α with a fixed target speed V*). We found that most
fish adapt their speed to compensate for the external current,
provided that the target speed V* falls within a physiologically
accessible range (<i>SI Appendix</i>, section 1G).

**Sensorimotor Delays Induce Sustained Speed Oscillations.** We noticed that the fictive speed signals displayed quasi-periodic oscillations around the target value *V*\*, as illustrated in Fig. 2B. These speed modulations have a characteristic frequency of ≈1.5 Hz and an amplitude proportional to the target speed (*SI Appendix*, sections 1H–I). We hypothesized that they could be a signature of delays in the sensorimotor loop. Intuitively, if the correcting action lags the driving signal by a finite delay *τ*,

<figure><img src="image_4.png" /><figcaption>**Fig. 2.** Fish adapt their swimming speed to stabilize external visual flows. (A) Definition of the optic flow rate ω. Rescaling the pattern size, distance *h*, and speed *v* by the same factor does not affect the perceived optic flow. (B) Example trace showing the fish response to forward pattern motion. After a short latency, the fish adjusts its swimming speed to match external and feedback flow rates. (C) Median swimming speed (black error bars indicate quartiles of the distribution across *N* = (33, 31, 28) fish, from left to right) for different values of the external flow rate ω<sub>ext</sub> and feedback gain α. Fish can adapt their swimming speed to the target value (gray lines) to stabilize themselves against currents. The schematics below the graphs illustrate the equivalence of the parameter changes in the real world, with the arrows denoting the speed of the external current for two different parameter values (larger in red).</figcaption></figure>
<figure><img src="image_5.png" /><figcaption>Fig. 3. Time delays in the sensorimotor loop. (A) Schematic showing the delays in the sensorimotor loop. The fish perceives a certain optic flow and updates its swimming speed after a sensorimotor delay τs. A given tail movement induces a change in the optic flow after a feedback delay τf. (B) Reverse correlation gives an estimate of the impulse response function (black line and gray area, mean and SD over N = 11 fish), i.e., the evolution of V following an impulse perturbation of ωext. The initial peak represents the response kernel (yellow area), whose time gives an estimate of the total delay τ = τs + τf. Integrating Eq. 1 with this response kernel, we obtained the theoretical impulse response shown in red.</figcaption></figure>

the fish may systematically overcompensate for the same duration after crossing the target speed, leading to oscillations of period ~4τ (19).

We measured the sensorimotor delay by modulating the imposed optic flow with a white-noise signal, while monitoring the fish velocity. The impulse response function, defined as the acceleration signal evoked by an impulse of optic flow rate, was then estimated by reverse correlation (20). This response function exhibits a sharp delayed positive peak, corresponding to the response kernel, followed by a negative modulation reflecting the feedback mechanism (Fig. 3B).

The time of the peak provides an estimate of the delay τ = 150 ± 20 ms. This value is close to one-fourth of the oscillatory period observed in fish swimming under constant current flow (Fig. 2B), supporting our initial hypothesis. This sensorimotor delay can be decomposed into two components, τ = τs + τf, where τs corresponds to the internal delay between the sensory perception and the execution of the correcting motor action, while τf accounts for the lag between the tail motion and the resulting change in optic flow (Fig. 3A). While in freely swimming conditions τf is due to inertia, here it corresponds to the latency of the virtual reality, which we measured to be τf = 60 ± 4 ms (SI Appendix, section 1E). Therefore, the sensory-to-motor internal delay is τs = 90 ± 20 ms, of the order of a tail-beat period. This value was found to be independent of both ωext and α (SI Appendix, section 2B).

To model the sensorimotor loop, we first assumed that the fish acceleration at time t is proportional to the net flow rate at time t - τ:

$$ \dot{V} = k\omega|_{t-\tau} = k(\omega_{\text{ext}} - \alpha V)|_{t-\tau} \quad [1] $$

where the parameter k denotes the responsiveness of the fish to optic flow. Rewriting Eq. 1 in dimensionless form, we found that the system dynamics are governed by a single dimensionless gain, μ = kaτ, whose value defines the stability regime (Fig. 4A, Materials and Methods). For μ < 1/e, V(t) decays exponentially to the target value V*. For 1/e < μ < π/2, it converges to V* through damped oscillations. At μ = π/2, one observes a Hopf-like bifurcation, followed by an unstable regime with diverging oscillations. This equation could thus lead to the sustained oscillations observed in our data through two distinct mechanisms: in the intermediate regime, sensorimotor noise could drive the system away from the target speed eliciting noise-induced

oscillations; in the unstable regime, nonlinearities could prevent the system from diverging leading to limit cycle oscillations.

This simple linear model accounts for nontrivial aspects of the system dynamics. We forced speed oscillations with a sinusoidal modulation of the external flow. Using the model, we could quantitatively reproduce the observed phase lag between the fish speed oscillations and the driving signal over a wide range of driving frequencies (SI Appendix, section 2C). We also manipulated the sensorimotor delay τ by adding a variable delay Δτ to the visual feedback. Again, the model quantitatively captures the decrease in frequency of the self-sustained oscillation with increasing Δτ (SI Appendix, section 2D). Notably, for large additional delays (~0.5 s), the oscillations become highly regular in both amplitude and frequency, as expected for a limit cycle, suggesting that the gain μ has crossed the bifurcation threshold.

**Adaptive Responsiveness Prevents Delay-Induced Instability.** The three dynamical regimes illustrated in Fig. 4A highlight the challenge that the fish need to overcome: they must operate at large enough gain μ = kaτ to swiftly reach the target speed, but keep clear of the bifurcation threshold beyond which oscillations become unstable. This seems challenging considering that μ is proportional to the feedback gain α, a parameter that can vary rapidly over a wide range and cannot be directly inferred from visual cues.

As its value governs the system dynamics, we sought to evaluate μ across experimental conditions, i.e., for different values of ωext, α, and the additional feedback delay Δτ. Since the delay τ was found to be invariant, we estimated the responsiveness k through linear regression between V̇(t) and ω(t - τ).

Assuming the responsiveness k to be fixed, the dimensionless gain μ should be proportional to both α and τ. In contrast, we found that μ is quasi-independent of α (except for target speeds approaching the upper physiological limit) and increases sublinearly with both Δτ and ωext (Fig. 4B). These observations suggest that the responsiveness k is adaptive. Interestingly, across most of the range of parameters tested, such adaptation leads the fish to operate within the intermediate dynamic regime, which optimally balances responsiveness and stability.

**Logarithmic Transformations Balance Responsiveness and Stability.** To better understand the mechanism underlying the adaptive behavior, we monitored the fish transient acceleration following a sudden change in optic flow rate. After a ~10 s period during which the fish adjusted their swimming speed to match a constant optic flow rate ωext, we suddenly disabled the feedback and displayed forward or backward flows of various rates ω (Fig. 5A). We found that, after a delay τ, the swimming speed approximately follows an exponential evolution, with an acceleration rate V̇/V independent of both ωext and α (SI Appendix, section 2F). For |ω| > ωth ≈ 0.03 rad/s, the acceleration rate was found to vary logarithmically with ω for both forward and backward flow, with the fish accelerating and decelerating, respectively. For |ω| < ωth the fish shows a slight deceleration independent of ω.

These findings can be summarized as a logarithmic compression of the sensory input, followed by a temporal integration and an exponential expansion (Fig. 5C), and so the swimming speed can be expressed by the following stochastic nonlinear delay equation:

$$ \frac{d}{dt} \log(V) = r \log^*(\omega/\omega_0)|_{t-\tau} + \sigma\xi \quad [2] $$
<figure><img src="image_6.png" /></figure>

<figure><img src="image_7.png" /><figcaption>**Fig. 4.** Fish adapt their responsiveness to prevent delay-induced instability. (A) Growth rate and oscillation frequency of the solutions to Eq. 1 as a function of the dimensionless gain $\mu$. The three dynamical regimes are illustrated by example trajectories (top plots) for three values of $\mu$ (colored triangles). (B) Estimated values of the dimensionless gain $\mu$ through linear regression [black error bars, quartiles of the distributions over $N = (33, 31, 28, 14)$ fish, from left to right]. The predictions of the effective linear theory of Eq. 2 are shown in gray.</figcaption></figure>

where $\log^*(x) = \operatorname{sgn}(x) \log(1 + |x|)$, a functional form that offers a reasonable approximation of the measured response function (Fig. 5B). The response parameters $r$ and $\omega_0$ were inferred to be $r = 1.6 \pm 0.3 \text{ s}^{-1}$ and $\omega_0 = 0.07 \pm 0.03 \text{ rad/s}$ from fitting the data of Fig. 5B. A white noise source $\xi$ with amplitude $\sigma$ was also introduced to account for the additive noise observed in the dynamics of $\log(V)$, in agreement with the motor control literature (21). From the variability in the stabilization to constant currents, we estimated the noise amplitude at $\sigma = 0.9 \pm 0.2 \text{ s}^{-1/2}$ (Materials and Methods). Importantly, the three parameters $r$,

$\omega_0$ and $\sigma$ were found to be independent of the experimental conditions and weakly variable across individuals.

To better interpret Eq. 2, we can define the effective responsiveness as $k_e = \dot{V}/\omega|_{t-\tau} = rV|_t[\log^*(\omega/\omega_0)/\omega]|_{t-\tau}$. For small deviations around the target speed $V \approx \omega_{\text{ext}}/\alpha$, the effective gain becomes $\mu_e = k_e \alpha \tau \approx r\omega_{\text{ext}} \tau [\log^*(\omega/\omega_0)/\omega]|_{t-\tau}$. Hence, the exponential expansion results in $\mu_e$ being independent of $\alpha$ and proportional to $\omega_{\text{ext}}$. Furthermore, because of the logarithmic compression of the optic flow rate, $k_e$ keeps decreasing as the swimming speed deviates from the target, preventing the oscillations from diverging.

<figure><img src="image_8.png" /><figcaption>**Fig. 5.** Logarithmic transformations balance responsiveness and stability. (A) Evolution of the swimming speed following a sudden perturbation, triggered at time $t=0$, of the optic flow rate $\omega$ (color-coded values). Median trajectories over trials (solid lines and shaded areas, mean and SD across $N=5$ fish) evolve approximately exponentially (dashed lines, best fit) after a delay $\tau$. (B) Acceleration rate (extracted from A) as a function of $\omega$. Beyond a threshold, the dependence is logarithmic (black line, best fit). The *Insets* show the same data on semilogarithmic scales for positive and negative $\omega$. (C) Schematic showing the sequence of sensorimotor transformations. The optic flow undergoes a logarithmic compression, followed by an integration process and, finally, an exponential expansion sets the swimming speed. (D) Amplitude and frequency of the oscillations derived from Eq. 2 as a function of the dimensionless parameters $\mu_0$ and $\sigma_0$. There is a sharp transition to oscillatory behavior (dashed line) and a smooth transition between noise-induced and limit cycle oscillations (solid line). (E) *Top*: distributions of relative swimming speeds $V/V^*$ (blue scale). The values at half-maximum (black dots) delimit the typical range of speed fluctuations. *Bottom*: power spectra of the relative acceleration $\dot{V}/V$ (red scale) and characteristic oscillation frequency (black error bars, for peak-to-width ratios larger than 3). Data were pooled across the fish from the experiments of Fig. 4B ($N = (33, 31, 28, 14)$, from left to right). The color bars on the bottom correspond to the points in (D), leading to the theoretical predictions shown in gray.</figcaption></figure>
As numerical simulations of Eq. 2 quantitatively reproduced the experimentally observed speed oscillations (SI Appendix, section 2I), we developed an effective linear theory to get an analytical understanding of the system's behavior (Materials and Methods). In the limit of small oscillations, for which $\frac{d}{dt}\log(V) \simeq \dot{V}/V^*$, we found that the dynamics are fully determined by the dimensionless gain $\mu_0 = r\tau\omega_{\text{ext}}/\omega_0$ and noise amplitude $\sigma_0 = \sigma\sqrt{\tau\omega_{\text{ext}}/\omega_0}$. We derived theoretical predictions for the amplitude and characteristic frequency of the fluctuations by combining the contributions of noise and nonlinearity (Fig. 5D). The deterministic dynamics (i.e., in the absence of noise) give rise to limit cycle oscillations for $\mu_0 > \pi/2$, whose amplitude corresponds to an effective responsiveness $k_e$ close to the stability boundary $\mu_e = \pi/2$. The presence of noise drives the system away from the deterministic attractor, leading to larger values of $|\omega|$ and correspondingly smaller values of $k_e$. As in the analysis of Eq. 1, we found a sharp transition to oscillatory dynamics for $\mu_e = 1/e$. However, the noise tends to smooth out the bifurcation to limit cycle oscillations at $\mu_0 = \pi/2$ (SI Appendix, section 2H).

While the value of $\alpha$ has no effect on the behavior of the solutions, increasing $\omega_{\text{ext}}$ or $\tau$ moves the system from the noise-dominated regime to the limit cycle-dominated regime with the oscillation frequency transitioning from 0 to $1/(4\tau)$. The relative amplitude of the fluctuations depends only weakly on $\omega_{\text{ext}}$ but it is strongly modulated by $\tau$. Plugging in our estimates of $\tau$, $\sigma$, $r$, and $\omega_0$, we obtained theoretical predictions that quantitatively match the amplitude and frequency of the measured speed fluctuations (Fig. 5E). We also found that the predicted effective responsiveness matches our naive estimates through linear regression (Fig. 4B).

**Logarithmic Coding in the Brain.** The behavioral experiments allowed us to establish the sensorimotor operations that govern

speed stabilization (Fig. 5C). We next asked whether these nonlinear transformations could be reflected in the neural coding of optic flow and swimming speed. To address this, we leveraged the small size and transparency of danionella's brain to perform brain-wide functional recordings in 2-wk-old transgenic larvae expressing the GCaMP6s calcium indicators in all neurons. The reporter expression was confined to the neuronal nuclei and we used a light sheet microscope with confocal line detection in order to mitigate possible cross-talk (Materials and Methods) (22, 23).

After neuronal segmentation and signal extraction, we obtained, for each neuron, a time-trace of the relative variation in fluorescence $\Delta F/F_0$. Although we could monitor calcium activity in closed-loop settings (Movie S4), we mostly used open-loop experiments as they allowed us to disentangle visually driven from motor-related activity. The fish were exposed to forward and backward flows of varying rates and we simultaneously recorded their tail movements. Visually driven neurons were categorized based on their correlation (positive or negative) with forward and/or backward flow rates (Fig. 6 A and B, Materials and Methods). Similarly, motor-related neurons were either positively or negatively correlated with swimming speed (Fig. 6 C and D). These distinct populations displayed stereotypical spatial distributions (Fig. 6 A and C, SI Appendix, Fig. S12, and Movies S5 and S6).

In line with previous observations made in zebrafish (24, 25), cells positively correlated with optic flow were found in the optic tectum, pretectum, and anterior hindbrain (Fig. 6A). We also identified neuronal populations anticorrelated with optic flow in the habenula, torus longitudinalis, cerebellum, superior and inferior raphe, and inferior olive. We further categorized these neurons based on the shape of their tuning curves (Fig. 6B). We observed that, as the information driving the optomotor response propagates from the visual regions to the hindbrain, the tuning undergoes a transformation from mostly linear to logarithmic

<figure><img src="image_9.png" /></figure>

Fig. 6. Neural activity encodes optic flow and swimming speed logarithmically. (A) Spatial distributions of neurons whose activity is correlated to optic flow rate $\omega$, either to both forward and backward flow (Left), only forward (Middle), or only backward (Right). Blue (correlated) populations show a linear response to optic flow rate, whereas red (correlated) and green (anticorrelated) are logarithmically tuned. The density distributions are averaged over $N=8$ fish and integrated along different axes to obtain the projections in the horizontal (Left) and sagittal (Right) planes. They are separately normalized for each neuronal population. The outlines indicate the forebrain, midbrain, and hindbrain (from top to bottom). (OT) optic tectum; (TL) torus longitudinalis; (Cb) cerebellum; (aHB) anterior hindbrain; (Pt) pretectum; (IR) inferior raphe; (IO) inferior olive; (Ha) habenula; (SR) superior raphe. (Scale bar, 100 µm.) (B) Tuning curves for the populations shown in (A), showing the average activity of each population as a function of $\omega$ (error bars, mean and SD across $N=8$ fish) and the best fits (solid lines). (C) Same as (A), but for neurons encoding the swimming speed $V$, either increasing (orange) or decreasing (light blue) logarithmically. (MO) medulla oblongata; (mTg) medial tegmentum; (LLg) lateral line ganglia. (D) Same as (B), but for the average activity of the populations shown in (C) as a function of $V$. The solid lines show the logarithmic fits.

<figure><img src="image_10.png" /></figure>
coding. We checked that these nonlinear response curves could
not be accounted for by a saturation of the calcium sensor (SI
Appendix, section 3F).

Neuronal populations encoding the swimming speed were distributed throughout the hindbrain (Fig. 6C), in regions consistent with known premotor areas in zebrafish (26, 27), the medulla oblongata and the medial tegmentum. We found neurons anticorrelated with swimming speed in the habenula, optic tectum, dorsal medulla, superior and inferior raphe, and lateral line ganglia. All motor-related neurons were logarithmically tuned, either positively and negatively, to the swimming speed (Fig. 6D).

In summary, the tuning curves of the neuronal populations engaged in visuomotor processing reveal nonlinear transformations along the visuomotor pathways that are consistent with the behavioral model.

Discussion

We experimentally probed the sensorimotor computation at play during visually driven speed regulation in danionella, by systematically manipulating the sensory feedback. This allowed us to infer a simple mathematical model that captures the speed of the animal, including the sustained oscillations induced by the sensorimotor delay, across a wide range of experimental conditions. Our analysis reveals that the nonlinear transformations that occur at both sensory and motor ends prevent instability and enable efficient stabilization.

These sensorimotor operations, inferred from behavioral
assays, were evident at the neural level in the tuning curves
of visually driven and motor-associated neurons. They are also
biologically grounded, reflecting two well-established principles
in neuroscience (Fig. 5C). The sensory compression seen in our
data is an instance of the Weber–Fechner law, which states that
the perceived intensity of a stimulus increases logarithmically be-
yond a certain detection threshold (28). The expansion observed
at the motor end corresponds to Henneman’s size principle (29),
which states that as the motor command increases, progressively
larger motor units are recruited, resulting in an exponential
transformation from motor command to muscle force (30).

Our model focuses on the regulation of forward speed during continuous swimming. A natural extension would be to incorporate orientation control, which maintains the fish aligned with the external current. In addition, a more complete model should include swimming initiation, which may be triggered by the detection of optic flow (31), as well as termination, which may result from sustained swimming at either boundary of the physiological speed range.

Our results suggest that the mechanism used by the fish to
stabilize their position is based on the sole perceived optic flow,
and does not involve a forward internal model. Under natural
conditions, fish do not only stabilize their position: internal drives
and competing stimuli can override the optomotor response,
allowing them to move across the environment. Our study does
not rule out the possibility that internal models are at play in
such general contexts, where they could prove advantageous by
helping fish disentangle the consequences of their own actions
from external environmental dynamics. Consistent with this idea,
insects have been shown to use efference copies to modulate
optic flow detection during active displacements, but not during
stabilization (32–34).

The observed speed modulations are reminiscent of the self-
generated oscillatory movements observed in animal locomotion,
which were shown to play a role in active sensing and depth

estimation (35–38). However, in our experiments, the oscilla-
tions are fully accounted for by delayed feedback control, and can
be manipulated in a deterministic way through perturbations of
feedback delay and optic flow rate. These observations indicate
that they are a by-product of the delays in the sensorimotor loop
rather than being driven by neural oscillators.

Zebrafish has been an important model system to study visuomotor control in vertebrates. Although the capacity of this animal to adapt its response to changes in the feedback gain is now well documented, the control mechanism at play, and notably the existence of an internal model, remains debated (39–42). The difficulty in reaching a definitive conclusion arises from the intermittent nature of zebrafish locomotion, which obscures the underlying sensorimotor computation. Given the close morphological and genetic proximity between danionella and zebrafish, and the existence of a comparable sensorimotor delay in both species (41), it seems likely that they share the same control mechanism. In the case of zebrafish however, the integrated optic flow rate is not directly reflected in the swimming speed, but we expect it to be encoded in the persistent activity of neuronal circuits that modulate the intensity, frequency, and duration of swimming bouts (43, 44).

Logarithmic coding has been shown to be optimal from an information-theoretical perspective as it minimizes relative error (30, 45-47), but we are not aware of any prior work addressing its role in sensorimotor control. Because it relies on fundamental neural encoding principles, we expect the control mechanism identified in danionella to be relevant across other species and sensorimotor systems in which responsiveness and stability need to be balanced. These include flight control in insects (48, 49), ocular pursuit in monkeys (50), motor control in humans (51) and position stabilization in electric fish (52), all examples in which latency-induced speed oscillations have been observed. Beyond biology, the proposed mechanism could also inspire the development of robust control strategies for robots navigating unpredictable environments (53).

**Materials and Methods**

**Virtual Reality Experiments.** All experiments were performed on larvae of *D. cerebrum* of age ≈14 d post fertilization and total body length ≈4.5 mm (SI Appendix, section 1A). The experimental procedures were approved by the ethics committee "Le Comité d'Éthique pour l'Expérimentation Animale Charles Darwin C2EA-005." Imaging experiments were performed using the transgenic line *Tg(elavl3:H2B-GCaMP6s)* (15), while behavioral experiments were also performed on wild type fish. The fish were immobilized in a 2% agarose gel (SI Appendix, section 1B) and placed in a custom-made tank (SI Appendix, section 1C). A Python program was written to compute the fictive velocity from the recorded tail movements and update the projected visual pattern in real-time (SI Appendix, section 1E). We used fluid dynamics to estimate the thrust and drag acting on the fish and computed its fictive forward speed *V* and angular velocity *Ω* (SI Appendix, section 1D). We calibrated these estimates using recordings of freely swimming fish. We projected a random pattern with a characteristic length scale of 5 mm on the bottom of the tank at a distance of *h* = 5 mm from the fish. To restore visual feedback, we translated the pattern opposite to the fish heading direction with speed *αVh* and rotated it with angular velocity *βΩ*. To simulate an external current, we translated the pattern with speed *ωexth* along a direction that rotated together with the pattern, corresponding to a fixed direction in the virtual environment (SI Appendix, section 1E). To study the response to constant currents, we presented currents with different parameter values in a randomized order, with each value presented in two trials of 30 s duration.

**Impulse Response Estimation Via Reverse Correlation.** We presented fish with an external current of five minutes duration with a fluctuating flow rate of the form $\omega_{\text{ext}}(t) = \bar{\omega}_{\text{ext}} + \sigma_{\text{ext}}\xi(t)$, where $\xi$ is a Gaussian white noise. Then, the
impulse response function $\dot{G}$ was estimated by computing the cross-correlation (20) (SI Appendix, section 2B):

$$ \dot{G}(t) = \frac{1}{\sigma_{\text{ext}}^2} \left\langle \left( \omega_{\text{ext}}(t' - t) - \bar{\omega}_{\text{ext}} \right) \dot{V}(t') \right\rangle_{t'} \quad [3] $$

Where we averaged over the periods of time where the fish were swimming. The impulse response could be reproduced (red line in Fig. 3B) by considering the first positive peak (yellow area in Fig. 3B, Gaussian fit) to be the response kernel $K$ and numerically integrating the equation $\dot{V} = K * \omega$.

**Analysis of Linear Delay Equation.** We nondimensionalized Eq. 1 by considering $x(t') = V(t) - \omega_{\text{ext}}/\alpha$ and $t' = t/\tau$, leading to (SI Appendix, section 2A):

$$ \frac{dx}{dt'} = -\mu x |t' - 1| \quad [4] $$

Looking for a solution in the form of an exponential with complex growth rate $\lambda$, we obtain the following characteristic equation:

$$ \lambda = -\mu e^{-\lambda}, \quad [5] $$

whose solutions are given by the Lambert W function as $\lambda_I = W_I(-\mu)$. The behavior is dominated by the largest growth rate Re($W_0(-\mu)$), with the corresponding oscillation frequency Im($W_0(-\mu)$) / (2$\pi$).

**Responsiveness Estimation Via Linear Regression.** We extracted the slope of the relationship between $\omega(t - \tau)$ and $\dot{V}$ using the Theil-Sen estimator to reduce the effect of outliers (54) (SI Appendix, section 2E). We used the estimate of $\tau$ obtained from the impulse response and considered the data from the experiments where the fish were swimming against constant currents.

**Open-Loop Perturbations.** We presented fish with constant currents in closed-loop and then suddenly presented a certain optic flow rate $\omega$ in open-loop for a duration of 0.5 s. The different values of $\omega$ were presented in a randomized order with each value presented at least 10 times for each one of several baseline closed-loop conditions ($\omega_{\text{ext}}, \alpha$) (SI Appendix, section 2F). The evolution of the speed following the perturbation was fit with a delayed exponential evolution:

$$ V(t) = V_0 \exp \left[ H(t - t_0) A \tanh \left( \frac{\lambda}{A} (t - t_0) \right) \right], \quad [6] $$

where $H$ is the Heaviside step function and we included a saturation in the form of a hyperbolic tangent. The dependence of the acceleration rate $\lambda$ on the flow rate was fit with a logarithm:

$$ \lambda(\omega) = \lambda_0 \pm \lambda_{\pm} \log(\pm\omega/\omega_{\text{th}}), \quad [7] $$

respectively, for positive and negative values of $\omega$.

**Noise Amplitude Estimation.** We estimated the noise amplitude by computing the SD of the increments of the speed on a logarithmic scale (SI Appendix, section 2G):

$$ \sigma = \sqrt{\left\langle \frac{(\log(V_t + \Delta t) - \log(V_t))^2}{\Delta t} \right\rangle} \quad [8] $$

For the estimate we considered the data from the experiments where the fish were swimming against constant currents.

**Analysis of Stochastic Nonlinear Delay Equation.** We nondimensionalized Eq. 2 in the limit of small oscillations by considering $x(t') = (\omega_{\text{ext}} - \alpha V(t))/\omega_0$ and $t' = t/\tau$, leading to (SI Appendix, section 2H):

$$ \dot{x} = -\mu_0 \log^*(x|t' - 1) + \sigma_0 \xi' |t'|, \quad [9] $$

where $\xi'$ denotes delta-correlated noise in the dimensionless time $t'$. For a certain value of $x|t' - 1 = x_0$ the system evolves locally with a rate of change $-\mu_0 \log^*(x_0)$ which would equivalently arise from a linear system with a gain

$\mu_e = \mu_0 \log^*(x_0)/x_0$. We obtained an estimate of the amplitude of limit cycle oscillations $A_{Ic}$ by considering the value of $x_0$ for which the effective gain becomes $\pi/2$:

$$ A_{Ic} = -\frac{2\mu_0}{\pi} W_{-1} \left( -\frac{\pi}{2\mu_0} \exp \left( -\frac{\pi}{2\mu_0} \right) \right) - 1. \quad [10] $$

The noise term induces fluctuations with an amplitude $A_n$ that can be derived from the following implicit relation:

$$ A_n \log(1 + A_n) = \frac{\sigma_0^2}{2\mu_0 c_n^2}, \quad [11] $$

which we obtained using the fact that a Ornstein-Uhlenbeck process with gain $\mu_e$ and noise amplitude $\sigma_0$ leads to a fluctuations with $SD \ c_nA_n = \sigma_0/\sqrt{2\mu_e}$ (55). By combining the limit cycle and the noise-induced amplitudes we obtained an estimate of the total amplitude of the fluctuations and thus of the effective gain $\mu_e(\mu_0, \sigma_0)$. The predicted oscillation frequency is then given by $\text{Im}(W_0(-\mu_e))/(2\pi)$.

**Brain Imaging Experiments.** We used a custom-made light sheet microscope with confocal slit detection to excite and record the fluorescence across the brain of the fish (SI Appendix, section 3A). We recorded stacks of 25 different layers at a rate of $\approx 2.3$ brain volumes per second for a laser power of $\approx 150$ µW. For the open-loop experiments we presented constant currents with different values of flow rate $\omega$ in a randomized order, with each value presented in 3 trials of 20 s duration (SI Appendix, section 3B).

**Processing of Brain Images.** We corrected an eventual horizontal shift in the images by computing the cross-correlation between different images (SI Appendix, section 3C). Then, we computed the average covariance between the intensity of neighboring pixels over the recording. Applying a blob detection algorithm to the resulting images gave the positions of all the neurons showing a modulation in activity during the recording. Then, we computed the relative fluorescence change $\Delta F/F_0$ for each neuron taking as baseline $F_0$ the median fluorescence in the absence of optic flow and tail movements.

**Registration to a Reference Brain.** To compare the results for different fish, we acquired a stack of brain images with high vertical resolution and long exposure for each fish. Then, we numerically estimated the optimal affine transform between different stacks by maximizing their cross-correlation through gradient descent (SI Appendix, section 3D). The reference stack was obtained by averaging the aligned stacks for all fish and then mapping the left-right symmetry plane to the middle plane of the stack.

**Correlation Analysis.** We identified the neurons whose activity is significantly correlated or anticorrelated with four different signals (SI Appendix, section 3E): flow rate $|\omega|$, forward flow rate $\omega H(\omega)$, backward flow rate $-\omega H(-\omega)$, and swimming speed $V$. We computed the Pearson correlation between each of these signals and the relative fluorescence change $\Delta F/F_0$ for every neuron. To determine significantly high correlation values, we built null distributions by computing the correlation with time-shifted versions of the signals with an autocorrelation smaller than 0.25 in magnitude. To account for the problem of multiple comparison for hypothesis testing, we used the Benjamini-Hochberg procedure (56), controlling the false discovery rate with a significance threshold of $10^{-5}$. Neurons present in more than one out of the 8 identified populations were assigned to the population for which the correlation was largest in magnitude. To separate the neurons correlated to optic flow into subpopulations showing linear or logarithmic coding, we computed the correlation values with the logarithm of the corresponding signal and compared them with the previously computed values. We fitted the tuning curves either with a linear response $Ax$ or a logarithmic one $A \log(x/x_0)H(x - x_0)$ as a function of the corresponding signal $x$. To visualize the spatial distributions of the neuronal populations, we used kernel density estimation with a uniform spherical kernel of radius 5 µm. We assigned a color to each pixel by computing the weighted sum of the hues corresponding to each population with the
respective value of the density. We separately normalized each density to result in a maximum pixel intensity of 1, and the weighted sum was renormalized when any color channel exceeded 1. We used the Max Planck Zebrafish Brain (mapzebrain) atlas (57) to identify the brain regions associated with the neuronal populations.

**Data, Materials, and Software Availability.** Behavioral and neural data and code for experiments and analysis have been deposited in Zenodo (https://doi.org/10.5281/zenodo.15187167) (58).

**ACKNOWLEDGMENTS.** We thank the members of the aquatic facility of the Institut de Biologie Paris-Seine for their help in taking care of the fish. We thank

Benjamin Judkewitz and Filippo Del Bene for sharing their fish with us and Julie Lafaye for helping set up the facility. We thank Pavan Kaushik, Verity Cook, and the members of the Laboratoire Jean Perrin and the SmartNets European Training Network for helpful feedback and discussions. This work was supported by the European Union's Horizon 2020 research and innovation programme under the Marie Skłodowska-Curie Grant Agreement No. 860949 and by the Agence Nationale de la Recherche under the Locomat project ANR-21-CE16-0037.

Author affiliations: a Sorbonne Université, CNRS, Laboratoire Jean Perrin, Paris F75005, France; and b Sorbonne Université, CNRS, INSERM, Institut de Biologie Paris-Seine, Paris F75005, France

1. K. J. Åström, R. M. Murray, *Feedback Systems: An Introduction for Scientists and Engineers* (Princeton University Press, Princeton, NJ, 2008), p. ocn183179623.

2. R. Sipahi, Si. Niculescu, C. T. Abdallah, W. Michiels, K. Gu, Stability and stabilization of systems with time delay. *IEEE Control. Syst. Mag.* **31**, 38–65 (2011).

3. E. Todorov, Optimality principles in sensorimotor control. *Nat. Neurosci.* **7**, 907–915 (2004).

4. R. Shadmehr, M. A. Smith, J. W. Krakauer, Error correction, sensory prediction, and adaptation in motor control. *Annu. Rev. Neurosci.* **33**, 89–108 (2010).

5. W. H. Warren, B. A. Kay, W. D. Zosh, A. P. Duchon, S. Sahuc, Optic flow is used to control human walking. *Nat. Neurosci.* **4**, 213–216 (2001).

6. A. S. Mauss, A. Borst, Optic flow-based course control in insects. *Curr. Opin. Neurobiol.* **60**, 21–27 (2020).

7. J. R. Serres, F. Ruffier, Optic flow-based collision-free strategies: From insects to robots. *Arthropod Struct. Dev.* **46**, 703–717 (2017).

8. R. C. Miall, D. M. Wolpert, Forward models for physiological motor control. *Neural Networks* **9**, 1265–1279 (1996).

9. B. Webb, Neural mechanisms for prediction: Do insects have forward models? *Trends Neurosci.* **27**, 278–282 (2004).

10. D. M. Wolpert, Z. Ghahramani, Computational principles of movement neuroscience. *Nat. Neurosci.* **3**, 1212–1217 (2000).

11. M. Kawato, Internal models for motor control and trajectory planning. *Curr. Opin. Neurobiol.* **9**, 718–727 (1999).

12. D. M. Wolpert, Z. Ghahramani, M. I. Jordan, An internal model for sensorimotor integration. *Science* **269**, 1880–1882 (1995).

13. L. Schulze *et al.*, Transparent *Danionella translucida* as a genetically tractable vertebrate brain model. *Nat. Methods* **15**, 977–983 (2018).

14. R. Britz, K. W. Conway, L. Rüber, The emerging vertebrate model species for neurophysiological studies is *Danionella cerebrum*, new species (Teleostei: Cyprinidae). *Sci. Rep.* **11**, 18942 (2021).

15. G. Rajan *et al.*, Evolutionary divergence of locomotion in two related vertebrate species. *Cell Rep.* **38**, 110585 (2022).

16. M. J. Lighthill, Large-amplitude elongated-body theory of fish locomotion. *Proc. R. Soc. Lond. Ser. B, Biol. Sci.* **179**, 125–138 (1971).

17. M. Gazzola, M. Argentina, L. Mahadevan, Scaling macroscopic aquatic locomotion. *Nat. Phys.* **10**, 758–761 (2014).

18. G. P. Arnold, Rheotropism in fishes. *Biol. Rev.* **49**, 515–576 (1974).

19. J. D. Murray, *Mathematical Biology: I. An Introduction, Interdisciplinary Applied Mathematics* (Springer, New York, NY, 2002), vol. 17.

20. D. Ringach, R. Shapley, Reverse correlation in neurophysiology. *Cogn. Sci.* **28**, 147–166 (2004).

21. E. Todorov, Stochastic optimal control and estimation methods adapted to the noise characteristics of the sensorimotor system. *Neural Comput.* **17**, 1084–1108 (2005).

22. T. Panier *et al.*, Fast functional imaging of multiple brain regions in intact zebrafish larvae using selective plane illumination microscopy. *Front. Neural Circuits* **7**, 65 (2013).

23. A. Baumgart, U. Kubitscheck, Scanned light sheet microscopy with confocal slit detection. *Opt. Express* **20**, 21805–21814 (2012).

24. E. A. Naumann *et al.*, From whole-brain data to functional circuit models: The zebrafish optomotor response. *Cell* **167**, 947–960.e20 (2016).

25. K. E. Fouke, Z. He, M. D. Loring, E. A. Naumann, Neural circuits underlying divergent visuomotor strategies of zebrafish and *Danionella cerebrum*. *Curr. Biol.* **35**, 2457–2466.e4 (2025).

26. K. E. Severi *et al.*, Neural control and modulation of swimming speed in the larval zebrafish. *Neuron* **83**, 692–707 (2014).

27. T. W. Dunn *et al.*, Brain-wide mapping of neural activity controlling zebrafish exploratory locomotion. *eLife* **5**, e12741 (2016).

28. J. C. Baird, E. J. Noma, *Fundamentals of Scaling and Psychophysics* (Wiley, 1978).

29. E. Henneman, Relation between size of neurons and their susceptibility to discharge. *Science* **126**, 1345–1347 (1957).

30. H. Hatze, A teleological explanation of Weber's law and the motor unit size law. *Bull. Math. Biol.* **41**, 407–425 (1979).

31. R. Portugues, M. Haesemeyer, M. L. Blum, F. Engert, Whole-field visual motion drives swimming in larval zebrafish via a stochastic process. *J. Exp. Biol.* **218**, 1433–1443 (2015).

32. L. M. Fenk, A. J. Kim, G. Maimon, Suppression of motion vision during course-changing, but not course-stabilizing, navigational turns. *Curr. Biol.* **31**, 4608–4619.e3 (2021).

33. A. J. Kim, J. K. Fitzgerald, G. Maimon, Cellular evidence for effference copy in *Drosophila* visuomotor processing. *Nat. Neurosci.* **18**, 1247–1255 (2015).

34. O. Dauzere-Peres, A. Wystrach, Ants integrate proprioception as well as visual context and effference copies to make robust predictions. *Nat. Commun.* **15**, 10205 (2024).

35. C. A. Freas, K. Cheng, The basis of navigation across species. *Annu. Rev. Psychol.* **73**, 217–241 (2022).

36. L. Clement, S. Schwarz, A. Wystrach, An intrinsic oscillator underlies visual navigation in ants. *Curr. Biol.* **33**, 411–422.e5 (2023).

37. L. Bergantin, N. Harbaoui, T. Raharijaona, F. Ruffier, Oscillations make a self-scaled model for honeybees' visual odometer reliable regardless of flight trajectory. *J. R. Soc. Interface* **18**, 20210567 (2021).

38. E. Sobel, The locust's use of motion parallax to measure distance. *J. Comp. Physiol. A* **167**, 579–588 (1990).

39. R. Portugues, F. Engert, Adaptive locomotor behavior in larval zebrafish. *Front. Syst. Neurosci.* **5**, 72 (2011).

40. M. B. Ahrens *et al.*, Brain-wide neuronal dynamics during motor adaptation in zebrafish. *Nature* **485**, 471–477 (2012).

41. D. A. Markov, L. Petruccio, A. M. Kist, R. Portugues, A cerebellar internal model calibrates a feedback controller involved in sensorimotor control. *Nat. Commun.* **12**, 6694 (2021).

42. J. G. Holman *et al.*, A behavioral and modeling study of control algorithms underlying the translational optomotor response in larval zebrafish with implications for neural circuit function. *PLoS Comput. Biol.* **19**, e1010924 (2023).

43. E. Yang *et al.*, A brainstem integrator for self-location memory and positional homeostasis in zebrafish. *Cell* **185**, 5011–5027.e20 (2022).

44. R. Tanaka, R. Portugues, Algorithmic dissection of optic flow memory in larval zebrafish. *bioRxiv* [Preprint]. https://doi.org/10.1101/2025.04.15.648832 (Accessed 19 April 2025).

45. R. D. Portugal, B. F. Svaiter, Weber-Fechner law and the optimality of the logarithmic scale. *Minds Mach.* **21**, 73–81 (2011).

46. J. Z. Sun, G. I. Wang, V. K. Goyal, L. R. Varshney, A framework for Bayesian optimality of psychophysical laws. *J. Math. Psychol.* **56**, 495–501 (1992).

47. W. Senn *et al.*, Size principle and information theory. *Biol. Cybern.* **76**, 11–22 (1997).

48. M. Ak Warzcha, Egelhaaf, Intrinsic properties of biological motion detectors prevent the optomotor control system from getting unstable. *Philos. Trans. R. Soc. Lond. Ser. B: Biol. Sci.* **351**, 1579–1591 (1996).

49. W. H. Kirchner, M. V. Srinivasan, Freely flying honeybees use image motion to estimate object distance. *Naturwissenschaften* **76**, 281–282 (1989).

50. D. Goldreich, R. J. Krauzlis, S. G. Lisberger, Effect of changing feedback delay on spontaneous oscillations in smooth pursuit eye movements of monkeys. *J. Neurophysiol.* **67**, 625–638 (1992).

51. A. Beuter, J. Milton, C. Labrie, L. Glass, S. Gauthier, Delayed visual feedback and movement control in Parkinson's disease. *Exp. Neurol.* **110**, 228–235 (1990).

52. Y. Yang, D. G. Yared, E. S. Fortune, N. J. Cowan, Sensorimotor adaptation to destabilizing dynamics in weakly electric fish. *Curr. Biol.* **34**, 2118–2131.e5 (2024).

53. H. Chao, Y. Gu, M. Napolitano, A survey of optical flow techniques for robotics navigation applications. *J. Intell. Rob. Syst.* **73**, 361–372 (2014).

54. H. Theil, "A rank-invariant method of linear and polynomial regression analysis" in *Henri Theil's Contributions to Economics and Econometrics: Econometric Theory and Methodology*, B. Raj, J. Koerts, Eds. (Springer, Dordrecht, The Netherlands, 1992), pp. 345–381.

55. G. E. Uhlenbeck, L. S. Ornstein, On the Theory of the Brownian Motion. *Phys. Rev.* **36**, 823–841 (1930).

56. Y. Benjamini, Y. Hochberg, Controlling the false discovery rate: A practical and powerful approach to multiple testing. *J. R. Stat. Soc.: Ser. B (Methodol.)* **57**, 289–300 (1995).

57. M. Kunst *et al.*, A cellular-resolution atlas of the larval zebrafish brain. *Neuron* **103**, 21–38.e5 (2019).

58. L. Demarchi *et al.*, Data and code - logarithmic coding leads to adaptive stabilization in the presence of sensorimotor delays. Zenodo. https://doi.org/10.5281/zenodo.15187167. Accessed 27 August 2025.