Latent flow models have proven to be a reliable and cost-effective method for time series generation. However, the latent compression induces unwanted artefacts, such as a spectral mismatch with respect to the underlying dataset, thus hindering their use as training surrogates. In this article, we propose a spectrally-aligned latent-flow time series generator, where the latent space for flow matching is trained to preserve dynamical properties that are relevant for the suitability of synthetic samples. We find that incorporating fine-tuning losses based on canonical signal representations such as the Fourier, wavelet and signature transforms helps overcome these issues. The interpretability of these transformations allows us to ensure that the synthetic signals are aligned with the true ones in terms of relevant features, such as smoothness or targeted spectral content, as opposed to relying on pointwise reconstruction losses only. We compare the proposed aligned models against a base latent-flow model and the state of the art over real-world long-range univariate and multivariate benchmark datasets. Our quantitative results validate the superiority of the proposed method in terms of its performance on metrics reflecting signal realness and computational efficiency, while being aligned to the training set with respect to its local structure.
Figures & tables
Figure 1: Fourier power spectrum of the Exchange rate dataset ( Lai et al., 2018 ) (mean ± 1 st. dev. , logscale): true samples (left), example of a non-aligned base flow model (centre), and our proposed aligned flow model (right). Observe how the non-aligned model exhibits a spectral artefact in the form of a peak at around frequency 0.25 , which is largely minimised by the proposed alignment strategy.
Figure 2: Latent flow matching for time-series generation. We a) train an encoder-decoder pair (E,D) for reconstruction, then b) fine-tune it with a transform-consistency loss. We then c) train a flow-matching model in the latent space to transport a Gaussian prior to the distribution of encoded latents, and d) sample by drawing from the prior, applying the flow, and decoding to obtain new time-series samples.
dataset
Model
Discriminative score
Predictive score
KS t=300
KS t=500
KS t=700
KS t=900
Base + Fourier cons. (ours)
0.018±.012
0.043±.001
0.15 (3%)
0.15 (4%)
0.14 (2%)
0.15 (3%)
Base + wavelet cons. (ours)
0.022±.015
0.043±.000
0.15 (3%)
0.17 (12%)
0.15 (4%)
0.15 (2%)
Base + signature cons. (ours)
0.208±.100
0.042±.000
0.17 (12%)
0.15 (3%)
0.16 (5%)
0.15 (4%)
HEPC
Base model (ours)
0.211±.103
0.043±.000
0.16 (7%)
0.15 (5%)
0.14 (2%)
0.16 (7%)
SigDiffusion
0.070±.032
0.050±.012
0.20 (16%)
0.18 (9%)
0.19 (12%)
0.21 (22%)
DDO ( γ = 1)
0.081±.019
0.044±.001
0.25 (46%)
0.23 (38%)
0.25 (46%)
0.25 (51%)
Table 1: Discriminative, predictive and KS test metrics (KS score and rejection percentage in brackets). Less is better for all metrics. The results are computed for 1000 synthetically generated time series of length 1000, compared to 1000 unseen series from the original datasets. The KS tests are computed over the temporal indices t=300,500,700,900 .
Figure 3: Signals from the weather dataset ( Kolle, 2024 ) and their reconstructions from the base and Fourier-aligned autoencoders.
Figure 4: First dimension of FM-generated samples vs testing data for the weather dataset ( Kolle, 2024 ) . The subcaption shows the underlying models used. The five samples from both models were drawn by solving the FM ODE from the same Gaussian source sample.
Figure 5: Comparison of density and t-SNE plots on the HEPC dataset.
Figure 6: Comparison of density and t-SNE plots on the Exchange dataset.
Figure 7: Comparison of density and t-SNE plots on the Weather dataset.
transform
weights
disc. score ↓
pred. score ↓
wavelet
Sobolev
0.28±.10
0.16±.00
truncated
0.47±.03
0.16±.00
Fourier
Sobolev
0.35±.15
0.16±.00
truncated
0.5±.00
0.47±.01
None
uniform
0.37±.11
0.16±.00
Table 2: Performance of the truncated version of the Fourier and wavelet consistency losses, using the Weather dataset. The abbreviations are disc. for the discriminative score, and pred. for the predictive score, respectively.
Figure 8: Sum of the reconstruction error for each frequency bin. The subcaption indicates the underlying dataset. The sections where the alignment helps decrease the reconstruction error are highlighted in red.
Figure 9: Sum of the reconstruction error averaged over each Wavelet level. The subcaption indicates the underlying dataset.
Figure 10: Sum of the reconstruction error averaged over the Signature level. The subcaption indicates the underlying dataset.
Appendix figures & tables4 assets
Supplementary material from the paper’s appendix.
Appendix
Dataset
Dim.
N. train
Variant
Levels (dim.)
Train time
Fine-tuning
flow training
Total time
HEPC
1
8242
Base
4m 5s
5m 34s
9m 39s
Fourier
- (1000)
14s
9m 53s
Wavelet
5 (1040)
34s
10m 13s
Signature
5 (62)
6m 35s
16m 14s
Exchange rates
8
5088
Base
3m 2s
3m 24s
6m 26s
Fourier
- (1000 × 8)
9s
6m 35s
Appendix
Table 3: Experimental details for the empirical evaluation of the transform-consistency losses. We present each dataset and its dimensionality. This, in turns, modifies the dimensionality of their transformed inputs, which are detailed along with the depths/decomposition levels used. The training times for each stage are also provided.
Dataset
Dim.
Latent dim.
Inner dim. flow
Total params.
FM epochs
HEPC
1
64
258
2.021 M
500
Exchange rates
8
128
512
8.037 M
500
Weather
14
128
512
8.037 M
250
Appendix
Table 4: Specifications of epochs and latent and hidden dimensionality for each dataset. The abbreviation “dim.” stands for dimensionality and “params.” for parameters. The number of epochs used to train the laten flow models is shown as “FM epochs”.
Figure 11: Effect of varying the Sobolev exponent s .
depth
3
4
5
6
7
time
2m 33s
4m 15s
6m 35s
9m 29s
12m 50s
dim
14
30
62
126
254
disc.
.21±.13
.17±.12
.18±.14
.17±.12
.12±.11
Appendix
Table 5: Change in fine-tuning times (25 epochs), dimensionality, and discriminative score for varying signature transform depth as observed for the HEPC dataset. The abbreviation disc. stands for the discriminative score, and the 0 before the decimal is omitted from the discriminative score results.