Manuscript Offprint
arXiv:2611.01846Z-Cache: Accelerating Diffusion Transformers via Self-Reflection
Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.
Abstract
Diffusion transformers have become the most powerful models for visual generation, but still suffer from massive computation costs. To solve this problem, feature caching has been proposed to cache the features of diffusion models in the previous computation steps and then reuse them in the following caching steps, which brings significant acceleration but also degradation in generation quality. To address this problem, this paper proposes Z-cache as a feature caching method that can maintain high-quality generation through self-reflection. Concretely, we observe that the error from feature caching tends to be sharply reduced after each full computation. Based on this observation, Z-Cache is designed to first predict the features in the future caching steps and then perform a full computation. After that, Z-Cache returns to the caching steps and re-predicts them based on the previous and the current computation steps, which brings correction in features. Experiments demonstrate that with Z-Cache, diffusion transformers achieve comparable generation quality to the original model but with faster inference speed, for instance, acceleration on FLUX-dev for text-to-image generation. Our code is released on GitHub.
Preprint.

Figure 2: Visualization of the per-layer L1 error from feature caching. It is observed that there exists a periodic decline in L1 error, which is caused by the full-computation step in feature caching. The proposed Z-Cache utilizes this phenomenon and derives fewer cumulative errors.
1 Introduction
Diffusion models [Ho et al., 2020, Song et al., 2021, Liu et al., 2023] have become a dominant paradigm for high-quality visual generation, but their iterative denoising process remains computationally expensive, especially for high-resolution image and video synthesis. This cost limits practical deployment and motivates a broad set of acceleration methods. Among them, feature caching [Selvaraju et al., 2024, Qiu et al., 2025, Zou et al., 2024b, Liu et al., 2024, 2025c, Feng et al., 2025, Zheng et al., 2025b, Liu et al., 2025d] is particularly attractive because it is training-free: instead of running the full denoising network at every timestep, it reuses or predicts intermediate hidden states across nearby timesteps.
The key assumption behind feature caching is temporal redundancy. Hidden states at adjacent denoising steps are often similar, allowing expensive transformer blocks to be skipped with minor quality loss. However, this assumption becomes fragile under aggressive acceleration. As the cache interval grows, single-anchor reuse or forecasting accumulates hidden-state errors, which can lead to semantic drift, local artifacts, and degraded prompt fidelity. This creates a central trade-off: larger cache windows improve efficiency but increasingly deviate from the true denoising trajectory.
We start from a simple empirical observation. As shown in Figure 2, cache-induced feature error tends to grow within each cache window, but drops sharply when a scheduled full-computation step is performed. This suggests that full-computation anchors partially pull the accelerated trajectory back toward the original denoising path. Rather than only using a full step as the starting point for the next cache window, we ask whether the newly obtained future anchor can also be used to correct the provisional states inside the previous active window.
Based on this observation, we propose Z-Cache, a training-free and predictor-agnostic reflection framework for diffusion feature caching. For each active cache window, Z-Cache first uses a base cache predictor to forecast intermediate hidden states from a past full-computation anchor and runs the corresponding provisional denoising transitions. After reaching the next scheduled full-computation anchor, Z-Cache revisits the same window, estimates each intermediate hidden state with both the past and future anchors, and re-samples the window trajectory before committing the reflected window-end latent. Therefore, Z-Cache is not a post-hoc smoothing operation over already generated samples. Instead, it is an in-loop trajectory correction mechanism that changes the subsequent denoising path. Extensive experiments demonstrate the effectiveness of Z-Cache in text-to-image, text-to-video, and image editing tasks, as well as its compatibility with other feature caching methods and other diffusion acceleration methods such as step distillation and quantization.
Our contributions are summarized as follows:
-
We identify a cache-induced error pattern in diffusion feature caching: hidden-state errors tend to accumulate within a cache window but are sharply reduced after scheduled full-computation anchors, which motivates using future anchors to correct the previous active cache window.
-
We propose Z-Cache, a training-free cache-then-check framework that performs dual-anchor reflection and active-window re-sampling. Unlike post-hoc smoothing, Z-Cache revises the latent trajectory inside the denoising loop and continues sampling from the reflected window-end state.

