Free cookie consent management tool by TermsFeed Policy Generator

source: trunk/tools/HL3Snippets/HL3.BackwardsCompatibility.snippet @ 14599

Last change on this file since 14599 was 6042, checked in by abeham, 14 years ago

#1425

  • Changed LocalImprovementOperators
    • Changed interface (made Problem a property, added a property that denotes the type of the problem that it can be applied on, added some general parameters)
    • Added some parameters and wiring
    • Changed move discovery and parameterization and added a helper class to ease finding compatible move operators
    • Discovering only IMultiMoveOperators and IExhaustiveMoveOperators and putting the multi move ones first
    • Fixed bug in Apply method that could create an endless string of nested execution contexts
    • Removed all problem specific analyzers in the two local improvement operators and only left the BestAverageWorstQualityAnalyzer since it doesn't make any sense to perform diversity or allele analysis during local improvement in the most common case and those analyzers take a lot of time (one can always add them manually should he/she be interested). The analyzers in the VNS's Analyzer parameter are left untouched.
  • Removed shaking operator and interface from VNS plugin and added that to Optimization and Optimization.Operators
  • Changed some ValueParameters to ConstrainedValueParameters and added type discovery to fill them (using the ProblemType property to get compatible local improvement operators)
  • Added missing GPL license headers
  • Changed some ValueParameters to the new FixedValueParameters
  • Added an additional encoding specific ShakingOperator to each encoding and added that to each problem
    • reason is that only the problem/encoding can really decide if a shaking operator is meaningful or not
  • Fixed an unrelated bug in the BestAverageWorstQualityAnalyzer that I encountered (and made the fix backwards compatible)
    • Also added a snippet for creating the backwards compatible comment marker and region
  • Fixed the operator graph of the VNS main loop
    • The condition to continue only when the local search was not successful is not necessary and is not part of the VNS definition as far as I know it (only condition to break the inner loop is when k reaches k_max)
  • Changed the ShakingOperator to input current index and output the maximum number of neighborhoods instead of a boolean that indicates that the last index has been reached since the maximum number is a little more generally useful and equally powerful in modeling
    • Remodeled the VNS main loop to check for k < k_max in order to continue the inner loop
  • other changes that I forgot...

Still necessary

  • test, test, test
  • check for backwards compatible breakers
  • add a maximum evaluated solutions stop criterion
  • optionally: implement fast problem specific local search improvement operators that do not build on the whole generic overhead (e.g. a 2-opt TSP specific local search operator). The idea of VNS is really to converge to a local optimum which is difficult to achieve using the current rather limited termination options
File size: 1.4 KB
Line 
1<?xml version="1.0" encoding="utf-8"?>
2<CodeSnippets xmlns="http://schemas.microsoft.com/VisualStudio/2005/CodeSnippet">
3  <CodeSnippet Format="1.0.0">
4    <Header>
5      <Title>HL3.BackwardsCompatibility</Title>
6      <Author>Andreas Beham</Author>
7      <Description>Adds the backwards compatibility comment and region</Description>
8      <HelpUrl>https://dev.heuristiclab.com/trac/hl/core/wiki/DevelopersCodeSnippets</HelpUrl>
9      <SnippetTypes>
10        <SnippetType>Expansion</SnippetType>
11      </SnippetTypes>
12      <Keywords />
13      <Shortcut>hl3BackwardsCompatibility</Shortcut>
14    </Header>
15    <Snippet>
16      <References />
17      <Imports />
18      <Declarations>
19        <Literal Editable="true">
20          <ID>currentversion</ID>
21          <Type />
22          <ToolTip>Enter the current major.minor version number</ToolTip>
23          <Default>3.3</Default>
24          <Function></Function>
25        </Literal>
26        <Literal Editable="true">
27          <ID>nextversion</ID>
28          <Type />
29          <ToolTip>Enter the next major.minor version number</ToolTip>
30          <Default>3.4</Default>
31          <Function></Function>
32        </Literal>
33      </Declarations>
34      <Code Language="csharp" Kind="" Delimiter="$"><![CDATA[// BackwardsCompatibility$currentversion$
35      #region Backwards compatible code, remove with $nextversion$
36     
37      #endregion]]></Code>
38    </Snippet>
39  </CodeSnippet>
40</CodeSnippets>
Note: See TracBrowser for help on using the repository browser.