Professor
Professor

Deep Learning A to Z · Fruit Fly Special from the Fruit Fly Lab

Welcome! This is the Fruit Fly Lab. Here we put a real fruit fly brain and an artificial neural network side by side, and learn by pressing buttons and changing the numbers. Follow the three parts in order and you'll travel from the senses to memory, and all the way to the wiring diagram.

Meet the lab crew

Press the expression buttons to change their mood.

Professor

Professor

In charge of explaining. Turns any tough formula into a single picture. When excited, purple sparks fly from their hands

Assistant

Assistant

In charge of experiments. Runs code all night, and cries along when the results lose to the baseline

Fly Researcher

Fly Researcher

The only crew member with a real brain. Always has something to say when people and AI claim to imitate its brain

Lab Robot

Lab Robot

In charge of data. Gives short reports when calculations are done. Its screen face is its mood

Research map — three parts in order

Just follow the numbers. Each part can be read on its own, but later parts reuse ideas from earlier ones.

Senses and learningMemory and circuitsWiring diagram simulation

Special 1 Exploring the Fruit Fly Brain

Follow the paths a fruit fly uses to smell, see and recognize, and watch a neural network grow one step at a time.

Try this · Release a rule-based fly and a learning fly into the same arena

Special 2 The Memory Retrieval Paper

Unpacks, with nicknames and pictures, a paper showing that a learned memory can only be retrieved by passing through one neuron in an instinct center.

Try this · Switch off the convergence neuron and see what happens to the memory score

Special 3 A Fruit Fly Brain in Minecraft

Takes apart a Minecraft mod that runs the real fruit fly wiring diagram as is. The number of learned weights: zero.

Try this · Mix bitterness into sugar and watch the moment the proboscis neuron shuts off

A day in the lab

Scenes from between the parts.

Sleep and forgetting — Special 2
Turning neurons on with light — Special 2
The Assistant's paper storm — Special 1
The Robot's data beam — Special 3

How to get the most out of it

Just press buttons

Every figure is changed with buttons. There are no boxes for typing numbers (except the Trainer's drawing pad).

Underlined words

Hover over or tap a yellow dotted underline to see its meaning. The same dictionary appears in each part's glossary (C).

Run it yourself in Colab

Download Code 1 (NumPy) and Code 2 (PyTorch) as notebooks from Common section A of each part.

For instructors and tutors

Use the Educator TIP (F) at the bottom of each part together with the Answer Key for Educators.

Phones work too

On narrow screens, figures and buttons stack vertically. You draw on the Trainer's drawing pad with your finger.