Changeset 12969 for branches/gteufl/HeuristicLab.Algorithms.GradientDescent
- Timestamp:
- 09/25/15 14:39:59 (9 years ago)
- Location:
- branches/gteufl
- Files:
-
- 10 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/gteufl
- Property svn:ignore
-
old new 8 8 FxCopResults.txt 9 9 Google.ProtocolBuffers-0.9.1.dll 10 Google.ProtocolBuffers-2.4.1.473.dll 10 11 HeuristicLab 3.3.5.1.ReSharper.user 11 12 HeuristicLab 3.3.6.0.ReSharper.user 12 13 HeuristicLab.4.5.resharper.user 13 14 HeuristicLab.ExtLibs.6.0.ReSharper.user 15 HeuristicLab.Scripting.Development 14 16 HeuristicLab.resharper.user 15 17 ProtoGen.exe … … 17 19 _ReSharper.HeuristicLab 18 20 _ReSharper.HeuristicLab 3.3 21 _ReSharper.HeuristicLab 3.3 Tests 19 22 _ReSharper.HeuristicLab.ExtLibs 20 23 bin 21 24 protoc.exe 22 _ReSharper.HeuristicLab 3.3 Tests 23 Google.ProtocolBuffers-2.4.1.473.dll 25 obj
-
- Property svn:mergeinfo changed
-
Property
svn:global-ignores
set to
*.nuget
packages
- Property svn:ignore
-
branches/gteufl/HeuristicLab.Algorithms.GradientDescent/3.3/HeuristicLab.Algorithms.GradientDescent-3.3.csproj
r9288 r12969 11 11 <RootNamespace>HeuristicLab.Algorithms.GradientDescent</RootNamespace> 12 12 <AssemblyName>HeuristicLab.Algorithms.GradientDescent-3.3</AssemblyName> 13 <TargetFrameworkVersion>v4. 0</TargetFrameworkVersion>13 <TargetFrameworkVersion>v4.5</TargetFrameworkVersion> 14 14 <FileAlignment>512</FileAlignment> 15 <TargetFrameworkProfile /> 15 16 </PropertyGroup> 16 17 <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> … … 22 23 <ErrorReport>prompt</ErrorReport> 23 24 <WarningLevel>4</WarningLevel> 25 <Prefer32Bit>false</Prefer32Bit> 24 26 </PropertyGroup> 25 27 <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' "> … … 30 32 <ErrorReport>prompt</ErrorReport> 31 33 <WarningLevel>4</WarningLevel> 34 <Prefer32Bit>false</Prefer32Bit> 32 35 </PropertyGroup> 33 36 <PropertyGroup> … … 52 55 <CodeAnalysisRuleDirectories>;C:\Program Files (x86)\Microsoft Visual Studio 10.0\Team Tools\Static Analysis Tools\FxCop\\Rules</CodeAnalysisRuleDirectories> 53 56 <CodeAnalysisIgnoreBuiltInRules>false</CodeAnalysisIgnoreBuiltInRules> 57 <Prefer32Bit>false</Prefer32Bit> 54 58 </PropertyGroup> 55 59 <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|x86'"> … … 67 71 <CodeAnalysisRuleDirectories>;C:\Program Files (x86)\Microsoft Visual Studio 10.0\Team Tools\Static Analysis Tools\FxCop\\Rules</CodeAnalysisRuleDirectories> 68 72 <CodeAnalysisIgnoreBuiltInRules>true</CodeAnalysisIgnoreBuiltInRules> 73 <Prefer32Bit>false</Prefer32Bit> 69 74 </PropertyGroup> 70 75 <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|x64'"> … … 83 88 <CodeAnalysisRuleDirectories>;C:\Program Files (x86)\Microsoft Visual Studio 10.0\Team Tools\Static Analysis Tools\FxCop\\Rules</CodeAnalysisRuleDirectories> 84 89 <CodeAnalysisIgnoreBuiltInRules>false</CodeAnalysisIgnoreBuiltInRules> 90 <Prefer32Bit>false</Prefer32Bit> 85 91 </PropertyGroup> 86 92 <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|x64'"> … … 100 106 <CodeAnalysisIgnoreBuiltInRules>true</CodeAnalysisIgnoreBuiltInRules> 101 107 <CodeAnalysisFailOnMissingRules>false</CodeAnalysisFailOnMissingRules> 108 <Prefer32Bit>false</Prefer32Bit> 102 109 </PropertyGroup> 103 110 <ItemGroup> -
branches/gteufl/HeuristicLab.Algorithms.GradientDescent/3.3/Lbfgs.cs
r9456 r12969 2 2 #region License Information 3 3 /* HeuristicLab 4 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)4 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 5 5 * 6 6 * This file is part of HeuristicLab. … … 39 39 /// </summary> 40 40 [Item("LM-BFGS", "The limited-memory BFGS (BroydenFletcherGoldfarbShanno) optimization algorithm.")] 41 [Creatable( "Algorithms")]41 [Creatable(CreatableAttribute.Categories.SingleSolutionAlgorithms, Priority = 160)] 42 42 [StorableClass] 43 43 public sealed class LbfgsAlgorithm : HeuristicOptimizationEngineAlgorithm, IStorableContent { … … 200 200 RegisterEvents(); 201 201 solutionCreator.OperatorParameter.ActualName = Problem.SolutionCreatorParameter.Name; 202 solutionCreator.OperatorParameter.Hidden = true; 202 203 evaluator.OperatorParameter.ActualName = Problem.EvaluatorParameter.Name; 204 evaluator.OperatorParameter.Hidden = true; 203 205 UpdateAnalyzers(); 204 206 ParameterizeOperators(); … … 220 222 protected override void Problem_OperatorsChanged(object sender, EventArgs e) { 221 223 base.Problem_OperatorsChanged(sender, e); 224 RegisterEvents(); 225 solutionCreator.OperatorParameter.ActualName = Problem.SolutionCreatorParameter.Name; 226 solutionCreator.OperatorParameter.Hidden = true; 227 evaluator.OperatorParameter.ActualName = Problem.EvaluatorParameter.Name; 228 evaluator.OperatorParameter.Hidden = true; 222 229 UpdateAnalyzers(); 230 ParameterizeOperators(); 223 231 } 224 232 … … 266 274 var realVectorParameterName = realVectorCreator.RealVectorParameter.ActualName; 267 275 initializer.PointParameter.ActualName = realVectorParameterName; 276 initializer.PointParameter.Hidden = true; 268 277 makeStep.PointParameter.ActualName = realVectorParameterName; 278 makeStep.PointParameter.Hidden = true; 269 279 analyzer.PointParameter.ActualName = realVectorParameterName; 280 analyzer.PointParameter.Hidden = true; 270 281 } 271 282 272 283 var qualityParameterName = Problem.Evaluator.QualityParameter.ActualName; 273 284 updateResults.QualityParameter.ActualName = qualityParameterName; 285 updateResults.QualityParameter.Hidden = true; 274 286 analyzer.QualityParameter.ActualName = qualityParameterName; 287 analyzer.QualityParameter.Hidden = true; 275 288 } 276 289 } -
branches/gteufl/HeuristicLab.Algorithms.GradientDescent/3.3/LbfgsAnalyzer.cs
r9456 r12969 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/gteufl/HeuristicLab.Algorithms.GradientDescent/3.3/LbfgsInitializer.cs
r9456 r12969 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/gteufl/HeuristicLab.Algorithms.GradientDescent/3.3/LbfgsMakeStep.cs
r9456 r12969 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/gteufl/HeuristicLab.Algorithms.GradientDescent/3.3/LbfgsState.cs
r9456 r12969 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. -
branches/gteufl/HeuristicLab.Algorithms.GradientDescent/3.3/LbfgsUpdateResults.cs
r9456 r12969 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 37 37 private const string StateParameterName = "State"; 38 38 private const string ApproximateGradientsParameterName = "ApproximateGradients"; 39 private const string MaximizationParameterName = "Maximization"; 39 40 40 41 #region Parameter Properties … … 51 52 get { return (ILookupParameter<LbfgsState>)Parameters[StateParameterName]; } 52 53 } 54 public ILookupParameter<BoolValue> MaximizationParameter { 55 get { return (ILookupParameter<BoolValue>)Parameters[MaximizationParameterName]; } 56 } 53 57 #endregion 54 58 … … 58 62 private DoubleValue Quality { get { return QualityParameter.ActualValue; } } 59 63 private LbfgsState State { get { return StateParameter.ActualValue; } } 64 65 private BoolValue Maximization { 66 get { 67 // BackwardsCompatibility3.3 68 #region Backwards compatible code, remove with 3.4 69 // the parameter is new, previously we assumed minimization problems 70 if (MaximizationParameter.ActualValue == null) return new BoolValue(false); 71 #endregion 72 return MaximizationParameter.ActualValue; 73 } 74 } 75 60 76 #endregion 61 77 … … 70 86 Parameters.Add(new LookupParameter<BoolValue>(ApproximateGradientsParameterName, 71 87 "Flag that indicates if gradients should be approximated.")); 88 Parameters.Add(new LookupParameter<BoolValue>(MaximizationParameterName, "Flag that indicates if we solve a maximization problem.")); 72 89 // in & out 73 90 Parameters.Add(new LookupParameter<LbfgsState>(StateParameterName, "The state of the LM-BFGS algorithm.")); 91 } 92 93 [StorableHook(HookType.AfterDeserialization)] 94 private void AfterDeserialization() { 95 // BackwardsCompatibility3.3 96 97 #region Backwards compatible code, remove with 3.4 98 if (!Parameters.ContainsKey(MaximizationParameterName)) { 99 // previous behaviour defaulted to minimization 100 Parameters.Add(new LookupParameter<BoolValue>(MaximizationParameterName, "Flag that indicates if we solve a maximization problem.")); 101 } 102 #endregion 74 103 } 75 104 … … 80 109 public override IOperation Apply() { 81 110 var state = State; 82 var f = Quality.Value; 111 var sign = Maximization.Value ? -1.0 : 1.0; 112 var f = sign * Quality.Value; 83 113 state.State.f = f; 84 114 if (!ApproximateGradients.Value) { 85 var g = QualityGradients. ToArray();115 var g = QualityGradients.Select(gi => sign * gi).ToArray(); 86 116 state.State.g = g; 87 117 } -
branches/gteufl/HeuristicLab.Algorithms.GradientDescent/3.3/Plugin.cs.frame
r10037 r12969 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 23 23 24 24 namespace HeuristicLab.Algorithms.GradientDescent { 25 [Plugin("HeuristicLab.Algorithms.GradientDescent", "3.3. 9.$WCREV$")]25 [Plugin("HeuristicLab.Algorithms.GradientDescent", "3.3.12.$WCREV$")] 26 26 [PluginFile("HeuristicLab.Algorithms.GradientDescent-3.3.dll", PluginFileType.Assembly)] 27 27 [PluginDependency("HeuristicLab.ALGLIB", "3.7.0")] -
branches/gteufl/HeuristicLab.Algorithms.GradientDescent/3.3/Properties/AssemblyInfo.cs.frame
r10037 r12969 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 3Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 32 32 [assembly: AssemblyCompany("HEAL")] 33 33 [assembly: AssemblyProduct("HeuristicLab")] 34 [assembly: AssemblyCopyright("(c) 2002-201 3HEAL")]34 [assembly: AssemblyCopyright("(c) 2002-2015 HEAL")] 35 35 [assembly: AssemblyTrademark("")] 36 36 [assembly: AssemblyCulture("")] … … 55 55 // [assembly: AssemblyVersion("1.0.*")] 56 56 [assembly: AssemblyVersion("3.3.0.0")] 57 [assembly: AssemblyFileVersion("3.3. 9.$WCREV$")]57 [assembly: AssemblyFileVersion("3.3.12.$WCREV$")]
Note: See TracChangeset
for help on using the changeset viewer.