build
public static java.util.HashMap<java.lang.String,java.util.TreeSet<java.lang.String>> build(CoOccurrenceMatrix coMa,
java.util.HashMap<java.lang.String,java.lang.Double> dict,
java.util.regex.Pattern pat_either,
java.util.regex.Pattern pat_all,
java.lang.Double dict_part_term_thresh,
java.lang.Double dict_all_term_thresh,
java.util.Set<java.lang.String> stopwords)
builds term index from the synonym graph.
For each term, it splits up the term into words and links the words to the terms.
If a word only appears in one term, then it is removed.
E.g., Pope -> (Pope_Benedict, Pope_Paul).
E.g., X -> (X_Y) -- remove X from index.
Adding additional terms from the dictionary only if they contain one or more
of the query terms.
- Parameters:
coMa - the synonym graph used for merging terms.
- Returns:
- index where single word terms point to all full terms that they occur in.