Logo Annotation Guidelines: Difference between revisions

From Open Food Facts wiki
mNo edit summary
No edit summary
 
(12 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{otherlang
  | fr=FR:Guide d'annotation de logos
}}
[[Category:Artificial Intelligence]]
[[Category:Hunger Games]]
[[File:Logo annotation game.png|alt=|thumb]]
The annotation Web interface is available at: https://hunger.openfoodfacts.org/logos.
The annotation Web interface is available at: https://hunger.openfoodfacts.org/logos.


The goal of the annotation is to provide ground-truth labels that will be used to predict the label of unseen logos.
The goal of the annotation is to provide ground-truth labels that will be used to predict the label of unseen logos.


'''It is extremely important to provide quality annotations, otherwise the predictions won't be qualitative'''.
'''It is extremely important to provide quality annotations, otherwise, the predictions won't be qualitative'''.


If you're not sure of how you should annotate a logo, ask on the Slack, in the #ai-logo-detection channel.
If you're not sure of how you should annotate a logo, ask on Slack, in the #ai-logo-detection channel.


== How to? ==
== How to? ==
1. Open web interface: https://hunger.openfoodfacts.org/logos
1. Open web interface: https://hunger.openfoodfacts.org/logos


2. Select logos to be annotated (click each desired logo whit your mouse)
2. Select logos to be annotated (click each desired logo with your mouse)


3. Fill ''value'' and ''type'' corresponding to the selected logos. Be sure to '''check that the ''value'' and ''type'' are correct before submitting the annotation''' :
3. Fill ''value'' and ''type'' corresponding to the selected logos. Be sure to '''check that the ''value'' and ''type'' are correct before submitting the annotation''' :
* The ''value'' field should only be completed for "brand" and "label" types.
* The ''value'' field should only be completed for "brand" and "label" types.
* The value should match one item in the associated taxonomy, otherwise it won't be used for prediction. The field value is lowercased before saving the annotation.
* The value should match one item in the associated taxonomy, otherwise it won't be used for prediction. The field value is lowercase before saving the annotation.
* Use ''QR code'' type for QR codes, ''Packager code'' for packager codes (code surrounded by a circle), ''Brand'' for brand logos and ''Label'' for label logos.
* Use ''QR code'' type for QR codes, ''Packager code'' for packager codes (code surrounded by a circle), ''Brand'' for brand logos, and ''Label'' for label logos.
 
Example: https://hunger.openfoodfacts.org/logos?logo_id=161643
Here, we should add "label rouge" as value and "label" as type. Server-side, the value is transformed into a tag ("label-rouge") and matched against the taxonomy to associate the real taxonomy ID to the value ("en:label-rouge").


Lang prefixes ("en:", "fr:") should not be added, otherwise the taxonomy match will fail.
For labels and brands, logo annotations will update the product by adding the annotated label or brand. Please note that there is a 5 minutes delay between the annotation and the database update.


Example of '''valid''' values:
Example (label): https://hunger.openfoodfacts.org/logos?logo_id=161643, here, we should add "Label Rouge" as value and "label" as type.
* gluten-free
* volaille française
* auchan
* reflets de france


Example of '''invalid''' values:
Example (brand): https://hunger.openfoodfacts.org/logos?logo_id=444915, here we should add "Rachel's" as value and "brand" as type. Please note there is not yet auto-completion for brand. Server-side, the value is transformed into a tag ("rachel-s") and matched against existing brands in the database. The brand logo annotation is used only if we find a match.
* en:gluten-free
* fr:volaille française
* ab bio (not in taxonomy, the right value is ''ab agriculture biologique'')


'''If more than one logo is visible on the crop, do not annotate it'''. A flag system should be available in the future to report them.
'''If more than one logo is visible on the crop, do not annotate it'''. A flag system should be available in the future to report them.
Line 37: Line 34:
If the logo is truncated, annotate it anyway if it can still be recognized.
If the logo is truncated, annotate it anyway if it can still be recognized.


You can click on the blue link on the top-right corner of each logo card. It will open a new tab with this specific logo as reference. It's really useful to find similar logos to annotate.
You can click on the blue link in the top-right corner of each logo card. It will open a new tab with this specific logo as a reference. It's really useful to find similar logos to annotate.


Query parameters:
Query parameters:
Line 45: Line 42:
For instance, to display 50 results, use: https://hunger.openfoodfacts.org/logos?count=50
For instance, to display 50 results, use: https://hunger.openfoodfacts.org/logos?count=50


