public class PSTree extends Object
| Modifier and Type | Field and Description |
|---|---|
String[] |
entries |
int[] |
forms |
int[] |
head |
static boolean |
INSERT_NEWLINE |
String[] |
lemmas |
String[] |
morph |
int |
non |
int[] |
ok |
int[] |
phrases |
String[] |
pos |
int[] |
ppos |
int[][] |
psfeats |
int |
terminalCount |
| Constructor and Description |
|---|
PSTree()
Create an undefined phrase tree
|
PSTree(SentenceData09 d) |
| Modifier and Type | Method and Description |
|---|---|
String |
conll09() |
boolean |
containsNull() |
void |
create(int terminals,
int nonTerminals) |
int |
equals(SentenceData09 s) |
boolean |
exec(String r,
int ph,
int pt,
boolean check) |
boolean |
execT(String r,
int ph,
int pt,
boolean check)
More tolerant mapping
|
String |
getChain(int dn,
int n,
int commonHead) |
int[] |
getChilds(int head) |
int |
getCommonHead(int d,
int dh) |
String |
getOperation(int dn,
int n,
int commonHead)
Create operation to include dependency edges in phrase structure
Operations: c - create ; i - insert ; in - insert (dependent) node ; up:X go the (phrase) X up
ci create and insert ...
|
String |
getOperationRoot(int pr)
Get operations to create root
see operation in method getOperation
|
int |
getPS(int dn) |
String |
toPennBracket(boolean newLine)
Convert to bracket format
|
String |
toString() |
public String[] entries
public String[] lemmas
public int[] head
public String[] pos
public int[] ok
public int non
public int terminalCount
public String[] morph
public int[] forms
public int[] phrases
public int[][] psfeats
public int[] ppos
public static final boolean INSERT_NEWLINE
public PSTree(SentenceData09 d)
d - public PSTree()
public void create(int terminals,
int nonTerminals)
terminals - nonTerminals - public boolean containsNull()
public int equals(SentenceData09 s)
public int getPS(int dn)
dn - public String getChain(int dn, int n, int commonHead)
dn - n - commonHead - the common head in the phrase structurepublic int getCommonHead(int d,
int dh)
dn - n - public String getOperationRoot(int pr)
pr - public String getOperation(int dn, int n, int commonHead)
dn - n - commonHead - public boolean exec(String r, int ph, int pt, boolean check)
ph - node in the phrase structure corresponding to the head in the dependency structurept - node in the prhase structure corresponding to the dependent in the ds.check - public boolean execT(String r, int ph, int pt, boolean check)
ph - node in the phrase structure corresponding to the head in the dependency structurept - node in the prhase structure corresponding to the dependent in the ds.check - public String toPennBracket(boolean newLine)
newLine - public String conll09()
public int[] getChilds(int head)
phead - Copyright © 2013. All rights reserved.