Wan2.2-Fun-5B-InP — Turbo 4-step, int4, MLX
First-and-last-frame video with alibaba-pai/Wan2.2-Fun-5B-InP (a Wan2.2-TI2V-5B fine-tune trained for start/end-frame inpainting) on Apple Silicon.
- 4 steps, no CFG: the Wan2.2-TI2V-5B Turbo LoRA (rank 64) is merged in, including its bias/norm deltas.
- int4 (group 64) transformer: 2.9 GB. Wan2.2 VAE included; int8 umT5 text encoder is fetched from bahae98/umt5-xxl-enc-int8-mlx.
- ~14× faster than the 14B FLF2V model; weaker on large motions (faces can smear mid-clip). For best quality use bahae98/Wan2.1-FLF2V-14B-4step-int5-SVD-mlx.
Quick start
pip install -r requirements.txt
hf download bahae98/Wan2.2-Fun-5B-InP-Turbo-int4-mlx --local-dir Wan-Fun-5B-mlx
cd Wan-Fun-5B-mlx
python generate_flf2v.py --model-dir . --image start.png --last-image end.png \
--prompt "Smooth cinematic dolly-in to the cat's face." \
--width 832 --height 480 --num-frames 49 --seed 7 --output-path out.mp4
Steps (4), shift (5) and CFG (off) come from config.json ("fun_inp": true selects the
Fun-InP conditioning path: the whole masked pixel video is VAE-encoded, as in VideoX-Fun).
Performance (M1 Pro, 32 GB)
832×480, 49 frames: VAE encode ~76 s, denoise 148 s (4 steps), MLX peak 5.5 GB.
Files
config.json model config (fun_inp, 4 steps, CFG 1, int4)
model.safetensors int4 transformer, Turbo LoRA merged
vae.safetensors Wan2.2 VAE
generate_flf2v.py inference (mlx-video pipeline + FLF / Fun-InP paths, T5 prompt cache)
vae_stream.py low-memory causal Wan2.2 VAE decode
build_fun_inp.py how the weights were made (streams the bf16 source from the Hub)
build_model.py LoRA key mapping used by the build
License — read this
The base model (Wan2.2-Fun-5B-InP) is Apache-2.0, but the merged Turbo LoRA comes from quanhaol/Wan2.2-TI2V-5B-Turbo, which does not state a license. Redistribution rights for this merged checkpoint are therefore unclear; keep this repo private until that is resolved.