Changeset 8086 for branches/ScatterSearch (trunk integration)/HeuristicLab.Selection/3.3/GeneralizedRankSelector.cs
- Timestamp:
- 06/22/12 11:11:38 (13 years ago)
- Location:
- branches/ScatterSearch (trunk integration)
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/ScatterSearch (trunk integration)
- Property svn:ignore
-
old new 20 20 bin 21 21 protoc.exe 22 _ReSharper.HeuristicLab 3.3 Tests
-
- Property svn:mergeinfo changed
- Property svn:ignore
-
branches/ScatterSearch (trunk integration)/HeuristicLab.Selection/3.3/GeneralizedRankSelector.cs
r7259 r8086 63 63 double pressure = PressureParameter.ActualValue.Value; 64 64 65 var ordered = qualities. Select((x, index) => new KeyValuePair<int, double>(index, x.Value)).OrderBy(x => x.Value).ToList();65 var ordered = qualities.Where(x => IsValidQuality(x.Value)).Select((x, index) => new KeyValuePair<int, double>(index, x.Value)).OrderBy(x => x.Value).ToList(); 66 66 if (maximization) ordered.Reverse(); 67 68 //check if list with indexes is as long as the original scope list 69 //otherwise invalid quality values were filtered 70 if (ordered.Count != scopes.Count) { 71 throw new ArgumentException("The scopes contain invalid quality values (either infinity or double.NaN) on which the selector cannot operate."); 72 } 67 73 68 74 int m = scopes.Count;
Note: See TracChangeset
for help on using the changeset viewer.