Skip to content

Why we dream from a computational lens

Computational neuroscience studies have revealed the functional role of dreams in helping us preserve memories.

Shamay Agaron
Shamay Agaron
3 min read
Why we dream from a computational lens

You’ve probably heard that the brain consolidates your memories when you sleep, but have you ever wondered how this happens? It turns out that dreams are a crucial part of this process, and not for the reasons you might think. Computational neuroscience studies have revealed the functional role of dreams in helping us preserve memories.

Giraffe, Child, Nature, Dream, Fantasy, Feeding, Boy

As a bit of background, there are two types of long-term memory:

  • episodic memory: involves the actual details of an event, situation or experience (e.g. where did I park today)
  • semantic memory: related to meaning, knowledge, significance, or relationships (e.g. where do I usually park?)

The brain is responsible for both remembering specifics (episodic) and extracting generalities over multiple experiences (semantic). To support these incompatible goals, there are two separate brain circuits for learning: hippocampus and neocortex.

Episodic information is initially encoded in the hippocampus, where it can be stored rapidly without interfering with existing knowledge. This turns into semantic memory when it’s slowly consolidated to the neocortex, which contains all your accumulated memories and experiences.

Behavioral evidence suggests that we consolidate new experiences from the day while we sleep. In an experiment, participants were taught new information and split into two groups — Group 1 was deprived of sleep the same night whereas Group 2 didn’t sleep the following night. After two days, the participants were tested and those from Group 1 performed worse even though Group 2 was more tired. This demonstrated that sleep plays a crucial role in same-day memory consolidation. The findings extends to declarative learning, perceptual learning, and skill learning.

How does the memory consolidation process work?

In short, the theory is that the hippocampus replays memories back to the neocortex during sleep. Researchers tried to model the integration of new info, but ran into a problem — all the old info was being immediately unlearned in the simulations.

Consider the paired associates learning paradigm. Here’s how it works:

  1. A set of paired associations, AB, are learned (ex: window-reason, bicycle-garbage)
  2. A new set of associations, AC, are learned for half of the old pair (ex: window-telephone, bicycle-desk)
  3. Both sets of associations, AB and AC, are tested (ex: window - ?, bicycle - ?)

In humans, we see a modest and gradual loss of memory for AB set as the number of AC set learning trials increases. This is expected, since half of the AC associations are overwriting the previously learned AB associations in memory.

The neural network model, on the other hand, was able to initially learn the AB set but the AB associations are completely overwritten when it starts to learn the AC set. In other words, the model wasn’t able to integrate the new info as well as humans can.

This puzzled researchers for a long time, until they discovered that the problem was the training regimen they used. Their assumption was that the hippocampus simply replayed new memories to the neocortex, but the simulations showed that this heavily interfered with older knowledge.

It turns out that the brain uses a slightly less efficient method called interleaved training, where new info is regularly jumbled with old and inconsistent knowledge. While this means that learning is slightly slower, it allows for the new info to coexist with the older knowledge in memory.

Imagine this process as slowly sifting flour (new info) into the dough of old knowledge.

Premium Photo | Close-up of baker sifting the wheat flour through sieve  over dough

This is where dreams come in. While we’re sleeping, our brain cycles between slow-wave (deep) sleep, where recent memories are integrated, and REM (dreaming) sleep, where connections damaged by new learning are revisited and repaired. Without dreams, old memories are more likely to be overwritten by new info being integrated.

Dreams are a byproduct of your brain bringing up random old information to aid in the memory consolidation process.

I always found it fascinating that the role of dreams was discovered only after trying to model the brain’s neural architecture and running into same problems that nature did.

I also wanted to thank my professor, Jon Cohen, for his brilliant lecture that inspired this post.