Deep Factorized Metric Learning

Chengkun Wang, Wenzhao Zheng, Junlong Li, Jie Zhou, Jiwen Lu
2/14/2026

No official code found. Best implementation: wangck20/DFML (20 stars, last commit 2023-06-06).

Abstract

Learning a generalizable and comprehensive similarity metric to depict the semantic discrepancies between images is the foundation of many computer vision tasks. While existing methods approach this goal by learning an ensemble of embeddings with diverse objectives, the backbone network still receives a mix of all the training signals. Differently, we propose a deep factorized metric learning (DFML) method to factorize the training signal and employ different samples to train various components of the backbone network. We factorize the network to different sub-blocks and devise a learnable router to adaptively allocate the training samples to each sub-block with the objective to capture the most information. The metric model trained by DFML capture different characteristics with different sub-blocks and constitutes a generalizable metric when using all the sub-blocks. The proposed DFML achieves state-of-the-art performance on all three benchmarks for deep metric learning including CUB-200-20ll, Cars196, and Stanford Online Products. We also generalize DFML to the image classification task on ImageNet-1K and observe consistent improvement in accuracy/computation trade-off. Specifically, we improve the performance of ViT-B on ImageNet (+0.2% accuracy) with less computation load (-24% FLOPs).11Code is available at: https://github.com/wangck20/DFML.

DOISemantic Scholar

Code Implementations(1)

wangck20/DFMLCommunity73%

Official implementation of Deep Factorized Metric Learning.

200PythonJun 6, 20233 years ago

Cite this paper

@article{wang2026deep,
  title  = {Deep Factorized Metric Learning},
  author = {Chengkun Wang and Wenzhao Zheng and Junlong Li and Jie Zhou and Jiwen Lu},
  year   = {2026},
  doi    = {10.1109/CVPR52729.2023.00741},
  url    = {https://doi.org/10.1109/CVPR52729.2023.00741},
  journal = {CVPR 2023 2023}
}

Discussion