---
title: "Food-101 – Mining Discriminative Components with Random"
description: "Food-101 introduces a benchmark for recognizing dishes in photos and uses random forests to discover the image regions that help tell them apart."
canonical: "https://research.elamur.ai/free/en/papers/bossard-2014-food-101-mining-discriminative-components/"
---
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/bossard-2014-food-101-mining-discriminative-components/)

[Elamur Research](https://md.research.elamur.ai/free/en/) / [papers](https://md.research.elamur.ai/free/en/papers/) / [2014](https://md.research.elamur.ai/free/en/papers/2014/) / Food-101 – Mining Discriminative Components with Random Forests

# Food-101 – Mining Discriminative Components with Random Forests

Paper · 2014 · Lukas Bossard, Matthieu Guillaumin and Luc Van Gool

**Authors:** Lukas Bossard, Matthieu Guillaumin and [Luc Van Gool](https://md.research.elamur.ai/free/en/authors/luc-van-gool/) · **Year:** 2014 · **Venue:** Lecture notes in computer science · **Licence:** other-oa per OpenAlex (not a CC licence; rights reserved) — text kept private

Lecture notes in computer science

- [PDF](https://lirias.kuleuven.be/retrieve/949e26d4-9274-42b6-9a14-30cfd2daee35)
- [DOI 10.1007/978-3-319-10599-4_29](https://doi.org/10.1007/978-3-319-10599-4_29)

## Summary

A photograph can show enough of a dish to recognize it even when the serving looks different from anything seen before. A few strawberries, the texture of fried rice, or the shape of a dumpling can carry much of the evidence. The challenge is learning which regions matter when the available labels name whole dishes and give no directions about where to look. The Food-101 paper addresses that challenge with a method for discovering useful regions and a public benchmark for testing how well those regions support recognition.

The benchmark contains 101’000 photos across 101 dish categories, drawn from the food-sharing site Foodspotting. Each category has 750 training images and 250 test images. The authors manually cleaned the test images and deliberately left noise in the training collection, including occasional wrong labels and unusually intense colors. The resulting task combines variation within dishes, such as differences in preparation, lighting, and camera angle, with visual resemblance between dishes. It asks a system to assign a dish label to a photo.

The recognition method begins by grouping neighboring pixels into regions of similar appearance, called superpixels. Each region initially inherits the label of its source photo. A random forest, a collection of decision trees, uses those weak labels to group regions and identify groups that help separate the dish categories. The authors keep distinctive groups, remove near-duplicates, and train a separate detector for each selected component. For an unseen image, those detectors score its superpixels. A final classifier uses the pattern of responses across the image to choose a dish. The forest does its work during discovery and is discarded before recognition.

On the Food-101 test set, the method reaches 50.76% average accuracy. Global classification with Improved Fisher Vectors reaches 38.88%, and an earlier part-mining approach adapted to the same kind of regions reaches 42.63%. A convolutional neural network leads the comparison at 56.40%. Experiments on indoor scenes show that the discovery method can also find useful regions outside food photography, although the strongest published indoor results in the comparison remain higher. The evidence is strongest for the combination of region selection, explicit detectors, and image-level classification. The accompanying pictures show what some of those detectors respond to, while the benchmark measures whether the resulting evidence leads to a correct dish name.

## Deep dive: Food-101 – Mining Discriminative Components with Random Forests

Food-101 introduces a benchmark for recognizing dishes in photos and uses random forests to discover the image regions that help tell them apart. · about 36 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

#### A dish can keep its identity while changing its appearance

Food photographs pose an awkward recognition problem. A prepared dish has a name that persists across different servings, yet its visible structure can change substantially. A recipe may be realized differently, ingredients can be mixed or covered, and the appearance changes again with the camera angle or illumination. A mixed salad illustrates the difficulty. The components that give it a recognizable appearance can lie in different places or partly hide one another. The authors contrast that freedom with scenes that have recurring large-scale organization and objects whose parts tend to occupy recognizable positions relative to each other.

The same variability can make two dish categories look alike in a photograph. A name can encode a distinction that is easy to make with a recipe or a menu in hand, while the corresponding visual evidence is confined to a texture, a garnish, or a small piece of the serving. The paper points to the color and texture of local regions as sources of evidence that can survive changes in presentation. Such evidence can take different forms. The appearance of a whole dumpling may be distinctive, while the useful part of a meat dish may be an area with a particular texture.

The question is how to learn those clues on the scale of a collection of food photographs. The site from which the authors gathered their data supplied dish names and photos from people recording what they ate. A dish name can serve as supervision for the whole image. It leaves open whether a particular patch contains the food, a plate, or something farther in the background. It also leaves open whether a patch of food is a reliable sign of the named dish or something shared by many dishes. The paper makes that uncertainty part of the learning problem.

The authors motivate dish recognition with photo organization and access to large online collections. They also point to work that used mobile photographs to help estimate and track food intake, with people supplying the food labels. In that setting, recognition could address part of the work involved in describing what was eaten. The task the paper sets up is narrower than the application. Its output is a dish category, and its evaluation asks whether that category agrees with the image label. Estimating an amount or determining a recipe would require additional evidence.

#### How earlier classifiers represented an image

In the classical pipeline the paper describes, a system first measures appearance in many small neighborhoods. An interest-point descriptor summarizes the look of a neighborhood around a detected feature, and dense sampling makes similar measurements at regularly spaced locations. An encoding step converts the collection of local measurements into a vector for an image or a portion of it. A support vector machine, or SVM, then uses those vectors to learn a decision rule for the categories.

A bag-of-words representation follows this pattern by building a vocabulary of recurring visual measurements and counting their occurrences. The words in this vocabulary are visual prototypes. A count records the presence of appearances similar to a prototype. A spatial pyramid divides the image into regions at different levels of detail and keeps separate summaries for those regions. A measurement from the upper part of an image can then contribute differently from a similar measurement farther down, while a coarse summary still captures what appears across the image.

The authors also discuss Fisher Vectors, which encode richer information about how local measurements relate to a learned visual vocabulary. This matters to the design of their experiments because Improved Fisher Vectors appear in two roles. They provide an alternative way to summarize appearance for a global classifier, and they help describe individual regions inside the proposed system. A comparison between the systems therefore asks what happens when a strong encoding is put to work at different points in the recognition pipeline.

Some earlier food-recognition work combined features or focused on a particular collection of dishes. The authors describe studies using private Japanese and Chinese food data and work that pooled features locally using deformable parts. They also discuss learning pairwise spatial relationships between ingredients. Such relationships can carry information when meals are presented in a standardized way. The motivating examples for Food-101 give more freedom to the arrangement, so the authors look for local evidence that can be useful across different placements.

#### How earlier systems discovered parts

The paper situates its approach among methods for finding mid-level visual parts. A part in this setting is an appearance pattern located between a low-level descriptor and a whole image. A local descriptor might record the distribution of gradients in a small neighborhood. A learned part can respond to a larger region with a characteristic shape, color, or texture. It earns its place in the recognition system through its usefulness for distinguishing categories, and it need never receive a human name.

Earlier approaches in the paper search for these parts in several ways. Some begin with candidate patches and measure how well the detectors trained from them perform on held-out data. Others build clusters through multiple-instance learning, where the supervision applies to a collection of patches and the useful individual patches have to be discovered. Still others optimize detectors with latent assignments, search for distinctive patterns in gradient features, or start with many individual exemplars. These are different answers to the same practical questions. Which candidate regions deserve their own detectors, and where should those detectors look in a new photograph?

The paper changes the search at both points. For discovery, it uses a multiclass forest to generate groups of candidate patches in a shared procedure. The evidence from other dish categories enters the search from the start because the trees look for splits that improve class separation. A group can subsequently interest more than one category, with a different detector trained for each category that selects it. For recognition, the authors choose candidate locations from an image segmentation. The approach borrows the idea of using image structure to guide where to look, as the paper notes in discussing region-based object detection. [Rich feature hierarchies for accurate object detection and semantic segmentation](https://md.research.elamur.ai/free/en/papers/girshick-2013-rich-feature-hierarchies-accurate-object/)

A sliding-window detector visits positions and scales laid out in advance. Inspecting many windows provides broad coverage but makes every extra detector and every richer feature more expensive. A superpixel offers a smaller search space and follows some of the visible boundaries in the image. That choice creates an opportunity to spend more computation describing each candidate. It also ties the kind of evidence the system can find to the segmentation, a tradeoff that matters when interpreting the experiments.

#### Why the collection mattered

Earlier food datasets offered different kinds of evidence about recognition. The authors describe closed collections that researchers could use for their own studies and a public Pittsburgh fast-food dataset made with standardized meals in a laboratory. Each of the 101 classes in the Pittsburgh dataset contains three instances, with eight images for each instance. Multiple views can test whether a system recognizes a given kind of meal across photographs. Repeated views of a small set of servings offer a different test from user-submitted pictures that can vary in the preparation itself.

Food-101 brings the recognition question into that second setting. The authors use popular dishes with consistent names to establish a defined set of categories, then work with the variation that comes with the photos. The data and the region-mining method address connected problems. A public [evaluation benchmark](https://md.research.elamur.ai/free/en/topics/evaluation-benchmarks/) supports comparisons across classifiers, while weak supervision makes it possible to search the training collection for useful visual evidence without tracing ingredients or drawing region boundaries by hand.

### The method, step by step

#### From an image label to a regional cue

The method has a discovery phase and a recognition phase. During discovery, each training image supplies a collection of regions, along with the common dish label those regions inherit. The forest learns to separate regions using their appearance and those inherited labels. Its terminal groups become candidates for components. A separate set of regions lets the authors measure how reliably the forest recognizes the examples that fall in each group. The top groups, after duplicate removal, supply training examples for explicit component detectors.

Recognition starts afresh with the pixels of an image. The segmentation and region descriptors put the new image into the same form as the training images. The learned component detectors measure how strongly each region resembles the examples supporting each component. Those responses are averaged over spatial regions and passed to a final classifier. The final classifier can use a pattern of responses from across the component vocabulary, including detectors whose positives came from different categories.

From labeled training photos to dish predictions The steps in order.

#### Turn each photograph into candidate regions

A superpixel is a group of neighboring pixels obtained by segmenting the image. The authors use a graph-based method, which treats segmentation as a grouping problem informed by local appearance. A candidate is therefore a region with an irregular outline that can follow a patch of color or texture. In the reported implementation, a segmentation setting of σ = 0.1, k = 300, and a minimum region size of 1% of the image area gives around 30 superpixels per image. Here σ and k name the settings of the segmentation algorithm. The minimum size sets the lower bound on the area of a superpixel relative to its image.

For food, one benefit of the region-based search is that it can put a detector on a coherent area even if that area occupies an unexpected location. The segmentation can also split an ingredient into several regions or group it with nearby material. During feature extraction, the authors include information from the superpixel's bounding box, the enclosing rectangle. This gives the representation some visual context beyond the irregular region itself. The procedure still evaluates a bounded collection of candidates tied to the segmentation.

Each candidate receives measurements of local appearance and color. The appearance channel uses densely sampled [SURF](https://md.research.elamur.ai/free/en/papers/bay-2006-surf-speeded-up-robust-features/) descriptors, with a signed square-root transformation that changes the magnitude of the descriptor entries while retaining their signs. Dense sampling supplies measurements throughout a region. The color channel uses L*a*b values, which express lightness and color through separate coordinates. Keeping both channels gives the detector a way to distinguish regions with similar structure and different colors, or regions with similar colors and different local patterns.

The authors whiten both feature channels with principal component analysis. Whitening changes the coordinates in which the local measurements are represented and rescales them according to their variation. They use Improved Fisher Vector encoding through VLFeat and a Gaussian mixture with 64 modes. The mixture serves as a vocabulary of recurring feature patterns. A Fisher Vector records how the local measurements of a region relate to the mixture, giving a fixed-length representation suitable for a linear decision function. The encoded appearance and color channels are concatenated into a dense region vector with 8’576 values.

Throughout discovery, that vector describes what a region looks like. The inherited image label describes the dish with which the region happened to occur. The correspondence can be strong, weak, or accidental. A local view of a dumpling may be useful evidence for the dumpling category. A region showing a neutral background could have the very same inherited label for completely different reasons. The forest uses many examples and repeated splits to find where appearance and label tend to agree.

#### Grow trees using the dish labels

A decision tree repeatedly divides the region examples. It starts with a sample of the available training regions and chooses an appearance test that sends each region down one of two branches. Each branch then gets its own appearance test. Regions gathered at a terminal node, or leaf, have taken the same route through that tree. They form a candidate group whose members share the appearance properties used on that route. A random forest repeats the procedure on randomly drawn samples and with different candidate tests, producing several ways to group the same kinds of regions.

The forest and its training examples can be written as follows.

```
F = {Tₜ}
```

F is the forest, Tₜ is the tree indexed by t, and braces indicate the collection of trees. Each tree receives its own random draw of superpixels.

```
S = {sᵢ = (xᵢ, y)}
```

S is a set of region examples. The index i identifies an example sᵢ. The pair consists of xᵢ, the appearance vector for that example, and y, the class label inherited from its source image. The paper writes y without an index in the pair, although the inherited label can differ from example to example. Each xᵢ belongs to a real-valued feature space with d dimensions, where d is the number of entries in the vector.

At a node, the authors try binary tests based on linear SVMs. To obtain a candidate test, they randomly assign the dish categories present at the node to binary groups and train a classifier to distinguish those groups. All examples of a dish category at that node receive the same binary assignment for that candidate. Another draw can put the same category on a different side and pair it with different categories. The binary assignment is a device for proposing a split, while the quality of the split is measured using the original dish labels.

```
φ(x) = 𝟙[wᵀx + b > 0]
```

Here φ is the binary routing function, x is a region's feature vector, w is the vector of learned weights, and wᵀx is the dot product of the weights and the features. The scalar b is the offset, and 𝟙 is an indicator. The brackets contain the test of whether the linear score exceeds 0. The function returns 1 when the condition holds and 0 otherwise. The outcomes route the region to different child nodes.

A promising split yields children whose labels are more concentrated than those of their parent. A node with a mixture of many dish labels is harder to interpret as a source of distinctive parts. A child dominated by fewer dish labels offers a more promising place to continue searching. Entropy is the paper's measure of how mixed the labels are. The training criterion measures the reduction in entropy after the split.

```
I(S, φ) = H(S) − (|Sₗ|/|S|) H(Sₗ) − (|Sᵣ|/|S|) H(Sᵣ)
```

I is information gain for the sample set S under the candidate routing test φ. H gives the entropy of the original dish labels in the set passed to it. Sₗ and Sᵣ are the subsets that go to the left and right child, respectively. The vertical bars give set sizes, so each child entropy is weighted by the fraction of parent examples sent there. The minus signs subtract the weighted child entropies from the parent entropy. The weighting makes the size of each child matter when assessing how much label uncertainty the split removes.

This criterion is what makes the forest a supervised search for region groups. A split based purely on appearance similarity might create a coherent collection of pale surfaces that occur in nearly every category. The information-gain criterion rewards an appearance boundary to the extent that it makes the dish labels easier to separate. The tree can still produce ambiguous groups because each example has only its parent image's label, sample counts become smaller deeper in a tree, and candidate tests vary by random draw. The next stage checks the groups against held-out examples.

The authors start with about 2.4 million training superpixels and draw 200’000 of them for validation of the mining procedure. Each tree grows on 200’000 randomly selected regions from the remaining 2.2 million. At each node they generate 100 candidate binary partitions. Each candidate SVM is trained with at most 20’000 superpixels, and the candidate with the highest information gain is kept. Splitting also stops at the chosen depth limit, when a node has fewer than 25 examples, or when its remaining examples all have the same class label. These are training controls for the forest, distinct from the number of detectors ultimately evaluated in a photograph.

```
L = ⋃ₜ Lₜ
```

L holds the candidate leaves from all trees. Lₜ is the collection of leaves of tree Tₜ, t ranges over the trees, and ⋃ is the union operator. Each leaf is identified by its place in its own tree. Different leaves can contain very similar groups even though the trees were trained independently.

#### Use validation regions to rank the leaves

Each leaf gets a distribution over dish labels from its training examples. A validation region is passed through every tree, reaching a leaf in each. The collection of distributions from those leaves indicates what the forest has learned about the region's appearance. A region that repeatedly arrives in groups dominated by the same dish receives a high confidence score for that category. A region that arrives in groups with less concentrated or inconsistent label distributions gives weaker evidence for individual categories.

```
p(y ∣ s) = (1/|F|) ∑ₗ∈L δₗ,ₛ p(y ∣ l)
```

Here s is a validation region, y is a dish category, and p(y ∣ s) is the forest's confidence for that category on the region. The vertical stroke in p(y ∣ s) reads as “given.” The set L contains the leaves of the forest F, and l denotes a particular leaf in the sum. The term p(y ∣ l) is the empirical frequency of class y among the training examples in l. The indicator δₗ,ₛ is 1 if region s reaches leaf l and 0 otherwise. The weight 1/|F| divides the sum by the number of trees. Since the region reaches one terminal group per tree, the equation averages the distributions of the leaves it visits.

This use of the forest differs from taking its confidence as the final dish prediction. The confidence score helps judge how distinctive each validation example is. The next calculation asks which leaves collect many regions with strong evidence for a given dish. A leaf benefits from repeated examples that the forest as a whole finds convincing. A small group can be very pure by its own training counts, yet receive little support from the rest of the forest or from the number of validation regions that reach it.

```
distinctiveness(l ∣ y) = ∑ₛ δₗ,ₛ p(y ∣ s)
```

The left side is the distinctiveness score of leaf l for category y. The summation index s runs over the validation regions used in the calculation. The indicator δₗ,ₛ restricts contributions to regions routed to l. Each such region contributes its forest confidence p(y ∣ s) for category y. The expression is a sum, so the score reflects both how much confidence the contributing regions carry and how many of them the leaf collects.

The distinction between the two equations is important. A region earns its confidence from several trees. A leaf earns its ranking from the regions that visit it. The forest therefore lets the authors use agreement across trees to assess a candidate group inside a particular tree. Since the score is computed for a category, the same grouping can receive different distinctiveness scores depending on which dish is under consideration.

The authors sort the candidate leaves by distinctiveness and apply a form of non-maximum suppression. They skip a weaker candidate when it shares more than half of its superpixels with a better-scoring leaf. Overlap here is between the members of the groups. It concerns whether two leaves found much the same set of examples, as opposed to whether two region outlines overlap in a single photograph. Keeping the stronger group preserves a useful candidate while leaving room in the component budget for other appearances.

This procedure gives diversity a specific role. If several trees find a distinctive cluster of almost the same examples, the agreement helps those examples receive strong confidence. Retaining every copy would spend multiple detector slots on similar cues. The selection rule uses the evidence of repetition to rank the candidate while trying to prevent repetition in the final collection. The chosen groups become the training material for the next stage.

#### Fit detectors to the components that survived

The system keeps the top N leaves for each class after selection. N is the component budget per category. Each selected leaf supplies examples for a linear binary SVM dedicated to its component. The positive examples are the most confident regions of the relevant dish category that belong to that leaf. The negative examples come from a large pool of regions. The task of this SVM is to respond to a particular appearance associated with a dish, at the level of a superpixel and its context.

The paper uses iterative hard-negative mining to make this stage practical. A hard negative is an example from the negative pool that the detector finds difficult to distinguish from its positives. An iteration concentrates training on such examples, which add information about where the detector's decision boundary is currently too permissive. The authors can work with a large negative repository while focusing the training iterations on informative cases.

A leaf can be chosen for more than one dish. When it is, the detector for each dish takes its positives only from examples carrying that dish's label. This is where shared grouping and class-specific recognition meet. The trees can discover an appearance neighborhood useful for different distinctions, and the individual detectors can learn separate boundaries using the positives relevant to each category. A component's identity thus comes from both the appearance group and the category for which it was selected.

After this stage the forest is discarded. A new photograph never needs a route through the trees or a vote from their leaves. The selected detectors provide the link between what the forest discovered during training and what the image classifier can see during recognition. Their scores describe the degree of match to learned regional appearances, rather than a direct frequency of dish labels in a forest leaf.

#### Turn regional detector scores into a dish decision

For a new photograph, the system uses the same kind of segmentation and encoding as it used to create the training regions. It evaluates the component detectors on the resulting superpixels. Every superpixel acquires a vector of detector responses. Some entries can be strong even when the corresponding category is ultimately wrong. A texture resembling one found in a particular dish may also appear in a different dish or in the background. The image-level stage learns how to use the responses together.

```
K × N
```

K is the number of dish categories, N is the number of components selected for each category, and multiplication gives the number of component scores for each superpixel. This is the length of the region's response vector before responses are grouped spatially.

The authors organize those responses with a spatial pyramid of 3 levels. The coarser regions retain evidence across large portions of the image. The finer regions preserve some information about where evidence occurs. A superpixel contributes its complete score vector to every spatial region it meets. The method then averages the scores separately in each region. A large superpixel that crosses a spatial boundary can therefore supply evidence on both sides, and its contribution does not need to be apportioned by a fractional overlap weight.

Averaging makes these pooled scores depend on the set of regions supporting a component within a spatial cell. A strongly responding patch can raise the average, and other patches in the cell can dilute that response. The resulting descriptor records coarse location and the collective response to each component. The classifier can learn how much weight to give that evidence for different dish labels. The paper reports that the loose assignment of superpixels to spatial cells worked better for food recognition than the more elaborate assignments the authors considered.

The final decision is learned with a structured-output multiclass SVM. A binary component detector handles one localized appearance pattern. The multiclass SVM handles the whole image and learns to score the possible dish labels using the pooled representation. The authors use DLib's implementation of an optimized cutting-plane training algorithm. The complete setup, called Random Forest Discriminant Components, or RFDC, uses the multiclass forest to discover the vocabulary of local evidence and the final SVM to turn that evidence into a prediction.

### Experiments and results

#### How Food-101 was assembled and scored

The authors drew Food-101 from Foodspotting, where users shared photos and identified what they were eating. They chose 101 popular dishes whose names were used consistently enough to define categories. For each category they randomly sampled 750 images for training and collected 250 for testing. The test collection was manually cleaned. The training collection retained problems such as wrong labels and unusually intense colors, so the setup measures how well the recognition methods can learn from imperfect user uploads. Smaller images were left out, and the remaining images were resized so their longest side was at most 512 pixels.

The labels cover dishes with widely different appearances as well as dishes with plausible visual overlap. The authors give examples ranging from escargots and sashimi to apple pie and waffles. Comparisons among categories such as paella and risotto help explain the demand placed on the classifier. Recognizing the broad kind of food in a photo can still leave the exact benchmark label unresolved. The recognition problem is also affected by the appearance variation among examples that belong to the same category.

Food-101 results use average accuracy, defined in the paper as the fraction of test images assigned the correct class. Every class contributes the same number of test images. The reported score therefore reflects the fixed category balance of the benchmark. The final Food-101 comparison uses 30 trees with a maximum depth of 5 for RFDC, keeping 20 components per category and 500 positive examples per component. Those settings belong to the comparison with alternative systems. The parameter and feature experiments use a different reference configuration.

#### What the Food-101 baselines test

The global bag-of-words baseline quantizes dense SURF descriptors with a vocabulary of 1024 clusters learned by k-means. It combines the resulting visual-word histograms using a spatial pyramid with 3 levels and trains a multiclass SVM on the pooled features. The global Improved Fisher Vector baseline uses a stronger encoding, again with spatial pooling and a multiclass SVM. These baselines show how far an image representation can go when it represents local measurements through a common encoding and lets the image classifier learn the category decision.

A direct random forest baseline instead predicts from the leaf distributions already available during mining. It adds the category confidence scores across the superpixels and picks the class with the highest total. This setup is especially informative because it asks what can be achieved with the forest's region judgments alone. The forest is trained to route patches by label information and can be applied as a classifier in its own right. Here the image decision uses that classifier's ordinary confidence values.

```
y∗ = argmaxᵧ ∑ₛᵢ∈I p(y ∣ sᵢ)
```

In this baseline rule, y∗ is the predicted dish category, and argmaxᵧ selects the category y with the greatest sum. The image I is represented by its set of superpixels, sᵢ denotes the superpixel indexed by i, and the membership condition limits the sum to the regions of that image. The term p(y ∣ sᵢ) is the forest confidence for category y on superpixel sᵢ, from the average of the reached leaf distributions.

The randomized clustering forest comparison uses the trained forest to build image features and learns a multiclass SVM on top. This gives the image classifier an opportunity to learn a decision from information encoded by the forest. It still uses a different intermediate representation from RFDC, whose features come from individually trained detectors for selected groups. The two forest baselines therefore approach the same question from different sides. One combines the forest's scores directly, while the other adds a learned image classifier to a forest-derived representation.

Mid-Level Discriminative Superpixels, or MLDS, adapts an earlier discovery method to superpixels. The authors substitute those regions for the earlier sliding gradient-feature patches and use the same image classification stage as RFDC. For each class the discovery pool contains around 22’500 superpixels. The negative pool contains 500’000 randomly selected superpixels. The adaptation initializes groups with k-means using a clusters-to-samples ratio of 1/3, runs discovery for at most 10 iterations, and fits each SVM to its top 10 members. It then keeps 20 components per class. This comparison puts a different candidate discovery procedure in a pipeline with a similar type of local evidence and the same final pooling and classification scheme.

The convolutional neural network supplies a separate comparison. The authors train a deep network on Food-101 using the Caffe implementation of the architecture from earlier image classification work. They report convergence at 450’000 iterations. This system learns image representations and predicts labels through its convolutional architecture, giving an accuracy comparison with a different approach to visual recognition. [ImageNet Classification with Deep Convolutional Neural Networks](https://md.research.elamur.ai/free/en/papers/krizhevsky-2012-imagenet-classification-deep-convolutional/)

#### How the systems rank on Food-101

Food-101 test accuracy by classification method RFDC leads the feature-based comparisons, and the convolutional network has the highest accuracy overall.

**The numbers**

| System or setting | average accuracy % |
| --- | --- |
| Global bag of words | 28.51 |
| Global Improved Fisher Vectors | 38.88 |
| Direct random forest | 32.72 |
| Randomized clustering forest | 28.46 |
| Mid-Level Discriminative Superpixels | 42.63 |
| RFDC (this paper) | 50.76 |
| Convolutional neural network | 56.40 |

The global Improved Fisher Vector classifier reaches 38.88% average test accuracy, ahead of the bag-of-words baseline at 28.51%. The difference in ordering matters because it establishes a stronger global comparison for the proposed method. Treating a weak encoding as the only global baseline would give little evidence about the value of explicit components. The stronger encoding improves the global classifier substantially, and the region-based results can then be read against that improved reference.

MLDS reaches 42.63% average test accuracy, showing that the usefulness of regional detectors extends to another mining procedure. RFDC reaches 50.76%, which the paper reports as gains of 8.13% over MLDS and 11.88% over global Improved Fisher Vectors. Those reported gaps are on the accuracy scale. The direct forest obtains 32.72%, and the randomized clustering forest obtains 28.46%. A forest used as a source of candidate groups can therefore support a stronger classifier than either of the ways the authors try to classify images from the forest's intermediate information.

The convolutional network reaches 56.40% average Food-101 test accuracy. The authors report its lead over RFDC as 5.64% and give a training time of six days on an NVIDIA Tesla K20X. That comparison establishes the accuracy ranking and gives a sense of the training effort for the network in the reported setup. The paper also gives timings for the RFDC pipeline in its discussion of the indoor experiments. Those timings use different hardware and conditions, so the results describe the reported systems in their own measurement settings.

The class-level comparison shows another side of the average. The authors display the 10 best and 10 worst classes for the component method, the 11 classes with the strongest gains over global Improved Fisher Vectors, and 8 additional classes where performance fell. In this selection, the positive shifts are more pronounced than the declines. The averages describe the whole test set. The selected categories show that changing the representation can affect classes differently, even when the overall result favors components.

#### What happens on indoor scenes

The MIT-Indoor experiment takes the method beyond dish classification. The same broad procedure applies because it requires image labels and visual regions. A tree can search for regions useful in separating scene categories just as it searches for regions associated with dish categories. In the indoor implementation the authors use 100’000 samples per tree's training bag and add horizontally flipped versions of the training photos. They report results with 50 components per class.

The study uses the original restricted protocol, assigning approximately 80 images in each category to training and 20 to testing. It also trains on the full collection of available training images and measures accuracy on the original test set. RFDC reaches 54.40% average accuracy with restricted training and 58.36% with full training. These are two evaluations on the same test set with different amounts of training data, a distinction that matters when reading either figure alongside results from other systems.

Average accuracy of selected methods on the MIT-Indoor test set RFDC improves with the full training set, while the strongest published comparison combines local and global evidence.

**The numbers**

| System or setting | average accuracy % |
| --- | --- |
| Discriminative Patches | 38.10 |
| Bags of Parts | 46.10 |
| Discriminative Parts | 51.40 |
| RFDC restricted training (this paper) | 54.40 |
| RFDC full training | 58.36 |
| Discriminative Mode Seeking | 64.03 |
| Global Improved Fisher Vectors | 60.77 |
| Improved Fisher Vectors with Discriminative Mode Seeking | 66.87 |

Among the other published part methods in the paper's comparison, the multiple-instance SVM obtains 46.40% average accuracy and maximum-margin multiple-instance dictionary learning obtains 50.15%. The combination of Improved Fisher Vectors with Bags of Parts reaches 63.10%. Discriminative Mode Seeking reaches 64.03% as a part-based entry, and its combination with global Improved Fisher Vectors gives the highest reported result in the comparison at 66.87%. The restricted and full RFDC runs show where the proposed approach stands when the training set changes. The published entries also differ in region search, features, and the number of components.

The strongest part-based comparator uses 200 components per class and evaluates multiscale sliding windows with gradient features. RFDC uses 50 components per class in the indoor experiment and usually considers 30 superpixels per image. The authors connect the smaller set of locations to their ability to afford a richer descriptor per location. The evidence from the indoor benchmark supports the method's applicability to a second recognition task and places its accuracy among the published part approaches, with the strongest indoor comparisons still ahead.

The indoor discussion reports a complete pipeline cost of around 250 CPU hours, including vocabulary learning and data handling. Roughly 55% goes to forest training, 15% to training component detectors, and 20% to the final classifier. The authors point out that segmentation, feature extraction, encoding, and individual tree training offer opportunities for parallel execution. They also report classification at around 0.8 seconds per image using 8 cores, including feature extraction and Fisher encoding. Encoding accounts for 70% of that time and part evaluation for 25%. Even with a small collection of candidate regions, preparing the features is a substantial part of the cost.

### What the ablations show

#### The forest settings have a broad workable range

The parameter study changes one setting at a time on Food-101. Its reference configuration uses 30 trees, mines at depth 7, retains 20 components per category, and trains each detector with its 100 most confident positive examples. This reference configuration establishes the conditions under which the parameter trends and feature results were measured. The comparison across complete recognition systems uses the separate configuration described above.

Increasing the forest from 10 to 30 trees makes little difference in the reported test accuracy. Greater depth has little influence beyond 4 levels. These trends matter because more trees and deeper trees can increase the amount of candidate discovery work. In the ranges studied, the final classifier appears able to exploit a useful pool of region groups without continual gains from enlarging the forest. The result concerns the accuracy of the complete recognition pipeline. It does not measure how similar the individual leaves or detectors discovered under different settings are.

Giving each detector more positive examples does improve recognition, with the experiment showing a plateau beyond 200 positives. The authors also report that using 200 helps speed up training. The trend fits the role of the detector as a classifier for a recurring appearance. More positives can expose it to variation within a candidate group, but eventually the additional examples in this setup add little to the final decisions. That plateau is measured for the studied configuration and feature representation.

Adding more components per dish also improves accuracy with diminishing returns. The authors highlight the cost after 20 components per class. With spatial pooling, the image descriptor has 42’420 dimensions for 20 components per class and 106’050 dimensions for 50. A new component adds response dimensions throughout the spatial representation, so its cost persists after detector evaluation. The study shows why a modest increase in accuracy can have a sizable effect on memory and speed.

#### The descriptor changes what a component can recognize

The feature comparison holds the mining setup fixed and changes how the regions are described. HOG, a histogram of oriented gradients, describes the distribution of local edges. The authors resize the patches to 64 × 64 pixels for this condition. Bag-of-words and Improved Fisher Vector conditions instead use the appearance and color channels with the vocabulary sizes specified in the comparison. The resulting scores show how strongly the discovery pipeline depends on the visual evidence made available to its trees and detectors.

Food-101 test accuracy with different RFDC region descriptors Improved Fisher Vectors of appearance and color give the highest accuracy in the feature comparison.

**The numbers**

| System or setting | average accuracy % |
| --- | --- |
| HOG | 8.85 |
| Bag of words with SURF at 1024 | 33.47 |
| Bag of words with SURF at 1024 and color at 256 | 38.83 |
| Improved Fisher Vectors with SURF at 64 | 44.79 |
| Improved Fisher Vectors with color at 64 | 14.24 |
| Improved Fisher Vectors with SURF at 64 and color at 64 (this paper) | 49.40 |

HOG gives 8.85% average test accuracy in this RFDC feature experiment. The authors suggest that gradient patterns in the resized food patches can be too specific to make useful descriptions of recurring parts. SURF with bag-of-words encoding reaches 33.47%, rising to 38.83% when the encoding includes color. The stand-alone Improved Fisher Vector color channel gives 14.24%. With Improved Fisher Vectors, SURF gives 44.79%, and the combined appearance and color channels reach 49.40%.

The color results show how a weak source of evidence in isolation can still help when paired with a stronger one. Color by itself can group many regions from different dishes, yet it can sharpen distinctions between regions with otherwise similar appearance descriptors. The comparison also shows higher scores for the reported Fisher encodings than for the corresponding bag-of-words configurations that use SURF. Vocabulary sizes differ across those conditions, so the evidence is about the complete descriptor settings evaluated by the authors.

The 49.40% result belongs to the feature experiment. The 50.76% result comes from the main comparison, with different training settings. Keeping the two contexts visible helps a reader understand why the same method with the same broad choice of channels can have different reported accuracies. The paper reports limited effects from changes in the segmentation parameters and a benefit from including bounding-box context. It also favors loose spatial assignment of superpixels. The detailed numerical comparison here is the one for descriptors, while those other observations are described without parallel sets of scores.

#### What can be inferred from the alternative uses of a forest

The direct forest and randomized clustering forest baselines help locate where the full pipeline adds value. The direct baseline exposes every image decision to the class distributions in the reached leaves. If a photograph contains many regions whose leaf distributions are noisy, summing can retain that ambiguity. The complete method selects groups with evidence of distinctiveness and then fits dedicated detectors. The randomized clustering forest baseline already uses an image-level classifier. Its lower score indicates that adding an SVM on top of forest-derived features was insufficient to reproduce the behavior of the learned component representation in this experiment.

These comparisons change several ingredients together. They support the combined value of selecting groups, training dedicated detectors, and aggregating their responses for a whole-image decision. They leave the separate contribution of each ingredient less certain. For example, the main result does not give a test score for the same component pipeline with duplicate suppression switched off. The rationale for that rule follows from the overlap of independently discovered groups and the finite budget of detectors.

The MLDS comparison offers a tighter perspective on discovery because it uses superpixels and the same final classification procedure. Its result leaves room for the forest-guided search to matter even when region-based evaluation is available to both methods. The procedures nevertheless differ in how they generate candidates and how they train and select detectors. The performance gap measures the difference between those configured discovery pipelines. A narrower comparison would be needed to assign it to a single scoring rule or a single choice about positive examples.

#### What the pictures reveal about successes and errors

The figures show examples of the regions selected for different dishes. Several are easy to connect to visible elements of the food. A fruit topping appears among cheesecake components, and regions for strawberry shortcake include strawberries. Other examples emphasize surfaces and textures, as with spaghetti carbonara, fried rice, and meat. The component discovery procedure can produce both kinds of evidence from the same representation and image-level training labels.

The authors also visualize aggregate class responses on superpixels as heat maps. For correct classifications, they compare the response for the true dish with the response for the next most confident category. For errors, they show the predicted and true categories. These pairs make it possible to see that the same photo can support competing classifications in different places, or that a prominent region can have an appearance the system associates more strongly with another dish. The visualizations show selected behavior and help connect the image representation to particular examples.

The illustrated confusions include onion rings versus french fries and carrot cake versus chocolate cake. Those pairs fit the problem that motivates the paper. Local similarities can make a detector fire on a region from a competing dish. Other examples involve clutter or ambiguous photographs, such as a confusion involving prime rib and spring roll or one involving steak and risotto. The paper presents these cases as qualitative diagnoses. The benchmark metric measures their consequences for classification, while the examples offer a view of how some errors arise.

### Limitations

#### Limits discussed by the authors

The authors identify substantial variation in presentation, recipe, viewpoint, and lighting as properties of the task. They also acknowledge noise in the user-supplied training labels. Those issues affect the mining stage directly because a region inherits its photo's label, even if its own appearance offers little dish information. In discussing the direct forest baseline, the authors suggest that averaging across trees does not adequately compensate for noisy leaves. They also suggest that the intermediate binary representation used by the randomized clustering forest may be too sparse with the available sample counts. These are proposed explanations for the observed baseline results.

The paper reports a limit to gains from enlarging the component vocabulary. Beyond the range where accuracy rises appreciably, more detectors make the pooled representation larger and increase memory and computation. The reported timing also shows that feature encoding remains costly even after the region search is reduced to superpixels. The efficiency claim is specifically about evaluating a small collection of candidates and making richer features practical there. The measured wall time applies to the implementation and hardware the authors describe.

The authors report the accuracy boundaries plainly. The convolutional approach leads on Food-101. On MIT-Indoor, the proposed method trails the strongest part-based entry on the restricted training protocol, and the full training set improves its standing. The paper notes that some alternative indoor systems use external training data or different numbers of components. Together with the differences in features and search, those details make the indoor table a comparison of published systems under their respective setups.

#### Limits visible in the evaluation

The benchmark is defined by a single collection source and by dishes popular enough to supply consistently named photos. Its equal test counts make the fixed comparison clear. Accuracy under that construction leaves open how frequently the same classifier would succeed in a collection with different dish frequencies, different naming conventions, or foods outside the chosen categories. Manual cleaning means the test inputs also represent a different labeling condition from the noisy training images. The study demonstrates learning under that train–test design, without measuring performance at specified levels of label corruption.

The task asks for the correct category from the available dish names. It leaves open how a classifier should respond to a photo with multiple plausible dishes, a preparation outside the benchmark, or a dish whose ingredients are concealed. The dataset labels and accuracy measure give no direct test of ingredient recovery, portions, or nutritional estimates. The food-intake example motivates recognition, but a useful dish label addresses only part of that application.

The spatial representation is similarly bounded. An image segmentation determines which candidate regions are described. The bounding box brings in some surrounding information, and spatial pooling combines detector responses at different levels. Small clues that are poorly represented by the resulting regions can still be missed. Averaging can also dilute an isolated response among many weaker ones. A useful component may cover a texture or a correlated contextual feature, so the evidence for recognizing a dish and the evidence for identifying its physical ingredients remain different.

The validation regions are randomly sampled from the training superpixels. The paper describes that split at region level, leaving open how much validation support comes from distinct source photographs as opposed to different regions of the same photograph. The test-image results are the evidence for recognition on the separate test collection. The validation scores serve to select candidates within the training procedure. They answer a different question from whether a component remains distinctive across new photographers, settings, or preparations.

Finally, the component examples and heat maps are qualitative. Some selected regions resemble recognizable food elements, while the detector training gives the system latitude to learn any recurring appearance that helps the label decision. The figures do not give an estimate of how frequently detected regions correspond to human-identified parts, and the paper does not measure region localization accuracy. The indoor experiment widens the empirical scope to a second dataset. It supports the reuse of the procedure, while leaving the value of the component representation dependent on the categories, available training images, and comparison methods.

### What came after

The subsequent citations connect Food-101 to a broader question about image recognition. The original paper learns a representation for the target task by discovering distinctive regions in its labeled training collection. Later papers ask how visual representations can be learned before a particular downstream task, how improvements carry across tasks, and what changes when visual learning also uses language. The citation records establish those connections at the level of research topics. They leave the individual evaluation protocols and any reuse of forest mining unspecified.

One line of work asks whether progress on a source task carries over to a target task. The question in *Do Better ImageNet Models Transfer Better?* places the emphasis on transfer. Food-101 defines a recognizable target for that kind of question because the outcome is a dish label and the benchmark specifies a training and test division. The original paper's comparison is rooted in approaches to constructing that target representation, from global encodings to supervised component discovery. The transfer question concerns how improvements learned elsewhere relate to downstream recognition. [Do Better ImageNet Models Transfer Better?](https://md.research.elamur.ai/free/en/papers/kornblith-2019-do-better-imagenet-models-transfer/)

EfficientNet addresses the scaling of convolutional networks. The Food-101 paper had already made computational cost visible by reporting detector counts, feature dimensions, and training effort alongside accuracy. Its resource decisions concern trees, superpixels, and component descriptors. EfficientNet puts the scale of the convolutional network itself at the center of its research question. The citation links two studies with different choices about where to spend recognition capacity. [EfficientNet](https://md.research.elamur.ai/free/en/papers/tan-2019-efficientnet-rethinking-model-scaling-convolutional/)

Other citing work addresses how to learn useful visual representations with different sources of supervision. SimCLR presents a contrastive approach to visual representation learning, where the general aim is to learn from comparisons between visual examples. Bootstrap Your Own Latent presents a self-supervised approach. Both bring a different question to the setting established by Food-101. Bossard and colleagues use dish labels directly in the mining criterion, whereas these later research directions focus on how visual features can be learned before the downstream labels enter the task. [SimCLR](https://md.research.elamur.ai/free/en/papers/chen-2020-simple-framework-contrastive-learning-visual/) and [Bootstrap Your Own Latent](https://md.research.elamur.ai/free/en/papers/grill-2020-bootstrap-your-own-latent-new/)

DINOv2 likewise addresses the learning of robust visual features without supervision. Its stated focus connects to a distinction made concrete by the original experiment. A feature representation determines which visual similarities the subsequent classifier can use. In Food-101, the feature comparison varies engineered descriptions of superpixels within a fixed discovery pipeline. In the later work the subject of study is learning the visual features themselves under a different supervision regime. [DINOv2](https://md.research.elamur.ai/free/en/papers/oquab-2023-dinov2-learning-robust-visual-features/)

Research using noisy text supervision takes the question toward [vision and language](https://md.research.elamur.ai/free/en/topics/multimodal/). The Food-101 paper deals with noise in user-submitted dish names while defining a fixed vocabulary of categories for classification. *Scaling Up Visual and Vision-Language Representation Learning With Noisy Text Supervision* studies noisy text as part of a larger representation-learning problem. DataComp addresses the construction of multimodal datasets. These two directions connect to different choices highlighted by the original paper, one about what kind of language can supervise visual learning and the other about how data selection shapes the experiment. [Scaling Up Visual and Vision-Language Representation Learning With Noisy Text Supervision](https://md.research.elamur.ai/free/en/papers/jia-2021-scaling-up-visual-vision-language/) and [DataComp](https://md.research.elamur.ai/free/en/papers/gadre-2023-datacomp-search-next-generation-multimodal/)

Across these citations, the durable connection is the problem Food-101 defines. A dish-recognition result depends on where the representation comes from, what supervisory information it has seen, and what photos count as evidence of success. The original study answers those questions through a noisy training collection, a cleaned test set, and a classifier built from discovered regional cues. The later works address different ways to obtain or assess the visual representation while citing that earlier benchmark paper.

## Cite

Cite as Lukas Bossard, Matthieu Guillaumin and Luc Van Gool. 2014. Food-101 – Mining Discriminative Components with Random Forests. Lecture notes in computer science.

The paper itself, not this page. BibTeX from the library's record of the work. [DOI 10.1007/978-3-319-10599-4_29](https://doi.org/10.1007/978-3-319-10599-4_29)

```bibtex
@inproceedings{bossard2014food,
  title = {{Food-101 – Mining Discriminative Components with Random Forests}},
  author = {Lukas Bossard, Matthieu Guillaumin and Luc {Van Gool}},
  booktitle = {Lecture notes in computer science},
  year = {2014},
  doi = {10.1007/978-3-319-10599-4\_29},
  url = {https://doi.org/10.1007/978-3-319-10599-4_29}
}
```

> 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)
