Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
07/30/09 10:47:00 (15 years ago)
Author:
gkronber
Message:

GP Refactoring: #713

  • added project GP.Operators
  • moved operators from plugin GP to plugin GP.Operators
  • deleted unused constraints
  • removed dependency of GP plugins on Constraints plugin
  • moved StructID functions into directory Symbols
  • deleted unused class FunView
  • implemented add and remove functionality for the FunctionLibraryView
Location:
branches/GP-Refactoring-713/sources/HeuristicLab.GP.Operators
Files:
2 added
7 edited
1 moved

Legend:

Unmodified
Added
Removed
  • branches/GP-Refactoring-713/sources/HeuristicLab.GP.Operators/3.3/Manipulation/ChangeNodeTypeManipulation.cs

    r2211 r2212  
    2020#endregion
    2121
    22 using System;
    2322using System.Collections.Generic;
    2423using System.Linq;
    25 using System.Text;
    2624using HeuristicLab.Core;
    27 using HeuristicLab.Operators;
    2825using HeuristicLab.Random;
    29 using HeuristicLab.Data;
    30 using HeuristicLab.Constraints;
    3126using System.Diagnostics;
    3227using HeuristicLab.GP.Interfaces;
    3328
    34 namespace HeuristicLab.GP {
     29namespace HeuristicLab.GP.Operators {
    3530  public class ChangeNodeTypeManipulation : GPManipulatorBase {
    3631
     
    7368        // size and height stays the same when changing a terminal so no need to update the variables
    7469        // schedule an operation to initialize the new terminal
    75         return TreeGardener.CreateInitializationOperation(TreeGardener.GetAllSubTrees(newTerminal), scope);
     70        return Util.CreateInitializationOperation(TreeGardener.GetAllSubTrees(newTerminal), scope);
    7671      } else {
    7772        List<IFunctionTree> uninitializedBranches;
     
    10499        Debug.Assert(gardener.IsValidTree(gpModel.FunctionTree));
    105100        // return a composite operation that initializes all created sub-trees
    106         return TreeGardener.CreateInitializationOperation(uninitializedBranches, scope);
     101        return Util.CreateInitializationOperation(uninitializedBranches, scope);
    107102      }
    108103    }
  • branches/GP-Refactoring-713/sources/HeuristicLab.GP.Operators/3.3/Manipulation/CutOutNodeManipulation.cs

    r2210 r2212  
    2323using System.Linq;
    2424using HeuristicLab.Core;
    25 using HeuristicLab.Data;
    26 using HeuristicLab.Operators;
    2725using HeuristicLab.Random;
    28 using System;
    2926using System.Diagnostics;
    3027using HeuristicLab.GP.Interfaces;
    3128
    32 namespace HeuristicLab.GP {
     29namespace HeuristicLab.GP.Operators {
    3330  public class CutOutNodeManipulation : GPManipulatorBase {
    3431    public override string Description {
     
    7168
    7269          // schedule an operation to initialize the whole tree
    73           return TreeGardener.CreateInitializationOperation(TreeGardener.GetAllSubTrees(gpModel.FunctionTree), scope);
     70          return Util.CreateInitializationOperation(TreeGardener.GetAllSubTrees(gpModel.FunctionTree), scope);
    7471        }
    7572      }
     
    108105        gpModel.Height = gpModel.FunctionTree.GetHeight();
    109106        // schedule an initialization operation for the new function-tree
    110         return TreeGardener.CreateInitializationOperation(TreeGardener.GetAllSubTrees(newFunctionTree), scope);
     107        return Util.CreateInitializationOperation(TreeGardener.GetAllSubTrees(newFunctionTree), scope);
    111108      }
    112109    }
  • branches/GP-Refactoring-713/sources/HeuristicLab.GP.Operators/3.3/Manipulation/DeleteSubTreeManipulation.cs

    r2211 r2212  
    2020#endregion
    2121
    22 using System;
    2322using System.Collections.Generic;
    2423using HeuristicLab.Core;
    25 using HeuristicLab.Data;
    26 using HeuristicLab.Operators;
    2724using HeuristicLab.Random;
    2825using System.Diagnostics;
    2926using HeuristicLab.GP.Interfaces;
    3027
    31 namespace HeuristicLab.GP {
     28namespace HeuristicLab.GP.Operators {
    3229  public class DeleteSubTreeManipulation : GPManipulatorBase {
    3330    public override string Description {
     
    5451        gpModel.FunctionTree = newTree;
    5552        // schedule an operation to initialize the newly created operator
    56         return TreeGardener.CreateInitializationOperation(TreeGardener.GetAllSubTrees(newTree), scope);
     53        return Util.CreateInitializationOperation(TreeGardener.GetAllSubTrees(newTree), scope);
    5754      }
    5855
     
    8481        gpModel.Height = gpModel.FunctionTree.GetHeight();
    8582        // return an initialization operation for the newly created tree
    86         return TreeGardener.CreateInitializationOperation(TreeGardener.GetAllSubTrees(newFunctionTree), scope);
     83        return Util.CreateInitializationOperation(TreeGardener.GetAllSubTrees(newFunctionTree), scope);
    8784      }
    8885    }
  • branches/GP-Refactoring-713/sources/HeuristicLab.GP.Operators/3.3/Manipulation/FullTreeShaker.cs

    r2210 r2212  
    2020#endregion
    2121
    22 using System;
    23 using System.Collections.Generic;
    2422using System.Linq;
    25 using System.Text;
    2623using HeuristicLab.Core;
    2724using HeuristicLab.Operators;
    2825using HeuristicLab.Random;
    2926using HeuristicLab.Data;
     27using HeuristicLab.GP.Interfaces;
    3028using HeuristicLab.Selection;
    31 using HeuristicLab.GP.Interfaces;
    3229
    33 namespace HeuristicLab.GP {
     30namespace HeuristicLab.GP.Operators {
    3431  public class FullTreeShaker : DelegatingOperator {
    3532    public override string Description {
  • branches/GP-Refactoring-713/sources/HeuristicLab.GP.Operators/3.3/Manipulation/GPManipulatorBase.cs

    r2210 r2212  
    2020#endregion
    2121
    22 using System;
    23 using System.Collections.Generic;
    24 using System.Linq;
    25 using System.Text;
    2622using HeuristicLab.Core;
    27 using HeuristicLab.Operators;
    2823using HeuristicLab.Random;
    2924using HeuristicLab.Data;
    30 using HeuristicLab.Constraints;
    31 using System.Diagnostics;
    32 using HeuristicLab.Evolutionary;
    3325using HeuristicLab.GP.Interfaces;
    3426
    35 namespace HeuristicLab.GP {
     27namespace HeuristicLab.GP.Operators {
    3628  public abstract class GPManipulatorBase : OperatorBase {
    3729    public GPManipulatorBase()
  • branches/GP-Refactoring-713/sources/HeuristicLab.GP.Operators/3.3/Manipulation/OnePointShaker.cs

    r2210 r2212  
    2020#endregion
    2121
    22 using System;
    23 using System.Collections.Generic;
    2422using System.Linq;
    25 using System.Text;
    2623using HeuristicLab.Core;
    2724using HeuristicLab.Operators;
     
    3128using HeuristicLab.GP.Interfaces;
    3229
    33 namespace HeuristicLab.GP {
     30namespace HeuristicLab.GP.Operators {
    3431  public class OnePointShaker : DelegatingOperator {
    3532    public override string Description {
  • branches/GP-Refactoring-713/sources/HeuristicLab.GP.Operators/3.3/Manipulation/SubstituteSubTreeManipulation.cs

    r2210 r2212  
    2222using System;
    2323using System.Collections.Generic;
    24 using System.Linq;
    2524using HeuristicLab.Core;
    26 using HeuristicLab.Data;
    27 using HeuristicLab.Operators;
    2825using HeuristicLab.Random;
    2926using System.Diagnostics;
    3027using HeuristicLab.GP.Interfaces;
    3128
    32 namespace HeuristicLab.GP {
     29namespace HeuristicLab.GP.Operators {
    3330  public class SubstituteSubTreeManipulation : GPManipulatorBase {
    3431
     
    5249        gpModel.FunctionTree = newTree;
    5350        // return a CompositeOperation that randomly initializes the new tree
    54         return TreeGardener.CreateInitializationOperation(TreeGardener.GetAllSubTrees(newTree), scope);
     51        return Util.CreateInitializationOperation(TreeGardener.GetAllSubTrees(newTree), scope);
    5552      } else {
    5653        // determine a random child of the parent to be replaced
     
    8178        // the root hasn't changed so we don't need to update
    8279        // return a CompositeOperation that randomly initializes all nodes of the new subtree
    83         return TreeGardener.CreateInitializationOperation(TreeGardener.GetAllSubTrees(newTree), scope);
     80        return Util.CreateInitializationOperation(TreeGardener.GetAllSubTrees(newTree), scope);
    8481      }
    8582    }
Note: See TracChangeset for help on using the changeset viewer.