Changeset 9090 for branches/LearningClassifierSystems/HeuristicLab.Encodings.CombinedIntegerVectorEncoding/3.3/Covering
- Timestamp:
- 12/29/12 20:15:48 (12 years ago)
- Location:
- branches/LearningClassifierSystems/HeuristicLab.Encodings.CombinedIntegerVectorEncoding/3.3
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/LearningClassifierSystems/HeuristicLab.Encodings.CombinedIntegerVectorEncoding/3.3
- Property svn:ignore
-
old new 1 1 *.user 2 2 Plugin.cs 3 obj
-
- Property svn:ignore
-
branches/LearningClassifierSystems/HeuristicLab.Encodings.CombinedIntegerVectorEncoding/3.3/Covering/CombinedIntegerVectorCoveringCreator.cs
r9089 r9090 28 28 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 29 29 30 namespace HeuristicLab.Encodings.CombinedIntegerVectorEncoding .Covering{30 namespace HeuristicLab.Encodings.CombinedIntegerVectorEncoding { 31 31 [Item("CombinedIntegerVectorCoveringCreator", "Description missing")] 32 32 [StorableClass] … … 43 43 get { return (IValueLookupParameter<IClassifier>)Parameters["CreatedClassifier"]; } 44 44 } 45 public I ValueLookupParameter<PercentValue> ChangeSymbolProbabilityParameter {46 get { return (I ValueLookupParameter<PercentValue>)Parameters["ChangeSymbolProbability"]; }45 public ILookupParameter<PercentValue> ChangeSymbolProbabilityParameter { 46 get { return (ILookupParameter<PercentValue>)Parameters["ChangeSymbolProbability"]; } 47 47 } 48 public ILookupParameter<IRandom> RandomParameter { 49 get { return (ILookupParameter<IRandom>)Parameters["Random"]; } 50 } 51 48 52 #endregion 49 53 … … 61 65 Parameters.Add(new LookupParameter<IClassifier>("Action")); 62 66 Parameters.Add(new ValueLookupParameter<IClassifier>("CreatedClassifier")); 63 Parameters.Add(new ValueLookupParameter<PercentValue>("ChangeSymbolProbability")); 67 Parameters.Add(new LookupParameter<PercentValue>("ChangeSymbolProbability")); 68 Parameters.Add(new LookupParameter<IRandom>("Random")); 64 69 } 65 70 66 71 public override IOperation Apply() { 72 CombinedIntegerVector newCondition = (CombinedIntegerVector)CoverClassifierParameter.ActualValue.Condition.Clone(); 73 67 74 CombinedIntegerVector condition = (CombinedIntegerVector)CoverClassifierParameter.ActualValue.Condition; 68 75 CombinedIntegerVector action = (CombinedIntegerVector)ActionParameter.ActualValue.Action; 69 76 70 //TODO: manipulation77 newCondition = UniformSomePositionInConditionManipulator.ManipulateCondition(RandomParameter.ActualValue, condition, newCondition, ChangeSymbolProbabilityParameter.ActualValue.Value); 71 78 72 CreatedClassifierParameter.ActualValue = new CombinedIntegerVector( condition, condition.Bounds, action, action.Bounds);79 CreatedClassifierParameter.ActualValue = new CombinedIntegerVector(newCondition, newCondition.Bounds, action, action.Bounds); 73 80 return base.Apply(); 74 81 }
Note: See TracChangeset
for help on using the changeset viewer.