RecurrentConceptDriftStream#
- class capymoa.stream.drift.RecurrentConceptDriftStream[source]#
Bases:
DriftStream
- next_instance() LabeledInstance | RegressionInstance [source]#
Return the next instance in the stream.
- Raises:
ValueError – If the machine learning task is neither a regression nor a classification task.
- Returns:
A labeled instances or a regression depending on the schema.
- __init__(
- concept_list: list,
- max_recurrences_per_concept: int = 3,
- transition_type_template: ~capymoa.stream.drift.Drift = <capymoa.stream.drift.AbruptDrift object>,
- concept_name_list: list = None,
Initialize the stream with the specified parameters.
- Parameters:
schema – The schema that defines the structure of the stream. Default is None.
CLI – Command Line Interface string used to define the stream configuration for the MOA (Massive Online Analysis) framework. Default is None.
moa_stream – A pre-configured ConceptDriftStream object from MOA. If specified, the stream will be instantiated directly using this object. This is useful for integrating with MOA-based streams. Default is None.
stream – A list that defines a composite stream consisting of various concepts and drifts. If this is set, the ConceptDriftStream object will be built according to the list of concepts and drifts specified. Default is None.
Notes:#
If moa_stream is specified, it takes precedence, and the stream will be instantiated directly from the provided ConceptDriftStream object.
The CLI and moa_stream parameters allow users to specify the stream using a ConceptDriftStream from MOA alongside its CLI. This provides flexibility for users familiar with MOA’s configuration style.
In the future, we might remove the functionality associated with CLI and moa_stream to simplify the code, focusing on other methods of stream configuration.