---
metadata:
  - name: generator
    content: Diplodoc Platform v5.50.3
alternate:
  - https://catboost.ai/docs/en/concepts/algorithm-main-stages_embedding-to-numeric.md
---
> **Documentation Index:** Fetch the complete configuration index at https://catboost.ai/docs/en/llms.txt

# Transforming embedding features to numerical features

<!-- source: en/_includes/work_src/reusage-common-phrases/supported-feature-types.md -->
CatBoost supports the following types of features:
- Numerical. Values of such features can be real numbers, positive and negative infinity and `NaN` (the latter represents [missing values](https://catboost.ai/docs/en/concepts/algorithm-missing-values-processing.md)). Examples are the height (<q>182</q>, <q>173</q>), or any binary feature (<q>0</q>, <q>1</q>).

- Categorical (cat). Such features can take one of a limited number of possible values. These values are usually fixed. Examples are the musical genre (<q>rock</q>, <q>indie</q>, <q>pop</q>) and the musical style (<q>dance</q>, <q>classical</q>).

- Text. Such features contain regular text (for example, <q>Music to hear, why hear'st thou music sadly?</q>).

- Embedding. Such features contain arrays of fixed size of numeric values.
<!-- endsource: en/_includes/work_src/reusage-common-phrases/supported-feature-types.md -->


Embedding features are transformed to numerical. The transformation method generally includes the following stages:
1. **Loading and storing embedding features**

    The embedding feature is loaded as a column. Every element in this column is an array of fixed size of numerical values.

    To load embedding features to CatBoost:
    - Specify the NumVector column type in the [column descriptions](https://catboost.ai/docs/en/concepts/input-data_column-descfile.md) file if the dataset is loaded from a file.
    - Use the `embedding_features` parameter in the Python package.

1. **Estimating numerical features**

    Each embedding is transformed to the one or multiple numeric features.

    Supported methods for calculating numerical features:

    - [Linear discriminant analysis](https://en.wikipedia.org/wiki/Linear_discriminant_analysis)
        - For classification the features will be calculated as Gaussian likelihood values for each class.

    - [K Nearest Neighbors](https://en.wikipedia.org/wiki/K-nearest_neighbors_algorithm).
        - For classification the features will be counts of target classes among the found neighbors from the training set.
        - For regression the single feature will be the average target value among the found neighbors from the training set.

1. **Training**

    Computed numerical features are passed to the regular CatBoost training algorithm.
