← All articles

datasetmultispectral imagingthermal imagingobject recognition

A photo collection of desk objects in visible, near-infrared and thermal light

An ordinary camera sees what our eyes see, and that is not always enough. In fog or poor light it struggles, and it misses properties of an object that other kinds of light reveal. We built JU-VNT, a collection of 7,800 photographs of everyday desk objects taken in three kinds of light: visible, near-infrared and thermal. We labelled the images, lined them up with each other, and tested standard neural networks on them.

Why three kinds of light

Each spectrum shows something different. Visible light gives colour, texture and shape. Near-infrared (NIR) light lies just beyond the red end of the visible range. NIR cameras have been found to work in fog where ordinary cameras cannot, and an infrared lamp can light a scene at night. It also copes better than visible light with glass, which bends and reflects light. Thermal cameras record heat, so they do not depend on the light source at all, although they are expensive and can struggle in warm surroundings.

Top row: two visible-light photos, a glass paper weight beside a blue-capped bottle, and a hexagonal glass block. Bottom row: the same two scenes as grey-scale near-infrared images.
Top: visible light. Bottom: near-infrared. The paper notes that the near-infrared images are less affected by the refraction of light through glass.Source: Fig. 5 of the paper.

Datasets that pair two spectra exist, for example visible with thermal for street scenes (Table 1). The paper states that there are none on these three spectra together. Having three cameras also brings practical complications, such as different lenses, viewpoints, sharpness and noise, which the dataset also carries.

How the photos were taken

We used a Nikon D3200 for visible light, a Watec WAT-902H2 camera with a filter that blocks everything below 830 nm for NIR, and a FLIR A655SC for thermal. The three cameras stood on tripods of different heights so that none blocked another, looking at a table covered in white paper, with an infrared lamp on the ceiling above it.

Three cameras on tripods side by side: a FLIR thermal camera on the left, a Nikon DSLR in the middle and a small near-infrared camera on the right.
The camera rig: thermal, visible and near-infrared, from left to right.Source: Fig. 1 of the paper.

There are 25 objects, made of wood, plastic, glass, ceramic, metal and other materials. They include a stapler, scissors, a key, a cup, a pair of spectacles and a power bank (Table 2). We rotated each object in 45 degree steps to get 8 views. That gives 600 images of single objects. We did the same for every pair of the 25 objects, which gives 7,200 more.

The three cameras do not see the table from the same spot, so their images do not line up. Before each set we took one extra shot with three vertical metal markers around the objects. The marker tips gave us three matching points. From those, an affine transformation (a mix of rotation, scaling and skewing) maps the NIR and thermal images onto the visible one, and we then tidied the result by hand. All three images are cropped with one window, found from the NIR image. We also give the objects' bounding boxes, in XML, and sort the images into folders by class.

Top row: a visible-light photo of a whiteboard marker and a photo of three small wooden blocks. Bottom row: the thermal images of the same scenes, a faint grey rod for the marker and one bright block among duller ones.
Top: visible light. Bottom: thermal. The printing on the marker disappears, and one of the blocks glows brighter than the others.Source: Fig. 6 of the paper.

What the benchmarks show

We trained four standard networks, ResNet18, Inception-V3, DenseNet-121 and MobileNetV2, on a random 3:1 train and test split. We tried each spectrum alone and every combination, with and without random flips of the images as data augmentation.

Single objects were the easier task. Several networks reached 98 to 100% on RGB or NIR alone (Table 3). Pairs were harder. Thermal alone did poorly: averaged over the four networks it reached 65.41% without augmentation, against 93.85% for RGB (Table 4). The paper explains that when two objects have similar temperatures, the network sees one blob.

On pairs of objects, with augmentation, RGB plus NIR averaged 97.52% over the four networks. Adding thermal as a third input gave 95.61% (Table 4).

The paper reads the results as a challenge. Its benchmarks show that standard networks are not suited to handling more than two spectra, and it offers JU-VNT as a testbed for that problem. The best score on pairs was 99.00%, from MobileNetV2 on RGB plus NIR with augmentation (Table 4).

Four bar charts of accuracy for each spectrum combination and each of four networks. The top row is single objects and the bottom row is pairs of objects; the left column is without augmentation and the right is with augmentation. Thermal alone is low for pairs.
Accuracy for every spectrum combination and network. Top row: single objects. Bottom row: pairs. Left: without augmentation. Right: with augmentation.Source: Fig. 8 of the paper.

Results in more detail

Table 3 of the paper holds the single-object results. Each row is one choice of input, either one spectrum or several joined together, so "rgb nir" means visible plus near-infrared. Each column is one network, and every value is the percentage of test images classified correctly. The table below shows the runs without data augmentation, plus the row means for the runs with augmentation in the last column. The last row averages over the rows. Data augmentation here means randomly flipping the training images to give the network more variety of views. The data were split at random, three parts for training and one for testing. The RGB images went in as three channels, and the NIR and thermal images, being grey-scale, went in as one.

Accuracy (%) for single objects, without augmentation, with the mean with augmentation in the last column
SpectrumResNet18Inception-V3DenseNet 121MobileNetV2MeanMean with augmentation
rgb72.0098.0096.0076.0085.5091.00
nir78.0096.00100.0096.0092.5093.00
thermal92.0092.0092.0089.0091.2591.50
rgb nir98.0098.0098.0096.0097.5097.75
nir thermal92.00100.0098.0096.0096.5093.50
rgb thermal94.00100.0098.0097.0097.2594.00
rgb nir thermal90.0098.0098.0099.0096.2597.50
Mean88.0097.4397.1492.71--
Table 3, as printed, with the four per-network columns of the with-augmentation runs left out. Higher is better. Source: Table 3 of the paper.

