el0ps.datafit.Logistic¶
- class el0ps.datafit.Logistic(y)¶
Logistic datafit function.
The function is defined as
\[f(\mathbf{w}) = \sum_{i=1}^m \log(1 + \exp(-y_i w_i))\]for some \(\mathbf{y} \in \mathbb{R}^m\).
- Parameters:
- yNDArray
Data vector.
- __init__(y)¶
Methods
__init__(y)bind_model(model)Impose a constraint associated with the datafit function in a pyomo model.
conjugate(w)Value of the convex conjugate of the function at
w.get_spec()Specify the numba types of the class attributes.
gradient(w)Value of gradient at
w.gradient_lipschitz_constant()Lipschitz constant of the gradient.
params_to_dict()Returns the parameters name and value used to initialize the class instance.
value(w)Value of the function at
w.