Figure 3: Pipeline of Z-Cache. The figure uses the reverse-diffusion notation for visualization, while the text uses a sampling-order index that increases along denoising. Traditional feature caching forecasts an active window from a past full-computation anchor and directly moves to the next window. In contrast, Z-Cache treats the window as provisional: after obtaining the next scheduled full-computation anchor, it revisits the same window, constructs dual-anchor hidden estimates, re-samples the window trajectory, and commits the reflected window-end latent. Z-Cache therefore performs in-loop trajectory correction without adding extra full-computation steps.
- We establish Z-Cache as a plug-and-play and composable acceleration module. It can be attached to compatible feature-cache predictors, generalizes beyond free-form generation to image editing and video synthesis, and remains compatible with orthogonal acceleration techniques such as few-step distillation and low-bit quantization.
Positioning of Z-Cache Z-Cache performs cache-then-check correction: after observing the next scheduled full-computation anchor on the provisional trajectory, it combines past- and future-anchor predictions, replays the closed provisional window, and continues from the reflected endpoint. This complements compatible cache policies and predictors while preserving the full-computation schedule; composition requires compatible cached representations and state updates. Appendix A.1 provides a detailed taxonomy and comparisons.
3 Methodology
3.1 Preliminary
3.1.1 Diffusion sampling.
Diffusion models [Ho et al., 2020, Song et al., 2021] generate a clean sample by iteratively denoising a noisy latent. In a standard DDPM-style parameterization, one reverse step is written as
where is the denoising network and are scheduler coefficients. Modern samplers may use different update rules, but they share the same iterative structure. To avoid confusion between the diffusion timestep and the order in which the sampler is executed, we use to denote the sampling-order index in the rest of this section, with larger corresponding to later denoising. Let be the diffusion timestep used at sampling index . We write one denoising update abstractly as
(2) where denotes the hidden features produced by the denoising network at and .
3.1.2 Diffusion transformer hidden states.
A Diffusion Transformer (DiT) [Peebles and Xie, 2023] is composed of transformer blocks, , where each block contains attention and MLP submodules with timestep- and condition-dependent normalization. At sampling index , the full denoising network produces a collection of block features
Feature caching accelerates inference by avoiding full recomputation of at selected sampling indices and replacing it with a cached or predicted estimate.
3.2 Feature Caching
Let be the set of sampling indices whose full hidden states have been cached before evaluating index . A generic cache predictor estimates the hidden features at a cached step by
This abstraction covers simple feature reuse, timestep-adaptive caching, polynomial forecasting, speculative prediction, and calibration-style predictors. For example, a naive fixed-interval cache method computes full features at an anchor and reuses them for the following cached steps,
where is one cache window and is the cache interval. Larger intervals reduce the number of full denoising-network evaluations, but the approximation error can accumulate inside the window and lead to semantic drift or local artifacts.
3.3 Z-Cache
Z-Cache is a training-free reflection wrapper for feature caching. It does not prescribe a specific cache predictor; instead, it can be applied on top of a base predictor such as TaylorSeer, SpeCa, or MagCache. The key idea is to treat the states inside the current cache window as provisional until the next scheduled full-computation anchor is available. After obtaining that future anchor, Z-Cache revisits the active window, constructs dual-anchor hidden estimates, re-samples the window trajectory, and then continues denoising from the reflected state.
Active cache window. Consider one active cache window in sampling-order indices. Full hidden states are computed at the endpoint anchors and , while the intermediate indices are cached. Let denote the anchor set available before entering this window, which includes the past anchor . The window proceeds in three stages.
Stage 1: forecast from the past anchor. Before the future endpoint is known, the base cache predictor estimates each intermediate hidden state from the currently available anchors:
where the superscript denotes the past-anchor prediction. These estimates define a provisional trajectory,
where and for . After the provisional trajectory reaches the endpoint, the sampler performs the next scheduled full computation and obtains the future anchor . This full computation is part of the original cache schedule, so Z-Cache does not add extra scheduled full-computation steps.
Stage 2: dual-anchor reflection. Once is available, Z-Cache constructs a future-anchor prediction for each intermediate index by reusing the same base predictor with the extended anchor set:
where the superscript f denotes the future-anchor prediction. The reflected hidden state is the convex dual-anchor estimate
The weight is defined by the normalized progress inside the active window,
This schedule is hyperparameter-free once the cache interval is fixed. It trusts the past-anchor prediction near the beginning of the window and gradually shifts trust toward the future-anchor prediction near the endpoint.
Stage 3: active-window re-sampling. The reflection step is performed inside the denoising loop, not after a sample has already been finalized. The provisional latent states are discarded, and the active window is re-sampled with the reflected hidden states:
where and is given by Eq. (9) for . The transition at is reused. After re-sampling, Z-Cache commits using the retained right-anchor features and updates the cache accordingly (Appendix A.4). States before have already been committed and are not modified, while states after have not yet been generated. Thus, Z-Cache changes the subsequent denoising trajectory without creating inconsistency with finalized states outside the current window. This distinguishes Z-Cache from post-hoc hidden-state smoothing: the reflected hidden estimates affect later outputs because they are used to re-run the latent transitions inside the active window.
Local error propagation. We next give a local analysis explaining why active-window reflection can reduce trajectory error. Let the full, non-accelerated trajectory satisfy
and let an accelerated method use a hidden estimate and latent . Define the latent error and hidden approximation error as
Assume each local update is Lipschitz in both the latent state and the hidden state:
Then
Unrolling this recursion over one active window gives
where an empty product equals 1. Therefore, the error depends on the hidden-state errors accumulated at all earlier indices in the same window. This explains why correcting intermediate cached steps changes later latents: the sampler recursively propagates hidden-state errors through Eq. (2).
For the no-reflection base predictor, the hidden error at an intermediate index is
Table 1: Quantitative comparison on class-to-image generation on ImageNet with DiT-XL/2. F-Speed denotes the FLOPs reduction relative to DDIM with 50 steps. Metrics marked with “-” are left unreported, as they were not provided in the original publications.
| Method | Efficient Attention | Latency(s) ↓ | FLOPs(T) ↓ | F-Speed ↑ | FID ↓ | sFID ↓ | Inception Score ↑ | PSNR ↑ | SSIM ↑ | LPIPS ↓ |
|---|---|---|---|---|---|---|---|---|---|---|
| DDIM-50 steps | ✓ | 0.428 | 23.74 | 1.00× | 2.32 | 4.32 | 241.25 | ∞ | 1.00 | 0.000 |
| DDIM-12 steps | ✓ | 0.128 | 5.70 | 4.17× | 7.80 | 8.03 | 184.50 | 22.70 | 0.742 | 0.196 |
| L2C(NFE=30) | ✓ | 0.281 | 11.55 | 2.05× | 2.61 | - | 237.83 | - | - | - |
| SmoothCache(α = 0.22) | ✓ | 0.251 | 8.57 | 2.77× | 4.15 | - | 231.71 | - | - | - |
| DDIM-10 steps | ✓ | 0.115 | 4.75 | 5.00× | 12.15 | 11.33 | 159.13 | 21.52 | 0.687 | 0.251 |
| FORA (N = 5) | ✓ | 0.149 | 5.24 | 4.53× | 6.58 | 11.29 | 193.01 | 21.85 | 0.692 | 0.235 |
| ToCa (N = 6) | ✕ | 0.163 | 6.34 | 3.75× | 6.55 | 7.10 | 189.53 | 17.66 | 0.572 | 0.360 |
| DuCa (N = 5) | ✓ | 0.154 | 6.27 | 3.78× | 6.06 | 6.72 | 198.46 | 16.65 | 0.543 | 0.390 |
| TaylorSeer (N = 5) | ✓ | 0.195 | 5.24 | 4.53× | 2.65 | 5.36 | 231.59 | 28.50 | 0.901 | 0.065 |
| Z-Cache (N = 5) | ✓ | 0.213 | 5.25 | 4.53× | 2.46 | 4.71 | 232.34 | 29.24 | 0.908 | 0.052 |
| FORA (N = 6) | ✓ | 0.135 | 4.29 | 5.53× | 9.24 | 14.84 | 171.33 | 20.69 | 0.638 | 0.290 |
| ToCa (N = 9) | ✕ | 0.127 | 4.54 | 5.23× | 12.86 | 12.82 | 151.37 | 15.71 | 0.485 | 0.473 |
| DuCa (N = 9) | ✓ | 0.105 | 4.30 | 5.52× | 12.05 | 11.82 | 156.20 | 15.85 | 0.483 | 0.460 |
| TaylorSeer (N = 6) | ✓ | 0.191 | 4.76 | 4.98× | 3.09 | 6.50 | 225.16 | 25.48 | 0.831 | 0.107 |
| Z-Cache (N = 6) | ✓ | 0.207 | 4.78 | 4.96× | 2.68 | 4.84 | 228.26 | 27.16 | 0.880 | 0.078 |
| FORA (N = 7) | ✓ | 0.123 | 3.82 | 6.22× | 12.55 | 18.63 | 148.44 | 19.87 | 0.598 | 0.335 |
| ToCa (N = 13) | ✕ | 0.118 | 4.03 | 5.90× | 21.24 | 19.93 | 116.08 | 15.06 | 0.449 | 0.540 |
| DuCa (N = 12) | ✓ | 0.081 | 3.94 | 6.02× | 31.97 | 27.26 | 87.94 | 14.23 | 0.396 | 0.593 |
| TaylorSeer (N = 7) | ✓ | 0.177 | 3.82 | 6.22× | 3.60 | 7.07 | 217.79 | 24.09 | 0.794 | 0.136 |
| Z-Cache (N = 7) | ✓ | 0.185 | 3.82 | 6.22× | 3.25 | 5.52 | 219.30 | 23.96 | 0.795 | 0.129 |
For Z-Cache, Eq. (9) and the triangle inequality yield
where is the future-anchor prediction error. Combining Eq. (18) with Eq. (16) shows that no-reflection caching is the special case , while Z-Cache replaces the single-anchor error term with the reflected error term . Thus, whenever the dual-anchor estimate reduces hidden error over the active window, Z-Cache gives a tighter local upper bound on .
4 Experiments
4.1 Class-to-Image Generation
For comprehensive evaluation of class-conditional generation on ImageNet [Russakovsky et al., 2015], all experiments employed a DDIM-50 sampling protocol at resolution with 50,000 images generated in total. Methods implementing activation period optimization are explicitly annotated with the operator . All experiments were executed on NVIDIA H20 GPUs with standardized controls.
Quantitative evaluations on ImageNet class-to-image generation using the DiT-XL/2 model confirm that Z-Cache consistently outperforms state-of-the-art caching baselines across key metrics. As Table 1 demonstrates, Z-Cache achieves the best performance at all tested acceleration levels. Specifically, at acceleration, Z-Cache maintains both the lowest FID (3.25) and sFID (5.52) score, and also the highest Inception Score (219.30). On the contrary, FORA, ToCa and DuCa are all suffering from catastrophic degradation (FID , sFID , and Inception Score ). This signifies Z-Cache's superior preservation of image fidelity and diversity.
Furthermore, as detailed in Table 1, Z-Cache achieved a comparable performance with Taylorseer while surpassing other sampling results on the acceleration level. This comprehensive performance advantage underscores that Z-Cache generates sampling trajectories closely aligned with the original model, minimizing semantic shifts in the output data.
To better illustrate Z-Cache's mechanism, we gathered latent hidden states generated during sampling and compared their trajectories. Visualized in Figure 4, other methods often produce "bumps" during cache time as they do not perceive future states, while Z-Cache repetitively reflects past hidden states and therefore lies close to the ground truth trajectories.
4.2 Text-to-Image Generation
The paired comparisons in Table 2 show a consistent pattern: Z-Cache mainly acts as a quality-recovery module for aggressive feature caching. Across TeaCache, TaylorSeer, SpeCa, and MagCache,

