Free cookie consent management tool by TermsFeed Policy Generator

source: branches/HeuristicLab.Modeling Database Backend/sources/HeuristicLab.CEDMA.Server/3.3/Problem.cs @ 2208

Last change on this file since 2208 was 2208, checked in by mkommend, 15 years ago

removed obsolete usings in CEDMA.Core and CEDMA.Server (ticket #712)

File size: 4.0 KB
Line 
1#region License Information
2/* HeuristicLab
3 * Copyright (C) 2002-2008 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
4 *
5 * This file is part of HeuristicLab.
6 *
7 * HeuristicLab is free software: you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation, either version 3 of the License, or
10 * (at your option) any later version.
11 *
12 * HeuristicLab is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15 * GNU General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
19 */
20#endregion
21
22using System;
23using System.Collections.Generic;
24using System.Linq;
25using System.Text;
26using HeuristicLab.Core;
27using System.Xml;
28using HeuristicLab.Operators;
29
30namespace HeuristicLab.CEDMA.Server {
31
32
33  /// <summary>
34  /// Problem describes the data mining task.
35  /// Contains the actual data and meta-data:
36  ///  * which variables should be modelled
37  ///  * regression, time-series or classification problem
38  /// </summary>
39  public class Problem {
40    internal event EventHandler Changed;
41
42    private HeuristicLab.DataAnalysis.Dataset dataset;
43    public HeuristicLab.DataAnalysis.Dataset Dataset {
44      get { return dataset; }
45      set {
46        if (value != dataset) {
47          dataset = value;
48        }
49      }
50    }
51
52    private int trainingSamplesStart;
53    public int TrainingSamplesStart {
54      get { return trainingSamplesStart; }
55      set { trainingSamplesStart = value; }
56    }
57
58    private int trainingSamplesEnd;
59    public int TrainingSamplesEnd {
60      get { return trainingSamplesEnd; }
61      set { trainingSamplesEnd = value; }
62    }
63
64    private int validationSamplesStart;
65    public int ValidationSamplesStart {
66      get { return validationSamplesStart; }
67      set { validationSamplesStart = value; }
68    }
69
70    private int validationSamplesEnd;
71    public int ValidationSamplesEnd {
72      get { return validationSamplesEnd; }
73      set { validationSamplesEnd = value; }
74    }
75
76    private int testSamplesStart;
77    public int TestSamplesStart {
78      get { return testSamplesStart; }
79      set { testSamplesStart = value; }
80    }
81
82    private int testSamplesEnd;
83    public int TestSamplesEnd {
84      get { return testSamplesEnd; }
85      set { testSamplesEnd = value; }
86    }
87
88    //private List<int> allowedInputVariables;
89    //public List<int> AllowedInputVariables {
90    //  get { return allowedInputVariables; }
91    //}
92
93    //private List<int> allowedTargetVariables;
94    //public List<int> AllowedTargetVariables {
95    //  get { return allowedTargetVariables; }
96    //}
97
98    private bool autoRegressive;
99    public bool AutoRegressive {
100      get { return autoRegressive; }
101      set { autoRegressive = value; }
102    }
103
104    private int minTimeOffset;
105    public int MinTimeOffset {
106      get { return minTimeOffset; }
107      set { minTimeOffset = value; }
108    }
109
110    private int maxTimeOffset;
111    public int MaxTimeOffset {
112      get { return maxTimeOffset; }
113      set { maxTimeOffset = value; }
114    }
115
116    private LearningTask learningTask;
117    public LearningTask LearningTask {
118      get { return learningTask; }
119      set { learningTask = value; }
120    }
121
122    public Problem()
123      : base() {
124      //allowedInputVariables = new List<int>();
125      //allowedTargetVariables = new List<int>();
126      Dataset = new HeuristicLab.DataAnalysis.Dataset();
127    }
128
129    public string GetVariableName(int index) {
130      return dataset.GetVariableName(index);
131    }
132
133    public IView CreateView() {
134      return new ProblemView(this);
135    }
136
137    internal void FireChanged() {
138      if (Changed != null) Changed(this, new EventArgs());
139    }
140  }
141}
Note: See TracBrowser for help on using the repository browser.