Abstract
Our brain can effortlessly recognize objects even when partially hidden from view. Seeing the visible of the hidden is called amodal completion; however, this task remains a challenge for generative AI despite rapid progress. We propose to sidestep many of the difficulties of existing approaches, which typically involve a two-step process of predicting amodal masks and then generating pixels. Our method involves thinking outside the box, literally! We go outside the object bounding box to use its context to guide a pre-trained diffusion inpainting model, and then progressively grow the occluded object and trim the extra background. We overcome two technical challenges: 1) how to be free of unwanted co-occurrence bias, which tends to regenerate similar occluders, and 2) how to judge if an amodal completion has succeeded. Our amodal completion method exhibits improved photorealistic completion results compared to existing approaches in numerous successful completion cases. And the best part? It doesn't require any special training or fine-tuning of models.
Introduction: The Challenge of Amodal Completion
Humans possess a remarkable ability to perceive the full shape of an object even when it is partially obscured. This cognitive process, known as amodal completion, allows us to understand our environment despite frequent occlusions. In computer vision, replicating this ability is an "ill-posed" problem because a single visible fragment could belong to many different complete shapes.
Traditional AI approaches often struggle with natural scenes, frequently failing due to co-occurrence bias. For instance, standard inpainting models trained on images of people holding coffee cups might struggle to remove the hand without regenerating another hand, as the model "expects" a hand to be near the cup. Furthermore, existing methods often require expensive, human-labeled datasets that are difficult to scale.
Methodology: Thinking Outside the Box
The proposed method leverages the power of pre-trained diffusion models without requiring additional training or fine-tuning. The core philosophy is to "think outside the box" by extending the generation process beyond the object's immediate bounding box to utilize broader environmental context.
The pipeline consists of three innovative stages:
- Progressive Occlusion-aware Completion: The system iteratively identifies occluders using off-the-shelf segmentation and depth models. It then inpaints these regions, checks for remaining occlusions, and repeats the process until the object is perceived as complete.
- Mixed Context (MC) Diffusion Sampling: To mitigate co-occurrence bias, the model temporarily detaches the object from its original environment. During diffusion, the background is replaced with a neutral, "product-style" backdrop. The model then extracts a "pseudo-complete" mask from the UNet’s internal features (specifically the 3rd decoder layer) and integrates it back into the original scene for final refinement.
- Counterfactual Completion Curation: In the absence of ground-truth data for hidden parts, the authors developed a training-free "judge." This system attempts to "outpaint" the generated object; if the mask expands significantly, it indicates the object was still incomplete, allowing for automated quality control.
Experimental Setup and Datasets
To evaluate the method, the researchers established a benchmark of 3,000 pseudo-occluded objects. By taking complete objects from the COCO and Open Images datasets and artificially overlaying them with occluders, they created "easy" (20-50% occlusion) and "hard" (50-80% occlusion) test cases. This synthetic approach provided a reliable ground truth for quantitative comparison.
Results and Key Insights
The Progressive Mixed Context Diffusion method significantly outperformed existing GAN-based and inpainting-based baselines.
- Quantitative Performance: The method achieved superior scores across CLIP (high-level), DreamSim (mid-level), and LPIPS (low-level) similarity metrics.
- User Preference: A study with Amazon Mechanical Turk workers revealed a staggering 90.9% preference for this method's results over traditional baselines.
- Ablation Study: The "Mixed Context" sampling proved vital, increasing the success rate on difficult co-occurrence cases by 18%.
A key discovery was that the internal features of a pre-trained diffusion model (at specific timesteps) contain rich geometric information. By using unsupervised clustering on these features, the model can generate accurate amodal masks dynamically.
Limitations and Future Outlook
Despite its success, the method faces challenges such as "over-extension," where small objects might grow into unrealistic shapes if hidden by large occluders. Additionally, residual shadows from the original occluder can sometimes lead the model to regenerate the hidden object. Future work may involve using the high-quality data generated by this pipeline to train more robust supervised models for amodal completion and curation.
Summary updated