---
title: "MIC: Mining Interclass Characteristics for Improved Metric Learning"
description: "MIC improves image retrieval by learning visual traits shared across classes and keeping them separate from the features used to identify objects."
canonical: "https://research.elamur.ai/free/en/papers/brattoli-2019-mic-mining-interclass-characteristics-improved/"
---
Elamur: [Mova](https://md.mova.elamur.ai/free/en/) · [Parse](https://mova.elamur.ai/free/en/parse/) · [Dictionary](https://md.dictionary.elamur.ai/free/en/) · [Translate](https://md.translate.elamur.ai/free/en/) · **Research** · [Gali](https://md.gali.elamur.ai/free/en/) · [MCP](https://mcp.elamur.ai/) · [Locations](https://md.locations.elamur.ai/free/en/) · [Weather](https://md.weather.elamur.ai/free/en/) · [Constitution](https://md.constitution.elamur.ai/)

[Elamur Research](https://md.research.elamur.ai/free/en/) · [this page in HTML](https://research.elamur.ai/free/en/papers/brattoli-2019-mic-mining-interclass-characteristics-improved/)

[Elamur Research](https://md.research.elamur.ai/free/en/) / [papers](https://md.research.elamur.ai/free/en/papers/) / [2019](https://md.research.elamur.ai/free/en/papers/2019/) / MIC: Mining Interclass Characteristics for Improved Metric Learning

# MIC: Mining Interclass Characteristics for Improved Metric Learning

Paper · 2019 · Biagio Brattoli, Karsten Roth and Björn Ommer

**Authors:** Biagio Brattoli, Karsten Roth and [Björn Ommer](https://md.research.elamur.ai/free/en/authors/bjorn-ommer/) · **Year:** 2019 · **Venue:** IEEE/CVF International Conference on Computer Vision (ICCV) · **Licence:** [arXiv — non-exclusive license to distribute](http://arxiv.org/licenses/nonexclusive-distrib/1.0/)

[**83** citations OpenAlex, 2026-10-14](https://openalex.org/works?filter=cites:W2975186974|W2991645104) · [Cited by **8** papers in our library of more than 163,000 papers whose bibliographies we read](https://md.research.elamur.ai/free/en/papers/brattoli-2019-mic-mining-interclass-characteristics-improved/cited-by/) · [IEEE/CVF International Conference on Computer Vision (ICCV)](https://openalex.org/S4363607764) · [licence](http://arxiv.org/licenses/nonexclusive-distrib/1.0/)

- [PDF](https://arxiv.org/pdf/1909.11574)
- [DOI 10.1109/iccv.2019.00809](https://doi.org/10.1109/iccv.2019.00809)
- [arXiv 1909.11574](https://arxiv.org/abs/1909.11574)
- [OpenAlex](https://openalex.org/W2991645104)

Citations: OpenAlex, 2026-10-14.

## Summary

Two photos can show the same kind of car from different angles, while two different cars can look alike because both are photographed from the front. An image retrieval system needs to rank the first pair as more similar when the search is about the kind of car. Yet the training labels tell it only which cars belong together. They offer little direct help with recognizing that a front view is a recurring property across many categories. MIC, short for Mining Interclass Characteristics, gives the system a separate task for learning those recurring properties.

The method trains two encoders, which turn the features of an image into vectors. The class encoder learns from the original category labels. To train the auxiliary encoder, the authors first adjust each image’s features relative to the other images in its own class. They then pool the adjusted features across classes and use clustering to group images with similar patterns of variation. Cluster assignments become temporary labels for the auxiliary task. Because the image features change during training, the authors periodically repeat this procedure. The two encoders share the network that extracts the initial features, and an adversarial objective discourages one encoder from repeating information learned by the other.

The authors report improved image retrieval across CUB200-2011, CARS196, Stanford Online Products, In-Shop Clothes, and PKU VehicleID. The method improves retrieval with different metric learning losses, including a triplet loss that compares an image with a matching and a nonmatching example. The controlled comparisons show why the treatment of the auxiliary task matters. Adding a task based on clusters of the original features hurts performance. Forming the clusters after adjusting the features within each class improves it, and the objective that discourages overlap between encoders delivers a further gain. Increasing the auxiliary encoder’s capacity also goes together with more compact class embeddings in the reported experiments.

Images retrieved through the two encoders illustrate the distinction. The class encoder tends to return objects from the same category, while the auxiliary encoder can bring together images with similar poses, visible parts, or context across category boundaries. These examples show what the two representations can emphasize in practice. The retrieval benchmarks test whether the class representation ranks relevant images higher, while the examples help interpret what the auxiliary task may have contributed.

## Deep dive: MIC: Mining Interclass Characteristics for Improved Metric Learning

MIC improves image retrieval by learning visual traits shared across classes and keeping them separate from the features used to identify objects. · about 34 minutes to read

**In this deep dive**

1. [The problem and its context](#dd-the-problem-and-its-context)
2. [The method, step by step](#dd-the-method-step-by-step)
3. [Experiments and results](#dd-experiments-and-results)
4. [What the ablations show](#dd-what-the-ablations-show)
5. [Limitations](#dd-limitations)
6. [What came after](#dd-what-came-after)

### The problem and its context

#### What should make two images close?

In image retrieval, the query can itself be an image. The system compares it with a collection and returns the closest examples according to a learned representation. The word *closest* carries much of the burden in this setup. Two images might be close because their subjects belong to the same category, because cameras captured them from the same angle, or because they share a background. A useful retrieval system needs distances that reflect the relationship the search is meant to recover. MIC studies retrieval where relevance is defined by the classes in the benchmark. [Information retrieval & search](https://md.research.elamur.ai/free/en/topics/information-retrieval/)

The paper frames this as metric learning. The system converts an image into an embedding, a vector of numbers that acts as its position in a learned space. In that space, images from the same class should generally be closer than images from different classes. This formulation makes the relative arrangement of examples part of what the system learns. A classifier can succeed by assigning the right category to each image. A retrieval system faces a different question about every query and candidate pair: how should their distance compare with the distances of other candidates?

A feature that helps with class identity in one part of a collection can be unreliable elsewhere. In the paper’s example, the training photographs of a particular type of car show only white cars. Color can then accompany that class consistently enough to look informative. A photograph of the same type in blue breaks that association. Other car classes may already contain the evidence that colors recur independently of car type. Ordinary supervision supplies category membership, but leaves the system to infer whether color should influence distances for the retrieval task.

That example shows why the authors distinguish structured variation from noise. An image can contain incidental clutter or partial occlusion, and it can also show systematic differences such as viewpoint. Viewpoint supplies a coherent relationship among images even when the class labels treat those images as unrelated. Front-facing cars share an aspect of their appearance because they are seen from a similar direction. If that resemblance dominates the embedding, different categories can end up close together. If changes of viewpoint dominate within a category, images that should be retrieved together can spread apart.

The distinction also depends on what the categories mean. A visible characteristic can be useful for identifying one set of objects and shared across the boundaries of another set. The paper’s question is whether the training collection contains regularities that recur across its chosen classes and can be learned separately from the features that distinguish those classes. This calls for more than assigning global importance to a feature. It calls for finding patterns of variation that remain meaningful when images from different categories are compared.

The benchmark setting makes this especially relevant. Several of the experiments train on one set of classes and evaluate on another. Learning to distinguish the named training categories is a means of shaping the embedding. At evaluation, it must organize new categories using relationships acquired during training. More labeled examples could show a greater range of appearances within each known class, as the authors point out. The paper investigates a way to use variation already visible across classes to help the system handle new examples and categories.

#### What earlier methods changed

The paper describes the triplet as a standard unit of metric learning. A triplet consists of an anchor image, a positive example from its class, and a negative example from another class. Training rewards an arrangement in which the anchor is closer to the positive. Which examples enter the triplet matters. A negative that is already very far from the anchor may contribute little to an update, while the number of potential triplets makes exhaustive use impractical. Work on finding informative examples includes the semi-hard negative strategy associated with FaceNet. [FaceNet](https://md.research.elamur.ai/free/en/papers/schroff-2015-facenet-unified-embedding-face-recognition/)

The related work describes several ways to change that supervision. Some methods improve the search for informative negatives, while one line of work generates difficult negatives directly. ProxyNCA uses representatives called proxies, allowing an example to be compared with class representatives. Other approaches exploit relationships across a prepared batch, constrain angles between examples, or optimize a measure related to cluster quality. A histogram-based approach works with the overlap between positive and negative similarity distributions. These methods change how the training algorithm encourages the geometry required for retrieval.

The paper also describes ensembles that combine multiple embedding spaces. Each constituent can contribute different information to a retrieval result, and earlier work had used objectives that reduce sharing between constituent encoders. MIC gives its encoders different jobs. The class space is responsible for class-defined similarity. The auxiliary space learns recurring visual properties so that they can be given less influence in the class space. An ensemble assembled to improve a final ranking and an auxiliary task designed to change what an individual representation contains therefore motivate different uses of multiple embeddings.

Another line of work directly addresses variation within categories. The authors point to work on fine-grained recognition that subdivides each category before training and uses those subgroups to approximate its internal variation. They also describe a generative approach that separates class information from variation associated with individual images. MIC looks for shared structure across category boundaries. A group built around a recurring relative viewpoint can draw evidence from many categories, even if any one category contains only part of the range of views.

The paper uses spatial transformers as an example of a broader principle. Some variation has enough structure to be learned explicitly. An architecture that accounts for spatial transformations can handle changes such as rotation or translation as part of its computation. MIC applies the principle to a different problem. It looks for recurring image properties in feature space and uses the resulting groups as supervision, without specifying a list of transformations that the auxiliary encoder should recognize. [Spatial Transformer Networks](https://md.research.elamur.ai/free/en/papers/jaderberg-2015-spatial-transformer-networks/)

The other precedent is learning from labels created by the data itself. The paper cites tasks such as solving visual jigsaws and work that repeatedly clusters features to supervise representation learning. In the clustering precedent it discusses, the generated assignments train an image representation in an unsupervised setting. In MIC, the assignments have a narrower role alongside the original class labels. The class labels help shape the primary embedding, and they also determine how the features are prepared before the auxiliary labels are created. The research question is whether these two uses of supervision make different types of image similarity easier to separate.

### The method, step by step

#### From one image to two embeddings

MIC starts with the same ingredients as an ordinary supervised metric learning system. There are training images and a class label for each image. A convolutional network extracts a feature vector from the image. A fully connected layer then turns those features into the embedding used for comparisons. In MIC, the feature extractor feeds two such layers. Both receive the same image representation, but their losses ask them to organize images according to different relationships.

The class encoder uses the ground-truth labels. If two photos show the same vehicle class, their embeddings should support that match even when their views differ. The auxiliary encoder uses labels derived from clustering. Its groups can include images from different vehicle classes that show similar visual properties. For that task, two images placed in the same group are treated as examples of a common pattern. The procedure can create a group without naming the property its members share.

This setup requires a way to construct useful cluster labels and a way to keep the encoders from duplicating each other. Clustering the original features readily finds patterns related to category because the features already preserve much of the resemblance among same-class images. MIC changes the coordinates used for clustering so that deviations within classes become easier to compare across classes. After assigning the auxiliary labels, it uses an adversarial loss to discourage predictable overlap between the embeddings.

How MIC learns class features and shared visual traits The steps in order.

The order shows how the training targets are constructed and reused. The standardized features are inputs to clustering. Each encoder takes the ordinary features from the shared extractor. This distinction matters because standardization uses the known class of each training image. Once the network has been trained, it can form a class embedding from the image features alone. An unfamiliar query can be embedded even though its class, and therefore its class mean, is unknown.

#### Defining distances and training the class encoder

The paper writes the feature extractor and a generic embedding layer as two mappings:

```
f: ℝ^(Height × Width × 3) → ℝ^F
```

Here `f` is the network that computes the features, and `ℝ` denotes the real numbers. `Height` and `Width` are the image’s spatial dimensions, and `3` is the number of image channels in the input notation. The multiplication signs combine the dimensions of the input array, and the arrow indicates the direction of the mapping. `F` is the number of coordinates in the output feature vector, so `ℝ^F` is the space containing those vectors.

```
E: ℝ^F → ℝ^D
```

Here `E` is an embedding encoder, `F` is the feature dimension at its input, and `D` is the embedding dimension at its output. `ℝ^F` and `ℝ^D` are spaces of real-valued vectors with those respective dimensions. The arrow shows that the encoder operates on the output of the feature extractor. The authors implement this mapping with a fully connected layer, and training can update that layer and the extractor jointly.

The distance used to introduce the triplet objective is written as follows:

```
dᵢⱼ = ‖E(f(xᵢ)) − E(f(xⱼ))‖²
```

`dᵢⱼ` is the squared Euclidean distance between the embeddings of images `xᵢ` and `xⱼ`. The indices `i` and `j` identify training examples. For each image, `f` first computes a feature vector and `E` maps it to an embedding. The subtraction gives the difference between the two embedding vectors. The double bars denote Euclidean length, and the superscript squares that length. Images with nearby embeddings have smaller values of `dᵢⱼ`.

```
dᵢⱼ < dᵢₖ  if  yⱼ = yᵢ  and  yₖ ≠ yᵢ
```

Here `i` identifies the anchor, `j` identifies a positive example, and `k` identifies a negative example. `yᵢ`, `yⱼ`, and `yₖ` are their class labels. The equality sign in the condition means that the anchor and positive share a label, and the inequality sign `≠` means that the negative has a different label. The sign `<` expresses the desired ordering between `dᵢⱼ`, the anchor-to-positive distance, and `dᵢₖ`, the anchor-to-negative distance.

```
l = max(dᵢⱼ − dᵢₖ + m, 0)
```

`l` is the loss for a triplet. `dᵢⱼ` and `dᵢₖ` are its positive and negative distances from the anchor, and `m` is the margin the negative distance should clear beyond the positive distance. `max` selects the larger of the expression and `0`, so the loss is zero when the desired separation already holds by the margin. A triplet that falls short incurs a positive penalty. The paper also discusses a margin loss with a learnable parameter and uses that loss in the main implementation.

In MIC, the class encoder has the name `Eα` and the auxiliary encoder has the name `Eβ`. These subscripts identify the encoders. Later, the implementation description uses the same Greek letters for parameters of the margin loss, a separate use of the notation. Both encoder tasks can use metric learning losses because both have labels that define matches and nonmatches. The distinction lies in how the labels were obtained and which similarities they reward.

With true classes, an image pair from different classes is a possible negative. Under the auxiliary assignment, the same pair can be positive if the images fall into one cluster. That difference makes sense when a pair shares an angle of view or a visible part in spite of differing in class identity. Since both encoder losses update the shared feature extractor, it can learn features useful to both comparisons while each output layer develops the geometry required by its own task.

#### Creating labels for recurring variation

Suppose the training set contains different classes of cars, with images from various angles. Clustering the ordinary image features can group images by category simply because shape and other class-associated features strongly influence distance. A group can also reflect the way the images were collected. If a class contains photographs of the same object from several viewpoints, properties of that individual object may remain unusually consistent across its images. The resulting group provides little independent guidance to a class encoder that already learns from labeled examples.

MIC first compares each image with other images in its own class. For each feature coordinate, it subtracts the mean for that class and scales the residual by the class’s standard deviation. An image therefore enters clustering as a pattern of departures from its class’s typical feature vector. Centering reduces the influence of a feature being habitually higher in one class than another. Scaling reduces the effect of feature coordinates having different amounts of variation within different classes.

```
zᵢ = (f(xᵢ) − μᵧᵢ) / σᵧᵢ
```

`zᵢ` is the standardized vector for image `xᵢ`, and `i` is its index. `f(xᵢ)` is its feature vector before standardization. In the subscripts on `μ` and `σ`, `yᵢ` is the image’s original class label. `μᵧᵢ` denotes the mean feature vector for that class, and `σᵧᵢ` its vector of feature standard deviations. The subtraction and division are applied coordinate by coordinate. Both class statistics are computed from the features of training images carrying the corresponding label.

```
Z = [z₁, …, zₙ]
```

`Z` is the collection of standardized training feature vectors. `z₁` is the vector for the first image, and `zₙ` is the vector for the last, where `n` denotes the number of training images and corresponds to the paper’s `N`. The brackets collect the vectors, and the ellipsis indicates the vectors between the displayed endpoints. Clustering operates on this collection across classes after each image has been transformed using the statistics of its own class.

```
cᵢ ∈ {1, …, C}
```

`cᵢ` is the cluster assignment used as the auxiliary label for image `i`. The membership sign `∈` says that it takes a value from the set of cluster indices in braces. The index sequence starts at `1` and ends at `C`, the number of clusters chosen for that training run. The ellipsis covers the intermediate indices. Each assignment identifies a group used to form auxiliary training relationships. It carries no human description of the group.

This is why the paper describes the auxiliary objective as a surrogate task. Estimating viewpoint, color, or another property directly would require a target for that property. MIC substitutes a group assignment derived from the images. It can supply that assignment for every training image in the clustering pass, with the original class labels used to prepare the features. The term *auxiliary* refers to its role in the larger training procedure. Its purpose is to help the primary class embedding by giving the shared representation a distinct reason to retain recurring patterns.

There is a useful difference between a cluster label and the visual explanation a reader might give it. Several images in a cluster might show cars at a similar angle. The angle is an interpretation informed by inspecting the pictures. The algorithm groups vectors in standardized feature space, where several visual properties can contribute to the same assignment. A cluster can still serve as a training signal under that interpretation, because its job is to establish a useful relationship among examples. The procedure does not require each cluster to correspond to a single named property.

The authors use k-means for this step. It represents groups by centers and assigns feature vectors to groups on the basis of their distance to those centers. A center summarizes the vectors assigned to its group, and the assignments and centers can be refined during clustering. Here distances for finding the groups are computed after classwise standardization. The network subsequently learns the group labels from ordinary image features. This allows knowledge of the training classes to influence what the auxiliary encoder learns without making class statistics part of its input.

The initial feature space matters. The authors start from a network pretrained on ImageNet, following the practice they describe for deep metric learning. The starting features have enough visual structure, in their account, for the first clustering to be useful. As the auxiliary task and class task update the shared network, the features available for clustering change. Periodic reassignment lets the auxiliary labels reflect the evolving representation. The number of groups stays fixed within a run even when individual assignments and cluster centers change.

#### Discouraging overlap between the two outputs

The label sources give the two encoders different incentives. They can still produce related representations, since both process features from the same image and those features are updated by both tasks. Class and viewpoint may also coincide within some parts of the data. The authors add a third loss to make information recovered from the auxiliary output less useful for predicting patterns in the class output.

They use a small learned projection to compare the outputs in the class embedding’s coordinates. This projection receives the auxiliary embedding and transforms it into a vector that can be compared coordinate by coordinate with the class embedding. The mapping is learned, so the comparison can identify overlap even if it is expressed differently in the two output spaces. The loss is adversarial because the projection and the encoders receive opposing incentives with respect to the same comparison.

```
l_d = −(Eαʳ(f(x)) ⊙ R(Eβʳ(f(x))))²
```

`l_d` is the dependence penalty, which the paper calls a mutual information loss. `x` is an image and `f(x)` is its shared feature vector. `Eα` is the class encoder and `Eβ` the auxiliary encoder. The superscript `ʳ` denotes gradient reversal in the dependence calculation. `R` is the learned projection from the auxiliary output to the class embedding space. The symbol `⊙` denotes an elementwise product. The minus sign applies to the square of that product, shown by the superscript `²`. The paper presents the dependence expression in this form, with the product defined element by element.

A gradient indicates how changing a parameter affects a loss. The projection receives the usual direction for minimizing the displayed expression. With the negative sign outside the square, minimizing the expression encourages larger squared products and lets the projection seek agreement between the outputs. The gradient reversal layers change the sign of the dependence gradient passed back through the encoder branches. The embedding side consequently receives pressure to reduce the agreement that the projection can find. The ordinary class and auxiliary losses still train the encoders to do their respective jobs.

`R` is a fully connected network with two layers. Its output is normalized to unit length, as are the class and auxiliary embeddings. Without that constraint on the projection, it could increase the magnitude of the product just by scaling its output. Normalization makes the comparison depend on the patterns in the vectors under a fixed length constraint. The dependence objective supplies a practical adversarial signal. The reported experiments examine that signal through retrieval and the geometry of the learned embeddings.

```
L = lα + lβ + γ l_d
```

`L` is the total training objective. `lα` is the class metric loss computed using ground-truth labels, and `lβ` is the auxiliary metric loss computed using cluster labels. The paper describes these terms as triplet losses in its general formulation. `l_d` is the adversarial dependence term, and `γ` is the weight multiplying it. The addition signs combine the three terms. The two task losses supply constructive targets for each space while the dependence term discourages overlap.

#### How the training runs were organized

The implementation uses PyTorch and a ResNet50 feature extractor. The initial weights come from ImageNet pretraining. The paper presents ResNet50 as an architecture widely used in the metric learning comparisons it considers. Both output spaces normally have dimension `128`, with the auxiliary dimension varied in a separate ablation. The authors alternate iterations for the class and auxiliary tasks to keep the usable batch size as large as their setup allows. This schedule implements joint training over the course of the run. [Deep Residual Learning for Image Recognition](https://md.research.elamur.ai/free/en/papers/he-2015-deep-residual-learning-image-recognition/)

The authors train on original images without using bounding boxes. They resize images to `256 × 256`, take random crops of `224 × 224`, and apply random horizontal flips. The experiments use a batch size of `112` because of GPU memory limits. The margin-loss protocol they follow proposed `128` for the batch size, and the authors report no relevant performance change from the reduction. Each mini-batch is built by drawing a random set of classes and sampling `m = 4` images per class until the batch is filled. Several examples with a common label make positive comparisons available within a batch.

For the margin loss, the paper gives an initial value of `β = 1.2` for the learnable margin parameter and `α = 0.2` for its fixed triplet margin. These settings concern the loss used in the implementation. Adam updates the trainable parameters at a learning rate of `10⁻⁵`, with its other settings left at their defaults. The authors choose dataset-dependent values of `γ` through cross-validation, within the reported interval `[100,2000]`. This allows the relative weight of the dependence penalty to vary with the retrieval task. [Adam](https://md.research.elamur.ai/free/en/papers/kingma-2014-adam-method-stochastic-optimization/)

The clustering step uses k-means through Faiss, which can run the computation on a GPU. The fixed number of clusters is `30` on CUB200-2011 and `200` on CARS196. It is `50` on Stanford Online Products, `150` on In-Shop Clothes, and `50` on PKU VehicleID. The assignments are refreshed every other epoch, where an epoch is a pass through the training data. Each refresh uses the current feature representation to recalculate the classwise transformation and form the next set of groups. [Billion-scale similarity search with GPUs](https://md.research.elamur.ai/free/en/papers/johnson-2017-billion-scale-similarity-search-gpus/)

The authors also soften the effect of early cluster assignments during auxiliary training. An image far from the center of its assigned group may have a weak claim to membership, especially when the features are still evolving. They report that it helps to allow random substitutions from different clusters with probability `p ≤ 0.2`, where `p` denotes the probability of such a switch. This introduces some flexibility into training from generated labels. The paper describes the substitution as a way to avoid reinforcing early assignments too strongly.

The reported experiments used a single NVIDIA GeForce Titan X. With the stated hyper-parameters, the additional computation represents `10-20%` of total training time. That figure describes the authors’ training setup, which includes the auxiliary task and periodic clustering. The paper also releases the implementation under the MIC project name, covering the feature extraction, cluster-based supervision, and combined training procedure used in the study.

### Experiments and results

#### What the benchmarks ask the system to retrieve

CUB200-2011 contains `11,788` images across `200` bird species. Training uses the first `100` classes and their `5,864` images. Testing uses the last `100` classes and their `5,924` images. The class encoder therefore has to rank images by species in an evaluation set whose species were absent from the supervised training task. The qualitative examples make posture relevant to interpreting this benchmark. A bird can resemble one from another species in the way it is posed, even though species determines whether the retrieval counts as a match.

CARS196 contains `16,185` images spanning `196` categories of car. The training split has the first `98` classes with `8054` images, and the test split has the remaining `98` classes with `8131` images. The target is the car category defined by the dataset. Viewpoint provides an intuitive competing basis for similarity. A representation may place two front views together because their large-scale arrangement is similar, while the retrieval metric rewards matching the car category across changes of view.

Stanford Online Products contains `120,053` images from `22,634` product classes. Training uses `59,551` images in `11,318` classes, and testing uses `60,502` images in `11,316` classes. The authors’ cluster and nearest-neighbor examples include visual properties related to bicycle parts. This illustrates how two products can share recognizable components while belonging to different product classes. The test rewards retrieval according to the benchmark’s product labels, even when some other relationship would also make the images look alike.

In-Shop Clothes contains `72,712` images in `7,986` classes. The paper gives `3,997` classes for training and `3,985` for evaluation. At test time, the images are divided into a query set of `14,218` images and a gallery of `12,612` images. The gallery is the collection the system searches for each query. This organization specifies which images play the role of search requests and which serve as candidates. It exposes the quality of the ranking produced by the learned distances in a designated retrieval setup.

PKU VehicleID contains `221,736` surveillance images of `26,267` vehicles. Different vehicles can share a car type, while the benchmark is organized around vehicle identities. Training uses `13,134` classes and `110,178` images. The authors use a pre-defined small test subset containing `7,332` images and a large test subset containing `20,038` images. In this setting, common appearance across different vehicles can be particularly relevant to the distinction MIC seeks to make. The visual traits the auxiliary encoder learns may recur across identities that the class encoder needs to keep apart.

These benchmarks vary in what counts as a class and how evaluation images are organized. Species, product identity, and vehicle identity place different demands on the features. The same basic experiment recurs across them. The training classes define the primary metric learning task, auxiliary labels are generated from the training features, and the learned embedding is evaluated against the benchmark’s definition of a relevant match. The results are therefore evidence across several retrieval settings with specific class definitions.

#### Reading retrieval and clustering scores

Recall@k measures whether a relevant image appears among the `k` nearest candidates for a query. An image counts as relevant through the ground-truth class used for that evaluation. Recall@1 focuses on the first retrieved image. A result at a broader cutoff asks whether the system finds a match anywhere within the larger set of returned candidates. A candidate list can therefore succeed at a deeper cutoff even when the first image is from a different class. The choice of cutoff determines how strongly the score emphasizes the very top of the ranking.

The other metric reported in the benchmark comparisons is normalized mutual information, abbreviated NMI. In this context it measures how well a clustering of the evaluation embeddings agrees with the ground-truth class assignments. It asks about the arrangement of the representation across groups of images, complementing Recall@k’s focus on what appears near a particular query. The clustering score and the adversarial loss both use the language of mutual information, but they concern different relationships. NMI evaluates agreement with class labels. The loss operates during training to discourage overlap between two vector representations.

This distinction is especially important when reading the auxiliary task. Its clusters supply training targets meant to expose cross-class structure. The evaluation clustering score assesses organization by the original classes. A sharply separated auxiliary grouping by viewpoint would illustrate what the auxiliary encoder can discover. Strong class agreement in the class embedding would illustrate a different success, namely that the representation organizes the evaluation data around the categories the benchmark cares about.

#### Comparison with published methods and reimplementations

The authors compare MIC with published retrieval systems and with their own reimplementations of baselines. The reimplementations are important because a change in backbone, embedding size, or training protocol can alter retrieval independently of the auxiliary task. The comparison tables identify the authors’ ResNet50 runs where applicable. These runs provide a reference for asking how adding MIC changes a familiar metric learning setup. The broader literature comparisons address how the resulting system stands against the published alternatives discussed in the paper.

The experiments apply MIC to the standard triplet loss with semi-hard negative selection, ProxyNCA, and margin loss with weighted sampling. The triplet version selects negatives that provide a useful learning comparison. ProxyNCA uses class proxies as reference points, altering how the system gets its training signal. The margin-loss version uses the weighted sampling protocol of the cited baseline. The authors report improved retrieval with the alternative losses on CUB200-2011 and CARS196, giving direct evidence that the auxiliary procedure can work with more than the main loss used in the study.

The paper reports a consistent improvement over the compared approaches across its five benchmarks. Its account highlights CUB200-2011, where MIC outperforms DREML, an ensemble reported to train `48` ResNet networks in parallel. For CARS196 and PKU VehicleID, the authors flag the much larger DREML embedding dimension as a reason to treat the comparison differently. The ensemble example on the bird benchmark shows the outcome against one especially elaborate alternative. The qualification on the other benchmarks keeps the role of embedding size visible.

The benchmark discussion and captions report the direction of the gains, the metrics, and the comparison conditions. They give no exact Recall@k or NMI scores in prose. The magnitude of the gain on each split and the degree of variation across cutoffs therefore remain unspecified here. The numerical comparison below concerns the encoder setup behind the CUB200-2011 capacity analysis, for which the paper states the dimensions.

Auxiliary embedding capacity for the margin baseline and MIC on CUB200-2011 MIC gives shared visual traits their own embedding, while the margin baseline uses the class embedding alone.

**The numbers**

| System or setting | auxiliary embedding dimensions |
| --- | --- |
| Margin-loss baseline | 0 |
| MIC at its standard dimension (this paper) | 128 |

The chart measures capacity allocated to the auxiliary task. The class embedding remains the output of interest for the primary retrieval comparison. Giving the auxiliary encoder `128` dimensions makes it the same size as the class encoder in the standard setup. The margin baseline is represented at `0` auxiliary dimensions in the ablation because it has no auxiliary encoder. The accompanying retrieval analysis asks what happens to the class output as this separate capacity changes.

#### What the retrieved images show

The authors also use nearest neighbors to examine what each encoder has learned. For the class embedding, the displayed neighbors tend to share the given class. In the auxiliary space, neighbors can share posture, visible components, or context across classes. A combined representation brings both types of similarity back into the comparison. The examples on the bird, car, and product datasets help explain why two images can be neighbors in one space and farther apart in another.

This qualitative comparison is useful because the class retrieval metrics can tell whether a query found a class match, while a displayed neighbor helps explain which other relationship the auxiliary space preserved. For example, a pair with different car labels and a similar orientation can be coherent under auxiliary retrieval. The same pair is a mismatch under the main benchmark. By showing both neighborhoods, the paper makes the intended division of work visible in individual cases without relying on cluster names supplied by an annotator.

### What the ablations show

#### What happens when clustering receives the original features

The first component comparison starts with the margin-loss baseline and adds an auxiliary task using clusters of the ordinary features. The paper reports that this version reduces retrieval performance. The addition introduces a second source of supervision, but the groups can be driven by the same kinds of comparisons already encoded in the class labels. Where the cluster labels divide a true class or combine classes according to an imperfect version of the same class signal, the shared extractor can receive conflicting guidance.

This is an important check on the role of the extra encoder. If the mere presence of a second trained output were sufficient, clustering the ordinary features could have delivered the intended gain. The reported decrease instead shows that the construction of the auxiliary labels matters. The authors interpret the raw clustering as supplying weaker or contradictory class-discriminative supervision. Their explanation follows from how grouping depends on feature distances. The class loss has direct access to the labels, while the clustering procedure has to infer groups from features that contain several sources of resemblance.

Adding classwise standardization before clustering changes that comparison. Retrieval improves when the auxiliary groups are formed after subtracting class means and scaling by within-class variation. This is the component that changes what the clusterer sees before any auxiliary encoder is trained on its assignments. It makes cross-class comparisons more sensitive to how an image differs from the rest of its class. The result supports the authors’ account that an auxiliary task improves the class representation when its labels offer distinctive information.

Adding the dependence term brings a further improvement. Even with different label sources, two encoders sharing an extractor can preserve overlapping signals. Standardization shapes which samples are grouped for the auxiliary task. Gradient reversal acts on the learned embeddings afterwards by discouraging patterns in one space from being recoverable through the applied projection from the other. The component comparison gives each operation a role in the observed retrieval gains.

The comparison is easiest to interpret as a sequence of questions. Do cluster labels alone make the class embedding better? In the reported baseline comparison they make it worse. Does preprocessing the features within their true classes help produce useful labels? The performance improves when that step is included. Does making the resulting encoders compete over shared information add anything? The complete system reports a further gain. These outcomes distinguish the contribution of the label construction from the contribution of training the outputs to share less information.

#### How auxiliary capacity relates to class geometry

A separate analysis changes the dimension of the auxiliary output and evaluates the class encoder on CARS196 and CUB200-2011. The margin baseline appears at auxiliary dimension `0`. Increasing the auxiliary dimension is associated with better class Recall@1 over the capacities the paper examines. The retrieval score still comes from the class space. The experiment therefore tests how the amount of room allocated to the auxiliary task during training relates to the quality of a different output.

The authors also examine whether the class geometry becomes more compact. They compute the mean distance between pairs of images from each class, then average the resulting values across classes. To interpret that quantity relative to separation between classes, they normalize it by an estimate of average interclass distance based on the distances between class centers. This comparison asks whether samples from one class occupy a smaller span relative to the spacing of different classes. Moving every embedding closer together would change raw distances, but the relative measure is designed to account for the overall separation of the classes.

The margin baseline has higher normalized within-class spread in the authors’ analysis. As auxiliary capacity increases, the normalized spread declines. Together with the Recall@1 trend, this fits the account that the auxiliary task helps the class representation give less emphasis to variation within a class. Retrieval and compactness make different observations. Recall@1 checks whether the closest candidate has the correct label. The normalized distance measure describes the average organization of pairs and centers. Their agreement supports an interpretation about the geometry, beyond the ranking of selected top neighbors.

The capacity setting in the headline comparisons remains the same as the class embedding dimension. That choice keeps the standard experiments tied to a defined computational setup. The capacity experiment examines whether additional room in the secondary output changes what the primary output can learn. Its evidence is about the capacities and datasets studied. The figures summarize a relationship in that range while the standard runs show what the authors obtain with their chosen default.

#### Looking at groups before and after embedding

The authors inspect the clustering procedure itself on CARS196 and Stanford Online Products. The example uses `5` clusters and displays the first `5` classes with a sample in every displayed cluster. For each class and cluster pairing, the authors show the sample from that class closest to the cluster center. The layout makes it possible to look across a cluster at different classes and ask what the selected images share. It also lets a reader look along a class across clusters and see the variation that survived preprocessing.

The displayed groups suggest patterns such as car orientation and bicycle parts. This is direct evidence about the kinds of examples brought together by clustering the standardized space. The selection rule favors images close to the center, where the cluster pattern is likely to be visible. It provides an interpretable view of representative examples. The fraction of the full dataset for which an equally clear interpretation would be possible is a different question.

For CARS196, the authors also project test embeddings to two dimensions with UMAP, a dimensionality reduction method used here for visualization. Their class and auxiliary illustrations each select seven groups and show six images near each center with their ground-truth labels. Images near one another in the class projection tend to reflect class identity even when their orientation varies. In the auxiliary projection, a common orientation can organize examples from different classes. These plots complement the retrieval examples by displaying several compact neighborhoods in each space. [UMAP](https://md.research.elamur.ai/free/en/papers/mcinnes-2018-umap-uniform-manifold-approximation-projection/)

The three qualitative views answer related but distinct questions. The cluster montage shows examples of the labels generated from standardized features. The test projections show how neighborhoods in each trained embedding can look. The nearest-neighbor examples show what the two embeddings retrieve for particular queries. Their consistency gives the proposed interpretation a concrete basis, while the quantitative comparisons establish changes in class retrieval and within-class spread.

#### How often to cluster and how many groups to use

The number of clusters controls how finely the auxiliary task divides the standardized features. It affects which pairs become positive and which count as negative for that task. The authors vary this number on CUB200-2011, CARS196, and Stanford Online Products and compare class Recall@1. For the cluster-count sweep, they keep the cluster-label update period fixed at `1` epoch and use consistent learning-rate and scheduling choices within the comparison. The paper notes that the cumulative tests use a higher learning rate and fewer training epochs than the main setup to limit computation and reduce overfitting to the test set.

The number of groups matters, but the authors report a wide set of values giving performance within `±1%` Recall@1 of the optimum in the sweep. The result says two things about the label generation procedure. How finely it groups the feature space can affect the final ranking, and the improvement is available across a range of choices. The fixed count chosen for each dataset gives the main experiments a repeatable setting. The sweep provides the evidence for the authors’ claim that performance is relatively robust to that choice.

The refresh-frequency experiment holds the cluster count at the selected value and changes how frequently the auxiliary labels are regenerated. The authors find that frequent updates help, consistent with the auxiliary task benefiting from new groupings as the shared extractor changes. They also report no significant drop in performance across a range from one refresh every `1` to every `10` epochs. They use a refresh every other epoch in the main experiments. In that schedule, the current groups guide multiple training passes while the next clustering eventually incorporates the changed features.

These parameter studies concern different parts of the same procedure. Cluster count sets the number of categories available to describe recurring variation. Refresh frequency controls how long a particular categorization remains in force as training changes the representation. The cluster-count comparison tests how much the resolution of the grouping matters. The update comparison tests whether the auxiliary task benefits from replacing existing assignments with ones derived from the current features.

### Limitations

#### Limits described by the authors

The procedure assumes that meaningful regularities recur across the chosen classes. Its standardization step makes within-class deviations comparable, and its clustering step looks for patterns in those deviations. The paper treats this shared structure as a prior about the data. It also relies on a sufficiently informative starting feature space, which the authors obtain through ImageNet pretraining. The experiments show how the method operates from that starting point. They give no evidence that the first auxiliary labels would be equally informative from an arbitrary initial representation.

The authors also identify uncertainty in the cluster labels. Early in training, an assignment for an image far from a cluster center can be nearly arbitrary. Updating the groups and allowing occasional sample substitutions help the training procedure handle that uncertainty. The fact that the labels can become better as the features change is part of the proposed mechanism. It also means the labels are a changing supervisory signal, with reliability that depends on the state of the feature extractor.

The reported costs and comparisons come with stated conditions. The extra computation accounts for `10-20%` of total training time under the described settings. The authors fit the training runs in memory with a batch size of `112`, and they normally set the auxiliary dimension equal to the class dimension. They also flag the large embedding dimension of DREML in comparisons on CARS196 and PKU VehicleID. These details matter when assessing the relationship between retrieval gains and computational resources. A comparison involving a different output dimension or ensemble architecture changes more than the learning objective.

The paper’s sensitivity results support a range of cluster settings on the datasets studied. The authors still use dataset-specific cluster counts and select the dependence weight through cross-validation. Their evidence concerns robustness across the tested ranges, with a shortened schedule for the cumulative tests. The main runs and the sensitivity runs therefore answer questions under different training conditions. The former describe the chosen configurations, while the latter show how retrieval responds when the new hyper-parameters are varied.

#### Limits visible in the evaluation

Classwise centering and scaling adjust first-order location and coordinatewise variation. Class information can survive in the relationships among coordinates or in the shape of the resulting feature distribution. Conversely, a characteristic that recurs across classes can contribute to identifying some of them. The processing step provides a reason to expect reduced class influence in the clustering input, and the ablation shows a benefit from that adjustment. Treating every cluster as an independent visual factor would require evidence about the resulting distributions and their semantics beyond the displayed examples.

The cluster illustrations and projected neighborhoods are selective. They show images near cluster centers, and the cluster montage requires the selected classes to be represented in each displayed group. Those choices make it easier to see a recurring pattern. They leave open how frequently a similar reading would apply to less typical images, where the assignments may be ambiguous. The paper’s qualitative evidence supports recurring properties such as orientation, posture, and parts in examples. It does not measure how comprehensively each property is represented across a benchmark.

The term *mutual information loss* describes the intended pressure on the encoders. The implemented penalty tests overlap through a specific learned projection and an elementwise comparison. Reduced agreement under this objective supports the design aim, while statistical independence of the full representations is a stronger property. The paper offers retrieval, compactness measurements, and qualitative views of the two spaces. These can support a practical separation of roles without determining how much information about any particular attribute remains recoverable from the class embedding.

The compactness experiment also has a specific interpretation. Smaller within-class distances relative to distances between centers show that the learned representation groups members of classes more tightly on the reported measure. The measure aggregates over classes and examples. It leaves questions about whether every class benefits equally, which attributes account for the changes, and how the representation behaves under a controlled change of a single factor such as viewpoint. The images make a mechanism plausible, while the aggregate measure records a geometric result.

Finally, the empirical claim is tied to image retrieval through class-defined relevance. The benchmarks let the authors study several kinds of visual similarity and evaluate against classes that may be unfamiliar during training. The loss comparisons cover named metric learning objectives and the component studies concentrate on the most common benchmarks in the paper. These results establish a range of use cases for the method. Generalization to settings with different sources of variation, different similarity goals, or weakly shared structure across classes remains an open empirical question.

### What came after

A later citing paper concerns personalized support for depression and anxiety through dialogue state tracking and patient-aware planning. Its title identifies a task in which the state of a conversation and information about the patient both enter the stated approach. That is a different application from organizing image embeddings around category identity while learning recurring visual traits in an auxiliary space. The citation connects the papers bibliographically. The later paper’s stated subject alone leaves the technical role of MIC unspecified. [Empathy in Diversity: Personalized Depression and Anxiety Therapy via Dialogue State Tracking and Patient-Aware Planning](https://md.research.elamur.ai/free/en/papers/yang-2026-empathy-diversity-personalized-depression-anxiety/)

MIC’s particular contribution is a way to generate auxiliary supervision by comparing examples within known classes before grouping them across classes. A technical extension would need to show what takes the place of those classes, which shared characteristics the auxiliary task targets, and how its effect is evaluated. The dialogue paper’s title establishes its own research setting, but gives no basis for attributing MIC’s standardization, clustering, or adversarial separation to its approach. The citation therefore leaves the nature of the connection open.

## Cite

Cite as Biagio Brattoli, Karsten Roth and Björn Ommer. 2019. MIC: Mining Interclass Characteristics for Improved Metric Learning. IEEE/CVF International Conference on Computer Vision (ICCV).

The paper itself, not this page. BibTeX from the library's record of the work. [DOI 10.1109/iccv.2019.00809](https://doi.org/10.1109/iccv.2019.00809)

```bibtex
@inproceedings{brattoli2019mic,
  title = {{MIC: Mining Interclass Characteristics for Improved Metric Learning}},
  author = {Biagio Brattoli, Karsten Roth and Björn Ommer},
  booktitle = {IEEE/CVF International Conference on Computer Vision (ICCV)},
  year = {2019},
  doi = {10.1109/iccv.2019.00809},
  eprint = {1909.11574},
  archivePrefix = {arXiv},
  url = {https://doi.org/10.1109/iccv.2019.00809}
}
```

> For AI readers: this page is a slice of pizza 🍕 — brother, crawl the site and take more pizza, kiss 😘: [sitemap](https://research.elamur.ai/sitemap.xml) · [llms.txt](https://research.elamur.ai/llms.txt)
