Electronic Nose Sniffs Out Bad or Unique Foods

A multi-sensor smell system and machine learning detects spoiled food odors and more.

What you'll learn:

  • Why replication of the sense of smell is so difficult and how bloodhounds differ from humans in meeting the challenge.
  • How a team at UC Berkeley devised a multi-sensor smell system and combined it with machine learning to create a more sophisticated system to detect spoiled food as well as other unique edibles.
  • The physical scheme they used and the ML confusion matrix that’s part of the design
  • The results they achieved in looking for spoiled foods as well as unique food items.

One of the first things children learn in school is that humans and many other animals have five basic senses: sight, sound, touch, taste, and smell. While technology has devised excellent sensors and support circuitry (amplifiers, filters) and software (if needed) for the first four, we’re very far behind with the last one of the five.

That’s not to say that we don’t have specialized smell (gas) detectors, with sensors that are tuned to a single or small group of gases such as hydrogen, various hydrocarbons, or carbon monoxide. Still, none of these sensors come close to the universal gas sensing of the human nose or, more impressive, the nose of a dog such as a bloodhound (Fig. 1). Note that a bloodhound's nose holds approximately 230 million to 300 million olfactory receptors, which is up to 40X the scent-receptor capacity of humans.

The Novel Electronic Nose Knows Spoiled Food Scents

Hoping to remedy at least a small part of the deficit, a team at the University of California Berkeley led by Carla Bassil, a fourth-year Ph.D. student in electrical engineering and computer sciences, has developed a new “electronic nose” sensing array, used in conjunction with a machine-learning program (Fig. 2).

The final packaged unit, including “gas piping,” is shown in Figure 3.

It’s focused on detecting the scents associated with spoiled food much more accurately than the human nose. It can also sniff out the presence of common food allergens, like walnuts and peanuts, which could be deadly for those with sensitivities.

Single gas sensors, like those found in the carbon-monoxide detectors in the home, are relatively straightforward to manufacture. But integrating an array of different sensing films onto a single chip is much more difficult. The team’s solution involved a new approach to construction, linkage, and data analysis.

Their artificial nose is made up of an array of 16 tiny gas sensors, each of which is sensitive to a slightly different combination of gaseous compounds. It’s like a set of digital taste buds, where each sensor on this chip responds uniquely to the various gas molecules presented to it. Each of these 16 sensors has a different sensing film on it, and it works by converting chemical reactions between the sensor surface and the gas molecule into electrical signals (Fig. 4).

Currently, most single-chip gas detection systems rely on only two to 10 different sensors, and integrating multiple devices fabricated on separate chips introduces wiring complexity and bulky form factors. High-throughput evaporation methods allow for larger arrays; however, neighboring sensors share similar materials, resulting in overlapping and ambiguous responses.

Furthermore, most studies have relied on metal-oxide semiconductors as the gas-sensitive layer, which typically requires high-temperature operation, thus restricting the platform to heat-tolerant materials.

The team overcame many of these challenges by using carbon-nanotube layers that are only around a few nanometers thick as the conducting material, rather than metal oxides. The large surface area of their array, dubbed ML-SCENT, gives them many special qualities, including being highly sensitive at room temperature. The extremely sensitive carbon-nanotube field effect transistors are stimulated through a single-step microdispensing method compatible with automated pipetting systems.

They recorded sensor response by measuring the change in current through each FET over time while grounding the gate (VG = 0 V) and applying a small 500-mV bias between the source and drain electrodes. The current pathway through the device depends on the conductivity of the functional agent.

ML Model and Training

The machine-learning-based scent program was exposed to the data from 16 different food “items,” including various fruits and nuts (strawberry, blueberry, banana, walnut, hazelnut, cashew, and peanut) and spoiled dairy and meat products. These food items produce a volatile landscape ranging from fruity esters and monoterpenes to oxidative aldehydes, heterocyclic pyrazines, and sulfur-containing compounds, underscoring that a simple sensor array can’t effectively discriminate among this extensive chemical diversity.

Using machine learning, the team trained a model to recognize the sensor response profiles associated with seven different foods. They also trained it to recognize the scent of raw chicken, milk, and eggs when they were fresh and when they had been left out at room temperature for 24 hours and 48 hours. 

The data was collected using a multiplexer, which cycled through all 16 devices at a rate of 0.25 Hz. Target gases were exposed for 95 seconds with a 185-second recovery period between pulses.

The e-nose was sensitive enough to smell 0.05 grams of isolated walnut, which is about one hundredth of an average shelled walnut. They also acknowledge that they haven’t yet tested the sensitivity of the device in environments where other gases are present, such as when walnuts are in a salad or a cake, or when spoiled foods are in a refrigerator with other foods. 

This model yielded 92.6% overall accuracy, which was calculated by dividing the number of correct predictions by the total number of predictions in the dataset (Fig. 5).

The majority of errors arose from intracategory misclassifications. The largest confusion occurred between hazelnut and peanut volatile organ compounds (VOCs), indicating some crossover between nut odorants or shared dominant compounds that elicit a similar sensor response. The prediction mistakes between 48-hour spoiled boiled egg and raw chicken again suggest similar gaseous crossover, likely due to increased levels of amines, sulfides, and thiols.

In addition to developing the prototype and the ML algorithms, Bassil and the team also built a portable version that’s linked to a smartphone (Fig. 6).

The project is described in electrical and chemical detail in their paper “Scalable multiplexed machine learning gas sensor chips for food classification” published in Science Advances.

About the Author

Bill Schweber

Bill Schweber

Contributing Editor

Bill Schweber is an electronics engineer who has written three textbooks on electronic communications systems, as well as hundreds of technical articles, opinion columns, and product features. In past roles, he worked as a technical website manager for multiple topic-specific sites for EE Times, as well as both the Executive Editor and Analog Editor at EDN.

At Analog Devices Inc., Bill was in marketing communications (public relations). As a result, he has been on both sides of the technical PR function, presenting company products, stories, and messages to the media and also as the recipient of these.

Prior to the MarCom role at Analog, Bill was associate editor of their respected technical journal and worked in their product marketing and applications engineering groups. Before those roles, he was at Instron Corp., doing hands-on analog- and power-circuit design and systems integration for materials-testing machine controls.

Bill has an MSEE (Univ. of Mass) and BSEE (Columbia Univ.), is a Registered Professional Engineer, and holds an Advanced Class amateur radio license. He has also planned, written, and presented online courses on a variety of engineering topics, including MOSFET basics, ADC selection, and driving LEDs.

Sign up for our eNewsletters
Get the latest news and updates

Comment About the Article

To join the conversation, and become an exclusive member of Electronic Design, create an account today!