Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
06/05/13 15:28:06 (12 years ago)
Author:
mkommend
Message:

#2038: Added backwards compatibility regions into the modified algorithms for elites reevaluation.

Location:
trunk/sources/HeuristicLab.Algorithms.GeneticAlgorithm/3.3
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • TabularUnified trunk/sources/HeuristicLab.Algorithms.GeneticAlgorithm/3.3/GeneticAlgorithm.cs

    r9554 r9591  
    216216    [StorableHook(HookType.AfterDeserialization)]
    217217    private void AfterDeserialization() {
     218      #region Backwards compatible code, remove with 3.4
    218219      if (!Parameters.ContainsKey("ReevaluateElites")) {
    219220        Parameters.Add(new FixedValueParameter<BoolValue>("ReevaluateElites", "Flag to determine if elite individuals should be reevaluated (i.e., if stochastic fitness functions are used.)", (BoolValue)new BoolValue(false).AsReadOnly()) { Hidden = true });
    220221      }
     222      #endregion
     223
    221224      Initialize();
    222225    }
     226
     227
    223228
    224229    private GeneticAlgorithm(GeneticAlgorithm original, Cloner cloner)
  • TabularUnified trunk/sources/HeuristicLab.Algorithms.GeneticAlgorithm/3.3/GeneticAlgorithmMainLoop.cs

    r9555 r9591  
    245245    [StorableHook(HookType.AfterDeserialization)]
    246246    private void AfterDeserialization() {
     247      #region Backwards compatible code, remove with 3.4
    247248      if (!Parameters.ContainsKey("ReevaluateElites")) {
    248249        Parameters.Add(new ValueLookupParameter<BoolValue>("ReevaluateElites", "Flag to determine if elite individuals should be reevaluated (i.e., if stochastic fitness functions are used.)"));
    249250      }
     251      #endregion
    250252    }
    251253
  • TabularUnified trunk/sources/HeuristicLab.Algorithms.GeneticAlgorithm/3.3/IslandGeneticAlgorithm.cs

    r9569 r9591  
    206206    [StorableHook(HookType.AfterDeserialization)]
    207207    private void AfterDeserialization() {
     208      #region Backwards compatible code, remove with 3.4
    208209      if (!Parameters.ContainsKey("ReevaluateElites")) {
    209210        Parameters.Add(new FixedValueParameter<BoolValue>("ReevaluateElites", "Flag to determine if elite individuals should be reevaluated (i.e., if stochastic fitness functions are used.)", (BoolValue)new BoolValue(false).AsReadOnly()) { Hidden = true });
    210211      }
     212      #endregion
     213
    211214      Initialize();
    212215    }
  • TabularUnified trunk/sources/HeuristicLab.Algorithms.GeneticAlgorithm/3.3/IslandGeneticAlgorithmMainLoop.cs

    r9569 r9591  
    381381    [StorableHook(HookType.AfterDeserialization)]
    382382    private void AfterDeserialization() {
     383      #region Backwards compatible code, remove with 3.4
    383384      if (!Parameters.ContainsKey("ReevaluateElites")) {
    384385        Parameters.Add(new ValueLookupParameter<BoolValue>("ReevaluateElites", "Flag to determine if elite individuals should be reevaluated (i.e., if stochastic fitness functions are used.)"));
    385386      }
     387      #endregion
    386388    }
    387389
Note: See TracChangeset for help on using the changeset viewer.