Machines that learn from examples
Nobel Prize in Physics, 2024: John J. Hopfield and Geoffrey Hinton
John J. Hopfield
born 1933 in the United States
A physicist who wandered into biology and the brain, and brought the physics of magnets with him.
Photo: Arthur Petron, CC BY-SA 4.0
Geoffrey Hinton
born 1947 in the United Kingdom
A psychologist turned computer scientist who kept working on neural networks through the years when almost everyone else had given up on them.
Photo: Arthur Petron, CC BY-SA 4.0
Your phone can unlock when it sees your face. An app can turn a sign in English into Nepali, or type what you say aloud. A photo app can find every picture you have taken of a dog, though nobody ever told it which ones they were. All of these use artificial neural networks: computer programs that learn from examples, a bit like a brain does.
In 2024 the Nobel Prize in Physics went to two scientists who, in the 1980s, laid the foundations for these machines. The surprise was the subject: the prize was for physics, because both of them built their networks from ideas that physicists use for magnets and gases.
The problem: computers that could only follow recipes
An ordinary computer program is like a recipe. The programmer writes every step: take this number, add that one, if the answer is more than 10, do this. The computer follows the steps exactly, very fast. For sums, bank accounts and timetables, that works perfectly.
But try writing a recipe for recognizing a cat. A cat can be black or ginger, sitting or running, in bright sun or half hidden behind a door. What rule tells a cat from a dog, or from a cushion? Nobody can write down all the steps. Yet a small child, after seeing a few cats, can point at a new one and say “cat!” almost every time. The child learns from examples, not from rules.
Could a machine learn the same way? To find out, scientists turned to the thing that does it best: the brain.
Why is it so hard to write an ordinary program that recognizes cats in photos?
Pick an answer to see why.
How the brain stores things
Your brain is made of about 86 billion nerve cells, the neurons Grade 9: Neuron or nerve cell. Each neuron is joined to thousands of others. When a neuron is active, it sends signals to the neurons it is joined to, and the joins, called synapses, can be strong or weak.
In 1949 the Canadian psychologist Donald Hebb suggested how learning might happen: when two connected neurons are active at the same time, again and again, the connection between them gets stronger. It is often put as “neurons that fire together, wire together”. That is why practice works: each time you say your times tables, the same neurons work together, and the path between them gets easier.
An artificial neural network copies this idea in a computer. It has nodes in place of neurons, each holding a number (for example 0 or 1, off or on), and connections between the nodes, each with a strength. The network learns by changing the strengths of its connections. This is called training.
Why it was hard
- Bad news in the 1960s. At the end of the 1960s, some mathematical results seemed to show that simple networks of this kind could never do anything really useful. Many researchers lost interest.
- Slow, small computers. In 1982 Hopfield’s first network had just 30 nodes. He tried 100, but that was too much for his computer.
- Too little data. A network learns from examples, and it needs a great many. Before the internet, there were no millions of photos to learn from.
What they did, step by step
Hopfield: a memory shaped like a landscape
John Hopfield was a physicist in the United States. He had first used physics to study problems in biology, such as how molecules in our cells work. At a meeting about the brain, he became fascinated by how neurons work together.
- An idea from magnets. Hopfield knew how magnetic materials such as iron work. Each atom in iron behaves like a tiny magnet, and each tiny magnet pushes its neighbors to point the same way as itself Grade 8: Molecular theory of magnetism. Physicists describe how such a material settles with a number they call its energy: the material moves towards the arrangement with the lowest energy.
- 1982, the network. Hopfield built a network in which every node is joined to every other node. Each node is 0 or 1, like a pixel in a black-and-white picture. To store a picture, the strengths of the connections are set so that this picture has a low energy.
- Remembering. Now give the network a damaged copy of the picture: some pixels wrong, or part of it erased. The network goes through the nodes one by one. For each, it asks: would the energy go down if this pixel changed? If so, the pixel changes. It keeps going until no change lowers the energy any further. By then, it has usually rebuilt the original picture.
- Many pictures at once. The same network can store several different pictures, and it finds the stored one that is closest to what it was given.
Hopfield compared this to a ball rolling in a landscape of hills and valleys. Each stored picture is the bottom of a valley. Drop the ball anywhere, and it rolls down into the nearest valley and stops. This is called an associative memory: you give it part of something, and it brings back the whole. You do it yourself when a smell brings back a whole memory, or when you search for a word you rarely use and find it from one that sounds a bit like it.
Hinton: a machine that finds its own patterns
Geoffrey Hinton had studied psychology in England and artificial intelligence in Scotland. He wanted machines that learn as people do: by seeing examples, and sorting them into their own groups, without being told the rules. Working in the United States with Terrence Sejnowski, he started from Hopfield’s network.
- An idea from gases. A gas is made of countless molecules, rushing about. Nobody can follow each one. But statistical physics can say how likely each arrangement of the molecules is, and so predict the gas’s pressure and temperature. In the 1800s, the Austrian physicist Ludwig Boltzmann worked out the rule: arrangements with lower energy are more likely.
- 1985, the Boltzmann machine. Hinton used Boltzmann’s rule in a network with two kinds of nodes: visible nodes, where examples are shown to the network, and hidden nodes, which no one sees and which the network uses to find its own patterns. Running the machine, its nodes keep changing, but some patterns come up more often than others.
- Training by examples. To train it, the strengths of the connections are changed, little by little, until the example pictures are the patterns that come up most often. After training, the machine can recognize a new example of the same kind, just as you can tell your friend’s brother is related to your friend before anyone tells you. It can also make new patterns like the ones it learned from: it was one of the first generative networks, the kind that makes pictures or text.
The first Boltzmann machines were slow. But Hinton kept improving them and kept working with neural networks in the 1990s, when most researchers had given up on them again. In 1986 he and two colleagues, David Rumelhart and Ronald Williams, showed how networks with hidden layers could be trained using a method called backpropagation: when the network gets an answer wrong, every connection is nudged a little in the direction that would have made the answer less wrong. In 2006 he and his colleagues found a way to train networks with many layers, by first training each layer with a Boltzmann machine. Networks with many layers are called deep networks, and training them is deep learning.
In a Boltzmann machine, what are the hidden nodes for?
Pick an answer to see why.
How it works now: deep networks
Around 2010, two things changed: the internet gave networks millions of examples to learn from, and computers became thousands of times faster. In 2012 a deep network built by Hinton and two of his students, Alex Krizhevsky and Ilya Sutskever, won a contest to name the objects in photos (dogs, cars, mushrooms) by a huge margin. Within a few years, deep networks were everywhere.
A deep network passes information through many layers of nodes:
- The input layer takes in the raw data, for example the brightness of every pixel of a photo.
- The hidden layers pick out features, step by step: the first layers find edges and lines, the later ones find shapes, and the last ones whole objects.
- The output layer gives the answer: “dog”, or the next word of a sentence.
Training such a network is like tuning a radio with millions of knobs. Show it a picture of a ४ labeled “four”. If it answers “seven”, every connection is nudged slightly towards the right answer. After millions of examples, it gets nearly all of them right, even ones it has never seen. Banks in the United States were already using networks like this to read the handwritten numbers on cheques in the 1990s.
In your life today
- Your phone. Face unlock, voice typing, the camera that brightens a dark photo, apps that translate signs: all use neural networks.
- Search and suggestions. Photo search, the videos suggested to you, spam filters in email.
- Chatbots. AI assistants that write text are huge deep networks trained on enormous amounts of writing.
- Science. Physicists used neural networks to sift the data that found the Higgs particle in 2012, to clean the signals of gravitational waves, and to search for planets around other stars. Neural networks also predict the shapes of proteins, which won the Nobel Prize in Chemistry in 2024.
What came next
- The laureates’ own worries. Both laureates have spoken about the dangers of AI. In 2023 Hinton left his job at Google so that he could speak freely about its risks: false information, people losing jobs, and machines that might one day be hard to control. When the prize was announced, Hopfield said that he, as a physicist, was very unnerved by something that has no control.
- Energy. Training the biggest networks uses huge amounts of electricity. Your brain does far more on about 20 watts, less than an old filament light bulb. How it manages that is not yet understood.
- The open question. A trained network gets answers right, but nobody can easily say why: its knowledge is spread through billions of connection strengths, not written as rules. How can we look inside a network and understand what it has learned? Physicists, computer scientists and brain scientists are all working on it.
In your science books
- Grade 8: artificial intelligence and its uses; the molecular theory of magnetism, the tiny magnets that gave Hopfield his idea.
- Grade 9: neurons and the human nervous system.
- Going further: how memory is stored, and why energy spreads out, the counting of molecules behind Boltzmann’s rule.
Learn more
- The Nobel Prize’s own explanation: They used physics to find patterns in information (nobelprize.org).
- The laureates’ Nobel lectures: Hopfield and Hinton.
The official reason
The prize was given “for foundational discoveries and inventions that enable machine learning with artificial neural networks.”
