7/2026: Thermal Mapping & Analysis from JPG Images (R Script for HT-18)
High-end thermal cameras typically save data in proprietary radiometric formats that embed temperature information directly into every pixel. However, many accessible and widespread devices—such as the HT-18 thermal camera—export thermal images as standard JPEGs, burning the color palette and temperature limits right into the frame.
To overcome this limitation, I developed an R script that converts a standard JPG image into an interactive, queryable thermal map:
- Palette extraction & smoothing: Samples the colorbar directly from the photo and removes JPEG compression noise via spline smoothing in the CIELAB color space.
- Continuous interpolation: Uses Inverse Distance Weighting (IDW) alongside CIEDE2000 color distance metrics to eliminate banding ("staircase" artifacts) and compute smooth, realistic temperature gradients.
- Interactive inspection: Renders a Plotly-based visualization that preserves the camera's original aspect ratio and exact colors, allowing you to hover over any point on the image to inspect its precise temperature in °C.
The complete R script and documentation are available on GitHub (Read_Thermal_Image_Camera) .
L'odv La Panchina, impegnata a cardioproteggere il territorio cilentano con l'installazione di defibrillatori semiautomatici e corsi di primo soccorso BLSD