Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
03/07/13 16:13:17 (11 years ago)
Author:
abeham
Message:

#1961:

  • Improved performance of CMA-ES without ALGLIB
    • All CMA-ES parameter are standard .NET types instead of HL types
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/CMAES/HeuristicLab.Algorithms.CMAEvolutionStrategy/3.3/Terminator.cs

    r9129 r9297  
    169169
    170170      double minSqrtdiagC = int.MaxValue, maxSqrtdiagC = int.MinValue;
    171       for (int i = 0; i < sp.C.Rows; i++) {
     171      for (int i = 0; i < sp.C.GetLength(0); i++) {
    172172        if (Math.Sqrt(sp.C[i, i]) < minSqrtdiagC) minSqrtdiagC = Math.Sqrt(sp.C[i, i]);
    173173        if (Math.Sqrt(sp.C[i, i]) > maxSqrtdiagC) maxSqrtdiagC = Math.Sqrt(sp.C[i, i]);
     
    175175
    176176      var tolx = MinimumStandardDeviationParameter.ActualValue.Value;
    177       if (sp.Sigma.Value * maxSqrtdiagC < tolx
    178           && sp.Sigma.Value * sp.PC.Select(x => Math.Abs(x)).Max() < tolx) return terminateOp;
     177      if (sp.Sigma * maxSqrtdiagC < tolx
     178          && sp.Sigma * sp.PC.Select(x => Math.Abs(x)).Max() < tolx) return terminateOp;
    179179
    180180      var stopTolUpXFactor = MaximumStandardDeviationChangeParameter.ActualValue.Value;
    181       if (sp.Sigma.Value * maxSqrtdiagC > stopTolUpXFactor * InitialSigmaParameter.ActualValue.Max())
     181      if (sp.Sigma * maxSqrtdiagC > stopTolUpXFactor * InitialSigmaParameter.ActualValue.Max())
    182182        return terminateOp;
    183183
Note: See TracChangeset for help on using the changeset viewer.