Cross-Domain Industrial Fault Detection by Causal Mechanism Monitoring
Summary
The paper proposes CMR-Mamba, a causal mechanism monitoring method using Mamba state-space models for unsupervised industrial fault detection, focusing on coupling faults and evaluated on electromechanical, hydraulic, and cyber-physical systems.
View Cached Full Text
Cached at: 08/18/26, 09:58 AM
# Cross-Domain Industrial Fault Detection by Causal Mechanism Monitoring
Source: [https://arxiv.org/html/2608.14666](https://arxiv.org/html/2608.14666)
\\setcopyright
ifaamas\\acmConference\[AAMAS ’26\]Proc\. of the 25th International Conference on Autonomous Agents and Multiagent Systems \(AAMAS 2026\)May 25 – 29, 2026 Paphos, CyprusC\. Amato, L\. Dennis, V\. Mascardi, J\. Thangarajah \(eds\.\)\\copyrightyear2026\\acmYear2026\\acmDOI\\acmPrice\\acmISBN\\affiliation\\institutionDeakin University\\cityWaurn Ponds, Victoria\\countryAustralia\\orcid0000\-0001\-6548\-311X\\affiliation\\institutionDeakin University\\cityWaurn Ponds, Victoria\\countryAustralia\\orcid0000\-0003\-1807\-430X\\affiliation\\institutionDeakin University\\cityWaurn Ponds, Victoria\\countryAustralia\\orcid0000\-0002\-6199\-9685\\affiliation\\institutionDeakin University\\cityWaurn Ponds, Victoria\\countryAustralia\\orcid0000\-0002\-6639\-6824
###### Abstract\.
Unsupervised fault detection in industrial systems is dominated by reconstruction\-based methods that monitor individual sensor marginal distributions\. This misses coupling faults, where the physical relationship between sensor groups breaks while marginal statistics remain normal\. Such faults evade marginal monitoring and persist as latent failures, with direct consequences for system reliability and safety\. We propose CMR\-Mamba \(Causal Mechanism Representation Mamba\), which trains per\-domain Mamba state\-space encoders on healthy data\. A causal cross\-modal predictor regularises these encoders so that the effect\-channel manifold reflects the normal cause\-to\-effect coupling\. Anomalies are scored bykk\-nearest\-neighbour distance on this manifold or by the mechanism residual between the observed and the causally predicted effect embedding\. We evaluate CMR\-Mamba on electromechanical \(Paderborn bearings\), hydraulic \(ZeMA\) and cyber\-physical \(SWaT\) coupling\-fault domains\. Ablations establish two findings\. First,kk\-NN manifold scoring, rather than the encoder family, is the dominant source of gain over reconstruction\-error scoring, improving baselines by up to\+0\.42\+0\.42AUROC and exceeding the gain from causal regularisation\. Second, aggregate AUROC is saturated by easy faults that any strong method solves, so the methods separate only on the low\-separability subset\. There CMR\-Mamba leads the evaluated baselines on Paderborn artificial defects and on SWaT stealthy attacks, which keep every sensor inside its normal range and which marginal methods detect only at chance\. CMR\-Mamba therefore offers an interpretable and consistently competitive approach to coupling\-fault detection across mechanical, hydraulic and cyber\-physical systems\. Code and data are available at[https://anonymous\.4open\.science/status/CMR\_Mamba\_MFD\_1177](https://anonymous.4open.science/status/CMR_Mamba_MFD_1177)\.
###### Key words and phrases:
Anomaly detection; Machinery fault detection; Mamba state\-space models; Causal mechanism monitoring; Unsupervised learning; Multi\-sensor fusion
\\settopmatter
printacmref=false\\setcopyrightnone
## 1\.Introduction
Rotating machinery such as motors, pumps, and turbines forms the operational backbone of modern industrial systems, from manufacturing plants to power generation facilities and transportation infrastructure\. Undetected faults in these machines can escalate from minor defects to catastrophic failures, resulting in unplanned downtime, safety hazards, significant economic losses, and, in severe cases, loss of lifeneupane2025comprehensive;lei2020applications\. The development of reliable and timely fault detection methods has consequently become a central concern in both the research community and industrial practicelei2020applications;zhao2019deep\.
Fault detection has progressed from classical signal\-processing methods to data\-driven deep learning and, where fault labels are scarce, to unsupervised anomaly detection\. The dominant unsupervised approach is reconstruction\-based in which a model trained on healthy data flags any sample it cannot reconstruct well\. These methods share a structural blind spot, because they monitor the marginal distribution of each signal and answer the question “Does this signal look normal?”\. They therefore cannot see faults that change the physical relationship between signals while each individual signal still looks normal\.
Consider a bearing developing a micro\-crack, one of the classic sub\-surface fatigue mechanisms catalogued for rolling bearingsiso15243\. In the initial stages, the overall vibration amplitude may remain within the normal operating range, and a reconstruction model trained on healthy vibration would report low error\. What has changed, however, is the coupling between the motor current and the resulting vibration\. In a healthy machine, the vibration response is tightly coupled to the electrical drive current through well\-understood physics\. Electromagnetic torque generates mechanical motion, which produces vibration through the bearing and housingrandall2011rolling\. A micro\-crack alters this transfer function, introducing new resonance frequencies and changing damping characteristics, without necessarily changing the amplitude envelope of either signal in isolationrandall2011rolling;smith2015rolling\. The marginal distributions appear unchanged\. The causal mechanism has shifted\. An analogous failure mode arises in hydraulic systems\. A pump developing internal leakage continues to draw similar motor power and to produce pressure at a similar level, yet the transfer function linking motor power input to pressure output changes measurably\. The same electrical driving force now produces less hydraulic work, because a portion of the fluid flow bypasses internally\. A reconstruction\-based anomaly detector trained on pressure signals would report low reconstruction error because the pressure waveform retains its characteristic shape\. The fault is invisible in the marginal signal but detectable in the conditional relationship between motor power and pressure outputhelwig2015hydraulic\. Multi\-sensor fusion approaches have shown promise in exploiting cross\-channel informationneupane2025multisensor, yet they still operate within the reconstruction or classification methodology rather than explicitly monitoring inter\-channel coupling\. Transitioning these passive monitoring tools into autonomous maintenance agents requires explicitly modelling these structural and causal dependenciesneupane2026fault\.
This observation motivates the central objective of the present work\. Rather than asking “Does this signal look normal?”, we ask “Does the physical relationship between these signals still follow the healthy pattern?” We answer it with the Causal Mechanism Representation Mamba \(CMR\-Mamba\) framework, which rests on two design choices that are independent and each beneficial on its own\. First, the domain\-specific encoders are trained only on healthy data, with reconstruction as the primary loss and an auxiliary cross\-channel coupling regulariser that shapes the latent manifold around the physically grounded causal direction between sensors\. A cross\-channel predictor learns the normal coupling function from a designated cause channel to a designated effect channel, with the direction fixed by known physicsrandall2011rolling;helwig2015hydraulic\. In electromechanical systems, motor current drives vibration\. In electro\-hydraulic systems, motor power drives pump pressure\. The framework is agnostic to the physical domain as long as this causal direction is grounded\. The second choice concerns how anomalies are scored\. At inference, a sample is scored bykk\-nearest neighbour \(kk\-NN\) distance to a bank of healthy embeddings in the effect encoder’s latent space, rather than by reconstruction error\. When a fault alters the causal mechanism, the effect embeddings are displaced from the healthy manifold even when the marginal signal statistics look normal\. We argue that a class of mechanism\-shift faults cannot be detected by any method operating on the marginal distributions alonebouman2025autoencoders, yet remains geometrically isolable through manifold monitoring of these causally\-regularised representations\.
Realizing this framework at the scale of industrial data presents a computational challenge\. Industrial sensors often operate at high sampling rates\. The Paderborn University \(PU\) bearing dataset, for example, records vibration and current signals at 64 kHz, producing 64,000 data points per second per channellessmeier2016condition\. Processing such long sequences is essential for capturing the full spectral and temporal structure of fault signatures, yet Transformer\-based architectures incur𝒪\(L2\)\\mathcal\{O\}\(L^\{2\}\)computational cost that renders direct processing of raw high\-frequency sequences impracticalvaswani2017attention;gu2024mamba\. Even at considerably lower sampling rates, sequence lengths remain substantial\. The ZeMA Hydraulic System datasethelwig2015hydraulicused in our cross\-domain evaluation records motor power and pump pressure at 100 Hz over 60\-second operational cycles, producing 6,000 data points per cycle\. Efficient sequential architectures are therefore valuable across a broad range of industrial sensing rates\. The integration of selective state\-space architectures with causal relational modelling provides the efficient spatiotemporal perception required for autonomous industrial diagnosticsneupane2026fault\. To address this, we employ Mambagu2024mamba, a selective state\-space model that achieves𝒪\(L\)\\mathcal\{O\}\(L\)complexity while maintaining strong long\-range modelling capability\. This enables our per\-channel encoders to operate directly on raw waveforms at the native sampling rate of each dataset without downsampling or time\-frequency transformation, preserving diagnostic information that would be lost through conventional preprocessing\. Recent works have begun exploring Mamba for fault detection in supervised settingsyu2025mamba;xia2025bmtmand for relation\-based fault detectionchen2025shrinkage, but none have combined state\-space encoders with causal mechanism regularisation in the unsupervised setting, nor demonstrated that the geometric properties of the resulting manifold enable superior anomaly detection compared to reconstruction\-based scoring\.
The principal contributions of this paper are as follows:
1. \(1\)A causal\-mechanism architecture that decouples encoder training from anomaly scoring\.We train encoders with reconstruction loss as the primary objective plus a causal coupling regulariser, and score anomalies bykk\-NN manifold distance rather than reconstruction error\. An ablation shows the two changes are independently beneficial and compound when combined\. The encoders are built from Mamba state\-space blocks, whose𝒪\(L\)\\mathcal\{O\}\(L\)complexity lets us process raw waveforms at each dataset’s native sampling rate without time\-frequency preprocessing, across sequences from1,5001\{,\}500to8,1928\{,\}192tokens and with weight sharing across physically identical channels\. The backbone is an adopted component and an enabling choice rather than a contribution of this work\.
2. \(2\)Primary validation and ablation on the Paderborn bearing dataset\.CMR\-Mamba detects the industrially relevant real\-damage bearing faults at 0\.944 AUROC under 15\-fold leave\-bearing\-out cross\-validation, and is competitive with the strongest baselines on the aggregate \(0\.880 overall, up to a 0\.930 per\-fold oracle upper bound\)\. An ablation crossing encoder type \(plain reconstruction versus CMR regularisation\) against scoring rule \(reconstruction error versuskk\-NN manifold distance\) shows thatkk\-NN scoring is the dominant factor \(\+0\.129\+0\.129AUROC\) and CMR regularisation adds a consistent further gain \(\+0\.013\+0\.013\)\.
3. \(3\)Cross\-domain transfer to a hydraulic system, and a further cyber\-physical test\.We apply CMR\-Mamba without core redesign to the ZeMA hydraulic dataset, swapping the electromechanical pair \(motor current to vibration\) for the electro\-hydraulic pair \(motor power to pump pressure\), repeating the full ablation and analysing domain\-specific differences in the optimal regularisation\. The framework is further evaluated on the SWaT cyber\-physical water\-treatment testbedgoh2016swatin the results, where the causal mechanism residual is the best of the evaluated detectors of stealthy attacks that keep every sensor within its normal range and that marginal methods detect only at chance\.
## 2\.Background and Related Work
Traditional approaches to machinery fault detection have relied on signal processing techniques applied to vibration and acoustic measurements\. Methods such as envelope spectrum analysis, empirical mode decomposition, and time\-frequency representations including the short\-time Fourier transform and continuous wavelet transform have formed the foundation of vibration\-based diagnostics for decadesrandall2011rolling\. While effective for well\-characterised fault signatures under controlled conditions, these methods depend heavily on expert knowledge to select appropriate frequency bands and interpretive thresholds, limiting their scalability across diverse machine types and operating environmentslei2020applications\.
The past decade has witnessed a significant shift toward data\-driven approaches, driven by advances in deep learning\. Convolutional neural networks operating on time\-frequency imagesbai2023application, recurrent architectures modelling temporal dynamicszhao2017lstm, and more recently Transformer\-based models capturing long\-range dependenciesding2023stationaryhave progressively improved diagnostic accuracy\. However, the vast majority of these methods are supervisedneupane2025comprehensive, requiring labelled examples of each fault type during training\. In practice, labelled fault data is scarce, expensive to collect, and inherently machine\-specific, i\.e\., a classifier trained on one motor’s inner race faults may not generalise to a different motor or even to the same motor under different operating conditionsneupane2024comparative;zhao2019deep\. This fundamental limitation has created a critical bottleneck for scalable industrial deployment\.
This scarcity of labelled data has motivated growing interest in unsupervised anomaly detection, where models are trained exclusively on healthy operational data and must flag deviations from learned normality at test timeruff2021unifying\. The dominant paradigm within this category is reconstruction\-based detection\. An autoencoder or similar generative model is trained to compress and reconstruct healthy signals\. At test time, samples that yield high reconstruction error are flagged as anomalousruff2021unifying;malhotra2016lstm\. This principle underpins a broad family of methods, ranging from LSTM autoencodersmalhotra2016lstmand variational autoencoderspark2018multimodalto adversarial reconstruction frameworks such as USADaudibert2020usadand TranADtuli2022tranad, and the state\-of\-the\-art Anomaly Transformerxu2022anomaly, which detects anomalies through discrepancies in learned self\-attention association patterns\. One\-class classification methods such as Deep SVDDruff2018deepoffer an alternative by learning a compact representation of normality without explicit reconstruction, though the underlying principle, characterising the healthy data distribution, remains fundamentally the same\. Recent efforts have also explored semi\-supervisedneupane2024comparativeand reinforcement learning\-basedneupanelearningformulations to reduce reliance on fault labels, yet the reconstruction paradigm continues to dominate the unsupervised settingruff2021unifying;bouman2025autoencoders\.
Despite their widespread adoption, reconstruction\-based methods share a fundamental limitation, i\.e\., they operate on the marginal distribution of sensor signals\. Recent work by Bouman and Heskesbouman2025autoencodersformally proved that autoencoders can perfectly reconstruct out\-of\-distribution data through three distinct failure mechanisms, namely identity shortcuts, correlated low\-level features between in\-distribution and out\-of\-distribution data, and small latent\-space norms for anomalous samples\. These results hold for both linear and nonlinear autoencoder architectures and represent structural limitations inherent to the reconstruction\-based framework, not isolated edge casesbouman2025autoencoders\. Complementary work on graph\-level anomaly detection has documented the “reconstruction flip” phenomenon, wherein anomalous structures paradoxically yield lower reconstruction error than normal oneskim2024rethinking\. By learning to reconstruct each channel’s output, or the joint output across channels, these methods implicitly answer the question “Does this signal look normal?” This framing is effective when faults produce visible deviations in signal amplitude, frequency content, or statistical properties\. However, there exists an important class of faults, particularly early\-stage mechanical defectsiso15243, that alter the relationship between sensors before affecting any individual sensor’s marginal behaviour\.
A large body of work applies deep learning to machinery fault detection and diagnosiszhang2017new;zhang2020deep;neupane2024advanced;jiang2025health\.
As mentioned earlier, most of this work is supervised and therefore depends on labelled fault examples\. The unsupervised and label\-efficient setting that we target is comparatively underexploredneupane2024comparative;pang2021deep;neupanelearning\. Recent literature has actively explored this field, spanning deep transfer learning for bearing fault diagnosiswang2020multiscale;wang2023online, physics\-informed diagnosis under domain shiftlu2024dpicen, semi\-supervised remaining\-useful\-life assessment of rotating machineryzhuang2022semisupervised, and change\-point detection coupled with prognosticsshi2021dual\. Building on these foundations, several recent studies map directly onto the specific components of our proposed approach\. On the causal side, structural\-causal and anti\-causal formulations have been developed for domain\-generalised and mechanism\-oriented fault diagnosisli2026causalgraph;guo2024cis2n;zhang2024anticausal\. On the architectural side, selective state\-space \(Mamba\) encoders have increasingly been applied to industrial prognostics and diagnosishan2026mamba\. Related work also covers multi\-sensor fusion that couples motor\-current and vibration signalsguo2023multisensor, interpretable cross\-machine condition monitoringyan2026unified, weakly\-supervised health\-indicator derivation for early fault detectionhu2025diffusion, and joint fault diagnosis with remaining\-useful\-life predictionqi2025multitask\.
Our method also draws on causal structure learning and on efficient sequence models\. Classical causal discoveryspirtes2000causation;zheng2018dagsand recent surveys of causal methods for time seriesassaad2022surveyshow how directed dependencies can be recovered from observational data, neural Granger causalitytank2022neurallearns such dependencies with deep networks, and causal representation learning frames the problem at the level of mechanismsscholkopf2021causal\. On the architectural side, structured state\-space modelsgu2022efficiently;gu2024mambaprovide linear\-time sequence modelling that makes raw high\-frequency monitoring tractable\. These two lines have developed separately\. Causal discovery and causal representation learning are used mainly to recover or explain structure, and state\-space models are used mainly to make long sequences affordable\. The work that does bring causal ideas to fault detection is largely supervised or aimed at domain generalisation\. What has not been done is to use a learned cause\-to\-effect mechanism as the anomaly score itself in a label\-free setting\. This study does this by letting a physically grounded cause\-to\-effect predictor regularise a linear\-time state\-space encoder, and by scoring anomalies through the geometry of the resulting manifold rather than through reconstruction error\.
## 3\.Methodology
This section develops the CMR\-Mamba framework generically for a cause channel𝐱\\mathbf\{x\}and an effect channel𝐲\\mathbf\{y\}, covering the encoder, the causal predictor and training objective, and the anomaly scoring rule that operate on that pair\. The architecture is invariant across domains, with only the input boundary and the channel groupings changing, and each such difference is stated with its physical motivation where it arises\. The PU bearing dataset is used to develop and ablate the design, ZeMA tests transfer to a physically unrelated domain, and SWaT extends it to a cyber\-physical plant\. The three datasets, with their preprocessing and splits, are detailed in Section[4](https://arxiv.org/html/2608.14666#S4), and Figure[1](https://arxiv.org/html/2608.14666#S3.F1)illustrates the general framework implemented in this study\.
Figure 1\.The CMR\-Mamba framework, shown generically for a cause channel𝐱\\mathbf\{x\}and an effect channel𝐲\\mathbf\{y\}\. In training, on healthy data only, the encodersℰx\\mathcal\{E\}\_\{x\}andℰy\\mathcal\{E\}\_\{y\}map the cause and effect windows to token embeddings𝐳x\\mathbf\{z\}\_\{x\}and𝐳y\\mathbf\{z\}\_\{y\}\. The causal predictor𝒫\\mathcal\{P\}predicts the effect embedding from the cause embedding against a stop\-gradient target, and the decoders anchor both embeddings to their input waveforms, giving the combined lossℒ\\mathcal\{L\}\. At inference the predictor and the decoders are discarded, shown dashed, and only the frozen effect encoder is used\. A test window is embedded, pooled, and scored by itskk\-nearest\-neighbour distance to the healthy reference bankℬref\\mathcal\{B\}\_\{\\mathrm\{ref\}\}\. Per\-domain channel bindings appear in Table[3](https://arxiv.org/html/2608.14666#S4.T3)and the symbols in Table[1](https://arxiv.org/html/2608.14666#S3.T1)\.The framework has three trainable parts, trained together on healthy data only, that shift detection from signal\-level appearance to manifold geometry\. Domain\-specific encoders turn raw sensor channels into sequences of short feature vectors, or tokens, using Mamba blocks so that raw waveforms are processed at the full sampling rate without the quadratic cost of Transformers\. A predictor maps the cause token sequence to the effect token sequence, and together with a stop\-gradient it shapes the representations around the physical causal coupling\. Decoders rebuild the raw waveforms and act as a regulariser that keeps the embeddings informative\. The combined loss mixes three goals, rebuilding the cause waveform, rebuilding the effect waveform, and predicting the effect tokens from the cause tokens\.
At inference, the predictor and decoders are discarded and only the effect encoder is kept\. Every healthy training window is passed through it and pooled to a single fixed\-size vector to form a reference bank, and a test window is scored by its distance to the nearest healthy vectors in that bank, so a healthy window scores low and a faulty one high\. Section[3\.3](https://arxiv.org/html/2608.14666#S3.SS3)develops this scoring rule, and Table[1](https://arxiv.org/html/2608.14666#S3.T1)lists the symbols used in the rest of the section\.
Table 1\.Notation used in the methodology section\.### 3\.1\.Encoder Architecture
A single encoder architecture serves all three domains, processing a raw single\-channel waveform to return a contextual token sequence \(illustrated in Figure[2](https://arxiv.org/html/2608.14666#S3.F2)\)\. Only the input sequence length and the resulting token count vary across datasets while the core architecture remains invariant\.
The encoder is constructed from Mamba selective state\-space blocksgu2024mamba, whose linear\-time scaling lets it process the raw waveform at each dataset’s native sampling rate, which reaches tens of thousands of samples on the highest\-rate domain \(Table[3](https://arxiv.org/html/2608.14666#S4.T3)\), where a quadratic\-complexity architecture would be intractable\. Working on the raw waveform matters because the conventional alternatives, downsampling or time\-frequency transforms such as spectrograms, discard the fine transient impulse structures that characterise early\-stage faults\. Mamba is chosen for its selectivity as much as its speed\. A time\-invariant state\-space model would treat transients and background alike, whereas its input\-dependent gating stays quiet through the stationary majority of a healthy window and responds sharply at the short transients that carry the fault information\.
##### Convolutional stem:
Each encoder begins with a one\-dimensional convolution that projects the single\-channel input to theD=128D=128model space using a kernel of seven, a stride of four, and a padding of three\. For an input window of lengthLL, the output token length is:
L′=⌊L\+2×3−74⌋\+1≈L4,L^\{\\prime\}=\\left\\lfloor\\frac\{L\+2\\times 3\-7\}\{4\}\\right\\rfloor\+1\\approx\\frac\{L\}\{4\},\(1\)so the stem reduces the raw window to one quarter of its length\. Batch normalisation and a Gaussian Error Linear Unit \(GELU\) activation follow the convolution, and the three stem values follow the physics of the fault transients\. A seven\-sample kernel is wide enough to span a localized fault impulse yet narrow enough to keep neighbouring transients distinct\. The stride of four is the largest downsampling factor that still leaves consecutive kernels overlapping, which gives a kernel\-to\-stride ratio of7/4=1\.757/4=1\.75and a three\-sample overlap so that no input interval falls between tokens\. The padding of three is the smallest value that holds the output length at⌈L/4⌉\\lceil L/4\\rceil\. Because the stem indexes samples rather than absolute time, these three values transfer unchanged across domains, and the physical duration a kernel spans in each domain follows from its sampling rate \(Section[4](https://arxiv.org/html/2608.14666#S4)\)\.
##### Mamba blocks:
The stem output passes through four Mamba layers in a pre\-normalisation residual stack, each with an internal state dimension of sixteen, a depthwise convolution width of four, and an expansion factor of two\. A final layer normalisation closes the encoder\. Each layer updates its representation by
𝐡ℓ\+1=𝐡ℓ\+Mamba\(LayerNorm\(𝐡ℓ\)\),\\mathbf\{h\}\_\{\\ell\+1\}=\\mathbf\{h\}\_\{\\ell\}\+\\operatorname\{Mamba\}\\bigl\(\\operatorname\{LayerNorm\}\(\\mathbf\{h\}\_\{\\ell\}\)\\bigr\),\(2\)where𝐡ℓ\\mathbf\{h\}\_\{\\ell\}is the token sequence at depthℓ\\ell\. The residual path keeps gradients flowing back to the stem, and pre\-normalisation holds each block’s input variance in check for stable early training\. StackingNenc=4N\_\{\\text\{enc\}\}=4blocks gives the encoder as a single composite function
ℰ\(𝐱\)=LayerNorm\(\(MambaNenc∘⋯∘Mamba1\)\(ConvStem\(𝐱\)\)\)\.\\mathcal\{E\}\(\\mathbf\{x\}\)=\\operatorname\{LayerNorm\}\\\!\\Bigl\(\\bigl\(\\mathrm\{Mamba\}\_\{N\_\{\\text\{enc\}\}\}\\circ\\cdots\\circ\\mathrm\{Mamba\}\_\{1\}\\bigr\)\\bigl\(\\operatorname\{ConvStem\}\(\\mathbf\{x\}\)\\bigr\)\\Bigr\)\.\(3\)
The terminal layer normalisation fixes the cause and effect embeddings to a common scale\. Without it, one encoder could drift to a larger variance and dominate the mean\-squared mechanism loss of Section[3\.2](https://arxiv.org/html/2608.14666#S3.SS2), so the predictor would fit a scale mismatch rather than the physical coupling\.
Figure 2\.The per\-channel Mamba encoder, drawn generically for an input window of lengthLL\. \(a\) The overall pipeline, a ConvStem followed by four stacked Mamba blocks and a final LayerNorm, producing contextual embeddings of shape\(B,L′,D\)\(B,L^\{\\prime\},D\)\. \(b\) The ConvStem, a strided Conv1D with BatchNorm and GELU\. \(c\) A Mamba block, a LayerNorm and Mamba SSM combined through a residual connection\. The same encoder is used unchanged on every dataset, with only the input lengthLLand the token countL′=L/4L^\{\\prime\}=L/4differing across domains \(Table[Full Architecture and Training Specification](https://arxiv.org/html/2608.14666#Sx1.SSx1)\)\.
##### Encoder instances and weight sharing:
Encoder allocation follows a single rule\. Channels that measure the same physical quantity share one encoder instance, which imposes a common representation as a useful inductive bias, while channels that measure distinct quantities use separate encoders so that one latent space is not forced to span incompatible dynamic ranges\. A shared encoder is applied to each of its channels independently and the resulting embeddings are concatenated, which keeps the parameter count controlled when a cause or effect group holds many channels\. The concrete channel groups and the sharing pattern for each domain are listed in Section[4](https://arxiv.org/html/2608.14666#S4)\.
### 3\.2\.Causal Mechanism Prediction and Training Objective
A single causal predictor maps the cause embedding sequence to a predicted effect embedding, and it is trained against the true effect embedding with a mean squared error under a stop\-gradient\. Its input and output widths are the only parts that vary between domains, set by the number of cause and effect channels of each \(Section[4](https://arxiv.org/html/2608.14666#S4)\)\. The predictor begins with a fusion layer, a bias\-free linear projection followed by layer normalisation, a GELU activation, and dropout of 0\.1\. Three temporal convolutional blocks with residual connections and causal padding follow, and the output projection is initialised to the identity on the two single\-coupling domains so that training starts from a stable point \(Table[Full Architecture and Training Specification](https://arxiv.org/html/2608.14666#Sx1.SSx1)\)\.
##### Receptive field of the predictor:
Three convolutional blocks with kernel five give a receptive field of1\+3×\(5−1\)=131\+3\\times\(5\-1\)=13tokens, which is13×4=5213\\times 4=52raw samples\. This window is set to cover the short physical delay between a cause event and its effect response while staying narrow\. A wider field was deliberately avoided, because excess temporal context would let the predictor memorise the transfer\-function fingerprint of individual instances rather than the general mechanism shared across them\. The physical delay this field spans in each domain follows from its sampling rate \(Section[4](https://arxiv.org/html/2608.14666#S4)\)\.
Causal padding enforces the direction of time\. A standard convolution reads tokens on both sides of the target, which would let the predictor use a future cause value to explain a present effect\. Restricting the window to the present and the past keeps the learned relationship aligned with the forward direction of physical causation\.
##### Mechanism and reconstruction losses:
The training procedure optimises a composite objective comprising one causal mechanism loss evaluated in the latent embedding space and two reconstruction losses evaluated in the raw waveform space\. Defining𝐳^y\\hat\{\\mathbf\{z\}\}\_\{y\}as the predicted effect embedding and𝐳y\\mathbf\{z\}\_\{y\}as the ground\-truth effect embedding, the mechanism loss is formulated as a mean squared error coupled with a stop\-gradient operation applied to the target tensor,
ℒmech=1L′D‖𝐳^y−sg\(𝐳y\)‖22\.\\mathcal\{L\}\_\{\\mathrm\{mech\}\}=\\frac\{1\}\{L^\{\\prime\}D\}\\bigl\\lVert\\hat\{\\mathbf\{z\}\}\_\{y\}\-\\operatorname\{sg\}\(\\mathbf\{z\}\_\{y\}\)\\bigr\\rVert\_\{2\}^\{2\}\.\(4\)The operatorsg\(⋅\)\\operatorname\{sg\}\(\\cdot\)denotes the stop\-gradient constraint, implemented computationally as a single\.detach\(\)call\. This operation preserves the forward pass and the numerical magnitude ofℒmech\\mathcal\{L\}\_\{\\mathrm\{mech\}\}entirely, acting exclusively on the backward pass to sever the gradient trajectory before it can traverse through the target embedding into the effect encoder\. Consequently, the effect encoder optimises solely via its own reconstruction objective, forcing the causal predictor and the cause encoder to actively map toward the stable effect representation rather than allowing the effect representation to drift toward the predictor\. Without the stop\-gradient, the two encoders can co\-adapt toward a shared, less discriminative representation, a collapse mode documented for such predictorschen2021simsiam\. Its effect is not uniform across the three datasets, and Section[5\.4\.3](https://arxiv.org/html/2608.14666#S5.SS4.SSS3)quantifies where it helps and where it does not\.
The reconstruction losses are formulated as standard mean squared errors computed over the normalised waveform space\. For the effect channel, the loss is defined as
ℒrecony=1L‖𝐲^−𝐲~‖22,\\mathcal\{L\}\_\{\\mathrm\{recon\}\}^\{y\}=\\frac\{1\}\{L\}\\bigl\\lVert\\hat\{\\mathbf\{y\}\}\-\\tilde\{\\mathbf\{y\}\}\\bigr\\rVert\_\{2\}^\{2\},\(5\)where𝐲^=𝒟y\(𝐳y\)\\hat\{\\mathbf\{y\}\}=\\mathcal\{D\}\_\{y\}\(\\mathbf\{z\}\_\{y\}\)represents the output tensor from the effect decoder\. The cause reconstruction takes the same form on the cause window,
ℒreconx=1L‖𝐱^−𝐱~‖22,\\mathcal\{L\}\_\{\\mathrm\{recon\}\}^\{x\}=\\frac\{1\}\{L\}\\bigl\\lVert\\hat\{\\mathbf\{x\}\}\-\\tilde\{\\mathbf\{x\}\}\\bigr\\rVert\_\{2\}^\{2\},\(6\)where𝐱^=𝒟x\(𝐳x\)\\hat\{\\mathbf\{x\}\}=\\mathcal\{D\}\_\{x\}\(\\mathbf\{z\}\_\{x\}\)\. Paderborn is the one domain with two cause channels, the current phases A and B\. They are encoded and decoded by shared\-weight instances ofℰx\\mathcal\{E\}\_\{x\}and𝒟x\\mathcal\{D\}\_\{x\}, and the cause loss is the average of their two reconstruction errors,12\(∥𝐱^A−𝐱~A∥22\+∥𝐱^B−𝐱~B∥22\)/L\\tfrac\{1\}\{2\}\(\\lVert\\hat\{\\mathbf\{x\}\}^\{A\}\-\\tilde\{\\mathbf\{x\}\}^\{A\}\\rVert\_\{2\}^\{2\}\+\\lVert\\hat\{\\mathbf\{x\}\}^\{B\}\-\\tilde\{\\mathbf\{x\}\}^\{B\}\\rVert\_\{2\}^\{2\}\)/L\. Both phases carry identical physical information separated only by a phase offset, so an asymmetric weighting would train the shared cause encoder to overfit the dominant phase\.
##### Decoder:
Each decoder inverts the stem as a four\-stage upsampler\. A feature\-mixing convolution is followed by two stride\-two transposed convolutions that double the length while contracting the channels from 128 to 64 to 32, and a final projection convolution collapses the result to a single\-channel waveform\. The first three stages use batch normalisation and a GELU activation, while the output stage is linear because the target is z\-scored and spans the real line, so a non\-linear output would clip the extreme transients that carry the fault information\. Two stride\-two stages are used instead of one stride\-four stage, because a kernel that is not divisible by the stride produces checkerboard artefacts, whereas two stride\-two stages tile the tensor evenly\.
##### Loss weights and their domain dependence:
The final training objective represents a weighted summation of Equations \([4](https://arxiv.org/html/2608.14666#S3.E4)\), \([5](https://arxiv.org/html/2608.14666#S3.E5)\), and \([6](https://arxiv.org/html/2608.14666#S3.E6)\),
ℒtotal=γℒmech\+αyℒrecony\+αxℒreconx,\\mathcal\{L\}\_\{\\text\{total\}\}=\\gamma\\,\\mathcal\{L\}\_\{\\text\{mech\}\}\+\\alpha\_\{y\}\\,\\mathcal\{L\}\_\{\\text\{recon\}\}^\{y\}\+\\alpha\_\{x\}\\,\\mathcal\{L\}\_\{\\text\{recon\}\}^\{x\},\(7\)utilising the precise coefficient weights detailed in Table[Full Architecture and Training Specification](https://arxiv.org/html/2608.14666#Sx1.SSx1)\. Each coefficient was set by sweeping one weight while holding the others fixed on the single evaluation split described in Section[5\.4\.1](https://arxiv.org/html/2608.14666#S5.SS4.SSS1), and the resulting operating point is confirmed under the full 15\-fold protocol in Section[5\.1\.1](https://arxiv.org/html/2608.14666#S5.SS1.SSS1)\.
Two of the three weights are fixed across domains\. The effect weightαy=1\.00\\alpha\_\{y\}=1\.00governs the encoder whose representation is used at inference, and lowering it would let that encoder drift toward a representation that suits the predictor but ruins the healthy manifold used for distance scoring\. The mechanism weightγ=0\.20\\gamma=0\.20is the smallest, because the mechanism loss lives in the embedding space and is numerically smaller than the waveform losses, yet even at 0\.20 it governs the embedding geometry, as the ablations confirm\.
The cause weightαx\\alpha\_\{x\}is the only one that varies, and its value follows the physics of the cause channel rather than tuning\. Where the cause signal is dominated by the drive that causally determines the effect, as motor current is for bearing vibration, reconstructing it is a useful constraint andαx\\alpha\_\{x\}is non\-zero\. Where the cause signal carries substantial non\-causal overhead, as motor power does through drive\-electronics losses, reconstructing it would inject that overhead into the predictor and blur the effect manifold, soαx=0\\alpha\_\{x\}=0\. Section[5\.5\.1](https://arxiv.org/html/2608.14666#S5.SS5.SSS1)examines this domain dependence in detail\.
One SWaT\-specific choice follows from the training objective\. Because only eight of the 25 process sensors carry a learnable actuator\-to\-sensor coupling \(Section[4\.1](https://arxiv.org/html/2608.14666#S4.SS1)\), the mechanism residual is measured only on those eight, which keeps it from being diluted by uncoupled channels\. This measurement is developed together with the scoring rule in Section[3\.3](https://arxiv.org/html/2608.14666#S3.SS3)\.
### 3\.3\.Anomaly Scoring by Manifold Distance
At inference the decoders are discarded and a test window is scored by its distance to the healthy training manifold rather than by a reconstruction error\. This choice of scoring rule matters more for detection performance than the choice of encoder, as the ablations of Section[5\.2](https://arxiv.org/html/2608.14666#S5.SS2)show\.
##### Pooling:
Every training window passes through the trained effect encoder to produce a token sequence of shape\(1,L′,D\)\(1,L^\{\\prime\},D\)\. Thekk\-NN score needs one fixed\-size vector per window, so each sequence is reduced by temporal standard\-deviation pooling, taking the standard deviation of every feature across time,
ϕ\(𝐳y\)d=1L′∑t=1L′\(zy,t,d−z¯y,d\)2,d=1,…,D,\\phi\(\\mathbf\{z\}\_\{y\}\)\_\{d\}=\\sqrt\{\\frac\{1\}\{L^\{\\prime\}\}\\sum\_\{t=1\}^\{L^\{\\prime\}\}\\bigl\(z\_\{y,t,d\}\-\\bar\{z\}\_\{y,d\}\\bigr\)^\{2\}\},\\quad d=1,\\ldots,D,\(8\)wherez¯y,d\\bar\{z\}\_\{y,d\}is the per\-channel temporal mean\. The resulting vector has sizeDDwhatever the sequence lengthL′L^\{\\prime\}, so one scoring routine serves all three domains even though their token counts differ by two orders of magnitude \(Table[Full Architecture and Training Specification](https://arxiv.org/html/2608.14666#Sx1.SSx1)\)\.
Standard deviation is used because of how early\-stage faults present physically\. A healthy window is close to stationary, so each latent feature stays near a stable baseline, whereas a fault adds brief high\-energy impulses at regular intervalsrandall2011rollingthat displace the embedding sharply over a few tokens\. Those impulses are too short to move the temporal mean, which the long stretches of ordinary rotation dominate, but they raise the standard deviation, which measures exactly such departures from the baseline\. This matches the early\-stage regime, where the average amplitude still looks normal while the temporal variance has grown\. Mean pooling averages the impulses away, and max pooling responds to the single largest activation, which is as likely to come from a sensor glitch as from a fault\. Section[5\.4\.2](https://arxiv.org/html/2608.14666#S5.SS4.SSS2)compares these alternatives empirically\.
##### Reference bank and anomaly score:
The healthy reference bank consists of the pooled training embeddings collected immediately following the optimisation phase,
ℬref=\{ϕ\(ℰy\(𝐲~i\)\):i∈ℐtrain\}⊂ℝD,\\mathcal\{B\}\_\{\\mathrm\{ref\}\}=\\bigl\\\{\\,\\phi\\bigl\(\\mathcal\{E\}\_\{y\}\(\\tilde\{\\mathbf\{y\}\}\_\{i\}\)\\bigr\)\\,:\\,i\\in\\mathcal\{I\}\_\{\\mathrm\{train\}\}\\,\\bigr\\\}\\subset\\mathbb\{R\}^\{D\},\(9\)whereℐtrain\\mathcal\{I\}\_\{\\mathrm\{train\}\}indexes the training windows\. This bank is constructed once and stored statically without further updates to guarantee computationally efficient and deterministic inference\. A test window is subsequently scored by its mean distance to itskknearest healthy neighbours in this reference bank\. Writing𝐪=ϕ\(ℰy\(𝐲~\)\)\\mathbf\{q\}=\\phi\(\\mathcal\{E\}\_\{y\}\(\\tilde\{\\mathbf\{y\}\}\)\)for the pooled embedding of the test window and𝐛\(1\),…,𝐛\(k\)\\mathbf\{b\}^\{\(1\)\},\\dots,\\mathbf\{b\}^\{\(k\)\}for itskknearest neighbours inℬref\\mathcal\{B\}\_\{\\mathrm\{ref\}\}, the score is
s\(𝐲\)=1k∑i=1kd\(𝐪,𝐛\(i\)\)\.s\(\\mathbf\{y\}\)=\\frac\{1\}\{k\}\\sum\_\{i=1\}^\{k\}d\\\!\\left\(\\mathbf\{q\},\\,\\mathbf\{b\}^\{\(i\)\}\\right\)\.\(10\)
Geometrically, the pooled healthy embeddings occupy a compact region of theDD\-dimensional latent space, the healthy manifold\. A healthy test window lands on or near it, while a faulty one is displaced along directions that normal operation never visits, and the distance to thekknearest healthy points turns that displacement into a single non\-negative score\.
##### Manifold distance against reconstruction error:
Reconstruction error is an unreliable score in principle\. Bouman and Heskesbouman2025autoencodersshow that an optimised autoencoder can rebuild out\-of\-distribution inputs with low error, so a faulty window may be reconstructed as faithfully as a healthy one\. That failure originates in the decoder, and the manifold score avoids it by working only in the representation space of the encoder, where a decoder that happens to reconstruct a fault cannot affect the distance\. The score is also non\-parametric\. It assumes only that faulty windows fall further from the healthy training support, with no assumption that anomalies reconstruct poorly or that scores follow a particular distribution, and distance to that support is the quantity anomaly detection asks forruff2021unifying\. The ablations support this from both directions\. Replacing reconstruction\-error scoring withkk\-NN distance on an otherwise unchanged autoencoder accounts for most of the gain, and Deep SVDD, the one baseline whose native objective already measures distance to a compact healthy region, is also the one baseline thatkk\-NN scoring does not improve \(Section[5\.2](https://arxiv.org/html/2608.14666#S5.SS2)\)\.
The same geometry marks the limits of the approach\. A fault that degrades the cause\-to\-effect coupling displaces the embedding along a direction the causal regulariser has trained the encoder to expose, so it is flagged even when its effect on the marginal signal is small\. A fault that leaves the coupling intact and merely superimposes an additive component, such as an external vibration source bleeding into the accelerometer, leaves the embedding near the healthy manifold and would likely be missed\. The Paderborn faults are of the coupling\-degrading kind, which is part of why the framework works well in that domain, and probing the additive case would require a broader fault catalogue\.
##### The predictor residual as an alternative score:
Scoring by the internal error of the predictor is intuitive but works less well on the single\-coupling datasets\. The predictor is fitted on a handful of healthy training bearings, each with a slightly different mechanical transfer function, so it learns an average that matches no individual bearing exactly\. On an unseen healthy bearing its error therefore rises simply because that bearing departs from the average, and this bearing\-identity noise swamps the small increase an early\-stage fault produces\. The manifold score avoids the problem because it never asks the predictor to extrapolate a transfer function to a new bearing\. It requires only that training place the healthy embeddings in one contiguous neighbourhood\. The ablations confirm the choice, with the predictor\-residual score falling well below thekk\-NN manifold score on both mechanical datasets\.
##### Neighbourhood size and metric:
The neighbourhood size and distance metric are set per domain by sweepingkkagainst both cosine andL2L\_\{2\}distance, and the sweeps themselves are reported in Section[5\.4\.4](https://arxiv.org/html/2608.14666#S5.SS4.SSS4)\. The chosen values track the size of the reference bank and the geometry of the fault\. Paderborn usesk=1k=1with cosine distance and is stable across all fifteen folds\. Cosine ignores the overall activation scale, which drifts with operating condition, so atk=1k=1the score is the smallest angular distance to any single healthy reference vector\. ZeMA usesk=20k=20withL2L\_\{2\}distance, because its bank holds only 415 cycles, an order of magnitude fewer than Paderborn, and a single neighbour in so sparse a space gives a volatile estimate\. The change of metric follows the fault physics, since bearing damage mainly rotates the embedding while pump leakage displaces it isotropically\. SWaT usesk=5k=5withL2L\_\{2\}distance and is insensitive to the choice, with AUROC moving only between 0\.846 and 0\.863 acrossk∈\[1,200\]k\\in\[1,200\], which indicates that the attack signal is spread broadly through the embedding space rather than concentrated near one neighbour\.
SWaT supports a second score that the single\-coupling datasets do not\. Its attacks break the actuator\-to\-sensor coupling directly, which makes the mechanism residual, the distance between the observed effect embedding and the one predicted from the concurrent actuator states, a diagnostic signal in its own right\. It is computed on the eight strongly coupled sensors and reported alongside the manifold distance, and because it is the stronger signal in that domain, the experimental sections treat it as the primary score there\.
### 3\.4\.Algorithmic Summary
Algorithm[1](https://arxiv.org/html/2608.14666#algorithm1)unifies the training sequence, reference bank construction, and inference scoring, providing a consolidated view of the complete operational pipeline\.
Input:Healthy training set
𝒯\\mathcal\{T\}; healthy validation set
𝒱\\mathcal\{V\}; test set
𝒬\\mathcal\{Q\}of mixed windows; loss weights
γ,αy,αx\\gamma,\\alpha\_\{y\},\\alpha\_\{x\}; neighbourhood size
kkand distance
dd; maximum epoch count
EmaxE\_\{\\max\}; batch size
BB\.
Output:Anomaly scores
\{s\(𝐲⋆\):⋆∈𝒬\}\\\{s\(\\mathbf\{y\}\_\{\\star\}\):\\star\\in\\mathcal\{Q\}\\\}\.
1Stage 1: Preprocessing\.;
2Compute per\-channel z\-score statistics
\(μc,σc\)\(\\mu\_\{c\},\\sigma\_\{c\}\)from healthy recordings; normalise all windows using Eq\. \([11](https://arxiv.org/html/2608.14666#S4.E11)\);
3Stage 2: Training\.;
4Initialise the encoders, predictor, and decoders, with the predictor output projection set as described in Section[3\.2](https://arxiv.org/html/2608.14666#S3.SS2);
5for*epoch=1,…,Emax\\text\{epoch\}=1,\\ldots,E\_\{\\max\}*do
6foreach*minibatchℳ⊂𝒯\\mathcal\{M\}\\subset\\mathcal\{T\}of sizeBB*do
7Compute cause and effect token embeddings via Eq\. \([3](https://arxiv.org/html/2608.14666#S3.E3)\);
8Compute predicted effect embedding
𝐳^y\\hat\{\\mathbf\{z\}\}\_\{y\}from cause embeddings;
9Compute the waveform reconstructions
𝐲^\\hat\{\\mathbf\{y\}\}and
𝐱^\\hat\{\\mathbf\{x\}\}for each cause channel;
10Compute
ℒtotal\\mathcal\{L\}\_\{\\mathrm\{total\}\}from Eqs\. \([4](https://arxiv.org/html/2608.14666#S3.E4)\)–\([6](https://arxiv.org/html/2608.14666#S3.E6)\) with
sg\(𝐳y\)\\operatorname\{sg\}\(\\mathbf\{z\}\_\{y\}\)as the mechanism target;
11Backpropagate; clip gradient norm to
1\.01\.0; take an AdamW step;
12
13end foreach
14Evaluate
ℒrecony\\mathcal\{L\}\_\{\\mathrm\{recon\}\}^\{y\}on
𝒱\\mathcal\{V\}; checkpoint if it has improved; step the learning\-rate scheduler;
15
16end for
17Reload the best checkpoint by validation
ℒrecony\\mathcal\{L\}\_\{\\mathrm\{recon\}\}^\{y\};
18Stage 3: Reference bank\.;
19foreach*training windowi∈ℐtraini\\in\\mathcal\{I\}\_\{\\mathrm\{train\}\}*do
20Compute
𝐫i=ϕ\(ℰy\(𝐲~i\)\)\\mathbf\{r\}\_\{i\}=\\phi\\bigl\(\\mathcal\{E\}\_\{y\}\(\\tilde\{\\mathbf\{y\}\}\_\{i\}\)\\bigr\)using Eq\. \([8](https://arxiv.org/html/2608.14666#S3.E8)\);
21
22end foreach
23Set
ℬref=\{𝐫i\}\\mathcal\{B\}\_\{\\mathrm\{ref\}\}=\\\{\\mathbf\{r\}\_\{i\}\\\}and store on disk;
24Stage 4: Anomaly scoring\.;
25foreach*test window⋆∈𝒬\\star\\in\\mathcal\{Q\}*do
26Compute pooled test embedding
𝐪⋆=ϕ\(ℰy\(𝐲~⋆\)\)\\mathbf\{q\}\_\{\\star\}=\\phi\\bigl\(\\mathcal\{E\}\_\{y\}\(\\tilde\{\\mathbf\{y\}\}\_\{\\star\}\)\\bigr\);
27Find the
kknearest neighbours
𝐛\(1\),…,𝐛\(k\)\\mathbf\{b\}^\{\(1\)\},\\dots,\\mathbf\{b\}^\{\(k\)\}of
𝐪⋆\\mathbf\{q\}\_\{\\star\}in
ℬref\\mathcal\{B\}\_\{\\mathrm\{ref\}\};
28Set
s\(𝐲⋆\)←1k∑i=1kd\(𝐪⋆,𝐛\(i\)\)s\(\\mathbf\{y\}\_\{\\star\}\)\\leftarrow\\tfrac\{1\}\{k\}\\sum\_\{i=1\}^\{k\}d\(\\mathbf\{q\}\_\{\\star\},\\mathbf\{b\}^\{\(i\)\}\)
29end foreach
30;
31
Algorithm 1CMR\-Mamba: training and inference\.
### 3\.5\.Implementation Details
The framework is implemented in PyTorch, with the officialmamba\-ssmlibrary, version 2\.2\.2, supplying the selective\-scan kernel\. Training was executed on a shared cluster with heterogeneous GPUs, so the wall\-clock figures in Table[Full Architecture and Training Specification](https://arxiv.org/html/2608.14666#Sx1.SSx1)are indicative rather than controlled benchmarks\. A Paderborn fold takes about three hours, which puts the full fifteen\-fold sweep near 45 GPU hours, a ZeMA seed about twenty minutes, and a SWaT seed about3\.33\.3hours\. The SWaT cost comes from the width of its multi\-channel cause and effect groups rather than from sequence length, since its windows are only 64 tokens\. Moreover, the parameter counts follow the same pattern \(Table[Full Architecture and Training Specification](https://arxiv.org/html/2608.14666#Sx1.SSx1)\)\. Paderborn and ZeMA are comparable at1\.671\.67M and1\.591\.59M, whereas SWaT is larger at5\.415\.41M, because its predictor maps a 12\-channel cause embedding to a 25\-channel effect embedding and a separate decoder is instantiated for each sensor\.
Model checkpoints are selected on the validation effect\-channel reconstruction loss\. Because inference relies entirely on the healthy manifold generated by the effect encoder, allowing minor fluctuations in the mechanism or cause\-reconstruction losses to dictate model selection would optimize total training metrics at the expense of downstream anomaly scoring\.
##### Reproducibility Requirements:
Gradient clipping at a maximum norm of1\.01\.0is required, because the selective\-scan kernel periodically produces large gradient spikes on windows with sharp transients that otherwise destabilise the early epochs and prevent encoder convergence\. Implementation notes, including themamba\-ssmsubmodule import used to avoid a deprecated transformers dependency, are provided in the code repository\.
Table 2\.Key training and inference settings\. The optimiser configuration is identical across domains, while loss weights, epoch limits, and scoring parameters adapt to the specific dataset\. The full specification is in Table[Full Architecture and Training Specification](https://arxiv.org/html/2608.14666#Sx1.SSx1)\.
## 4\.Experimental Setup
This section describes the three datasets that instantiate the framework, the preprocessing and split protocol, and the evaluation protocol used throughout the results\.
### 4\.1\.Datasets, Preprocessing, and Splits
The framework is evaluated on three datasets that share a common causal structure but span distinct physical domains\. Each records a physically grounded cause channel and an effect channel synchronously, allowing the same cause\-to\-effect mechanism to be learned without modifying the underlying model\. The PU dataset represents an electromechanical system in which motor current drives bearing vibration\. The ZeMA hydraulic dataset captures an electro\-hydraulic rig in which motor power drives pump pressure\. SWaT provides a cyber\-physical plant in which actuator commands drive process sensors\. Table[3](https://arxiv.org/html/2608.14666#S4.T3)details the instantiation for each domain\. Each design decision below, the causal pair, the normalisation rule, and the windowing and splitting protocol, is stated as a general principle and then instantiated for each domain\.
Table 3\.Characteristics of the three coupling\-fault domains\. The underlying detection framework remains invariant across all datasets, while the causal pairs and temporal window lengths are adapted to the specific physical dynamics of each system\.##### The causal pair:
Paderbornlessmeier2016conditionrecords vibration from a piezoelectric accelerometer on the bearing housing together with two motor current phases at 64 kHz\. While most bearing benchmarks record vibration alone, the simultaneous capture of current and vibration at identical resolution in the PU dataset supplies the electrical input and the mechanical response as a matched pair\. This synchronous pairing makes the dataset uniquely suited for causal evaluationneupane2025multisensor\. The rig is an electromechanical drive with a motor, a torque measurement shaft, a type 6203 deep groove ball bearing under test, and a flywheel load\. Each bearing is recorded twenty times for approximately four seconds under four operating conditions spanning two speeds \(900 and 1500 revolutions per minute\), two load torques \(0\.7 and 0\.1 newton metres\), and two radial forces \(400 and 1000 newtons\)neupane2025multisensor\.
ZeMAhelwig2015hydraulicprovides the hydraulic analogue\. Two channels sampled at 100 Hz yield 6,000 samples per 60\-second cycle\. EPS1, the motor power in watts, serves as the cause channel\. PS1, the pump output pressure in bar, serves as the effect channel\. This causal direction follows from first principles\. Motor power drives the pump and the pump converts mechanical energy into hydraulic pressure\. Internal leakage breaks this coupling by allowing fluid to bypass internally, causing pressure to fall for the same power input\. This mechanism makes leakage the exact hydraulic counterpart to the bearing fault rather than an unrelated failure mode\.
SWaTgoh2016swat;mathur2016swatextends this methodology to cyber\-physical systems\. The plant records 51 channels at 1 Hz, comprising 26 discrete actuators and 25 continuous sensors\. The causal pair is multi\-channel because control actuators collectively drive the process sensors\. Pruning 14 constant actuators leaves 12 active components to form the cause group\. Linear regression under normal operation separates the sensors that carry a learnable physical mechanism from those governed by unpredictable chemical dynamics\. The eight sensors with linearR2R^\{2\}values exceeding 0\.55 represent this mechanism, while all 25 provide full system coverage\. A SWaT attack forces an actuator or spoofs a sensor to contradict the control commands\. This creates a broken control\-to\-process coupling in exactly the sense the framework targets\.
Because the encoder and predictor architectures are defined strictly in discrete samples, their effective temporal receptive fields scale naturally with each domain’s sampling rate\. At the 64 kHz resolution of the Paderborn dataset, the seven\-sample stem kernel spans approximately 0\.1 ms, and the 52\-sample predictor field covers 0\.8 ms\. These durations tightly encapsulate the 0\.08 to 0\.31 ms bearing\-fault impulse and the sub\-millisecond current\-to\-vibration delayrandall2011rolling\. Conversely, at the 100 Hz resolution of the ZeMA dataset, the identical seven\-sample kernel spans 70 ms, natively accommodating the slower pressure transients characteristic of hydraulic leakage\. This sample\-domain invariance allows a single architectural configuration to adapt seamlessly across vastly different physical timescales\.
##### Fault populations:
Paderborn contains 32 bearing experiments, comprising 6 healthy bearings \(K001 to K006\) and 26 faulty bearings, of which 12 carry artificially induced damage and 14 carry real damage from accelerated lifetime tests at 3800 newtons and 2900 revolutions per minutelessmeier2016condition\. The artificial defects were produced by electrical discharge machining, electric engraving, and drilling, with each method leaving a geometrically clean and distinct defectneupane2025comprehensive\. The real damage arises as fatigue pitting, where subsurface cracks reach the raceway and produce sharp periodic impulses, or as plastic deformation, where the contact geometry is altered smoothly without material removal and without those sharp impulsesiso15243;randall2011rolling\. Nineteen of the 26 faulty bearings are used for evaluation, comprising 8 artificial and 11 real instances\. The 7 excluded bearings are redundant duplicates of damage categories already represented in the dataset\. The final selection preserves all five damage processes, both individual races and their combination, severity levels 1 to 3, and six specific severity progressions\. These progressions hold the damage mechanism and location fixed while varying only the severity, allowing the anomaly score to be evaluated for monotonic response to physical damage extent\. The weighting toward real faults, 11 out of 19, ensures the aggregate metric remains representative of true industrial difficulty\. Table[Paderborn Bearing Subset](https://arxiv.org/html/2608.14666#Sx1.SSx2)lists the resulting subset along with the selection rationale for each bearing\.
ZeMA records 2,205 cycles under four independently varied component conditions\. This work targets pump internal leakage, which is encoded across three distinct levels\. These levels are healthy, weak, and severehelwig2015hydraulic\. A stable flag marks cycles that reached thermal and hydraulic equilibrium prior to recording\. Only the 1,449 stable cycles are retained\. This filtering ensures the model processes steady\-state operation rather than unpredictable start\-up transients\. Following this step, 489 pump\-healthy stable cycles form the candidate training pool\. The test set comprises 960 pump\-faulty stable cycles, divided equally into 480 weak and 480 severe instances\. SWaT provides seven days of normal operation followed by four days containing 36 documented attacks\. The first six hours of the normal run are discarded to account for plant stabilisation\.
##### Normalisation:
A single normalisation rule governs all three datasets\. Each channel is z\-score standardised using statistics computed exclusively from healthy data, and these parameters are subsequently applied across every split\. Computing normalisation statistics across the entire dataset would allow high\-amplitude fault impulses to artificially inflate the global standard deviation\. This inflation would subsequently suppress the relative magnitude of the exact transient anomalies the framework is designed to detect\. Restricting the statistical estimation exclusively to the healthy distribution prevents this signal attenuation, aligning with established unsupervised anomaly detection protocolsruff2021unifying\. Formally, for a given channelccwith meanμc\\mu\_\{c\}and standard deviationσc\\sigma\_\{c\}derived from healthy recordings, every sample is replaced according to the following equation
𝐱~c=𝐱c−μcσc\+ε,\\tilde\{\\mathbf\{x\}\}^\{c\}=\\frac\{\\mathbf\{x\}^\{c\}\-\\mu\_\{c\}\}\{\\sigma\_\{c\}\+\\varepsilon\},\(11\)whereε=10−8\\varepsilon=10^\{\-8\}guards against division by zero on a flat channel\. On Paderborn the statistics are computed from the six healthy bearings, on ZeMA from the 415 training cycles, and on SWaT from the normal training rows\.
##### Windowing:
The temporal window length is dictated by the physical dynamics of each plant rather than by a fixed convention\. Paderborn uses 32,768 samples, corresponding to 0\.512 seconds at 64 kHz, with a stride of 16,384 to provide a 50 percent overlap\. At operating speeds of 15 to 25 revolutions per second, this duration captures 8 to 13 full shaft revolutions\. Because every classical bearing fault signature is rotational, a window must span enough revolutions for the repetition pattern to appear multiple times\. This allows the encoder to model the pattern as a structural feature rather than a random coincidencerandall2011rolling;dhirajSN\_CNN\. The overlap guarantees that an impulse landing near a boundary is fully covered by at least one window, while simultaneously doubling the healthy training set size at no cost beyond computation\. This procedure yields a final Paderborn dataset comprising 6,727 healthy windows and 21,337 faulty windows\. ZeMA requires no windowing\. Each 60\-second cycle represents an independent operating condition, making one full cycle equivalent to one sample of shape\(2,6,000\)\(2,6\{,\}000\)\. SWaT employs 256\-second windows with a stride of 128 seconds\. This length was selected based on the attack\-duration distribution, which has a median of 444 seconds\. The 256\-second window fits entirely inside most attacks while remaining short enough to localise them accurately\. A window is labelled an attack window if any timestep within it contains an attack\. At 1 Hz, this window spans only 256 raw samples, indicating that the primary challenge on SWaT is channel count rather than sequence length\.
##### Splits and leakage:
A single rigorous principle governs the data splits\. No physical machine instance and no adjacent stretch of time may appear in both the training and testing sets\. On Paderborn, the physical instance is the bearing itself\. Every window originating from a given bearing is assigned entirely to one split\. Two windows from the same recording share nearly all of their physical characteristics and differ only in the specific time region they cover\. A naive window\-level split would allow a model to achieve high accuracy simply by memorising the unique acoustic fingerprint of an individual bearing without ever generalising to a new machine\. The strict bearing\-level separation removes that evaluation loophole\. Among the six healthy reference bearings, we employ a leave\-two\-out cross\-validation strategy, holding out two bearings for validation and training on the remaining four\. There are\(62\)=15\\binom\{6\}\{2\}=15possible pairs, generating fifteen distinct folds\. The bearings are enumerated alphabetically to ensure determinism\. All nineteen faulty bearings are reserved exclusively for the test set\. The two held\-out healthy bearings are also added to the test set to evaluate specificity\. This protocol demands two simultaneous levels of generalisation\. The model must correctly recognise unseen healthy bearings as healthy, and it must assign systematically higher anomaly scores to the unseen faulty bearings\. A method mastering only the first requirement would flag nothing, while a method mastering only the second would trigger constant false alarms\. The standard deviation across the fifteen folds explicitly measures how sensitive the final performance is to the specific bearings present in the training set\.
ZeMA and SWaT each represent a single physical plant, meaning no leave\-instance\-out split is possible\. The separation must therefore be temporal\. On ZeMA, the 489 healthy stable cycles are ordered chronologically by their cycle index\. The first 85 percent, comprising 415 cycles, form the training set\. The remaining 15 percent, comprising 74 cycles, form the validation set\. All 960 faulty cycles are placed in the test set alongside the 74 validation cycles to ensure the area under the curve metric has access to both positive and negative examples\. This temporal ordering is critical because hydraulic oil temperature drifts slowly over the course of an experiment\. A random split would place thermally adjacent cycles into both the training and testing sets, creating subtle data leakage through shared thermal states\. On SWaT, the temporal separation is naturally embedded in the data collection, as seven attack\-free days precede the four attack days\. The normal windows are partitioned chronologically into 3,142 training windows and 551 validation windows\. The test set comprises 3,513 windows, of which 3,017 are normal and 496 contain at least one attack timestep\. For both of these single\-plant datasets, robustness is assessed by training three models from independently drawn random initialisations\. The mean and standard deviation of the area under the curve are reported across these three runs\. For the ZeMA evaluation, results are reported separately for weak and severe leakage to establish a severity gradient\.
### 4\.2\.Experimental Protocol
##### Metric:
The area under the receiver operating characteristic curve \(AUROC\) is the primary metric on all three datasets\. It is the probability that a randomly chosen faulty window scores higher than a randomly chosen healthy one, so it measures the quality of the ranking without committing to a threshold\. That suits this framework, because an operating threshold is a deployment decision governed by the plant\-specific costs of false alarms and missed detections, which lie outside an algorithmic comparison\. The metric can flatter a detector when the positive class is very rare, but the imbalance here is moderate, with roughly14%14\\%attack windows in the SWaT test set, and at that level the receiver operating characteristic and the precision\-recall geometry remain coupleddavis2006relationship\. Point\-wise F1 is additionally reported on SWaT for comparability with the existing literature\.
##### Estimating variance:
Robustness and variance are quantified strictly according to the physical structure of each dataset\. Because the Paderborn dataset provides six independent healthy bearings, variance is estimated across the fifteen leave\-two\-out folds defined in Section[4\.1](https://arxiv.org/html/2608.14666#S4.SS1), with each fold training a model from random initialisation\. This strict cross\-validation is critical; individual training bearings vary in how comprehensively they span the global healthy manifold\. A high mean AUROC coupled with a large fold\-to\-fold standard deviation indicates algorithmic brittleness rather than generalizable stability, a vulnerability that a pooled mean would mathematically obscure\. Conversely, ZeMA and SWaT each record telemetry from a single physical plant, precluding cross\-instance validation\. Variance for these single\-plant domains is therefore estimated across three models trained from independent random initialisation seeds\.
##### Stratified reporting of fault populations:
Aggregate AUROC is never evaluated in isolation, as a pooled metric mathematically obscures the operational boundaries that determine algorithmic viability\. Each dataset is therefore explicitly stratified\. The Paderborn dataset is partitioned by fault origin into artificial and real damage\. A detector that successfully identifies geometrically idealised machined defects but fails on natural fatigue damage has merely overfitted a machining signature rather than learning the generalised physics of bearing failurelessmeier2016condition;iso15243\. The ZeMA dataset is stratified by fault severity, separating weak from severe internal leakage to verify that the anomaly score scales monotonically with physical degradation\. The SWaT dataset is stratified by attack stealth, classifying attacks as stealthy when every individual sensor remains strictly within its historical normal bounds, and blunt otherwise\. This specific split isolates the complex coupling\-violating attacks that marginal detectors fundamentally ignore\. While tracking distinct physical variables, these three stratification strategies serve an identical diagnostic function, i\.e\., they separate high\-separability faults that any baseline algorithm can identify from the low\-separability edge cases that genuinely differentiate competing architectures\.
## 5\.Results and Analysis
This section reports the main cross\-dataset results, isolates the scoring rule from the encoder, examines the hard fault subsets, presents the ablations, and closes with the cross\-domain analysis\.
Paderborn is the primary validation domain, because it is the only one of the three that provides independent machine instances and so supports a leave\-instance\-out protocol, which makes generalisation to unseen bearings the property under test\. The data, causal pair, windowing, and splits follow Section[4\.1](https://arxiv.org/html/2608.14666#S4.SS1), and the architecture and training settings follow Table[Full Architecture and Training Specification](https://arxiv.org/html/2608.14666#Sx1.SSx1)and Table[2](https://arxiv.org/html/2608.14666#S3.T2), with the operating point\(γ,αy,αx\)=\(0\.20,1\.00,0\.75\)\(\\gamma,\\alpha\_\{y\},\\alpha\_\{x\}\)=\(0\.20,\\,1\.00,\\,0\.75\)selected by the ablations of Section[5\.4](https://arxiv.org/html/2608.14666#S5.SS4)\. Repeating the fifteen folds three times from independent initialisations gives 45 trained models, meaning 45 instances of CMR\-Mamba rather than 45 distinct methods, and figures averaged over them are labelled “15 folds×\\times3 runs”\. Aggregate figures are the mean over these 45 models, with the standard deviation taken across the 15 folds\.
### 5\.1\.Main Cross\-Dataset Results
#### 5\.1\.1\.Paderborn Results and 15\-Fold Cross\-Validation
Table[8](https://arxiv.org/html/2608.14666#Sx1.T8)reports the per\-fold AUROC under the fixed loss weights\(αx,αy,γ\)=\(0\.75,1\.0,0\.2\)\(\\alpha\_\{x\},\\alpha\_\{y\},\\gamma\)=\(0\.75,1\.0,0\.2\)averaged over three independent runs\. Figure[3](https://arxiv.org/html/2608.14666#S5.F3)plots these per\-fold means alongside their corresponding run\-to\-run dispersion metrics\.
Under the fixed evaluation protocol, a single configuration fixed in advance with std\-pooling,k=1k=1, and cosine distance applied unchanged to every fold, CMR\-Mamba attains a grand\-mean overall AUROC of0\.8803±0\.1085\\mathbf\{0\.8803\\pm 0\.1085\}across the 15 evaluation folds, decomposing into0\.79190\.7919on artificial faults and0\.94450\.9445on real damage\. The three runs agree within0\.0030\.003at the aggregate, so the pipeline is reproducible\. Real\-damage detection is consistently strong, while the more idealised artificial faults are harder and carry most of the between\-fold variance\. Evaluated under the same fixed protocol, USAD reaches0\.88500\.8850, the VAE0\.87360\.8736, and the autoencoder0\.86740\.8674\(Table[9](https://arxiv.org/html/2608.14666#Sx1.T9)\), so CMR\-Mamba is competitive on the aggregate rather than dominant, while remaining the best detector of the artificial\-defect subset at0\.79190\.7919against0\.75380\.7538for the strongest baseline\.
Selecting the embedding strategy, the neighbourhood size, and the distance metric per fold on the evaluation set instead raises the grand mean to0\.9297±0\.03510\.9297\\pm 0\.0351, with0\.86010\.8601on artificial faults and0\.98030\.9803on real damage and run means0\.93130\.9313,0\.92810\.9281, and0\.92970\.9297\. This per\-fold detail is the series plotted in Figure[3](https://arxiv.org/html/2608.14666#S5.F3)and tabulated in Table[8](https://arxiv.org/html/2608.14666#Sx1.T8)\. Because it selects hyperparameters on the test folds, it is an upper bound rather than a generalisation estimate and is reported only as a sensitivity bound\. The gap between the two protocols is a property of that per\-fold selection\.
Performance approaches near\-perfect levels on the most accessible split\. Split 1 holds out bearings K001 and K003 and achieves an AUROC of0\.99980\.9998with a run\-to\-run standard deviation of only0\.00020\.0002\. Conversely performance degrades on a single hard fold\. Split 12 holds out bearings K004 and K005 and yields an AUROC of0\.86160\.8616\. This specific fold represents the lowest performance across all three independent runs\. This systematic difficulty remains intrinsic to the held\-out bearing hardware rather than the model architecture\. The faulty\-to\-healthy mean score ratio for split 12 is only0\.97×0\.97\\timeswhich indicates that faulty windows score no higher on average than healthy ones\. The remaining evaluation folds achieve ratios between1\.4×1\.4\\timesand2\.8×2\.8\\times\. The healthy embeddings of bearings K004 and K005 intrinsically lie close to the faulty manifold\. This overlap represents an irreducible physical property of those two reference components\. Reporting the comprehensive per\-fold distribution instead of the mean alone provides transparency regarding this hardware limitation and explains the0\.0350\.035between\-fold standard deviation\.
A direct measurement of the embedding geometry identifies the cause of this fold\. Under the fixed protocol, the mean distance from faulty windows to the healthy reference bank, divided by the same distance measured for held\-out healthy windows, is1\.0451\.045on split 12 against a mean of3\.4873\.487and a minimum of1\.5191\.519across the other fourteen folds\. A ratio of one leaves the score with nothing to separate\. The quantity that moves is not the faulty distance, which at0\.1200\.120is unremarkable, but the held\-out healthy distance, which rises to0\.1150\.115from a typical0\.020\.02to0\.050\.05\. Bearings K004 and K005 are the two most atypical of the six on the vibration channel and depart from the population in the same direction on every statistic measured, so they form a mutually covering pair\. Whenever one of them remains in the reference bank the other is covered and the fold behaves normally, with held\-out healthy distances of0\.0270\.027to0\.0410\.041across the six folds that hold out exactly one of them\. Split 12 is the only combination of the fifteen that removes both at once, which leaves the bank without coverage of the region those bearings occupy\. The collapse is therefore a property of this particular leave\-two\-out combination rather than of the architecture\.
Two consequences follow from the diagnosis above\. The0\.00480\.0048gap by which USAD leads CMR\-Mamba on the fixed\-protocol aggregate is a twentieth of CMR\-Mamba’s own fold\-to\-fold standard deviation of0\.10850\.1085, well inside the noise floor of a 15\-fold estimate, so it does not support a ranking claim in either direction\. The gap is also disproportionately carried by the one fold just diagnosed: over the other fourteen, CMR\-Mamba averages0\.90340\.9034against USAD’s0\.89560\.8956, a lead of0\.00780\.0078\. This is reported as a decomposition of the aggregate already disclosed above, not as a replacement for it, and split 12 remains in every other figure and table in this paper\.
A Wilcoxon signed\-rank test on the fifteen paired folds confirms this assessment\. Under the fixed protocol, CMR\-Mamba does not differ significantly from USAD \(p=0\.64p=0\.64\), the VAE \(p=0\.52p=0\.52\), or the autoencoder \(p=0\.25p=0\.25\) in the aggregate, while it significantly outperforms Deep SVDD \(p=0\.001p=0\.001\)\. The median paired difference nonetheless favours CMR\-Mamba, by0\.0150\.015over USAD,0\.0270\.027over the VAE, and0\.0160\.016over the autoencoder, and CMR\-Mamba exceeds USAD on nine of the fifteen folds \(Table[9](https://arxiv.org/html/2608.14666#Sx1.T9)\)\. USAD’s slight edge in the aggregate mean is carried by the single hard fold, split 12, so the fixed\-protocol aggregate supports parity rather than a ranking\.
Figure 3\.Per\-fold AUROC on PU dataset \(3\-run mean\)\. The green bars use the fixed evaluation protocol\. The light\-blue bars select the embedding strategy, neighbourhood size, and distance metric per fold on the evaluation set, which makes them an upper bound\. The two series agree on most folds and diverge where per\-fold selection can exploit the test set, most sharply on split 12, whose collapse under the fixed protocol is diagnosed below\.
#### 5\.1\.2\.ZeMA Results and SWaT Point\-wise F1
The CMR\-Mamba framework attains an overall AUROC of0\.9843±0\.0065\\mathbf\{0\.9843\\pm 0\.0065\}under the reference configuration utilising no stop\-gradient alongsideαx=0\\alpha\_\{x\}=0andγ=0\.2\\gamma=0\.2andk=20k=20\. The no\-stop\-gradient choice on this dataset is not arbitrary and follows the data\-size rule established later in Section[5\.4\.3](https://arxiv.org/html/2608.14666#S5.SS4.SSS3)\. Table[10](https://arxiv.org/html/2608.14666#Sx1.T10)reports the per\-seed performance breakdown alongside the contrasting stop\-gradient variant\.
Two observations follow\. First, the framework resolves severe leakage, with the no\-stop\-gradient severe\-fault AUROC averaging0\.99980\.9998and reaching1\.00001\.0000on one seed, so nearly all remaining difficulty and variance sits in the weak\-leakage faults at0\.96880\.9688\(k=20k=20\), consistent with a minor leak perturbing the EPS1→\\toPS1 coupling only slightly\. Second, the no\-stop\-gradient variant is stable across seeds, spanning0\.97520\.9752to0\.98970\.9897against the stop\-gradient variant’s wider0\.89210\.8921to0\.98580\.9858, a practical advantage for deployment\.
The SWaT literature frequently evaluates performance using a per\-timestep F1 metric operating under the point\-adjust protocol\. The evaluation maps window scores to individual timesteps to report both the raw best\-F1 metric and the point\-adjust variant as detailed in Table[4](https://arxiv.org/html/2608.14666#S5.T4)\.
This specific evaluation serves two distinct architectural purposes\. First the comparison validates the internal evaluation pipeline\. The original USAD publication reports a point\-adjusted F1 score of approximately0\.790\.79on the SWaT dataset\. The USAD implementation in this study reaches a raw F1 of0\.7740\.774alongside a point\-adjusted F1 spanning between0\.840\.84and0\.900\.90\. These values fall squarely within the published range to confirm the absolute accuracy of the dataset preprocessing and labelling alongside the core evaluation mechanics\. Second this analysis exposes the well\-documented mathematical pathology inherent to the point\-adjust protocol\(kim2022towards\)\. Flagging a single timestep within an attack sequence automatically credits the entire attack segment under this permissive protocol\. This generous attribution artificially inflates the performance metric of every evaluated method by margins between0\.060\.06and0\.120\.12while simultaneously reordering the overarching performance rankings\. Thekk\-NN point\-adjusted F1 score for USAD specifically jumps to0\.8990\.899under these conditions\. The raw F1 score is therefore the figure reported here\. The point\-adjusted variant is provided strictly to ensure empirical comparability with prior literature\. This conservative reporting practice is recommended generally for future cyber\-physical anomaly detection evaluations\.
Table 4\.SWaT point\-wise best\-F1 \(3\-seed mean±\\pmstd\)\. Raw F1 is the honest metric, and point\-adjusted \(PA\) F1 is reported only for comparability\.
#### 5\.1\.3\.Consolidated Cross\-Dataset Results
Table[5](https://arxiv.org/html/2608.14666#S5.T5)collects the optimal performance metric of every evaluated method across all three datasets\. Figure[4](https://arxiv.org/html/2608.14666#S5.F4)directly compares CMR\-Mamba against the two strongest baseline architectures across these domains\.
Two observations follow\. First, no single baseline stays competitive across all three domains\. The autoencoder collapses on ZeMA at0\.7790\.779, the Anomaly Transformer is intractable on Paderborn and weakest on SWaT at0\.7610\.761, and Deep SVDD trails on both Paderborn and SWaT at0\.8400\.840\. Only the VAE holds up everywhere, and where it exceeds CMR\-Mamba the margin sits within overlapping intervals,0\.9980\.998against0\.9840\.984on ZeMA and0\.8710\.871against0\.8680\.868on SWaT\. Second, aggregate AUROC is saturated\. It is dominated by high\-separability faults that every strong method already solves, with all methods near≈1\.0\\approx 1\.0on severe ZeMA leakage and a median sensor total\-variation distance of0\.610\.61on SWaT showing most attacks are blunt\. The methods separate on the low\-separability hard subset of each dataset, where CMR\-Mamba leads \(Table[7](https://arxiv.org/html/2608.14666#S5.T7)\), so aggregate scoring rewards the easy majority and hides the coupling\-aware advantage that disaggregation by difficulty exposes\.
Table 5\.Consolidated overall AUROC\. The PU column applies one configuration fixed in advance \(std\-pooling,k=1k=1, cosine\) unchanged to all fifteen folds and matched across every method\. ZeMA and SWaT report each method at its best configuration \(3\-seed mean\)\.- On PU the four reconstruction methods lie within0\.0180\.018of one another, and CMR\-Mamba’s per\-fold oracle upper bound there is0\.9300\.930\(Section[5\.1\.1](https://arxiv.org/html/2608.14666#S5.SS1.SSS1)\)\.
- “OOM” marks the Anomaly Transformer, which is intractable at the PU window length\.
- Reconstruction methods are scored bykk\-NN, which improves substantially on their native scores in every domain \(Figure[5](https://arxiv.org/html/2608.14666#S5.F5)\), with the per\-dataset breakdowns in the appendix\.
- Deep SVDD is a centre\-distance method, so its native score of0\.8920\.892on the PU evaluation split is its intended metric\. The0\.6630\.663shown here is its matchedkk\-NN value, used to keep the PU column comparable across methods\.
- CMR\-Mamba uses the no\-stop\-gradient variant on ZeMA and the stop\-gradient variant on Paderborn and SWaT, following the data\-size rule of Section[5\.4\.3](https://arxiv.org/html/2608.14666#S5.SS4.SSS3)\.
Figure 4\.CMR\-Mamba against the two strongest baselines \(VAE, USAD\) across the three domains\. Aggregate scores are close on ZeMA and SWaT, where most faults are easy, and the methods separate on each dataset’s hard subset \(Table[7](https://arxiv.org/html/2608.14666#S5.T7)\)\.
### 5\.2\.Baseline Comparison and the Role of the Scoring Rule
Every evaluation framework is scored twice across all datasets by utilising its own native anomaly metric alongside akk\-nearest\-neighbour distance computed directly on the corresponding embeddings under matched data splits and random seeds\. This pairing isolates the structural influence of the scoring rule from the representation capability of the underlying encoder\. The Paderborn dataset evaluations are presented first because they exhibit the largest performance delta between the two scoring approaches\. The evaluations on the ZeMA and SWaT datasets follow\. This identical comparative test is then applied directly to the CMR\-Mamba encoder itself, and the consolidated comparison across all methods and domains appears in Section[5\.1](https://arxiv.org/html/2608.14666#S5.SS1)\. This empirical effect remains highly consistent across all three domains and constitutes the largest single performance variance measured in this study\.
#### 5\.2\.1\.Baseline Comparison on the Paderborn Dataset
The proposed CMR\-Mamba framework is compared against four established one\-class baseline models consisting of a convolutional autoencoder, a variational autoencoder, the USAD architecture, and Deep SVDD alongside the Anomaly Transformer\. Every baseline reports both its native anomaly score and a separatekk\-NN score calculated using the identical encoder embeddings to isolate the contribution of the scoring strategy from the underlying representation\. The consolidated comparison across all methods and datasets is Table[5](https://arxiv.org/html/2608.14666#S5.T5), and the full per\-dataset breakdown with native scores is in the appendix \(Table[11](https://arxiv.org/html/2608.14666#Sx1.T11)\)\.
Two primary empirical conclusions follow from these results\. First the scoring strategy operates as the dominant factor for all reconstruction\-based methodologies\. Replacing the native reconstruction\-error metric with akk\-NN distance score on the identical embeddings increases the USAD performance from0\.5370\.537to0\.8990\.899to achieve a net improvement of\+0\.362\+0\.362\. This change similarly raises the variational autoencoder from0\.6620\.662to0\.9060\.906for an improvement of\+0\.244\+0\.244and elevates the standard autoencoder from0\.8490\.849to0\.9070\.907to gain\+0\.058\+0\.058\. Deep SVDD represents the sole exception to this trend because its hypersphere geometry intrinsically favours its native centre\-distance metric yielding0\.8920\.892compared to a suboptimal0\.6460\.646under thekk\-NN protocol\. Second the three reconstruction encoders are nearly indistinguishable under the unifiedkk\-NN protocol by spanning a narrow performance range between0\.8990\.899and0\.9070\.907\. The proposed CMR\-Mamba framework exceeds the strongest of these baselines by approximately0\.0480\.048on this specific split\. The single\-split baseline figures in this table are not directly comparable with the 15\-fold CMR result quoted above, because the latter uses per\-fold selection while the baselines use a single fixed configuration\. Under the fixed protocol applied identically to all fifteen folds, CMR\-Mamba reaches0\.88030\.8803against0\.88500\.8850for USAD,0\.87360\.8736for the VAE, and0\.86740\.8674for the autoencoder, which places the four methods within0\.0180\.018of one another\. The Anomaly Transformer cannot execute at the standard Paderborn window length of32,76832,768samples corresponding to8,1928,192tokens because its𝒪\(N2\)\\mathcal\{O\}\(N^\{2\}\)self\-attention mechanism completely exhausts available GPU memory\. This computational bottleneck highlights the practical scalability advantage of the linear\-time Mamba encoder architecture at industrial scale\.
#### 5\.2\.2\.Baseline Comparison on the ZeMA and SWaT Datasets
The identical matched comparison framework was executed on the hydraulic leakage task and the cyber\-physical testbed\. Both evaluation domains reproduce the central pattern rather than the exact ordering, withkk\-NN scoring dominating native scoring, the reconstruction encoders clustering tightly, and CMR\-Mamba staying competitive with the strongest of them\. This consistency establishes that the performance differences are not an isolated property of bearing vibration signatures\.
The four one\-class baseline models are evaluated on the ZeMA dataset using identical data splits and random seeds alongside uniformkk\-NN scoring\. Each baseline model is assessed at its respective optimal neighbourhood size using a multi\-seed protocol to ensure an equal statistical footing \(full detail in the appendix, Table[12](https://arxiv.org/html/2608.14666#Sx1.T12)\)\. A multi\-seed variational autoencoder emerges as the single strongest methodology on the ZeMA dataset by achieving an AUROC of0\.9979±0\.00060\.9979\\pm 0\.0006which places it marginally above the CMR\-Mamba score of0\.98430\.9843\. This performance gap of0\.01360\.0136remains minor yet consistent\. The variational latent space of the variational autoencoder forces the posterior mean to remain smooth and consistent during normal operational cycles\. This constraint yields a highly clean manifold structure for subsequentkk\-NN scoring within this single\-setting dataset\. Conversely the standard autoencoder represents both the weakest baseline and the least stable configuration by yielding an AUROC of0\.7787±0\.13220\.7787\\pm 0\.1322\. The performance of the autoencoder across different seeds spans a wide range from approximately0\.530\.53to0\.830\.83whereas the standard deviation of CMR\-Mamba is twenty times lower\. Deep SVDD achieves its optimal performance at the smallest neighbourhood size ofk=1k=1and degrades monotonically askkincreases\. This trend reflects the specific geometric constraints of its hypersphere optimisation objective\. The variational autoencoder is intentionally retained in this comparative analysis\. Although it marginally outperforms CMR\-Mamba on the ZeMA dataset the broader cross\-dataset evaluation demonstrates that no single baseline model remains competitive with CMR\-Mamba across all evaluated domains\. Omitting the strongest baseline would weaken the overall comparative validity of the framework\.
The comparative evaluation on the SWaT dataset assesses CMR\-Mamba against the autoencoder and the variational autoencoder\(kingma2014vae\)and the USAD framework\(audibert2020usad\)and Deep SVDD\(ruff2018deep\)alongside the Anomaly Transformer\(xu2022anomaly\)\. All models are evaluated under matched conditions utilising the identical windows and splits and random seeds \(full leaderboard in the appendix, Table[13](https://arxiv.org/html/2608.14666#Sx1.T13)\)\. The baseline methods cluster tightly within a narrow performance band between0\.860\.86and0\.870\.87\. This close clustering matches expectations from the exploratory data analysis\. The median sensor total\-variation distance serves as a metric for the separation of two probability distributions across a range from0for identical distributions to11for disjoint distributions\. This distance metric computed between the normal and attack marginal distributions of each sensor yields a value of0\.610\.61\. This intermediate value indicates that the majority of SWaT anomalies are blunt attacks that are detectable by any standard model\. Aggregate AUROC metrics consequently provide limited separation between the architectures\. The variational autoencoder formally achieves the highest value at0\.87060\.8706followed by CMR\-Mamba at0\.86790\.8679\. This performance gap of0\.00270\.0027falls within overlapping confidence intervals and replicates the near\-tie conditions observed on the ZeMA dataset\. The mechanism residual of the CMR architecture nonetheless outperforms the autoencoder and USAD along with its ownkk\-NN score\. Only the variational autoencoder edges the proposed framework\. Thekk\-NN scoring strategy universally dominates native reconstruction scoring across all evaluation sets\. This change elevates the reconstruction baselines from approximately0\.770\.77under native scoring to approximately0\.860\.86under thekk\-NN framework\.
Deep SVDD yields a lower score of0\.8400\.840and the Anomaly Transformer trails the performance cluster at0\.7610\.761\. The performance of the Anomaly Transformer provides critical insights regarding architectural selection\. This attention\-based model is computationally intractable on the Paderborn dataset due to its𝒪\(L2\)\\mathcal\{O\}\(L^\{2\}\)attention mechanism which exhausts available GPU memory at an8,1928\{,\}192\-token window length\. The SWaT dataset utilises a short window length of 256 steps which allows the Anomaly Transformer to execute without memory pressure\. It nonetheless functions as the weakest method on this dataset\. This lower performance demonstrates that even where self\-attention remains computationally tractable it is not competitive with the alternative architectures\. This empirical result validates the choice of a linear\-time state\-space backbone based on accuracy considerations rather than memory limits alone\. The Anomaly Transformer also represents the single method where thekk\-NN scoring protocol fails to improve upon the native score\. Both metrics remain flat across all evaluatedkkvalues at approximately0\.760\.76\. The association\-discrepancy objective optimisation shapes the resulting attention maps rather than generating a distance\-friendly embedding manifold\. Thekk\-NN manifold trick that systematically elevates the reconstruction baselines is therefore inapplicable to this attention\-centric architecture\.
#### 5\.2\.3\.Reconstruction Scoring of the CMR Encoder
This contrast sharpens when the identical evaluation protocol is applied directly to the proposed CMR encoder\. Evaluating the CMR encoder via reconstruction error yields an AUROC of only0\.6850\.685\. This value falls substantially below both its ownkk\-NN score of0\.9550\.955and the plain autoencoder reconstruction score of0\.8490\.849\. This outcome occurs by design rather than representing an architectural deficiency\. The causal regulariser intentionally shapes the encoder toward a compact healthy manifold instead of prioritising faithful waveform reconstruction\. Reconstruction error consequently becomes a poor anomaly signal\. The resulting manifold simultaneously becomes the most discriminative representation among all evaluated encoders\. Identical network weights thus yield an AUROC of0\.6850\.685under decoder\-based scoring alongside0\.9550\.955under decoder\-freekk\-NN scoring\. The binding operational constraint is therefore the anomaly scoring rule rather than the underlying representation\. Even the strongest encoder in this study fails under pure reconstruction scoring\. The true detection value of the representation is recovered exclusively through manifold distance evaluation\.
The single largest performance variation observed in this study stems from the choice of anomaly score rather than the choice of encoder architecture\. Replacing the native reconstruction or association score of a baseline method with akk\-nearest\-neighbour distance on the identical embeddings improves the AUROC substantially and consistently as illustrated in Figure[5](https://arxiv.org/html/2608.14666#S5.F5)\. The USAD performance on the Paderborn dataset rises from0\.5370\.537to0\.8990\.899to yield a\+0\.362\+0\.362improvement\. The variational autoencoder on the same dataset rises from0\.6620\.662to0\.9060\.906to achieve a\+0\.244\+0\.244gain\. The standard autoencoder on the ZeMA dataset rises from0\.3580\.358to0\.7790\.779representing a\+0\.421\+0\.421increase\. All reconstruction baselines on the SWaT dataset similarly rise from approximately0\.7690\.769to approximately0\.860\.86for a net\+0\.09\+0\.09gain\. The absolute performance gain derived fromkk\-NN scoring ranges from\+0\.09\+0\.09to\+0\.42\+0\.42\. This scoring improvement completely dwarfs the architectural gain achieved by adding the causal regulariser to a plain autoencoder which spans only\+0\.01\+0\.01to\+0\.18\+0\.18\.
This empirical finding carries two primary consequences\. From a practical perspective it demonstrates that industrial practitioners deploying reconstruction\-based detectors can recover a massive portion of the achievable performance ceiling simply by transitioning tokk\-NN scoring on their existing embeddings without requiring model retraining\. From a conceptual perspective it reframes the fundamental contribution of the CMR\-Mamba architecture\. The causal mechanism does not function primarily by artificially inflating detection scores\. The mechanism operates instead by organising the embedding manifold to ensure that critical operational faults are displaced in geometrically salient directions\. This structured representation simultaneously furnishes the mechanism\-residual score that no standard reconstruction methodology possesses\.
Figure 5\.kk\-NN manifold scoring versus native reconstruction scoring across datasets and methods\.
### 5\.3\.The Mechanism Residual on Low\-Separability Faults
The consolidated scores in Section[5\.2](https://arxiv.org/html/2608.14666#S5.SS2)separate the architectures by hundredths of an AUROC point on two of the three datasets, which is an artefact of the saturated aggregate rather than equal capability\. All models isolate severe ZeMA leakage at≈1\.0\\approx 1\.0, and the SWaT median sensor total\-variation distance of0\.610\.61shows most attacks drive at least one sensor out of range, so a method that handles only this easy majority scores almost the same as one that also handles the hard cases\.
CMR\-Mamba targets the opposite class, faults where every channel stays within its normal range while the relationship between channels breaks\. These coupling violations form the low\-separability hard subset of each dataset, and evaluating on them alone is the discriminating test that shows the mechanism residual is a distinct capability rather than another scoring rule\. SWaT gives the clearest such test and Paderborn the second\.
The aggregate near\-tie between CMR\-Mamba and the VAE hides a qualitative divergence in which anomalies each isolates\. Most SWaT attacks are blunt and drive an affected sensor beyond its healthy range, while a critical minority are stealthy and keep every sensor within its normal historical thresholds so the window looks globally on\-distribution\. Reconstruction and distribution\-based methods flag only off\-distribution windows and are structurally blind to the stealthy attacks, whereas the mechanism residual instead asks whether the observed effect sensors stay physically consistent with the concurrent actuator commands\.
A model\-free marginal deviation is calculated for each test window by isolating the maximum absolute time\-averaged z\-score across the2525effect sensors to quantify how far any single channel strays from its historical healthy range\. Attack windows that fall below the9595th percentile of the healthy marginal deviation are formally labelled as stealthy due to their marginal indistinguishability from normal operations\. The remaining windows are categorized as blunt\. This classification split yields192192stealthy attack windows and304304blunt attack windows\. Every method is subsequently evaluated by calculating the resulting AUROC against healthy windows separately across these two distinct subsets as documented in Table[6](https://arxiv.org/html/2608.14666#S5.T6)\.
The disaggregated results justify the causal formulation in a way the aggregate hides\. On the stealthy subset the CMR mechanism residual leads at0\.7470\.747, ahead of the VAE at0\.7010\.701and every other baseline, while the pure\-marginal scores collapse below chance to about0\.400\.40, confirming these coupling anomalies are invisible to marginal detectors\. The ordering reverses on the blunt subset, where marginal and reconstruction methods reach0\.970\.97to0\.9990\.999and the mechanism residual stays effective at0\.9490\.949but trails them\. Because blunt windows outnumber stealthy ones304304to192192, the VAE’s edge on the blunt majority produces the marginally higher aggregate and the near\-tie of Section[5\.2](https://arxiv.org/html/2608.14666#S5.SS2)\.
Two conclusions follow\. First, the mechanism residual is a distinct detection capability, not an alternative scoring trick, isolating the stealthy coupling\-violating attacks that a VAE or autoencoder cannot capture, which are exactly what an adversary would design to evade marginal monitoring\. Second, the residual and reconstruction manifold scoring are complementary, so a deployed monitor is best served by both, using reconstruction for blunt anomalies and the residual for stealthy ones\. The stealthy subset of192192windows warrants caution on precise margins, but the qualitative pattern is unambiguous, with the causal residual best on stealthy attacks and marginal methods best on blunt ones\.
Because the stealthy subset is defined by a single percentile cut of the model\-free marginal deviation, its robustness to that cut matters\. Re\-splitting the attack windows at the 90th, 95th, and 99th healthy percentiles leaves the ordering unchanged\. The CMR stop\-gradient mechanism residual leads the stealthy subset at every threshold, at0\.7470\.747,0\.7470\.747, and0\.7530\.753, ahead of the VAE at0\.7010\.701,0\.7010\.701, and0\.7080\.708, while the pure\-marginal score and the native VAE stay between0\.400\.40and0\.440\.44throughout\. The 90th and 95th cuts give the identical subset because no attack window falls between the two thresholds, and the 99th cut adds eleven borderline windows without moving the result\. The stealthy advantage is therefore a property of the attacks rather than of the chosen threshold\.
Table 6\.Stealthy versus blunt attack detection on SWaT \(AUROC against healthy, 3\-seed mean\)\. On stealthy attacks the CMR mechanism residual leads, and on blunt attacks the marginal and reconstruction methods lead\.#### 5\.3\.1\.Artificial Defect Faults on the Paderborn Dataset
Paderborn shows the same dichotomy, here set by the physics of the damage rather than an attacker’s intent\. Real damage produces distributed energetic signatures that every reconstruction baseline detects above0\.970\.97, while artificial defects are geometrically idealised and perturb the current\-to\-vibration coupling far more subtly, and they carry the aggregate variance\. Under the fixed 15\-fold protocol CMR\-Mamba is the strongest of the learned detectors on the artificial faults, at0\.7920\.792against0\.7540\.754for the strongest baseline, USAD, winning ten of fifteen folds against USAD and the VAE, eleven against the autoencoder, and fourteen against Deep SVDD\. On the single tuning split the ordering is sharper, at0\.9000\.900against0\.8090\.809for the autoencoder\. Real damage is detected reliably by every strong method, the0\.970\.97figures above being single\-split values, and CMR\-Mamba reaches0\.9440\.944across the fifteen folds, so the methods separate on the artificial\-defect subset rather than on real damage\. That artificial\-subset margin is far larger than the hundredths separating the methods on the aggregate, so the architectures are near\-parity on easy faults and diverge on the harder ones\.
Table[7](https://arxiv.org/html/2608.14666#S5.T7)compares both hard subsets\. ZeMA has no equivalent entry, because its weak\-leakage faults, though harder than severe leakage, are still resolved near\-perfectly by the strongest baselines, so it offers no subset that separates the methods\.
The conclusion aligns with the causal claim\. The mechanism residual does not inflate scores on easy anomalies, it enables detection of a fault class that evades marginal and reconstruction scoring entirely, the coupling\-violating anomalies\. That capability adds only a few thousandths to the aggregate but becomes decisive on the attacks an adversary engineers and the subtle defects of early bearing failure, contributing an absolute margin of0\.050\.05to0\.090\.09on these subsets and fixing the performance hierarchy\.
Table 7\.Hard\-subset comparison\. On each dataset’s low\-separability faults, the ones the coupling paradigm targets, CMR\-Mamba is the best of the evaluated learned detectors\. The PU values come from the fixed 15\-fold protocol with identicalkk\-NN scoring for all methods, and the SWaT values are the 3\-seed mean from Table[6](https://arxiv.org/html/2608.14666#S5.T6)\. “Marginal” is the model\-free per\-sensor deviation score\.
### 5\.4\.Ablation Studies
#### 5\.4\.1\.Loss\-Weight Ablations on Paderborn
The three loss weights in Equation \([7](https://arxiv.org/html/2608.14666#S3.E7)\) were set by single\-split ablations on the standard evaluation split of about4,4864\{,\}486healthy training windows and23,57823\{,\}578test windows, then validated under the full 15\-fold protocol\. Single\-split values carry the per\-fold noise quantified in Section[5\.1\.1](https://arxiv.org/html/2608.14666#S5.SS1.SSS1), a 15\-fold standard deviation of about0\.0350\.035, so they are read as trends\. The weights were tuned by coordinate descent from a working point, sweeping one weight while the other two were held fixed\. The reconstruction weightsαx\\alpha\_\{x\}andαy\\alpha\_\{y\}anchor the encoders to their inputs and are set first, andγ\\gammais swept afterwards atαx=0\.75\\alpha\_\{x\}=0\.75,αy=1\.0\\alpha\_\{y\}=1\.0\. The stop\-gradient is structural rather than a tunable weight and is evaluated separately below\.
##### Reconstruction Weightsαx\\alpha\_\{x\}andαy\\alpha\_\{y\}
Each reconstruction weight is swept as a one\-dimensional slice averaged over three runs \( Figure[9](https://arxiv.org/html/2608.14666#Sx1.F9)in the appendix\), withαx\\alpha\_\{x\}varied atαy=1\.0\\alpha\_\{y\}=1\.0and thenαy\\alpha\_\{y\}varied at the selectedαx=0\.75\\alpha\_\{x\}=0\.75\. The current weight peaks atαx=0\.75\\alpha\_\{x\}=0\.75with0\.9573±0\.00310\.9573\\pm 0\.0031, andαx=0\\alpha\_\{x\}=0drops it to0\.93930\.9393because the cause encoder then sees no reconstruction signal, while the range0\.250\.25to1\.01\.0stays within0\.9420\.942to0\.9570\.957\. The vibration weight collapses to0\.88890\.8889atαy=0\\alpha\_\{y\}=0, confirming the effect encoder needs a reconstruction anchor, and is otherwise flat, withαy∈\{0\.5,0\.75,1\.0\}\\alpha\_\{y\}\\in\\\{0\.5,0\.75,1\.0\\\}within0\.0050\.005of one another at0\.93960\.9396,0\.94570\.9457, and0\.94660\.9466\. We fix\(αx,αy\)=\(0\.75,1\.0\)\(\\alpha\_\{x\},\\alpha\_\{y\}\)=\(0\.75,1\.0\), matching the vibration channel’s role as the monitored effect\.
##### Mechanism Loss Weightγ\\gamma
The weightγ\\gammacontrols how strongly the causal\-mechanism term shapes the learned embedding relative to signal reconstruction\. The parameterγ\\gammais evaluated across the set\{0\.0,0\.05,0\.1,0\.2,0\.5,1\.0\}\\\{0\.0,0\.05,0\.1,0\.2,0\.5,1\.0\\\}while maintainingαx=0\.75\\alpha\_\{x\}=0\.75andαy=1\.0\\alpha\_\{y\}=1\.0as constant values\. Table[14](https://arxiv.org/html/2608.14666#Sx1.T14)reports these results\.
The response is unimodal and peaks at0\.94050\.9405atγ=0\.2\\gamma=0\.2, which we adopt\. Smaller weights under\-enforce the mechanism and leave the embedding close to a plain reconstruction, for example0\.92030\.9203atγ=0\.05\\gamma=0\.05, while larger weights over\-constrain it against reconstruction fidelity,0\.92290\.9229atγ=0\.5\\gamma=0\.5\. The overall AUROC stays within a0\.0210\.021span across the whole range, and the real\-damage score is near\-saturated between0\.9840\.984and0\.9950\.995throughout, soγ\\gammaacts mainly on the harder artificial\-fault subset\. Both theαx\\alpha\_\{x\}slice and thisγ\\gammaslice were run atγ=0\.2\\gamma=0\.2, so their shared nominal point\(αx,αy,γ\)=\(0\.75,1\.0,0\.2\)\(\\alpha\_\{x\},\\alpha\_\{y\},\\gamma\)=\(0\.75,1\.0,0\.2\)is the same configuration, and the small difference between the two reported values \(0\.95730\.9573against0\.94050\.9405\) is single\-split run\-to\-run variation between two independent coordinate\-descent passes\. The operating point is confirmed under the 15\-fold protocol in Section[5\.1\.1](https://arxiv.org/html/2608.14666#S5.SS1.SSS1)\.
#### 5\.4\.2\.Embedding Strategy and Neighbourhood Size on Paderborn
The decoder is discarded during inference\. The method used to pool the token\-sequence embedding into a fixed\-length descriptor and the specifickk\-NN configuration therefore materially affect detection performance\. Eight pooling strategies were evaluated for each trained model\. Each strategy was swept acrossk∈\{1,5,10,20,50,100\}k\\in\\\{1,5,10,20,50,100\\\}and the distance metric∈\{ℓ2,cosine\}\\in\\\{\\ell\_\{2\},\\mathrm\{cosine\}\\\}\. Table[15](https://arxiv.org/html/2608.14666#Sx1.T15)ranks these strategies by their mean AUROC over the 45 models with each evaluated at its respective optimalkkand metric combination\. Figure[6](https://arxiv.org/html/2608.14666#S5.F6)shows the complete strategy×k\\times kgrid, from which this ranking follows as the per\-row optimum, and also shows that AUROC is nearly flat inkkfor every usable strategy\.
Three findings follow\. The original384384\-dimensionalmean\+std\+maxdescriptor and plainmax\-poolare the weakest usable strategies at≈0\.69\\approx 0\.69, because the maximum component is dominated by transient peaks on Paderborn, which motivates moment\-based and concatenated descriptors\. The best are the cause\-effect concatenation at0\.89120\.8912and the cause\-conditioned effect mean at0\.88460\.8846, both stable across folds atstd≈0\.045\\mathrm\{std\}\\approx 0\.045against thestd\-pool’sstd≈0\.109\\mathrm\{std\}\\approx 0\.109, whose spread comes almost entirely from the single hard fold diagnosed in Section[5\.1\.1](https://arxiv.org/html/2608.14666#S5.SS1.SSS1)\. The AUROC is nearly insensitive tokk, within0\.0050\.005acrossk∈\[1,100\]k\\in\[1,100\]for every usable strategy, unlike the hydraulic dataset where a specifickkis required, which indicates a compact well\-separated healthy manifold on which a single neighbour suffices\.
Figure 6\.PU strategy×k\\times\\,kmean AUROC \(cosine, 15 folds×\\times3 runs\)\. Themax\-based descriptors \(max\-pool, mean\+std\+max\) are uniformly weak, and every other strategy is near\-flat inkk\.
#### 5\.4\.3\.The Stop\-Gradient and Training\-Set Size
Across datasets the stop\-gradient looks contradictory\. It adds\+0\.068\+0\.068AUROC on Paderborn, subtracts−0\.056\-0\.056on ZeMA, and adds\+0\.044\+0\.044to the SWaTkk\-NN score\. The cases reconcile once training\-set size and the presence of a cause\-encoder reconstruction loss are read together, since the datasets vary both at once\. This section works through that interaction, starting with the most sensitive dataset\.
##### Stop\-Gradient Ablation on the Paderborn Dataset
The mechanism loss predicts the effect embedding from the cause embedding, and the stop\-gradient on the effect target stops the two encoders co\-adapting into a degenerate shared representation\. An otherwise identical model trained on a common split with the stop\-gradient removed \(Table[16](https://arxiv.org/html/2608.14666#Sx1.T16)in the appendix\) drops the overall AUROC by0\.0680\.068from0\.93900\.9390to0\.87140\.8714\. The effect\-embedding standard deviation stayed well above the collapse threshold throughout, so this is not representational collapse but the two encoders drifting toward a shared less\-discriminative space\. The loss is largest on artificial faults at−0\.090\-0\.090and smaller on real damage at−0\.052\-0\.052, so the stop\-gradient is a structural part of the causal formulation rather than a stability trick\.
##### Stop\-Gradient Ablation on the ZeMA Dataset
The same ablation on ZeMA reverses\. Removing the stop\-gradient raises the overall AUROC by0\.0560\.056and cuts the seed standard deviation six\-fold from0\.04090\.0409to0\.00650\.0065\(Table[17](https://arxiv.org/html/2608.14666#Sx1.T17)in the appendix, each variant at its optimalkk\)\. The reversal comes from the interaction between training\-set size and the cause\-reconstruction weight\.
On ZeMAαx=0\\alpha\_\{x\}=0\(Section[5\.5\.1](https://arxiv.org/html/2608.14666#S5.SS5.SSS1)\), so the cause encoder gets no reconstruction gradient, and the stop\-gradient additionally severs the mechanism gradient into the effect target, leaving the cause encoder with only the mechanism prediction error\. On just415415cycles this starves it and its representation under\-trains\. Removing the stop\-gradient restores a direct mechanism signal to the cause encoder, which acts as useful regularisation on a tiny dataset, unlike the harmful co\-adaptation it causes on a large dataset that already supplies a reconstruction constraint such as Paderborn whereαx\>0\\alpha\_\{x\}\>0\.
Training\-set size and cause\-reconstruction weight vary together between Paderborn and ZeMA, so these two datasets alone leave the account under\-determined and a third dataset is needed to separate the variables\.
##### Stop\-Gradient Ablation on the SWaT Dataset
On SWaT the stop\-gradient variant wins, with the mechanism residual at0\.86790\.8679against0\.85570\.8557and thekk\-NN score at0\.86290\.8629against0\.81860\.8186\(Figure[7](https://arxiv.org/html/2608.14666#S5.F7)\), matching Paderborn and opposing ZeMA\. SWaT shares ZeMA’sαx=0\\alpha\_\{x\}=0but has enough data to avoid gradient starvation, so dataset size, not the reconstruction weight, is the primary determinant\.
The practical rule follows\. Keep the stop\-gradient when the cause channel has its own reconstruction weight or when the training set is large enough to train the cause encoder through the mechanism loss alone, and omit it only when both are absent, that is an unreconstructed cause encoder on a few hundred samples\.
Figure 7\.Stop\-gradient effect across the three datasets\.
#### 5\.4\.4\.Manifold Geometry Across Domains
Rather than treating the neighbourhood sizekkmerely as a free hyperparameter to be tuned, it is more accurate to view it as a direct readout of the healthy manifold’s compactness\. Across the three datasets, this metric reveals three distinct geometric profiles\.
ZeMA shows a pronounced optimum, contrasting sharply with Paderborn’s near\-indifference tokk\(Table[18](https://arxiv.org/html/2608.14666#Sx1.T18)in the appendix, both variants\)\. The no\-stop\-gradient variant peaks atk=20k=20, while the stop\-gradient variant requiresk=50k=50\. This optimal value acts as a gauge for manifold quality: a compact, well\-separated manifold requires only a few neighbours, whereas a noisier one relies on a wider radius to average out local irregularities\. Consequently, the no\-stop\-gradient training produces a much better\-structured space, perfectly aligning with its higher and more stable AUROC\. Paderborn’s indifference acrossk∈\[1,100\]k\\in\[1,100\]against ZeMA’s sharp optimum reflects the fact that ZeMA’s manifold, learned from only415415cycles around a single operating point, is more sharply defined, making the exact choice ofkkcritical\. However, ifkkis pushed too high, performance across both variants collapses to an AUROC of≈0\.38\\approx 0\.38atk=200k=200\. Askkapproaches the total reference bank size of415415, the distance metric stops discriminating—a generic large\-kkartefact observed across all datasets\.
SWaT occupies the opposite geometric extreme \(Table[19](https://arxiv.org/html/2608.14666#Sx1.T19)in the appendix, showing the CMRkk\-sweep with the mechanism residual for both variants\)\. Three key observations emerge here\. First, the mechanism residual proves to be the strongest CMR metric, achieving0\.86790\.8679for the stop\-gradient variant\. This outperforms its ownkk\-NN score and, as discussed in Section[5\.2](https://arxiv.org/html/2608.14666#S5.SS2), beats every baseline except the VAE\. This indicates that the causal signal captures critical fault information that a simple manifold distance misses\. Second, SWaT’skk\-NN score is nearly invariant to changes inkk, hovering tightly between0\.8460\.846and0\.8630\.863across the entirek∈\[1,200\]k\\in\[1,200\]range\. This mirrors Paderborn’s stability while directly contrasting with ZeMA\. Finally, SWaT suffers no large\-kkcollapse\. While ZeMA crashes to≈0\.38\\approx 0\.38atk=200k=200, SWaT holds steady near0\.850\.85\. This resilience proves that the cyber\-attack signal is broadly distributed throughout the latent space, rather than being confined to a narrow local neighbour\.
### 5\.5\.Cross\-Domain Transfer
The preceding subsections evaluated all three datasets simultaneously\. This subsection analyses the specific framework modifications required to enable that cross\-domain functionality\. The architectural components remain largely invariant\. The encoder and the loss function and the optimiser alongside the scoring rule are identical across every domain as documented in Table[3](https://arxiv.org/html/2608.14666#S4.T3)and Table[Full Architecture and Training Specification](https://arxiv.org/html/2608.14666#Sx1.SSx1)and Table[Full Architecture and Training Specification](https://arxiv.org/html/2608.14666#Sx1.SSx1)\. The framework exclusively adapts the treatment of the cause channel\. This specific adaptation follows established physical principles rather than relying on empirical hyperparameter searches\. The comparison against the strongest baseline and the limits of the approach are taken up in the discussion of Section[6](https://arxiv.org/html/2608.14666#S6)\.
The full per\-domain instantiation, the causal pairs, window lengths, channel pruning, and train, validation, and test splits, is specified in Section[4\.1](https://arxiv.org/html/2608.14666#S4.SS1)and Table[3](https://arxiv.org/html/2608.14666#S4.T3), and is not repeated here\. The one setting that does not transfer uniformly across domains is the cause\-reconstruction weight, examined next\.
#### 5\.5\.1\.Cause Reconstruction Weight Across Domains
The cause reconstruction weight represents the singular architectural setting that fails to transfer uniformly across datasets\. This specific parameter requires a distinct optimal value within each evaluation domain\. These numerical differences track the physical composition of the underlying cause signal rather than reflecting an arbitrary limitation of the model architecture\.
The weight parameterαx\\alpha\_\{x\}dictates the degree to which the cause encoder anchors to reconstructing the EPS1 signal compared to being shaped exclusively by the causal\-mechanism objective\. This coefficient was systematically swept across the specific values of0\.00\.0and0\.250\.25and0\.50\.5and0\.750\.75and1\.01\.0\. Table[20](https://arxiv.org/html/2608.14666#Sx1.T20)documents the resulting performance metrics\.
The optimum falls atαx=0\\alpha\_\{x\}=0, giving0\.99770\.9977overall\. This is physically interpretable\. Paderborn motor current is dominated by the electromagnetic drive that causes the vibration, so reconstructing it retains causal signal andαx=0\.75\\alpha\_\{x\}=0\.75helps, whereas ZeMA motor power carries electrical overhead unrelated to the hydraulic response, so reconstructing it forces the encoder to keep noise that pollutes the predictor\. Atαx=0\\alpha\_\{x\}=0the cause encoder acts as a pure causal feature extractor, coherent with the no\-stop\-gradient training of Section[5\.4\.3](https://arxiv.org/html/2608.14666#S5.SS4.SSS3)in which the mechanism loss alone trains it\. The sweep used a single seed, and theαx=0\\alpha\_\{x\}=0choice is confirmed by the multi\-seed0\.9843±0\.00650\.9843\\pm 0\.0065of Section[5\.1\.2](https://arxiv.org/html/2608.14666#S5.SS1.SSS2), with the apparent dip atαx=0\.5\\alpha\_\{x\}=0\.5a seed artefact that re\-evaluation places near0\.920\.92\.
SWaT behaves differently\. Sweeping the cause weight across0,0\.250\.25,0\.50\.5,0\.750\.75, and1\.01\.0\(Table[21](https://arxiv.org/html/2608.14666#Sx1.T21)\) leaves both the mechanism residual and thekk\-NN AUROC flat, within0\.0050\.005across the range, soαx=0\\alpha\_\{x\}=0is adopted for efficiency, since dropping the cause reconstruction removes the actuator decoders and cuts parameters\. Where ZeMA motor power carries non\-causal overhead that an enforced reconstruction term degrades, the heavily pruned SWaT actuator set is already a clean cause group, so adding a reconstruction weight changes nothing\.
The SWaT dataset deviates structurally from the single\-coupling bearing and hydraulic evaluations\. The water treatment facility incorporates six distinct operational stages with cyber\-attacks distributed broadly across all segments\. A single cause\-effect pair cannot adequately monitor the entire plant\. The designated cause and effect groups are consequently formulated as multi\-channel tensors\. The empirical data strictly dictates which specific sensors carry a learnable physical mechanism\. A simple linear least\-squares regression model was fitted exclusively on normal operation data to evaluate this property\. This regression model predicts the output of each individual sensor based entirely on the1212active actuator signals\. The coefficient of determination was subsequently extracted to quantify the fraction of sensor variance mathematically explained by the actuators\. AnR2R^\{2\}value approaching11indicates that the specific sensor is fully determined by the active control commands\. AnR2R^\{2\}value approaching0indicates that the sensor is driven primarily by external unmonitored phenomena\. This standard goodness\-of\-fit metric functions strictly as an initial screening statistic\. The fluid flows and tank levels driven directly by mechanical pumps and valves prove to be highly predictable\. TheR2R^\{2\}values span from0\.940\.94to0\.990\.99for the specific stage flows and reach0\.790\.79for the primary stage\-one tank level\. The chemical analysers and reverse\-osmosis pressures yieldR2R^\{2\}values below0\.150\.15because they are governed entirely by complex membrane and chemistry dynamics\. The mechanism residual is therefore measured exclusively across the eight strongly coupled hydraulic sensors\. The comprehensivekk\-NN anomaly score continues to utilise all twenty\-five sensors to ensure total plant coverage\. This strict data\-driven separation encodes the entire system for global anomaly detection but isolates the precise mechanism residual strictly to the channels where a provable physical coupling exists\. This targeted calculation ensures the mechanism residual avoids mathematical dilution from continuous channels that lack a learnable correlation\.
##### Optimal Cause Regularisation and Sensor Physics
The architectural divergence between aαx=0\\alpha\_\{x\}=0optimum on the ZeMA dataset and anαx=0\.75\\alpha\_\{x\}=0\.75optimum on the Paderborn dataset represents a direct mathematical reflection of the signal\-to\-causal\-noise ratio inherent to each cause channel rather than an arbitrary tuning artefact\. Motor current functions as a predominantly causal input for mechanical bearing vibration\. Motor power inherently carries non\-causal electrical overhead that actively dilutes the causal signal if mathematically reconstructed\. The optimal configuration of the proposed framework successfully tracks this fundamental physical distinction\. This adaptability provides compelling evidence that the architecture successfully learns the intended causal relationship instead of defaulting to a generic unconstrained representation\.
## 6\.Discussion and Limitations
The discussion treats the Paderborn results first, since they carry the full ablation, then turns to the cross\-domain comparison against the strongest baseline\.
### 6\.1\.Discussion of the Paderborn Results
The Paderborn experiments establish four primary architectural and empirical conclusions\. First, on Paderborn the framework is robust to its loss weights, though the neighbourhood size, distance metric, cause\-reconstruction weight, and stop\-gradient variant are each set per domain rather than universally fixed\. The mechanism weight peaks atγ=0\.2\\gamma=0\.2but varies the overall AUROC by less than0\.0210\.021across an order\-of\-magnitude evaluation range\. The current weight remains stable between0\.250\.25and1\.01\.0with a clear optimum at0\.750\.75\. Both channels require a reconstruction anchor because settingαx=0\\alpha\_\{x\}=0or settingαy=0\\alpha\_\{y\}=0degrades overall performance\. Second the stop\-gradient operator contributes a structural improvement of\+0\.068\+0\.068AUROC without inducing representation collapse\. On Paderborn this makes it a valuable component, though Section[5\.4\.3](https://arxiv.org/html/2608.14666#S5.SS4.SSS3)shows its benefit is dataset\-dependent rather than universal\. Third the anomaly scoring strategy dominates detection performance for reconstruction\-based methods as detailed in Section[5\.2](https://arxiv.org/html/2608.14666#S5.SS2)\. Under a matched fixed protocol the causal embedding of CMR\-Mamba is competitive with the strongestkk\-NN baseline, trailing USAD by0\.0050\.005on the aggregate while leading it on the artificial\-defect subset, while remaining computationally tractable where attention\-based detectors fail due to hardware limits\. Fourth CMR\-Mamba achieves an overall AUROC of0\.8800\.880under a rigorous 15\-fold leave\-bearing\-out cross\-validation with a single fixed configuration, reaching0\.9440\.944on real damage with run\-to\-run variance bounded within0\.0030\.003, and a per\-fold oracle upper bound of0\.9300\.930\. Total performance is limited primarily by a single hard bearing pair whose healthy signature intrinsically overlaps the faulty manifold\. These collective results validate the causal\-mechanism formulation on electromechanical bearing faults and establish the baseline operating parameters utilised for subsequent evaluations on the hydraulic and cyber\-physical datasets\.
### 6\.2\.Cross\-Domain Comparison and the Strongest Baseline
The strongest baseline is a multi\-seed variational autoencoder withkk\-NN scoring\. It exceeds CMR\-Mamba on ZeMA at0\.9980\.998against0\.9840\.984and ties it on SWaT at0\.8710\.871against0\.8680\.868, within overlapping intervals\. We keep it as the strongest comparator because it corroborates rather than contradicts Section[5\.2](https://arxiv.org/html/2608.14666#S5.SS2), since its strength comes from thekk\-NN protocol and not the variational objective, its native reconstruction score reaching only0\.660\.66to0\.770\.77\. A strong variational autoencoder underkk\-NN scoring is direct evidence that the scoring rule dominates the encoder\.
The aggregate parity hides a decisive subset result\. The variational autoencoder edges CMR\-Mamba only where anomalies are blunt, on ZeMA severe leakage and the SWaT aggregate, within overlapping intervals, and the order reverses on the hard low\-separability faults\. The mechanism residual leads the SWaT stealthy attacks at0\.7470\.747while the variational autoencoder falls to0\.7010\.701and pure\-marginal scores drop below chance, and it leads the Paderborn artificial defects at0\.7920\.792against0\.7540\.754under the fixed 15\-fold protocol, and at0\.9000\.900against the variational autoencoder’s0\.7930\.793on the single tuning split\. A variational autoencoder reports only that a window is off\-manifold, whereas the residual identifies which cause\-to\-effect relationship broke, a fault\-localising signal the baseline lacks\(scholkopf2021causal\)\. The slight aggregate edge is AUROC saturation on blunt faults, not a limit of the causal architecture, which leads on the coupling\-violating faults it was designed to detect\.
##### Competitiveness across domains:
A properly tuned variational autoencoder marginally exceeds CMR\-Mamba on the ZeMA dataset\. CMR\-Mamba conversely exceeds the variational autoencoder on the Paderborn dataset, by0\.9310\.931against0\.9060\.906under per\-fold selection and by0\.88030\.8803against0\.87360\.8736under the fixed protocol, although USAD edges it on the Paderborn aggregate under that same fixed protocol\. No single baseline model is simultaneously the strongest across all three datasets\. USAD’s aggregate edge is specific to Paderborn and does not generalise: it trails CMR\-Mamba by0\.03290\.0329on ZeMA \(0\.95140\.9514against0\.98430\.9843\) and by0\.00200\.0020on SWaT \(0\.86590\.8659against0\.86790\.8679\), so it is not the cross\-domain competitor that the variational autoencoder is\. The standard autoencoder collapses on ZeMA while the Anomaly Transformer remains computationally intractable on Paderborn and the variational autoencoder trails on Paderborn\. CMR\-Mamba consistently performs within0\.0140\.014of the best method on every evaluated domain\. It additionally provides a causal and interpretable representation alongside a mechanism\-residual signal that the reconstruction baselines entirely lack\. This core contribution is therefore best defined as consistent cross\-domain competitiveness paired with structural interpretability rather than as an isolated per\-dataset leaderboard victory\.
## 7\.Conclusion
This research introduced CMR\-Mamba as an unsupervised fault detector that monitors the causal coupling between distinct sensor groups rather than evaluating the marginal appearance of individual signals\. The framework pairs per\-domain Mamba state\-space encoders with a causal cross\-modal predictor\. It scores anomalies utilising akk\-nearest neighbour distance calculated on the healthy effect manifold alongside a dedicated mechanism residual\. The architecture was evaluated across three physically unrelated coupling\-fault domains comprising electromechanical bearings and hydraulic leakage and a cyber\-physical water\-treatment testbed\. CMR\-Mamba proves competitive with the strongest baseline models on the aggregate metrics across all environments\. On the aggregate the leading methods are statistically indistinguishable, and a paired Wilcoxon test on the Paderborn folds cannot separate CMR\-Mamba from USAD, the VAE, or the autoencoder, while the differences on the hydraulic and cyber\-physical datasets fall within overlapping intervals, so no single method dominates the aggregate\. CMR\-Mamba is nonetheless the best of the evaluated learned detectors on the low\-separability hard subset of every dataset that has one, reaching0\.7920\.792against0\.7540\.754on the Paderborn artificial defects and0\.7470\.747against0\.7010\.701on the SWaT stealthy attacks, where marginal methods sit at chance\. It achieves this performance while supplying an interpretable and fault\-localizing signal that pure reconstruction methods cannot mathematically provide\. Two primary findings generalise well beyond this specific architecture\. The anomaly\-scoring strategy rather than the chosen encoder family operates as the dominant driver of detection performance\. Thekk\-NN manifold scoring protocol improves every reconstruction baseline substantially more than any structural change to the encoder\. The mechanism residual provides a distinct and highly security\-relevant detection capability\. It successfully isolates stealthy cyber\-physical attacks that keep every individual sensor within its normal historical range to evade standard marginal detectors\. The scope of the method is stated plainly\. It targets coupling faults, and a fault that leaves the instantaneous cause\-to\-effect relationship intact is by construction invisible to it, whatever score is applied\. Fault classes of that kind were not evaluated here\. Future work will include comprehensive per\-domain parameter sweeps of the cause\-reconstruction weight to definitively confirm its transferability\. Future research will also encompass cross\-rig validation of the hydraulic findings and the mathematical extension of the mechanism residual to achieve multi\-stage root\-cause localization\. The ultimate objective remains the integration of this structured perception module with normative reward\-learning frameworks to realize fully autonomous industrial maintenance agents\.
## Appendix
### Full Architecture and Training Specification
This appendix gives the complete per\-domain specification summarised in the methodology\. Table[Full Architecture and Training Specification](https://arxiv.org/html/2608.14666#Sx1.SSx1)lists the full training and inference settings, and Table[Full Architecture and Training Specification](https://arxiv.org/html/2608.14666#Sx1.SSx1)lists the complete architecture\. The main text reports only the settings needed to read the results, and the full detail is collected here for reproducibility\.
Training and inference settings\. The optimiser, gradient handling, and metric are common to all three domains\. The loss weights and the inference settings differ, and they follow the physical asymmetry in cause\-channel signal\-to\-noise ratio discussed in Section[3\.2](https://arxiv.org/html/2608.14666#S3.SS2)\.HyperparameterPaderbornZeMASWaT\\endfirstheadTable[Full Architecture and Training Specification](https://arxiv.org/html/2608.14666#Sx1.SSx1)continued from previous pageHyperparameterPaderbornZeMASWaT\\endheadcontinued on next page\\endfoot\\endlastfootLoss weights \(Eqs\.[4](https://arxiv.org/html/2608.14666#S3.E4)–[6](https://arxiv.org/html/2608.14666#S3.E6)\)γ\\gamma\(mechanism\)0\.200\.200\.20αy\\alpha\_\{y\}\(effect reconstruction\)1\.001\.001\.00αx\\alpha\_\{x\}\(cause reconstruction\)0\.750\.000\.00Optimiser and scheduleOptimiserAdamWAdamWAdamWInitial learning rate5×10−45\\times 10^\{\-4\}5×10−45\\times 10^\{\-4\}5×10−45\\times 10^\{\-4\}Weight decay10−510^\{\-5\}10−510^\{\-5\}10−510^\{\-5\}β1\\beta\_\{1\},β2\\beta\_\{2\}0\.9, 0\.9990\.9, 0\.9990\.9, 0\.999Warm\-up5 epochs \(linear\)5 epochs \(linear\)5 epochs \(linear\)Post\-warm\-up schedulecosine annealingReduceLROnPlateauReduceLROnPlateauGradient clipping norm1\.01\.01\.0Training budgetBatch size123232Maximum epochs100200150Early\-stopping patience10 epochs15 epochs15 epochsTraining set size∼\\sim4,500 windows415 cycles3,142 windowsWall\-clock per fold or seed∼\\sim3 hours∼\\sim20 minutes∼\\sim3\.3 hoursHardwareShared cluster \(RTX A4000, RTX 4000/4500 Ada, L40S, A100 40 GB\)InferenceReported scorekk\-NN distancekk\-NN distancemechanism residual,kk\-NNTemporal poolingϕ\\phistd \(Eq\.[8](https://arxiv.org/html/2608.14666#S3.E8)\)std \(Eq\.[8](https://arxiv.org/html/2608.14666#S3.E8)\)std \(Eq\.[8](https://arxiv.org/html/2608.14666#S3.E8)\)Neighbourhood sizekk1205Distance metriccosineL2L\_\{2\}L2L\_\{2\}Reference bankall training windows415 healthy cycles3,142 healthy windowsEvaluationValidation strategyleave\-two\-outtemporal splitnormal/attack splitRuns reported15 \(\(62\)\\binom\{6\}\{2\}pairs\)3 seeds3 seedsRandom seedsdeterministic1337, 9999, 7771337, 9999, 777Primary metricAUROCAUROCAUROC, point\-wise F1Stratified metricartificial vs\. realweak vs\. severestealthy vs\. blunt
Complete architecture specification for the three dataset instantiations\. The PerChannelMambaEncoder hyperparameters are identical across datasets, and the only architectural differences sit at the input boundary and at the encoder/decoder sharing pattern, and they arise mechanically from the different sampling rates and sensor counts of the three acquisition systems\.HyperparameterPaderbornZeMASWaT\\endfirstheadTable[Full Architecture and Training Specification](https://arxiv.org/html/2608.14666#Sx1.SSx1)continued from previous pageHyperparameterPaderbornZeMASWaT\\endheadcontinued on next page\\endfoot\\endlastfootInputSampling rate64 kHz100 Hz1 HzInput window length \(samples\)32,7686,000256Sensor channels per window3237 \(12 cause \+ 25 effect\)Cause channel\(s\)Current phase A, BEPS1 \(motor power\)12 active actuators \(pumps, valves\)Effect channelVibrationPS1 \(pump pressure\)25 process sensorsConvStem \(one per encoder instance\)Input→\\tooutput channels1→1281\\to 1281→1281\\to 1281→1281\\to 128Kernel size777Stride444Padding333Output token sequence lengthL′L^\{\\prime\}8,1921,50064Post\-convolution normalisationBatchNorm1dBatchNorm1dBatchNorm1dPost\-convolution activationGELUGELUGELUMamba block \(each of four stacked\)Number of stacked blocksNencN\_\{\\mathrm\{enc\}\}444Model dimensiondmodeld\_\{\\mathrm\{model\}\}128128128State dimensiondstated\_\{\\mathrm\{state\}\}161616Depthwise convolution widthdconvd\_\{\\mathrm\{conv\}\}444Expansion factor222Internal hidden dimension after expansion256256256Normalisation placementpre\-normpre\-normpre\-normFinal LayerNorm after the stackyesyesyesEncoder instances per datasetNumber of encoder instances222Effect\-channel encoderenc\_vib\(dedicated\)enc\_ps1\(dedicated\)enc\_effect\(shared on 25 sensors\)Cause\-channel encoderenc\_curr\(shared on A, B\)enc\_eps1\(dedicated\)enc\_cause\(shared on 12 actuators\)Causal predictorFusion input dimension256 \(concatenated A, B\)128 \(single channel\)1,536 \(12×12812\\times 128\)Fusion output dimension1281283,200 \(25×12825\\times 128\)Fusion dropout probability0\.10\.10\.1Number of causal convolutional blocks333Convolution kernel size555Padding modeleft\-only \(causal\)left\-only \(causal\)left\-only \(causal\)Receptive field \(tokens\)131313Receptive field \(physical time\)0\.81 ms520 ms52 sOutput projection initialisationidentityidentitydefaultDecoder \(one per modality\)Stage 1: feature\-enrichment convolution128→128128\\to 128channels128→128128\\to 128channels128→128128\\to 128channelsStage 2: ConvTranspose1d \(×2\\times 2upsample\)128→64128\\to 64channels128→64128\\to 64channels128→64128\\to 64channelsStage 3: ConvTranspose1d \(×2\\times 2upsample\)64→3264\\to 32channels64→3264\\to 32channels64→3264\\to 32channelsStage 4: projection convolution \(k=7,p=3k\{=\}7,p\{=\}3\)32→132\\to 1channel32→132\\to 1channel32→132\\to 1channelOutput waveform length32,7686,000256Per\-stage normalisation / activationBatchNorm1d / GELUBatchNorm1d / GELUBatchNorm1d / GELUDecoder sharingcause decoder shared on A, Bnoneeffect decoder per sensor, and cause decoder omitted \(αx=0\\alpha\_\{x\}\{=\}0\)Total model sizeTrainable parameters1\.67 M1\.59 M5\.41 M
### Paderborn Bearing Subset
This table lists the 25 Paderborn bearing experiments used in the study and the reason each faulty bearing was selected\. The main text refers to it for the composition of the evaluation set\.
The 25 PU bearing experiments used in this study: 6 healthy bearings used for both training and held\-out testing under leave\-bearings\-out cross\-validation, and 19 faulty bearings for evaluation\. OR = outer race; IR = inner race; IR\+OR = combined\.BearingDamage TypeLocationSeveritySelection Rationale\\endfirstheadTable[Paderborn Bearing Subset](https://arxiv.org/html/2608.14666#Sx1.SSx2)continued from previous pageBearingDamage TypeLocationSeveritySelection Rationale\\endheadcontinued on next page\\endfoot\\endlastfootHealthy Bearings \(no fault; used for training and held\-out test under cross\-validation\)K001–K006———Full healthy envelopeArtificial Faults \(evaluation / test only\)KA01EDMOR1Sole OR EDM Level 1KA03EngraverOR2OR engraver Level 2; severity pair with KA05KA05EngraverOR1OR engraver Level 1; high mechanism\-shift potentialKA07DrillingOR1OR drilling Level 1; hard fault for CMR validationKA08DrillingOR2OR drilling Level 2; severity pair with KA07KI01EDMIR1Sole IR EDM Level 1KI03EngraverIR1IR engraver Level 1; severity pair with KI07KI07EngraverIR2IR engraver Level 2; moderate difficultyReal \(Lifetime\) Faults \(evaluation / test only\)KA04Fatigue pittingOR1OR pitting Level 1; high mechanism\-shift potentialKA15Plastic deform\.OR1Sole OR plastic deformation specimenKA16Fatigue pittingOR2OR pitting Level 2; severity pair with KA04/KA22KA22Fatigue pittingOR1OR pitting Level 1; hardest real OR faultneupane2025multisensorKA30Plastic deformOR1Distributed OR plastic deformationKB23Fatigue pittingIR\+OR2Combined fault Level 2; compound coupling disruptionKB24Fatigue pittingIR\+OR3Combined fault Level 3; severity pair with KB23KB27Plastic deform\.IR\+OR1Sole combined plastic deformation specimenKI04Fatigue pittingIR1IR pitting Level 1; hardest fault in datasetneupane2025multisensorKI14Fatigue pittingIR1IR pitting Level 1; second hard IR specimenKI16Fatigue pittingIR2IR pitting Level 2; severity pair with KI04/KI14
### Per\-Fold and Per\-Seed Detail
Table[8](https://arxiv.org/html/2608.14666#Sx1.T8)gives the per\-fold Paderborn AUROC and Table[10](https://arxiv.org/html/2608.14666#Sx1.T10)the per\-seed ZeMA AUROC\. The main text reports their aggregates, and the full breakdowns are collected here\.
Table 8\.Per\-fold AUROC on PU \(3\-run mean\), under\(αx,αy,γ\)=\(0\.75,1\.0,0\.2\)\(\\alpha\_\{x\},\\alpha\_\{y\},\\gamma\)=\(0\.75,1\.0,0\.2\)\. Each fold holds out the listed healthy bearing pair\.Table 9\.Per\-fold Paderborn AUROC under the fixed evaluation protocol \(std\-pooling,k=1k=1, cosine\), for CMR\-Mamba \(three\-run mean\) and the four baselines evaluated at the same matched protocol\. These are the paired per\-fold values behind the Wilcoxon signed\-rank test reported in Section[5\.1\.1](https://arxiv.org/html/2608.14666#S5.SS1.SSS1)\. CMR\-Mamba exceeds USAD on nine of the fifteen folds, the VAE on nine, the autoencoder on eleven, and Deep SVDD on fourteen\.Table 10\.Per\-seed AUROC on ZeMA at the optimal neighbourhood size\. No\-stop\-gradient atk=20k=20, and stop\-gradient atk=50k=50\.
### Per\-Dataset Baseline Detail
These tables give the per\-dataset baseline comparisons in full, including native reconstruction scores, optimal neighbourhood sizes, and per\-method ranks\. The consolidated cross\-dataset view is Table[5](https://arxiv.org/html/2608.14666#S5.T5)in the main text\. The Anomaly Transformer is absent from the Paderborn comparison because its𝒪\(N2\)\\mathcal\{O\}\(N^\{2\}\)attention exhausts GPU memory at that window length, leaving only 4 of the 15 folds evaluable, and the Paderborn panel of Figure[Per\-Dataset Baseline Detail](https://arxiv.org/html/2608.14666#Sx1.SSx4)uses the fixed evaluation protocol matched across methods\.
Table 11\.Baseline comparison on PU \(single split\)\.kk\-NN scoring on the same embeddings is reported alongside each method’s native score\. The Anomaly Transformer is intractable at the PU window length\.Table 12\.Baseline comparison on ZeMA \(3\-seed mean±\\pmstd, each method at its optimalkk\), with the native reconstruction score for reference\. CMR\-Mamba is competitive with the strongest baseline, andkk\-NN scoring lifts every reconstruction method far above its native score\.\(b\)ZeMA\.\(c\)SWaT\.Figure 8\.Baseline comparison across the three domains, each panel a ranked leaderboard with the CMR\-Mamba bars outlined\. \(a\) On Paderborn the top four methods are statistically tied, as the bracket marks, and CMR\-Mamba’s wide error bar comes from the single hard fold in which a mutually covering bearing pair collapses class separation\. \(b\) On ZeMA, CMR\-Mamba is competitive with the VAE and far more stable than the AE\. \(c\) On SWaT, its mechanism residual is second behind the VAE\.Table 13\.SWaT leaderboard \(3\-seed mean±\\pmstd, each method at its best score\)\.
### Ablation Sweep Detail
The loss\-weight, mechanism\-weight, and embedding\-strategy sweeps referenced in Section[5\.4](https://arxiv.org/html/2608.14666#S5.SS4)are collected here\. The main text reports the selected operating points, and the full sweeps follow\.
Figure 9\.Current \(left\) and vibration \(right\) reconstruction\-weight sweeps on PU \(three\-run mean, shaded±\\pmstd\)\. The current weight peaks atαx=0\.75\\alpha\_\{x\}=0\.75\. The vibration weight degrades sharply atαy=0\\alpha\_\{y\}=0, where the effect encoder loses its reconstruction anchor, then forms a flat plateau acrossαy∈\{0\.5,0\.75,1\.0\}\\alpha\_\{y\}\\in\\\{0\.5,0\.75,1\.0\\\}on whichαy=1\.0\\alpha\_\{y\}=1\.0is adopted\.Table 14\.Mechanism\-weight \(γ\\gamma\) sweep on PU \(single split,αx=0\.75\\alpha\_\{x\}=0\.75,αy=1\.0\\alpha\_\{y\}=1\.0\)\. Overall AUROC peaks atγ=0\.2\\gamma=0\.2\.Table 15\.Embedding\-strategy ranking on PU \(mean over 45 models, each strategy at its own bestkk/metric\)\. The originalmean\+std\+maxdescriptor andmax\-poolcollapse, while concatenation andstd\-pool dominate\.Table 16\.Stop\-gradient ablation on PU \(matched, same split\)\. Removing the stop\-gradient costs0\.0680\.068overall AUROC, and no representational collapse occurs\.Table 17\.Stop\-gradient comparison on ZeMA \(3\-seed mean±\\pmstd, each variant at its optimalkk\)\. Removing the stop\-gradient improves overall AUROC by0\.0560\.056and reduces the seed variance sixfold\.Table 18\.kk\-NN sweep on ZeMA \(3\-seed mean overall AUROC, with weak/severe\)\. No\-stop\-gradient peaks atk=20k=20, stop\-gradient atk=50k=50\. Both collapse atk=200k=200as the neighbourhood approaches the bank size\.Table 19\.CMR\-Mamba on SWaT \(3\-seed mean±\\pmstd, window\-level AUROC\)\. The mechanism residual is the best CMR score, andkkis essentially flat\.Table 20\.Cause\-reconstruction weight \(αx\\alpha\_\{x\}\) sweep on ZeMA\. The optimum isαx=0\.00\\alpha\_\{x\}=0\.00\.Table 21\.Cause\-reconstruction weight \(αx\\alpha\_\{x\}\) sweep on SWaT \(single split, StopGrad\)\. Both scores are flat across the range, andαx=0\\alpha\_\{x\}=0is adopted \(no actuator decoders needed\)\.
## Declaration on the Use of Generative AI
All research reported in this paper, including its conception, methodology, implementation, experiments, analysis, and the writing of the manuscript, was carried out by the authors\. Generative AI tools, including GitHub and Copilot, were used only as assistive aids,i\.e\., to help resolveLaTeXerrors, to check syntax and formatting, to perform grammar and spelling checks, and to make individual paragraphs more concise\. They were not used to generate research ideas, results, or claims\. The authors reviewed all content and take full responsibility for it\.
## ReferencesSimilar Articles
Robust Fault Detection in Mechanical Multimodal Time Series via Self-Supervised Cross-Modal Reconstruction
This paper proposes a multimodal anomaly detection framework for fault detection in mechanical systems using self-supervised cross-modal reconstruction and adaptive thresholding to improve robustness under distribution shifts.
LMT: A Bayesian Framework for Causal Discovery from Textual Alarm Records in Manufacturing Systems
This paper proposes LMT, a Bayesian causal discovery framework that combines LLM-extracted semantic signals from textual alarm records with timestamp-based statistical evidence to infer causal graphs in manufacturing systems.
CAFD: Concept-Aware DNN Fault Detection using VLMs
This paper introduces CAFD, a learning-based approach for DNN fault detection that integrates model-based, distance-based, and a novel concept-based feature called Concept Failure Ratio (CFR) derived from Vision-Language Models. CAFD consistently outperforms state-of-the-art baselines in fault detection rate across multiple datasets and budgets.
MOSAIC: Module Discovery via Sparse Additive Identifiable Causal Learning for Scientific Time Series
This paper introduces MOSAIC, a method for module discovery in scientific time series that combines causal representation learning with sparse additive identifiable causal learning. It aims to recover interpretable latent variables and their associated observations without post-hoc alignment, validated on domains like molecular dynamics and climate data.
Label-free Industrial Fault Detection via Adversarial Inverse Reinforcement Learning: A System for Run-to-Failure Prognostics
The paper proposes an adversarial inverse reinforcement learning framework for machinery fault detection that learns a health reward from normal operational data without requiring fault labels, achieving consistent detection across multiple benchmarks.