Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
02/26/15 15:33:40 (9 years ago)
Author:
bburlacu
Message:

#2326: Moved phenotypic diversity analyzers one level up (since they can be applied to both single- and multiobjective problems). Added wiring in the multiobjective problems. Changed base class to SolutionSimilarityCalculator and adjusted analyzers.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/SymbolicExpressionTreeDiversityAnalyzers/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/TreeMatching/SymbolicExpressionTreeMaxCommonSubtreeSimilarityCalculator.cs

    r12028 r12086  
    3030  [StorableClass]
    3131  [Item("SymbolicExpressionTreeMaxCommonSubtreeSimilarityCalculator", "A similarity calculator based on the size of the maximum common subtree between two trees")]
    32   public class SymbolicExpressionTreeMaxCommonSubtreeSimilarityCalculator : SingleObjectiveSolutionSimilarityCalculator {
     32  public class SymbolicExpressionTreeMaxCommonSubtreeSimilarityCalculator : SolutionSimilarityCalculator {
    3333    [Storable]
    3434    private readonly SymbolicExpressionTreeNodeEqualityComparer comparer;
     
    4242      set { comparer.MatchConstantValues = value; }
    4343    }
     44
     45    protected override bool IsCommutative { get { return true; } }
    4446
    4547    [StorableConstructor]
     
    8587    }
    8688
     89
    8790    public static double MaxCommonSubtreeSimilarity(ISymbolicExpressionTree a, ISymbolicExpressionTree b, ISymbolicExpressionTreeNodeSimilarityComparer comparer) {
    8891      int max = 0;
Note: See TracChangeset for help on using the changeset viewer.