edu.washington.cs.knowitall.extractor.mapper
Class NormalizedRelationDictionaryFilter
java.lang.Object
edu.washington.cs.knowitall.extractor.mapper.Mapper<T>
edu.washington.cs.knowitall.extractor.mapper.FilterMapper<ChunkedExtraction>
edu.washington.cs.knowitall.extractor.mapper.NormalizedRelationDictionaryFilter
public class NormalizedRelationDictionaryFilter
- extends FilterMapper<ChunkedExtraction>
A class used to filter out any relations whose normalized form does not
appear in the given dictionary. Relation strings are normalized using the
VerbalRelationNormalizer class.
- Author:
- afader
|
Method Summary |
boolean |
doFilter(ChunkedExtraction extr)
Returns true if the tokens in the given extraction appear in the set of
relations passed to the constructor. |
| Methods inherited from class edu.washington.cs.knowitall.extractor.mapper.FilterMapper |
doMap |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
NormalizedRelationDictionaryFilter
public NormalizedRelationDictionaryFilter(HashSet<String> relations)
- Constructs a new filter using the String relations in the given set.
These relations should be normalized using the VerbalRelationNormalizer
class, with a space between each token in the string.
- Parameters:
relations -
doFilter
public boolean doFilter(ChunkedExtraction extr)
- Returns true if the tokens in the given extraction appear in the set of
relations passed to the constructor.
- Specified by:
doFilter in class FilterMapper<ChunkedExtraction>
Copyright © 2010-2012 University of Washington CSE. All Rights Reserved.