FEDOT Documentation

repository·master·Indexed 20 days ago

https://github.com/aimclub/fedot

An open-source AutoML framework that automates the design of machine learning pipelines using an evolutionary approach. FEDOT supports classification, regression, clustering, and time series forecasting for text, images, and tabular data. It features a high-level API, a command-line interface (CLI), and a modular architecture including a GraphOptimizer, EvaluationDispatcher, and Tuner. The framework provides tools for hierarchical pipeline construction via AtomizedModel and comprehensive tabular data preprocessing.

Tokens
41K
Snippets
102
Records
149
Agent score
72%

What's inside FEDOT

  1. Core capabilities of the FEDOT framework

    master

    FEDOT is an AutoML framework designed for automating the construction of machine learning solutions. Its core design principles include:

    • Flexibility: Automates solutions for various problems, data types (text, images, tables), and models.
    • Extensibility: Uses data- and task-independent pipeline optimization algorithms, while allowing for special strategies tailored to specific tasks like time-series forecasting, NLP, or tabular data.
    • Integrability: Supports major ML libraries (Scikit-learn, CatBoost, XGBoost, etc.) and allows for the integration of custom libraries.
    • Tuningability: Supports various hyper-parameter tuning methods, including custom evaluation metrics and search spaces.
    • Versatility: Not limited to standard modeling tasks; can be applied to domains like ODE or PDE.
    • Reproducibility: Pipelines can be exported as JSON files or as ZIP archives containing both the pipeline and the input data to ensure experiment reproducibility.
    • Customizability: Enables management of model complexity to achieve specific quality targets.
  2. Explore FEDOT Side Projects and Ecosystem

    master

    FEDOT is part of a broader ecosystem of research and tools. Related projects include:

    • FEDOT.WEB: A prototype web-GUI for FEDOT.
    • GAMLET: A prototype of FEDOT-based meta-AutoML using meta-learning (GNN and RL).
    • FEDOT.LLM: Implementation of Large Language Models for AutoML tasks.
    • GOLEM: An optimization core used to improve algorithms within the FEDOT ecosystem.
  3. Explore FEDOT project structure

    master

    The FEDOT repository is organized into several key directories:

    • fedot/core: The core of the framework, containing main classes and scripts.
    • examples: A collection of usage examples to help you get started with FEDOT.
    • test: Contains all unit and integration tests.
    • docs: Project documentation files.
  4. Understand M4 forecasting benchmarks for FEDOT

    master

    FEDOT's time series forecasting performance is benchmarked using the M4 competition dataset via the pytsbe framework. The benchmark evaluates forecasting accuracy across different seasonal intervals using the Symmetric Mean Absolute Percentage Error (SMAPE) metric.

    Key benchmark details:

    • Dataset: M4 competition subsample (998 series).
    • Intervals & Horizons:
      • Daily: 14-step horizon
      • Weekly: 13-step horizon
      • Monthly: 18-step horizon
      • Quarterly: 8-step horizon
      • Yearly: 6-step horizon
    • Metric: SMAPE (lower is better).

    Performance Summary: FEDOT's results are statistically indistinguishable from industry leaders like NBEATS and autogluon, and are statistically superior to TimeGPT and LagLlama.

  5. Overview of FEDOT concepts

    master

    FEDOT is an AutoML framework designed for the automatic generative design of machine learning pipelines. Key conceptual features include:

    • Flexibility: Supports various problems (classification, regression, clustering, time series), data types (text, images, tables), and models.
    • Extensibility: Allows using special strategies for specific tasks (NLP, time-series) and integrating custom ML libraries (Scikit-learn, CatBoost, XGBoost, etc.).
    • Tuningability: Supports hyper-parameter tuning with custom evaluation metrics and search spaces.
    • Reproducibility: Pipelines can be exported as JSON or as a ZIP archive containing the input data.
    • Customizability: Enables managing model complexity to balance quality and performance.
  6. Compare and select a Tuner class

    master

    FEDOT uses tuners from the GOLEM library. You can choose between simultaneous tuning (optimizing all parameters at once) and sequential tuning (optimizing node by node). Use .with_tuner(tuner_class) to specify the implementation.

    TunerBased OnTypeSupported Parameters
    SimultaneousTunerHyperoptSimultaneouscategorical, discrete, continuous
    SequentialTunerHyperoptSequential/Node-onlycategorical, discrete, continuous
    IOptTuneriOptSimultaneousdiscrete, continuous
    OptunaTunerOptunaSimultaneouscategorical, discrete, continuous

    Notes:

    • IOptTuner provides more stable results than Hyperopt-based tuners.
    • OptunaTuner supports multi-objective tuning.
    • Hyperopt-based tuners are generally faster per iteration.
    from golem.core.tuning.sequential import SequentialTuner
    
    tuner = SequentialTuner
    
    pipeline_tuner = TunerBuilder(Task(TaskTypesEnum.classification)) \\
        .with_tuner(tuner) \\
        .build(train_data)
    
    tuned_pipeline = pipeline_tuner.tune(pipeline)
  7. Use 'auto' as a predefined model in Fedot

    master

    When calling model.fit(), you can set the predefined_model parameter to 'auto'. This instructs FEDOT to choose and fit a default initial assumption for the specific task (classification, regression, etc.) without requiring you to manually construct a Pipeline object. This serves as a useful baseline to compare against your manually constructed pipelines.

    model.fit(features=dataset_to_train, target=target_col, predefined_model='auto')
  8. Handle multi-modal and datetime data in FEDOT

    master

    FEDOT supports various input data types and formats:

    • Data Sources: Accepts pandas.DataFrame, numpy arrays, or file paths to datasets.
    • Multi-modal Data: Can process different types of datasets simultaneously, including tables, text, and images.
    • Datetime Features: When using datetime features, be aware that FEDOT casts them into a float type with milliseconds units.

    For detailed usage of multi-modal tasks, see the multi-modal data description guide.

  9. Customize optimization algorithms with ComposerBuilder

    master
    If the default optimization behavior is insufficient, you can customize the process by using the ComposerBuilder class or by interacting directly with GOLEM optimizers. This allows you to implement custom genetic operators (such as specific mutation or crossover strategies) or define custom verification rules for the pipeline search.
  10. Core components for AutoML optimization in FEDOT

    master

    When using FEDOT for AutoML model optimization, the framework relies on three key abstractions:

    • Pipeline: Defines how ML operations are wired together and how data flows through the system. Use fedot.core.pipelines.pipeline.Pipeline to define these structures.
    • InputData & DataPreprocessor: Handles loading data from various formats and performing necessary preprocessing steps. Refer to fedot.core.data.data.InputData and the data preprocessing documentation for implementation details.
    • OperationRepository: A registry that defines the available ML operations and their specific implementations.