edu::tum::cs::srl::bayesnets::learning::CPTLearner Class Reference

Inheritance diagram for edu::tum::cs::srl::bayesnets::learning::CPTLearner:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 CPTLearner (RelationalBeliefNetwork bn, boolean uniformDefault, boolean debug) throws Exception
 CPTLearner (RelationalBeliefNetwork bn) throws Exception
void learn (Database db) throws Exception
void learnTyped (Database db, boolean closedWorld, boolean verbose) throws Exception

Protected Member Functions

void countVariable (Database db, RelationalNode node, String[] params, String[] domainNames, int i, boolean closedWorld) throws Exception
void countVariable (Database db, RelationalNode node, String[] params, boolean closedWorld) throws Exception

Protected Attributes

boolean debug = false
HashMap< Integer, HashMap
< String, Integer > > 
marginals
int numExamples
boolean verbose

Detailed Description

Definition at line 21 of file srl/bayesnets/learning/CPTLearner.java.


Constructor & Destructor Documentation

edu::tum::cs::srl::bayesnets::learning::CPTLearner::CPTLearner ( RelationalBeliefNetwork  bn  )  throws Exception [inline]

Definition at line 28 of file srl/bayesnets/learning/CPTLearner.java.

edu::tum::cs::srl::bayesnets::learning::CPTLearner::CPTLearner ( RelationalBeliefNetwork  bn,
boolean  uniformDefault,
boolean  debug 
) throws Exception [inline]

Definition at line 32 of file srl/bayesnets/learning/CPTLearner.java.


Member Function Documentation

void edu::tum::cs::srl::bayesnets::learning::CPTLearner::countVariable ( Database  db,
RelationalNode  node,
String[]  params,
String[]  domainNames,
int  i,
boolean  closedWorld 
) throws Exception [inline, protected]

generates all groundings (possible lists of parameters) of the node with the given name and counts the corresponding example

Parameters:
db the database (containing domains and propositions) to use
nodeName name of the node for which to count examples
params current list of parameters
domainNames list of domain names, with one entry for each parameter
i index into params at which to insert the next parameter
closedWorld whether to make the closed-world assumption
Exceptions:
Exception 

Definition at line 301 of file srl/bayesnets/learning/CPTLearner.java.

void edu::tum::cs::srl::bayesnets::learning::CPTLearner::countVariable ( Database  db,
RelationalNode  node,
String[]  params,
boolean  closedWorld 
) throws Exception [inline, protected]

count an example (variable setting) by incrementing the counter for the given variable

Parameters:
db the database containing propositions
node node of the variable for which we are counting an example
params the node's actual parameters
closedWorld whether the closed-world assumption is to be made
Exceptions:
Exception 

Definition at line 47 of file srl/bayesnets/learning/CPTLearner.java.

void edu::tum::cs::srl::bayesnets::learning::CPTLearner::learn ( Database  db  )  throws Exception [inline]

learn the CPTs from only the data that is given in the database (relations not in the database are not considered because the closed-world assumption is not being made)

Parameters:
db 
Exceptions:
Exception 

Definition at line 249 of file srl/bayesnets/learning/CPTLearner.java.

void edu::tum::cs::srl::bayesnets::learning::CPTLearner::learnTyped ( Database  db,
boolean  closedWorld,
boolean  verbose 
) throws Exception [inline]

generates for all nodes all the possible parameters (using the node signatures and domain elements from the database) and counts the corresponding examples

Parameters:
db 
closedWorld 
verbose 
Exceptions:
Exception 

Definition at line 263 of file srl/bayesnets/learning/CPTLearner.java.


Member Data Documentation

Definition at line 26 of file srl/bayesnets/learning/CPTLearner.java.

HashMap<Integer, HashMap<String, Integer> > edu::tum::cs::srl::bayesnets::learning::CPTLearner::marginals [protected]

Definition at line 23 of file srl/bayesnets/learning/CPTLearner.java.

Definition at line 24 of file srl/bayesnets/learning/CPTLearner.java.

Definition at line 25 of file srl/bayesnets/learning/CPTLearner.java.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Enumerations


srldb
Author(s): Dominik Jain, Stefan Waldherr, Moritz Tenorth
autogenerated on Fri Jan 11 09:58:45 2013