Clear Sky Science · en
Detection and imaging of chemicals and hidden explosives using terahertz time-domain spectroscopy and deep learning
Seeing Hidden Dangers Without Opening the Box
Imagine being able to tell what chemical is inside a sealed envelope or pill bottle—down to whether a powder is an explosive or a harmless drug ingredient—without opening it or touching it. This study shows how a special kind of "invisible light" combined with artificial intelligence can do just that, offering a safer and more precise way to spot hidden explosives and check the quality of medicines.

Why Terahertz Light Is a Powerful Detective
The researchers work in the terahertz region of the spectrum, which lies between microwaves and infrared light. Terahertz waves can pass through everyday materials such as paper, clothing, and some plastics, yet they do not carry enough energy to damage what they hit, unlike X-rays. Many chemicals absorb terahertz waves in very specific ways, leaving behind a kind of spectral fingerprint. This makes terahertz light appealing for security screening, drug manufacturing, agriculture, and food safety. But in real-world conditions—with irregular shapes, varying thicknesses, and different types of packaging—these fingerprints can become distorted, making it hard to reliably identify what is hidden inside.
Building a High-Sensitivity Imaging System
To tackle this, the team built an advanced terahertz time-domain spectroscopy system that sends extremely short terahertz pulses toward a sample and measures how they bounce back over time. They use specially engineered plasmonic nanoantenna arrays—tiny metal structures that boost the interaction between light and the detector—to generate and detect these pulses with high sensitivity and a wide bandwidth, up to 4.5 terahertz. The sample sits on a motorized stage that scans point by point, so the system records a full time-varying terahertz signal for every pixel across a small area. This reflection-based design means it can be used at a distance from an object, an important feature for practical security and inspection tasks.
Turning Raw Pulses into Chemical Maps with AI
Instead of converting the entire time trace into a spectrum, the researchers focus on the individual reflected pulses themselves. When a terahertz pulse hits a tablet on a metal holder, several echoes appear: one from the top surface, one from the metal backing, and others from internal reflections inside the material. Each important pulse carries information about the chemical it has passed through. The team developed an automatic method to extract these pulses from each pixel and then fed them into two neural networks. One network, called EdgeNet, decides where the boundaries of the sample lie. The other, ClassNet, looks at each pulse and predicts which chemical it belongs to, including the background metal if no sample is present. A final cleaning step uses simple spatial rules—checking what neighboring pixels say—to smooth out stray errors and create crisp chemical images.

Detecting Explosives, Even Under Cover
The researchers tested eight different substances: four common pharmaceutical ingredients and four explosives, including well-known military and industrial compounds. In blind tests on uncovered samples, their system reached an average accuracy of about 99 percent at the pixel level, correctly outlining the shapes of the tablets and explosive pellets. Remarkably, it also worked well on cracked and irregular samples, even though the networks were trained only on perfectly formed ones, because the essential pulse shapes stayed similar. The real stress test came when the explosives were hidden under opaque paper covers, mimicking letters, packages, or bags. Without retraining on covered samples, the system still identified the hidden explosives with an average accuracy close to 89 percent, successfully distinguishing between different explosive types within the same field of view.
From Lab Demonstration to Real-World Tool
Scanning a 12-by-12-millimeter area currently takes several minutes, but once the data are collected, the neural networks generate a full chemical map in about one second. Future versions using detector arrays instead of mechanical scanning could dramatically speed up the process and shrink the hardware. Because the method is non-destructive, contact-free, and highly specific to chemical type, it could be used to verify drug tablets, detect counterfeit medicines, and screen mail or luggage for hidden explosives. In simple terms, this work shows that combining fast terahertz pulses with deep learning can turn invisible reflections into detailed, reliable maps of what is inside an object—without ever needing to open it.
Citation: Jiang, X., Li, Y., Li, Y. et al. Detection and imaging of chemicals and hidden explosives using terahertz time-domain spectroscopy and deep learning. Light Sci Appl 15, 80 (2026). https://doi.org/10.1038/s41377-026-02190-z
Keywords: terahertz imaging, explosive detection, deep learning, noninvasive screening, chemical mapping