Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
04/21/21 15:31:20 (4 years ago)
Author:
abeham
Message:

#2521: updated samples (except for GPR - unit test needs to be refactored first)

  • Fixed a few bugs in VRP
  • Fixed the GAGroupingProblemSampleTest
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2521_ProblemRefactoring/HeuristicLab.Tests/HeuristicLab-3.3/Samples/GAGroupingProblemSampleTest.cs

    r17356 r17954  
    6464    }
    6565
    66     public override double Evaluate(LinearLinkage solution, IRandom random, CancellationToken token) {
     66    public override ISingleObjectiveEvaluationResult Evaluate(LinearLinkage solution, IRandom random, CancellationToken token) {
    6767      var penalty = 0;
    6868      var groups = solution.GetGroups().ToList();
     
    7474      var result = groups.Count;
    7575      if (penalty > 0) result += penalty + ProblemSize;
    76       return result;
     76      return new SingleObjectiveEvaluationResult(result);
    7777    }
    7878
    79     public override void Analyze(LinearLinkage[] solutions, double[] qualities, ResultCollection results, IRandom random) { }
     79    public override void Analyze(ISingleObjectiveSolutionContext<LinearLinkage>[] solutionContexts, IRandom random) { }
    8080
    8181    public override IEnumerable<LinearLinkage> GetNeighbors(LinearLinkage solution, IRandom random) {
Note: See TracChangeset for help on using the changeset viewer.