- class asreview.models.query.MixedQuery(strategy_1='max', strategy_2='random', mix_ratio=0.95, random_state=None, **kwargs)
Mixed query strategy.
Use two different query strategies at the same time with a ratio of one to the other. A mix of two query strategies is used. For example mixing max and random sampling with a mix ratio of 0.95 would mean that at each query 95% of the instances would be sampled with the max query strategy after which the remaining 5% would be sampled with the random query strategy. It would be called the max_random query strategy. Every combination of primitive query strategy is possible.
strategy_1 (str) – Name of the first query strategy. Default ‘max’.
strategy_2 (str) – Name of the second query strategy. Default ‘random’
mix_ratio (float) – Sampling from strategy_1 and strategy_2 according a Bernoulli distribution. E.g. for mix_ratio=0.95, this implies strategy_1 with probability 0.95 and strategy_2 with probability 0.05. Default 0.95.
random_state (float) – Seed for the numpy random number generator.
**kwargs (dict) – Keyword arguments for the two strategy. To specify which of the strategies the argument is for, prepend with the name of the query strategy and an underscore, e.g. ‘max’ for maximal sampling.
Get the default parameters of the model.
str(object='') -> str str(bytes_or_buffer[, encoding[, errors]]) -> str
Get the (assigned) parameters of the model.
query(X, classifier[, n_instances, ...])
Put records in ranked order.