pandora-s's picture
Update README.md
f0506ea verified
metadata
dataset_info:
  features:
    - name: name
      dtype: string
    - name: country_label
      dtype: string
    - name: category_labels
      struct:
        - name: plant-based-foods
          dtype: string
        - name: cereals-and-potatoes
          dtype: string
        - name: beverages
          dtype: string
        - name: dairies
          dtype: string
        - name: meats-and-their-products
          dtype: string
        - name: sweet-snacks
          dtype: string
        - name: snacks
          dtype: string
        - name: plant-based-foods-and-beverages
          dtype: string
  splits:
    - name: train
      num_bytes: 8953027
      num_examples: 80273
    - name: validation
      num_bytes: 1119856
      num_examples: 10034
    - name: test
      num_bytes: 1119911
      num_examples: 10035
  download_size: 2655136
  dataset_size: 11192794
configs:
  - config_name: default
    data_files:
      - split: train
        path: data/train-*
      - split: validation
        path: data/validation-*
      - split: test
        path: data/test-*

OpenFood Classification

A subset of openfoodfacts/product-database selecting only a balanced set of countries and food categories.

Labels

There are 2 main labels:

  • Country single label: The corresponding country of the food/dish among 8 possible values: italy, spain, germany, france, united-states, belgium, united-kingdom and switzerland.
  • Category multi-label: The category it belongs to among 8 possible values: snacks, beverages, cereals-and-potatoes, plant-based-foods, dairies, plant-based-foods-and-beverages, meats-and-their-products and sweet-snacks.

Dataset

There are 8 countries and 8 different categories. Due to the nature of each label, the dataset is split as follows:

  • name: The name of the food/dish, extracted from the product_name of the openfoodfacts/product-database dataset.
  • country_label: The country ID, extracted from countries_tags of the openfoodfacts/product-database dataset.
  • category_labels: The categories it belongs to, extracted from categories_tags of the openfoodfacts/product-database dataset.

Distribution

image/png Note that the categories overlap each other, since a sample can have multiple categories.

Splits

The dataset was split into 3 sets:

  • train: 80%
  • validation: 10%
  • test: 10%