Few more @Parameter annotations where useful.
This commit is contained in:
parent
cb83280a55
commit
d676e78f61
@ -7,11 +7,6 @@ import eva2.optimization.individuals.AbstractEAIndividual;
|
||||
* This metric methods is experimental and should be moved to the
|
||||
* optimization problem to allow problem specific distance metrics
|
||||
* between individuals.
|
||||
* Created by IntelliJ IDEA.
|
||||
* User: streiche
|
||||
* Date: 24.04.2003
|
||||
* Time: 13:23:40
|
||||
* To change this template use Options | File Templates.
|
||||
*/
|
||||
public interface InterfaceDistanceMetric {
|
||||
|
||||
|
@ -15,6 +15,7 @@ import eva2.tools.math.Mathematics;
|
||||
import eva2.tools.math.RNG;
|
||||
import eva2.tools.math.StatisticUtils;
|
||||
import eva2.util.annotation.Description;
|
||||
import eva2.util.annotation.Parameter;
|
||||
|
||||
import java.util.*;
|
||||
import java.util.logging.Level;
|
||||
@ -1633,6 +1634,7 @@ public class Population extends ArrayList implements PopulationInterface, Clonea
|
||||
*
|
||||
* @param size
|
||||
*/
|
||||
@Parameter(name = "size", description = "The initial population size.")
|
||||
public final void setTargetSize(int size) {
|
||||
this.targetPopSize = size;
|
||||
}
|
||||
@ -1652,10 +1654,6 @@ public class Population extends ArrayList implements PopulationInterface, Clonea
|
||||
return this.targetPopSize;
|
||||
}
|
||||
|
||||
public String targetSizeTipText() {
|
||||
return "The initial population size.";
|
||||
}
|
||||
|
||||
public AbstractEAIndividual getEAIndividual(int i) {
|
||||
return (AbstractEAIndividual) this.get(i);
|
||||
}
|
||||
@ -1831,14 +1829,11 @@ public class Population extends ArrayList implements PopulationInterface, Clonea
|
||||
return popDistMetric;
|
||||
}
|
||||
|
||||
@Parameter(name = "metric", description = "Set a default distance metric to be used with the population.")
|
||||
public void setPopMetric(InterfaceDistanceMetric metric) {
|
||||
popDistMetric = metric;
|
||||
}
|
||||
|
||||
public String popMetricTipText() {
|
||||
return "Set a default distance metric to be used with the population.";
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the average, minimal and maximal individual distance as diversity
|
||||
* measure for the population. If the given metric argument is null, the
|
||||
@ -2325,6 +2320,7 @@ public class Population extends ArrayList implements PopulationInterface, Clonea
|
||||
return initMethod;
|
||||
}
|
||||
|
||||
@Parameter(description = "Define the initial sampling method. Note that anything other than inidividualDefault will override the individual initialization concerning the positions in solution space.")
|
||||
public void setInitMethod(PopulationInitMethod initMethod) {
|
||||
this.initMethod = initMethod;
|
||||
GenericObjectEditor.setShowProperty(this.getClass(), "initAround", initMethod == PopulationInitMethod.aroundSeed);
|
||||
@ -2332,10 +2328,6 @@ public class Population extends ArrayList implements PopulationInterface, Clonea
|
||||
GenericObjectEditor.setShowProperty(this.getClass(), "seedCardinality", initMethod == PopulationInitMethod.binCardinality);
|
||||
}
|
||||
|
||||
public String initMethodTipText() {
|
||||
return "Define the initial sampling method. Note that anything other than inidividualDefault will override the individual initialization concerning the positions in solution space.";
|
||||
}
|
||||
|
||||
/**
|
||||
* Add the population data of a given population to this instance. Note that
|
||||
* collisions are not checked!
|
||||
|
Loading…
x
Reference in New Issue
Block a user