With single objects, no one input won everywhere. Without augmentation, ResNet18, Inception-V3 and MobileNetV2 did better on the combined spectra than on any single one, while DenseNet-121 did best on NIR alone. With augmentation, Inception-V3 reached 100.00 on both RGB and NIR (Table 3). Augmentation helped MobileNetV2 a great deal, for example from 76.00 to 98.00 on RGB. It worked against some networks on the combinations with thermal: ResNet18 on NIR plus thermal went from 92.00 to 82.00 (Table 3). The paper's reason is that thermal adds little for general learning when there is only one object in the picture, so whenever RGB or NIR is left out, augmentation hurts.

Table 4 has the same layout for pairs of objects, which is the harder task. Here are the runs without augmentation.

Accuracy (%) for pairs of objects, without augmentation
SpectrumResNet18Inception-V3DenseNet 121MobileNetV2Mean
rgb90.5892.6795.6796.4893.85
nir83.0877.7590.3394.4286.40
thermal59.9251.5062.2587.9965.41
rgb nir89.5891.5097.2597.8094.03
nir thermal81.7581.9286.9290.6485.31
rgb thermal87.8392.7596.1795.7493.12
rgb nir thermal92.7587.5095.8395.8392.98
Mean83.6482.2389.2094.13-
The left half of Table 4, as printed. Higher is better. Source: Table 4 of the paper.

Thermal alone is the lowest row for every network, and Inception-V3 has the lowest mean of the four networks. MobileNetV2 has the highest mean and held up best on thermal images, with 87.99. These are the runs with augmentation.

Accuracy (%) for pairs of objects, with random flips as augmentation
SpectrumResNet18Inception-V3DenseNet 121MobileNetV2Mean
rgb93.4294.6798.1795.3295.39
nir82.5875.9192.2594.5186.31
thermal64.3352.9271.3392.5370.28
rgb nir96.1796.8398.0899.0097.52
nir thermal81.9279.9291.0893.9486.71
rgb thermal93.4289.0897.9295.0493.86
rgb nir thermal97.0891.1797.9296.2795.61
Mean86.9982.9392.3995.23-
The right half of Table 4, as printed. Higher is better. Source: Table 4 of the paper.

With augmentation the mean of every network went up. For example, DenseNet-121 went from 89.20 to 92.39 and MobileNetV2 from 94.13 to 95.23 (Table 4). The paper says that augmentation was more effective on pairs than on single objects. The combinations with thermal scored below RGB with NIR for most networks. The paper puts it this way: when two objects have similar thermal intensity the network sees them as a whole, while NIR helps to tell different materials apart, which helps when there are several objects.

Discussion

We built JU-VNT as a testbed, and the benchmarks give it a job. Most earlier multispectral datasets use two spectra, such as RGB with NIR or RGB with thermal. Our results show how hard it is to use three. The standard networks we tried are not suited to handling more than two spectra, so we see the combination of all three as a challenge that readers can take up.

The pattern in the results has a simple cause in our view. Thermal images record temperature, so printing on an object disappears and, as the paper notes, different objects with a similar colour can show different intensities. That is useful when objects differ in how they hold heat, and a handicap when two neighbouring objects are about equally warm. NIR copes better with glass, and it helps the network tell materials apart. RGB with NIR therefore worked well for most networks.

The limits are stated in the paper. The registration is approximate. An affine transformation can rotate, scale and skew an image but not shift it, so we refined each result by hand, and the cameras see the table from slightly different angles, which makes a pixel-exact match technically impossible. The objects are ordinary desk items photographed indoors on white paper.

We see the collection as a starting point. Besides classifying one or several objects and locating them, the paper suggests translating images from one spectrum to another and generating images that simulate an object's rotation. The paper calls JU-VNT one of the largest multispectral datasets of its time, with 7,800 images, and the dataset is on GitHub.

Sources

The figures and tables listed here are taken from the paper cited at the top of this page; the numbers quoted in the text come from it too.

  • Figures: Fig. 5, Fig. 1, Fig. 6, Fig. 8
  • Tables: Table 1: earlier multispectral datasets; Table 2: the 25 object classes and their materials; Table 3: single-object accuracy of each network and spectrum combination; Table 4: object-pair accuracy of each network and spectrum combination

Acknowledgements

This work is supported by the project sponsored by SERB (Government of India, order no. SB/S3/EECE/054/2016, dated 25/11/2016), and was carried out at the Centre for Microprocessor Application for Training Education and Research, CSE Department, Jadavpur University. The authors thank the team that made the collection of the dataset possible. Image capturing: Subham Jana and Puspendu Khan. Data preprocessing: Tathagata Bandyopadhyay, Anwesha Sen and Soupik Chowdhury. Data annotation: Osman Goni, Priyam Sarkar, Rounak Dutta, Supriyo Das, Debarati Roy and Ujjwal Misra. Benchmarks: Somenath Kuiry and Bodhisatwa Mondal. Special thanks to Somenath Kuiry for his contribution during revision.

Cite the paper

Swarnendu Ghosh, N Das, P Sarkar, M Nasipuri (2021). JU-VNT: a multi-spectral dataset of indoor object recognition using visible, near-infrared and thermal spectrum. Multimedia Tools and Applications, Vol. 80, No. 12, pp. 17807–17826 · Springer.

BibTeX
@article{ghosh2021ju,
  author    = {Ghosh, Swarnendu and Das, N and Sarkar, P and Nasipuri, M},
  title     = {{JU-VNT:} a multi-spectral dataset of indoor object recognition using visible, near-infrared and thermal spectrum},
  journal   = {Multimedia Tools and Applications},
  volume    = {80},
  pages     = {17807--17826},
  publisher = {Springer},
  year      = {2021},
  doi       = {10.1007/s11042-020-10302-z}
}