Real-world multivariate time series, particularly in critical infrastructure such as electrical power grids, are often corrupted by noise and anomalies that degrade the performance of downstream tasks. Standard data cleaning approaches often rely on disjoint strategies, which involve detecting errors with one model and imputing them with another. Such approaches can fail to capture the full joint distribution of the data and ignore prediction uncertainty. This work introduces Conditional Imputation and Noisy Data Integrity (CINDI), an unsupervised probabilistic framework designed to restore data integrity in complex time series. Unlike fragmented approaches, CINDI unifies anomaly detection and imputation into a single end-to-end system built on conditional normalizing flows. By modeling the exact conditional likelihood of the data, the framework identifies low-probability segments and iteratively samples statistically consistent replacements. This allows CINDI to efficiently reuse learned information while preserving the underlying physical and statistical properties of the system. We evaluate the framework using real-world grid loss data from a Norwegian power distribution operator, though the methodology is designed to generalize to any multivariate time series domain. The results demonstrate that CINDI yields robust performance compared to competitive baselines, offering a scalable solution for maintaining reliability in noisy environments.
Figures & tables
Figure 1: Overview of our CINDI framework based on normalizing flows. The framework alternates between the two states (green and blue), indicated by the orange path, of training and data improvement until convergence. At this point, no further changes are made, and an improved dataset is available, as indicated by the black dotted path. In the green state, CINDI uses the current dataset and outputs a normalizing flow model. The following blue state uses this model to identify data points that deviate from the expected behavior and then corrects them by generating plausible replacements. This process leads to convergence away from detecting unexpected behavior, resulting in improved data for another task.
Name
Start Date
End Date
Error %
Length
D1 Train (0%)
2017-05-01
2019-03-17
0.00%
16461
D2 Train (1.04%)
2020-05-03
1.04%
26370
D3 Train (13.69%)
2020-10-15
13.69%
30330
D4 Train (24.19%)
2021-10-21
24.19%
39233
Evaluation
2022-01-06
2022-07-01
56.72%
4224
Test
2022-11-01
2023-08-25
52.25%
7149
Table 1: Overview of the dataset splits, detailing their time ranges and the percentage of data points flagged as errors.
Figure 2: Comparing expected (left) and unexpected (right) behavior in power grid measurements, showing both grid loss and power consumption. The top row displays the full time series, while the bottom row zooms in on specific sections for a closer look. The expected behavior on the left is mostly normal with a few unusual spikes. In contrast, the behavior on the right starts normally but then shifts to consistently unusual readings, a change that coincides with the start of daylight saving time.
D2 Train 1.04 %
D3 Train 13.69 %
D4 Train 24.19 %
F1
VUS
AUC
F1
VUS
AUC
F1
VUS
AUC
Method
Encoder
final
final
final
final
final
final
final
final
final
(max)
(max)
(max)
(max)
(max)
(max)
(max)
(max)
(max)
CINDI
Base
0.93
0.97
0.97
0.92
0.97
0.96
0.81
0.82
0.81
(0.94)
(0.97)
( 0.98 )
(0.92)
(0.97)
(0.96)
(0.86)
(0.89)
(0.88)
CINDI
CNN
0.83
0.83
0.82
0.82
0.85
0.85
0.65
0.76
0.74
Table 2: Overview of test results on the grid loss data with anomaly detection as a downstream task. With the CINDI methods, we present the final performance of the last iteration and, in brackets, the maximum performance reached during all iteration steps. Values in bold highlight the highest performing score on the given dataset with a specific metric. Not completed experiments are shown as ’-’. Dynamix as proposed by [ 12 ] and KnowIpm by [ 5 ] .
Figure 3: VUS performance results for CINDI and baselines with 1.04% errors in the training data. Points are the final model performance after model selection, and box plots show all the tested candidate solutions.
Figure 4: Results from the second iteration on the dataset with 1.04% noise. Fig. (a), (b) show self-regressing imputation of two flagged sections, where the heatmap indicates the negative log-likelihood of possible other samples.
Figure 5: Results from the second iteration on the dataset with 1.04% noise. Fig. (a), (b) show self-regressing imputation of two flagged sections, with a heatmap indicating the negative log-likelihood of possible options. Fig. (c) shows the reconstruction of expected data with its negative log-likelihood. Fig. (d) and (e) display test data, detected anomalies, and latent space.
Figure 6: Imputation of one section across the first four iterations with CINDI on the dataset with 1.04% noise.
Figure 7: Imputation of an extended marked section in the third iteration with CINDI.
Appendix figures & tables7 assets
Supplementary material from the paper’s appendix.
Appendix
Figure 8: F1 performance results on training dataset with 1.04% noise.
Figure 9: VUS performance results on training dataset with 13.69% noise.
Figure 10: F1 performance results on training dataset with 13.69% noise.
Figure 11: VUS performance results on training dataset with 24.19% noise.
Figure 12: F1 performance results on training dataset with 24.19% noise.
Figure 13: Imputation of two errors in the training data using CINDI with model type CNN over three iterations, shown in Fig. (a)–(e). The anomaly detection performance on the test set across iterations yields F1 scores of 0.33,0.69,0.33,0.44 , and VUS scores of 0.90,0.96,0.97,0.98 . Fig. (f) shows the input and latent spaces where the error regions have moved into the main data range. The latent space (right) shows that the error sections in the test set are shifted into lower density areas.
Figure 14: Original and imputed training data with negative log-likelihoods, showing CINDI’s long term prediction capabilities and denoising effect.
Multivariate time series imputation (MTSI) aims to recover missing values in temporal data composed of multiple interdependent variables. This problem is central to real-world applications such as healthcare monitoring, traffic networks, and energy systems. Recent diffusion-based approaches have shown strong potential for probabilistic imputation by learning to generate missing values through iterative denoising. However, most existing approaches perform diffusion directly in the original data space, requiring the denoising network to simultaneously capture global structure, temporal dynamics, and stochastic variability. This makes the generative task unnecessarily complex, especially when modern deterministic imputers can already provide accurate initial reconstructions. To address this limitation, we propose RDDMPI, a conditional residual diffusion framework that operates directly in residual space. Instead of modeling the full missing signal directly, we reformulate probabilistic imputation as a baseline-residual decomposition, where a pretrained model captures the dominant signal and a diffusion process models the residual uncertainty. To better exploit deterministic guidance, \model{} conditions the reverse denoising process on both the baseline-completed signal and its latent representation, while a reliability-aware conditioning mechanism adaptively controls the influence of baseline information during residual generation. This formulation simplifies the diffusion learning objective, enabling it to focus on structured correction terms rather than reconstructing the full signal. Experiments on multiple benchmark datasets demonstrate that RDDMPI consistently improves both reconstruction accuracy and uncertainty quantification.
Ramiro Valdes Jara, David Chapman, Adam Meyers
Department of Industrial and Systems Engineering, University of Miami, United States of America · Department of Computer Science, University of Miami, United States of America
Real-world time-series data in industrial sensing, healthcare, and energy systems is often corrupted by a mixture of Gaussian noise and occasional large-magnitude impulse outliers. For tasks that depend on local shape, such as ECG morphology analysis and battery degradation monitoring, the main requirement is not only low reconstruction error but also preservation of derivative peaks and task-critical features. We propose Cascade-KDE, a training-free restoration framework for corrupted time series. The method first estimates a two-dimensional temporal-amplitude density, then applies a Density-Truncated Robust Expectation to limit the influence of distant abnormal points, and finally refines the sequence through an exponential cascade with adaptive stopping. This design aims to improve robustness under out-of-distribution impulse corruptions while keeping the restored trajectory close to the original local structure. Across several benchmark datasets, the proposed method shows consistent gains over classical filters and representative learning-based baselines on curve fidelity, derivative preservation, downstream classification, and runtime efficiency. These results suggest that bounded density-based restoration is a practical option for feature-preserving preprocessing in noisy time-series pipelines.
Yuefeng Liu, Ning Yang, Ziyu Yang
School of Digital and Intelligent Industry (School of Cyber Science and Technology), Inner Mongolia University of Science and Technology, Baotou, China
This paper introduces temporal-conditioned normalizing flows (tcNF), a novel framework that addresses anomaly detection in time series data with accurate modeling of temporal dependencies and uncertainty. By conditioning normalizing flows on previous observations, tcNF effectively captures complex temporal dynamics and generates accurate probability distributions of expected behavior. This autoregressive approach enables robust anomaly detection by identifying low-probability events within the learned distribution. We evaluate tcNF on diverse datasets, demonstrating good accuracy and robustness compared to existing methods. A comprehensive analysis of strengths and limitations and open-source code is provided to facilitate reproducibility and future research.
David Baumgartner, Helge Langseth, Kenth Engø-Monsen +1
Department of Computer Science, Norwegian University of Science and Technology.