def __init__(self, prox_list: list): # Range is stored in each Prox individually Prox.__init__(self, range=None) if len(prox_list) == 0: raise ValueError('prox_list must have at least one Prox') self.prox_list = prox_list self.n_proxs = len(self.prox_list)
def __init__(self, strength: float, n_rows: int = None, range: tuple = None, positive: bool = False): Prox.__init__(self, range) self.positive = positive self.strength = strength self.n_rows = n_rows self.rank_max = None
def __init__(self, strength: float, fdr: float = 0.6, range: tuple = None, positive: bool = False): Prox.__init__(self, range) self.strength = strength self.fdr = fdr self.positive = positive self.weights = None self._prox = self._build_cpp_prox("float64")
def __init__(self, strength: float, fdr: float = 0.6, range: tuple = None, positive: bool = False): Prox.__init__(self, range) self.strength = strength self.fdr = fdr self.positive = positive self.weights = None if range is None: self._prox = _ProxSlope(self.strength, self.fdr, self.positive) else: self._prox = _ProxSlope(self.strength, self.fdr, self.range[0], self.range[1], self.positive)
def __init__(self, strength: float, fdr: float = 0.6, weights_type: str = "bh", range: tuple = None, positive: bool = False): Prox.__init__(self, range) self.strength = strength self.fdr = fdr self.weights_type = weights_type self.positive = positive self.weights = None if range is None: self._prox = _ProxSortedL1(self.strength, self.fdr, self._weights_type, self.positive) else: self._prox = _ProxSortedL1(self.strength, self.fdr, self._weights_type, self.range[0], self.range[1], self.positive)