Package gmisclib :: Module nbest :: Class node
[frames] | no frames]

Class node

source code

This is a node of a graph, it includes links to other nodes.

Instance Methods
 
__init__(self, cost=0.0, label=None, terminal=0, comment=None)
Create a node, with a specified cost (used in the beam search), and a label (arbitrary information).
source code
 
add(self, nextnode, cost=0.0, label=None)
Add a link from self to nextnode.
source code
 
__str__(self) source code
 
__repr__(self) source code
Class Variables
  __doc__ = """This is a node of a graph, it includes links to o...
Method Details

__init__(self, cost=0.0, label=None, terminal=0, comment=None)
(Constructor)

source code 

Create a node, with a specified cost (used in the beam search), and a label (arbitrary information). Terminal nodes are marked, and terminate the search.

add(self, nextnode, cost=0.0, label=None)

source code 

Add a link from self to nextnode. Links can have a cost and label, too.


Class Variable Details

__doc__

Value:
"""This is a node of a graph, it includes links to other nodes."""