]> granicus.if.org Git - liblinear/commitdiff
the array D for the diagonal matrix in Hessian isn't needed for l2_loss problems
authorChih-Jen Lin <cjlin@csie.ntu.edu.tw>
Thu, 31 Dec 2015 11:01:15 +0000 (19:01 +0800)
committerChih-Jen Lin <cjlin@csie.ntu.edu.tw>
Thu, 31 Dec 2015 11:01:15 +0000 (19:01 +0800)
so we remove it. It's now only used for lr.

linear.cpp

index 0aadba388262e1ade5f9467863575406c4101d96..b7bfecaf6713a200eb8f0b64ad80940f3131a05f 100644 (file)
@@ -233,7 +233,6 @@ protected:
 
        double *C;
        double *z;
-       double *D;
        int *I;
        int sizeI;
        const problem *prob;
@@ -246,7 +245,6 @@ l2r_l2_svc_fun::l2r_l2_svc_fun(const problem *prob, double *C)
        this->prob = prob;
 
        z = new double[l];
-       D = new double[l];
        I = new int[l];
        this->C = C;
 }
@@ -254,7 +252,6 @@ l2r_l2_svc_fun::l2r_l2_svc_fun(const problem *prob, double *C)
 l2r_l2_svc_fun::~l2r_l2_svc_fun()
 {
        delete[] z;
-       delete[] D;
        delete[] I;
 }