Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/moses-smt/vowpal_wabbit.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/cg.cc
diff options
context:
space:
mode:
authorJohn Langford <jl@hunch.net>2011-07-14 21:47:59 +0400
committerJohn Langford <jl@hunch.net>2011-07-14 21:47:59 +0400
commit6cb47949f15cfad879976775ae20c733909e9518 (patch)
tree429e44cb9f9eeaa391fa1e4389c91eb440574d8b /cg.cc
parent940bc1a021e3f33581e84a5717cd5b57e8d6be9f (diff)
debug per-feature regularization
Diffstat (limited to 'cg.cc')
-rw-r--r--cg.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/cg.cc b/cg.cc
index cfbcaae7..6b1897e8 100644
--- a/cg.cc
+++ b/cg.cc
@@ -355,7 +355,7 @@ float accumulate_scalar(node_socks socks, float local_sum) {
return temp;
}
-void setup_cg(gd_thread_params t)
+void setup_cg(gd_thread_params& t)
{
regressor reg = t.reg;
size_t thread_num = 0;
@@ -574,6 +574,7 @@ void setup_cg(gd_thread_params t)
free(predictions.begin);
free(old_first_derivative);
free(ec);
+ t.reg = reg;
return;
}
else
@@ -590,6 +591,7 @@ void setup_cg(gd_thread_params t)
cerr<<"Net time spent = "<<(float)net_time/(float)1000<<"seconds\n";
fflush(stderr);
+ t.reg = reg;
return;
}