Ignore:
Timestamp:
12/21/18 14:07:02 (5 months ago)
Author:
mkommend
Message:

#2910: Merged r15871 into stable.

Location:
stable
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • stable

  • stable/HeuristicLab.Problems.DataAnalysis.Symbolic

  • stable/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/SymbolicDataAnalysisSolutionImpactValuesCalculator.cs

    r15584 r16434  
    4040        out double impactValue, out double replacementValue, out double newQualityForImpactsCalculation,
    4141        double qualityForImpactsCalculation = double.NaN) {
    42       if (double.IsNaN(qualityForImpactsCalculation))
    43         qualityForImpactsCalculation = CalculateQualityForImpacts(model, problemData, rows);
    4442
    4543      var cloner = new Cloner();
    4644      var tempModel = cloner.Clone(model);
     45
     46      if (double.IsNaN(qualityForImpactsCalculation)) {
     47        qualityForImpactsCalculation = CalculateQualityForImpacts(tempModel, problemData, rows);
     48      }
     49
    4750      var tempModelNode = (ISymbolicExpressionTreeNode)cloner.GetClone(node);
    48 
    4951      var tempModelParentNode = tempModelNode.Parent;
    5052      int i = tempModelParentNode.IndexOfSubtree(tempModelNode);
     
    5456      newQualityForImpactsCalculation = qualityForImpactsCalculation; // initialize
    5557      // try the potentially reasonable replacement values and use the best one
    56       foreach (var repValue in CalculateReplacementValues(node, model.SymbolicExpressionTree, model.Interpreter, problemData.Dataset, problemData.TrainingIndices)) {
     58      foreach (var repValue in CalculateReplacementValues(node, model.SymbolicExpressionTree, model.Interpreter, problemData.Dataset, rows)) {
    5759        tempModelParentNode.RemoveSubtree(i);
    5860
Note: See TracChangeset for help on using the changeset viewer.