summaryrefslogtreecommitdiff
path: root/gi
diff options
context:
space:
mode:
authorphilblunsom@gmail.com <philblunsom@gmail.com@ec762483-ff6d-05da-a07a-a48fb63a330f>2010-07-02 15:29:49 +0000
committerphilblunsom@gmail.com <philblunsom@gmail.com@ec762483-ff6d-05da-a07a-a48fb63a330f>2010-07-02 15:29:49 +0000
commit26da1f79020673498fd8d134d358c8b71fcf21e2 (patch)
tree4890b41f232de80082c0a20293a2af81771e4018 /gi
parent1988573b4d995c146abcd1c334f6b734b72a3cc8 (diff)
git-svn-id: https://ws10smt.googlecode.com/svn/trunk@113 ec762483-ff6d-05da-a07a-a48fb63a330f
Diffstat (limited to 'gi')
-rw-r--r--gi/pyp-topics/src/train-contexts.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/gi/pyp-topics/src/train-contexts.cc b/gi/pyp-topics/src/train-contexts.cc
index bf56288e..12e7baec 100644
--- a/gi/pyp-topics/src/train-contexts.cc
+++ b/gi/pyp-topics/src/train-contexts.cc
@@ -107,7 +107,8 @@ int main(int argc, char **argv)
// increment this terms frequency
pair<map<int,int>::iterator,bool> insert_result = all_terms.insert(make_pair(*docIt,1));
if (!insert_result.second)
- insert_result.first++;
+ all_terms[*docIt] = all_terms[*docIt] + 1;
+ //insert_result.first++;
}
documents_out << contexts_corpus.key(document_id) << '\t';
for (std::vector<int>::const_iterator termIt=unique_terms.begin();