Papers › T-Stitch: Accelerating Sampling in Pre-Trained Diffusion Models with Trajectory Stitching

T-Stitch: Accelerating Sampling in Pre-Trained Diffusion Models with Trajectory Stitching

21 Feb 2024arXiv:2402.14167archive 2025-07-28

Zizheng Pan, Bohan Zhuang, De-An Huang, Weili Nie, Zhiding Yu, Chaowei Xiao, Jianfei Cai, Anima Anandkumar

Sampling from diffusion probabilistic models (DPMs) is often expensive for high-quality image generation and typically requires many steps with a large model. In this paper, we introduce sampling Trajectory Stitching T-Stitch, a simple yet efficient technique to improve the sampling efficiency with little or no generation degradation. Instead of solely using a large DPM for the entire sampling trajectory, T-Stitch first leverages a smaller DPM in the initial steps as a cheap drop-in replacement of the larger DPM and switches to the larger DPM at a later stage. Our key insight is that different diffusion models learn similar encodings under the same training data distribution and smaller models are capable of generating good global structures in the early steps. Extensive experiments demonstrate that T-Stitch is training-free, generally applicable for different architectures, and complements most existing fast sampling techniques with flexible speed and quality trade-offs. On DiT-XL, for example, 40% of the early timesteps can be safely replaced with a 10x faster DiT-S without performance drop on class-conditional ImageNet generation. We further show that our method can also be used as a drop-in technique to not only accelerate the popular pretrained stable diffusion (SD) models but also improve the prompt alignment of stylized SD models from the public model zoo. Code is released at https://github.com/NVlabs/T-Stitch

PaperPDFCodeCode Syntology ran

In Syntology Open this paper in Syntology's Atlas, the map of the papers in Syntology's graph and their citations.

For agents, Syntology's MCP tool lists every function and class Syntology harvested from this paper and whether it ran (how to connect): get_harvested_code_for_paper(arxiv_id="2402.14167")

Code

Syntology Ran 5 of 8 code samples harvested from 1 repository linked to this paper; 3 have no recorded run. Of those that ran: 1 ran · honoured contract; 4 ran · our draft was wrong.

By repository: official repository: 8 samples from 1 repository, 5 ran. The run record, sample by sample. “Ran” means executed on a synthesized input, not that the code is correct or reproduces the paper.

nvlabs/t-stitch officialmentioned in papermentioned on GitHubpytorchNOASSERTION report

Repository list and official/mentioned flags are the archive's, frozen 2025-07-28. Reachability, where shown, is from one Syntology probe window (2026-09-16 to 2026-09-18); repositories not probed show nothing. GitHub stars are not tracked.

Code Syntology ran Syntology

8 samples harvested; 5 ran; 1 honoured the contract we drafted; 3 have no recorded run. Read from Syntology's graph 2026-09-24; that is when this build read the record, not when the samples ran.

1ran · honoured contract
4ran · our draft was wrong
3unverified

Licence: 8 of the 8 samples are pointer only, meaning Syntology does not serve that copy's text. This page shows no code text for any sample; each one links to its file in the repository.

Harvested from nvlabs/t-stitch. “Ran” means the sample executed on a synthesized input. It does not mean the output is correct, and nothing here reproduces the paper's results. “Honoured” and “violated” refer to a contract Syntology drafted from the code itself; “our draft was wrong” and “fixture could not drive it” are failures of Syntology's instrument, not of the code.

Each sample ends with its code_sha256, Syntology's identity for that exact code. An agent fetches the stored sample with Syntology's MCP tool get_code(code_sha256="…") (how to connect); click an identity to copy that call.

Repository labels, per sample. official repository: The archive marks this repository official for the paper. named in the paper: The archive records that the paper mentions this repository; it is not marked official. community (archive-listed): In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper. found in paper text by Syntology: Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted. community: Not in the archive's code links for this paper; a community repository Syntology harvested. Samples from a repository marked official are listed first. Licence labels name the repository's licence as recorded at harvest. “Pointer only” means Syntology does not serve that copy's text, for one of four reasons: no licence file was found; the licence was not identified; the licence is recorded as permissive but that copy's record is not marked cleared; or the licence is outside the permissive list Syntology serves text under (MIT, Apache-2.0, BSD and similar). Some licences outside that list permit redistribution, such as WTFPL, and GPL-3.0 under its conditions; they are simply not on the list. Hover a licence label for the reason. File links open the file on GitHub at the default branch, which may have changed since the harvest.

Normalize nvlabs/t-stitch/dit/autoencoder.py official repository ran · our draft was wrong no licence file found · pointer only · 9fcdaa6e423e8aa7 · report
create_npz_from_sample_folder nvlabs/t-stitch/dit/sample_ddp_t_stitch.py official repository ran · our draft was wrong no licence file found · pointer only · 7b21a01ae77703a3 · report
get_2d_sincos_pos_embed nvlabs/t-stitch/dit/models.py official repository ran · honoured contract no licence file found · pointer only · c92c27c924b517e8 · report
modulate nvlabs/t-stitch/dit/models.py official repository ran · our draft was wrong fingerprinted no licence file found · pointer only · 03310bba324ae4fb · report
nonlinearity nvlabs/t-stitch/dit/autoencoder.py official repository ran · our draft was wrong fingerprinted no licence file found · pointer only · 3137073275f8c21a · report
get_2d_sincos_pos_embed_from_grid nvlabs/t-stitch/dit/models.py official repository unverified no licence file found · pointer only · 665d8a4e8f673a4c · report
get_depth_map nvlabs/t-stitch/sdxl_depth.py official repository unverified licence not identified · pointer only · 8a667eab2fac37fa · report
make_attn nvlabs/t-stitch/dit/autoencoder.py official repository unverified no licence file found · pointer only · f97adc1ae5efb785 · report

Tasks

Image Generation

Results from the paper archive 2025-07-28

No leaderboard rows for this paper in the archive.

Methods

DiffusionSPEED

Report a problem or propose a change · a person checks every report against the paper or source before anything changes; decisions are listed on /corrections