Organizations: Shenzhen Key Laboratory of Internet Information Collaboration, Harbin Institute of Technology, Shenzhen · Pengcheng Laboratory, Shenzhen
Speculative Jacobi Decoding (SJD) is an important approach for accelerating autoregressive image generation. Although SJD has shown superior performance, recent studies point out that it usually suffers from a token ambiguity issue during token verification but its reason can not be well explained. To figure out this reason, in this paper, we conduct a visualization analysis on vision token and find that different from text tokens, vision tokens generally corresponds to some local, small, and unclear vision details, which means only using single token is difficult to accurately express a certain semantic, thereby causing token ambiguity issue. To this end, we propose a novel Speculative Jacobi Decoding with Semantics Verification (called SJD-SV), for accelerating autoregressive image generation. The key idea is that leveraging the strong correction characters between tokens to recognize semantic-aware token subsequence and then instead of perform token-by-token verification, turning to perform verification on semantic-aware token subsequence level for accelerating image generation. In particular, our method is plug-in, which can be directly integrated into existing SJD and its variants. Extensive experiments on various datasets show that existing SJD methods achieve significant performance improvement after integrating our SJD-SV method.
Figures & tables
Figure 1: (a) Existing image AR models represents an image as a fine-grained token sequence, such that individual tokens is difficult to accurately and clearly express a certain semantic, thereby introducing token ambiguity; (b) Instead of performing token-by-token verification as existing SJD methods, we turn to perform verification on semantic-aware token subsequence level. Its advantage is that token subsequences can encode more stable semantic information, effectively reducing false rejections during verification.
Figure 2: Analysis of semantic verification on token subsequence.
Configuration
Latency (↓)
NFE (↓)
Acceleration (↑)
FID (↓)
CLIP-Score (↑)
Latency
NFE
Parti-prompt
Lumina-mGPT ( Liu et al., 2024a )
79.37s
2392
1.00 ×
1.00 ×
–
32.09
Jacobi Decoding ( Song et al., 2021 )
82.21s
2300.0
0.97 ×
1.04 ×
–
32.09
SJD ( Teng et al., 2024a )
36.07s
1035.3
2.20 ×
2.31 ×
–
32.09
SJD-SV
30.48s
826.32
2.60 ×
2.89 ×
–
32.13
Table 1: Results of quantitative evaluation on the Parti-prompt and MS-COCO 2017 benchmarks. The best results are highlighted in bold.
Figure 3: Qualitative experiment. Our method shows on average 1.25× NFE acceleration while maintaining image quality.
Method
Accept (All)
Accept (Amb.)
Accept (Clear)
SJD
60.53%
56.49%
61.67%
SJD-SV
64.16 %
62.03 %
65.83 %
Table 2: Ablation study on the token ambiguity issue.
Fallback
Latency
NFE
CLIP
w/o
35.78s
972.92
32.11
w/ (Ours)
30.48s
826.32
32.13
Table 3: Analysis of our fallback mechanism on Parti-prompt.
Strategy
Latency
NFE
CLIP
Fixed-1
26.29s
710.83
31.04
Fixed-2
28.84s
760.92
31.76
Fixed-3
30.53s
822.11
32.09
Fixed-4
32.74s
867.37
32.11
All
33.25s
877.29
32.08
Adaptive (Ours)
30.48s
826.32
32.13
Table 4: Adaptive vs. fixed-length joint probability estimation.
α
NFE
Latency
CLIP
1.0
877.29
33.25s
32.08
0.9
843.53
31.44s
32.11
0.8
826.32
30.48s
32.13
0.7
790.84
29.13s
32.06
0.6
748.26
27.38
32.01
0.5
670.80
24.68
31.88
Table 5: Ablation study of hyperparameter α on Parti-prompt.
SJD-SV
GSD-SV
LANTERN-SV
Time overhead
2.05ms
5.54ms
0.81ms
Table 6: Computational overhead analysis on Parti-prompt.
Configuration
Latency
NFE
Acceleration ( ↑ )
FID
CLIP-Score
( ↓ )
( ↓ )
Latency
NFE
( ↓ )
( ↑ )
Parti-prompt
Emu3 ( Wang et al., 2024 )
780.98s
8193.0
1.00 ×
1.00 ×
–
32.13
Emu3(+SJD)
345.65s
3571.0
2.26 ×
2.29 ×
–
32.14
Emu3(+Ours)
180.30s
2786.1
4.33 ×
2.94 ×
–
32.16
LLamagen ( Sun et al., 2024a )
30.58s
927.5
1.00 ×
1.00 ×
–
28.14
Table 7: Results of other baselines on the Parti-prompt benchmark. The best results are highlighted in bold.