diff options
author | Chris Dyer <cdyer@cs.cmu.edu> | 2012-03-15 22:47:04 -0400 |
---|---|---|
committer | Chris Dyer <cdyer@cs.cmu.edu> | 2012-03-15 22:47:04 -0400 |
commit | 4a129e055387baf922f30f1502c6b6efad7dd8eb (patch) | |
tree | 677620ce39d792b33dfb77f87de014b0b2bcd972 /utils | |
parent | a45af4a3704531a8382cd231f6445b3a33b598a3 (diff) |
bayes bayes bayes
Diffstat (limited to 'utils')
-rw-r--r-- | utils/ccrp.h | 4 | ||||
-rw-r--r-- | utils/mfcr.h | 4 |
2 files changed, 8 insertions, 0 deletions
diff --git a/utils/ccrp.h b/utils/ccrp.h index 4a8b80e7..390d4994 100644 --- a/utils/ccrp.h +++ b/utils/ccrp.h @@ -55,6 +55,10 @@ class CCRP { double discount() const { return discount_; } double strength() const { return strength_; } + void set_hyperparameters(double d, double s) { + discount_ = d; strength_ = s; + check_hyperparameters(); + } void set_discount(double d) { discount_ = d; check_hyperparameters(); } void set_strength(double a) { strength_ = a; check_hyperparameters(); } diff --git a/utils/mfcr.h b/utils/mfcr.h index 886f01ef..4aacb567 100644 --- a/utils/mfcr.h +++ b/utils/mfcr.h @@ -73,6 +73,10 @@ class MFCR { double discount() const { return discount_; } double strength() const { return strength_; } + void set_hyperparameters(double d, double s) { + discount_ = d; strength_ = s; + check_hyperparameters(); + } void set_discount(double d) { discount_ = d; check_hyperparameters(); } void set_strength(double a) { strength_ = a; check_hyperparameters(); } |