Free cookie consent management tool by TermsFeed Policy Generator

Changeset 13102


Ignore:
Timestamp:
11/03/15 06:51:49 (9 years ago)
Author:
gkronber
Message:

#1998:

  • changed namespace and name of view
  • calculate f1 score only for solutions for binary classification problems
Location:
trunk/sources
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.Problems.DataAnalysis.Views/3.4/Classification/ClassificationSolutionComparisonView.cs

    r13101 r13102  
    2929
    3030namespace HeuristicLab.Problems.DataAnalysis.Views.Classification {
    31   [View("Classification Solution Comparison")]
     31  [View("Solution Comparison")]
    3232  [Content(typeof(IClassificationSolution))]
    3333  public partial class ClassificationSolutionComparisonView : DataAnalysisSolutionEvaluationView {
  • trunk/sources/HeuristicLab.Problems.DataAnalysis.Views/3.4/HeuristicLab.Problems.DataAnalysis.Views-3.4.csproj

    r13100 r13102  
    138138      <DependentUpon>ClassificationFeatureCorrelationView.cs</DependentUpon>
    139139    </Compile>
    140     <Compile Include="Classification\ClassificationSolutionComparisonView.cs" />
     140    <Compile Include="Classification\ClassificationSolutionComparisonView.cs">
     141      <SubType>UserControl</SubType>
     142    </Compile>
    141143    <Compile Include="Classification\ClassificationSolutionComparisonView.Designer.cs">
    142144      <DependentUpon>ClassificationSolutionComparisonView.cs</DependentUpon>
  • trunk/sources/HeuristicLab.Problems.DataAnalysis/3.4/Implementation/Classification/ClassificationSolutionBase.cs

    r13100 r13102  
    137137        ClassificationPerformanceMeasures.SetTestResults(testPerformanceCalculator);
    138138
    139       var f1Training = FOneScoreCalculator.Calculate(originalTrainingClassValues, estimatedTrainingClassValues, out errorState);
    140       if (errorState == OnlineCalculatorError.None) ClassificationPerformanceMeasures.TrainingF1Score = f1Training;
    141       var f1Test = FOneScoreCalculator.Calculate(originalTestClassValues, estimatedTestClassValues, out errorState);
    142       if (errorState == OnlineCalculatorError.None) ClassificationPerformanceMeasures.TestF1Score = f1Test;
    143 
     139      if (ProblemData.Classes == 2) {
     140        var f1Training = FOneScoreCalculator.Calculate(originalTrainingClassValues, estimatedTrainingClassValues, out errorState);
     141        if (errorState == OnlineCalculatorError.None) ClassificationPerformanceMeasures.TrainingF1Score = f1Training;
     142        var f1Test = FOneScoreCalculator.Calculate(originalTestClassValues, estimatedTestClassValues, out errorState);
     143        if (errorState == OnlineCalculatorError.None) ClassificationPerformanceMeasures.TestF1Score = f1Test;
     144      }
    144145
    145146      var mccTraining = MatthewsCorrelationCoefficientCalculator.Calculate(originalTrainingClassValues, estimatedTrainingClassValues, out errorState);
  • trunk/sources/HeuristicLab.Problems.DataAnalysis/3.4/OnlineCalculators/ClassificationPerformanceMeasuresCalculator.cs

    r12012 r13102  
    2323using System.Collections.Generic;
    2424using HeuristicLab.Common;
     25using HeuristicLab.Problems.DataAnalysis.OnlineCalculators;
    2526
    2627namespace HeuristicLab.Problems.DataAnalysis {
  • trunk/sources/HeuristicLab.Problems.DataAnalysis/3.4/OnlineCalculators/ConfusionMatrixCalculator.cs

    r13100 r13102  
    2424using System.Linq;
    2525
    26 namespace HeuristicLab.Problems.DataAnalysis.OnlineCalculators {
     26namespace HeuristicLab.Problems.DataAnalysis {
    2727  public class ConfusionMatrixCalculator {
    2828    public static double[,] Calculate(IEnumerable<double> originalValues, IEnumerable<double> estimatedValues, out OnlineCalculatorError errorState) {
  • trunk/sources/HeuristicLab.Problems.DataAnalysis/3.4/OnlineCalculators/FOneScoreCalculator.cs

    r13100 r13102  
    2424using System.Linq;
    2525
    26 namespace HeuristicLab.Problems.DataAnalysis.OnlineCalculators {
     26namespace HeuristicLab.Problems.DataAnalysis {
    2727  public class FOneScoreCalculator {
    2828    public static double Calculate(IEnumerable<double> originalValues, IEnumerable<double> estimatedValues, out OnlineCalculatorError errorState) {
Note: See TracChangeset for help on using the changeset viewer.