Skip to main content

We can learn from fruit fly brains to improve our search algorithms

We can learn from fruit fly brains to improve our search algorithms


Nature knows what it’s doing

Share this story

The key to better computer algorithms might be found in the brains of fruit flies, researchers say.

Computers are always doing searches that involve comparing similar things. Think about when you go on YouTube to listen to Coldplay and it recommends a song by Radiohead. (This is called a “similarity search.”) Fruit flies do a version of this to survive: if they learned that the smell of an orange indicates food, they will know in the future that a similar smell is also food they can eat. In a study published today in the journal Science, scientists found that the way their brains do this is different from how most computer algorithms do it — and by using the fly method, we can make our computer programs better.

Imagine your computer is comparing the Coldplay and Radiohead songs. There are a lot of attributes to look at: genre, speed, gender of the singer, instruments. A computer takes all of these attributes and then boils it down to, say, 10, a more manageable number. They then assign a tag called a “hash” to each of these items. When it does a similarity search, it compares the hashes instead of going through all the attributes.

Flies do the opposite, says study co-author Saket Navlakha, a computer scientist at the Salk Institute for Biological Studies. When fruit flies smell something for the first time, 50 neurons fire in a unique combination. Instead of simplifying these neurons to 10, they expand this information. The fly brains send the information throughout the brain to 2,000 neurons.

Why would this make them faster at identifying similar smells? Let’s say you have 50 people (like the 50 neurons) and you want to find the similarities between them. If you put them in a small room, they’re going to be crowded in on each other and it’ll be hard to organize them, explains Navlakha. But if you take the 50 people and spread them out in a big field, it’s easier to identify information. Spreading the information around helps the fly brain give a more unique label to each smell. Then, it stores the top 5 percent of these 2,000 neurons as “hashes.”

Navlakha and his colleagues tested this expansion approach on three datasets. They kept the computing power the same, but judged how accurate the old versus new methods were, and found that the fly method was 30 to 50 percent more accurate.

“It’s nice to see new insights coming from neuroscience being used to influence computer algorithms,” says Kristin Branson, a computational biologist at the Howard Hughes Medical Institute who was not involved with the study. “This is one of the reasons we’re studying the brains and doing computations at the circuit level — to try to find the better algorithms that evolution has found and incorporate them.” The team has proven that the method works well for their sets, so the next step should be for them to try the technique on more datasets, says Branson.

Though some existing algorithms do use a method similar to the fly’s, not all of them do. Next, Navlakha would like to try this out with other datasets and perhaps work with industry partners.