Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
03/18/11 15:36:57 (14 years ago)
Author:
svonolfe
Message:

Integrated VNS into trunk (#1425)

Location:
trunk/sources
Files:
4 edited
1 copied

Legend:

Unmodified
Added
Removed
  • trunk/sources

  • trunk/sources/HeuristicLab.Algorithms.SimulatedAnnealing/3.3/HeuristicLab.Algorithms.SimulatedAnnealing-3.3.csproj

    r5163 r5753  
    1212    <AssemblyName>HeuristicLab.Algorithms.SimulatedAnnealing-3.3</AssemblyName>
    1313    <TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
    14     <TargetFrameworkProfile></TargetFrameworkProfile>
     14    <TargetFrameworkProfile>
     15    </TargetFrameworkProfile>
    1516    <FileAlignment>512</FileAlignment>
    1617    <SignAssembly>true</SignAssembly>
     
    107108  <ItemGroup>
    108109    <Compile Include="HeuristicLabAlgorithmsSimulatedAnnealingPlugin.cs" />
     110    <Compile Include="SimulatedAnnealingImprovementOperator.cs" />
    109111    <Compile Include="Properties\AssemblyInfo.cs" />
    110112    <Compile Include="SimulatedAnnealing.cs" />
  • trunk/sources/HeuristicLab.Algorithms.SimulatedAnnealing/3.3/SimulatedAnnealing.cs

    r5445 r5753  
    189189      variableCreator.Name = "Initialize EvaluatedMoves";
    190190      variableCreator.CollectedValues.Add(new ValueParameter<IntValue>("EvaluatedMoves", new IntValue()));
     191      variableCreator.CollectedValues.Add(new ValueParameter<IntValue>("Iterations", new IntValue(0)));
    191192      variableCreator.Successor = resultsCollector;
    192193
     
    206207      mainLoop.AnalyzerParameter.ActualName = AnalyzerParameter.Name;
    207208      mainLoop.EvaluatedMovesParameter.ActualName = "EvaluatedMoves";
     209      mainLoop.IterationsParameter.ActualName = "Iterations";
    208210
    209211      foreach (IDiscreteDoubleValueModifier op in ApplicationManager.Manager.GetInstances<IDiscreteDoubleValueModifier>().OrderBy(x => x.Name))
  • trunk/sources/HeuristicLab.Algorithms.SimulatedAnnealing/3.3/SimulatedAnnealingMainLoop.cs

    r5445 r5753  
    6060      get { return (ValueLookupParameter<IntValue>)Parameters["InnerIterations"]; }
    6161    }
     62    public LookupParameter<IntValue> IterationsParameter {
     63      get { return (LookupParameter<IntValue>)Parameters["LocalIterations"]; }
     64    }
    6265    public ValueLookupParameter<IntValue> MaximumIterationsParameter {
    6366      get { return (ValueLookupParameter<IntValue>)Parameters["MaximumIterations"]; }
     
    109112      Parameters.Add(new ValueLookupParameter<DoubleValue>("EndTemperature", "The end temperature."));
    110113      Parameters.Add(new ValueLookupParameter<IntValue>("InnerIterations", "The amount of inner iterations (number of moves before temperature is adjusted again)."));
     114      Parameters.Add(new LookupParameter<IntValue>("LocalIterations", "The number of generations."));
    111115      Parameters.Add(new ValueLookupParameter<IntValue>("MaximumIterations", "The maximum number of iterations which should be processed."));
    112116
     
    144148      ConditionalBranch iterationsTermination = new ConditionalBranch();
    145149
    146       variableCreator.CollectedValues.Add(new ValueParameter<IntValue>("Iterations", new IntValue(0))); // Class SimulatedAnnealing expects this to be called Iterations
    147150      variableCreator.CollectedValues.Add(new ValueParameter<DoubleValue>("Temperature", new DoubleValue(double.MaxValue)));
    148151
    149       resultsCollector1.CollectedValues.Add(new LookupParameter<IntValue>("Iterations"));
     152      resultsCollector1.CollectedValues.Add(new LookupParameter<IntValue>(IterationsParameter.Name));
    150153      resultsCollector1.CollectedValues.Add(new LookupParameter<DoubleValue>("Temperature"));
    151154      resultsCollector1.ResultsParameter.ActualName = ResultsParameter.Name;
     
    180183      iterationsCounter.Name = "Increment Iterations";
    181184      iterationsCounter.Increment = new IntValue(1);
    182       iterationsCounter.ValueParameter.ActualName = "Iterations";
     185      iterationsCounter.ValueParameter.ActualName = IterationsParameter.Name;
    183186
    184187      iterationsComparator.Name = "Iterations >= MaximumIterations";
    185       iterationsComparator.LeftSideParameter.ActualName = "Iterations";
     188      iterationsComparator.LeftSideParameter.ActualName = IterationsParameter.Name;
    186189      iterationsComparator.RightSideParameter.ActualName = MaximumIterationsParameter.Name;
    187190      iterationsComparator.ResultParameter.ActualName = "Terminate";
Note: See TracChangeset for help on using the changeset viewer.