NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

D-Feat Occlusions: Diffusion Features for Robustness to Partial Visual Occlusions in Object Recognition

Rupayan Mallick, Sibo Dong, Nataniel Ruiz, Sarah Adel Bargal · DOI

Introduction

Deep learning models for object recognition often exhibit significant brittleness when faced with partial occlusions. While a human observer can easily identify a dog partially hidden behind a fence by leveraging a mental model of the animal's holistic structure, standard classifiers typically rely on local, highly discriminative features. If these specific features—such as a dog's ears or snout—are obscured, the model's performance tends to collapse.

Traditional data augmentation techniques like CutMix or random erasing attempt to mitigate this by forcing models to be less reliant on specific pixel groups. However, these methods act primarily as regularization; they do not teach the model to reason about what is missing. This paper introduces D-Feat, a framework that utilizes the generative priors of pre-trained diffusion models to "fill in the blanks," enabling more robust object recognition through structural understanding.

Methodology: Leveraging Generative Priors

The core innovation of D-Feat lies in using a frozen Stable Diffusion (SD) model as a source of structural knowledge. The authors propose two distinct strategies to integrate these generative capabilities into the classification pipeline.

The D-Feat framework: (a) Input-based augmentation via SD Inpainting and (b) Feature-based augmentation via SD Feature extraction.

1. Input-Based Augmentation (SD Inpaint)

As shown in Figure 1(a), this method identifies occluded regions using part-segmentation masks. An SD inpainting pipeline then "hallucinates" the missing pixels based on the target object's class label. This process transforms a fragmented image into a visually coherent whole, which is then used to fine-tune standard classifiers like ConvNeXt or Swin Transformer. By training on these "restored" images, the classifier learns to associate the hallucinated structures with the correct class.

2. Feature-Based Augmentation (SD Features)

Alternatively, Figure 1(b) illustrates a more direct approach. Instead of generating new pixels, the framework extracts intermediate features from the Stable Diffusion U-Net using a "null prompt." These features inherently encode rich spatial context and object geometry. By fusing these generative features with the standard features of the classification model, the system provides the classifier with a "structural hint" about the hidden parts of the object without the overhead of full image generation.

Datasets and Evaluation

To rigorously test these methods, the authors utilized three primary datasets, moving from controlled simulations to real-world complexity.

  • PartImageNet: Provides pixel-level part segmentations, allowing for precise simulation of occlusions on specific functional parts of objects during training.
  • ImageNet1K Validation: Used for large-scale evaluation with synthetic occlusions created by randomly blacking out 16x16 patches at varying levels of information loss (20% to 80%).
  • D-feat (New): A newly curated benchmark specifically designed to test real-world occlusions. It contains 300 images across 100 classes where objects are naturally obscured by their environment (e.g., foliage, other objects).
Comparison between synthetic patch-based occlusions used in ImageNet validation and the natural, complex occlusions found in the new D-feat dataset.

Key Results and Insights

The D-Feat approach demonstrates that generative models can serve as powerful structural priors for discriminative tasks.

Performance Under Extreme Occlusion

On the ImageNet benchmark with 80% of the image obscured, the "SD Features" approach maintained a 78.14% top-1 accuracy (using a Swin Transformer), significantly outperforming the baseline model's 71.87%. This suggests that the generative features provide critical information that standard discriminative features lose under heavy occlusion.

Real-World Robustness

The most striking gains were observed on the D-feat dataset. The "SD Features" method boosted ConvNeXt accuracy from 82.03% to 90.06%. This 8% improvement on non-synthetic, real-world data highlights the practical utility of the framework.

Efficiency and Architecture Agnosticism

The authors found that feature-based augmentation was generally more efficient than full image inpainting while providing comparable or superior robustness. Furthermore, the benefits were consistent across both Convolutional Neural Networks (ConvNeXt) and Vision Transformers (Swin), indicating that the bottleneck in occlusion robustness lies in the data representation rather than the specific neural architecture.

Conclusion and Future Directions

D-Feat shifts the paradigm of occlusion handling from simple noise regularization to constructive hallucination. By tapping into the deep geometric understanding of diffusion models, classifiers can "see" through obstacles.

However, challenges remain. The computational cost of running a diffusion U-Net alongside a classifier is non-trivial, suggesting a need for future research into distilling these generative features into more lightweight architectures. Additionally, the system's performance is inherently tied to the quality and potential biases of the underlying generative model. Future work will likely focus on quantifying real-world occlusion levels more precisely and exploring the limits of generative "hallucination" in increasingly complex visual environments.

Summary updated

BibTeX
@inproceedings{mallick2025d,
  author = {Rupayan Mallick and Sibo Dong and Nataniel Ruiz and Sarah Adel Bargal},
  title = {{D-Feat Occlusions: Diffusion Features for Robustness to Partial Visual Occlusions in Object Recognition}},
  booktitle = {Workshops @ CVPR},
  year = {2025},
}
Figure