diff options
author | philblunsom@gmail.com <philblunsom@gmail.com@ec762483-ff6d-05da-a07a-a48fb63a330f> | 2010-07-02 15:29:49 +0000 |
---|---|---|
committer | philblunsom@gmail.com <philblunsom@gmail.com@ec762483-ff6d-05da-a07a-a48fb63a330f> | 2010-07-02 15:29:49 +0000 |
commit | e75ebb84de721b1d0a29c81ea8192aa787ea9284 (patch) | |
tree | 4b166b3c981060548ca7680b80c46d77a6a5e2e5 /gi | |
parent | b9da57b72eae5cb01c1b109476278df1e4f74fe7 (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.cc | 3 |
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(); |