Source code for HALF.Utils.ConfigActiveLearner
from typing import Dict
[docs]class ConfigActiveLearner:
[docs] def __init__(self, strategy: str, budget:int=5000, AL_batch_size:int=500, targeted_accuracy:float=0.8, strategy_args:Dict=None):
"""Configuratiton for acttive learning
Args:
strategy (str): Identifier of the strategy to employ
budget (int, optional): Total number of labels to be queried. Defaults to 5000.
AL_batch_size (int, optional): Size of each query batch. Defaults to 500.
targeted_accuracy (float, optional): Accuracy at which the active learning should be stopped. Defaults to 0.8.
strategy_args (Dict, optional): Arguments to be passed to the strategy. Defaults to None.
"""
self.AL_batch_size = AL_batch_size
self.budget = budget
self.targeted_accuracy = targeted_accuracy
self.strategy_name = strategy
self.strategy_args = strategy_args