- Timestamp:
- 07/06/09 17:12:37 (15 years ago)
- Location:
- trunk/sources/HeuristicLab.GP.StructureIdentification.ConditionalEvaluation/3.3
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.GP.StructureIdentification.ConditionalEvaluation/3.3/ConditionalCoefficientOfDeterminationEvaluator.cs
r1902 r2136 36 36 } 37 37 } 38 38 39 39 public override string Description { 40 40 get { … … 45 45 46 46 public override double Evaluate(double[,] values) { 47 double quality = SimpleR2Evaluator.Calculate(values); 48 if (double.IsNaN(quality) || double.IsInfinity(quality)) 49 quality = double.MaxValue; 50 51 return quality; 47 try { return SimpleR2Evaluator.Calculate(values); } 48 catch (ArgumentException) { 49 return double.NegativeInfinity; 50 } 52 51 } 53 52 } -
trunk/sources/HeuristicLab.GP.StructureIdentification.ConditionalEvaluation/3.3/ConditionalMeanAbsolutePercentageErrorEvaluator.cs
r1902 r2136 45 45 46 46 public override double Evaluate(double[,] values) { 47 double quality = SimpleMeanAbsolutePercentageErrorEvaluator.Calculate(values); 48 if (double.IsNaN(quality) || double.IsInfinity(quality)) 49 quality = double.MaxValue; 50 51 return quality; 47 try { return SimpleMeanAbsolutePercentageErrorEvaluator.Calculate(values); } 48 catch (ArgumentException) { 49 return double.PositiveInfinity; 50 } 52 51 } 53 52 } -
trunk/sources/HeuristicLab.GP.StructureIdentification.ConditionalEvaluation/3.3/ConditionalMeanAbsolutePercentageOfRangeErrorEvaluator.cs
r1902 r2136 44 44 45 45 public override double Evaluate(double[,] values) { 46 double quality = SimpleMeanAbsolutePercentageOfRangeErrorEvaluator.Calculate(values); 47 if (double.IsNaN(quality) || double.IsInfinity(quality)) 48 quality = double.MaxValue; 49 50 return quality; 46 try { 47 return SimpleMeanAbsolutePercentageOfRangeErrorEvaluator.Calculate(values); 48 } 49 catch (ArgumentException) { 50 return double.PositiveInfinity; 51 } 51 52 } 52 53 } -
trunk/sources/HeuristicLab.GP.StructureIdentification.ConditionalEvaluation/3.3/ConditionalMeanSquaredErrorEvaluator.cs
r1902 r2136 44 44 45 45 public override double Evaluate(double[,] values) { 46 double quality = SimpleMSEEvaluator.Calculate(values); 47 48 if (double.IsNaN(quality) || double.IsInfinity(quality)) { 49 quality = double.MaxValue; 46 try { 47 return SimpleMSEEvaluator.Calculate(values); 50 48 } 51 52 return quality; 49 catch (ArgumentException) { 50 return double.PositiveInfinity; 51 } 53 52 } 54 53 } -
trunk/sources/HeuristicLab.GP.StructureIdentification.ConditionalEvaluation/3.3/ConditionalVarianceAccountedForEvaluator.cs
r1902 r2136 53 53 54 54 public override double Evaluate(double[,] values) { 55 double quality = SimpleVarianceAccountedForEvaluator.Calculate(values); 56 57 if (double.IsNaN(quality) || double.IsInfinity(quality)) { 58 quality = double.MaxValue; 55 try { return SimpleVarianceAccountedForEvaluator.Calculate(values); } 56 catch (ArgumentException) { 57 return double.NegativeInfinity; 59 58 } 60 return quality;61 59 } 62 60 }
Note: See TracChangeset
for help on using the changeset viewer.