Interpretable Smart Meter Anomaly Detection Based on Bayesian-Optimized XGBoost and SHAP
Open Access
- 21 August 2026
- journal article
- research article
- Published by MDPI AG in Information
- Vol. 17 (8) , 810
Abstract
Smart meter anomaly detection is critical for ensuring the security and stability of smart grids. However, existing detection methods face the following limitations: insufficient feature extraction, severe class imbalance, inefficient manual hyperparameter tuning, and poor model interpretability. To overcome these limitations, we propose an accurate and interpretable anomaly detection method based on Bayesian-optimized XGBoost and SHAP. Our method integrates multi-dimensional feature extraction to enrich feature information, Borderline-SMOTE to mitigate class imbalance, Bayesian optimization to tune XGBoost hyperparameters, and SHAP to quantify feature contributions and provide model interpretability. Experimental results on the public MAD dataset demonstrate that our method consistently outperforms both classical machine learning models, including decision tree, Random Forest, XGBoost, and LightGBM, as well as representative deep learning models such as CNN, TCN, LSTM, and CNN-LSTM in binary and multi-class classification tasks, achieving superior accuracy, precision, recall, and F1 scores. SHAP analysis further reveals that three-phase unbalance features are the dominant indicators of abnormal samples, a finding highly consistent with the physical mechanisms of power systems. Our method achieves both competitive detection performance and transparent decision-making, providing an actionable solution for smart meter anomaly detection in practical engineering applications.Keywords
Funding Information
- Research Project “Research and Application of a Lightweight En-cryption Architecture for Power Data Based on Multi-Level Privacy Protection” (522709260006)
This publication has 45 references indexed in Scilit:
- EGIVE (Efficient Global Interaction and Variable Explainability): A fast and comprehensive method for global interpretability analysis of black-box modelsDecision Support Systems, 2026
- Estimating residential flexibility from smart meter data: A bilevel framework for demand response aggregationEnergy Conversion and Management, 2026
- Smart meter data intelligence for sustainable distribution network operations: State-of-the-Art applications and pathways toward net-zeroRenewable and Sustainable Energy Reviews, 2026
- Microgrid design and multi-year dispatch optimization under climate-informed load and renewable resource uncertaintyApplied Energy, 2024
- Ensemble LOF-based detection of false data injection in smart grid demand response systemComputers and Electrical Engineering, 2024
- Anomaly detection using K-Means and long-short term memory for predictive maintenance of large-scale solar (LSS) photovoltaic plantEnergy Reports, 2023
- Faulty feeder detection of single phase-to-ground fault for distribution networks based on improved K-means power angle clustering analysisInternational Journal of Electrical Power & Energy Systems, 2022
- A novel OC-SVM based ensemble learning framework for attack detection in AGC loop of power systemsElectric Power Systems Research, 2022
- Convolutional neural network applied to detect electricity theft: A comparative study on unbalanced data handling techniquesInternational Journal of Electrical Power & Energy Systems, 2021
- Online power quality disturbance detection by support vector machine in smart meterJournal of Modern Power Systems and Clean Energy, 2018