Abstract
We describe a method to extract persistent elements of a dynamic scene from an input video. We represent each scene element as a Deformable Sprite consisting of three components: 1) a 2D texture image for the entire video, 2) per-frame masks for the element, and 3) non-rigid deformations that map the texture image into each video frame. The resulting decomposition allows for applications such as consistent video editing. Deformable Sprites are a type of video auto-encoder model that is optimized on individual videos, and does not require training on a large dataset, nor does it rely on pre-trained models. Moreover, our method does not require object masks or other user input, and discovers moving objects of a wider variety than previous work. We evaluate our approach on standard video datasets and show qualitative results on a diverse array of Internet videos.
Introduction
Most computer vision models treat video as a 3D grid of pixels. While computationally convenient, this representation fails to capture how humans naturally perceive scenes: as a collection of distinct, persistent objects moving through space. Existing "layered" video representations often struggle with two primary challenges: supervision and rigidity. Many current methods require pre-trained object detectors or manual masks to identify what to track. Furthermore, older unsupervised methods typically assume objects are rigid (like a sliding box), failing when an object deforms, such as a bear walking or a flower swaying in the wind.
To address these limitations, we introduce the Deformable Sprite framework. This model automatically discovers video layers and handles non-rigid, "squishy" deformations using only the information present in a single input video, without any human supervision or pre-training.
Methodology
The core of our approach is the Deformable Sprite representation. For a given video, the model learns a set of $L$ layers. Each layer consists of three key components:
- A Canonical Sprite ($A$): A single, high-resolution RGB texture image representing the "true" appearance of the object or background across the entire video.
- Per-frame Masks ($M_t$): Soft masks that determine which pixels in a specific frame belong to which layer.
- Spatio-Temporal Splines ($T_t$): This is the critical innovation. Instead of simple shifts, the model uses a combination of a homography (for global camera or rigid motion) and a 2D B-spline (for local, non-rigid warping). These transformations are smoothed over time using a 1D temporal spline.
The Training Process
The model functions as an auto-encoder optimized for each video independently. It does not require a massive dataset; it simply attempts to reconstruct the specific video it is given. The optimization is driven by three main loss functions:
- Reconstruction Loss ($\mathcal{L}_{recon}$): Ensures the combined layers accurately recreate the original frames.
- Motion Grouping Loss ($\mathcal{L}_{group}$): Utilizes optical flow to encourage pixels that move together to be assigned to the same layer.
- Flow Consistency Loss ($\mathcal{L}_{warp}$): Ensures that if a point moves in the video, it maps back to the same pixel on the canonical sprite texture.
Experimental Results
We evaluated our method on several standard video object segmentation (VOS) benchmarks, including DAVIS 2016, FBMS (Freiburg-Berkeley Motion Segmentation), and SegTrackV2. To demonstrate flexibility, we also tested on "in-the-wild" Internet videos featuring non-standard subjects like rotating Earth footage, moving clouds, and bees on flowers.
Key Insights
- Texture as an Anchor: By forcing the model to use a single "sprite" image for the whole video, the model is naturally incentivized to find long-term correspondences. If an object moves, the model must find a way to warp the sprite's texture to match, or the reconstruction loss will increase.
- Spline Efficiency: Modeling motion with splines using a grid of control points is significantly more parameter-efficient than predicting a unique flow field for every pixel. This inherent smoothness acts as a powerful regularizer.
- Beyond Semantic Categories: Because the model is unsupervised and motion-driven, it can segment elements that are not "objects" in the traditional sense, such as specific cloud patches or reflections, which standard pre-trained detectors (like Mask R-CNN) would ignore.
Performance and Applications
On the DAVIS benchmark, our method achieved a 79.1 J (Intersection over Union) score, the second-best among unsupervised methods, outperforming several models pre-trained on large datasets. Ablation studies confirmed that adding Spatio-Temporal Splines significantly improved results over rigid-only models (79.1 vs 71.5).
One of the most compelling applications is consistent video editing. Because the model maps every frame back to a single sprite, a user can "paint" on the sprite (e.g., adding a logo to a walking bear), and the edit will automatically and correctly propagate through the entire video, following the subject's muscle movements and gait.
Discussion and Limitations
While Deformable Sprites offer a powerful new representation, some challenges remain. The model currently assumes a fixed texture; if an object moves from bright sunlight into deep shadow, the model may struggle as it cannot easily adjust the sprite's brightness. Additionally, the model does not always automatically determine the correct depth ordering of layers. Finally, as the sprites are 2D textures, they do not capture true 3D geometry; a single 2D sprite cannot perfectly represent an object that rotates 180 degrees to show its back. Future work will explore extending this framework to true 3D decompositions to better handle complex rotations and occlusions.
Summary updated