This repository contains Low-Rank Adaptation (LoRA) models for the WAN 2.5 image-to-video generation system in FP8 precision format. These LoRAs provide specialized enhancements for camera control, lighting adjustment, motion control, and quality improvement in generated videos from static images.
Model Description
WAN 2.5 Image-to-Video LoRAs are adapter models that enhance the base WAN 2.5 model for animating static images into dynamic videos. These LoRAs provide specialized capabilities:
Camera Control LoRAs: Precise control over camera movements, angles, and transitions in animated scenes
Motion Control LoRAs: Natural object and character motion within the scene
Lighting LoRAs: Enhanced lighting conditions, cinematic effects, and mood adjustment
Disk Space: 5 GB (for experimentation and caching)
GPU: NVIDIA RTX 4070 Ti / RTX 4080 or equivalent
Memory Usage by LoRA Count
1 LoRA: +200-400 MB VRAM
2 LoRAs: +400-800 MB VRAM
3+ LoRAs: +600-1200 MB VRAM
Usage Examples
Basic LoRA Loading with Diffusers
python
1from diffusers import DiffusionPipeline
2import torch
34# Load base WAN 2.5 model5pipe = DiffusionPipeline.from_pretrained(6"E:/huggingface/wan25-base",# Path to base WAN model7 torch_dtype=torch.float8_e4m3fn,8 variant="fp8"9)1011# Load camera control LoRA12pipe.load_lora_weights(13"E:/huggingface/wan25-fp8-loras/loras/wan/camera",14 weight_name="camera_pan.safetensors",15 adapter_name="camera_pan"16)1718# Set LoRA scale (0.0 to 1.0)19pipe.set_adapters(["camera_pan"], adapter_weights=[0.8])2021# Generate video with camera pan effect22prompt ="A sweeping pan across a mountain landscape at sunset"23video = pipe(24 prompt=prompt,25 num_frames=120,26 height=720,27 width=1280,28 guidance_scale=7.5,29 num_inference_steps=5030).frames[0]3132# Save video33import imageio
34imageio.mimsave("output_video.mp4", video, fps=24)
Multiple LoRA Combination
python
1# Load multiple LoRAs for combined effects2pipe.load_lora_weights(3"E:/huggingface/wan25-fp8-loras/loras/wan/camera",4 weight_name="camera_pan.safetensors",5 adapter_name="camera"6)78pipe.load_lora_weights(9"E:/huggingface/wan25-fp8-loras/loras/wan/lighting",10 weight_name="lighting_cinematic.safetensors",11 adapter_name="lighting"12)1314pipe.load_lora_weights(15"E:/huggingface/wan25-fp8-loras/loras/wan/quality",16 weight_name="quality_detail.safetensors",17 adapter_name="quality"18)1920# Set weights for each LoRA21pipe.set_adapters(22["camera","lighting","quality"],23 adapter_weights=[0.8,0.7,0.6]24)2526# Generate with combined effects27prompt ="Cinematic camera pan through a detailed futuristic cityscape"28video = pipe(prompt=prompt, num_frames=120).frames[0]
Purpose: Artistic style and aesthetic modifications
Types: Anime, realistic, painterly, sci-fi, fantasy
Weight Range: 0.6-1.0 (depends on desired style strength)
Technical Details
Training: Fine-tuned on specific video datasets
Compatibility: WAN 2.5 base model required
Inference: ~5-20% overhead per LoRA
Memory: ~100-200 MB per LoRA in FP8
Performance Tips and Optimization
LoRA Weight Tuning
Start Low: Begin with weights around 0.5 and adjust upward
Test Combinations: Some LoRAs may conflict at high weights
Per-Category Guidelines:
Camera: 0.7-1.0 for strong movements
Lighting: 0.5-0.8 for natural appearance
Quality: 0.4-0.7 for subtle enhancement
Style: 0.6-1.0 depending on desired intensity
Memory Optimization
python
1# Enable memory-efficient attention2pipe.enable_xformers_memory_efficient_attention()34# Use CPU offloading for limited VRAM5pipe.enable_model_cpu_offload()67# Reduce batch size for multiple LoRAs8pipe.enable_sequential_cpu_offload()
Inference Speed
Single LoRA: ~5-10% slowdown vs base model
2-3 LoRAs: ~10-20% slowdown
4+ LoRAs: ~20-30% slowdown
Tip: Merge compatible LoRAs offline for faster inference