Figure 1.
Predictive maintenance architecture for a CNC machine tool, showing how sensor signals flow through acquisition, the PLC and NC control unit, triggering, storage, and operator feedback. The diagram emphasizes that diagnosis quality is set upstream by synchronized sensing and event-driven recording. Adapted and enhanced from Jimenez-Cortadi et al. [
13], licensed under CC BY 4.0.
Figure 1.
Predictive maintenance architecture for a CNC machine tool, showing how sensor signals flow through acquisition, the PLC and NC control unit, triggering, storage, and operator feedback. The diagram emphasizes that diagnosis quality is set upstream by synchronized sensing and event-driven recording. Adapted and enhanced from Jimenez-Cortadi et al. [
13], licensed under CC BY 4.0.
Figure 2.
End- to-end modular framework from raw multi-sensor streams to TCN-based predictions. It summarizes the main stages for preprocessing, multiscale feature construction, training, evaluation, and interpretation within a single reproducible flow.
Figure 2.
End- to-end modular framework from raw multi-sensor streams to TCN-based predictions. It summarizes the main stages for preprocessing, multiscale feature construction, training, evaluation, and interpretation within a single reproducible flow.
Figure 3.
Framework overview linking raw sensor acquisition to feature fusion, TCN inference, and dual outputs for health state classification and remaining useful life estimation, with attention and SHAP-based explanations generated alongside predictions.
Figure 3.
Framework overview linking raw sensor acquisition to feature fusion, TCN inference, and dual outputs for health state classification and remaining useful life estimation, with attention and SHAP-based explanations generated alongside predictions.
Figure 4.
Deployment sketch illustrating a conceptual multi-machine scenario in which multiple machines stream sensor data to a central TCN-based prediction block, with operator-facing outputs including attention heatmaps, SHAP values, and remaining useful life trends.
Figure 4.
Deployment sketch illustrating a conceptual multi-machine scenario in which multiple machines stream sensor data to a central TCN-based prediction block, with operator-facing outputs including attention heatmaps, SHAP values, and remaining useful life trends.
Figure 5.
Parallel coordinates comparison of RMS feature magnitudes across sensors for short, medium, and long window scales. Each polyline represents the RMS feature vector of one windowed sample, and overlapping trajectories are intentional, reflecting natural variability across samples rather than obscuring scientific interpretation. Colors encode the window scale, with red indicating short windows, orange indicating medium windows, and gray indicating long windows.
Figure 5.
Parallel coordinates comparison of RMS feature magnitudes across sensors for short, medium, and long window scales. Each polyline represents the RMS feature vector of one windowed sample, and overlapping trajectories are intentional, reflecting natural variability across samples rather than obscuring scientific interpretation. Colors encode the window scale, with red indicating short windows, orange indicating medium windows, and gray indicating long windows.
Figure 6.
Correlation heatmap for the final time window, showing modality coupling patterns across current, vibration, and acoustic channels. The strongest relationship appears between AE table and AE spindle, while smcAC and smcDC exhibit moderate association.
Figure 6.
Correlation heatmap for the final time window, showing modality coupling patterns across current, vibration, and acoustic channels. The strongest relationship appears between AE table and AE spindle, while smcAC and smcDC exhibit moderate association.
Figure 7.
Residual overlay across all sensor channels for a representative run, illustrating how deviations from the reference signal evolve over time. The current channels show the largest excursions, supporting their prioritization in residual based sensor ranking.
Figure 7.
Residual overlay across all sensor channels for a representative run, illustrating how deviations from the reference signal evolve over time. The current channels show the largest excursions, supporting their prioritization in residual based sensor ranking.
Figure 8.
Learning curves over epochs, showing validation accuracy rising as validation loss decreases. The trends indicate stable convergence without abrupt divergence during training.
Figure 8.
Learning curves over epochs, showing validation accuracy rising as validation loss decreases. The trends indicate stable convergence without abrupt divergence during training.
Figure 9.
Violin plot of predicted softmax confidence by class, where class_0 = Healthy, class_1 = Worn, and class_2 = Failed. The plot shows tighter confidence distributions for the extreme states and broader uncertainty for the intermediate Worn state.
Figure 9.
Violin plot of predicted softmax confidence by class, where class_0 = Healthy, class_1 = Worn, and class_2 = Failed. The plot shows tighter confidence distributions for the extreme states and broader uncertainty for the intermediate Worn state.
Figure 10.
Multi-head attention heatmaps for a representative sample, illustrating how different attention heads emphasize different time steps and feature groups. Color intensity encodes the normalized attention weight assigned by each head, with darker colors indicating lower attention contribution and brighter colors indicating higher attention contribution. The diversity across heads reflects complementary temporal cues and multi-scale dependencies exploited by the model.
Figure 10.
Multi-head attention heatmaps for a representative sample, illustrating how different attention heads emphasize different time steps and feature groups. Color intensity encodes the normalized attention weight assigned by each head, with darker colors indicating lower attention contribution and brighter colors indicating higher attention contribution. The diversity across heads reflects complementary temporal cues and multi-scale dependencies exploited by the model.
Figure 11.
Attention transparency overlay across sensor channels for a representative sample. Each curve shows the normalized attention-weighted contribution of one sensor over time. Overlapping trajectories are intentional and illustrate concurrent sensor influence rather than obscuring information; dominant sensors and temporal emphasis are interpreted by relative magnitude and consistent trends rather than isolated peaks.
Figure 11.
Attention transparency overlay across sensor channels for a representative sample. Each curve shows the normalized attention-weighted contribution of one sensor over time. Overlapping trajectories are intentional and illustrate concurrent sensor influence rather than obscuring information; dominant sensors and temporal emphasis are interpreted by relative magnitude and consistent trends rather than isolated peaks.
Figure 12.
Runtime and memory profiling summary, decomposing end-to-end time into data loading, inference, and overhead, and reporting the corresponding peak memory trajectory during execution.
Figure 12.
Runtime and memory profiling summary, decomposing end-to-end time into data loading, inference, and overhead, and reporting the corresponding peak memory trajectory during execution.
Table 1.
Categorized comparison of predictive maintenance methods with emphasis on temporal modeling, explainability, robustness and deployment readiness.
Table 1.
Categorized comparison of predictive maintenance methods with emphasis on temporal modeling, explainability, robustness and deployment readiness.
| Category | Data/Task | Core Method | T | X | R | D | Gap |
|---|
| Statistical baselines [25] | Small-scale signals | Regression, PCA, ARIMA | ∆ | ✓ | ✗ | ✗ | Noise and shift sensitive |
| Tree based ML [26] | Windowed features | Random forest, GBDT | ∆ | ∆ | ∆ | ✗ | Feature design needed |
| RNN models [27,28] | Long sequences | LSTM, GRU | ✓ | ✗ | ∆ | ✗ | Slow on long horizons |
| Temporal convolution [30,31] | Multivariate series | Causal dilated conv | ✓ | ✗ | ∆ | ∆ | XAI often external |
| Conv plus attention [32,34,35] | Multi-scale signals | Residual conv, attention | ✓ | ∆ | ∆ | ∆ | Limited stress testing |
| XAI focus [40] | Alarm validation | Importances, saliency | ∆ | ✓ | ∆ | ✗ | Weak profiling |
| Deployment focus [33,41] | Edge constraints | Footprint, latency, memory | ∆ | ∆ | ∆ | ✓ | Often conceptual |
Proposed framework [30,35,41] | Multisensor windows | Lightweight TCN, attention, multi task | ✓ | ✓ | ✓ | ✓ | Single domain evaluation |
Table 2.
High-level structure of the proposed workflow and its intermediate artifacts.
Table 2.
High-level structure of the proposed workflow and its intermediate artifacts.
| Stage | Input | Output/Artifact |
|---|
| Signal preparation | Raw multi-sensor streams | Cleaned, synchronized windows |
| Multiscale feature construction | Windowed signals | Fixed-length feature vectors |
| Sensor prioritization | Training features | Selected sensor and feature subsets |
| Temporal modeling (TCN) | Feature sequences | Health-state probabilities and RUL estimate |
| Diagnostic analysis | Model internals and outputs | Feature attributions and temporal saliency maps |
| Evaluation and profiling | Predictions and explanations | Accuracy and deployment metrics |
Table 3.
Overview of the NASA Ames milling dataset with sensor composition and average RMS statistics across multiple window scales.
Table 3.
Overview of the NASA Ames milling dataset with sensor composition and average RMS statistics across multiple window scales.
| Property | Description/Value | Notes |
|---|
| Dataset Overview |
| Dataset | NASA Ames Milling, public benchmark | CNC milling tool condition monitoring |
| Dataset structure | Multiple runs, multi-sensor time series | Each run provides synchronized channels and a tool state label |
| Access | Public online release by NASA | Source link and file list reported in Data Availability Statement |
| Sensors used in RMS summary | Vibration, AE, smcAC, smcDC | Multi-sensor subset used for RMS statistics |
| Additional sensor channels | Force | Present in acquisition, retained for downstream analysis |
| Labels | Healthy, Worn, Failed | Three tool health states |
| Window scales | 0.5 s, 1.0 s, 2.0 s | Overlapping segmentation at three scales |
| Data traits | High-frequency, noisy, imbalanced | Requires cleaning, normalization and balancing |
| Average RMS Values per Sensor Across Window Scales |
| smcAC | 0.388 average across windows | Current channel RMS magnitude |
| smcDC | 1.346 average across windows | Dominant energy contributor |
| Vibration | 0.286 average across windows | Mechanical response indicator |
| AE | 0.126 average across windows | High-frequency acoustic bursts |
| Force | Included in raw acquisition | Force channel retained for downstream features |
Table 4.
Signal preprocessing pipeline steps, parameter choices and resulting outputs applied consistently before model training and evaluation.
Table 4.
Signal preprocessing pipeline steps, parameter choices and resulting outputs applied consistently before model training and evaluation.
| Step | Action | Params | Out |
|---|
| Quality checks | Missing values and outliers | Interp, percentile clip | ✓ |
| Denoising | Noise suppression and drift removal | Low-pass, detrend | ✓ |
| Segmentation | Multi-scale windows | 0.5 s, 1.0 s, 2.0 s | ✓ |
| Cross-correlation | Sensor coupling | Rolling corr, lags | ✓ |
| Feature extraction | Window-level statistics | RMS, var | ✓ |
| Scaling | Standardize features | z-score train stats | ✓ |
| Balancing | Rebalance training only | Resample | ✓ |
| Diagnostics | Visual sanity checks | Spectrogram, radar | ✓ |
Table 5.
Residual-based sensor prioritization for feature selection using training split residual energy.
Table 5.
Residual-based sensor prioritization for feature selection using training split residual energy.
| Sensor Channel | Mean Residual Energy | Normalized Importance | Selected |
|---|
| Vibration | | | no |
| Acoustic emission (AE) | | | no |
| Spindle motor current AC (smcAC) | | | yes |
| Spindle motor current DC (smcDC) | | | yes |
Table 6.
Hyperparameter search space explored during grid search for the TCN backbone and training configuration.
Table 6.
Hyperparameter search space explored during grid search for the TCN backbone and training configuration.
| Hyperparameter | Values |
|---|
| Number of TCN layers | {3, 4, 5} |
| Hidden units per layer | {32, 64, 128} |
| Kernel size | {2, 3, 5} |
| Dilation scheme | {Linear, Exponential} |
| Residual connections | {Enabled, Disabled} |
| Dropout rate | {0.1, 0.2, 0.3} |
| Learning rate | 1 × 10−4, 5 × 10−4, 1 × 10−3 |
| Batch size | {32, 64, 128} |
| Loss weight (classification vs. RUL) | {0.3, 0.5, 0.7} |
Table 7.
Temporal Convolutional Network architecture, optimization and training hyperparameters employed consistently across all experimental evaluations.
Table 7.
Temporal Convolutional Network architecture, optimization and training hyperparameters employed consistently across all experimental evaluations.
| Setting | Value |
|---|
| Search strategy | Grid search, accuracy-stability-efficiency trade-off |
| Model type | Temporal Convolutional Network |
| Convolutional layers | 4 |
| Hidden units per layer | 64 |
| Kernel size | 3 |
| Dilation and residuals | Enabled |
| Dropout | 0.2 |
| Optimizer | Adam |
| Learning rate | |
| Batch size | 64 |
| Tasks | Health-state classification and RUL regression |
| Loss | Cross-entropy plus mean squared error |
Table 8.
Minimum hardware and software configuration used for model training, inference profiling and experimental reproducibility.
Table 8.
Minimum hardware and software configuration used for model training, inference profiling and experimental reproducibility.
| Component | Specification |
|---|
| CPU | Intel Core i7 class |
| Memory | 16 GB RAM |
| Storage | 50 GB free disk |
| GPU | Optional for faster training |
| OS | Ubuntu 20.04 or Windows 10 |
| Python | 3.10 |
| Core libraries | NumPy (v1.26.4), pandas (v2.1.4), scikit-learn (v1.4.0), PyTorch (v2.1.0) |
| Recorded during runs | Wall-clock time, memory use, inference throughput |
Table 9.
Evaluation protocol used for training, model selection, testing, and deployment profiling.
Table 9.
Evaluation protocol used for training, model selection, testing, and deployment profiling.
| Protocol Item | Specification Used in This Work |
|---|
| Split unit | Run level split so all segments from one run stay in one split |
| Split ratios | Training 70%, validation 15%, test 15% using stratified assignment over labels |
| Segmentation timing | Windowing performed after run assignment to enforce leakage free splits |
| Preprocessing fit | Fitted on training split only then applied to validation and test |
| Scaling | Z-score standardization using training split mean and standard deviation only |
| Feature selection | Residual-based sensor prioritization computed on training split only and then fixed |
| Model selection | Grid search using validation split under an accuracy stability efficiency trade-off |
| Final training | Train on training split and select by validation performance using the fixed TCN setup in Table 7 |
| Final test report | Single evaluation on the held out test split after model selection is complete |
| Classification metrics | Accuracy, precision, recall, macro F1, confusion matrix |
| RUL metrics | Mean absolute error, root mean squared error |
| Profiling metrics | Parameter count, model size, peak memory, end-to-end runtime, inference throughput |
| Profiling environment | Hardware and software baseline as reported in Table 8 |
Table 10.
Window-scale RMS statistics with variance and normalized energy contribution for current, vibration and acoustic channels. Results highlight stable cross-scale dominance of smcDC and smcAC, with vib_spn providing consistent secondary mechanical information and supporting multi-scale feature fusion for degradation monitoring.
Table 10.
Window-scale RMS statistics with variance and normalized energy contribution for current, vibration and acoustic channels. Results highlight stable cross-scale dominance of smcDC and smcAC, with vib_spn providing consistent secondary mechanical information and supporting multi-scale feature fusion for degradation monitoring.
| Scale | Sensor | Mean RMS | Variance | Contr. % |
|---|
| 0.5 s | smcAC | 0.50 | 0.25 | 18.2 |
| 0.5 s | smcDC | 1.38 | 0.78 | 57.7 |
| 0.5 s | vib_tbl | 0.16 | 0.04 | 3.6 |
| 0.5 s | vib_spn | 0.29 | 0.09 | 12.1 |
| 0.5 s | AE_tbl | 0.09 | 0.03 | 4.4 |
| 0.5 s | AE_spn | 0.11 | 0.03 | 4.0 |
| 1.0 s | smcAC | 0.55 | 0.27 | 20.4 |
| 1.0 s | smcDC | 1.36 | 0.75 | 54.9 |
| 1.0 s | vib_tbl | 0.15 | 0.03 | 3.1 |
| 1.0 s | vib_spn | 0.29 | 0.08 | 12.3 |
| 1.0 s | AE_tbl | 0.09 | 0.03 | 4.6 |
| 1.0 s | AE_spn | 0.11 | 0.02 | 4.7 |
| 2.0 s | smcAC | 0.45 | 0.21 | 16.7 |
| 2.0 s | smcDC | 1.34 | 0.74 | 52.3 |
| 2.0 s | vib_tbl | 0.14 | 0.03 | 3.3 |
| 2.0 s | vib_spn | 0.28 | 0.07 | 12.1 |
| 2.0 s | AE_tbl | 0.09 | 0.03 | 4.5 |
| 2.0 s | AE_spn | 0.10 | 0.02 | 4.1 |
| All | Avg all sensors | 0.41 | 0.18 | 100.0 |
| All | Dominant sensor smcDC | 1.36 | 0.76 | 55.0 |
| All | Next sensor smcAC | 0.50 | 0.24 | 18.0 |
| All | Next sensor vib_spn | 0.29 | 0.08 | 12.0 |
| All | KDE peak vib_spn | 0.29, 0.30, 0.31 | 0.08 | 12.0 |
Table 11.
Correlation, lag and spectral relationships among key sensor pairs, revealing cross-domain coupling and diagnostic timing characteristics.
Table 11.
Correlation, lag and spectral relationships among key sensor pairs, revealing cross-domain coupling and diagnostic timing characteristics.
| Sensor Pair | Corr. | Lag | Band Hz | Domain | Key Observation |
|---|
| AE spindle—AE table | 0.77 | 0 | 0–500 | Acoustic | Strong coupling at spindle table interface |
| Vibration spindle—AE spindle | 0.80 | +100 | 0–500 | Mech-Acous | Mechanical energy transfer to acoustic channel |
| smcDC—Vibration spindle | 0.24 | +35 | 0–500 | Elec-Mech | Delayed electrical to mechanical response cue |
| smcAC—smcDC | 0.45 | 0 | Broadband | Electrical | Stable intra current coupling |
| Vibration spindle - Vibration table | 0.07 | 0 | Broadband | Mechanical | Low coherence provides complementary motion info |
| AE table—smcDC | 0.21 | 0 | Broadband | Cross modal | Weak acoustic electrical interaction |
| Mean correlation | 0.26 with standard deviation 0.21 |
Table 12.
Residual energy distribution across sensor channels, highlighting dominant electrical contributions and supporting mechanical and acoustic responses.
Table 12.
Residual energy distribution across sensor channels, highlighting dominant electrical contributions and supporting mechanical and acoustic responses.
| Sensor | Key Metrics | Role | Observation |
|---|
| smcAC | Mean 2.6 ± 0.6, Max 3.6 | Primary driver | High residual energy with oscillatory electrical patterns |
| smcDC | Mean 0.7 ± 1.3, Max 3.5 | Early indicator | Transient spikes linked to load variation |
| vib_spindle | Mean 0.02 ± 0.03, Max 0.09 | Mechanical response | Low-amplitude residuals aligned with current bursts |
| vib_table | Range 0.02–0.10 | Structural baseline | Stable response with limited variance |
| AE_table | Mean 0.01 ± 0.01 | Validation cue | Minimal acoustic deviation, supports confirmation |
| AE_spindle | Mean 0.01 ± 0.01 | Supporting signal | Low residuals correlated with AE table |
| Aggregate | - | Current dominated | Mean residual about 0.66 driven mainly by smcAC and smcDC |
Table 13.
Class-wise classification, calibration and remaining useful life prediction performance on the test dataset.
Table 13.
Class-wise classification, calibration and remaining useful life prediction performance on the test dataset.
| Class | Prec. | Rec. | F1 | AUC | AUPRC | RUL MAE (s) | ECE | Supp. |
|---|
| Healthy | 0.89 | 0.91 | 0.90 | 0.95 | 0.95 | 2.1 | 0.03 | 1200 |
| Worn | 0.75 | 0.78 | 0.76 | 0.89 | 0.72 | 3.8 | 0.08 | 600 |
| Failed | 0.86 | 0.88 | 0.87 | 0.90 | 0.98 | 1.5 | 0.02 | 400 |
Table 14.
Combined explainability analyses linking signal dynamics, sensor behavior and learned model responses across machine health states.
Table 14.
Combined explainability analyses linking signal dynamics, sensor behavior and learned model responses across machine health states.
| Analysis | Key Focus | Primary Sensor | Derived Insight |
|---|
| Z-score heatmap | Normalized activation | smcAC, smcDC | Strong and coherent activations indicate dominant electrical health cues |
| Patch variability | Early variance | smcAC | High initial variance reflects process transients and degradation onset |
| RMS evolution | Amplitude growth | smcAC, smcDC | Progressive RMS increase tracks fatigue and load imbalance |
| Entropy trend | Signal complexity | AE_spindle | Entropy reduction signals loss of acoustic diversity with wear |
| Variance share | Energy dominance | smcAC, smcDC | Electrical load governs overall framework variability |
| SHAP failed | Feature impact | vib_table | Rising vibration energy reflects resonance near failure |
| SHAP worn | Feature impact | AE_spindle | Reduced acoustic activity aligns with partial tool dulling |
| SHAP healthy | Feature suppression | vib_table | Low vibration stabilizes framework and suppresses fault signatures |
Table 15.
Patch-wise attention weights across sensors, highlighting dominant signals and their relative importance in fault detection.
Table 15.
Patch-wise attention weights across sensors, highlighting dominant signals and their relative importance in fault detection.
| Sensor | P0 | P5 | P10 | P15 | Rank | Key Observation |
|---|
| smcAC | 0.012 | 0.014 | 0.010 | 0.011 | 2nd | Early electrical cues with mid-segment confirmation |
| smcDC | 0.018 | 0.020 | 0.015 | 0.017 | 1st | Dominant attention aligned with current spikes and fault onset |
| vib_spindle | 0.009 | 0.010 | 0.007 | 0.008 | 3rd | Mechanical response following electrical transients |
| AE_table | 0.005 | 0.006 | 0.004 | 0.006 | 4th | Low attention; corroborative acoustic evidence |
Table 16.
Performance, interpretability and edge suitability comparison of deep learning models for predictive maintenance across benchmark datasets.
Table 16.
Performance, interpretability and edge suitability comparison of deep learning models for predictive maintenance across benchmark datasets.
| Model | Dataset | Acc. | AUC | Lat. | Interp. | Edge | Remarks |
|---|
| CNN-LSTM [45] | NASA Milling/C-MAPSS | 82 | 0.88 | 210 | No | No | High temporal cost |
| Bi-LSTM [46] | NASA Milling | 84 | 0.90 | 170 | No | No | Good RUL; low interpret. |
| Transformer [47] | C-MAPSS | 90 | 0.95 | 300+ | Part. | No | High acc.; heavy compute |
| 1D-CNN [48] | Milling | 80 | 0.87 | 120 | No | Yes | Light; lower precision |
| Proposed TCN (This work) | NASA Ames (Real) | 87–89 | 0.89–0.96 | 89 | High | High | High acc.; edge-ready |
Table 17.
End-to-end runtime, memory and CPU utilization profiling of the proposed predictive maintenance framework during inference.
Table 17.
End-to-end runtime, memory and CPU utilization profiling of the proposed predictive maintenance framework during inference.
| Module | Time (s) | Mem. MB | CPU % | Role | Observation |
|---|
| Load CSV | 1.2 | 3390 | 62.5 | Input I O | Fast read with moderate CPU load |
| Preprocess | 2.3 | 3394 | 75.3 | Feature prep | CPU intensive due to filtering and scaling |
| Patchify | 1.1 | 3395 | 53.1 | Windowing | Stable memory and low overhead |
| TCN inference | 4.7 | 3396 | 52.9 | Core compute | Main latency contributor during prediction |
| Save output | 1.8 | 3397 | 77.2 | Output I O | Disk writes dominate CPU usage |
| Total or avg. | 11.1 | 3394 | 64.2 | End to end | Stable runtime and memory profile |