TL;DR
AniDoc is a novel video line art colorization framework that automates the coloring and in-betweening stages of 2D animation using a video diffusion model. By leveraging explicit semantic correspondence matching and robust binarization training, it accurately transfers colors from a single character design sheet to complex sketch sequences, even when given sparse inputs.
What Problem Does This Paper Address?
The traditional 2D animation production pipeline is notoriously labor-intensive. It moves sequentially from character design to keyframe sketching, in-betweening (drawing the transitional frames), and manual coloring.
While generative AI has made strides in image colorization, automating line art colorization for video faces three major roadblocks:
- Pose and Scale Mismatch: Reference character design sheets rarely align perfectly with the dynamic poses, angles, and scales found in actual animation sketches.
- Color Information Leakage: Many existing models are trained on synthetic sketches extracted from color images via neural networks. These sketches secretly retain invisible color residuals. When faced with real-world, completely binarized (pure black and white) sketches, these models suffer severe performance degradation.
- Dense Input Requirements: Most current tools require a complete sequence of sketches, meaning animators still have to manually draw every single intermediate frame.
Methods
AniDoc builds upon Stable Video Diffusion (SVD) and introduces a dual-branch 3D U-Net architecture to handle colorization and frame interpolation simultaneously.
Its core innovations include:
- Correspondence-Guided Colorization: To bridge the structural gap between the reference sheet and the sketch, the model explicitly maps keypoints. During training, it uses LightGlue and SIFT to find matching pairs, which are tracked across frames using Co-Tracker to build explicit point maps. Because low-level features fail during inference due to the massive domain gap between a colored image and a raw sketch, AniDoc switches to a semantic-level matcher (X-Pose + DIFT) at inference time.
- Binarization and Background Augmentation: To prevent the model from "cheating" via color leakage, the authors strictly binarize training sketches into pure black and white. To help the model distinguish between a white background and large white foreground regions (like a character's shirt), they randomly remove the background of the reference images with a 50% probability during training.
- Sparse Sketch Training: A two-stage training strategy enables automatic in-betweening. After mastering dense colorization, intermediate sketches are removed during the second stage. Keypoint trajectories are transformed into Gaussian heatmaps to guide the model to interpolate and colorize intermediate frames using only the start and end sketches.
Datasets
The model was trained and evaluated using the Sakuga-42M dataset, a large-scale collection of diverse anime clips. To ensure the model learned to handle significant character transformations, the authors filtered out short clips, ultimately retaining approximately 150,000 high-quality video clips containing rich variations in posture, scale, and camera angles.
Key Insights and Ideas
- The Synthetic Sketch Trap: The paper exposes a critical methodology flaw in prior line art colorization research. Models trained on non-binarized sketches fail in production because they rely on imperceptible color data left behind by edge-detection algorithms rather than actually understanding the reference image.
- Unified Motion and Color Control: Instead of treating interpolation (in-betweening) and colorization as separate steps, AniDoc demonstrates that sparse keypoint trajectories can serve as a unified control signal for both spatial color placement and temporal motion generation.
- Semantic vs. Pixel Matching: Traditional pixel-level feature matching fails across the sketch-to-color domain. By utilizing features extracted from pretrained diffusion models (DIFT), the system matches components based on semantic meaning (e.g., identifying an eye or a jacket) rather than raw texture.
Key Results
AniDoc significantly outperforms state-of-the-art baselines (including LVCD, ToonCrafter, and ID-Animator) both qualitatively and quantitatively.
- Quantitative Metrics: AniDoc achieves a PSNR of 19.23, substantially higher than the best-performing baseline (LVCD + IP-Adapter at 16.52). It also drastically reduces the Frechet Video Distance (FVD to 230.18 from the baseline's best of 492.10), demonstrating superior temporal consistency and image quality.
- Ablation Validation: Ablation experiments confirm that without the correspondence matching module, the model struggles to localize details, often miscoloring clothing with hair colors or losing identity consistency.
Limitations and Future Work
- Unseen Objects: If an animation sketch introduces an object or secondary character not present in the reference design sheet (such as a prop or a background element), the model struggles to color it accurately, often defaulting to the dominant colors of the reference character.
- Outfit Variations: If a character's clothing changes drastically from the reference sheet, the model can only infer reasonable color patterns based on the reference, which cannot guarantee absolute accuracy.
- Future Directions: The authors aim to incorporate interactive point control to allow artists to manually guide subtle color variations and plan to scale the architecture to support longer, higher-resolution animation sequences.
Summary updated