Changeset 11929 for stable/HeuristicLab.Encodings.BinaryVectorEncoding/3.3/Manipulators/SomePositionsBitflipManipulator.cs
- Timestamp:
- 02/06/15 08:30:19 (10 years ago)
- Location:
- stable
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
stable
- Property svn:mergeinfo changed
/trunk/sources merged: 11410-11411,11909
- Property svn:mergeinfo changed
-
stable/HeuristicLab.Encodings.BinaryVectorEncoding/3.3/Manipulators/SomePositionsBitflipManipulator.cs
r11170 r11929 20 20 #endregion 21 21 22 using System; 22 23 using HeuristicLab.Common; 23 24 using HeuristicLab.Core; … … 39 40 /// Mmutation probability for each position. 40 41 /// </summary> 41 public ValueLookupParameter<DoubleValue> MutationProbabilityParameter {42 get { return ( ValueLookupParameter<DoubleValue>)Parameters["MutationProbability"]; }42 public IValueLookupParameter<DoubleValue> MutationProbabilityParameter { 43 get { return (IValueLookupParameter<DoubleValue>)Parameters["MutationProbability"]; } 43 44 } 44 45 … … 78 79 /// <param name="realVector">The vector of binary values to manipulate.</param> 79 80 protected override void Manipulate(IRandom random, BinaryVector binaryVector) { 80 Apply(random, binaryVector, MutationProbabilityParameter.Value); 81 if (MutationProbabilityParameter.ActualValue == null) throw new InvalidOperationException("SomePositionsBitflipManipulator: Parameter " + MutationProbabilityParameter.ActualName + " could not be found."); 82 Apply(random, binaryVector, MutationProbabilityParameter.ActualValue); 81 83 } 82 84 }
Note: See TracChangeset
for help on using the changeset viewer.