Musculoskeletal simulation of limb movement biomechanics in Drosophila melanogaster

Pembe Gizem Ozdil, Chuanfang Ning, Jasper S. Phelps, Sibo Wang-Chen, Guy Elisha, Auke Ijspeert, Pavan Ramdya

Researchers have developed the first biologically detailed, 3D musculoskeletal model of the Drosophila melanogaster (fruit fly) leg. By integrating high-resolution X-ray imaging with reinforcement learning, the team created a simulation that bridges the gap between neural activity and physical movement. Their work reveals that just three muscle "synergies" can explain most fly behaviors and that passive joint properties act as secret weapons for stable locomotion.

In the world of neuroscience, Drosophila is a superstar because we have nearly complete maps of its central nervous system (the connectome) and its exoskeleton. However, there has been a glaring "missing link": a physically grounded model of its muscles.

Without knowing how motor neurons actually pull on the skeleton via muscles, it is impossible to fully understand how the brain orchestrates complex behaviors like walking or grooming. Previous fly models often used "abstract" joint controllers (like simple motors) that ignored the messy, compliant, and redundant nature of real biology. This paper fills that gap, providing a vital tool to study how biomechanics and neural control interact.

Overview of the modeling pipeline, from anatomical reconstruction to 3D pose kinematics.

Methods and Datasets

The authors built a comprehensive pipeline to turn raw anatomical data into a functional simulation across two major platforms: OpenSim (for biomechanical analysis) and MuJoCo (for fast physics and machine learning).

  1. Anatomical Reconstruction: The team used structural data from public X-ray datasets alongside a new custom synchrotron radiation $\mu$CT dataset to capture different leg postures. They segmented 15 muscle-tendon units (MTUs) in the fly's foreleg.
  2. Hill-type Muscle Models: They implemented standard Hill-type models, which account for active contraction, passive stretch, and damping.
  3. Parameter Optimization: Because measuring the "max force" of a microscopic fly muscle is incredibly difficult, they used a genetic algorithm (NSGA-II) to tune unknown parameters until the model's movements matched real-world 3D pose data from behaving flies.
  4. Imitation Learning: To test if the model could "learn" to move, they trained neural network policies using Proximal Policy Optimization (PPO) to mimic recorded fly kinematics from tethered flies performing forward walking and antennal grooming.
Detailed anatomical dataset and the resulting OpenSim model showing specific thoracic and leg muscle groups.

Key Insights and Results

  • Behavioral Replay & Anatomical Correction: The model successfully recapitulated complex 3D kinematics for both walking and grooming in OpenSim. During this process, researchers discovered that the fly's leg doesn't extend in a straight line but follows a "parenthesis-like" curvature due to the bridge-like structure of the trochanter segment—a crucial detail missing in previous models.
  • The Power of Three: Using Non-negative Matrix Factorization (NMF), the researchers found that just three muscle primitives (synergies) explain over 90% of the variance in muscle activity. This suggests the fly's brain doesn't have to control every muscle independently; it likely uses "presets" for different phases of movement. While some muscles were "task-invariant" across behaviors, others were highly specialized (e.g., certain coxal muscles acted as flexors during grooming but had broader roles during locomotion).
  • Passive Physics as a "Prior": In the MuJoCo simulations, adding passive joint properties like stiffness and damping significantly accelerated reinforcement learning. Biomechanical models with these properties outperformed "armature-only" models, achieving higher rewards in fewer training steps. Essentially, biology "hard-codes" stability into the joints, reducing the computational load on the brain to achieve smooth motion.

Limitations and Future Work

The biggest hurdle for this type of modeling remains data scarcity. Many physiological parameters, such as exact contraction velocities, had to be estimated or optimized because they are nearly impossible to measure in a living fly.

Additionally, the reinforcement learning agents were trained "in the air" (suspended), omitting complex body-environment interactions like friction and ground adhesion. The authors suggest that future work integrating in vivo muscle imaging and more complex contact physics will be necessary to fully realize a "virtual fly" that can navigate a simulated world as deftly as a real one.

Check out the project website for simulation videos and source code: https://gizemozd.github.io/fly_mimic

Summary updated

BibTeX
@inproceedings{ozdil2026musculoskeletal,
  author = {Pembe Gizem Ozdil and Chuanfang Ning and Jasper S. Phelps and Sibo Wang-Chen and Guy Elisha and Auke Ijspeert and Pavan Ramdya},
  title = {{Musculoskeletal simulation of limb movement biomechanics in Drosophila melanogaster}},
  booktitle = {International Conference on Learning Representations},
  year = {2026},
  url = {https://openreview.net/forum?id=6lEjX1getx},
}
Figure