API Reference#
This is an overview of the API.
skactiveml.base
#
The skactiveml.base
package implements the base classes for
skactiveml
.
Classes#
Base class for all query strategies in scikit-activeml. |
|
Base class for all pool-based active learning query strategies with a single annotator in scikit-activeml. |
|
Base class for all pool-based active learning query strategies with multiple annotators in scikit-activeml. |
|
Base class for all budget managers for stream-based active learning to model budgeting constraints. |
|
Base class for all stream-based active learning query strategies. |
|
Skactiveml Classifier |
|
Class Frequency Estimator |
|
Annotator Model |
|
Skactiveml Regressor |
|
Base class for scikit-activeml probabilistic regressors. |
skactiveml.pool
#
The skactiveml.pool
package implements query strategies for
pool-based active learning.
Classes#
Random Sampling (RS) |
|
Multi-class Probabilistic Active Learning (McPAL) |
|
Uncertainty Sampling (US) |
|
Epistemic Uncertainty Sampling (EpisUS) |
|
Monte Carlo Expected Error Reduction |
|
Value of Information (VOI) |
|
Query-by-Committee (QBC) |
|
QUerying Informative and Representative Examples (QUIRE) |
|
4DS |
|
Active Learning with Cost Embedding (ALCE) |
|
Expected Model Change (EMC) |
|
Regression based Expected Model Output Change (EMOC) |
|
Expected Model Variance Reduction (EMVR) |
|
Regression based Kullback-Leibler Divergence Maximization |
|
Greedy Sampling in the Feature Space (GSx) |
|
Greedy Sampling in the Target Space (GSi or GSy) |
|
Discriminative Active Learning (DAL) |
|
Batch Bayesian Active Learning by Disagreement (BatchBALD) |
|
Clustering Uncertainty-weighted Embeddings (CLUE) |
|
Dropout Query (DropQuery) |
|
Core Set |
|
Typical Clustering (TypiClust) |
|
Batch Active Learning by Diverse Gradient Embedding (BADGE) |
|
Probability Coverage (ProbCover) |
|
Contrastive Active Learning (ContrastiveAL) |
|
Greedy Bayesian Active Learning by Disagreement (GreedyBALD) |
|
Regression Tree-based Active Learning (RT-AL) |
|
Sub-sampling Wrapper |
|
Parallel Utility Estimation Wrapper |
|
Fast Active Learning by Contrastive UNcertainty (FALCUN) |
Functions#
Calculate the expected cost reduction. |
|
Computes uncertainty scores. |
|
Calculate the expected average precision [R24358fbc63f7-1]. |
|
Calculates the average Kullback-Leibler (KL) divergence for measuring the level of disagreement in QueryByCommittee. |
|
Calculates the vote entropy for measuring the level of disagreement in QueryByCommittee. |
|
Calculates the variation ratios for measuring the level of disagreement in QueryByCommittee. |
|
BatchBALD: Efficient and Diverse Batch Acquisition for Deep Bayesian Active Learning |
|
An active learning method that greedily forms a batch to minimize the maximum distance to a cluster center among all unlabeled datapoints. |
skactiveml.pool.multiannotator
#
The skactiveml.pool.multiannotator
package implements multi annotator
pool-based active learning for multiple annotators.
Classes#
Interval Estimation Threshold (IEThresh) |
|
IELearning |
|
Single Annotator Wrapper |
skactiveml.pool.utils
#
Classes#
Classifier to simplify retraining classifiers in an active learning scenario. |
skactiveml.stream
#
The skactiveml.stream
package implements query strategies for
stream-based active learning.
Classes#
Random Sampling for Data Streams. |
|
Periodic Sampling for Data Streams |
|
Fixed Uncertainty Strategy |
|
Variable Uncertainty Strategy |
|
The Split query strategy (Split Strategy in [R79653b04d29c-1]) queries labels based on the classifiers uncertainty assessed based on the classifier's predictions. |
|
Probabilistic Active Learning in Datastreams |
|
The RandomVariableUncertainty (Uncertainty Strategy With Randomization in [R7113787876b0-1]) query strategy samples samples based on the classifier's uncertainty assessed based on the classifier's predictions. |
|
The StreamDensityBasedAL [Rddab91d1dd87-1] query strategy is an extension to the uncertainty based query strategies proposed by Žliobaitė et al. [Rddab91d1dd87-2]. |
|
This class is the base for the CognitiveDualQueryStrategy query strategy proposed in [R1e46791e62c8-1]. |
|
This class implements the CognitiveDualQueryStrategy [Rffbcc2a90939-1] strategy with Random Sampling. |
|
This class implements the CognitiveDualQueryStrategy [R291d9e1f2fe6-1] strategy with RandomVariableUncertainty. |
|
This class implements the CognitiveDualQueryStrategy [Rb64f38603851-1] strategy with VariableUncertainty. |
|
This class implements the CognitiveDualQueryStrategy [R68dceac87beb-1] strategy with FixedUncertainty. |
skactiveml.stream.budgetmanager
#
The skactiveml.stream.budgetmanager
package implements budget managers,
which are capable of modeling the budget constraints in stream-based active
learning settings.
Classes#
Budget manager which checks, whether the specified budget has been exhausted already. |
|
Budget Manager for Fixed Uncertainty Strategy |
|
Budget Manager for Variable Uncertainty Strategy |
|
Budget Manager for Split Strategy |
|
Balanced Incremental Quantile Filter (BIQF) |
|
Budget Manager for Uncertainty Strategy With Randomization |
|
Budget Manager for DBALStream |
|
Budget manager which checks, whether the specified budget has been exhausted already. |
skactiveml.classifier
#
The skactiveml.classifier
module.
Classes#
Parzen Window Classifier (PWC) |
|
Classifier based on a Mixture Model (CMM) |
|
Sklearn Classifier |
|
Sliding Window Classifier |
skactiveml.classifier.multiannotator
#
Classes#
Logistic Regression for Crowds |
|
Ensemble of Annotator-wise Classifier |
skactiveml.visualization
#
The skactiveml.visualization
module includes various tools for
visualization.
Functions#
Plot the utility for the given single-annotator query strategy. |
|
Plot the decision boundary of the given classifier. |
|
Plot the utility for the given query strategy. |
|
Plot the utility for the given query strategy. |
|
Plot the utility for the given query strategy. |
|
Plot the decision boundary of the given classifier. |
|
Function to get samples of a mesh grid as well as x-mesh and y-mesh with given resolution in the specified bounds. |
skactiveml.utils
#
The skactiveml.utils
module includes various utilities.
Classes#
Encode class labels with value between 0 and classes-1 and uses -1 for unlabeled samples. |
Functions#
Returns index of maximum value. |
|
Returns index of minimum value. |
|
Counts number of votes per class label for each sample. |
|
Assigns a label to each sample based on weighted voting. |
|
Creates a boolean mask indicating missing labels. |
|
Creates a boolean mask indicating present labels. |
|
Check whether class labels are uniformly strings or numbers. |
|
Check whether a missing label is compatible to a given target type. |
|
Check whether cost matrix has shape (n_classes, n_classes). |
|
Validate scalar parameters type and value. |
|
Check whether the parameters are compatible to each other (only if classes is not None). |
|
Input validation for standard estimators. |
|
Check validity of the given random state. |
|
Calls a function with the given parameters given in kwargs, if they exist as parameters in f_callable. |
|
A decorator that matches the signature to a given method from a reference and hides it when the reference object does not have the wrapped function. |
|
Check if the class_prior is a valid prior. |
|
Compute confusion matrix [R3479f72bc894-1] to evaluate the accuracy of a classification. |
|
Return an array of indices indicating present labels. |
|
Return an array of indices indicating missing labels. |
|
Check if obj is one of the given types. |
|
Validates bound and returns the bound of X if bound is None. |
|
Check whether two missing label values are equal to each other. |
|
Validate if budget_manager is a budget manager class and create a copy budget_manager_. |
|
Check if indices fit to array. |
|
Generates a batch by selecting the highest values in the utilities. |
|
Validate and update the number of features for an estimator based on the input data. |
|
Checks if func is a callable and if the number of free parameters is correct. |
skactiveml.exceptions
#
Classes#
Exception class to raise if a strategy needs a mapping between samples and candidates which is not available. |