Public Member Functions | |
void | finish () throws Exception |
BeliefNetworkEx | getNetwork () |
abstract void | learn (ResultSet rs) throws Exception |
void | learn (String sqlQuery, String dbConnectString) throws Exception, SQLException |
Learner (BeliefNetwork bn) | |
Learner (BeliefNetworkEx bn) | |
Protected Member Functions | |
abstract void | end_learning () throws Exception |
Protected Attributes | |
BeliefNetworkEx | bn |
boolean | finished = false |
BeliefNode[] | nodes |
the abstract base class for other learners, which provides some basic functionality
Definition at line 17 of file Learner.java.
edu::tum::cs::bayesnets::learning::Learner::Learner | ( | BeliefNetworkEx | bn | ) | [inline] |
constructs a new learner from a BeliefNetworkEx object
bn |
Definition at line 38 of file Learner.java.
edu::tum::cs::bayesnets::learning::Learner::Learner | ( | BeliefNetwork | bn | ) | [inline] |
constructs a new learner from a BeliefNetwork object
bn |
Definition at line 47 of file Learner.java.
abstract void edu::tum::cs::bayesnets::learning::Learner::end_learning | ( | ) | throws Exception [protected, pure virtual] |
This function must be overridden by each subclass. It is called by finish to complete the learning process.
Implemented in edu::tum::cs::bayesnets::learning::CPTLearner, edu::tum::cs::bayesnets::learning::DomainLearner, and edu::tum::cs::srl::bayesnets::learning::DomainLearner.
void edu::tum::cs::bayesnets::learning::Learner::finish | ( | ) | throws Exception [inline] |
completes the learning process, performing final processing. Only when this function has been called can you be sure that all the learnt examples are reflected in the network's properties.
Exception |
Definition at line 88 of file Learner.java.
BeliefNetworkEx edu::tum::cs::bayesnets::learning::Learner::getNetwork | ( | ) | [inline] |
returns the network the learner is working on. If this function is called after the learning process has been completed (i.e. finish() has been called), the network will contain the final result of learning – the modified network. The returned BeliefNetworkEx object can subsequently be used to save the network, display it in the editor, etc.
Definition at line 59 of file Learner.java.
abstract void edu::tum::cs::bayesnets::learning::Learner::learn | ( | ResultSet | rs | ) | throws Exception [pure virtual] |
void edu::tum::cs::bayesnets::learning::Learner::learn | ( | String | sqlQuery, | |
String | dbConnectString | |||
) | throws Exception, SQLException [inline] |
learns all the examples in the result set that is obtained by executing the given query.
sqlQuery | an SQL query to execute in order to obtain a table (result set) of examples | |
dbConnectString | the connect string to establish a connection to the database |
Exception | ||
SQLException |
Definition at line 71 of file Learner.java.
the Bayesian network, for which we are learning something
Definition at line 22 of file Learner.java.
boolean edu::tum::cs::bayesnets::learning::Learner::finished = false [protected] |
whether the learning process has been completed
Definition at line 32 of file Learner.java.
BeliefNode [] edu::tum::cs::bayesnets::learning::Learner::nodes [protected] |
the array of nodes in the network
Definition at line 27 of file Learner.java.