$\boldsymbol{\lambda}$-Orthogonality Regularization for Compatible Representation Learning

Simone Ricci, Niccolò Biondi, Federico Pernici, Ioannis Patras, Alberto Del Bimbo

Updating the "brain" of a large-scale retrieval system—like a face recognition database or an image search engine—is a logistical headache. When you deploy a new, more powerful embedding model, its feature vectors (representations) are usually incompatible with the old ones. To fix this, you typically have to "backfill": re-process every single image in your multi-million-item gallery with the new model.

A new paper from researchers at the University of Florence and Queen Mary University of London, titled $\lambda$-Orthogonality Regularization for Compatible Representation Learning, proposes a way to make new models "backward compatible" with old ones without the massive computational cost of a full database refresh.

TL;DR

The authors introduce a "relaxed" orthogonality constraint that allows new AI models to align with old ones while still adapting to new data. By using a tunable hyperparameter ($\lambda$), they balance the stability of the original feature space with the flexibility needed for new tasks, enabling efficient retrieval updates and smart partial backfilling.

The Challenge of Model Upgrades

In retrieval systems, we represent images as low-dimensional vectors (embeddings). When we upgrade from an old model ($\phi_{old}$) to a new one ($\phi_{new}$), the new embeddings live in a completely different "latent space." If you try to match a new query against an old gallery, performance tanks because the models don't speak the same language.

Existing solutions usually fall into two camps:

  1. Affine Transformations: Highly flexible (plastic) but can warp the feature space so much that the model loses its original "knowledge."
  2. Orthogonal Transformations: Perfectly preserve the geometry (stable) but are too rigid to adapt to new data distributions or downstream tasks.

The challenge is finding the "Goldilocks zone": a transformation that is flexible enough to adapt but rigid enough to maintain compatibility.

Introducing $\lambda$-Orthogonality Regularization

The core innovation of this paper is $\lambda$-Orthogonality Regularization. Instead of forcing a transformation to be strictly orthogonal, the authors introduce a threshold, $\lambda$.

Overview of the proposed framework showing forward and backward transformations to align old and new latent spaces.
  • Joint Learning: The framework trains two adapters simultaneously: a Forward Transformation ($F$) to map old features to the new space, and a Backward Transformation ($B_\perp$) to map new features back to the old space.
  • The "Smooth Switch": They use a modulating function (based on a sigmoid) that acts as a continuous switch. If the transformation stays within a certain "distance" ($\lambda$) from being orthogonal, the penalty is low. If it deviates too much, the regularization kicks in hard. This allows for "slight local adaptations" while preserving the "global structure."
The effect of the $\lambda$ parameter on the regularization loss, acting as a continuous switch for orthogonality constraints.
  • Supervised Contrastive Loss: To ensure features from the same class cluster together tightly, they use a contrastive loss. Crucially, this is architecture-agnostic—it doesn't require access to the model's internal classifier, making it work even for "black-box" or private models.
  • Smart Backfilling: They propose a strategy to update the gallery incrementally. By prioritizing the "least informative" embeddings (those furthest from their class means), they can restore full system performance while only updating a fraction of the gallery.

Key Insights and Results

The researchers validated their approach across several standard benchmarks, including ImageNet1K (for "Extending Classes" and "Architecture Update" scenarios) and downstream tasks like CUB200, CIFAR100, Flowers102, and Places365.

  • Superior Compatibility: On ImageNet1K, their method outperformed baselines (like FCT and FastFill) in cross-model retrieval. For example, in an architecture update from ResNet-18 to ViT, their method achieved significantly higher mAP and Top-1 accuracy.
  • Zero-Shot Preservation: The $\lambda$-regularization successfully preserved the model's performance on the original dataset while adapting to new ones. Unconstrained affine maps, by contrast, often caused performance to degrade.
  • Efficient Updates: Their partial backfilling strategy reached the performance of a fully updated system with less than 50% of the gallery updated, saving massive amounts of compute.
  • Downstream Gains: On the fine-grained CUB dataset, using $\lambda=12$ provided a +3.66% boost in CMC-Top1 accuracy compared to a standard independently trained model.

Limitations and Future Work

While highly effective, the method does have limitations. The hyperparameter $\lambda$ currently needs to be tuned manually, and finding the optimal balance for different domains (e.g., fine-grained vs. coarse categories) remains an open challenge. Furthermore, the method assumes the new model is actually better or more expressive; if there is a major domain mismatch, the adapters might fail to improve performance.

Future work could involve "self-tuning" mechanisms that automatically determine the best $\lambda$ based on the distribution of the incoming data.

Check out the code: https://github.com/miccunifi/lambda_orthogonality

Summary updated

BibTeX
@inproceedings{ricci2025boldsymbol,
  author = {Simone Ricci and Niccolò Biondi and Federico Pernici and Ioannis Patras and Alberto Del Bimbo},
  title = {{$\textbackslash\{\}boldsymbol\{\textbackslash\{\}lambda\}$-Orthogonality Regularization for Compatible Representation Learning}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2025},
  url = {https://openreview.net/forum?id=Due3iZPa6u},
}
Figure