Figure 4: The Trajectories of PCA components of hidden features. Z-Cache has the minimum divergence to the ground-truth comparing with other methods.
Table 2: Full paired results for cache predictors on FLUX.1-dev with DrawBench. Rows are grouped by the equivalent cache interval . Bold quality metrics indicate the better value within each Base/+Z-Cache pair; gray rows identify +Z-Cache. Parameters are abbreviated in parentheses: TeaCache uses , where ; SpeCa uses ; MagCache uses .
| Method(FLUX.1-dev) | Peak Mem(GiB) ↓ | Latency(s) ↓ | L-Speed ↑ | FLOPs(T) ↓ | F-Speed ↑ | PSNR ↑ | SSIM ↑ | LPIPS ↓ | IR ↑ |
|---|---|---|---|---|---|---|---|---|---|
| Equivalent cache interval | |||||||||
| TeaCache () | 35.77 | 2.53 | 3.67× | 891.97 | 4.17× | 28.47 | 0.6084 | 0.4691 | 1.0246 |
| TeaCache + Z-Cache () | 39.99 | 5.07 | 1.83× | 896.71 | 4.15× | 28.65 | 0.6367 | 0.4328 | 1.0147 |
| TaylorSeer | 39.96 | 3.10 | 3.00× | 745.54 | 4.99× | 28.84 | 0.6302 | 0.4359 | 0.9737 |
| TaylorSeer + Z-Cache | 39.96 | 3.29 | 2.82× | 746.47 | 4.98× | 29.22 | 0.6539 | 0.3914 | 0.9882 |
| SpeCa (100, 1, 4, 20) | 40.02 | 3.24 | 2.86× | 756.87 | 4.91× | 28.78 | 0.6617 | 0.4034 | 0.9517 |
| SpeCa + Z-Cache (100, 1, 4, 20) | 40.02 | 3.46 | 2.69× | 757.96 | 4.91× | 29.18 | 0.6806 | 0.3675 | 0.9844 |
| MagCache (.45, 7, .02) | 33.85 | 1.99 | 4.67× | 746.03 | 4.99× | 29.44 | 0.7119 | 0.3556 | 0.9316 |
| MagCache + Z-Cache (.45, 7, .02) | 37.98 | 3.37 | 2.75× | 747.27 | 4.98× | 29.73 | 0.7253 | 0.3236 | 0.9674 |
| Equivalent cache interval | |||||||||
| TeaCache () | 35.77 | 1.99 | 4.67× | 668.98 | 5.56× | 28.30 | 0.5577 | 0.5466 | 0.8715 |
| TeaCache + Z-Cache () | 39.99 | 4.75 | 1.95× | 673.17 | 5.53× | 28.41 | 0.5875 | 0.5085 | 0.8802 |
| TaylorSeer | 39.96 | 2.94 | 3.16× | 671.11 | 5.54× | 28.61 | 0.6032 | 0.4797 | 0.9455 |
| TaylorSeer + Z-Cache | 39.96 | 3.12 | 2.97× | 672.02 | 5.53× | 28.93 | 0.6310 | 0.4306 | 0.9753 |
| SpeCa (100, 1, 5, 20) | 40.02 | 2.97 | 3.12× | 679.74 | 5.47× | 28.54 | 0.6353 | 0.4527 | 0.9305 |
| SpeCa + Z-Cache (100, 1, 5, 20) | 40.02 | 3.39 | 2.74× | 680.83 | 5.46× | 28.87 | 0.6581 | 0.4059 | 0.9698 |
| MagCache (.45, 9, .02) | 33.85 | 1.94 | 4.78× | 671.50 | 5.54× | 29.41 | 0.7020 | 0.3689 | 0.9252 |
| MagCache + Z-Cache (.45, 9, .02) | 37.98 | 3.12 | 2.97× | 672.70 | 5.53× | 29.68 | 0.7164 | 0.3356 | 0.9682 |
| Equivalent cache interval | |||||||||
| TeaCache () | 35.77 | 1.87 | 4.96× | 594.65 | 6.25× | 28.24 | 0.5353 | 0.5770 | 0.7680 |
| TeaCache + Z-Cache () | 39.99 | 4.64 | 2.00× | 598.66 | 6.21× | 28.33 | 0.5702 | 0.5321 | 0.8288 |
| TaylorSeer | 39.96 | 2.83 | 3.28× | 596.69 | 6.23× | 28.46 | 0.5703 | 0.5190 | 0.9292 |
| TaylorSeer + Z-Cache | 39.96 | 3.17 | 2.93× | 597.52 | 6.22× | 28.71 | 0.6002 | 0.4692 | 0.9451 |
| SpeCa (100, 1, 6, 20) | 40.02 | 2.84 | 3.27× | 605.23 | 6.15× | 28.43 | 0.6111 | 0.4867 | 0.8874 |
| SpeCa + Z-Cache (100, 1, 6, 20) | 40.02 | 3.04 | 3.05× | 606.27 | 6.14× | 28.67 | 0.6327 | 0.4420 | 0.9004 |
| MagCache (.80, 7, .02) | 33.85 | 1.86 | 5.00× | 596.98 | 6.23× | 28.88 | 0.6582 | 0.4275 | 0.9415 |
| MagCache + Z-Cache (.80, 7, .02) | 37.98 | 2.78 | 3.34× | 598.12 | 6.22× | 29.05 | 0.6710 | 0.3994 | 0.9511 |
reflection improves PSNR, SSIM, and LPIPS in every matched setting, while ImageReward improves in all but one case. These results indicate Z-Cache can be directly applied to any existing feature caching methods.
Table 2 also separates arithmetic cost from practical wall-clock cost. Since Z-Cache reuses the next scheduled full-computation anchor rather than inserting extra full steps, the additional FLOPs are small. The FLOP overhead is below 0.7% for all paired settings and below 0.2% for TaylorSeer, SpeCa, and MagCache, so the FLOPs speedup is nearly unchanged after reflection. However, latency and peak memory are more predictor-dependent. For TaylorSeer and SpeCa, Z-Cache introduces modest latency overhead and no measured increase in peak memory. For TeaCache and MagCache, the quality gain remains consistent, but the current implementation incurs a larger wall-clock cost and higher peak memory. This suggests that Z-Cache should be viewed as a FLOPs-light quality-recovery wrapper rather than a universally latency-free module.
Figure 5 further shows an interval sweep where TaylorSeer progressively loses semantic details as increases, while Z-Cache preserves the object layout and visual identity over larger cache intervals. Together, the prompt-level comparison and the interval sweep are consistent with the quantitative trend in Table 2: revisiting the active cache window with a future anchor reduces cache-induced semantic drift under high acceleration.

Figure 5: Semantic stability under increasing cache interval . As the cache interval increases, TaylorSeer gradually accumulates semantic drift, while Z-Cache maintains more stable object layout and visual identity.
4.3 Text-to-Video Generation
Table 3: Quantitative comparison on text-to-video generation with HunyuanVideo on VBench. L-Speed and F-Speed are the latency and FLOPs speedups relative to the original 50-step model. Within each caching block, bold numbers indicate the best values, including ties.
| Method(on HunyuanVideo) | EfficientAttention | Acceleration | VBenchScore(%) | |||
|---|---|---|---|---|---|---|
| Latency(s) ↓ | L-Speed ↑ | FLOPs(T) ↓ | F-Speed ↑ | |||
| Original: 50 steps | ✓ | 145.00 | 1.00× | 29773.0 | 1.00× | 80.66 |
| 22% steps | ✓ | 31.87 | 4.55× | 6550.1 | 4.55× | 78.74 |
| TeaCache (l = 0.4) | ✓ | 26.61 | 5.45× | 6550.1 | 4.55× | 79.36 |
| FORA (N = 5) | ✓ | 34.39 | 4.22× | 5960.4 | 5.00× | 78.83 |
| ToCa (N = 5, R = 90%) | ✗ | 38.52 | 3.76× | 7006.2 | 4.25× | 78.86 |
| DuCa (N = 5, R = 90%) | ✓ | 31.69 | 4.58× | 6483.2 | 4.59× | 78.72 |
| TaylorSeer (N = 5, O = 1) | ✓ | 25.34 | 5.72× | 5960.4 | 5.00× | 79.93 |
| Z-Cache (N = 5, O = 1) | ✓ | 28.69 | 5.05× | 5997.2 | 4.96× | 80.10 |
| TeaCache (l = 0.5) | ✓ | 26.61 | 5.45× | 5359.1 | 5.56× | 78.32 |
| TaylorSeer (N = 7, O = 1) | ✓ | 21.01 | 6.90× | 4794.5 | 6.21× | 79.09 |
| Z-Cache (N = 7, O = 1) | ✓ | 23.08 | 6.28× | 4799.6 | 6.20× | 79.60 |

