- Timestamp:
- 04/30/13 16:54:43 (12 years ago)
- Location:
- branches/LearningClassifierSystems/HeuristicLab.Algorithms.DataAnalysis/3.4
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
TabularUnified branches/LearningClassifierSystems/HeuristicLab.Algorithms.DataAnalysis/3.4/CrossValidation.cs ¶
r8970 r9411 29 29 using HeuristicLab.Core; 30 30 using HeuristicLab.Data; 31 using HeuristicLab.Encodings.ConditionActionEncoding; 31 32 using HeuristicLab.Optimization; 33 using HeuristicLab.Optimization.Operators.LCS; 32 34 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 33 35 using HeuristicLab.Problems.DataAnalysis; … … 405 407 results.Add(result.Name, result.Value); 406 408 } 409 foreach (IResult result in ExtractAndAggregateGAssistSolutions(resultCollections)) { 410 results.Add(result.Name, result.Value); 411 } 412 foreach (IResult result in ExtractAndAggregateConditionActionSolutions(resultCollections)) { 413 results.Add(result.Name, result.Value); 414 } 407 415 results.Add("Execution Time", new TimeSpanValue(this.ExecutionTime)); 408 416 results.Add("CrossValidation Folds", new RunCollection(runs)); 417 } 418 419 private IEnumerable<IResult> ExtractAndAggregateConditionActionSolutions(IEnumerable<KeyValuePair<string, IItem>> resultCollections) { 420 Dictionary<string, List<IConditionActionSolution>> resultSolutions = new Dictionary<string, List<IConditionActionSolution>>(); 421 foreach (var result in resultCollections) { 422 var conditionActionSolution = result.Value as IConditionActionSolution; 423 if (conditionActionSolution != null) { 424 if (resultSolutions.ContainsKey(result.Key)) { 425 resultSolutions[result.Key].Add(conditionActionSolution); 426 } else { 427 resultSolutions.Add(result.Key, new List<IConditionActionSolution>() { conditionActionSolution }); 428 } 429 } 430 } 431 List<IResult> aggregatedResults = new List<IResult>(); 432 foreach (KeyValuePair<string, List<IConditionActionSolution>> solutions in resultSolutions) { 433 // clone manually to correctly clone references between cloned root objects 434 Cloner cloner = new Cloner(); 435 var problemDataClone = (IConditionActionProblemData)cloner.Clone(Problem.ProblemData); 436 // set partitions of problem data clone correctly 437 problemDataClone.TrainingPartition.Start = SamplesStart.Value; problemDataClone.TrainingPartition.End = SamplesEnd.Value; 438 problemDataClone.TestPartition.Start = SamplesStart.Value; problemDataClone.TestPartition.End = SamplesEnd.Value; 439 // clone models 440 var ensembleSolution = new ConditionActionEnsembleSolution(problemDataClone); 441 ensembleSolution.AddConditionActionSolutions(solutions.Value); 442 443 aggregatedResults.Add(new Result(solutions.Key + " (ensemble)", ensembleSolution)); 444 } 445 List<IResult> flattenedResults = new List<IResult>(); 446 CollectResultsRecursively("", aggregatedResults, flattenedResults); 447 return flattenedResults; 448 } 449 450 private IEnumerable<IResult> ExtractAndAggregateGAssistSolutions(IEnumerable<KeyValuePair<string, IItem>> resultCollections) { 451 Dictionary<string, List<IGAssistSolution>> resultSolutions = new Dictionary<string, List<IGAssistSolution>>(); 452 foreach (var result in resultCollections) { 453 var gassistSolution = result.Value as IGAssistSolution; 454 if (gassistSolution != null) { 455 if (resultSolutions.ContainsKey(result.Key)) { 456 resultSolutions[result.Key].Add(gassistSolution); 457 } else { 458 resultSolutions.Add(result.Key, new List<IGAssistSolution>() { gassistSolution }); 459 } 460 } 461 } 462 List<IResult> aggregatedResults = new List<IResult>(); 463 foreach (KeyValuePair<string, List<IGAssistSolution>> solutions in resultSolutions) { 464 // clone manually to correctly clone references between cloned root objects 465 Cloner cloner = new Cloner(); 466 var problemDataClone = (IGAssistProblemData)cloner.Clone(Problem.ProblemData); 467 // set partitions of problem data clone correctly 468 problemDataClone.TrainingPartition.Start = SamplesStart.Value; problemDataClone.TrainingPartition.End = SamplesEnd.Value; 469 problemDataClone.TestPartition.Start = SamplesStart.Value; problemDataClone.TestPartition.End = SamplesEnd.Value; 470 // clone models 471 var ensembleSolution = new GAssistEnsembleSolution(problemDataClone); 472 ensembleSolution.AddGAssistSolutions(solutions.Value); 473 474 aggregatedResults.Add(new Result(solutions.Key + " (ensemble)", ensembleSolution)); 475 } 476 List<IResult> flattenedResults = new List<IResult>(); 477 CollectResultsRecursively("", aggregatedResults, flattenedResults); 478 return flattenedResults; 409 479 } 410 480 -
TabularUnified branches/LearningClassifierSystems/HeuristicLab.Algorithms.DataAnalysis/3.4/HeuristicLab.Algorithms.DataAnalysis-3.4.csproj ¶
r9359 r9411 43 43 <DebugType>full</DebugType> 44 44 <Optimize>false</Optimize> 45 <OutputPath> $(SolutionDir)\bin\</OutputPath>45 <OutputPath>..\..\..\..\trunk\sources\bin\</OutputPath> 46 46 <DefineConstants>DEBUG;TRACE</DefineConstants> 47 47 <ErrorReport>prompt</ErrorReport> … … 52 52 <DebugType>pdbonly</DebugType> 53 53 <Optimize>true</Optimize> 54 <OutputPath> $(SolutionDir)\bin\</OutputPath>54 <OutputPath>..\..\..\..\trunk\sources\bin\</OutputPath> 55 55 <DefineConstants>TRACE</DefineConstants> 56 56 <ErrorReport>prompt</ErrorReport> … … 62 62 <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' "> 63 63 <DebugSymbols>true</DebugSymbols> 64 <OutputPath> $(SolutionDir)\bin\</OutputPath>64 <OutputPath>..\..\..\..\trunk\sources\bin\</OutputPath> 65 65 <DefineConstants>DEBUG;TRACE</DefineConstants> 66 66 <DebugType>full</DebugType> … … 70 70 </PropertyGroup> 71 71 <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' "> 72 <OutputPath> $(SolutionDir)\bin\</OutputPath>72 <OutputPath>..\..\..\..\trunk\sources\bin\</OutputPath> 73 73 <DefineConstants>TRACE</DefineConstants> 74 74 <DocumentationFile> … … 82 82 <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x64' "> 83 83 <DebugSymbols>true</DebugSymbols> 84 <OutputPath> $(SolutionDir)\bin\</OutputPath>84 <OutputPath>..\..\..\..\trunk\sources\bin\</OutputPath> 85 85 <DefineConstants>DEBUG;TRACE</DefineConstants> 86 86 <DebugType>full</DebugType> … … 90 90 </PropertyGroup> 91 91 <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x64' "> 92 <OutputPath> $(SolutionDir)\bin\</OutputPath>92 <OutputPath>..\..\..\..\trunk\sources\bin\</OutputPath> 93 93 <DefineConstants>TRACE</DefineConstants> 94 94 <DocumentationFile> … … 102 102 <ItemGroup> 103 103 <Reference Include="ALGLIB-3.7.0, Version=3.7.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL"> 104 <HintPath>..\..\ bin\ALGLIB-3.7.0.dll</HintPath>104 <HintPath>..\..\..\..\trunk\sources\bin\ALGLIB-3.7.0.dll</HintPath> 105 105 <Private>False</Private> 106 106 </Reference> 107 107 <Reference Include="AutoDiff-1.0, Version=1.0.0.14388, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL"> 108 108 <SpecificVersion>False</SpecificVersion> 109 <HintPath>..\..\bin\AutoDiff-1.0.dll</HintPath> 109 <HintPath>..\..\..\..\trunk\sources\bin\AutoDiff-1.0.dll</HintPath> 110 </Reference> 111 <Reference Include="HeuristicLab.Algorithms.GradientDescent-3.3"> 112 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Algorithms.GradientDescent-3.3.dll</HintPath> 113 </Reference> 114 <Reference Include="HeuristicLab.Analysis-3.3"> 115 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Analysis-3.3.dll</HintPath> 116 </Reference> 117 <Reference Include="HeuristicLab.Collections-3.3"> 118 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Collections-3.3.dll</HintPath> 119 </Reference> 120 <Reference Include="HeuristicLab.Common-3.3"> 121 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Common-3.3.dll</HintPath> 122 </Reference> 123 <Reference Include="HeuristicLab.Common.Resources-3.3"> 124 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Common.Resources-3.3.dll</HintPath> 125 </Reference> 126 <Reference Include="HeuristicLab.Data-3.3"> 127 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Data-3.3.dll</HintPath> 128 </Reference> 129 <Reference Include="HeuristicLab.Encodings.RealVectorEncoding-3.3"> 130 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Encodings.RealVectorEncoding-3.3.dll</HintPath> 131 </Reference> 132 <Reference Include="HeuristicLab.Encodings.SymbolicExpressionTreeEncoding-3.4"> 133 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Encodings.SymbolicExpressionTreeEncoding-3.4.dll</HintPath> 134 </Reference> 135 <Reference Include="HeuristicLab.Operators-3.3"> 136 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Operators-3.3.dll</HintPath> 137 </Reference> 138 <Reference Include="HeuristicLab.Optimization-3.3"> 139 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Optimization-3.3.dll</HintPath> 140 </Reference> 141 <Reference Include="HeuristicLab.Parameters-3.3"> 142 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Parameters-3.3.dll</HintPath> 143 </Reference> 144 <Reference Include="HeuristicLab.Persistence-3.3"> 145 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Persistence-3.3.dll</HintPath> 146 </Reference> 147 <Reference Include="HeuristicLab.PluginInfrastructure-3.3"> 148 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.PluginInfrastructure-3.3.dll</HintPath> 149 </Reference> 150 <Reference Include="HeuristicLab.Problems.DataAnalysis.Symbolic-3.4"> 151 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Problems.DataAnalysis.Symbolic-3.4.dll</HintPath> 152 </Reference> 153 <Reference Include="HeuristicLab.Problems.DataAnalysis.Symbolic.Classification-3.4"> 154 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Problems.DataAnalysis.Symbolic.Classification-3.4.dll</HintPath> 155 </Reference> 156 <Reference Include="HeuristicLab.Problems.DataAnalysis.Symbolic.Regression-3.4"> 157 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Problems.DataAnalysis.Symbolic.Regression-3.4.dll</HintPath> 158 </Reference> 159 <Reference Include="HeuristicLab.Problems.DataAnalysis.Symbolic.TimeSeriesPrognosis-3.4"> 160 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Problems.DataAnalysis.Symbolic.TimeSeriesPrognosis-3.4.dll</HintPath> 161 </Reference> 162 <Reference Include="HeuristicLab.Problems.Instances-3.3"> 163 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Problems.Instances-3.3.dll</HintPath> 164 </Reference> 165 <Reference Include="HeuristicLab.Random-3.3"> 166 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Random-3.3.dll</HintPath> 110 167 </Reference> 111 168 <Reference Include="LibSVM-3.12, Version=3.12.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL"> 112 <HintPath>..\..\ bin\LibSVM-3.12.dll</HintPath>169 <HintPath>..\..\..\..\trunk\sources\bin\LibSVM-3.12.dll</HintPath> 113 170 <Private>False</Private> 114 171 </Reference> … … 278 335 </ItemGroup> 279 336 <ItemGroup> 280 <ProjectReference Include="..\..\HeuristicLab.Algorithms.GradientDescent\3.3\HeuristicLab.Algorithms.GradientDescent-3.3.csproj">281 <Project>{1256B945-EEA9-4BE4-9880-76B5B113F089}</Project>282 <Name>HeuristicLab.Algorithms.GradientDescent</Name>283 <Private>False</Private>284 </ProjectReference>285 <ProjectReference Include="..\..\HeuristicLab.Analysis\3.3\HeuristicLab.Analysis-3.3.csproj">286 <Project>{887425B4-4348-49ED-A457-B7D2C26DDBF9}</Project>287 <Name>HeuristicLab.Analysis-3.3</Name>288 <Private>False</Private>289 </ProjectReference>290 <ProjectReference Include="..\..\HeuristicLab.Collections\3.3\HeuristicLab.Collections-3.3.csproj">291 <Project>{958B43BC-CC5C-4FA2-8628-2B3B01D890B6}</Project>292 <Name>HeuristicLab.Collections-3.3</Name>293 <Private>False</Private>294 </ProjectReference>295 <ProjectReference Include="..\..\HeuristicLab.Common.Resources\3.3\HeuristicLab.Common.Resources-3.3.csproj">296 <Project>{0E27A536-1C4A-4624-A65E-DC4F4F23E3E1}</Project>297 <Name>HeuristicLab.Common.Resources-3.3</Name>298 <Private>False</Private>299 </ProjectReference>300 <ProjectReference Include="..\..\HeuristicLab.Common\3.3\HeuristicLab.Common-3.3.csproj">301 <Project>{A9AD58B9-3EF9-4CC1-97E5-8D909039FF5C}</Project>302 <Name>HeuristicLab.Common-3.3</Name>303 <Private>False</Private>304 </ProjectReference>305 337 <ProjectReference Include="..\..\HeuristicLab.Core\3.3\HeuristicLab.Core-3.3.csproj"> 306 338 <Project>{C36BD924-A541-4A00-AFA8-41701378DDC5}</Project> … … 308 340 <Private>False</Private> 309 341 </ProjectReference> 310 <ProjectReference Include="..\..\HeuristicLab.Data\3.3\HeuristicLab.Data-3.3.csproj"> 311 <Project>{BBAB9DF5-5EF3-4BA8-ADE9-B36E82114937}</Project> 312 <Name>HeuristicLab.Data-3.3</Name> 313 <Private>False</Private> 342 <ProjectReference Include="..\..\HeuristicLab.Encodings.ConditionActionEncoding\3.3\HeuristicLab.Encodings.ConditionActionEncoding-3.3.csproj"> 343 <Project>{422fb262-0845-4969-8d16-12f057aa90b1}</Project> 344 <Name>HeuristicLab.Encodings.ConditionActionEncoding-3.3</Name> 314 345 </ProjectReference> 315 <ProjectReference Include="..\..\HeuristicLab.Encodings.RealVectorEncoding\3.3\HeuristicLab.Encodings.RealVectorEncoding-3.3.csproj"> 316 <Project>{BB6D334A-4BB6-4674-9883-31A6EBB32CAB}</Project> 317 <Name>HeuristicLab.Encodings.RealVectorEncoding-3.3</Name> 318 <Private>False</Private> 319 </ProjectReference> 320 <ProjectReference Include="..\..\HeuristicLab.Encodings.SymbolicExpressionTreeEncoding\3.4\HeuristicLab.Encodings.SymbolicExpressionTreeEncoding-3.4.csproj"> 321 <Project>{06D4A186-9319-48A0-BADE-A2058D462EEA}</Project> 322 <Name>HeuristicLab.Encodings.SymbolicExpressionTreeEncoding-3.4</Name> 323 <Private>False</Private> 324 </ProjectReference> 325 <ProjectReference Include="..\..\HeuristicLab.Operators\3.3\HeuristicLab.Operators-3.3.csproj"> 326 <Project>{23DA7FF4-D5B8-41B6-AA96-F0561D24F3EE}</Project> 327 <Name>HeuristicLab.Operators-3.3</Name> 328 <Private>False</Private> 329 </ProjectReference> 330 <ProjectReference Include="..\..\HeuristicLab.Optimization\3.3\HeuristicLab.Optimization-3.3.csproj"> 331 <Project>{14AB8D24-25BC-400C-A846-4627AA945192}</Project> 332 <Name>HeuristicLab.Optimization-3.3</Name> 333 <Private>False</Private> 334 </ProjectReference> 335 <ProjectReference Include="..\..\HeuristicLab.Parameters\3.3\HeuristicLab.Parameters-3.3.csproj"> 336 <Project>{56F9106A-079F-4C61-92F6-86A84C2D84B7}</Project> 337 <Name>HeuristicLab.Parameters-3.3</Name> 338 <Private>False</Private> 339 </ProjectReference> 340 <ProjectReference Include="..\..\HeuristicLab.Persistence\3.3\HeuristicLab.Persistence-3.3.csproj"> 341 <Project>{102BC7D3-0EF9-439C-8F6D-96FF0FDB8E1B}</Project> 342 <Name>HeuristicLab.Persistence-3.3</Name> 343 <Private>False</Private> 344 </ProjectReference> 345 <ProjectReference Include="..\..\HeuristicLab.PluginInfrastructure\3.3\HeuristicLab.PluginInfrastructure-3.3.csproj"> 346 <Project>{94186A6A-5176-4402-AE83-886557B53CCA}</Project> 347 <Name>HeuristicLab.PluginInfrastructure-3.3</Name> 348 <Private>False</Private> 349 </ProjectReference> 350 <ProjectReference Include="..\..\HeuristicLab.Problems.DataAnalysis.Symbolic.Classification\3.4\HeuristicLab.Problems.DataAnalysis.Symbolic.Classification-3.4.csproj"> 351 <Project>{05BAE4E1-A9FA-4644-AA77-42558720159E}</Project> 352 <Name>HeuristicLab.Problems.DataAnalysis.Symbolic.Classification-3.4</Name> 353 <Private>False</Private> 354 </ProjectReference> 355 <ProjectReference Include="..\..\HeuristicLab.Problems.DataAnalysis.Symbolic.Regression\3.4\HeuristicLab.Problems.DataAnalysis.Symbolic.Regression-3.4.csproj"> 356 <Project>{5AC82412-911B-4FA2-A013-EDC5E3F3FCC2}</Project> 357 <Name>HeuristicLab.Problems.DataAnalysis.Symbolic.Regression-3.4</Name> 358 <Private>False</Private> 359 </ProjectReference> 360 <ProjectReference Include="..\..\HeuristicLab.Problems.DataAnalysis.Symbolic.TimeSeriesPrognosis\3.4\HeuristicLab.Problems.DataAnalysis.Symbolic.TimeSeriesPrognosis-3.4.csproj"> 361 <Project>{07486E68-1517-4B9D-A58D-A38E99AE71AB}</Project> 362 <Name>HeuristicLab.Problems.DataAnalysis.Symbolic.TimeSeriesPrognosis-3.4</Name> 363 </ProjectReference> 364 <ProjectReference Include="..\..\HeuristicLab.Problems.DataAnalysis.Symbolic\3.4\HeuristicLab.Problems.DataAnalysis.Symbolic-3.4.csproj"> 365 <Project>{3D28463F-EC96-4D82-AFEE-38BE91A0CA00}</Project> 366 <Name>HeuristicLab.Problems.DataAnalysis.Symbolic-3.4</Name> 367 <Private>False</Private> 346 <ProjectReference Include="..\..\HeuristicLab.Optimization.Operators.LCS\3.3\HeuristicLab.Optimization.Operators.LCS-3.3.csproj"> 347 <Project>{f2c6d3b0-bd4f-4747-b13e-b18e53a2a09d}</Project> 348 <Name>HeuristicLab.Optimization.Operators.LCS-3.3</Name> 368 349 </ProjectReference> 369 350 <ProjectReference Include="..\..\HeuristicLab.Problems.DataAnalysis\3.4\HeuristicLab.Problems.DataAnalysis-3.4.csproj"> 370 351 <Project>{DF87C13E-A889-46FF-8153-66DCAA8C5674}</Project> 371 352 <Name>HeuristicLab.Problems.DataAnalysis-3.4</Name> 372 <Private>False</Private>373 </ProjectReference>374 <ProjectReference Include="..\..\HeuristicLab.Problems.Instances\3.3\HeuristicLab.Problems.Instances-3.3.csproj">375 <Project>{3540E29E-4793-49E7-8EE2-FEA7F61C3994}</Project>376 <Name>HeuristicLab.Problems.Instances-3.3</Name>377 <Private>False</Private>378 </ProjectReference>379 <ProjectReference Include="..\..\HeuristicLab.Random\3.3\HeuristicLab.Random-3.3.csproj">380 <Project>{F4539FB6-4708-40C9-BE64-0A1390AEA197}</Project>381 <Name>HeuristicLab.Random-3.3</Name>382 353 <Private>False</Private> 383 354 </ProjectReference>
Note: See TracChangeset
for help on using the changeset viewer.