Multivariate Point Outliers
Ver. 1.1.0 (2024-04-26)
This module provides a multivariate benchmark stream with configurable baselines per feature and additional random point outliers.
- class mlpro.bf.streams.streams.point_outliers.StreamMLProPOutliers(p_num_dim: int = 4, p_num_instances: int = 1000, p_functions: list[str] = ['sin', 'cos', 'const', 'lin'], p_outlier_rate: float = 0.05, p_seed=None, p_logging=True, **p_kwargs)
Bases:
StreamMLProBase
This benchmark stream provides multidimensional instances with configurable baselines per feature. Additionally, random point outliers per feature are induced.
- p_num_dimint
The number of dimensions or features of the data. Default = 3.
- p_num_instancesint
Total number of instances. The value ‘0’ means indefinite. Default = 1000.
- p_functionslist[str]
List of mathematical functions per feature.
- p_outlier_ratefloat
A value in [0,1] that defines the number of random outliers in % per feature.
- p_seed
Seeding value for the random generator. Default = None (no seeding).
- p_logging
Log level (see constants of class Log). Default: Log.C_LOG_ALL.
- C_ID = 'PointOutliersND'
- C_NAME = 'Point Outliers N-Dim'
- C_TYPE = 'Benchmark'
- C_VERSION = '1.1.0'
- C_SCIREF_ABSTRACT = 'This benchmark stream provides multidimensional instances with configurable baselines per feature. Additionally, random point outliers per feature are induced.'
- C_BOUNDARIES = [0, 0]
- _setup_feature_space() MSpace
Custom method to set up the feature space of the stream. It is called by method get_feature_space().
- Returns:
feature_space – Feature space of the stream.
- Return type:
- _init_dataset()
Custom method to generate stream data as a numpy array named self._dataset.
- _get_next() Instance
Custom method to determine the next data stream instance. At the end of the stream exception StopIteration is to be raised. See method __next__() for more details.
- Returns:
instance – Next instance of data stream or None.
- Return type:
- _fct_sin(p_x, p_outlier: bool)
- _fct_cos(p_x, p_outlier: bool)
- _fct_const(p_x, p_outlier: bool)
- _fct_lin(p_x, p_outlier: bool)