As everyone knows, a good sense of direction is needed to successfully navigate the world. In mammals, this ‘sense’ involves neurons called head-direction cells. Each such cell becomes most active when the animal faces a particular direction relative to landmarks in its environment. Together, the cells’ activity indicates which direction the animal is facing in at any given moment. In 2015, it emerged that fruit flies, which are much easier than mammals to study experimentally, have strikingly similar cells, called heading neurons1. Writing in Nature, Fisher et al.2 and Kim et al.3 now build on this discovery to tackle a decades-old problem: how does this type of neuron respond to the locations of landmarks in a manner that is stable enough to be reliable, but flexible enough to allow adaptation to new environments?

To give an example of the problem, imagine emerging from a subway station onto a crowded street. If you are a regular visitor, a glance around is all you need to be on your way. However, if you have never been to this station before, you might need a moment to orient yourself. You take note of surrounding street signs, shops and monuments. Before long, you have your bearings and can set off in the right direction.

Read the paper: Sensorimotor experience remaps visual input to a heading-direction network

This example highlights two challenges for the brain’s directional system. First, it must stably indicate direction in familiar environments: returning to the same station should call the same orientation to mind. Second, it must have the flexibility to learn new configurations of landmarks, even when similar landmarks have been seen before — the particular configuration of street signs at the new station must be learnt, even though you may have seen similar street signs in other places.

The neural mechanisms that underlie these abilities in flies are a beautiful example of form following function. The insects’ heading neurons (also known as E–PG, or compass, neurons) are arranged in a ring (Fig. 1) that corresponds to the 360° of possible directions in which the fly can face1, sometimes called heading angles. Because of inhibition between neurons, only one heading angle can be indicated at one time, providing the fly with an unambiguous signal. Of note, rather than always aligning their activity to a cardinal direction such as north, heading neurons realign their activity arbitrarily when the fly enters a new environment. The heading neurons receive input from visual ring neurons, which are activated by visual cues at particular orientations relative to the fly, and from internal cues about self-motion.

Figure 1 | Neurons in the central complex of the fruit-fly brain, tagged with fluorescent proteins. The central complex includes a ring-like structure called the ellipsoid body that contains heading neurons. These cells correspond to all the possible directions in which the fly can face, providing the insect with a compass-like signal that it uses to navigate. Two studies2,3 have revealed how flies orient themselves in familiar environments and adapt to new ones, thanks to signalling to heading neurons from visual ring neurons, which originate in the eyes (not shown).Credit: Tanya Wolff

Fisher et al. set out to test whether and how the connections between visual ring neurons and heading neurons change with experience, using a range of experimental techniques (many of which are possible only in fruit flies). They implemented a virtual-reality (VR) system in which the fly walked on a floating ball. An array of lights around the fly flashed on and off in concert with the animal’s movements4, providing visual cues to enable the fly to orient itself. The authors then measured inputs from visual ring neurons to heading neurons as the flies explored this virtual environment. They also used genetic techniques to inhibit the activity of visual ring neurons.

These experiments revealed that individual heading neurons are inhibited by visual ring neurons that are activated by visual cues at specific angles relative to the fly. Because of the specificity of this pairing, the visual input reinforces the directional preference of the heading neurons. This work solves the problem of how the brain can transform visual input into a stable directional signal in a familiar environment — the first of the challenges in our subway scenario.

Next, Fisher et al. tested how heading neurons can adapt when their environment changes. They presented flies with two identical visual cues, separated by 180° — an ambiguous environment in which a half turn produces the same visual cue as a full turn. The flies’ heading neurons, which can represent only one heading angle at a time, flipped between being preferentially activated by two opposing heading orientations.

After the flies were returned to the one-cue world, the relationship between visual input and the activity of the heading network as a whole sometimes changed by 180°. The strength of visual inputs to heading neurons also changed, but only in neurons that were active during the two-cue period.

This finding shows that new associations can form between visual ring neurons and heading neurons in new environments. However, simple visual changes are not enough. Instead, there must be a coordinated activation of the upstream visual ring neuron and downstream heading neuron. This leads to a decrease in the strength of the inhibitory synaptic connection between them, so that the heading neuron becomes less sensitive to inhibition by the visual ring neuron — a phenomenon known as associative plasticity.

Read the paper: Generation of stable heading representations in diverse visual scenes

In a complementary experiment, Kim et al. presented flies with VR scenes derived from natural images, moving a step closer to naturalistic conditions. They then stimulated heading neurons in arbitrary orientations relative to the visual cues the fly was receiving, thereby altering neurons’ preferred heading directions. After this stimulation period, the offsets between heading-neuron activity and visual input remained intact, demonstrating the capacity of the system to learn new visual–heading associations. Even partial views of a scene, when paired with stimulation, caused global changes in the activity of the heading-neuron network. This reveals a useful property of the network for our subway set-up: it enables you to orient yourself at a new station without having to survey all 360° of the scene.

But the system’s flexibility could have a downside — if synapses can change, can they also be erased? Kim et al. asked whether the heading network can ‘remember’ multiple scenes. First, they found that presenting flies with different scenes elicited different heading-neuron direction preferences, which varied from fly to fly. But, crucially, these preferences were stable for a given scene for each fly, even when the scene was presented as part of a ‘slide show’ of multiple different scenes. This shows that the fly’s heading network can store and retrieve memories of scenes. The authors conclude their paper by developing theories that predict what types of scene can be simultaneously stored and what kinds of rule allow scenes to be learnt without existing memories being erased.

Together, these studies rigorously establish the ability of the fly’s heading network to learn through associative plasticity. Future work should explore the memory capacity of the system. A key question is whether flies and other insects use memories of complex scenes for navigation, or rely more heavily on celestial cues such as the Sun5. Other types of sensory input, such as light polarization, also probably have a role in anchoring insect heading representations, and need to be taken into account. In addition, molecular and cellular work will be needed to uncover the synaptic-plasticity rules at work in the system and to determine whether they match Kim and colleagues’ theoretical prediction. Finally, this work generates hypotheses that should be tested in other species, because many properties of the fruit fly’s heading neurons are similar to those of mammalian head-direction cells.

So, although it might not have mastered the subway, the fruit fly has deepened our understanding of the neural mechanisms that underlie our sense of direction. A rich landscape of further research awaits.