Changeset 6760 for branches/PersistenceSpeedUp/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/Analyzers/SymbolicDataAnalysisAlleleFrequencyAnalyzer.cs
- Timestamp:
- 09/14/11 13:59:25 (13 years ago)
- Location:
- branches/PersistenceSpeedUp
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/PersistenceSpeedUp
- Property svn:ignore
-
old new 12 12 *.psess 13 13 *.vsp 14 *.docstates
-
- Property svn:mergeinfo changed
- Property svn:ignore
-
branches/PersistenceSpeedUp/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/Analyzers/SymbolicDataAnalysisAlleleFrequencyAnalyzer.cs
r6135 r6760 20 20 #endregion 21 21 22 using System ;22 using System.Collections.Generic; 23 23 using System.Linq; 24 using System.Text; 24 25 using HeuristicLab.Analysis; 25 26 using HeuristicLab.Common; 26 27 using HeuristicLab.Core; 27 28 using HeuristicLab.Data; 29 using HeuristicLab.Encodings.SymbolicExpressionTreeEncoding; 28 30 using HeuristicLab.Parameters; 29 31 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 30 using System.Collections.Generic;31 using System.Text;32 using HeuristicLab.Encodings.SymbolicExpressionTreeEncoding;33 32 34 33 namespace HeuristicLab.Problems.DataAnalysis.Symbolic { … … 47 46 } 48 47 49 public I ValueParameter<IntValue> AlleleTreeDepthParameter {48 public IFixedValueParameter<IntValue> AlleleTreeDepthParameter { 50 49 get { return (IFixedValueParameter<IntValue>)Parameters[AlleleTreeDepthParameterName]; } 51 50 } … … 71 70 72 71 protected override Allele[] CalculateAlleles(ISymbolicExpressionTree solution) { 73 List<Allele> alleles = new List<Allele>(); 74 75 foreach (var subtree in GetAllSubtreesOfDepth(solution, AlleleTreeDepth)) { 76 alleles.Add(GetAlleleFromSubtreeOfDepth(subtree, AlleleTreeDepth)); 77 } 78 return alleles.ToArray(); 72 return GetAllSubtreesOfDepth(solution, AlleleTreeDepth) 73 .AsParallel() 74 .Select(t => GetAlleleFromSubtreeOfDepth(t, AlleleTreeDepth)) 75 .ToArray(); 79 76 } 80 77
Note: See TracChangeset
for help on using the changeset viewer.