skglm
skglm copied to clipboard
ENH Issue a warning when solution found is null
Most non-expert users might not be familiar with the rescaling by n_samples
for alpha
. Issuing a warning when alpha > alpha_max
and giving hints to the user (for instance by printing alpha_max
) and informing the user of the scaling by n_samples
would be a valuable addition.
Do you see an easy way of computing alpha_max for non convex penalites ? Is it worth the cost and code complication ?
No indeed. But I still think if we ambition to make skglm
available for a larger audience (potentially including ML practicioners not really familiar with the inner workings of an optimizer), we should issue some form of warning or piece of information. A warning after convergence would be the least expensive solution for us.
We'd need a flexible way, because we handle penalties such as IndicatorBox. What's the pathological case we want to warn again in this case?
For the record, sklearn fits an intercept by default. Talk about surprising behavior for the user.
We could instead raise a warning when we exit the solver without having updated any coefficient