Changeset 7666


Ignore:
Timestamp:
03/27/12 16:13:25 (10 years ago)
Author:
sforsten
Message:

#1784:

  • deleted obsolete project Problems.Instances.Regression.Views
  • added TrentMcConaghy and Various problem instances (zip file from TrentMcConaghy is rather big)
Location:
branches/ProblemInstancesRegressionAndClassification
Files:
9 added
1 deleted
9 edited

Legend:

Unmodified
Added
Removed
  • branches/ProblemInstancesRegressionAndClassification/HeuristicLab 3.3.sln

    r7665 r7666  
    1515EndProject
    1616Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.Problems.Instances.Regression-3.4", "HeuristicLab.Problems.Instances.Regression\3.4\HeuristicLab.Problems.Instances.Regression-3.4.csproj", "{26BF13E1-C8B2-4ACE-862D-EBFD360116B3}"
    17 EndProject
    18 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.Problems.Instances.Regression.Views-3.4", "HeuristicLab.Problems.Instances.Regression.Views\3.4\HeuristicLab.Problems.Instances.Regression.Views-3.4.csproj", "{1CC61973-7706-42DC-8023-310F591AB02B}"
    1917EndProject
    2018Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.Optimization.Views-3.3", "HeuristicLab.Optimization.Views\3.3\HeuristicLab.Optimization.Views-3.3.csproj", "{662B4B15-8F4D-4AE5-B3EB-D91C215F5AF2}"
     
    9492    {26BF13E1-C8B2-4ACE-862D-EBFD360116B3}.Release|x64.ActiveCfg = Release|Any CPU
    9593    {26BF13E1-C8B2-4ACE-862D-EBFD360116B3}.Release|x86.ActiveCfg = Release|Any CPU
    96     {1CC61973-7706-42DC-8023-310F591AB02B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
    97     {1CC61973-7706-42DC-8023-310F591AB02B}.Debug|Any CPU.Build.0 = Debug|Any CPU
    98     {1CC61973-7706-42DC-8023-310F591AB02B}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
    99     {1CC61973-7706-42DC-8023-310F591AB02B}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
    100     {1CC61973-7706-42DC-8023-310F591AB02B}.Debug|x64.ActiveCfg = Debug|Any CPU
    101     {1CC61973-7706-42DC-8023-310F591AB02B}.Debug|x86.ActiveCfg = Debug|Any CPU
    102     {1CC61973-7706-42DC-8023-310F591AB02B}.Release|Any CPU.ActiveCfg = Release|Any CPU
    103     {1CC61973-7706-42DC-8023-310F591AB02B}.Release|Any CPU.Build.0 = Release|Any CPU
    104     {1CC61973-7706-42DC-8023-310F591AB02B}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
    105     {1CC61973-7706-42DC-8023-310F591AB02B}.Release|Mixed Platforms.Build.0 = Release|Any CPU
    106     {1CC61973-7706-42DC-8023-310F591AB02B}.Release|x64.ActiveCfg = Release|Any CPU
    107     {1CC61973-7706-42DC-8023-310F591AB02B}.Release|x86.ActiveCfg = Release|Any CPU
    10894    {662B4B15-8F4D-4AE5-B3EB-D91C215F5AF2}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
    10995    {662B4B15-8F4D-4AE5-B3EB-D91C215F5AF2}.Debug|Any CPU.Build.0 = Debug|Any CPU
  • branches/ProblemInstancesRegressionAndClassification/HeuristicLab.Problems.Instances.Regression/3.4

    • Property svn:ignore
      •  

        old new  
        22bin
        33obj
         4*.user
  • branches/ProblemInstancesRegressionAndClassification/HeuristicLab.Problems.Instances.Regression/3.4/HeuristicLab.Problems.Instances.Regression-3.4.csproj

    r7664 r7666  
    5353      <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Random-3.3.dll</HintPath>
    5454    </Reference>
     55    <Reference Include="ICSharpCode.SharpZipLib, Version=0.85.4.369, Culture=neutral, PublicKeyToken=1b03e6acf1164f73, processorArchitecture=MSIL" />
    5556    <Reference Include="System" />
    5657    <Reference Include="System.Core" />
     
    107108    <Compile Include="Properties\AssemblyInfo.cs" />
    108109    <Compile Include="RegressionInstanceProvider.cs" />
     110    <Compile Include="TrentMcConaghy\TrentMcConaghyInstanceProvider.cs" />
    109111    <Compile Include="ValueGenerator.cs" />
     112    <Compile Include="Various\BreimanOne.cs" />
     113    <Compile Include="Various\SpatialCoevolution.cs" />
     114    <Compile Include="Various\PolyTen.cs" />
     115    <Compile Include="Various\VariousInstanceProvider.cs" />
    110116    <Compile Include="Vladislavleva\UnwrappedBallFunctionFiveDimensional.cs" />
    111117    <Compile Include="Vladislavleva\SineCosineFunction.cs" />
     
    119125  </ItemGroup>
    120126  <ItemGroup>
     127    <EmbeddedResource Include="Data\TrentMcConaghy.zip" />
    121128    <None Include="HeuristicLab.snk" />
    122129    <None Include="Plugin.cs.frame" />
     
    133140    </ProjectReference>
    134141  </ItemGroup>
     142  <ItemGroup />
    135143  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
    136144  <PropertyGroup>
  • branches/ProblemInstancesRegressionAndClassification/HeuristicLab.Problems.Instances.Regression/3.4/Properties/AssemblyInfo.cs

    r7665 r7666  
    5555// [assembly: AssemblyVersion("1.0.*")]
    5656[assembly: AssemblyVersion("3.4.0.0")]
    57 [assembly: AssemblyFileVersion("3.4.0.7664")]
     57[assembly: AssemblyFileVersion("3.4.0.7665")]
  • branches/ProblemInstancesRegressionAndClassification/HeuristicLab.Problems.Instances.Regression/3.4/ResourceRegressionDataDescriptor.cs

    r7664 r7666  
    2626    public string Description { get; internal set; }
    2727
    28     internal string resourceName { get; set; }
     28    internal string ResourceName { get; set; }
     29    internal ResourceRegressionDataDescriptor(string name, string description, string resourceName) {
     30      Name = name;
     31      Description = description;
     32      ResourceName = resourceName;
     33    }
    2934  }
    3035}
  • branches/ProblemInstancesRegressionAndClassification/HeuristicLab.Problems.Instances.Regression/3.4/ResourceRegressionInstanceProvider.cs

    r7664 r7666  
    2323using System.Linq;
    2424using System.Reflection;
     25using System.Text.RegularExpressions;
     26using ICSharpCode.SharpZipLib.Zip;
    2527
    2628namespace HeuristicLab.Problems.Instances.Regression {
    2729  public abstract class ResourceRegressionInstanceProvider : RegressionInstanceProvider {
     30
     31    protected abstract string FileExtension { get; }
     32
    2833    public override RegressionData LoadData(IDataDescriptor id) {
    2934      var descriptor = (ResourceRegressionDataDescriptor)id;
    3035
    31       RegressionData regData = LoadData(GetTempFileForResource(descriptor.resourceName));
     36      RegressionData regData = LoadData(GetTempFileForResource(descriptor.ResourceName));
    3237      regData.Name = descriptor.Name;
    3338      regData.Description = descriptor.Description;
     
    3641    }
    3742
    38     #region Helpers
    39     protected static string GetTempFileForResource(string resourceName) {
    40       Assembly assembly = Assembly.GetExecutingAssembly();
    41       string resource = assembly.GetManifestResourceNames().Where(x => x.EndsWith(resourceName)).First();
    42 
    43       string path = Path.GetTempFileName();
    44 
    45       using (Stream stream = assembly.GetManifestResourceStream(resource)) {
    46         WriteStreamToTempFile(stream, path);
    47       }
    48       return path;
     43    protected virtual string GetResourceName(string fileName) {
     44      return Assembly.GetExecutingAssembly().GetManifestResourceNames()
     45              .Where(x => Regex.Match(x, @".*\.Data\." + fileName).Success).SingleOrDefault();
    4946    }
    5047
    51     private static void WriteStreamToTempFile(Stream stream, string path) {
     48    private string GetTempFileForResource(string resourceName) {
     49      var instanceArchiveName = GetResourceName(FileExtension + @"\.zip");
     50      using (var instancesZipFile = new ZipFile(GetType().Assembly.GetManifestResourceStream(instanceArchiveName))) {
     51        var entry = instancesZipFile.GetEntry(resourceName);
     52        string path = Path.GetTempFileName();
     53        using (var stream = instancesZipFile.GetInputStream(entry)) {
     54          WriteStreamToTempFile(stream, path);
     55        }
     56        return path;
     57      }
     58    }
     59
     60    private void WriteStreamToTempFile(Stream stream, string path) {
    5261      using (FileStream output = new FileStream(path, FileMode.Create, FileAccess.Write)) {
    5362        int cnt = 0;
     
    5766      }
    5867    }
    59     #endregion
    6068  }
    6169}
  • branches/ProblemInstancesRegressionAndClassification/HeuristicLab.Problems.Instances.Regression/3.4/Vladislavleva/KotanchekFunction.cs

    r7664 r7666  
    5757      }
    5858
    59 
    6059      double x1, x2;
    6160      List<double> results = new List<double>();
  • branches/ProblemInstancesRegressionAndClassification/HeuristicLab.Problems.Instances.Views/3.4/Plugin.cs

    r7665 r7666  
    2323
    2424namespace HeuristicLab.Problems.Instances.Views {
    25   [Plugin("HeuristicLab.Problems.Instances.Views", "3.4.0.7664")]
     25  [Plugin("HeuristicLab.Problems.Instances.Views", "3.4.0.7665")]
    2626  [PluginFile("HeuristicLab.Problems.Instances.Views-3.4.dll", PluginFileType.Assembly)]
    2727  [PluginDependency("HeuristicLab.Common", "3.3")]
  • branches/ProblemInstancesRegressionAndClassification/HeuristicLab.Problems.Instances.Views/3.4/Properties/AssemblyInfo.cs

    r7665 r7666  
    5353// by using the '*' as shown below:
    5454[assembly: AssemblyVersion("3.4.0.0")]
    55 [assembly: AssemblyFileVersion("3.4.2.7664")]
     55[assembly: AssemblyFileVersion("3.4.2.7665")]
Note: See TracChangeset for help on using the changeset viewer.