public static ProtoChromosome MakeProtoChromosome() { return(new ProtoChromosome(new[] { // input data window ProtoGene.Create("TrainingOffsetPct", 0, 1, GeneType.Continuous), ProtoGene.Create("TrainingSizePct", 0.03, 1, GeneType.Continuous), // transformations ProtoGene.Create("DatabaseType", 0, 1, GeneType.Discrete), ProtoGene.CreateBoolean("UseComplementCoding"), ProtoGene.CreateBoolean("UsePCA"), ProtoGene.Create("PrincipalComponent", 0, 100, GeneType.Discrete), // RNN params ProtoGene.Create("RnnTrainingEpochs", 20, 1000, GeneType.Discrete), ProtoGene.Create("RnnLayer1NodeCount", 3, 200, GeneType.Discrete), ProtoGene.Create("RnnLayer2NodeCount", 3, 200, GeneType.Discrete), // RBF params ProtoGene.Create("RbfNetTolerance", 0, 1, GeneType.Continuous), ProtoGene.Create("RbfGaussianSpread", 0.1, 10, GeneType.Continuous), })); }
public static double RandomGeneValue(ProtoGene gd) { return(Quantize(RandomDouble(gd.MinValue, gd.MaxValue), gd.MinValue, gd.Granularity)); }