summaryrefslogtreecommitdiff
path: root/utils/ccrp_onetable.h
diff options
context:
space:
mode:
authorChris Dyer <cdyer@cs.cmu.edu>2012-06-18 20:28:42 -0400
committerChris Dyer <cdyer@cs.cmu.edu>2012-06-18 20:28:42 -0400
commit67456f9f7af754750faeea6f1e66b14b910d8751 (patch)
treed4c647f455e0a2b9fe102843fd0a060264867c44 /utils/ccrp_onetable.h
parentc3fddf01ebfa8f523ab2d6bb2db5e2be1a929ee2 (diff)
add non-const iterators to sparse vector, speed up model1 code
Diffstat (limited to 'utils/ccrp_onetable.h')
-rw-r--r--utils/ccrp_onetable.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/utils/ccrp_onetable.h b/utils/ccrp_onetable.h
index 1fe01b0e..abe399ea 100644
--- a/utils/ccrp_onetable.h
+++ b/utils/ccrp_onetable.h
@@ -183,7 +183,7 @@ class CCRP_OneTable {
assert(has_discount_prior() || has_alpha_prior());
DiscountResampler dr(*this);
ConcentrationResampler cr(*this);
- for (int iter = 0; iter < nloop; ++iter) {
+ for (unsigned iter = 0; iter < nloop; ++iter) {
if (has_alpha_prior()) {
alpha_ = slice_sampler1d(cr, alpha_, *rng, 0.0,
std::numeric_limits<double>::infinity(), 0.0, niterations, 100*niterations);