|
ZGen
0.2.0
a linearization system for natural language.
|
#include <tree.h>
Public Member Functions | |
| int | set_ref (const dependency_t *ref) |
| int | lvl0 (int i) const |
| int | lvl1 (int i) const |
| int | lvl2 (int i) const |
Public Member Functions inherited from ZGen::DependencyTree | |
| DependencyTree () | |
| ~DependencyTree () | |
| const edgeset_t & | siblings (int i) |
| Access the siblings of node i. More... | |
| const edgeset_t & | descendants (int i) |
| Access the descendants of node i. More... | |
| const edgeset_t & | children (int i) |
| Access the children of node i. More... | |
| int | head (int i) |
| Access the head of node i. More... | |
| bool | arc (int source, int target) |
| Return if there is an edge between source and target. More... | |
Protected Member Functions | |
| void | reset (int N=kMaxNumberOfWords) |
Protected Member Functions inherited from ZGen::DependencyTree | |
| void | dependency_to_tree (const dependency_t *parse) |
| Convert the dependency parse into the dependency tree. More... | |
| void | go (int now) |
Additional Inherited Members | |
Public Types inherited from ZGen::DependencyTree | |
| typedef std::vector< int > | edgeset_t |
Protected Attributes inherited from ZGen::DependencyTree | |
| const dependency_t * | ref |
| The reference to the dependency parse instance. More... | |
| edgeset_t | children_ [kMaxNumberOfWords] |
| Record the children for each node. More... | |
| int | parent_ [kMaxNumberOfWords] |
| Record the parent for each node. More... | |
| int | indgr_ [kMaxNumberOfWords] |
| Record the in degree of the graph. More... | |
| edgeset_t | descendants_ [kMaxNumberOfWords] |
| Record the descendant for each node. More... | |
| edgeset_t | siblings_ [kMaxNumberOfWords] |
| Record the siblings for each node. More... | |
| int ZGen::DependencyTreeWithGuidance::lvl0 | ( | int | i | ) | const |
| int ZGen::DependencyTreeWithGuidance::lvl1 | ( | int | i | ) | const |
| int ZGen::DependencyTreeWithGuidance::lvl2 | ( | int | i | ) | const |
|
protectedvirtual |
Clear all the cached information.
Reimplemented from ZGen::DependencyTree.
|
virtual |
Set the dependency tree reference onto the tree.
| [in] | _ref | The reference of the dependency tree. |
Reimplemented from ZGen::DependencyTree.
1.8.6