However, it is hard to decide when to reuse the cache to ensure quality generated images or videos. ParaAttention directly uses the **residual difference of the first transformer block output** to approximate the difference among model outputs. When the difference is small enough, the residual difference of previous inference steps is reused. In other words, the denoising step is skipped.  
This achieves a 2x speedup on FLUX.1-dev and HunyuanVideo inference with very good quality.  
<figure>