Free cookie consent management tool by TermsFeed Policy Generator

Changeset 14832


Ignore:
Timestamp:
04/06/17 11:55:23 (8 years ago)
Author:
gkronber
Message:

#2650 adapted GP unit test so that they produce the same outcomes as before reintegration of the factors branch

Location:
trunk/sources/HeuristicLab.Tests/HeuristicLab-3.3/Samples
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.Tests/HeuristicLab-3.3/Samples/GPSymbolicClassificationSampleTest.cs

    r14185 r14832  
    100100      grammar.ConfigureAsDefaultClassificationGrammar();
    101101      grammar.Symbols.OfType<VariableCondition>().Single().Enabled = false;
    102       var varSymbol = grammar.Symbols.OfType<Variable>().Where(x => !(x is LaggedVariable)).Single();
     102      foreach (var varSy in grammar.Symbols.OfType<VariableBase>()) varSy.VariableChangeProbability = 1.0; // for backwards compatibilty
     103      var varSymbol = grammar.Symbols.OfType<Variable>().Single();
    103104      varSymbol.WeightMu = 1.0;
    104105      varSymbol.WeightSigma = 1.0;
  • trunk/sources/HeuristicLab.Tests/HeuristicLab-3.3/Samples/GPSymbolicRegressionSampleTest.cs

    r14185 r14832  
    101101      grammar.ConfigureAsDefaultRegressionGrammar();
    102102      grammar.Symbols.OfType<VariableCondition>().Single().InitialFrequency = 0.0;
    103       var varSymbol = grammar.Symbols.OfType<Variable>().Where(x => !(x is LaggedVariable)).Single();
     103      foreach (var varSy in grammar.Symbols.OfType<VariableBase>()) varSy.VariableChangeProbability = 1.0; // for backwards compatibilty
     104      var varSymbol = grammar.Symbols.OfType<Variable>().Single();
    104105      varSymbol.WeightMu = 1.0;
    105106      varSymbol.WeightSigma = 1.0;
  • trunk/sources/HeuristicLab.Tests/HeuristicLab-3.3/Samples/GPTimeSeriesSampleTest.cs

    r14529 r14832  
    7474          autoRegressiveSymbol.MaxLag = -1;
    7575        }
     76        if (symbol is VariableBase) {
     77          var varSy = symbol as VariableBase;
     78          varSy.VariableChangeProbability = 1.0; // backwards compatibility
     79        }
    7680      }
    7781
Note: See TracChangeset for help on using the changeset viewer.