Example #1
0
        public static MultiObjectiveParameters ReadXmlProperties(XmlElement xmlConfig)
        {
            MultiObjectiveParameters props = new MultiObjectiveParameters();

            props.Enabled = XmlUtils.TryGetValueAsBool(xmlConfig, "Enabled") ?? false;
            props.GeneticDiversityEnabled = XmlUtils.TryGetValueAsBool(xmlConfig, "GeneticDiversityEnabled") ?? true;
            props.GeneticDiversityK       = XmlUtils.TryGetValueAsInt(xmlConfig, "GeneticDiversityK") ?? 10;
            props.RejectSimilarBehaviours = XmlUtils.TryGetValueAsBool(xmlConfig, "RejectSimilarBehaviours") ?? false;
            props.RejectSimilarThreshold  = XmlUtils.TryGetValueAsDouble(xmlConfig, "RejectSimilarThreshold") ?? 0.001d;

            return(props);
        }
        public static MultiObjectiveParameters ReadXmlProperties(XmlElement xmlConfig)
        {
            MultiObjectiveParameters props = new MultiObjectiveParameters();

            props.Enabled = XmlUtils.TryGetValueAsBool(xmlConfig, "Enabled") ?? false;
            props.GeneticDiversityEnabled = XmlUtils.TryGetValueAsBool(xmlConfig, "GeneticDiversityEnabled") ?? true;
            props.GeneticDiversityK = XmlUtils.TryGetValueAsInt(xmlConfig, "GeneticDiversityK") ?? 10;
            props.RejectSimilarBehaviours = XmlUtils.TryGetValueAsBool(xmlConfig, "RejectSimilarBehaviours") ?? false;
            props.RejectSimilarThreshold = XmlUtils.TryGetValueAsDouble(xmlConfig, "RejectSimilarThreshold") ?? 0.001d;

            return props;
        }
Example #3
0
 public NSGAII(MultiObjectiveParameters multiObjectiveParameters)
 {
     _params = multiObjectiveParameters;
 }