amidst / toolbox

A Java Toolbox for Scalable Probabilistic Machine Learning
http://www.amidsttoolbox.com
Apache License 2.0
119 stars 35 forks source link

Number of iterations in learning #97

Open shayantabrizi opened 6 years ago

shayantabrizi commented 6 years ago

In calling model.updateModel(data), I found nowhere to indicate the number of iterations for learning. Shouldn't the learning algorithms have some parameter for how many times they read data and try to optimize the parameters? Then, Is it correct to call model.updateModel(data) several times (e.g., 100 times) to learn the parameters correctly? Then, how can I know if the model is converging?

andresmasegosa commented 6 years ago

Good question. Here you have an example showing how to do it,

SVB svb = new SVB(); svb.getPlateuStructure().getVMP().setMaxIter(niter); svb.getPlateuStructure().getVMP().setOutput(true); svb.getPlateuStructure().getVMP().setThreshold(threshold);

The threshold is defined as the percentage of increase in the lower bound.