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

ID-Sim: An Identity-Focused Similarity Metric

Julia Chae, Nicholas Kolkin, Jui-Hsien Wang, Richard Zhang, Sara Beery, Cusuh Ham

TL;DR

ID-Sim is a novel, feed-forward similarity metric designed to mimic human "selective sensitivity"—the ability to remain invariant to massive contextual shifts (like lighting, pose, and background) while staying highly sensitive to subtle changes in an object's unique identity. By combining real-world datasets with strategically edited synthetic data and a dual global-local contrastive learning objective, ID-Sim consistently outperforms foundation models and standard perceptual metrics across instance retrieval, recognition, and generation tasks.

What Problem Does This Paper Address?

When humans look at an object—say, a specific pet dog—we easily recognize it whether it's running on grass, sleeping in a dark room, or viewed from a sharp aerial angle. Conversely, we can easily tell it apart from a highly similar dog of the same breed. Computer vision models, however, deeply struggle with this balance.

Existing evaluation tools fall into two traps:

  1. Perceptual metrics (like LPIPS or DreamSim) focus heavily on overall pixel or low-level appearance similarity, meaning they get confused when the background or lighting changes.
  2. Foundation models (like CLIP or DINO) often prioritize high-level semantic categories, occasionally grouping two distinct but similar-looking objects together or failing under severe contextual changes.

This gap makes it incredibly difficult to reliably evaluate identity-focused tasks, such as personalized text-to-image generation (e.g., "put this specific toy on the moon").

ID-Sim Motivation and Results

Methods

ID-Sim tackles this by training a Vision Transformer (ViT-L) backbone using a specialized supervised contrastive learning framework based on image triplets (Anchor, Positive, Negative).

The core technical innovations lie in its dual-headed architecture and training objectives:

  • Global CLS Loss: Standard InfoNCE loss is applied to the global CLS token to pull representations of the same identity together and push different identities apart.
  • Local Patch Loss: To prevent the model from losing fine-grained spatial details, the authors introduce a patch-level loss. Because objects can be misaligned across different viewpoints, they treat patch tokens as an unordered set and compute similarity using Sinkhorn distance (entropically regularized optimal transport). This allows for soft, permutation-invariant alignment across different images of the same instance.
Figure 3. ID-Sim training pipeline. We train our metric with dual contrastive supervision. At the global level, CLS-token projections for anchor–positive pairs are contrasted against one hard negative and additional batch negatives using InfoNCE. At the patch level, projected patch tokens are compared using Sinkhorn distance for the same instance pairs.

Datasets

To train a model with true domain and contextual diversity, the authors curated a massive training set (~10k instances across ~300 categories) divided into two main subsets:

  1. Subset 1 (Real Instance Datasets): Images from existing fine-grained and instance-level datasets spanning landmarks, fashion, products, art, and animals (e.g., GLDv2, DF2, MET, Cats/Dogs datasets).
  2. Subset 2 (Generative Edited Data): To fill the gaps where real data lacks controlled variations, they used generative AI (like Qwen-Edit) to create counterfactual pairs:
  3. Identity-Preserving Contextual Edits (S2a): The same object placed in completely different backgrounds, lighting, or poses.
  4. Identity-Altering Instance Edits (S2b): Modifying subtle details of an object (e.g., changing the color of shoe laces or dress patterns) to create challenging negative examples.

For evaluation, the authors introduced SUBJECTS2K, a new high-quality, human-annotated benchmark consisting of 2,000 binary (same/different instance) verification labels to clean up noisy automated metrics in generative evaluation.

Figure 2. Dataset curation pipeline. We highlight the different real and synthetic data subsets that enable ID-Sim training. To- gether, they provide high context, domain, and visual identity di- versities.

Key Insights and Ideas

  • Synthetic Data as a Regularizer: Purely real-world data doesn't provide enough isolated "controls." By generating synthetic images where only the background changes or only a tiny identity feature is altered, the model is explicitly forced to learn what defines an "instance" versus what defines "context."
  • The Power of Soft Patch Alignment: Hard patch-matching fails when an object rotates or moves. Utilizing optimal transport (Sinkhorn distance) allows the model to match local features (like a logo on a shirt or the texture of a vase) regardless of where they appear in the frame.
  • Downstream Transferability: Because the patch embeddings capture spatially coherent identity information, ID-Sim can be plugged directly into dense downstream tasks like personalized segmentation (e.g., PerSAM), drastically improving prompt localization.

Key Results

ID-Sim was evaluated against 7 prominent baselines (including DINOv3, CLIP, LPIPS, and Google's Universal Embedding model) across 49 distinct evaluation setups. ID-Sim outperformed the baselines in 48 out of 49 cases.

  • Instance Retrieval: On the challenging PODS and DeepFashion2 datasets, ID-Sim achieved massive boosts in mean Average Precision (mAP), outperforming the next-best models by +0.11 and +0.30 respectively.
  • Concept Preservation: On the newly introduced SUBJECTS2K benchmark, ID-Sim outperformed standard perceptual metrics by +0.05 mAP and even beat large Multimodal LLMs (like GPT-4o and Gemini) which are notoriously expensive and non-deterministic to run.
  • Segmentation: When integrated into PerSAM for personalized segmentation, it boosted the segmentation mAP from 0.153 (using DINOv3) to 0.436.

Limitations and Future Work

While ID-Sim marks a major step forward, the authors note a few key limitations:

  • Rigid Definition of Identity: The metric assumes visual properties (shape, texture, color) must remain identical. It does not inherently understand broader semantic identities that undergo natural transformations, such as a kitten aging into a cat, or a person putting on accessories.
  • Multi-Entity Scenes: ID-Sim is currently a global, prompt-free metric. If an image contains multiple distinct objects, it cannot automatically isolate which specific entity it should evaluate without external spatial conditioning (like bounding boxes or masks).

Summary updated

BibTeX
@inproceedings{chae2026id,
  author = {Julia Chae and Nicholas Kolkin and Jui-Hsien Wang and Richard Zhang and Sara Beery and Cusuh Ham},
  title = {{ID-Sim: An Identity-Focused Similarity Metric}},
  booktitle = {IEEE/CVF Conference on Computer Vision and Pattern Recognition},
  year = {2026},
  url = {https://openreview.net/forum?id=kC2B1DgCR9},
}
Figure