== Common labels ==
== Infinite mode ==
 
Once you're confident with the standard logo annotation interface, you can try the more powerful Infinite mode available at: https://hunger.openfoodfacts.org/logos/deep-search
 
The mechanism of Infinite mode annotation is the following:
 
* fetch all logos annotated with a type and value
* for each fetched logo, get the most similar logos without annotations
* display all these unannotated logos
 
This is a very effective mode to annotate logos that already have a few annotations.
 
== Product mode ==
If you want to annotate logos of a specific brand or label but infinite mode does not yield any result (because there is no annotated logos yet), you can try bootstrapping logo annotations with product mode: https://hunger.openfoodfacts.org/logos/product-search


Remembering the right label name may be hard sometimes, so here is a list of common label names you will probably see:
Start selecting a type (label or brand) and a value. All logos of all images of all products that have this brand/label will be displayed. You just need to select relevant logos and annotate them.
* [https://world.openfoodfacts.org/label/fr:viande-porcine-francaise Viande porcine française]
* [https://world.openfoodfacts.org/label/fr:volaille-francaise Volaille Française]
* [https://world.openfoodfacts.org/label/fr:viande-bovine-francaise Viande Bovine Française]
* [https://world.openfoodfacts.org/label/nutriscore-grade-a Nutriscore Grade A]
* [https://world.openfoodfacts.org/label/green-dot Green Dot]
* [https://world.openfoodfacts.org/label/ab-agriculture-biologique AB Agriculture Biologique]
* [https://world.openfoodfacts.org/label/eu-organic EU Organic]
* [https://world.openfoodfacts.org/label/european-vegetarian-union European Vegetarian Union]

Latest revision as of 10:37, 28 December 2022

Other languages
/ français /

The annotation Web interface is available at: https://hunger.openfoodfacts.org/logos.

The goal of the annotation is to provide ground-truth labels that will be used to predict the label of unseen logos.

It is extremely important to provide quality annotations, otherwise, the predictions won't be qualitative.

If you're not sure of how you should annotate a logo, ask on Slack, in the #ai-logo-detection channel.

How to?

1. Open web interface: https://hunger.openfoodfacts.org/logos

2. Select logos to be annotated (click each desired logo with your mouse)

3. Fill value and type corresponding to the selected logos. Be sure to check that the value and type are correct before submitting the annotation :

  • The value field should only be completed for "brand" and "label" types.
  • The value should match one item in the associated taxonomy, otherwise it won't be used for prediction. The field value is lowercase before saving the annotation.
  • Use QR code type for QR codes, Packager code for packager codes (code surrounded by a circle), Brand for brand logos, and Label for label logos.

For labels and brands, logo annotations will update the product by adding the annotated label or brand. Please note that there is a 5 minutes delay between the annotation and the database update.

Example (label): https://hunger.openfoodfacts.org/logos?logo_id=161643, here, we should add "Label Rouge" as value and "label" as type.

Example (brand): https://hunger.openfoodfacts.org/logos?logo_id=444915, here we should add "Rachel's" as value and "brand" as type. Please note there is not yet auto-completion for brand. Server-side, the value is transformed into a tag ("rachel-s") and matched against existing brands in the database. The brand logo annotation is used only if we find a match.

If more than one logo is visible on the crop, do not annotate it. A flag system should be available in the future to report them.

If the logo is truncated, annotate it anyway if it can still be recognized.

You can click on the blue link in the top-right corner of each logo card. It will open a new tab with this specific logo as a reference. It's really useful to find similar logos to annotate.

Query parameters:

  • logo_id: the ID of the logo. If not provided, will be random.
  • count: the number of results to display (default: 25). Useful to annotate many logos at once.

For instance, to display 50 results, use: https://hunger.openfoodfacts.org/logos?count=50

Infinite mode

Once you're confident with the standard logo annotation interface, you can try the more powerful Infinite mode available at: https://hunger.openfoodfacts.org/logos/deep-search

The mechanism of Infinite mode annotation is the following:

  • fetch all logos annotated with a type and value
  • for each fetched logo, get the most similar logos without annotations
  • display all these unannotated logos

This is a very effective mode to annotate logos that already have a few annotations.

Product mode

If you want to annotate logos of a specific brand or label but infinite mode does not yield any result (because there is no annotated logos yet), you can try bootstrapping logo annotations with product mode: https://hunger.openfoodfacts.org/logos/product-search

Start selecting a type (label or brand) and a value. All logos of all images of all products that have this brand/label will be displayed. You just need to select relevant logos and annotate them.