Skip to content
Snippets Groups Projects
user avatar
Joseph Walton-Rivers authored
374f4a52
History

Example paramter tuning library

building

It's a maven project, so the usual applies:

mvn clean package

Usage

see examples in com.fossgalaxy.tuner.examples

DomainSet ds = new DomainSet();
ds.addParameter(new BoundedChoice(0, 100)); //an int between 0 and 100
ds.addParameter(new BoundedChoice(20, 50, 2)); //an int between 20 and 50 (steps of 2)
ds.addParameter(new ChoiceDomain("red", "blue", "orange")); //a category (one from the list of provided values)

Tuner rs = new RandomSearch(10_000); //random search for 10,000 generations
Instance best = rs.tune(ds, ExampleUsage::minimiseError); //perform a tuning run using "minimise error" as the fitness function