Changeset 4917 for branches/DataAnalysis.PopulationDiversityAnalysis/HeuristicLab.Problems.DataAnalysis.Regression
- Timestamp:
- 11/24/10 00:18:44 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/DataAnalysis.PopulationDiversityAnalysis/HeuristicLab.Problems.DataAnalysis.Regression/3.3/Symbolic/Analyzers/FineGrainedStructuralPopulationDiversityAnalyzer.cs
r4886 r4917 66 66 return result; 67 67 } 68 69 68 /* 70 69 #region private class GeneticInformationItem, ported from HL 2 … … 430 429 } 431 430 431 private static IList<GeneticInformationItem> getGeneticInformationItems(SymbolicExpressionTreeNode node) { 432 // Idea: collect all descendants' lists and then add new items using the retrieved ones. 433 // This should save lots of time and reduce complexity of the items retrieval process. 434 List<GeneticInformationItem> list = new List<GeneticInformationItem>(); 435 for (int i = 0; i < node.SubTrees.Count; i++) { 436 IList<GeneticInformationItem> descendantItems = getGeneticInformationItems(node.SubTrees[i]); 437 list.AddRange(descendantItems); 438 foreach (GeneticInformationItem item in descendantItems) { 439 GeneticInformationItem newItem = new GeneticInformationItem(); 440 newItem.AncestorIndex = i; 441 newItem.AncestorDefinition = node.Symbol.GetType(); 442 // ... TODO! 443 } 444 } 445 return list; 446 } 447 432 448 } 433 449 434 450 #endregion 435 451 */ 436 437 452 } 438 453 }
Note: See TracChangeset
for help on using the changeset viewer.