From: Chih-Jen Lin Date: Mon, 20 Jul 2020 01:27:26 +0000 (+0800) Subject: add -R explanation in README (and mention that generally it's not needed) X-Git-Tag: v240~1 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=c3af75aa386b91030b36b2b8f9c8a61ba2f23d2a;p=liblinear add -R explanation in README (and mention that generally it's not needed) --- diff --git a/README b/README index b81ad8c..8a6b385 100644 --- a/README +++ b/README @@ -214,7 +214,15 @@ where Q is a matrix with Q_ij = x_i^T x_j. -If bias >= 0, w becomes [w; w_{n+1}] and x becomes [x; bias]. +If bias >= 0, w becomes [w; w_{n+1}] and x becomes [x; bias]. For +example, L2-regularized logistic regression (-s 0) becomes + +min_w w^Tw/2 + (w_{n+1})^2/2 + C \sum log(1 + exp(-y_i [w; w_{n+1}]^T[x_i; bias])) + +Some may prefer not having (w_{n+1})^2/2 (i.e., bias variable not +regularized). For primal solvers (-s 0, 2, 5, 6, 11), we provide an +option -R to remove (w_{n+1})^2/2. However, -R is generally not needed +as for most data with/without (w_{n+1})^2/2 give similar performances. The primal-dual relationship implies that -s 1 and -s 2 give the same model, -s 0 and -s 7 give the same, and -s 11 and -s 12 give the same.