seldonian.models.models.RandomClassifierModel

class RandomClassifierModel

Bases: ClassificationModel

__init__()

Implements a classifier that always predicts that the positive class has prob=0.5, regardless of input

__repr__()

Return repr(self).

Methods

predict(theta, X)

Predict the probability of having the positive class label

Parameters:
  • theta (numpy ndarray) – The parameter weights

  • X (numpy ndarray) – The features

Returns:

predictions for each observation

Return type:

float