NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

A Diffusion Model for Regular Time Series Generation from Irregular Data with Completion and Masking

Gal Fadlon, Idan Arbiv, Nimrod Berman, Omri Azencot

Abstract

Generating high-quality, regularly sampled time series from irregular data is a significant challenge in modern data science. Existing methods, such as those based on Neural Controlled Differential Equations (NCDEs), are computationally intensive and struggle to scale to long sequences. We propose a novel two-step diffusion framework that addresses these limitations by combining a Transformer-based completion step with a vision-based diffusion model. By utilizing a masked loss function, our approach ensures that the model learns from natural data neighborhoods while remaining grounded in observed values. Experimental results across 12 diverse datasets demonstrate a 70% improvement in data fidelity and an 85% reduction in computational costs compared to current state-of-the-art models.

Introduction

In real-world scenarios, time series data is rarely "regular." Measurements are often interrupted by sensor failures, network latency, or inconsistent human recording, resulting in irregular intervals and missing values. While generating synthetic data from these sources is vital for privacy-preserving research and robust testing, existing solutions like GT-GAN or KoVAE face significant scalability issues. Vision-based models, which treat time series as images, offer a faster alternative but often fail when dealing with irregular data; filling gaps with zeros creates "unnatural neighborhoods"—artificial patterns that disrupt the convolutional kernels' ability to learn the underlying signal logic.

Methodology

The proposed framework leverages a hybrid approach to overcome the "unnatural neighborhood" problem through two key steps:

  1. Natural Neighborhood Construction (Completion): The process begins with a Time Series Transformer (TST) autoencoder. Instead of simple zero-filling, the TST completes the irregular sequences, creating a continuous and "natural" context for every data point. This ensures that when the data is mapped into an image space via Delay Embedding, the resulting pixels represent a coherent signal rather than a fragmented one.
  2. Robust Generation (Masking): The completed series is processed by a vision-based diffusion model (U-Net). A critical innovation here is the use of a masked loss function. During training, the model is only penalized for errors on the originally observed data points. This "Completion + Masking" strategy allows the model to use the Transformer's imputations for context without being forced to overfit to potentially inaccurate guesses.
The proposed two-step diffusion framework: (Top) Autoencoder training for signal completion; (Middle) Diffusion model training with masked loss on images; (Bottom) Inference process.

Key Insights: The Unnatural Neighborhood Problem

The authors demonstrate that for CNN-based diffusion models, the preprocessing of gaps is as important as the model architecture itself. As illustrated in Figure 2, different strategies for representing irregular data lead to varying levels of fidelity. Poorly handled gaps create sharp, artificial edges in the image representation, which degrade the model's performance. By treating the Transformer's output as a "weak conditioning signal," the framework maintains a balance between learning the global structure and respecting the local, observed measurements.

Comparison of different data representation strategies. The 'unnatural neighborhood' problem occurs when gaps are filled poorly, leading to lower fidelity scores (D-F).

Experimental Results

The model was rigorously tested across 12 datasets covering finance, physics, and infrastructure. Notable benchmarks included the MuJoCo physics simulator, USHCN weather data, and the KDD-Cup dataset, which features ultra-long sequences of up to 10,920 time steps.

  • Superior Fidelity: The framework achieved a 70% relative improvement in discriminative scores compared to KoVAE, indicating that the generated data is significantly harder for discriminators to distinguish from real data.
  • Computational Efficiency: Training times were reduced by 85% on average. For instance, on the Energy dataset, training was completed in under 7 hours, compared to over 84 hours for competing methods.
  • Scalability and Robustness: Unlike previous models whose inference times grew exponentially with sequence length, this model's performance remained stable even as sequences stretched to thousands of steps. It also demonstrated high robustness against Gaussian noise and large, continuous blocks of missing data.

Conclusion

This research introduces a scalable, efficient, and high-fidelity method for generating regular time series from irregular inputs. By bridging the gap between Transformers and vision-based Diffusion models, the framework sets a new standard for synthetic time series generation. Future work will focus on extending this approach to multimodal data and refining the adaptive masking techniques to further enhance generation quality.

Summary updated

BibTeX
@inproceedings{fadlon2025diffusion,
  author = {Gal Fadlon and Idan Arbiv and Nimrod Berman and Omri Azencot},
  title = {{A Diffusion Model for Regular Time Series Generation from Irregular Data with Completion and Masking}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2025},
  url = {https://openreview.net/forum?id=M9JmlA6Cgf},
}
Figure