Shaduf.Research preview

Projects catalogue · project page

DOOMFLY: the fruit fly brain that "plays Doom", and what the code really does

DOOMFLY feeds frames from the game Doom into a simulation of the complete male fruit fly nervous system (MaleCNS v1.0, 166,700 neurons), and four neurons chosen by the author press the turn, move and fire buttons. Nothing in it is trained. It went viral in September 2026 as "a fruit fly brain plays Doom".

  • Our grade: B connectome runs, hand-made input and output
  • Code: nftechie/DOOMFLY, MIT licence
  • Last commit: 71ecf53, (no release)
  • Checked by us: , link HTTP 200, code unchanged

Short answer

A real connectome runs and drives the game. The wiring is the measured MaleCNS v1.0 graph, uncut, and its simulated spikes really move the player. But a person designed how the picture reaches the eyes and chose the four neurons that press the buttons, after checking which ones respond to the screen.

It does not show that the fly brain plays Doom well. The author's own learning experiment did not work, and a third-party control study, doom-fly-control by gabrycina, found that a brainless autopilot, which turns, walks and shoots at constant rates, survives about as long (51.9 s against 53.3 s).

How the loop works

Each game frame is turned into signals for about 4,100 light-sensing cells, the brain model runs, and four descending neurons (cells that send commands from the brain to the body) are read as game buttons. Colours show what is measured, modelled or hand-made.

How DOOMFLY plays DoomFive stages from left to right: game frames go through a hand-made pixel map into 4,146 photoreceptor inputs; the measured MaleCNS v1.0 wiring (166,700 neurons) runs as a modelled leaky integrate-and-fire network; four hand-picked descending neurons are read out with hand-set gains as turn, move and fire; the Doom game moves the player. Stages 2 and 3 are the simulated brain. The next game frame closes the loop. Nothing is trained.The simulated brain1 · SENSEEye inputGame frame → 4,146photoreceptor inputshand-made pixel map2 · WIRINGMaleCNS v1.0166,700 neurons,25.6 M connectionsmeasured, no cropping3 · DYNAMICSLIF spikesAll edges updatedevery framemodelled, not trained4 · READOUT4 chosen neuronsDNp20 → turn,DNpe017 → move, firehand-made gains5 · ACTDoom (ViZDoom)Buttons move theplayer in the gameordinary game codeDashed line: the next game frame goes back into the eyes (closed loop). Nothing in this loop is trained. How DOOMFLY plays Doom, from top to bottom: hand-made eye input, measured MaleCNS v1.0 wiring, modelled LIF spikes, four hand-picked readout neurons, the Doom game. Closed loop; nothing is trained.The simulated brain1 · SENSEEye inputGame frame → 4,146photoreceptor inputshand-made pixel map2 · WIRINGMaleCNS v1.0166,700 neurons,25.6 M connectionsmeasured, no cropping3 · DYNAMICSLIF spikesAll edges updatedevery framemodelled, not trained4 · READOUT4 chosen neuronsDNp20 → turn,DNpe017 → move, firehand-made gains5 · ACTDoom (ViZDoom)Buttons move theplayer in the gameordinary game codeDashed: next frame (closed loop)
From DOOMFLY's code at commit 71ecf53 (doom/engine.py, doom/connectome.py, README), read by us on 28 Sep 2026.
  • Measured (connectome data)
  • Modelled
  • Hand-made by the author
  • Ordinary game code
DOOMFLY's parts, from the code we read ([direct] sources).
PartWhat it isKind
WiringMaleCNS v1.0, the whole retained graph: 166,700 neurons and 25,582,938 directed connections, no cropping. The loader accepts only this dataset (doom/connectome.py lines 98–174).Measured
Neuron modelA leaky integrate-and-fire (LIF) model, updated over all connections every frame (doom/engine.py lines 78–100).Modelled
InputFrame brightness and colour are mapped to 3,335 brightness inputs (R1–R6 cells) and 811 colour inputs (R8 cells). The README calls the pixel positions and colour responses "inferred proxies".Hand-made
Output ("bci" mode, used in the videos)Turn = right minus left DNp20 rate × 0.12; forward = DNpe017 rate × 0.4; fire = any DNpe017 spike. A code comment calls these "chosen joystick mappings, not biological interpretations or a trained game policy" (doom/engine.py lines 121–125).Hand-made
Output ("biological" mode)DNa02 for turning, DNp09 minus MDN for walking, MN9 for fire. By the author's account this readout produced zero actions.Hand-made
Learning (optional)An experimental dopamine-gated rule on 4,184 Kenyon cell → MBON11 connections; losing health sends a 200 ms pulse into 2 PPL101 cells. It failed its own tests (see below).Modelled, experimental
Trained or scripted partsNone. The readout gains are fixed, and no game state goes into the decoder.None found

