def __init__(self, contamination=0.1, n_neighbors=20, ref_set=10, alpha=0.8):
    super(SOD, self).__init__(contamination=contamination)
    if isinstance(n_neighbors, int):
        check_parameter(n_neighbors, low=1, param_name='n_neighbors')
    else:
        raise ValueError(('n_neighbors should be int. Got %s' % type(n_neighbors)))
    if isinstance(ref_set, int):
        check_parameter(ref_set, low=1, high=n_neighbors, param_name='ref_set')
    else:
        raise ValueError(('ref_set should be int. Got %s' % type(ref_set)))
    if isinstance(alpha, float):
        check_parameter(alpha, low=0.0, high=1.0, param_name='alpha')
    else:
        raise ValueError(('alpha should be float. Got %s' % type(alpha)))
    self.n_neighbors_ = n_neighbors
    self.ref_set_ = ref_set
    self.alpha_ = alpha
    self.decision_scores_ = None
def __init__(self, contamination=0.1, n_neighbors=20, ref_set=10, alpha=0.8):
    super(SOD, self).__init__(contamination=contamination)
    if isinstance(n_neighbors, int):
        check_parameter(n_neighbors, low=1, param_name='n_neighbors')
    else:
        raise ValueError(('n_neighbors should be int. Got %s' % type(n_neighbors)))
    if isinstance(ref_set, int):
        check_parameter(ref_set, low=1, high=n_neighbors, param_name='ref_set')
    else:
        raise ValueError(('ref_set should be int. Got %s' % type(ref_set)))
    if isinstance(alpha, float):
        check_parameter(alpha, low=0.0, high=1.0, param_name='alpha')
    else:
        raise ValueError(('alpha should be float. Got %s' % type(alpha)))
    self.n_neighbors_ = n_neighbors
    self.ref_set_ = ref_set
    self.alpha_ = alpha
    self.decision_scores_ = None