sktime.benchmarking.tasks

Unified high-level interface for various time series related learning tasks.

class sktime.benchmarking.tasks.BaseTask(target, features=None, metadata=None)[source]

Bases: object

Abstract base task class.

A task encapsulates metadata information such as the feature and target variable which to fit the data to and additional necessary instructions on how to fit and predict.

Implements attributes and operations shared by all tasks, including compatibility checks between the concrete task type and passed metadata.

Parameters
  • target (str) – The column name for the target variable to be predicted.

  • features (list of str, optional, (default=None)) – The column name(s) for the feature variable. If None, every column apart from target will be used as a feature.

  • metadata (pandas.DataFrame) – Contains the metadata that the task is expected to work with.

check_data_compatibility(metadata)[source]

Check compatibility of task with passed metadata.

Parameters

metadata (pandas.DataFrame) – Metadata container

property features[source]

Make attributes read-only.

property metadata[source]

Make attributes read-only.

set_metadata(metadata)[source]

Provide missing metadata information to task if not already set.

This method is especially useful in orchestration where metadata may not be available when specifying the task.

Parameters

metadata (pandas.DataFrame) – Metadata container

Returns

self

Return type

an instance of self

property target[source]

Make attributes read-only.

class sktime.benchmarking.tasks.TSCTask(target, features=None, metadata=None)[source]

Bases: sktime.benchmarking.tasks.BaseTask

Time series classification task.

A task encapsulates metadata information such as the feature and target variable to which to fit the data to and any additional necessary instructions on how to fit and predict.

Parameters
  • target (str) – The column name for the target variable to be predicted.

  • features (list of str, optional (default=None)) – The column name(s) for the feature variable. If None, every column apart from target will be used as a feature.

  • metadata (pandas.DataFrame, optional (default=None)) – Contains the metadata that the task is expected to work with.

class sktime.benchmarking.tasks.TSRTask(target, features=None, metadata=None)[source]

Bases: sktime.benchmarking.tasks.BaseTask

Time series regression task.

A task encapsulates metadata information such as the feature and target variable to which to fit the data to and any additional necessary instructions on how to fit and predict.

Parameters
  • target (str) – The column name for the target variable to be predicted.

  • features (list of str, optional (default=None)) – The column name(s) for the feature variable. If None, every column apart from target will be used as a feature.

  • metadata (pandas.DataFrame, optional (default=None)) – Contains the metadata that the task is expected to work with.