Machine learning.

The engine.
Post Reply
yg
Posts: 8
Joined: Wed Sep 17, 2008 3:54 pm

Machine learning.

Post by yg »

I am looking to update the probability of a node given evidence gathered in real time (or as close to real time as I can get). Am I right in thinking that something akin to the following will work:

Code: Select all

cout << "Before p = " << prob << endl; // Generic probability before learning.
for (int i=0; i<max; i++ )
{
    ...
    theNet.GetNode (forecast)->Value ()->SetEvidence (0);
    theNet.UpdateBeliefs ();
    ...
}
cout << "After p =  " << prob << endl; // New update probability after "max" iterations.
If so, does anyone have some code I could borrow?

Thanks.
mark
Posts: 179
Joined: Tue Nov 27, 2007 4:02 pm

Post by mark »

The code looks ok, but don't you want to use a dynamic Bayesian network? Or will the evidence be fixed once it's observed?
yg
Posts: 8
Joined: Wed Sep 17, 2008 3:54 pm

Post by yg »

mark wrote:The code looks ok, but don't you want to use a dynamic Bayesian network? Or will the evidence be fixed once it's observed?
I do indeed want the evidence to change. Dynamic Bayesian Network it is. Do you have any code that does that kind of things? So, each time an evidence is set, the node's probability are updated to reflect that.

Thanks.
mark
Posts: 179
Joined: Tue Nov 27, 2007 4:02 pm

Post by mark »

I don't have such code, but it should be easy to write.
Post Reply