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
diff options
context:
space:
mode:
Diffstat (limited to 'vowpalwabbit/binary.cc')
-rw-r--r--vowpalwabbit/binary.cc12
1 files changed, 9 insertions, 3 deletions
diff --git a/vowpalwabbit/binary.cc b/vowpalwabbit/binary.cc
index 04810e26..d9afc63b 100644
--- a/vowpalwabbit/binary.cc
+++ b/vowpalwabbit/binary.cc
@@ -28,10 +28,16 @@ namespace BINARY {
}
}
- LEARNER::base_learner* setup(vw& all, po::variables_map& vm)
- {
+LEARNER::base_learner* setup(vw& all)
+ {//parse and set arguments
+ new_options(all,"Binary options")
+ ("binary", "report loss as binary classification on -1,1");
+ if(missing_required(all)) return NULL;
+
+ //Create new learner
LEARNER::learner<char>& ret =
- LEARNER::init_learner<char>(NULL, all.l, predict_or_learn<true>, predict_or_learn<false>);
+ LEARNER::init_learner<char>(NULL, setup_base(all),
+ predict_or_learn<true>, predict_or_learn<false>);
return make_base(ret);
}
}