"Every object above absolute zero is shouting its temperature at me in infrared. The trouble is that shiny objects lie, mirrors repeat what they see, and my own warm body whispers into every frame. My whole job is learning whom to believe."
A Radiometric AI Agent
Prerequisites
This section builds directly on the forward-model discipline of Chapter 2: a thermal camera does not measure temperature, it measures radiant power reaching a detector, and temperature is an inference from that power under assumptions that are often wrong. You need the blackbody idea at the level of a physics survey, comfort with exponentials and integrals, and the sampling and noise vocabulary of Chapter 3. The word "calibration" here means radiometric calibration (counts to temperature), which is distinct from the probabilistic model calibration of Chapter 18; keeping the two senses apart will save you confusion later. Constants used below: the Stefan-Boltzmann constant \(\sigma \approx 5.67\times10^{-8}\,\mathrm{W\,m^{-2}\,K^{-4}}\).
Why the physics comes before the model
Thermal imaging is the modality where naive deep learning fails most quietly. An RGB pixel is a fairly honest report of visible light; a thermal pixel is a tangled sum of the target's own emission, radiation the target reflects from its surroundings, and the intervening atmosphere, all filtered through a sensor whose gain drifts with its own temperature. Feed raw thermal frames to a network and it will happily learn shortcuts that evaporate the moment the ambient temperature, the surface finish, or the camera's internal heat changes. To build robust thermal AI you must know what a thermal pixel physically is, why emissivity makes two objects at the same temperature look wildly different, and how radiometric calibration turns raw detector counts into a number you can trust across scenes. This section is the physical grounding for everything that follows in the chapter: human monitoring (Section 45.2), industrial inspection (Section 45.3), and cross-modal learning against ordinary cameras (Section 45.4).
Blackbody radiation: temperature as a spectrum
What a thermal camera exploits is that every object above absolute zero emits electromagnetic radiation whose spectrum is set by its temperature. An idealized perfect emitter, a blackbody, radiates according to Planck's law, whose spectral radiance rises and whose peak shifts to shorter wavelengths as temperature climbs. Two consequences are the workhorses of the field. The total emitted power per unit area integrates to the Stefan-Boltzmann law,
$$ M = \sigma T^4, $$and the peak wavelength follows Wien's displacement law, \(\lambda_{\text{peak}} \approx 2898\,/\,T\) micrometres with \(T\) in kelvin. Why this matters operationally: a scene near room temperature (\(T \approx 300\) K) peaks around 9.7 micrometres, squarely in the long-wave infrared (LWIR, 8 to 14 micrometres) band. That is why uncooled thermal cameras are built for LWIR, and it is also why the atmosphere cooperates: LWIR sits in an atmospheric transmission window where water vapour and carbon dioxide absorb little. The competing mid-wave infrared (MWIR, 3 to 5 micrometres) band gives sharper contrast for hot targets but demands a cryogenically cooled detector, which is why it lives in defense and specialized science rather than in the wearable and automotive systems this book cares about.
How the \(T^4\) dependence shapes practice is worth internalizing: radiated power is a steep function of temperature, so small hot spots dominate a frame, and a detector integrating over a wide band collapses a rich spectrum into a single scalar per pixel. A thermal camera is, in effect, a wide-band radiometer replicated across a focal-plane array. It gives you one number per pixel, and that number is radiance, not temperature.
Emissivity: why shiny objects lie
What separates a real surface from a blackbody is emissivity \(\varepsilon \in [0,1]\), the fraction of blackbody radiance a surface actually emits at a given temperature and wavelength. Human skin, water, soil, and painted surfaces are near-blackbodies (\(\varepsilon \approx 0.95\) to \(0.98\)). Bare polished metal is the villain: aluminium can sit near \(\varepsilon \approx 0.05\). Why this wrecks naive readings is conservation of energy. For an opaque surface in thermal equilibrium, Kirchhoff's law ties emissivity to reflectivity: \(\varepsilon + \rho = 1\). A low-emissivity surface is therefore a good reflector, so most of what the camera sees off a shiny pipe is not the pipe's own temperature but the reflected radiance of everything around it, including the camera and its operator. The radiance reaching the sensor from a surface is, to first order,
$$ L_{\text{sensor}} = \varepsilon\, L_{\text{bb}}(T_{\text{obj}}) + (1-\varepsilon)\, L_{\text{bb}}(T_{\text{refl}}), $$where \(T_{\text{refl}}\) is the effective temperature of the surrounding scene. How you recover the true object temperature is by inverting this relation with an assumed \(\varepsilon\) and \(T_{\text{refl}}\); the code below does exactly that. The uncomfortable truth for an AI engineer is that a single measured radiance maps to a whole family of (temperature, emissivity) pairs. Absolute thermometry from one uncalibrated band is fundamentally under-determined, which is why thermal features that look like "temperature" are often really "apparent temperature under this scene's reflections."
A thermal pixel is apparent temperature, not true temperature
The most common failure in thermal AI is treating the pixel value as the object's physical temperature. It is not. It is the temperature a blackbody would need to produce the observed radiance, and that apparent temperature folds together the true temperature, the surface emissivity, reflected ambient radiation, and atmospheric effects along the path. Two identically hot objects, one matte and one polished, can differ by tens of degrees in apparent temperature; the same object photographed against a cold sky versus a warm wall shifts too. For classification this is often survivable, because relative contrast within a frame still tracks structure. For any task that compares absolute values across scenes, cameras, or days, unmodelled emissivity and reflection are a distribution shift you built into your labels. Treat emissivity the way Chapter 5 treats any confound: something to record as metadata, not to let leak silently into the split.
Sensor non-idealities: the microbolometer and its drift
What sits behind an uncooled LWIR pixel is a microbolometer: a tiny thermally isolated membrane whose electrical resistance changes as absorbed infrared warms it. Why it needs constant discipline is that this readout is plagued by two effects. First, fixed-pattern noise (FPN): every pixel has a slightly different gain and offset, so a uniform scene reads as a fixed texture. Second, the whole array drifts with the camera's own body temperature, because the detector has no cold reference of its own. The quality metric you will see quoted is NETD (noise-equivalent temperature difference), the scene temperature change that equals the noise, typically 20 to 50 millikelvin for a modern uncooled core. How vendors tame this is non-uniformity correction (NUC): the camera periodically flicks an internal shutter (a flat, known surface) across the array and re-estimates per-pixel offsets, which is the soft "click" you hear from a handheld thermal camera every minute or so. For AI, two lessons follow. The frame right after a shutter event has different statistics from one just before the next, and any model trained on absolute pixel values inherits the camera's thermal state as a hidden variable, exactly the kind of confound leakage-safe evaluation (Chapter 5) exists to catch.
The gas pipeline that read too cold
An energy operator (a real recurring pattern in industrial monitoring, echoing Chapter 39) deployed fixed thermal cameras to flag overheating flange bolts on a gas line. The model, trained in autumn, fired constant false alarms by midsummer and missed a genuinely hot joint in winter. Nothing was wrong with the model; the physics had been ignored. The polished stainless flanges had emissivity near \(0.15\), so the cameras were mostly reading reflected sky and structure, which swung with weather and time of day. The fix was a two-part radiometric correction: matte high-emissivity paint dots were added to each monitored joint to give an honest \(\varepsilon \approx 0.95\) patch, and the pipeline logged reflected ambient temperature from a shielded blackbody reference so apparent temperature could be converted to true temperature before the detector ever saw a pixel. Alarm precision recovered because the model finally consumed a calibrated, emissivity-corrected signal instead of raw counts.
Radiometric calibration: from counts to temperature
What radiometric calibration does is fit the mapping from raw detector counts (digital numbers, DN) to radiance, and then to temperature. Why a simple approach works is that over a modest range the microbolometer response is close to linear, so a two-point calibration against blackbody references at known cold and hot temperatures, \(T_c\) and \(T_h\), fixes a gain and offset per pixel:
$$ L(\text{DN}) = g\,\text{DN} + b, \qquad g = \frac{L_{\text{bb}}(T_h) - L_{\text{bb}}(T_c)}{\text{DN}_h - \text{DN}_c}. $$How you get from radiance back to temperature is by inverting the band-integrated Planck relation, in practice through a fitted parametric curve (many vendors use an \(R,B,F\) form) or a lookup table. When to redo it: whenever the optics, integration time, or ambient regime changes, and, for absolute work, on a schedule, because gain drifts. The snippet below carries a measured apparent temperature through the emissivity and reflection correction of the previous section, the step most casual users skip.
import numpy as np
SIGMA = 5.670374419e-8 # Stefan-Boltzmann, W m^-2 K^-4
def apparent_to_true_temperature(t_app_c, emissivity, t_refl_c):
"""Correct an apparent temperature for emissivity and reflected ambient.
Uses a broadband Stefan-Boltzmann (T^4) approximation: adequate for LWIR
scenes near ambient, where a full band-integrated Planck inversion adds
little. All temperatures in are Celsius; result in Celsius.
"""
t_app = np.asarray(t_app_c, float) + 273.15 # -> kelvin
t_refl = float(t_refl_c) + 273.15
# Measured radiance = eps * L(T_true) + (1 - eps) * L(T_refl),
# with L(T) proportional to T^4. Solve for T_true.
l_measured = t_app ** 4 # apparent body emits like T_app^4
l_true = (l_measured - (1.0 - emissivity) * t_refl ** 4) / emissivity
l_true = np.clip(l_true, 1.0, None) # guard against unphysical roots
return l_true ** 0.25 - 273.15
# A polished flange (eps=0.15) reads 24 C apparent against a 15 C sky.
print(round(float(apparent_to_true_temperature(24.0, 0.15, 15.0)), 1)) # ~63.9 C
Vendor SDKs already carry the Planck curve
The hand-rolled \(T^4\) inversion above is a teaching approximation. Production radiometric cameras ship the real band-integrated Planck fit inside their SDKs. With FLIR's file format via flirimageextractor, or a vendor SDK such as the Teledyne FLIR Science library, converting a whole radiometric frame to true temperature (emissivity, reflected temperature, atmospheric transmission, and window transmission all applied) is roughly a five-line call instead of the fifty-plus lines it takes to fit the Planck curve, manage per-pixel gain and offset, and handle the atmosphere model yourself. The library owns the calibration constants baked in at the factory; you supply object emissivity and the reflected-ambient temperature and let it do the inversion. Roll your own only when you need a correction the SDK does not expose, and validate against the SDK output when you do.
What thermal calibration means for the model
What a machine-learning practitioner should take away is a fork in the road. If your task is relative (segment a warm person from a cool background, spot the hottest bearing in a frame), raw or lightly normalized thermal is fine, and per-frame contrast normalization often beats absolute values because it cancels the camera's drifting offset. If your task is absolute (does this transformer exceed 90 C, is this forehead febrile), you must feed emissivity-corrected, calibrated temperature and you must record \(\varepsilon\), reflected ambient, and camera core temperature as covariates. Why this is a modeling decision and not just a preprocessing detail: the choice determines what counts as leakage and what counts as distribution shift. A febrile-screening model that learned on one camera's uncalibrated counts will not transfer to another unit, an effect that reappears as the RGB-thermal domain gap in Section 45.4. Like the range-Doppler-angle triad of the radar chapter (Chapter 44), thermal gives you a physically meaningful but easily misread quantity; respecting the forward model is what separates a demo from a deployable system.
Exercise: how much does emissivity matter?
Using the code above, sweep emissivity from \(0.95\) down to \(0.05\) for a surface whose apparent temperature reads 40 C against a 20 C reflected background, and plot recovered true temperature versus \(\varepsilon\). At what emissivity does the correction change the reading by more than 10 C? Then flip the reflected background to 60 C (a hot indoor scene) and repeat. Explain in two sentences why the sign of the correction flips, and state which regime, cold or hot surroundings, makes a low-emissivity object look deceptively hot.
Self-check
- A polished aluminium plate and a matte black plate sit side by side at the same true temperature. Which reads hotter to an uncorrected LWIR camera in a warm room, and why?
- Why do uncooled thermal cameras target the 8 to 14 micrometre band rather than 3 to 5 micrometres for room-temperature scenes? Name both the physics reason and the hardware reason.
- Your model's accuracy drops whenever the camera has been running for more than ten minutes. What sensor non-ideality is the prime suspect, and what routine event partially resets it?
What's Next
In Section 45.2, we put this radiometry to work on the most common thermal target of all: people. Because human skin is a near-blackbody with stable, high emissivity, it is the friendliest possible surface for absolute thermometry, which is exactly why thermal drives contactless fever screening, presence detection, and low-light pedestrian sensing. We will see how the calibration discipline from this section becomes the difference between a screening tool that works and one that quietly mislabels everyone who walks in from the cold.