- Timestamp:
- 03/23/10 01:48:44 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Algorithms.TabuSearch/3.3/TabuSelector.cs
r3140 r3195 72 72 get { return (IValueLookupParameter<BoolValue>)Parameters["CopySelected"]; } 73 73 } 74 public ILookupParameter<BoolValue> EmptyNeighborhoodParameter { 75 get { return (ILookupParameter<BoolValue>)Parameters["EmptyNeighborhood"]; } 76 } 74 77 75 78 public BoolValue CopySelected { … … 90 93 Parameters.Add(new SubScopesLookupParameter<BoolValue>("MoveTabu", "The tabu status of the move.")); 91 94 Parameters.Add(new ValueLookupParameter<BoolValue>("CopySelected", "True if the selected move should be copied.", new BoolValue(false))); 95 Parameters.Add(new LookupParameter<BoolValue>("EmptyNeighborhood", "Will be set to true if the neighborhood didn't contain any non-tabu moves. It is not set to false.")); 92 96 } 93 97 … … 120 124 } 121 125 122 if (selected[0] == null) throw new InvalidOperationException("TabuSelector: The neighborhood contained no or too little moves that are not tabu."); 126 if (selected[0] == null) { 127 EmptyNeighborhoodParameter.ActualValue = new BoolValue(true); 128 selected[0] = new Scope("All moves are tabu."); 129 } 123 130 124 131 // remove from last to first so that the stored indices remain the same
Note: See TracChangeset
for help on using the changeset viewer.