Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
01/14/22 15:11:36 (2 years ago)
Author:
mkommend
Message:

#3136: Fixed error in structur GP if only one numeric parameter is present in the template by providing a new copy crossover for real vectors.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/3136_Structural_GP/HeuristicLab.Encodings.RealVectorEncoding/3.3/Crossovers/MultiRealVectorCrossover.cs

    r17180 r18198  
    2222using System;
    2323using System.Linq;
     24using HEAL.Attic;
    2425using HeuristicLab.Collections;
    2526using HeuristicLab.Common;
     
    2930using HeuristicLab.Optimization;
    3031using HeuristicLab.Parameters;
    31 using HEAL.Attic;
    3232using HeuristicLab.PluginInfrastructure;
    3333
     
    6767
    6868      foreach (Type type in ApplicationManager.Manager.GetTypes(typeof(IRealVectorCrossover))) {
    69         if (!typeof(MultiOperator<IRealVectorCrossover>).IsAssignableFrom(type))
    70           Operators.Add((IRealVectorCrossover)Activator.CreateInstance(type), true);
     69        if (typeof(MultiOperator<IRealVectorCrossover>).IsAssignableFrom(type)) continue;
     70        if (typeof(CopyCrossover).IsAssignableFrom(type)) continue;
     71
     72        Operators.Add((IRealVectorCrossover)Activator.CreateInstance(type), true);
    7173      }
    7274
Note: See TracChangeset for help on using the changeset viewer.