Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
11/24/15 17:22:41 (9 years ago)
Author:
mkommend
Message:

#2521: Fixed all problems.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/ProblemRefactoring/HeuristicLab.Problems.ExternalEvaluation/3.4/Programmable/CompiledSingleObjectiveOptimizationSupport.cs

    r13257 r13372  
    66  public class CompiledSingleObjectiveOptimizationSupport : CompiledOptimizationSupport, ISingleObjectiveOptimizationSupport {
    77
    8     public void Analyze(Individual[] individuals, double[] qualities, ResultCollection results, IRandom random) {
     8    public void Analyze(ISolution[] individuals, double[] qualities, ResultCollection results, IRandom random) {
    99      // Use vars.yourVariable to access variables in the variable store i.e. yourVariable
    1010      // Write or update results given the range of vectors and resulting qualities
     
    1717    }
    1818
    19     public IEnumerable<Individual> GetNeighbors(Individual individual, IRandom random) {
     19    public IEnumerable<ISolution> GetNeighbors(ISolution individual, IRandom random) {
    2020      // Use vars.yourVariable to access variables in the variable store i.e. yourVariable
    2121      // Create new vectors, based on the given one that represent small changes
     
    2424        // Algorithm will draw only a finite amount of samples
    2525        // Change to a for-loop to return a concrete amount of neighbors
    26         var neighbor = individual.Copy();
     26        var neighbor = (ISolution)individual.Clone();
    2727        // For instance, perform a single bit-flip in a binary parameter
    2828        //var bIndex = random.Next(neighbor.BinaryVector("b").Length);
Note: See TracChangeset for help on using the changeset viewer.