Logistic RegressionBinary logistic regression as a Bernoulli model: setup, cross-entropy objective, and gradient-based fitting.