Infusing Synthetic Data with Real-World Patterns for Zero-Shot Material State Segmentation

Sagi Eppel, Jolina Li, Manuel S. Drehwald, Alán Aspuru-Guzik

Introduction

Researchers have developed a novel "Pattern Infusion" method that extracts complex, messy textures from real-world images and infuses them into synthetic 3D scenes. By training on this real-world-inspired synthetic data, their resulting model—MatSeg—significantly outperforms top foundation models like Segment Anything (SAM) in identifying material states. This includes distinguishing between wet and dry soil, or cooked and burnt food, especially in cases with fuzzy boundaries and scattered patterns.

The Challenge of Material States

While computer vision has become excellent at identifying discrete objects (e.g., "this is a leaf"), it still struggles with material states (e.g., "this leaf is infected" or "this part of the leaf is wet"). Segmenting these states is notoriously difficult for two main reasons:

  1. Annotation Complexity: Material states often have fuzzy boundaries or appear as scattered, sparse patterns like rust or stains. Manually drawing precise polygons around these regions is expensive, time-consuming, and highly subjective.
  2. The Reality Gap: Synthetic data is easy to generate with perfect labels, but it usually looks too clean or follows rigid procedural rules. Real-world material states are chaotic and diverse—a complexity that standard synthetic datasets fail to capture.

Methods: The Pattern Infusion Pipeline

To bridge the gap between synthetic precision and real-world messiness, the authors introduce an unsupervised approach called Pattern Infusion.

Overview of the Pattern Infusion pipeline, including 3D scene mapping, 2D scene mapping, and material extraction.
  • Unsupervised Map Extraction: Instead of relying on manual labeling, the system takes a random real-world image and isolates a single channel (like Saturation, Hue, or the Red channel). It applies a random "ramp threshold" to create a soft binary map. These maps capture the natural, organic shapes found in the wild, such as shadows, highlights, and complex textures.
  • Infusion into Synthetic Scenes: These extracted maps are then used as blending weights or UV maps in a 3D engine (Blender). For example, a pattern extracted from a shadow in a real photo might dictate where rust is placed on a synthetic 3D pipe.
  • Material Extraction: The authors also developed a method to automatically find uniform texture regions in real images, creating 300,000 new PBR (Physically Based Rendering) materials to serve as a massive library for data generation.
  • The Model: They trained a U-Net-style encoder to produce 128-dimensional vector embeddings for every pixel. Using a cosine similarity loss, the model learns to group pixels with similar material properties together.

Datasets and Evaluation

To properly evaluate the model, the team introduced the MatSeg Benchmark, a first-of-its-kind dataset containing 1,220 real-world images across domains like food, construction, plants, and liquids.

Examples from the MatSeg benchmark showing point-based annotations and the model's similarity predictions.

To avoid the fuzzy boundary problem during evaluation, they utilized point-based annotation. Annotators marked points that are identical or partially similar, and the model was evaluated on its ability to predict these relationships. The model was also tested on 12 existing domain-specific datasets, including those for copper ore microscopy, leaf diseases, and road dust.

Key Insights and Results

  • Noise is a Feature, Not a Bug: The unsupervised extraction process is inherently noisy—sometimes extracting a shadow instead of a material. However, neural networks are highly effective at learning from this noisy data. This diversity prevents the model from overfitting to the clean rules of standard simulators.
  • Foundation Models Have a "Material Gap": Models like SAM are trained primarily on object boundaries. When asked to segment a material state (like a wet spot on a shirt), SAM often tries to segment the whole shirt or the person wearing it, failing to isolate the material state itself.
  • State-of-the-Art Performance: On the MatSeg Benchmark, the MatSeg model achieved a triplet accuracy of 0.92, significantly higher than SAM (0.74) and Materialistic (0.76). Notably, SAM failed to reach high accuracy even when given 8 guiding points, whereas MatSeg succeeded with just 1.
  • Zero-Shot Generalization: Despite being trained entirely on synthetic data, the model outperformed specialized models on 10 out of 12 external real-world datasets. It handles a vast array of states—cooked, burned, wet, dry, infected, rusted—without ever having seen a labeled example of those specific classes during training.

Limitations and Future Work

Because the patterns are extracted from general datasets (like Open Images), the model is less familiar with specialized domains, showing lower accuracy on tissue and mineral microscopy benchmarks compared to macro-world images. Additionally, the unsupervised method naturally extracts common textures (like grass or water) more frequently than rare ones, leading to a texture bias.

Future work could involve more targeted pattern extraction for specific industries (e.g., medical or industrial) and improving the 3D rendering pipeline to include even more complex physical interactions. The authors have made their dataset, code, and 300,000 extracted textures publicly available to encourage further research in this material-centric view of computer vision.

Summary updated

BibTeX
@inproceedings{eppel2024infusing,
  author = {Sagi Eppel and Jolina Li and Manuel S. Drehwald and Alán Aspuru-Guzik},
  title = {{Infusing Synthetic Data with Real-World Patterns for Zero-Shot Material State Segmentation}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2024},
}
Figure