- Timestamp:
- 09/15/20 13:53:11 (4 years ago)
- Location:
- branches/2521_ProblemRefactoring/HeuristicLab.Problems.Programmable/3.3
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2521_ProblemRefactoring/HeuristicLab.Problems.Programmable/3.3/CompiledProblemDefinition.cs
r17699 r17745 74 74 } 75 75 76 public virtual void Analyze(TEncodedSolution[] solutions, double[] qualities, ResultCollection results, IRandom random) { } 77 public virtual void Analyze(ISingleObjectiveSolutionContext<TEncodedSolution>[] solutionContexts, ResultCollection results, IRandom random) { 78 var solutions = solutionContexts.Select(c => c.EncodedSolution).ToArray(); 79 var qualities = solutionContexts.Select(c => c.EvaluationResult.Quality).ToArray(); 80 Analyze(solutions, qualities, results, random); 81 } 76 77 public virtual void Analyze(ISingleObjectiveSolutionContext<TEncodedSolution>[] solutionContexts, IRandom random) { } 82 78 83 79 public virtual IEnumerable<TEncodedSolution> GetNeighbors(TEncodedSolution solutions, IRandom random) { -
branches/2521_ProblemRefactoring/HeuristicLab.Problems.Programmable/3.3/SingleObjectiveProblemDefinitionScript.cs
r17699 r17745 66 66 } 67 67 68 void ISingleObjectiveProblemDefinition<TEncoding, TEncodedSolution>.Analyze(ISingleObjectiveSolutionContext<TEncodedSolution>[] solutionContexts, ResultCollection results,IRandom random) {69 CompiledProblemDefinition.Analyze(solutionContexts, r esults, random);68 void ISingleObjectiveProblemDefinition<TEncoding, TEncodedSolution>.Analyze(ISingleObjectiveSolutionContext<TEncodedSolution>[] solutionContexts, IRandom random) { 69 CompiledProblemDefinition.Analyze(solutionContexts, random); 70 70 } 71 71 -
branches/2521_ProblemRefactoring/HeuristicLab.Problems.Programmable/3.3/SingleObjectiveProgrammableProblem.cs
r17699 r17745 115 115 } 116 116 117 public override void Analyze(ISingleObjectiveSolutionContext<TEncodedSolution>[] solutionContexts, ResultCollection results,IRandom random) {118 ProblemDefinition.Analyze(solutionContexts, r esults, random);117 public override void Analyze(ISingleObjectiveSolutionContext<TEncodedSolution>[] solutionContexts, IRandom random) { 118 ProblemDefinition.Analyze(solutionContexts, random); 119 119 } 120 120
Note: See TracChangeset
for help on using the changeset viewer.