public class CacheParseHypotheses extends Object
| Modifier and Type | Field and Description |
|---|---|
java.util.function.Predicate<Tree> |
treeFilter |
| Constructor and Description |
|---|
CacheParseHypotheses(LexicalizedParser parser) |
| Modifier and Type | Method and Description |
|---|---|
IdentityHashMap<Tree,byte[]> |
convertToBytes(IdentityHashMap<Tree,List<Tree>> uncompressed) |
byte[] |
convertToBytes(List<Tree> input) |
static List<Tree> |
convertToTrees(byte[] input) |
static IdentityHashMap<Tree,List<Tree>> |
convertToTrees(Collection<Tree> keys,
IdentityHashMap<Tree,byte[]> compressed,
int numThreads) |
static IdentityHashMap<Tree,List<Tree>> |
convertToTrees(IdentityHashMap<Tree,byte[]> compressed,
int numThreads) |
static void |
main(String[] args)
An example of a command line is
java -mx1g edu.stanford.nlp.parser.dvparser.CacheParseHypotheses -model /scr/horatio/dvparser/wsjPCFG.nocompact.simple.ser.gz -output cached9.simple.ser.gz -treebank /afs/ir/data/linguistic-data/Treebank/3/parsed/mrg/wsj 200-202 java -mx4g edu.stanford.nlp.parser.dvparser.CacheParseHypotheses -model ~/scr/dvparser/wsjPCFG.nocompact.simple.ser.gz -output cached.train.simple.ser.gz -treebank /afs/ir/data/linguistic-data/Treebank/3/parsed/mrg/wsj 200-2199 -numThreads 6 java -mx4g edu.stanford.nlp.parser.dvparser.CacheParseHypotheses -model ~/scr/dvparser/chinese/xinhuaPCFG.ser.gz -output cached.xinhua.train.ser.gz -treebank /afs/ir/data/linguistic-data/Chinese-Treebank/6/data/utf8/bracketed 026-270,301-499,600-999 |
public final java.util.function.Predicate<Tree> treeFilter
public CacheParseHypotheses(LexicalizedParser parser)
public IdentityHashMap<Tree,byte[]> convertToBytes(IdentityHashMap<Tree,List<Tree>> uncompressed)
public static IdentityHashMap<Tree,List<Tree>> convertToTrees(IdentityHashMap<Tree,byte[]> compressed, int numThreads)
public static IdentityHashMap<Tree,List<Tree>> convertToTrees(Collection<Tree> keys, IdentityHashMap<Tree,byte[]> compressed, int numThreads)
public static void main(String[] args) throws IOException
IOException