ChemoMAE: Self-Supervised Spectral Representation Learning Reveals Chemical Heterogeneity in Historical Wood

Ryuji Yamaguchi, Miyuki MatsuoarXiv 2026

TL;DR

Centuries-old wooden temples don't rot uniformly; sunlight, rain, and internal aging leave invisible, overlapping chemical fingerprints across the timber. This paper introduces ChemoMAE, a self-supervised Transformer that reads near-infrared light bounced off wood cross-sections to map out these hidden chemical states—without needing human-labeled training data. By turning raw light spectra into crisp anatomical and degradation maps, it gives conservationists a new lens to understand how ancient materials survive or decay over centuries.

What Problem Does This Paper Address?

When restoring a historical timber building, engineers face a tough question: is an old wooden beam still structurally sound, or has rot crept too deep inside? Over centuries, ultraviolet light breaks down surface polymers, rainwater washes away soluble compounds, and moisture sneaks in through cracks or insect holes, causing internal aging.

Standard point-by-point chemical tests tell you what is happening at one tiny spot, missing the broader spatial picture. Near-infrared hyperspectral imaging (NIR-HSI)—where every pixel in a photo captures a full spectrum of light—can scan an entire cross-section at once. However, analyzing this data across different beams is tricky: there are no "ground-truth" labels for centuries-old chemical states, wood chemistry naturally varies between tree species and growth rings, and traditional linear tools like Principal Component Analysis (PCA) struggle to untangle complex, nonlinear chemical relationships.

Methods

To compare diverse wood samples on equal footing, the authors built ChemoMAE, a self-supervised Transformer based on a masked denoising task:

  • Standard Preprocessing: Each pixel's spectrum (256 wavelength channels) undergoes a Standard Normal Variate (SNV) transformation, giving it zero mean and constant length—essentially placing every spectrum onto the surface of a high-dimensional sphere.
  • Geometry-Aware Perturbations: Before masking, the authors inject synthetic noise (Tangent Gaussian Noise) and slight wavelength shifts (Fractional Shift) designed specifically to stay on that mathematical sphere without reintroducing baseline scale variations.
  • Masked Reconstruction: Half of the spectral patches are hidden. The Transformer encoder compresses the visible, noisy patches into a 16-dimensional unit-length vector, and a simple linear decoder tries to reconstruct the clean, original values of the missing bands. Because a single chemical bond vibrates across multiple NIR wavelengths (multicollinearity), the bottleneck is forced to learn deep inter-band chemical relationships.
  • Spatial Segmentation & Evaluation: Pixel representations are grouped using spherical k-means clustering (Cosine-KMeans) and mapped back to their 2D coordinates. Crucially, zero spatial information is given to the model during training or clustering. To evaluate the maps without ground-truth labels, the authors introduce Local Label Agreement (LLA)—a chance-corrected metric measuring how often neighboring pixels land in the same cluster, testing the physical intuition that real wood anatomy and decay form continuous regions.
ChemoMAE architecture and unsupervised segmentation workflow

Datasets

The authors collected and imaged transverse cross-sections of 49 historical wood specimens taken from structural timber members across several historical buildings in Japan.

Pseudo-RGB images of seven historical wood specimens across taxa

The dataset spans seven wood taxa (including Japanese cypress, pine, zelkova, and cedar) and diverse architectural roles (such as pillars, eaves supports, and bearing blocks) with varying histories of outdoor weathering, dampness, and insect damage. Each specimen was scanned at ~0.19 mm spatial resolution across wavelengths from 913 to 2518 nm.

Key Insights and Ideas

  • Withholding space to test chemistry: If a model only sees individual pixel spectra—completely blind to where pixels sit next to each other—yet still paints crisp growth rings and weathered outer rims on unseen wood samples, you have strong evidence it learned genuine material states rather than image artifacts.
  • Better cluster separation $\neq$ better physical maps: PCA achieved higher cluster separation scores (cosine-silhouette) in latent space than ChemoMAE, yet produced noisier spatial maps. Picking an evaluation metric tied to a physical hypothesis (spatial continuity via LLA) prevented the authors from being misled by geometry alone.
  • Unmasking overfitting in unsupervised learning: A standard denoising autoencoder (without masking) produced great spatial maps on the specimens it was trained on, but fell apart on held-out specimens. Cross-validation proved essential even without labels.
  • Two mechanistic models of wood decay: Cross-referencing the AI-generated maps with NIR absorption bands led to two physical hypotheses: (1) Internal degradation, where slow aging loosens polymers around cellulose microfibrils, and intermittent water ingress washes away sugars while wetting/drying cycles locally snap cellulose chains back into tighter hydrogen-bonded order; and (2) Surface degradation, where rainwater carries acidic photodegradation products from sunlit outer layers inward along wood grain and insect galleries, triggering secondary acid hydrolysis beneath the surface.

Key Results

  • Superior generalization on unseen wood: In 5-fold cross-validation at $K = 8$ clusters, ChemoMAE (with perturbations) achieved the highest out-of-fold spatial coherence (LLA-5 = 0.519), outperforming raw spectra (0.450), PCA (0.458), and an unmasked denoising autoencoder (0.341). It beat PCA on 41 out of 49 held-out specimens and led across all tested cluster counts ($K = 2$ to $14$).
  • Suppressing scanner artifacts: While masking drove almost all of the quantitative LLA gains, adding the sphere-preserving spectral perturbations dramatically stabilized cluster assignments (dropping the Label Flip Rate from 0.269 to 0.0891) and erased vertical streak artifacts caused by the line-scan camera.
  • Consistent chemical signatures: Across 41 specimens, regions mapped to internal aging showed lower amorphous and crystalline cellulose O–H band curvature than sound interior wood in nearly every case (40–41/41 specimens), while weathered rims consistently tracked expected millimeter-scale UV penetration depths.

Limitations and Future Work

  • Surface finish effects: The 49 historical samples did not have standardized sanding or surface finishing, meaning physical surface roughness could not be cleanly separated from pure wood chemistry in the spectral derivatives.
  • Ambiguous states: NIR spectra reflect molecular environments rather than exact constituent quantities, leaving some ambiguities—for instance, aged interior wood can spectrally resemble naturally lignin-rich "compression wood" in softwoods.
  • Experimental validation: The proposed internal and surface degradation models remain mechanistic hypotheses. As future work, the authors suggest using ChemoMAE's spatial atlas to guide targeted physical tests—such as measuring X-ray diffraction crystallinity, deuterium-exchange accessibility, and water-extract pH across mapped transition boundaries.

Summary updated

BibTeX
@misc{yamaguchi2026chemomae,
  author = {Ryuji Yamaguchi and Miyuki Matsuo},
  title = {{ChemoMAE: Self-Supervised Spectral Representation Learning Reveals Chemical Heterogeneity in Historical Wood}},
  year = {2026},
  eprint = {2611.34581},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2611.34581},
}
Figure