mlrl.seco.cython.learner module¶
@author: Michael Rapp (michael.rapp.ml@gmail.com)
- class mlrl.seco.cython.learner.AccuracyHeuristicMixin¶
Bases:
ABCAllows to configure a rule learner to use the “Accuracy” heuristic for learning rules.
- abstractmethod use_accuracy_heuristic()¶
Configures the rule learner to use the “Accuracy” heuristic for learning rules.
- class mlrl.seco.cython.learner.AccuracyPruningHeuristicMixin¶
Bases:
ABCAllows to configure a rule learner to use the “Accuracy” heuristic for pruning rules.
- abstractmethod use_accuracy_pruning_heuristic()¶
Configures the rule learner to use the “Accuracy” heuristic for pruning rules.
- class mlrl.seco.cython.learner.CoverageStoppingCriterionMixin¶
Bases:
ABCAllows to configure a rule learner to use a stopping criterion that stops the induction of rules as soon as the sum of the weights of the uncovered labels is smaller or equal to a certain threshold.
- abstractmethod use_coverage_stopping_criterion() CoverageStoppingCriterionConfig¶
Configures the rule learner to use a stopping criterion that stops the induction of rules as soon as the sum of the weights of the uncovered labels is smaller or equal to a certain threshold.
- Returns:
A CoverageStoppingCriterionConfig that allows further configuration of the stopping criterion
- class mlrl.seco.cython.learner.FMeasureHeuristicMixin¶
Bases:
ABCAllows to configure a rule learner to use the “F-Measure” heuristic for learning rules.
- abstractmethod use_f_measure_heuristic() FMeasureConfig¶
Configures the rule learner to use the “F-Measure” heuristic for learning rules.
- Returns:
A FMeasureConfig that allows further configuration of the heuristic
- class mlrl.seco.cython.learner.FMeasurePruningHeuristicMixin¶
Bases:
ABCAllows to configure a rule learner to use the “F-Measure” heuristic for pruning rules.
- abstractmethod use_f_measure_pruning_heuristic() FMeasureConfig¶
Configures the rule learner to use the “F-Measure” heuristic for pruning rules.
- Returns:
A FMeasureConfig that allows further configuration of the heuristic
- class mlrl.seco.cython.learner.KlnLiftFunctionMixin¶
Bases:
ABCAllows to configure a rule learner to use a lift function that monotonously increases according to the natural logarithm of the number of labels for which a rule predicts.
- abstractmethod use_kln_lift_function() KlnLiftFunctionConfig¶
Configures the rule learner to use a lift function that monotonously increases according to the natural logarithm of the number of labels for which a rule predicts.
- Returns:
A KlnLiftFunctionConfig that allows further configuration of the lift function
- class mlrl.seco.cython.learner.LaplaceHeuristicMixin¶
Bases:
ABCAllows to configure a rule learner to use the “Laplace” heuristic for learning rules.
- abstractmethod use_laplace_heuristic()¶
Configures the rule learner to use the “Laplace” heuristic for learning rules.
- class mlrl.seco.cython.learner.LaplacePruningHeuristicMixin¶
Bases:
ABCAllows to configure a rule learner to use the “Laplace” heuristic for pruning rules.
- abstractmethod use_laplace_pruning_heuristic()¶
Configures the rule learner to use the “Laplace” heuristic for pruning rules.
- class mlrl.seco.cython.learner.MEstimateHeuristicMixin¶
Bases:
ABCAllows to configure a rule learner to use the “M-Estimate” heuristic for learning rules.
- abstractmethod use_m_estimate_heuristic() MEstimateConfig¶
Configures the rule learner to use the “M-Estimate” heuristic for learning rules.
- Returns:
A MEstimateConfig that allows further configuration of the heuristic
- class mlrl.seco.cython.learner.MEstimatePruningHeuristicMixin¶
Bases:
ABCAllows to configure a rule learner to use the “M-Estimate” heuristic for pruning rules.
- abstractmethod use_m_estimate_pruning_heuristic() MEstimateConfig¶
Configures the rule learner to use the “M-Estimate” heuristic for pruning rules.
- Returns:
A MEstimateConfig that allows further configuration of the heuristic
- class mlrl.seco.cython.learner.NoCoverageStoppingCriterionMixin¶
Bases:
ABCAllows to configure a rule learner to not use any stopping criterion that stops the induction of rules as soon as the sum of the weights of the uncovered labels is smaller or equal to a certain threshold.
- abstractmethod use_no_coverage_stopping_criterion()¶
Configures the rule learner to not use any stopping criterion that stops the induction of rules as soon as the sum of the weights of the uncovered labels is smaller or equal to a certain threshold.
- class mlrl.seco.cython.learner.NoLiftFunctionMixin¶
Bases:
ABCAllows to configure a rule learner to not use a lift function.
- abstractmethod use_no_lift_function()¶
Configures the rule learner to not use a lift function.
- class mlrl.seco.cython.learner.OutputWiseBinaryPredictionMixin¶
Bases:
ABCAllows to configure a rule learner to use a predictor for predicting whether individual labels of given query examples are relevant or irrelevant by processing rules of an existing rule-based model in the order they have been learned. If a rule covers an example, its prediction is applied to each label individually.
- abstractmethod use_output_wise_binary_predictor()¶
Configures the rule learner to use predictor for predicting whether individual labels of given query examples are relevant or irrelevant by processing rules of an existing rule-based model in the order they have been learned. If a rule covers an example, its prediction is applied to each label individually.
- class mlrl.seco.cython.learner.PartialHeadMixin¶
Bases:
ABCAllows to configure a rule learner to induce rules with partial heads.
- abstractmethod use_partial_heads()¶
Configures the rule learner to induce rules with partial heads that predict for a subset of the available labels.
- class mlrl.seco.cython.learner.PeakLiftFunctionMixin¶
Bases:
ABCAllows to configure a rule learner to use a lift function that monotonously increases until a certain number of labels, where the maximum lift is reached, and monotonously decreases afterwards.
- abstractmethod use_peak_lift_function() PeakLiftFunctionConfig¶
Configures the rule learner to use a lift function that monotonously increases until a certain number of labels, where the maximum lift is reached, and monotonously decreases afterwards.
- Returns:
A PeakLiftFunctionConfig that allows further configuration of the lift function
- class mlrl.seco.cython.learner.PrecisionHeuristicMixin¶
Bases:
ABCAllows to configure a rule learner to use the “Precision” heuristic for learning rules.
- abstractmethod use_precision_heuristic()¶
Configures the rule learner to use the “Precision” heuristic for learning rules.
- class mlrl.seco.cython.learner.PrecisionPruningHeuristicMixin¶
Bases:
ABCAllows to configure a rule learner to use the “Precision” heuristic for pruning rules.
- abstractmethod use_precision_pruning_heuristic()¶
Configures the rule learner to use the “Precision” heuristic for pruning rules.
- class mlrl.seco.cython.learner.RecallHeuristicMixin¶
Bases:
ABCAllows to configure a rule learner to use the “Recall” heuristic for pruning rules.
- abstractmethod use_recall_heuristic()¶
Configures the rule learner to use the “Recall” heuristic for learning rules.
- class mlrl.seco.cython.learner.RecallPruningHeuristicMixin¶
Bases:
ABCAllows to configure a rule learner to use the “Recall” heuristic for pruning rules.
- abstractmethod use_recall_pruning_heuristic()¶
Configures the rule learner to use the “Recall” heuristic for pruning rules.
- class mlrl.seco.cython.learner.SingleOutputHeadMixin¶
Bases:
ABCAllows to configure a rule learner to induce rules with single-output heads that predict for a single output.
- abstractmethod use_single_output_heads()¶
Configures the rule learner to induce rules with single-output heads that predict for a single output.
- class mlrl.seco.cython.learner.WraHeuristicMixin¶
Bases:
ABCAllows to configure a rule learner to use the “Weighted Relative Accuracy” (WRA) heuristic for learning rules.
- abstractmethod use_wra_heuristic()¶
Configures the rule learner to use the “Weighted Relative Accuracy” heuristic for learning rules.
- class mlrl.seco.cython.learner.WraPruningHeuristicMixin¶
Bases:
ABCAllows to configure a rule learner to use the “Weighted Relative Accuracy” (WRA) heuristic for pruning rules.
- abstractmethod use_wra_pruning_heuristic()¶
Configures the rule learner to use the “Weighted Relative Accuracy” heuristic for pruning rules.