Does the brain play? The controls

A control is the same test run with something removed or scrambled. If the scrambled version does just as well, the removed part was not doing the work.

A brainless autopilot plays Doom as well as the fly brainSeconds survived in DOOMFLY's Doom arena, from gabrycina/doom-fly-control@6b22922 results/a2/summary.json: DOOMFLY, real wiring 53.34 s (95% interval 49.73–56.78); Autopilot matched to the fly 51.93 s (95% interval 45.32–57.28); Best of 12 settings (spray_t1_f20) 53.44 s (95% interval 48.81–57.31); All 12 autopilot settings 5.28–53.44 s; No vision (blind) 10.46 s (95% interval 8.84–12.83); Shuffled wiring, 3 seeds 6.75 s; No connections 5.5 s (95% interval 5.24–5.76). Shuffled-wiring seeds: 5.48, 9.29, 5.48 s. A brainless autopilot matched to the fly's average commands survives almost as long as the fly brain, and the best of 12 autopilot settings slightly longer.0102030405060DOOMFLY, real wiringDOOMFLY: real FlyWire wiring (real): 53.34 s, 95% interval 49.73–56.78, n 2053.34 sn 20Autopilot matched to the flyMatched spray autopilot (no brain) (spray_matched): 51.93 s, 95% interval 45.32–57.28, n 2051.93 sn 20, no brainBest of 12 settings (spray_t1_f20)Spray autopilot setting t1_f20 (spray_t1_f20): 53.44 s, 95% interval 48.81–57.31, n 1653.44 sn 16All 12 autopilot settingsSpray autopilot setting t0_f0 (spray_t0_f0): 6.11 s, 95% interval 5.63–6.67, n 16Spray autopilot setting t0_f10 (spray_t0_f10): 8.59 s, 95% interval 7.65–9.57, n 16Spray autopilot setting t0_f20 (spray_t0_f20): 9.63 s, 95% interval 8.47–10.89, n 16Spray autopilot setting t1_f0 (spray_t1_f0): 5.68 s, 95% interval 5.35–6, n 16Spray autopilot setting t1_f10 (spray_t1_f10): 26.7 s, 95% interval 21.91–31.43, n 16Spray autopilot setting t1_f20 (spray_t1_f20): 53.44 s, 95% interval 48.81–57.31, n 16Spray autopilot setting t2_f0 (spray_t2_f0): 5.46 s, 95% interval 5.18–5.76, n 16Spray autopilot setting t2_f10 (spray_t2_f10): 9.65 s, 95% interval 8.29–10.99, n 16Spray autopilot setting t2_f20 (spray_t2_f20): 21.09 s, 95% interval 16.55–26.08, n 16Spray autopilot setting t4_f0 (spray_t4_f0): 5.28 s, 95% interval 5.06–5.53, n 16Spray autopilot setting t4_f10 (spray_t4_f10): 7.6 s, 95% interval 6.73–8.52, n 16Spray autopilot setting t4_f20 (spray_t4_f20): 11.41 s, 95% interval 9.39–13.59, n 165.28–53.44 sNo vision (blind)No vision (blind) (blind): 10.46 s, 95% interval 8.84–12.83, n 810.46 sn 8Shuffled wiring, 3 seedsShuffled wiring, seed 0 (shuf0): 5.48 s, 95% interval 4.99–5.97, n 4Shuffled wiring, seed 1 (shuf1): 9.29 s, 95% interval 7.1–11.47, n 4Shuffled wiring, seed 2 (shuf2): 5.48 s, 95% interval 4.99–5.97, n 46.75 spooled, n 12No connectionsNo connections (noconn): 5.5 s, 95% interval 5.24–5.76, n 85.50 sn 8Seconds survived (mean; whiskers: the file's 95% interval)fly brainautopilot, no brainbroken brain Seconds survived in DOOMFLY's Doom arena, from gabrycina/doom-fly-control@6b22922 results/a2/summary.json: DOOMFLY, real wiring 53.34 s (95% interval 49.73–56.78); Autopilot matched to the fly 51.93 s (95% interval 45.32–57.28); Best of 12 settings (spray_t1_f20) 53.44 s (95% interval 48.81–57.31); All 12 autopilot settings 5.28–53.44 s; No vision (blind) 10.46 s (95% interval 8.84–12.83); Shuffled wiring, 3 seeds 6.75 s; No connections 5.5 s (95% interval 5.24–5.76). Shuffled-wiring seeds: 5.48, 9.29, 5.48 s. A brainless autopilot matched to the fly's average commands survives almost as long as the fly brain, and the best of 12 autopilot settings slightly longer.Fly brain: 53.34 sAutopilot: 51.93 sBest autopilot: 53.44 s12 settings: 5.3–53.4 sNo vision: 10.46 sShuffled wiring: 6.75 sNo connections: 5.50 s0 s30 s60 sLine: the fly brain, 53.34 s
Source: gabrycina/doom-fly-control@6b22922 results/a2/summary.json (the doom-fly-control study's own results, commit 6b22922); all 5 numbers our ledger uses match the file. The matched autopilot always turns, walks and shoots at the fly brain's average rates; the 12 settings vary its turning and firing. The autopilot's constants come from the fly's average output, so this shows a constant policy reproduces the play, not that the brain does nothing. DOOMFLY's spread (sd 8.40 s, n 20) is from our ledger, recomputed from the study's per-episode file.
All 19 rows of the source file
Every number from results/a2/summary.json in gabrycina/doom-fly-control at commit 6b22922 (fetched 1 Oct 2026; sha256 3508cd4f…67e86). The study author's measurements; we read the file but did not re-run the games.
ArmKey in the fileSeconds survived (mean)95% intervalEpisodesKills (mean)
DOOMFLY, real wiringreal53.3449.73–56.782012.1
Matched spray autopilot (no brain)spray_matched51.9345.32–57.282011.75
Spray autopilot setting t0_f0spray_t0_f06.115.63–6.67161.625
Spray autopilot setting t0_f10spray_t0_f108.597.65–9.57161.625
Spray autopilot setting t0_f20spray_t0_f209.638.47–10.89161.875
Spray autopilot setting t1_f0spray_t1_f05.685.35–6160.9375
Spray autopilot setting t1_f10spray_t1_f1026.721.91–31.43166.6875
Spray autopilot setting t1_f20spray_t1_f2053.4448.81–57.311613.25
Spray autopilot setting t2_f0spray_t2_f05.465.18–5.76160.25
Spray autopilot setting t2_f10spray_t2_f109.658.29–10.99162.625
Spray autopilot setting t2_f20spray_t2_f2021.0916.55–26.08165.0625
Spray autopilot setting t4_f0spray_t4_f05.285.06–5.53160.25
Spray autopilot setting t4_f10spray_t4_f107.66.73–8.52161.5
Spray autopilot setting t4_f20spray_t4_f2011.419.39–13.59163.125
Shuffled wiring, seed 0shuf05.484.99–5.9740.25
Shuffled wiring, seed 1shuf19.297.1–11.4741.5
Shuffled wiring, seed 2shuf25.484.99–5.9740.25
No connectionsnoconn5.55.24–5.7680.375
No vision (blind)blind10.468.84–12.8382.5
Measured results and controls. None of these numbers was reproduced by us.
TestResultWho measured it
Causal-loop check (outputs/doom/bci-validation.json)Intact brain vs black pixels vs retina disconnected vs all connections removed: removing every connection stops all control. The file itself says "biologically_validated": false and "learning_demonstrated": false.The author
Learning pilot v6With learning 3.66 s mean survival, without learning 5.83 s (2 test episodes each; one run stopped at 8 s). Marked "not ready to announce".The author
First learning pilot22 episodes: zero Kenyon-cell spikes and zero changed memory connections in every training run.The author
Control study: doom-fly-controlReal wiring 53.3 s and 12.1 kills (20 runs); shuffled wiring 6.75 s (12 runs, 3 seeds); no connections 5.5 s (8 runs); blind 10.5 s (8 runs); brainless constant autopilot 51.9 s and 11.75 kills (20 runs). The real brain presses fire almost all the time (attack fraction 0.94). The same results file also holds a sweep of 12 autopilot settings; the best one survives 53.44 s, slightly longer than DOOMFLY's 53.34 s (checked by us on 30 Sep 2026; all 18 rows of that file are in the chart above, re-matched on 1 Oct 2026). How this compares with 31 other control studies: Does fly wiring help?A third party (entry doom-fly-control, grade A)

Our reading

The real wiring matters for producing any output: shuffled or disconnected brains hardly move. But the output it produces is close to a constant "turn slightly right, walk, shoot" command, and in this arena a constant command does as well.

Limits of that test

The autopilot's constants were taken from the real fly's average output, so it shows that a constant policy reproduces the behaviour, not that no brain-driven policy exists. The shuffled groups are small (4 runs per seed), and shuffled brains are much quieter overall, so a control with matched activity is still missing. The study's author says so.

This keeps DOOMFLY at grade B: the connectome runs and drives the game, with hand-made input and output, and there is no evidence of skilled play. The new control does not change the grade. See also the Doom test on Is it real?

The claim and our verdict

What DOOMFLY and its viral posts say, against what the code and controls show.
ClaimSourceVerdict
"Game frames stimulate modeled sensory neurons; activity propagates through the retained MaleCNS v1.0 wiring, and a fixed neuron-to-button interface turns, moves and fires."README, line 3Accurate as a description of the loop.
"A fruit fly brain plays Doom"The author's posts on X (6 and 9 Sep 2026) and a PC Gamer shortOverstated. The readout cells were picked because they responded to the screen; the biological readout gave zero actions; learning did not work; a constant autopilot survives about as long (third-party test). Verdict row

What you need to run it

DOOMFLY requirements and commands from its README. All untested by us.
ItemWhat the README saysOur status
PlatformLinux or macOS; Python 3.11 and a C++ compiler; Node.js 22.13 or newer for the viewer. No GPU needed.Untested
Memory and data"The full graph needs several GB of RAM and downloaded data": three MaleCNS v1.0 files listed in doom/datasets.json, checked against a lock file.Untested
Installpython3.11 -m venv .venv-neural, then pip install -r requirements-neural.txt -r doom/requirements.txtUntested
Buildpython -m doom.connectome malecns_v1, python -m doom.prepare, python -m doom.audit_data, python -m doom.build_kernelUntested
Runpython -m doom.server --model experimental-v6 --learning --port 8766 …, then the viewer in doom-ui/ with npm ci and npm run devUntested
Testspython -m pytest tests/test_doom.py tests/test_doom_reference.py tests/test_doom_live_training.py -q. The README adds: "Passing software tests is not evidence of biological validity".Untested
SpeedSlower than real time, about 0.16–0.21× (from the project's documents).Not measured by us
Online demoNone. The viewer address in the documents is a placeholder.No online demo

Known issues

  • Readout chosen after the fact. DNp20 and DNpe017 were picked after checking which cells respond to the screen. The author says these are not their natural motor roles.
  • Learning failed its vision, conditioning and survival tests (see the controls above).
  • Small controls in the repository: two seeds, one reconstructed animal, 12-second episodes, some stopped early. By the author's own notes, the first shuffled control failed its dose check.
  • The repository is a fresh snapshot with no history. We did not look at its issue tracker in this check.
  • Adoom-fly-control

    The third-party control study of DOOMFLY and doomfly-rl described above. New on 28 Sep 2026.

  • Adoomfly-rl

    A trained image encoder, a fly-wired network and a trained policy. Its own tests and the 100-game re-run in doom-fly-control show that real, shuffled and no wiring score the same. New on 28 Sep 2026.

  • Aflydoom by mutkuoz

    A separate, untrained FlyWire v783 whole-brain Doom player with shuffled-wiring and matched random-agent controls. Not derived from DOOMFLY. New on 28 Sep 2026.

  • Afly-brain-zero-shot

    The counterpoint: a whole FlyWire brain steers a simulated fly body toward targets, and scrambled wiring or disconnected turn neurons fail (2.96 against 0.34 and 0.12 poles per 10 s). Compared with the Doom test. New on 29 Sep 2026.

  • CFlyDoom by eganeganegan

    A roughly 5,000-neuron MaleCNS subgraph trained with reinforcement learning (PPO).

  • DFlyBrain-HalfLife

    Its code says its graph matches "DOOMFLY's graph manifest" and reuses the DNp20 and DNpe017 names, but by default the network is generated by the code, not loaded from MaleCNS. New on 28 Sep 2026.

Videos

Both DOOMFLY videos answered our check on 3 Oct 2026. Videos open on their original platform.

Status

DOOMFLY status on 6 Oct 2026.
FieldValue
Codegithub.com/nftechie/DOOMFLY
Last commit (default branch)71ecf53, 9 Sep 2026; unchanged since our first check
Last releaseNone
Code licenceMIT (LICENSE file)
Data licenceMaleCNS v1.0: CC BY 4.0
GitHub stars404 on 27 Sep 2026 (not re-queried since)
Link checkHTTP 200 on 6 Oct 2026
Catalogue entrydoomfly, grade B, last verified 6 Oct 2026

Sources

Search published pools, pages, reports, and evidence.