A hyperspectral camera records each pixel as a spectrum across hundreds of wavelengths. That spectrum is roughly a weighted mix of a few pure materials, such as grass, asphalt and soil. Their signatures are called endmembers, and the mixing weights are called abundances. Real materials do not have one fixed signature: leaves dry out, slopes fall into shade, soils get wet. Methods that model this endmember variability let each material's signature wander within a learned distribution. That fixes unmixing, but it creates a problem for anyone looking for rare objects. A model flexible enough to explain wet soil and shaded grass is often flexible enough to explain a painted vehicle or a tarp. The rare target gets absorbed into a "variant" of a background material and disappears.
We propose to score each patch with a variability-aware unmixing model that was fitted without that patch. The score is then split into two parts. The first is an aleatoric part, the variation one expects given known material variability and sensor noise. The second is an epistemic part, how much the model's ability to explain the patch depends on having seen the patch itself. In two sentences: natural variation of background materials is predictable from the rest of the scene, while a rare foreign material is only "explainable" when the model has fitted to it. Measuring that gap between held-in and held-out fits gives an anomaly score that resists absorption by flexible endmember models and resists masking by repeated anomalies.
Core Claim
The defining difficulty at this intersection is self-explanation, not variability modeling or reconstruction error alone. Reconstruction-based anomaly detection works by fitting a model of "normal" and reading anomalies off the residual. It fails when the model reconstructs the anomaly too. That failure is usually called the identical shortcut. In hyperspectral unmixing it takes a physical form: endmember distributions widen, or an extra endmember is extracted, to cover the target. Our claim is that cross-fitting turns this failure into the detection signal. Cross-fitting means fitting the background model on spatial folds that exclude a buffered block around each candidate patch.
Write $\log p_{\text{in}}(\mathbf{y}_n)$ for the predictive log-density of pixel spectrum $\mathbf{y}_n$ under the model fitted on the whole scene. Write $\log p_{\text{out}}^{(r)}(\mathbf{y}_n)$ for the same quantity under the $r$-th of $R$ models whose fitting excluded the block containing $n$. Each predictive density is Gaussian with mean $\hat{\mathbf{M}}\mathbf{a}_n$ and covariance $\boldsymbol{\Sigma}_n = \sum_k a_{n,k}^2 \boldsymbol{\Sigma}_k + \sigma^2\mathbf{I}$. Here $\boldsymbol{\Sigma}_k$ is the variability covariance of endmember $k$ and $\sigma^2$ is the sensor noise level. The two components of the score are then
$$U^{\text{ale}}_n = \frac{1}{R}\sum_{r=1}^R (\mathbf{y}_n - \hat{\mathbf{M}}^{(r)}\mathbf{a}^{(r)}_n)^\top (\boldsymbol{\Sigma}^{(r)}_n)^{-1} (\mathbf{y}_n - \hat{\mathbf{M}}^{(r)}\mathbf{a}^{(r)}_n),$$
$$U^{\text{epi}}_n = \log p_{\text{in}}(\mathbf{y}_n) - \frac{1}{R}\sum_{r=1}^R \log p_{\text{out}}^{(r)}(\mathbf{y}_n) \;+\; \operatorname{Var}_r\!\left[\log p_{\text{out}}^{(r)}(\mathbf{y}_n)\right].$$
$U^{\text{ale}}_n$ is the residual whitened by the expected variability. $U^{\text{epi}}_n$ is the self-influence gap plus the disagreement among held-out models. The epistemic term matches the textbook meaning of reducible uncertainty. If a pixel's material also occurs in normal background elsewhere, holding out its block changes little and the term stays small. If the material is unique to that block, the gap is large.
Relation to Prior Work
The closest work is Robust Linear Spectral Unmixing Using Anomaly Detection. It adds a sparse anomaly term with a 3D Markov random field prior to joint Bayesian unmixing. On its synthetic scene it lowers abundance error from 8.27 RNMSE for VCA-FCLS to 0.74. It motivates our work by showing that joint background and anomaly estimation pays off, and it constrains our design in two ways. It assumes static endmembers, so natural variation lands in the anomaly term. It also takes about 30 minutes on a 60×60 tile, which rules out sampling-based inference for our setting.
HELEN supplies our background model. It performs variational unmixing in which endmembers stay fixed inside small patches and vary across them, and its Gaussian variant runs up to 400 times faster than sampling-based unmixing. HELEN discards outliers as nuisance and does not ask whether its own flexibility absorbed them. Our addition is to cross-fit it and read the anomaly signal from that.
PM-LDA unmixing and Gader et al.'s Bayesian endmember likelihoods are alternative distributional endmember models. We treat them as substitutable components, not competitors.
On the uncertainty side, U²AD supplies the idea of using an epistemic/aleatoric split to steer reconstruction anomaly detection in MRI. It takes epistemic uncertainty from 10 Monte Carlo passes and aleatoric uncertainty from reconstruction error. That last equation is exactly what fails in hyperspectral scenes. A large residual there is often natural variability, nonlinear scattering or striping, not an anomaly. Our aleatoric term is instead a physically derived variance from the mixing model, and our epistemic term comes from data exclusion rather than dropout. Dropout measures how uncertain the network's weights are. It does not measure whether the background model has absorbed the target.
Black-box detectors define the strongest empirical bar. BSDM suppresses background with a diffusion model trained on pseudo-background noise. SAP uses a learned anomaly prior inside low-rank reconstruction. DVAD fuses a spatial-consistency view with a static-endmember NMF unmixing view. None of the three represents endmember variability or quantifies uncertainty.
Finally, ADBench constrains the work in two ways. Unsupervised detectors lose a median 16.43% when anomalies are duplicated, which is the masking problem our buffered folds target. Deep unsupervised detectors often lose to shallow ones, which is why we keep a simple physical model at the core.
Research Program
We will build a cross-fitted variant of Gaussian HELEN, with a Beta-prior variant as a check on physical bounds. The scene is tiled into the method's patches. We draw $R$ random partitions of patches into $F$ folds, and every held-out block is surrounded by an excluded buffer ring. For each fold we fit the scene-level endmember distribution on the remaining patches. We then score held-out patches by projecting them onto that distribution: abundances are re-estimated with sum-to-one and non-negativity constraints, and the local endmembers are re-estimated under the fold's prior.
The buffer width is the key design variable. Clustered anomalies defeat cross-fitting if copies of a target fall inside the training folds. We will therefore study detection as a function of buffer radius relative to target cluster size. We will also test a scene-adaptive buffer chosen from the spatial autocorrelation of the full-scene residual.
The compute cost is about $F \times R$ HELEN fits. With $F=5$ and $R=3$ that is roughly 15 times one fit. HELEN's speed advantage over sampling makes this practical. Distilling the cross-fitted score into a single model, as in Contextual Similarity Distillation, is a follow-up we will try only if the undistilled score proves useful.
The analysis component asks whether the two terms really separate what they claim to. To test this we build semi-synthetic scenes from Moffett Field and HYDICE Urban. Each scene receives implanted subpixel targets of foreign library materials at prevalences of 0.1% and 0.01%, in isolated, clustered and repeated configurations. Each scene also receives "hard negatives": background materials perturbed by realistic variability such as illumination scaling, moisture-like absorption-depth changes and shadow. These hard negatives should raise $U^{\text{ale}}$ but not $U^{\text{epi}}$. Because these scenes have known ground truth for both, we can test the decomposition directly, rather than only checking whether total detection improves.
A small extension uses a few labels. Following ADBench's finding that a 1% label budget favors methods that model the normal data, with a median AUCROC of 75.56% versus 60.84% for fully supervised methods, we will use a handful of labeled targets only to learn how to combine the two terms and to set the threshold at a target false-alarm rate. We will not train a classifier on them.
Baselines
The naive reference point is global RX, which ranks pixels by Mahalanobis distance from the scene mean and covariance, together with its local-window variant. These are the remote-sensing default. They will be run on identical cubes with window sizes tuned on the same validation scenes used for our method. The deep HAD review reports that they fail in complex backgrounds, and beating them is necessary but not interesting.
The in-sample variability-aware score is the ablation that isolates the key ingredient. It is HELEN fitted once on the whole scene and scored by $U^{\text{ale}}$ computed from $p_{\text{in}}$. This is a strong method in its own right: it already whitens residuals by the variability the model expects. It shares our model class, priors, patch size and tuning budget, and differs only in cross-fitting. If cross-fitting is not better than this, the proposal fails.
The physical-anomaly-term baseline is the robust Bayesian linear unmixing model of Altmann et al., scored by the posterior probability of its anomaly support. Its sampling cost limits it to the small tiles where it was evaluated, so we compare there. Its reported benchmark number is abundance error (0.74 RNMSE versus 8.27 for VCA-FCLS on its synthetic scene), not detection accuracy. We will report its detection metrics ourselves.
The strongest existing detectors on the real benchmarks are DVAD, BSDM-preprocessed 2S-GLRT and SAP. DVAD reports AUC 0.9980 on HYDICE Urban and "generally above 0.95" on its other scenes. BSDM reports a 26.39% gain for 2S-GLRT on San Diego. We found no exact SAP AUC on Lacuna, only the claim of highest AUC on San Diego, Los Angeles and HYDICE. We will rerun all three from released or reimplemented code on the same cubes, with the same band handling and comparable hyperparameter search.
Because a 0.998 AUC leaves almost no room, beating these methods means one of two things. On the semi-synthetic scenes it means a higher detection rate at false-alarm rates of $10^{-3}$ and $10^{-4}$, especially for clustered targets. On the real scenes it means matching their AUC within noise while lowering false alarms at fixed recall.
The black-box cross-fitting control is a cross-fitted spectral autoencoder with the same folds and buffers. It tells us whether the physical mixing model matters or whether cross-fitting alone does the work. A U²AD-style Monte Carlo dropout autoencoder serves as the uncertainty-decomposition baseline.
Why not just…?
Why not just use HELEN's whitened residual, since it already accounts for variability? This is the most serious threat. On isolated, spectrally distinct targets it may match our method, because there the variability model has nothing to absorb. Our argument rests on two cases. In the first, the target lies close to a widened endmember distribution. In the second, the target repeats often enough to pull the scene-level distribution or spawn an endmember, the masking effect ADBench documents for unsupervised detectors. The in-sample-versus-cross-fitted ablation on clustered and near-background implants settles this. If the gap is negligible there, we will report that cross-fitting is unnecessary.
Why not just run a strong black-box detector like BSDM or SAP? On the standard real scenes they may well be as good. Those scenes are near AUC saturation and mostly contain distinct man-made targets. They give no account of why a pixel was flagged, and nothing in BSDM or SAP prevents a stressed-vegetation patch from scoring high. The hard-negative scenes test exactly that, and so does the low false-alarm regime that matters at 0.01% prevalence. If they still win there, our contribution narrows to interpretability and we will say so.
Why not just take epistemic uncertainty from Monte Carlo dropout, as U²AD does? Dropout disagreement measures uncertainty in network weights under a fixed training set. A target included in that training set can be confidently reconstructed by every dropout sample, so dropout does not detect self-absorption. The dropout-autoencoder baseline on clustered implants checks this. If dropout variance tracks implants as well as the self-influence gap does, the data-exclusion design is not needed.
Why not just cross-fit an autoencoder and skip the physics? That is a legitimate simpler design, and it is included as a baseline. We expect the physical model to help through its explicit aleatoric covariance. That covariance lets hard negatives be predicted as normal variation, whereas an autoencoder's residual on a shaded or wet variant has no principled scale. If the cross-fitted autoencoder matches us on hard negatives, the physics is decorative.
Proposed Experiments
The decisive experiments use semi-synthetic Moffett Field and HYDICE Urban scenes with known implants and hard negatives. We vary prevalence (0.1% and 0.01%), cluster size, repeat count and subpixel abundance (from 0.1 to 1). Metrics are probability of detection at false-alarm rates of $10^{-3}$ and $10^{-4}$, the area under the low-false-alarm part of the ROC curve, and AUC for comparability.
The decomposition is tested separately. On hard negatives, $U^{\text{epi}}$ should be indistinguishable from untouched background while $U^{\text{ale}}$ rises. On implants, $U^{\text{epi}}$ should rise with how unique the material is to its block. Implants of a background material moved to a new location serve as the null: there, $U^{\text{epi}}$ should stay low.
On the real benchmarks, which are San Diego, HYDICE Urban, the Airport-Beach-Urban scenes and Texas Coast, we report AUC alongside low-false-alarm detection against all baselines. On Texas Coast we also inspect whether striping noise lands in the aleatoric rather than the epistemic term. On Villelongue, a forest scene with strong canopy variability, we count false alarms per square kilometre. This is where static-endmember methods are expected to suffer most.
Supporting checks cover the remaining design choices. We plot detection versus buffer radius, measure sensitivity to $F$ and $R$, compare the Gaussian and Beta priors, and report wall-clock cost relative to one HELEN fit.
The proposal succeeds if cross-fitting clearly beats the in-sample variability-aware score on clustered and near-background targets without losing on isolated ones. It also requires the two uncertainty terms to separate hard negatives from implants on the semi-synthetic scenes. It fails if either result is absent, whatever the real-scene AUC.
References
- Robust Linear Spectral Unmixing using Anomaly Detection
- Hyperspectral Unmixing Under Endmember Variability: A Variational Inference Framework
- Hyperspectral unmixing with endmember variability using Partial Membership Latent Dirichlet Allocation
- An Investigation of Likelihoods and Priors for Bayesian Endmember Estimation
- U2AD: Uncertainty-based Unsupervised Anomaly Detection Framework for Detecting T2 Hyperintensity in MRI Spinal Cord
- BSDM: Background Suppression Diffusion Model for Hyperspectral Anomaly Detection
- Hyperspectral anomaly detection with self-supervised anomaly prior
- Dual-View Hyperspectral Anomaly Detection via Spatial Consistency and Spectral Unmixing
- ADBench: Anomaly Detection Benchmark
- Contextual Similarity Distillation: Ensemble Uncertainties with a Single Model
- Hyperspectral Anomaly Detection Using Deep Learning: A Review