diff options
author | Paul Baltescu <pauldb89@gmail.com> | 2013-11-24 13:19:28 +0000 |
---|---|---|
committer | Paul Baltescu <pauldb89@gmail.com> | 2013-11-24 16:26:49 +0000 |
commit | 0d1f0af81ad2a368bc3216451a87111be8b9f6f5 (patch) | |
tree | 15d54f0ae8e79ffff5e06d66799855dd8bd37a63 /extractor/fast_intersector.h | |
parent | 9cc2e002a064a2e14444669178126d1e96be8230 (diff) |
Reduce memory overhead for constructing the intersector.
Diffstat (limited to 'extractor/fast_intersector.h')
-rw-r--r-- | extractor/fast_intersector.h | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/extractor/fast_intersector.h b/extractor/fast_intersector.h index 2819d239..305373dc 100644 --- a/extractor/fast_intersector.h +++ b/extractor/fast_intersector.h @@ -12,7 +12,6 @@ using namespace std; namespace extractor { typedef boost::hash<vector<int>> VectorHash; -typedef unordered_map<vector<int>, vector<int>, VectorHash> Index; class Phrase; class PhraseLocation; @@ -52,11 +51,6 @@ class FastIntersector { FastIntersector(); private: - // Uses the vocabulary to convert the phrase from the numberized format - // specified by the source data array to the numberized format given by the - // vocabulary. - vector<int> ConvertPhrase(const vector<int>& old_phrase); - // Estimates the number of computations needed if the prefix/suffix is // extended. If the last/first symbol is separated from the rest of the phrase // by a nonterminal, then for each occurrence of the prefix/suffix we need to @@ -85,10 +79,10 @@ class FastIntersector { pair<int, int> GetSearchRange(bool has_marginal_x) const; shared_ptr<SuffixArray> suffix_array; + shared_ptr<Precomputation> precomputation; shared_ptr<Vocabulary> vocabulary; int max_rule_span; int min_gap_size; - Index collocations; }; } // namespace extractor |