Figure 6: Visualization of videos generated by Hunyuan Video with different feature caching methods. The annotated speedups denote FLOPs reductions relative to 50-step sampling.
Extending to video synthesis on HunyuanVideo, Z-Cache maintains a consistent and comparable performance with other competing methods on the VBench metric. As Table 3 shows, our method achieves the highest VBench scores within the two caching groups (80.10 at 4.96× FLOPs speedup and 79.60 at 6.20× FLOPs speedup). This demonstrates Z-Cache's advantage for video diffu-sion acceleration, where existing caching strategies struggle to balance efficiency with temporal consistency.
Beyond quantitative metrics, we present qualitative comparisons of these methods on identical frame sequences in Figure 6. For instance, in the “a motorcycle” video, Z-Cache generates a coherent depiction of the rider’s face, whereas methods like TaylorSeer produce distorted facial features or fragmented figures. In the “a blue clock with white numbers” video, several baselines generate extra or distorted clock hands, whereas Z-Cache better preserves the intended clock structure. Finally, in the “a fork on the right of a knife” video, all baseline methods either produce malformed or misshapen knives or completely disregard the fork, whereas Z-Cache accurately captures both objects in their correct spatial arrangement.
4.4 Miscellaneous
To test whether Z-Cache remains effective in the few-step regime, we additionally evaluate it on a distilled model, as reported in Table 4a. Specifically, we compare Z-Cache with TaylorSeer and ToCa on Qwen-Image-Lightning using an 8-step sampler. Z-Cache achieves the highest PSNR and the lowest LPIPS among the methods, while maintaining comparable SSIM. These results show that, even under aggressive distillation with very few denoising steps, Z-Cache still delivers a clear improvement over prior cache-based baselines, indicating that cache-based acceleration can remain beneficial beyond standard multi-step diffusion settings.
Table 4: Additional quantitative results on few-step generation, image editing, U-Net backbones, and non-cache acceleration settings. All Z-Cache variants use the TaylorSeer predictor, and the number in parentheses is the cache interval.
(a) Few-step distilled model Qwen-Image-Lightning on DrawBench.
| Method | PSNR ↑ | SSIM ↑ | LPIPS ↓ |
|---|---|---|---|
| TaylorSeer (2) | 30.222 | 0.6734 | 0.2984 |
| ToCa (2) | 29.546 | 0.6780 | 0.2938 |
| Z-Cache (2) | 30.440 | 0.6785 | 0.2910 |
(c) FLUX-Kontext-dev [Labs et al., 2025] on Gedit-bench [Liu et al., 2025e].
| Method | PSNR ↑ | SSIM ↑ | LPIPS ↓ |
|---|---|---|---|
| TaylorSeer (8) | 29.014 | 0.4338 | 0.4448 |
| Z-Cache (8) | 29.511 | 0.5114 | 0.3694 |
| TaylorSeer (7) | 29.675 | 0.5013 | 0.3658 |
| Z-Cache (7) | 30.279 | 0.5667 | 0.3015 |
(b) Comparison with other acceleration methods on DrawBench.
| Method | PSNR ↑ | SSIM ↑ | LPIPS ↓ | ImageReward ↑ | Accel. ↑ |
|---|---|---|---|---|---|
| ToMA [Lu et al., 2025] | 29.271 | 0.6984 | 0.4258 | 0.7812 | 1.21× |
| 8bit | 32.331 | 0.8334 | 0.1770 | 1.1971 | 2.10× |
| 8bit TaylorSeer (2) | 33.085 | 0.8197 | 0.1413 | 0.8773 | 3.12× |
| 8bit Z-Cache (2) | 33.600 | 0.8289 | 0.1337 | 0.8877 | 3.12× |
| Flux-mini | 28.101 | 0.5186 | 0.6449 | 0.2522 | 3.80× |
| Z-Cache (4) | 30.570 | 0.7758 | 0.2406 | 0.9890 | 2.17× |
(d) Experiments with the U-Net model SDXL [Podell et al., 2023] on DrawBench.
| Method | PSNR ↑ | SSIM ↑ | LPIPS ↓ | ImageReward ↑ | Accel. ↑ |
|---|---|---|---|---|---|
| TaylorSeer (5) | 29.028 | 0.6969 | 0.3294 | 0.3350 | 2.61× |
| Z-Cache (5) | 29.399 | 0.7112 | 0.3100 | 0.3788 | 2.61× |
| TaylorSeer (7) | 28.251 | 0.6041 | 0.4528 | 0.1024 | 4.00× |
| Z-Cache (7) | 28.589 | 0.6373 | 0.4162 | 0.1802 | 4.00× |
In addition to free-form generation, we also evaluate Z-Cache in an image-editing setting. Specifically, we run FLUX-Kontext-dev on the Gedit-bench benchmark and compare Z-Cache with TaylorSeer, as summarized in Table 4c. At the same acceleration ratio, Z-Cache achieves higher PSNR and SSIM while substantially reducing LPIPS. These improvements indicate that Z-Cache better preserves the source image’s structure and perceptual details, which are crucial for maintaining subject identity and keeping non-edited background regions consistent.
We further compare Z-Cache with non-caching acceleration methods in Table 4b. The results show that Z-Cache is complementary to quantization: adding Z-Cache on top of 8-bit quantization (8bit Z-Cache) increases the speedup from 2.10× (8bit only) to 3.12×, while also improving PSNR and reducing LPIPS. Under the same 3.12× acceleration budget, 8bit Z-Cache consistently outperforms 8bit TaylorSeer across all four metrics (PSNR, SSIM, LPIPS, and ImageReward), indicating that the reflection step provides non-trivial gains even when the backbone is already compressed. In contrast, a distilled model such as Flux-mini achieves a comparable speedup (3.80×) but with substantially worse fidelity and preference scores, suggesting that cache-based acceleration remains competitive in the high-speed regime. Overall, these results support the view that Z-Cache is not a replacement for quantization/pruning, but a plug-in that can be layered on top of them.
We additionally evaluate Z-Cache on SDXL, a U-Net-based diffusion model, and directly compare it with TaylorSeer under matched step budgets (i.e., the same cache-step setting). As summarized in Table 4d, Z-Cache consistently improves PSNR and SSIM, reduces LPIPS, and achieves higher ImageReward than TaylorSeer across both acceleration ratios, while using the same number of cache steps. These results indicate that the proposed cache-then-check mechanism generalizes beyond DiT-style backbones and naturally transfers to U-Net architectures.
Additional trajectory controls, fusion and replay ablations, and recent-predictor compositions are reported in Appendix A.3.
5 Conclusion
This paper introduces Z-Cache, a novel caching framework that redefines the efficiency-quality trade-off for diffusion transformers. Central to its innovation is a self-reflective mechanism, which periodically refines intermediate features through "future-aware" feature integration—enabling substantial acceleration without sacrificing output fidelity. By integrating this mechanism, Z-Cache achieves exceptional acceleration (up to 6.22× faster inference on FLUX-dev.1) while preserving high output quality. Beyond static image generation, Z-Cache demonstrates remarkable adaptability to video tasks, attaining a state-of-the-art 6.20× acceleration rate for videos, all while maintaining high output quality.
Acknowledgment
This paper was partially sponsored by WUYING - Alibaba Cloud.
References
Black Forest Labs. Flux. https://github.com/black-forest-labs/flux, 2024. URL https://github.com/black-forest-labs/flux.
Daniel Bolya and Judy Hoffman. Token merging for fast stable diffusion. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR) Workshops, pages 4599–4603, 2023.
Peiliang Cai, Jiacheng Liu, Haowen Xu, Xinyu Wang, Chang Zou, and Linfeng Zhang. Lesa: Learnable stage-aware predictors for diffusion model acceleration, 2026. URL https://arxiv.org/abs/2602.20497.
Junsong Chen, Chongjian Ge, Enze Xie, Yue Wu, Lewei Yao, Xiaozhe Ren, Zhongdao Wang, Ping Luo, Huchuan Lu, and Zhenguo Li. Pixart-: Weak-to-strong training of diffusion transformer for 4k text-to-image generation, 2024a.
Junsong Chen, Jincheng Yu, Chongjian Ge, Lewei Yao, Enze Xie, Yue Wu, Zhongdao Wang, James Kwok, Ping Luo, Huchuan Lu, and Zhenguo Li. Pixart-: Fast training of diffusion transformer for photorealistic text-to-image synthesis. In International Conference on Learning Representations, 2024b.
Pengtao Chen, Mingzhu Shen, Peng Ye, Jianjian Cao, Chongjun Tu, Christos-Savvas Bouganis, Yiren Zhao, and Tao Chen. -dit: A training-free acceleration method tailored for diffusion transformers. arXiv preprint arXiv:2406.01125, 2024c. URL https://arxiv.org/abs/2406.01125.
Xinle Cheng, Zhuoming Chen, and Zhihao Jia. Cat pruning: Cluster-aware token pruning for text-to-image diffusion models, 2025. URL https://arxiv.org/abs/2502.00433.
Gongfan Fang, Xinyin Ma, and Xinchao Wang. Structural pruning for diffusion models. arXiv preprint arXiv:2305.10924, 2023.
Haipeng Fang, Yu Li, Fan Tang, Yixing Lu, Juan Cao, and Sheng Tang. ResCa: Residual caching for diffusion transformers acceleration. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pages 32957–32966, June 2026. URL https://openaccess.thecvf.com/content/CVPR2026/html/Fang_ResCa_Residual_Caching_for_Diffusion_Transformers_Acceleration_CVPR_2026_paper.html.
Liang Feng, Shikang Zheng, Jiacheng Liu, Yuqi Lin, Qinming Zhou, Peiliang Cai, Xinyu Wang, Junjie Chen, Chang Zou, Yue Ma, and Linfeng Zhang. Hicache: Training-free acceleration of diffusion models via hermite polynomial-based feature caching, 2025. URL https://arxiv.org/abs/2508.16984v1.
Yasaman Haghighi and Alexandre Alahi. SenCache: Accelerating diffusion model inference via sensitivity-aware caching. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pages 14295–14304, June 2026. URL https://openaccess.thecvf.com/content/CVPR2026/html/Haghighi_SenCache_Accelerating_Diffusion_Model_Inference_via_Sensitivity_Aware_Caching_CVPR_2026_paper.html.
Jonathan Ho, Ajay Jain, and Pieter Abbeel. Denoising diffusion probabilistic models. Advances in neural information processing systems, 33:6840–6851, 2020. URL https://proceedings.neurips.cc/paper/2020/hash/4c5bcfec8584af0d967f1ab10179ca4b-Abstract.html.
Minchul Kim, Shangqian Gao, Yen-Chang Hsu, Yilin Shen, and Hongxia Jin. Token fusion: Bridging the gap between token pruning and token merging. In Proceedings of the IEEE/CVF Winter Conference on Applications of Computer Vision, pages 1383–1392, 2024.
Sungbin Kim, Hyunwuk Lee, Wonho Cho, Mincheol Park, and Won Woo Ro. Ditto: Accelerating diffusion model via temporal value similarity. In Proceedings of the 2025 IEEE International Symposium on High-Performance Computer Architecture (HPCA). IEEE, 2025.
Weijie Kong, Qi Tian, Zijian Zhang, Rox Min, Zuozhuo Dai, Jin Zhou, Jiangfeng Xiong, Xin Li, Bo Wu, Jianwei Zhang, Kathrina Wu, Qin Lin, Junkun Yuan, Yanxin Long, Aladdin Wang, Andong Wang, Changlin Li, Duojun Huang, Fang Yang, Hao Tan, Hongmei Wang, Jacob Song, Jiawang Bai, Jianbing Wu, Jinbao Xue, Joey Wang, Kai Wang, Mengyang Liu, Pengyu Li, Shuai Li, Weiyan Wang, Wenqing Yu, Xinchi Deng, Yang Li, Yi Chen, Yutao Cui, Yuanbo Peng, Zhentao Yu, Zhiyu He, Zhiyong Xu, Zixiang Zhou, Zunnan Xu, Yangyu Tao, Qinglin Lu, Songtao Liu, Dax Zhou, Hongfa Wang, Yong Yang, Di Wang, Yuhong Liu, Jie Jiang, and Caesar Zhong. HunyuanVideo: A systematic framework for large video generative models, 2024. URL https://arxiv.org/abs/2412.03603.
Black Forest Labs, Stephen Batifol, Andreas Blattmann, Frederic Boesel, Saksham Consul, Cyril Diagne, Tim Dockhorn, Jack English, Zion English, Patrick Esser, Sumith Kulal, Kyle Lacey, Yam Levi, Cheng Li, Dominik Lorenz, Jonas Müller, Dustin Podell, Robin Rombach, Harry Saini, Axel Sauer, and Luke Smith. Flux.1 kontext: Flow matching for in-context image generation and editing in latent space, 2025. URL https://arxiv.org/abs/2506.15742.
Senmao Li, Taihang Hu, Fahad Shahbaz Khan, Linxuan Li, Shiqi Yang, Yaxing Wang, Ming-Ming Cheng, and Jian Yang. Faster diffusion: Rethinking the role of unet encoder in diffusion models. arXiv preprint arXiv:2312.09608v1, 2023a. URL https://arxiv.org/abs/2312.09608v1.
Xiuyu Li, Yijiang Liu, Long Lian, Huanrui Yang, Zhen Dong, Daniel Kang, Shanghang Zhang, and Kurt Keutzer. Q-diffusion: Quantizing diffusion models. In 2023 IEEE/CVF International Conference on Computer Vision (ICCV), pages 17489–17499, 2023b. doi: 10.1109/ICCV51070.2023.01608.
Yanyu Li, Huan Wang, Qing Jin, Ju Hu, Pavlo Chemerys, Yun Fu, Yanzhi Wang, Sergey Tulyakov, and Jian Ren. Snapfusion: Text-to-image diffusion model on mobile devices within two seconds. Advances in Neural Information Processing Systems, 36, 2023c.
Enhuai Liu, Yunke Wang, Changming Sun, and Chang Xu. D2Cache: Second-order delta caching for higher video diffusion acceleration. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pages 43589–43599, June 2026. URL https://openaccess.thecvf.com/content/CVPR2026/html/Liu_D2Cache_Second-Order_Delta_Caching_for_Higher_Video_Diffusion_Acceleration_CVPR_2026_paper.html.
Feng Liu, Shiwei Zhang, Xiaofeng Wang, Yujie Wei, Haonan Qiu, Yuzhong Zhao, Yingya Zhang, Qixiang Ye, and Fang Wan. Timestep embedding tells: It's time to cache for video diffusion model, 2024. URL https://arxiv.org/abs/2411.19108.
Jiacheng Liu, Peiliang Cai, Qinming Zhou, Yuqi Lin, Deyang Kong, Benhao Huang, Yupei Pan, Haowen Xu, Chang Zou, Junshu Tang, Shikang Zheng, and Linfeng Zhang. FreqCa: Accelerating diffusion models via frequency-aware caching, 2025a. URL https://arxiv.org/abs/2510.08669.
Jiacheng Liu, Xinyu Wang, Yuqi Lin, Zhikai Wang, Peiru Wang, Peiliang Cai, Qinming Zhou, Zhengan Yan, Zexuan Yan, Zhengyi Shi, Chang Zou, Yue Ma, and Linfeng Zhang. A survey on cache methods in diffusion models: Toward efficient multi-modal generation, 2025b. URL https://arxiv.org/abs/2510.19755.
Jiacheng Liu, Chang Zou, Yuanhuiyi Lyu, Junjie Chen, and Linfeng Zhang. From reusing to forecasting: Accelerating diffusion models with taylorseers, 2025c. URL https://arxiv.org/abs/2503.06923.
Jiacheng Liu, Chang Zou, Yuanhuiyi Lyu, Fei Ren, Shaobo Wang, Kaixin Li, and Linfeng Zhang. Speca: Accelerating diffusion transformers with speculative feature caching. In Proceedings of the 33rd ACM International Conference on Multimedia, MM '25, page 10024–10033. ACM, October 2025d. doi: 10.1145/3746027.3755331. URL http://dx.doi.org/10.1145/3746027.3755331.
Shiyu Liu, Yucheng Han, Peng Xing, Fukun Yin, Rui Wang, Wei Cheng, Jiaqi Liao, Yingming Wang, Honghao Fu, Chunrui Han, Guopeng Li, Yuang Peng, Quan Sun, Jingwei Wu, Yan Cai, Zheng
Ge, Ranchen Ming, Lei Xia, Xianfang Zeng, Yibo Zhu, Binxing Jiao, Xiangyu Zhang, Gang Yu, and Daxin Jiang. Step1x-edit: A practical framework for general image editing, 2025e. URL https://arxiv.org/abs/2504.17761.
Xingchao Liu, Chengyue Gong, and Qiang Liu. Flow straight and fast: Learning to generate and transfer data with rectified flow. In The Eleventh International Conference on Learning Representations, 2023. URL https://iclr.cc/virtual/2023/poster/11266.
Ziming Liu, Yifan Yang, Chengruidong Zhang, Yiqi Zhang, Lili Qiu, Yang You, and Yuqing Yang. Region-adaptive sampling for diffusion transformers, 2025f. URL https://arxiv.org/abs/2502.10389.
Cheng Lu, Yuhao Zhou, Fan Bao, Jianfei Chen, Chongxuan Li, and Jun Zhu. Dpm-solver: A fast ode solver for diffusion probabilistic model sampling in around 10 steps. Advances in Neural Information Processing Systems, 35:5775–5787, 2022a.
Cheng Lu, Yuhao Zhou, Fan Bao, Jianfei Chen, Chongxuan Li, and Jun Zhu. Dpm-solver++: Fast solver for guided sampling of diffusion probabilistic models. arXiv preprint arXiv:2211.01095, 2022b.
Wenbo Lu, Shaoyi Zheng, Yuxuan Xia, and Shengjie Wang. Toma: Token merge with attention for diffusion models, 2025. URL https://arxiv.org/abs/2509.10918.
Xinyin Ma, Gongfan Fang, and Xinchao Wang. Deepcache: Accelerating diffusion models for free. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 15762–15772, 2024. URL https://openaccess.thecvf.com/content/CVPR2024/html/Ma_DeepCache_Accelerating_Diffusion_Models_for_Free_CVPR_2024_paper.html.
Zehong Ma, Longhui Wei, Feng Wang, Shiliang Zhang, and Qi Tian. Magcache: Fast video generation with magnitude-aware cache, 2025. URL https://arxiv.org/abs/2506.09045.
Chenlin Meng, Ruiqi Gao, Diederik P Kingma, Stefano Ermon, Jonathan Ho, and Tim Salimans. On distillation of guided diffusion models. In NeurIPS 2022 Workshop on Score-Based Methods, 2022. URL https://arxiv.org/abs/2210.03142v1.
William Peebles and Saining Xie. Scalable diffusion models with transformers. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pages 4195–4205, 2023. doi: 10.1109/ICCV51070.2023.00387. URL https://openaccess.thecvf.com/content/ICCV2023/html/Peebles_Scalable_Diffusion_Models_with_Transformers_ICCV_2023_paper.html.
Dustin Podell, Zion English, Kyle Lacey, Andreas Blattmann, Tim Dockhorn, Jonas Müller, Joe Penna, and Robin Rombach. Sdxl: Improving latent diffusion models for high-resolution image synthesis, 2023. URL https://arxiv.org/abs/2307.01952.
Haoran Qin, Zhengan Yan, Shikang Zheng, Xiaobing Tu, Jiacheng Liu, Yuqi Lin, Chang Zou, JinShan Liu, Peiliang Cai, Xiantao Zhang, Jinkui Ren, and Linfeng Zhang. Avits: Adaptive spatiotemporal token selection for efficient dynamic-resolution generation, 2026. URL https://arxiv.org/abs/2608.17995.
Junxiang Qiu, Shuo Wang, Jinda Lu, Lin Liu, Houcheng Jiang, and Yanbin Hao. Accelerating diffusion transformer via error-optimized cache, 2025. URL https://arxiv.org/abs/2501.19243v1.
Olaf Ronneberger, Philipp Fischer, and Thomas Brox. U-net: Convolutional networks for biomedical image segmentation. In Medical image computing and computer-assisted intervention–MICCAI 2015: 18th international conference, Munich, Germany, October 5-9, 2015, proceedings, part III 18, pages 234–241. Springer, 2015.
Olga Russakovsky, Jia Deng, Hao Su, Jonathan Krause, Sanjeev Satheesh, Sean Ma, Zhiheng Huang, Andrej Karpathy, Aditya Khosla, Michael Bernstein, Alexander C. Berg, and Li Fei-Fei. ImageNet Large Scale Visual Recognition Challenge. International Journal of Computer Vision, 115(3): 211–252, December 2015. doi: 10.1007/s11263-015-0816-y. URL https://link.springer.com/article/10.1007/s11263-015-0816-y.
Omid Saghatchian, Atiyeh Gh. Moghadam, and Ahmad Nickabadi. Cached adaptive token merging: Dynamic token reduction and redundant computation elimination in diffusion model, 2025.
Tim Salimans and Jonathan Ho. Progressive distillation for fast sampling of diffusion models. arXiv preprint arXiv:2202.00512, 2022.
Pratheba Selvaraju, Tianyu Ding, Tianyi Chen, Ilya Zharkov, and Luming Liang. Fora: Fast-forward caching in diffusion transformer acceleration. arXiv preprint arXiv:2407.01425, 2024. URL https://arxiv.org/abs/2407.01425.
Yuzhang Shang, Zhihang Yuan, Bin Xie, Bingzhe Wu, and Yan Yan. Post-training quantization on diffusion models. In Proceedings of the IEEE/CVF conference on computer vision and pattern recognition, pages 1972–1981, 2023.
Zhirong Shen, Rui Huang, Jiacheng Liu, Chang Zou, Peiliang Cai, Shikang Zheng, Zhengyi Shi, Liang Feng, and Linfeng Zhang. Beyond fixed formulas: Data-driven linear predictor for efficient diffusion models, 2026a. URL https://arxiv.org/abs/2604.26365.
Zhirong Shen, Rui Huang, Chang Zou, Shikang Zheng, Jiacheng Liu, Peiliang Cai, Zhengyi Shi, Yaosong Du, Liang Feng, Xiaobing Tu, Jinkui Ren, Xiantao Zhang, and Linfeng Zhang. Accelerating diffusion transformers with gaussian process rectified feature cache, 2026b. URL https://arxiv.org/abs/2609.05981.
Jascha Sohl-Dickstein, Eric Weiss, Niru Maheswaranathan, and Surya Ganguli. Deep unsupervised learning using nonequilibrium thermodynamics. In International conference on machine learning, pages 2256–2265. PMLR, 2015.
Jiaming Song, Chenlin Meng, and Stefano Ermon. Denoising diffusion implicit models. In International Conference on Learning Representations, 2021. URL https://iclr.cc/virtual/2021/poster/2804.
Yang Song, Prafulla Dhariwal, Mark Chen, and Ilya Sutskever. Consistency models. In International Conference on Machine Learning, pages 32211–32252. PMLR, 2023.
Wenzhang Sun, Qirui Hou, Donglin Di, Jiahui Yang, Yongjia Ma, and Jianxun Cui. Unicp: A unified caching and pruning framework for efficient video generation, 2025. URL https://arxiv.org/abs/2502.04393.
Zhengan Yan, Shikang Zheng, Haoran Qin, Xiaobing Tu, Yinggui Wang, Jiacheng Liu, Jiaxuan Ren, Yuqi Lin, Peiliang Cai, Jinkui Ren, Xiantao Zhang, and Linfeng Zhang. Specedit: Training-free acceleration for diffusion based image editing via semantic locking, 2026. URL https://arxiv.org/abs/2605.02152.
Zhuoyi Yang, Jiayan Teng, Wendi Zheng, Ming Ding, Shiyu Huang, Jiazheng Xu, Yuanming Yang, Wenyi Hong, Xiaohan Zhang, Guanyu Feng, Da Yin, Yuxuan Zhang, Weihan Wang, Yean Cheng, Bin Xu, Xiaotao Gu, Yuxiao Dong, and Jie Tang. Cogvideox: Text-to-video diffusion models with an expert transformer. In The Thirteenth International Conference on Learning Representations, 2025. URL https://proceedings.iclr.cc/paper_files/paper/2025/hash/ce31378e9f41d8907e97dab172b6c559-Abstract-Conference.html.
Evelyn Zhang, Bang Xiao, Jiayi Tang, Qianli Ma, Chang Zou, Xuefei Ning, Xuming Hu, and Linfeng Zhang. Token pruning for caching better: 9 times acceleration on stable diffusion for free, 2024. URL https://arxiv.org/abs/2501.00375.
Evelyn Zhang, Jiayi Tang, Xuefei Ning, and Linfeng Zhang. Training-free and hardware-friendly acceleration for diffusion models via similarity-based token pruning. In Proceedings of the AAAI Conference on Artificial Intelligence, 2025.
Kaiwen Zheng, Cheng Lu, Jianfei Chen, and Jun Zhu. DPM-solver-v3: Improved diffusion ODE solver with empirical model statistics. In Thirty-seventh Conference on Neural Information Processing Systems, 2023. URL https://proceedings.neurips.cc/paper_files/paper/2023/hash/ada8de994b46571bdcd7eeff2d3f9cff-Abstract-Conference.html.
Shikang Zheng, Guantao Chen, Qinming Zhou, Yuqi Lin, Lixuan He, Chang Zou, Peiliang Cai, Jiacheng Liu, and Linfeng Zhang. Let features decide their own solvers: Hybrid feature caching for diffusion transformers, 2025a. URL https://arxiv.org/abs/2510.04188.
Shikang Zheng, Liang Feng, Xinyu Wang, Qinming Zhou, Peiliang Cai, Chang Zou, Jiacheng Liu, Yuqi Lin, Junjie Chen, Yue Ma, and Linfeng Zhang. Forecast then calibrate: Feature caching as ode for efficient diffusion transformers, 2025b. URL https://arxiv.org/abs/2508.16211.
Shikang Zheng, Guantao Chen, Lixuan He, Jiacheng Liu, Yuqi Lin, Chang Zou, and Linfeng Zhang. From sketch to fresco: Efficient diffusion transformer with progressive resolution, 2026a. URL https://arxiv.org/abs/2601.07462.
Shikang Zheng, Jingkai Huang, Jiacheng Liu, Guantao Chen, Lixuan He, Yuqi Lin, Peiliang Cai, and Linfeng Zhang. Dynamic video generation: Shaping video generation across time and space, 2026b. URL https://arxiv.org/abs/2605.21042.
Zangwei Zheng, Xiangyu Peng, Tianji Yang, Chenhui Shen, Shenggui Li, Hongxin Liu, Yukun Zhou, Tianyi Li, and Yang You. Open-sora: Democratizing efficient video production for all, 2024. URL https://arxiv.org/abs/2412.20404.
Haowei Zhu, Dehua Tang, Ji Liu, Mingjie Lu, Jintu Zheng, Jinzhang Peng, Dong Li, Yu Wang, Fan Jiang, Lu Tian, Spandan Tiwari, Ashish Sirasao, Jun-Hai Yong, Bin Wang, and Emad Barsoum. Dip-go: A diffusion pruner via few-step gradient optimization, 2024.
Chang Zou, Xuyang Liu, Ting Liu, Siteng Huang, and Linfeng Zhang. Accelerating diffusion transformers with token-wise feature caching. arXiv preprint arXiv:2410.05317, 2024a. URL https://arxiv.org/abs/2410.05317.
Chang Zou, Evelyn Zhang, Runlin Guo, Haohang Xu, Conghui He, Xuming Hu, and Linfeng Zhang. Accelerating diffusion transformers with dual feature caching, 2024b. URL https://arxiv.org/abs/2412.18911v1.
Chang Zou, Changlin Li, Yang Li, Patrol Li, Jianbing Wu, Xiao He, Songtao Liu, Zhao Zhong, Kailin Huang, and Linfeng Zhang. Disca: Accelerating video diffusion transformers with distillation-compatible learnable feature caching, 2026. URL https://arxiv.org/abs/2602.05449.
A Appendix
A.1 Additional Related Works
Diffusion models and diffusion transformers. Diffusion models [Sohl-Dickstein et al., 2015, Ho et al., 2020] generate data through iterative denoising and have become a dominant framework for visual generation. Early systems were largely based on U-Net architectures [Ronneberger et al., 2015], while recent large-scale models increasingly adopt diffusion transformers (DiTs) [Peebles and Xie, 2023]. This architectural shift has enabled strong image and video generation performance across modern systems [Chen et al., 2024b,a, Zheng et al., 2024, Yang et al., 2025]. However, the iterative sampling process remains computationally expensive, motivating two broad acceleration directions: reducing the number of sampling timesteps and reducing the per-step cost of the denoising network.
Sampling timestep reduction. Timestep reduction methods aim to preserve generation quality with fewer denoising iterations. DDIM [Song et al., 2021] introduces deterministic sampling for faster inference, while DPM-Solver and its variants [Lu et al., 2022a,b, Zheng et al., 2023] use high-order ODE solvers to reduce the number of function evaluations. Rectified Flow [Liu et al., 2023] learns straighter paths between noise and data, and distillation-based approaches compress multi-step generation into fewer steps [Salimans and Ho, 2022, Meng et al., 2022]. Consistency Models [Song et al., 2023] further enable one-step or few-step generation by directly mapping noisy inputs to clean outputs. These methods reduce sampling length and are orthogonal to our goal of improving feature caching within a given sampling schedule.
Denoising network acceleration. Another line of work accelerates the denoising network at each timestep. Compression-based methods include pruning [Fang et al., 2023, Zhu et al., 2024], quantization [Li et al., 2023b, Shang et al., 2023, Kim et al., 2025], distillation [Li et al., 2023c], and token reduction or token merging [Bolya and Hoffman, 2023, Kim et al., 2024, Zhang et al., 2024, 2025, Cheng et al., 2025, Saghatchian et al., 2025], alongside dynamic-resolution approaches [Zheng et al., 2026a, Yan et al., 2026, Zheng et al., 2026b, Qin et al., 2026]. These approaches reduce computation by simplifying model weights, activations, or token sequences. Although effective, they often require tuning, calibration, or careful engineering to maintain the quality–efficiency balance. Z-Cache is complementary to these methods because it is training-free and modifies the inference-time feature-caching trajectory rather than the model parameters.
Feature caching-based acceleration. Feature caching exploits temporal redundancy across diffusion timesteps to accelerate inference [Liu et al., 2025b,a]. Early caching methods for U-Net diffusion models include Faster Diffusion [Li et al., 2023a] and DeepCache [Ma et al., 2024]. Recent methods extend this idea to transformer-based diffusion models. FORA [Selvaraju et al., 2024] and -DiT [Chen et al., 2024c] reuse attention or representation states across nearby steps. TeaCache [Liu et al., 2024] uses timestep-adaptive caching, while ToCa and DuCa [Zou et al., 2024a,b] cache token-wise or dual feature representations. Other methods improve efficiency through error-aware caching, adaptive caching-pruning combinations, or spatially varying sampling strategies [Qiu et al., 2025, Sun et al., 2025, Liu et al., 2025f].
Forecasting and predictor-oriented caching. More recent feature-caching methods improve the base cache predictor itself [Zheng et al., 2025a, Cai et al., 2026, Shen et al., 2026b, Zou et al., 2026, Shen et al., 2026a]. TaylorSeer [Liu et al., 2025c] predicts intermediate features using polynomial extrapolation from neighboring cached activations, which establishes the cache-then-forecast paradigm. SpeCa [Liu et al., 2025d] introduces speculative feature caching, and MagCache [Ma et al., 2025] exploits magnitude-aware caching for efficient generation. These works primarily focus on improving feature prediction or cache scheduling.
Sensitivity-aware, second-order, and spatial residual caching. Recent methods address different sources of caching error. SenCache [Haghighi and Alahi, 2026] estimates how denoising outputs respond to changes in the latent input and timestep, and uses these sensitivities to decide whether cached outputs can be reused for each sample. Its sensitivity estimates are obtained using a small calibration set. D2Cache [Liu et al., 2026] augments a cached first-order residual with a second-order residual difference and scales this correction using error estimates derived from timestep embeddings.
ResCa [Fang et al., 2026] exploits similarity among token denoising trajectories: it computes a proxy token for each cluster and uses multi-order residuals to guide simulated updates of the remaining tokens. Its updates combine a token's historical residuals with current residual information from the proxy. These approaches respectively emphasize sensitivity-guided cache decisions, temporal residual prediction, and spatially shared denoising information.
Relation to Z-Cache. Z-Cache performs retrospective trajectory correction within an active cache window. Once the next scheduled full-computation anchor is observed on the provisional trajectory, Z-Cache combines past-anchor and future-anchor predictions, replays the window, and commits the reflected endpoint before continuing denoising. This differs from SenCache's reuse decisions, D2Cache's temporal extrapolation, and ResCa's current-step proxy-guided token updates. Z-Cache can therefore complement compatible cache policies and predictors while preserving the base full-computation schedule, provided their cached representations and state updates support dual-anchor prediction and window replay.
A.2 Experiment Settings
A.2.1 DiT
We conducted experiments mainly on three state-of-the-art diffusion architectures: DiT-XL/2 [Peebles and Xie, 2023], FLUX.1-dev [Black Forest Labs, 2024], and HunyuanVideo [Kong et al., 2024]. A per-model subset of baselines was systematically selected from the literature: FORA [Selvaraju et al., 2024], ToCa [Zou et al., 2024a], DuCa [Zou et al., 2024b], TeaCache Liu et al. [2024], and TaylorSeer [Liu et al., 2025c].
A.2.2 FLUX-dev.1
We evaluate text-guided image generation on FLUX.1-dev with DrawBench. Each method generates 200 images at resolution using the default sampling configuration. To make the efficiency comparison explicit, we report end-to-end H100 latency, peak CUDA memory, and FLOPs under the same implementation. FLOPs speed is normalized by the original 50-step FLUX.1-dev cost. PSNR, SSIM, and LPIPS are computed against the corresponding full 50-step FLUX.1-dev outputs under the same prompts and seeds, while ImageReward is computed on generated image-prompt pairs.
A.2.3 HunyuanVideo
For video generation tasks, all experiments utilized the model's default configuration. We generated a total of 4720 video sequences (65 frames per sequence at resolution) from VBench with 4 samples each. Evaluation employed the comprehensive VBench framework. Since all methods produce noticeable semantic shifts, we skipped all pixel-level evaluation for the best interpretation.
A.3 Supplementary Experiments
A.3.1 Global trajectory comparison
We compare Full sampling, TaylorSeer without reflection, and canonical Z-Cache on FLUX.1-dev using 32 frozen DrawBench prompts, two seeds per prompt, and cache intervals . Each paired sample shares its initial latent and the 50-step scheduler. We save all 50 latent tensors. For Z-Cache, the last replayed value replaces the provisional value at each revisited step; this reconciled trajectory is the primary comparison.
For method , define the relative latent error and its normalized trapezoidal area under the curve (AUC) as
Table 5 reports sample means.
Table 5: Global latent trajectories relative to the shared Full reference.
| N | Metric | TaylorSeer | Z-Cache |
|---|---|---|---|
| 6 | AUC ↓ | 0.212977 | 0.198117 |
| 6 | Final rel.- ↓ | 0.574011 | 0.546836 |
| 6 | Final cosine ↑ | 0.823749 | 0.841404 |
| 8 | AUC ↓ | 0.256287 | 0.235652 |
| 8 | Final rel.- ↓ | 0.669091 | 0.630887 |
| 8 | Final cosine ↑ | 0.762938 | 0.792403 |
Reflection reduces mean trajectory AUC by 6.98% and 8.05% at and , respectively. All three prompt-averaged metrics improve for all 32 prompts at both settings. This does not imply uniform sample-wise improvement: final relative improves for 60/64 and 63/64 samples, respectively. All 52,736 checked trajectory values are finite and no rank fails. These are latent-trajectory measurements, not additional image-quality or latency scores, and they do not establish a universal stability or convergence guarantee.
A.3.2 Same-start local reflection analysis
To separate the effect of reflection from previously accumulated drift, we fork three branches from the exact same committed canonical Z-Cache left-anchor state : a local Full branch, the provisional TaylorSeer branch, and canonical reflected replay. The local Full branch evaluates the full network at every post-anchor step. It supplies neither features nor the future anchor to the cached branches and is a diagnostic reference, not an equal-compute baseline. The experiment uses the same 32 prompts and two seeds as Section A.3.1, with seven windows per sample at and five at , giving 768 matched windows.
We first average window metrics within each sample. For the endpoint-displacement intervals reported below, we use 95% percentile bootstrap intervals from 20,000 prompt-cluster resamples, retaining both seeds of each sampled prompt. Local AUC is the normalized trapezoidal relative- error from the common start through the window endpoint . Table 6 uses the conditional local Full trajectory as its reference; it must not be pooled with the global Full comparison.
Table 6: Same-start local trajectories relative to the conditional local Full reference.
| N | Metric | TaylorSeer | Z-Cache |
|---|---|---|---|
| 6 | AUC ↓ | 0.012688 | 0.008928 |
| 6 | Endpoint rel.- ↓ | 0.026057 | 0.016922 |
| 6 | Endpoint cosine ↑ | 0.999620 | 0.999828 |
| 8 | AUC ↓ | 0.020822 | 0.015519 |
| 8 | Endpoint rel.- ↓ | 0.045693 | 0.031364 |
| 8 | Endpoint cosine ↑ | 0.998882 | 0.999430 |
All three sample-aggregated local metrics favor reflection for 64/64 samples and 32/32 prompts at both intervals. The common starts match exactly and all 20,992 checked local relative-/cosine values are finite.
The replayed endpoint intentionally differs from the provisional endpoint. Its direct relative- displacement, normalized by the provisional TaylorSeer endpoint norm, is 0.014184 [0.013653, 0.014733] at and 0.023060 [0.022209, 0.023909] at (sample means and prompt-cluster 95% intervals). The corresponding window-level 95th percentiles are 0.025632 and 0.037227. Thus, endpoint changes are measurable; the same-start control shows that they move the tested local trajectories closer to conditional Full, without asserting that every possible trajectory or cache predictor behaves similarly.
A.3.3 Fusion rules and replay implementation
We evaluate four reflection functions on 200 paired DrawBench prompts with FLUX.1-dev, TaylorSeer , and the same frozen Base schedule. With Taylor order , distances , , and , the weights on the future-conditioned feature prediction are
The “variance-optimal” name refers to an independent-error model using squared Taylor-remainder scales; it does not use oracle errors.
Image-evaluation protocol. Tables 7–9 report SSIM computed on grayscale images; LPIPS and ImageReward use the same frozen evaluation configuration.
Table 7: Fusion-function ablation. Bold marks the best point estimate in each SSIM, LPIPS, and IR column; no confidence intervals or human-preference study establish quality significance.
| Fusion rule | SSIM↑ | LPIPS↓ | IR↑ |
|---|---|---|---|
| Original linear | 0.6462 | 0.3914 | 0.9908 |
| Remainder ratio | 0.6474 | 0.3888 | 0.9763 |
| Variance-optimal | 0.6476 | 0.3883 | 0.9863 |
| Jet smoothstep | 0.6471 | 0.3898 | 0.9821 |
All four rules use the same Base schedule, 747.501934 TFLOPs, and approximately 41.652 GiB peak allocated memory. Variance-optimal leads SSIM and LPIPS, whereas linear leads ImageReward. Linear remains a simple parameter-free default.
Table 8: Two replay backends under the same TaylorSeer schedule. Image quality uses DrawBench200; efficiency is a separate frozen-prompt A100 diagnostic.
| Backend | SSIM↑ | LPIPS↓ | IR↑ |
|---|---|---|---|
| Block-wise linear | 0.6462 | 0.3914 | 0.9908 |
| Root-residual state graft | 0.6505 | 0.3797 | 0.9916 |
| Backend | Latency (s)↓ | TFLOPs↓ | Peak GiB↓ |
|---|---|---|---|
| Block-wise linear | 6.7656 | 747.502 | 41.652 |
| Root-residual state graft | 5.4130 | 747.095 | 40.011 |
The graft reflects root residuals and bypasses the 57 Transformer blocks during replay instead of fusing 95 internal feature sites. Both backends retain 10 primary FULL steps, 40 primary PREDICT steps, seven closed windows, and zero extra endpoint FULL calls. Latency is the median of seven balanced rounds after one excluded warm-up on one A100 and frozen prompt 0, including hooks, denoising, and replay but excluding model loading, prompt encoding, latent preparation, and VAE decoding. Memory is maximum CUDA allocated memory; FLOPs are a separate exact-trajectory Transformer-forward profile. The graft reduces latency by 19.99% and peak memory by 3.94%, while changing the approximation rather than preserving identical outputs. This is not an H100 reproduction or evidence that overhead is eliminated for other Bases, intervals, or models.
A.3.4 Composition with recent cache predictors
We evaluate audited clean-room FLUX ports of SenCache and D2Cache on all 200 DrawBench prompts. Within each Base/+Z pair, prompts, seeds, initial latents, and the Base FULL schedule are identical. These controlled ports are additional composability evidence, not measurements of the authors' official implementations. Table 9 uses the image-evaluation protocol described in
Section A.3.3; bold indicates the better SSIM, LPIPS, or ImageReward point estimate within each matched pair.
Table 9: Matched recent-predictor results. FULL is the mean number of primary FULL evaluations across 200 samples. F-Speed is measured on one frozen prompt-0 trajectory; it is not a mean over 200 prompts or a latency speedup.
| Base | N | Arm | FULL | F-Speed ↑ | SSIM ↑ | LPIPS ↓ | IR ↑ |
|---|---|---|---|---|---|---|---|
| SenCache | 6 | Base | 10.000 | 4.996 | 0.6115 | 0.5126 | 0.7210 |
| 6 | +Z | 10.000 | 4.987 | 0.6149 | 0.4917 | 0.7985 | |
| SenCache | 7/8 | Base | 8.000 | 6.243 | 0.5943 | 0.5559 | 0.5486 |
| 7/8 | +Z | 8.000 | 6.230 | 0.5982 | 0.5289 | 0.6256 | |
| D2Cache | 6 | Base | 10.045 | 4.996 | 0.6488 | 0.4211 | 0.9536 |
| 6 | +Z | 10.045 | 4.987 | 0.6515 | 0.4158 | 0.9415 | |
| D2Cache | 7 | Base | 9.015 | 5.550 | 0.6346 | 0.4416 | 0.9411 |
| 7 | +Z | 9.015 | 5.539 | 0.6358 | 0.4390 | 0.9554 | |
| D2Cache | 8 | Base | 8.140 | 6.243 | 0.6146 | 0.4775 | 0.8706 |
| 8 | +Z | 8.140 | 6.229 | 0.6134 | 0.4778 | 0.9107 |
SenCache improves SSIM, LPIPS, and ImageReward at each distinct operating point. Its calibration target realizes eight FULL evaluations, yielding the same schedules and pixel-identical outputs as for each arm; we combine these rows rather than count them as independent replications. D2Cache is mixed: at , SSIM/LPIPS improve while ImageReward decreases; at , only ImageReward improves among these three metrics. No quality confidence intervals or human-preference evaluation support a significance or uniform-dominance claim.
F-Speed is the 50-step Full Transformer FLOPs divided by each arm's whole-trajectory Transformer FLOPs, including reflection forwards. The measured additional compute is 0.17–0.21% for these five distinct operating points. The separate A100 latency measurements are preliminary execution diagnostics and are omitted because they do not match the original H100 hardware and optimized timing protocol. Low additional Transformer FLOPs therefore do not imply universally low wall-clock or memory overhead.
A.4 Pseudocode and State Updates
Algorithm 1 specifies the TaylorSeer-based block-feature instantiation with linear fusion used in the trajectory experiments, with a deterministic step-indexed scheduler. Let be consecutive indices selected for FULL computation by the base schedule. The saved left boundary is . The notation , and follows the main text.
Let be the frozen predictor state at the left boundary and its feature prediction. evaluates the uncached network components and the scheduler using the supplied cache-site features. FullStep performs one full network evaluation and its scheduler update, returning the output latent and the observed feature bank. Both operators use the original timestep and step index ; replay does not advance a shared scheduler cursor.
Algorithm 1 Z-Cache: forecast, reflect, and commit one window
Require: Scheduled FULL indices ; saved latent ; frozen history ; predictor
Ensure: Committed latent and predictor state
1: {provisional trajectory}
2: for do
3:
4:
5: end for
6: {the scheduled right FULL}
7:
8: if then
9: return {no cached interior}
10: end if
11: {restore the left boundary}
12: for do
13:
14:
15: {cached replay, including step }
16: end for
17: {reconcile the closing cache}
18: return
Cache reconciliation. Update rebuilds the predictor state from the frozen past state and the supplied endpoint features; for TaylorSeer, it rebuilds the finite-difference coefficients at . At each cache site, let be the available coefficients and the maximum order. The update is
Both predictor states remain fixed during replay. With the linear weight and Taylor prediction, and . This bank was observed on the provisional input to step ; it is not a new FULL evaluation on the replayed input. The replayed output latent can therefore differ from .
Sampling-loop integration. Execute the initial FULL step before opening a window, then use each returned as the next left boundary. Warm-up FULL steps follow the base schedule. Every scheduled closing step is completed even if no later closed window remains. A cached tail with no scheduled right FULL follows the base predictor without reflection; no extra endpoint FULL is inserted. The procedure preserves the FULL schedule while adding cached replay and scheduler operations.
A.5 Impact Statement
This work improves the efficiency of diffusion-model inference via a training-free caching-and-reflection strategy (Z-Cache). By reducing the compute and latency required per generated sample, it can lower energy use and broaden access to high-quality generative models for research and practical applications. However, cheaper and faster generation may also enable misuse (e.g., large-scale misinformation, deceptive or non-consensual synthetic media, and spam) and can amplify existing concerns such as bias or copyright infringement. Z-Cache does not change the underlying model's training data or safety properties, so responsible deployment should rely on standard safeguards such as access controls, rate limiting, moderation/filtering, and provenance mechanisms where appropriate.