Changeset 8701 for branches/DataAnalysisCSVImport
- Timestamp:
- 09/25/12 16:16:23 (12 years ago)
- Location:
- branches/DataAnalysisCSVImport
- Files:
-
- 9 added
- 13 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/DataAnalysisCSVImport
-
Property
svn:ignore
set to
*.suo
-
Property
svn:ignore
set to
-
branches/DataAnalysisCSVImport/HeuristicLab.Problems.Instances.DataAnalysis.Views/3.3/DataAnalysisImportTypeDialog.Designer.cs
r8693 r8701 1 namespace HeuristicLab.Problems.Instances.DataAnalysis.Views { 1 2 using HeuristicLab.Common.Resources; 3 namespace HeuristicLab.Problems.Instances.DataAnalysis.Views { 2 4 partial class DataAnalysisImportTypeDialog { 3 5 /// <summary> … … 27 29 this.OkButton = new System.Windows.Forms.Button(); 28 30 this.TrainingTestTrackBar = new System.Windows.Forms.TrackBar(); 29 this.TrainingTestGroupBox = new System.Windows.Forms.GroupBox();30 31 this.TestLabel = new System.Windows.Forms.Label(); 31 32 this.TrainingLabel = new System.Windows.Forms.Label(); 32 33 this.CancelButton = new System.Windows.Forms.Button(); 33 this. openFileButton = new System.Windows.Forms.Button();34 this.OpenFileButton = new System.Windows.Forms.Button(); 34 35 this.ProblemFileLabel = new System.Windows.Forms.Label(); 35 36 this.ProblemTextBox = new System.Windows.Forms.TextBox(); 36 37 this.openFileDialog = new System.Windows.Forms.OpenFileDialog(); 38 this.DateTimeFormatComboBox = new System.Windows.Forms.ComboBox(); 39 this.DecimalSeparatorComboBox = new System.Windows.Forms.ComboBox(); 40 this.DateTimeFormatLabel = new System.Windows.Forms.Label(); 41 this.DecimalSeperatorLabel = new System.Windows.Forms.Label(); 42 this.SeparatorLabel = new System.Windows.Forms.Label(); 43 this.SeparatorComboBox = new System.Windows.Forms.ComboBox(); 44 this.CSVSettingsGroupBox = new System.Windows.Forms.GroupBox(); 45 this.SeparatorInfoButton = new System.Windows.Forms.Button(); 46 this.ProblemDataSettingsGroupBox = new System.Windows.Forms.GroupBox(); 47 this.PreviewLabel = new System.Windows.Forms.Label(); 48 this.ErrorTextBox = new System.Windows.Forms.TextBox(); 49 this.PreviewDatasetMatrix = new HeuristicLab.Data.Views.StringConvertibleMatrixView(); 50 this.DecimalSeparatorInfoButton = new System.Windows.Forms.Button(); 51 this.DateTimeFormatInfoButton = new System.Windows.Forms.Button(); 52 this.ShuffleDataInfoButton = new System.Windows.Forms.Button(); 37 53 ((System.ComponentModel.ISupportInitialize)(this.TrainingTestTrackBar)).BeginInit(); 38 this.TrainingTestGroupBox.SuspendLayout(); 54 this.CSVSettingsGroupBox.SuspendLayout(); 55 this.ProblemDataSettingsGroupBox.SuspendLayout(); 39 56 this.SuspendLayout(); 40 57 // … … 42 59 // 43 60 this.ShuffleDataCheckbox.AutoSize = true; 44 this.ShuffleDataCheckbox.Location = new System.Drawing.Point(12, 38); 61 this.ShuffleDataCheckbox.CheckAlign = System.Drawing.ContentAlignment.MiddleRight; 62 this.ShuffleDataCheckbox.Location = new System.Drawing.Point(9, 20); 45 63 this.ShuffleDataCheckbox.Name = "ShuffleDataCheckbox"; 46 64 this.ShuffleDataCheckbox.Size = new System.Drawing.Size(91, 17); … … 51 69 // OkButton 52 70 // 71 this.OkButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); 53 72 this.OkButton.DialogResult = System.Windows.Forms.DialogResult.OK; 54 73 this.OkButton.Enabled = false; 55 this.OkButton.Location = new System.Drawing.Point( 61, 147);74 this.OkButton.Location = new System.Drawing.Point(87, 407); 56 75 this.OkButton.Name = "OkButton"; 57 76 this.OkButton.Size = new System.Drawing.Size(75, 23); … … 64 83 this.TrainingTestTrackBar.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) 65 84 | System.Windows.Forms.AnchorStyles.Right))); 66 this.TrainingTestTrackBar.Location = new System.Drawing.Point(6, 19);85 this.TrainingTestTrackBar.Location = new System.Drawing.Point(6, 43); 67 86 this.TrainingTestTrackBar.Maximum = 100; 68 87 this.TrainingTestTrackBar.Minimum = 1; 69 88 this.TrainingTestTrackBar.Name = "TrainingTestTrackBar"; 70 this.TrainingTestTrackBar.Size = new System.Drawing.Size( 303, 45);89 this.TrainingTestTrackBar.Size = new System.Drawing.Size(435, 45); 71 90 this.TrainingTestTrackBar.TabIndex = 4; 72 91 this.TrainingTestTrackBar.TickStyle = System.Windows.Forms.TickStyle.None; … … 74 93 this.TrainingTestTrackBar.ValueChanged += new System.EventHandler(this.TrainingTestTrackBar_ValueChanged); 75 94 // 76 // TrainingTestGroupBox77 //78 this.TrainingTestGroupBox.Controls.Add(this.TestLabel);79 this.TrainingTestGroupBox.Controls.Add(this.TrainingLabel);80 this.TrainingTestGroupBox.Controls.Add(this.TrainingTestTrackBar);81 this.TrainingTestGroupBox.Location = new System.Drawing.Point(12, 61);82 this.TrainingTestGroupBox.Name = "TrainingTestGroupBox";83 this.TrainingTestGroupBox.Size = new System.Drawing.Size(315, 80);84 this.TrainingTestGroupBox.TabIndex = 5;85 this.TrainingTestGroupBox.TabStop = false;86 this.TrainingTestGroupBox.Text = "Training/Test";87 //88 95 // TestLabel 89 96 // 97 this.TestLabel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); 90 98 this.TestLabel.AutoSize = true; 91 this.TestLabel.Location = new System.Drawing.Point( 188, 51);99 this.TestLabel.Location = new System.Drawing.Point(303, 68); 92 100 this.TestLabel.Name = "TestLabel"; 93 101 this.TestLabel.Size = new System.Drawing.Size(57, 13); … … 98 106 // 99 107 this.TrainingLabel.AutoSize = true; 100 this.TrainingLabel.Location = new System.Drawing.Point( 50, 51);108 this.TrainingLabel.Location = new System.Drawing.Point(76, 68); 101 109 this.TrainingLabel.Name = "TrainingLabel"; 102 110 this.TrainingLabel.Size = new System.Drawing.Size(74, 13); … … 106 114 // CancelButton 107 115 // 116 this.CancelButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); 108 117 this.CancelButton.DialogResult = System.Windows.Forms.DialogResult.Cancel; 109 this.CancelButton.Location = new System.Drawing.Point( 182, 147);118 this.CancelButton.Location = new System.Drawing.Point(318, 407); 110 119 this.CancelButton.Name = "CancelButton"; 111 120 this.CancelButton.Size = new System.Drawing.Size(75, 23); … … 116 125 // openFileButton 117 126 // 118 this.openFileButton.Location = new System.Drawing.Point(303, 12); 119 this.openFileButton.Name = "openFileButton"; 120 this.openFileButton.Size = new System.Drawing.Size(24, 24); 121 this.openFileButton.TabIndex = 8; 122 this.openFileButton.UseVisualStyleBackColor = true; 123 this.openFileButton.Click += new System.EventHandler(this.openFileButton_Click); 127 this.OpenFileButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); 128 this.OpenFileButton.Location = new System.Drawing.Point(429, 3); 129 this.OpenFileButton.Name = "openFileButton"; 130 this.OpenFileButton.Size = new System.Drawing.Size(24, 24); 131 this.OpenFileButton.TabIndex = 8; 132 this.OpenFileButton.Text = "Open"; 133 this.OpenFileButton.UseVisualStyleBackColor = true; 134 this.OpenFileButton.Click += new System.EventHandler(this.openFileButton_Click); 124 135 // 125 136 // ProblemFileLabel 126 137 // 127 138 this.ProblemFileLabel.AutoSize = true; 128 this.ProblemFileLabel.Location = new System.Drawing.Point(1 2, 15);139 this.ProblemFileLabel.Location = new System.Drawing.Point(18, 9); 129 140 this.ProblemFileLabel.Name = "ProblemFileLabel"; 130 141 this.ProblemFileLabel.Size = new System.Drawing.Size(67, 13); … … 134 145 // ProblemTextBox 135 146 // 136 this.ProblemTextBox.Location = new System.Drawing.Point(85, 12); 147 this.ProblemTextBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) 148 | System.Windows.Forms.AnchorStyles.Right))); 149 this.ProblemTextBox.Location = new System.Drawing.Point(91, 6); 137 150 this.ProblemTextBox.Name = "ProblemTextBox"; 138 151 this.ProblemTextBox.ReadOnly = true; 139 this.ProblemTextBox.Size = new System.Drawing.Size( 212, 20);152 this.ProblemTextBox.Size = new System.Drawing.Size(332, 20); 140 153 this.ProblemTextBox.TabIndex = 9; 141 154 // … … 143 156 // 144 157 this.openFileDialog.Filter = "CSV files (*.csv)|*.csv|Text files (*.txt)|*.txt|All files (*.*)|*.*"; 158 // 159 // DateTimeFormatComboBox 160 // 161 this.DateTimeFormatComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) 162 | System.Windows.Forms.AnchorStyles.Right))); 163 this.DateTimeFormatComboBox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; 164 this.DateTimeFormatComboBox.FormattingEnabled = true; 165 this.DateTimeFormatComboBox.Location = new System.Drawing.Point(111, 73); 166 this.DateTimeFormatComboBox.Name = "DateTimeFormatComboBox"; 167 this.DateTimeFormatComboBox.Size = new System.Drawing.Size(300, 21); 168 this.DateTimeFormatComboBox.TabIndex = 15; 169 this.DateTimeFormatComboBox.SelectionChangeCommitted += new System.EventHandler(this.CSVFormatComboBoxSelectionChangeCommitted); 170 // 171 // DecimalSeparatorComboBox 172 // 173 this.DecimalSeparatorComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) 174 | System.Windows.Forms.AnchorStyles.Right))); 175 this.DecimalSeparatorComboBox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; 176 this.DecimalSeparatorComboBox.FormattingEnabled = true; 177 this.DecimalSeparatorComboBox.Location = new System.Drawing.Point(111, 46); 178 this.DecimalSeparatorComboBox.Name = "DecimalSeparatorComboBox"; 179 this.DecimalSeparatorComboBox.Size = new System.Drawing.Size(300, 21); 180 this.DecimalSeparatorComboBox.TabIndex = 14; 181 this.DecimalSeparatorComboBox.SelectionChangeCommitted += new System.EventHandler(this.CSVFormatComboBoxSelectionChangeCommitted); 182 // 183 // DateTimeFormatLabel 184 // 185 this.DateTimeFormatLabel.AutoSize = true; 186 this.DateTimeFormatLabel.Location = new System.Drawing.Point(6, 76); 187 this.DateTimeFormatLabel.Name = "DateTimeFormatLabel"; 188 this.DateTimeFormatLabel.Size = new System.Drawing.Size(91, 13); 189 this.DateTimeFormatLabel.TabIndex = 13; 190 this.DateTimeFormatLabel.Text = "DateTime Format:"; 191 // 192 // DecimalSeperatorLabel 193 // 194 this.DecimalSeperatorLabel.AutoSize = true; 195 this.DecimalSeperatorLabel.Location = new System.Drawing.Point(6, 49); 196 this.DecimalSeperatorLabel.Name = "DecimalSeperatorLabel"; 197 this.DecimalSeperatorLabel.Size = new System.Drawing.Size(97, 13); 198 this.DecimalSeperatorLabel.TabIndex = 12; 199 this.DecimalSeperatorLabel.Text = "Decimal Separator:"; 200 // 201 // SeparatorLabel 202 // 203 this.SeparatorLabel.AutoSize = true; 204 this.SeparatorLabel.Location = new System.Drawing.Point(6, 22); 205 this.SeparatorLabel.Name = "SeparatorLabel"; 206 this.SeparatorLabel.Size = new System.Drawing.Size(56, 13); 207 this.SeparatorLabel.TabIndex = 11; 208 this.SeparatorLabel.Text = "Separator:"; 209 // 210 // SeparatorComboBox 211 // 212 this.SeparatorComboBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) 213 | System.Windows.Forms.AnchorStyles.Right))); 214 this.SeparatorComboBox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; 215 this.SeparatorComboBox.FormattingEnabled = true; 216 this.SeparatorComboBox.Location = new System.Drawing.Point(111, 19); 217 this.SeparatorComboBox.Name = "SeparatorComboBox"; 218 this.SeparatorComboBox.Size = new System.Drawing.Size(300, 21); 219 this.SeparatorComboBox.TabIndex = 10; 220 this.SeparatorComboBox.SelectionChangeCommitted += new System.EventHandler(this.CSVFormatComboBoxSelectionChangeCommitted); 221 // 222 // CSVSettingsGroupBox 223 // 224 this.CSVSettingsGroupBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) 225 | System.Windows.Forms.AnchorStyles.Right))); 226 this.CSVSettingsGroupBox.Controls.Add(this.DateTimeFormatInfoButton); 227 this.CSVSettingsGroupBox.Controls.Add(this.DecimalSeparatorInfoButton); 228 this.CSVSettingsGroupBox.Controls.Add(this.SeparatorInfoButton); 229 this.CSVSettingsGroupBox.Controls.Add(this.SeparatorComboBox); 230 this.CSVSettingsGroupBox.Controls.Add(this.DateTimeFormatComboBox); 231 this.CSVSettingsGroupBox.Controls.Add(this.SeparatorLabel); 232 this.CSVSettingsGroupBox.Controls.Add(this.DecimalSeparatorComboBox); 233 this.CSVSettingsGroupBox.Controls.Add(this.DecimalSeperatorLabel); 234 this.CSVSettingsGroupBox.Controls.Add(this.DateTimeFormatLabel); 235 this.CSVSettingsGroupBox.Location = new System.Drawing.Point(12, 32); 236 this.CSVSettingsGroupBox.Name = "CSVSettingsGroupBox"; 237 this.CSVSettingsGroupBox.Size = new System.Drawing.Size(447, 105); 238 this.CSVSettingsGroupBox.TabIndex = 16; 239 this.CSVSettingsGroupBox.TabStop = false; 240 this.CSVSettingsGroupBox.Text = "CSV Settings"; 241 // 242 // SeparatorInfoButton 243 // 244 this.SeparatorInfoButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); 245 this.SeparatorInfoButton.Location = new System.Drawing.Point(417, 17); 246 this.SeparatorInfoButton.Name = "SeparatorInfoButton"; 247 this.SeparatorInfoButton.Size = new System.Drawing.Size(24, 24); 248 this.SeparatorInfoButton.TabIndex = 18; 249 this.SeparatorInfoButton.Text = "SeparatorInfo"; 250 this.SeparatorInfoButton.UseVisualStyleBackColor = true; 251 // 252 // ProblemDataSettingsGroupBox 253 // 254 this.ProblemDataSettingsGroupBox.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 255 | System.Windows.Forms.AnchorStyles.Left) 256 | System.Windows.Forms.AnchorStyles.Right))); 257 this.ProblemDataSettingsGroupBox.Controls.Add(this.ShuffleDataInfoButton); 258 this.ProblemDataSettingsGroupBox.Controls.Add(this.PreviewLabel); 259 this.ProblemDataSettingsGroupBox.Controls.Add(this.ErrorTextBox); 260 this.ProblemDataSettingsGroupBox.Controls.Add(this.TestLabel); 261 this.ProblemDataSettingsGroupBox.Controls.Add(this.PreviewDatasetMatrix); 262 this.ProblemDataSettingsGroupBox.Controls.Add(this.TrainingLabel); 263 this.ProblemDataSettingsGroupBox.Controls.Add(this.TrainingTestTrackBar); 264 this.ProblemDataSettingsGroupBox.Controls.Add(this.ShuffleDataCheckbox); 265 this.ProblemDataSettingsGroupBox.Location = new System.Drawing.Point(12, 143); 266 this.ProblemDataSettingsGroupBox.Name = "ProblemDataSettingsGroupBox"; 267 this.ProblemDataSettingsGroupBox.Size = new System.Drawing.Size(447, 258); 268 this.ProblemDataSettingsGroupBox.TabIndex = 17; 269 this.ProblemDataSettingsGroupBox.TabStop = false; 270 this.ProblemDataSettingsGroupBox.Text = "ProblemData Settings"; 271 // 272 // PreviewLabel 273 // 274 this.PreviewLabel.AutoSize = true; 275 this.PreviewLabel.Location = new System.Drawing.Point(9, 89); 276 this.PreviewLabel.Name = "PreviewLabel"; 277 this.PreviewLabel.Size = new System.Drawing.Size(45, 13); 278 this.PreviewLabel.TabIndex = 7; 279 this.PreviewLabel.Text = "Preview"; 280 // 281 // ErrorTextBox 282 // 283 this.ErrorTextBox.Location = new System.Drawing.Point(111, 164); 284 this.ErrorTextBox.Multiline = true; 285 this.ErrorTextBox.Name = "ErrorTextBox"; 286 this.ErrorTextBox.Size = new System.Drawing.Size(193, 32); 287 this.ErrorTextBox.TabIndex = 0; 288 this.ErrorTextBox.Visible = false; 289 // 290 // PreviewDatasetMatrix 291 // 292 this.PreviewDatasetMatrix.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 293 | System.Windows.Forms.AnchorStyles.Left) 294 | System.Windows.Forms.AnchorStyles.Right))); 295 this.PreviewDatasetMatrix.Caption = "Dataset Preview"; 296 this.PreviewDatasetMatrix.Content = null; 297 this.PreviewDatasetMatrix.Location = new System.Drawing.Point(6, 108); 298 this.PreviewDatasetMatrix.Name = "PreviewDatasetMatrix"; 299 this.PreviewDatasetMatrix.ReadOnly = true; 300 this.PreviewDatasetMatrix.ShowRowsAndColumnsTextBox = false; 301 this.PreviewDatasetMatrix.ShowStatisticalInformation = false; 302 this.PreviewDatasetMatrix.Size = new System.Drawing.Size(435, 144); 303 this.PreviewDatasetMatrix.TabIndex = 0; 304 // 305 // DecimalSeparatorInfoButtin 306 // 307 this.DecimalSeparatorInfoButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); 308 this.DecimalSeparatorInfoButton.Location = new System.Drawing.Point(417, 44); 309 this.DecimalSeparatorInfoButton.Name = "DecimalSeparatorInfoButtin"; 310 this.DecimalSeparatorInfoButton.Size = new System.Drawing.Size(24, 24); 311 this.DecimalSeparatorInfoButton.TabIndex = 19; 312 this.DecimalSeparatorInfoButton.Text = "DecimalSeparatorInfo"; 313 this.DecimalSeparatorInfoButton.UseVisualStyleBackColor = true; 314 // 315 // DateTimeFormatInfoButton 316 // 317 this.DateTimeFormatInfoButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); 318 this.DateTimeFormatInfoButton.Location = new System.Drawing.Point(417, 71); 319 this.DateTimeFormatInfoButton.Name = "DateTimeFormatInfoButton"; 320 this.DateTimeFormatInfoButton.Size = new System.Drawing.Size(24, 24); 321 this.DateTimeFormatInfoButton.TabIndex = 20; 322 this.DateTimeFormatInfoButton.Text = "DateTimeFormatInfo"; 323 this.DateTimeFormatInfoButton.UseVisualStyleBackColor = true; 324 // 325 // ShuffleDataInfoButton 326 // 327 this.ShuffleDataInfoButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); 328 this.ShuffleDataInfoButton.Location = new System.Drawing.Point(111, 15); 329 this.ShuffleDataInfoButton.Name = "ShuffleDataInfoButton"; 330 this.ShuffleDataInfoButton.Size = new System.Drawing.Size(24, 24); 331 this.ShuffleDataInfoButton.TabIndex = 19; 332 this.ShuffleDataInfoButton.Text = "ShuffleDataInfo"; 333 this.ShuffleDataInfoButton.UseVisualStyleBackColor = true; 145 334 // 146 335 // DataAnalysisImportTypeDialog … … 149 338 this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); 150 339 this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 151 this.ClientSize = new System.Drawing.Size( 339, 179);340 this.ClientSize = new System.Drawing.Size(471, 442); 152 341 this.ControlBox = false; 342 this.Controls.Add(this.ProblemDataSettingsGroupBox); 343 this.Controls.Add(this.CSVSettingsGroupBox); 153 344 this.Controls.Add(this.ProblemTextBox); 154 this.Controls.Add(this. openFileButton);345 this.Controls.Add(this.OpenFileButton); 155 346 this.Controls.Add(this.ProblemFileLabel); 156 347 this.Controls.Add(this.CancelButton); 157 348 this.Controls.Add(this.OkButton); 158 this.Controls.Add(this.ShuffleDataCheckbox);159 this.Controls.Add(this.TrainingTestGroupBox);160 this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;161 349 this.MaximizeBox = false; 162 350 this.MinimizeBox = false; … … 166 354 this.Text = "CSV Import"; 167 355 ((System.ComponentModel.ISupportInitialize)(this.TrainingTestTrackBar)).EndInit(); 168 this.TrainingTestGroupBox.ResumeLayout(false); 169 this.TrainingTestGroupBox.PerformLayout(); 356 this.CSVSettingsGroupBox.ResumeLayout(false); 357 this.CSVSettingsGroupBox.PerformLayout(); 358 this.ProblemDataSettingsGroupBox.ResumeLayout(false); 359 this.ProblemDataSettingsGroupBox.PerformLayout(); 170 360 this.ResumeLayout(false); 171 361 this.PerformLayout(); … … 178 368 protected System.Windows.Forms.Button OkButton; 179 369 protected System.Windows.Forms.TrackBar TrainingTestTrackBar; 180 protected System.Windows.Forms.GroupBox TrainingTestGroupBox;181 370 protected System.Windows.Forms.Label TestLabel; 182 371 protected System.Windows.Forms.Label TrainingLabel; … … 184 373 protected System.Windows.Forms.OpenFileDialog openFileDialog; 185 374 protected System.Windows.Forms.Label ProblemFileLabel; 186 protected System.Windows.Forms.Button openFileButton;375 protected System.Windows.Forms.Button OpenFileButton; 187 376 protected System.Windows.Forms.TextBox ProblemTextBox; 377 protected System.Windows.Forms.ComboBox DateTimeFormatComboBox; 378 protected System.Windows.Forms.ComboBox DecimalSeparatorComboBox; 379 protected System.Windows.Forms.Label DateTimeFormatLabel; 380 protected System.Windows.Forms.Label DecimalSeperatorLabel; 381 protected System.Windows.Forms.Label SeparatorLabel; 382 protected System.Windows.Forms.ComboBox SeparatorComboBox; 383 protected System.Windows.Forms.GroupBox CSVSettingsGroupBox; 384 protected System.Windows.Forms.GroupBox ProblemDataSettingsGroupBox; 385 protected System.Windows.Forms.TextBox ErrorTextBox; 386 protected HeuristicLab.Data.Views.StringConvertibleMatrixView PreviewDatasetMatrix; 387 private System.Windows.Forms.Label PreviewLabel; 388 protected System.Windows.Forms.Button SeparatorInfoButton; 389 protected System.Windows.Forms.Button DateTimeFormatInfoButton; 390 protected System.Windows.Forms.Button DecimalSeparatorInfoButton; 391 protected System.Windows.Forms.Button ShuffleDataInfoButton; 188 392 189 393 } -
branches/DataAnalysisCSVImport/HeuristicLab.Problems.Instances.DataAnalysis.Views/3.3/DataAnalysisImportTypeDialog.cs
r8693 r8701 20 20 #endregion 21 21 22 using System; 23 using System.Collections.Generic; 24 using System.ComponentModel; 25 using System.Globalization; 26 using System.Linq; 22 27 using System.Windows.Forms; 28 using HeuristicLab.Common.Resources; 29 using HeuristicLab.Problems.DataAnalysis; 23 30 24 31 namespace HeuristicLab.Problems.Instances.DataAnalysis.Views { 25 32 public partial class DataAnalysisImportTypeDialog : Form { 33 34 public static readonly BindingList<KeyValuePair<DateTimeFormatInfo, string>> dateTimeFormats = new BindingList<KeyValuePair<DateTimeFormatInfo, string>>{ 35 new KeyValuePair<DateTimeFormatInfo, string>(DateTimeFormatInfo.GetInstance(new CultureInfo("de-DE")), "dd/mm/yyyy hh:MM:ss" ), 36 new KeyValuePair<DateTimeFormatInfo, string>(DateTimeFormatInfo.InvariantInfo, "mm/dd/yyyy hh:MM:ss" ), 37 new KeyValuePair<DateTimeFormatInfo, string>(DateTimeFormatInfo.InvariantInfo, "yyyy/mm/dd hh:MM:ss" ), 38 new KeyValuePair<DateTimeFormatInfo, string>(DateTimeFormatInfo.InvariantInfo, "mm/yyyy/dd hh:MM:ss" ) 39 }; 40 41 public static readonly BindingList<KeyValuePair<char, string>> POSSIBLE_SEPARATORS = new BindingList<KeyValuePair<char, string>>{ 42 new KeyValuePair<char, string>(',', ", (Comma)" ), 43 new KeyValuePair<char, string>(';', "; (Semicolon)" ), 44 new KeyValuePair<char, string>('\t', "\\t (Tab)") 45 }; 46 47 public static readonly BindingList<KeyValuePair<NumberFormatInfo, string>> POSSIBLE_DECIMAL_SEPARATORS = new BindingList<KeyValuePair<NumberFormatInfo, string>>{ 48 new KeyValuePair<NumberFormatInfo, string>(NumberFormatInfo.InvariantInfo, ". (Period)" ), 49 new KeyValuePair<NumberFormatInfo, string>(NumberFormatInfo.GetInstance(new CultureInfo("de-DE")), ", (Comma)" ) 50 }; 26 51 27 52 public string Path { … … 38 63 } 39 64 65 public DataAnalysisCSVFormat CSVFormat { 66 get { 67 return new DataAnalysisCSVFormat() { 68 Separator = (char)SeparatorComboBox.SelectedValue, 69 NumberFormatInfo = (NumberFormatInfo)DecimalSeparatorComboBox.SelectedValue, 70 DateTimeFormatInfo = (DateTimeFormatInfo)DateTimeFormatComboBox.SelectedValue 71 }; 72 } 73 } 74 40 75 public DataAnalysisImportTypeDialog() { 41 76 InitializeComponent(); 77 OpenFileButton.Text = String.Empty; 78 OpenFileButton.Image = VSImageLibrary.Open; 79 SeparatorInfoButton.Text = String.Empty; 80 SeparatorInfoButton.Image = VSImageLibrary.Information; 81 DecimalSeparatorInfoButton.Text = String.Empty; 82 DecimalSeparatorInfoButton.Image = VSImageLibrary.Information; 83 DateTimeFormatInfoButton.Text = String.Empty; 84 DateTimeFormatInfoButton.Image = VSImageLibrary.Information; 85 ShuffleDataInfoButton.Text = String.Empty; 86 ShuffleDataInfoButton.Image = VSImageLibrary.Information; 87 88 SeparatorComboBox.DataSource = POSSIBLE_SEPARATORS; 89 SeparatorComboBox.ValueMember = "Key"; 90 SeparatorComboBox.DisplayMember = "Value"; 91 DecimalSeparatorComboBox.DataSource = POSSIBLE_DECIMAL_SEPARATORS; 92 DecimalSeparatorComboBox.ValueMember = "Key"; 93 DecimalSeparatorComboBox.DisplayMember = "Value"; 94 DateTimeFormatComboBox.DataSource = dateTimeFormats; 95 DateTimeFormatComboBox.ValueMember = "Key"; 96 DateTimeFormatComboBox.DisplayMember = "Value"; 42 97 } 43 98 … … 50 105 if (openFileDialog.ShowDialog(this) == DialogResult.OK) { 51 106 ProblemTextBox.Text = openFileDialog.FileName; 107 ParseCSVFile(); 108 } 109 } 110 111 protected void CSVFormatComboBoxSelectionChangeCommitted(object sender, EventArgs e) { 112 if (!ProblemTextBox.Text.Equals(String.Empty)) { 113 ParseCSVFile(); 114 } 115 } 116 117 protected void ParseCSVFile() { 118 PreviewDatasetMatrix.Content = null; 119 try { 120 TableFileParser csvParser = new TableFileParser(); 121 csvParser.Parse(ProblemTextBox.Text, 122 (NumberFormatInfo)DecimalSeparatorComboBox.SelectedValue, 123 (DateTimeFormatInfo)DateTimeFormatComboBox.SelectedValue, 124 (char)SeparatorComboBox.SelectedValue); 52 125 OkButton.Enabled = true; 126 IEnumerable<string> variableNamesWithType = GetVariableNamesWithType(csvParser); 127 PreviewDatasetMatrix.Content = new Dataset(variableNamesWithType, csvParser.Values); 128 var bla = new Dataset(csvParser.VariableNames, csvParser.Values); 129 130 if (!csvParser.Values.Any(x => x is List<double>)) { 131 throw new ArgumentException("No double column could be found!"); 132 } 133 ErrorTextBox.Text = String.Empty; 134 ErrorTextBox.Visible = false; 53 135 } 136 catch (Exception ex) { 137 OkButton.Enabled = false; 138 ErrorTextBox.Text = ex.Message; 139 ErrorTextBox.Visible = true; 140 } 141 } 142 143 private IEnumerable<string> GetVariableNamesWithType(TableFileParser csvParser) { 144 IList<string> variableNamesWithType = csvParser.VariableNames.ToList(); 145 for (int i = 0; i < csvParser.Values.Count; i++) { 146 if (csvParser.Values[i] is List<double>) { 147 variableNamesWithType[i] += " (Double)"; 148 } else if (csvParser.Values[i] is List<string>) { 149 variableNamesWithType[i] += " (String)"; 150 } else if (csvParser.Values[i] is List<DateTime>) { 151 variableNamesWithType[i] += " (DateTime)"; 152 } else { 153 throw new ArgumentException("The variable values must be of type List<double>, List<string> or List<DateTime>"); 154 } 155 } 156 return variableNamesWithType; 54 157 } 55 158 } -
branches/DataAnalysisCSVImport/HeuristicLab.Problems.Instances.DataAnalysis.Views/3.3/DataAnalysisInstanceConsumerView.cs
r8693 r8701 30 30 [View("DataAnalysis InstanceProvider View")] 31 31 [Content(typeof(IProblemInstanceConsumer<IDataAnalysisProblemData>), IsDefaultView = true)] 32 [Content(typeof(IProblemInstanceConsumer<IClassificationProblemData>), IsDefaultView = true)]33 32 [Content(typeof(IProblemInstanceConsumer<IRegressionProblemData>), IsDefaultView = true)] 34 33 [Content(typeof(IProblemInstanceConsumer<IClusteringProblemData>), IsDefaultView = true)] … … 42 41 public DataAnalysisInstanceConsumerView() { 43 42 InitializeComponent(); 43 44 44 } 45 45 46 46 protected override void importButton_Click(object sender, EventArgs e) { 47 var provider = SelectedProvider as DataAnalysisInstanceProvider<T >;47 var provider = SelectedProvider as DataAnalysisInstanceProvider<T, DataAnalysisImportType>; 48 48 if (provider != null) { 49 49 DataAnalysisImportTypeDialog importTypeDialog = new DataAnalysisImportTypeDialog(); … … 51 51 T instance = default(T); 52 52 try { 53 instance = provider.ImportData(importTypeDialog.Path, importTypeDialog.ImportType );53 instance = provider.ImportData(importTypeDialog.Path, importTypeDialog.ImportType, importTypeDialog.CSVFormat); 54 54 55 55 } -
branches/DataAnalysisCSVImport/HeuristicLab.Problems.Instances.DataAnalysis.Views/3.3/HeuristicLab.Problems.Instances.DataAnalysis.Views-3.3.csproj
r8693 r8701 18 18 <DebugType>full</DebugType> 19 19 <Optimize>false</Optimize> 20 <OutputPath> bin\Debug\</OutputPath>20 <OutputPath>..\..\..\..\trunk\sources\bin\</OutputPath> 21 21 <DefineConstants>DEBUG;TRACE</DefineConstants> 22 22 <ErrorReport>prompt</ErrorReport> … … 26 26 <DebugType>pdbonly</DebugType> 27 27 <Optimize>true</Optimize> 28 <OutputPath>..\..\ bin\</OutputPath>28 <OutputPath>..\..\..\..\trunk\sources\bin\</OutputPath> 29 29 <DefineConstants>TRACE</DefineConstants> 30 30 <ErrorReport>prompt</ErrorReport> … … 38 38 </PropertyGroup> 39 39 <ItemGroup> 40 <Reference Include="System" /> 41 <Reference Include="System.Core" /> 42 <Reference Include="System.Drawing" /> 43 <Reference Include="System.Windows.Forms" /> 44 <Reference Include="System.Xml.Linq" /> 45 <Reference Include="System.Data.DataSetExtensions" /> 46 <Reference Include="Microsoft.CSharp" /> 47 <Reference Include="System.Data" /> 48 <Reference Include="System.Xml" /> 40 <Reference Include="HeuristicLab.Common-3.3"> 41 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Common-3.3.dll</HintPath> 42 </Reference> 43 <Reference Include="HeuristicLab.Common.Resources-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL"> 44 <Private>False</Private> 45 </Reference> 46 <Reference Include="HeuristicLab.Core-3.3"> 47 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Core-3.3.dll</HintPath> 48 </Reference> 49 <Reference Include="HeuristicLab.Data-3.3"> 50 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Data-3.3.dll</HintPath> 51 </Reference> 52 <Reference Include="HeuristicLab.Data.Views-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL"> 53 <Private>False</Private> 54 </Reference> 55 <Reference Include="HeuristicLab.MainForm-3.3"> 56 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.MainForm-3.3.dll</HintPath> 57 </Reference> 58 <Reference Include="HeuristicLab.MainForm.WindowsForms-3.3"> 59 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.MainForm.WindowsForms-3.3.dll</HintPath> 60 </Reference> 61 <Reference Include="HeuristicLab.PluginInfrastructure-3.3"> 62 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.PluginInfrastructure-3.3.dll</HintPath> 63 </Reference> 64 <Reference Include="HeuristicLab.Problems.DataAnalysis-3.4"> 65 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Problems.DataAnalysis-3.4.dll</HintPath> 66 </Reference> 67 <Reference Include="HeuristicLab.Problems.Instances-3.3"> 68 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Problems.Instances-3.3.dll</HintPath> 69 </Reference> 70 <Reference Include="HeuristicLab.Problems.Instances.Views-3.3"> 71 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Problems.Instances.Views-3.3.dll</HintPath> 72 </Reference> 73 <Reference Include="System"> 74 <Private>True</Private> 75 </Reference> 76 <Reference Include="System.Core"> 77 <Private>True</Private> 78 </Reference> 79 <Reference Include="System.Drawing"> 80 <Private>True</Private> 81 </Reference> 82 <Reference Include="System.Windows.Forms"> 83 <Private>True</Private> 84 </Reference> 85 <Reference Include="System.Xml.Linq"> 86 <Private>True</Private> 87 </Reference> 88 <Reference Include="System.Data.DataSetExtensions"> 89 <Private>True</Private> 90 </Reference> 91 <Reference Include="Microsoft.CSharp"> 92 <Private>True</Private> 93 </Reference> 94 <Reference Include="System.Data"> 95 <Private>True</Private> 96 </Reference> 97 <Reference Include="System.Xml"> 98 <Private>True</Private> 99 </Reference> 49 100 </ItemGroup> 50 101 <ItemGroup> 102 <Compile Include="ClassificationImportTypeDialog.cs"> 103 <SubType>Form</SubType> 104 </Compile> 105 <Compile Include="ClassificationImportTypeDialog.Designer.cs"> 106 <DependentUpon>ClassificationImportTypeDialog.cs</DependentUpon> 107 </Compile> 108 <Compile Include="ClassificationInstanceConsumerView.cs"> 109 <SubType>UserControl</SubType> 110 </Compile> 111 <Compile Include="ClassificationInstanceConsumerView.Designer.cs"> 112 <DependentUpon>ClassificationInstanceConsumerView.cs</DependentUpon> 113 </Compile> 51 114 <Compile Include="DataAnalysisImportTypeDialog.cs"> 52 115 <SubType>Form</SubType> … … 68 131 </ItemGroup> 69 132 <ItemGroup> 70 <ProjectReference Include="..\..\HeuristicLab.Common\3.3\HeuristicLab.Common-3.3.csproj">71 <Project>{A9AD58B9-3EF9-4CC1-97E5-8D909039FF5C}</Project>72 <Name>HeuristicLab.Common-3.3</Name>73 </ProjectReference>74 <ProjectReference Include="..\..\HeuristicLab.Core\3.3\HeuristicLab.Core-3.3.csproj">75 <Project>{C36BD924-A541-4A00-AFA8-41701378DDC5}</Project>76 <Name>HeuristicLab.Core-3.3</Name>77 </ProjectReference>78 <ProjectReference Include="..\..\HeuristicLab.Data\3.3\HeuristicLab.Data-3.3.csproj">79 <Project>{BBAB9DF5-5EF3-4BA8-ADE9-B36E82114937}</Project>80 <Name>HeuristicLab.Data-3.3</Name>81 </ProjectReference>82 <ProjectReference Include="..\..\HeuristicLab.MainForm.WindowsForms\3.3\HeuristicLab.MainForm.WindowsForms-3.3.csproj">83 <Project>{AB687BBE-1BFE-476B-906D-44237135431D}</Project>84 <Name>HeuristicLab.MainForm.WindowsForms-3.3</Name>85 </ProjectReference>86 <ProjectReference Include="..\..\HeuristicLab.MainForm\3.3\HeuristicLab.MainForm-3.3.csproj">87 <Project>{3BD61258-31DA-4B09-89C0-4F71FEF5F05A}</Project>88 <Name>HeuristicLab.MainForm-3.3</Name>89 </ProjectReference>90 <ProjectReference Include="..\..\HeuristicLab.PluginInfrastructure\3.3\HeuristicLab.PluginInfrastructure-3.3.csproj">91 <Project>{94186A6A-5176-4402-AE83-886557B53CCA}</Project>92 <Name>HeuristicLab.PluginInfrastructure-3.3</Name>93 <Private>False</Private>94 </ProjectReference>95 <ProjectReference Include="..\..\HeuristicLab.Problems.DataAnalysis\3.4\HeuristicLab.Problems.DataAnalysis-3.4.csproj">96 <Project>{DF87C13E-A889-46FF-8153-66DCAA8C5674}</Project>97 <Name>HeuristicLab.Problems.DataAnalysis-3.4</Name>98 <Private>False</Private>99 </ProjectReference>100 133 <ProjectReference Include="..\..\HeuristicLab.Problems.Instances.DataAnalysis\3.3\HeuristicLab.Problems.Instances.DataAnalysis-3.3.csproj"> 101 134 <Project>{94C7714E-29D4-4D6D-B213-2C18D627AB75}</Project> 102 135 <Name>HeuristicLab.Problems.Instances.DataAnalysis-3.3</Name> 103 <Private>False</Private>104 </ProjectReference>105 <ProjectReference Include="..\..\HeuristicLab.Problems.Instances.Views\3.3\HeuristicLab.Problems.Instances.Views-3.3.csproj">106 <Project>{B1BA398F-953F-4C3A-B07B-1E5E17A27DD9}</Project>107 <Name>HeuristicLab.Problems.Instances.Views-3.3</Name>108 <Private>False</Private>109 </ProjectReference>110 <ProjectReference Include="..\..\HeuristicLab.Problems.Instances\3.3\HeuristicLab.Problems.Instances-3.3.csproj">111 <Project>{3540E29E-4793-49E7-8EE2-FEA7F61C3994}</Project>112 <Name>HeuristicLab.Problems.Instances-3.3</Name>113 136 <Private>False</Private> 114 137 </ProjectReference> -
branches/DataAnalysisCSVImport/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Classification/CSV/ClassifiactionCSVInstanceProvider.cs
r8693 r8701 92 92 } 93 93 94 public override IClassificationProblemData ImportData(string path, DataAnalysisImportType type) { 95 TableFileParser csvFileParser = new TableFileParser(); 96 csvFileParser.Parse(path); 97 94 protected override IClassificationProblemData ImportData(string path, ClassificationImportType type, TableFileParser csvFileParser) { 98 95 int trainingPartEnd = (csvFileParser.Rows * type.Training) / 100; 99 96 List<IList> values = csvFileParser.Values; … … 126 123 } 127 124 125 protected List<IList> Shuffle(List<IList> values, int target, int trainingPercentage, int trainingPartEnd) { 126 target = 5; 127 IList targetValues = values[target]; 128 var group = targetValues.Cast<double>().GroupBy(x => x).Select(g => new { Key = g.Key, Count = g.Count() }).ToList(); 129 Dictionary<double, double> taken = new Dictionary<double, double>(); 130 foreach (var classCount in group) { 131 taken[classCount.Key] = (classCount.Count * trainingPercentage) / 100; 132 } 133 134 List<IList> training = GetListOfIListCopy(values); 135 List<IList> test = GetListOfIListCopy(values); 136 137 for (int i = 0; i < targetValues.Count; i++) { 138 if (taken[(double)targetValues[i]] > 0) { 139 AddRow(training, values, i); 140 taken[(double)targetValues[i]]--; 141 } else { 142 AddRow(test, values, i); 143 } 144 } 145 146 training = Shuffle(training); 147 test = Shuffle(test); 148 for (int i = 0; i < training.Count; i++) { 149 for (int j = 0; j < test[i].Count; j++) { 150 training[i].Add(test[i][j]); 151 } 152 } 153 154 return training; 155 } 156 157 private void AddRow(List<IList> destination, List<IList> source, int index) { 158 for (int i = 0; i < source.Count; i++) { 159 destination[i].Add(source[i][index]); 160 } 161 } 162 163 private List<IList> GetListOfIListCopy(List<IList> values) { 164 List<IList> newList = new List<IList>(values.Count); 165 for (int col = 0; col < values.Count; col++) { 166 167 if (values[col] is List<double>) 168 newList.Add(new List<double>()); 169 else if (values[col] is List<DateTime>) 170 newList.Add(new List<DateTime>()); 171 else if (values[col] is List<string>) 172 newList.Add(new List<string>()); 173 else 174 throw new InvalidOperationException(); 175 } 176 return newList; 177 } 178 179 private List<IList> NormalizeClasses(List<IList> values) { 180 int column = GetLastDoubleColumn(values); 181 Dictionary<object, int> count = new Dictionary<object, int>(); 182 foreach (var item in values[column]) { 183 if (count.Keys.Contains(item)) { 184 count[item]++; 185 } else { 186 count.Add(item, 1); 187 } 188 } 189 int min = count.Values.Min(); 190 Dictionary<object, int> taken = new Dictionary<object, int>(); 191 foreach (var key in count.Keys) { 192 taken[key] = 0; 193 } 194 List<IList> normalizedValues = new List<IList>(values.Count); 195 for (int col = 0; col < values.Count; col++) { 196 197 if (values[col] is List<double>) 198 normalizedValues.Add(new List<double>()); 199 else if (values[col] is List<DateTime>) 200 normalizedValues.Add(new List<DateTime>()); 201 else if (values[col] is List<string>) 202 normalizedValues.Add(new List<string>()); 203 else 204 throw new InvalidOperationException(); 205 } 206 for (int i = 0; i < values.First().Count; i++) { 207 if (taken[values[column][i]] < min) { 208 taken[values[column][i]]++; 209 for (int col = 0; col < values.Count; col++) { 210 normalizedValues[col].Add(values[col][i]); 211 } 212 } 213 } 214 return normalizedValues; 215 } 216 217 private int GetLastDoubleColumn(List<IList> values) { 218 for (int i = values.Count - 1; i >= 0; i--) { 219 if (values[i] is List<double>) { 220 return i; 221 } 222 } 223 throw new ArgumentException("No possible Target Variable could be found!"); 224 } 225 128 226 public override bool CanExportData { 129 227 get { return true; } -
branches/DataAnalysisCSVImport/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Classification/ClassificationInstanceProvider.cs
r8598 r8701 23 23 24 24 namespace HeuristicLab.Problems.Instances.DataAnalysis { 25 public abstract class ClassificationInstanceProvider : DataAnalysisInstanceProvider<IClassificationProblemData > {25 public abstract class ClassificationInstanceProvider : DataAnalysisInstanceProvider<IClassificationProblemData, ClassificationImportType> { 26 26 } 27 27 } -
branches/DataAnalysisCSVImport/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Clustering/CSV/ClusteringCSVInstanceProvider.cs
r8685 r8701 91 91 } 92 92 93 public override IClusteringProblemData ImportData(string path, DataAnalysisImportType type) { 94 TableFileParser csvFileParser = new TableFileParser(); 95 csvFileParser.Parse(path); 96 93 protected override IClusteringProblemData ImportData(string path, DataAnalysisImportType type, TableFileParser csvFileParser) { 97 94 List<IList> values = csvFileParser.Values; 98 95 if (type.Shuffle) { -
branches/DataAnalysisCSVImport/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Clustering/ClusteringInstanceProvider.cs
r8598 r8701 23 23 24 24 namespace HeuristicLab.Problems.Instances.DataAnalysis { 25 public abstract class ClusteringInstanceProvider : DataAnalysisInstanceProvider<IClusteringProblemData > {25 public abstract class ClusteringInstanceProvider : DataAnalysisInstanceProvider<IClusteringProblemData, DataAnalysisImportType> { 26 26 } 27 27 } -
branches/DataAnalysisCSVImport/HeuristicLab.Problems.Instances.DataAnalysis/3.3/DataAnalysisInstanceProvider.cs
r8598 r8701 27 27 28 28 namespace HeuristicLab.Problems.Instances.DataAnalysis { 29 public abstract class DataAnalysisInstanceProvider<TData> : ProblemInstanceProvider<TData> 30 where TData : class, IDataAnalysisProblemData { 29 public abstract class DataAnalysisInstanceProvider<TData, ImportType> : ProblemInstanceProvider<TData> 30 where TData : class, IDataAnalysisProblemData 31 where ImportType : DataAnalysisImportType { 31 32 32 33 // has to be implemented, if CanImportData is true 33 public virtual TData ImportData(string path, DataAnalysisImportType type) { 34 public TData ImportData(string path, ImportType type) { 35 TableFileParser csvFileParser = new TableFileParser(); 36 csvFileParser.Parse(path); 37 return ImportData(path, type, csvFileParser); 38 } 39 public TData ImportData(string path, ImportType type, DataAnalysisCSVFormat csvFormat) { 40 TableFileParser csvFileParser = new TableFileParser(); 41 csvFileParser.Parse(path, csvFormat.NumberFormatInfo, csvFormat.DateTimeFormatInfo, csvFormat.Separator); 42 return ImportData(path, type, csvFileParser); 43 } 44 protected virtual TData ImportData(string path, ImportType type, TableFileParser csvFileParser) { 34 45 throw new NotSupportedException(); 35 46 } -
branches/DataAnalysisCSVImport/HeuristicLab.Problems.Instances.DataAnalysis/3.3/HeuristicLab.Problems.Instances.DataAnalysis-3.3.csproj
r8693 r8701 18 18 <DebugType>full</DebugType> 19 19 <Optimize>false</Optimize> 20 <OutputPath>..\..\ bin\</OutputPath>20 <OutputPath>..\..\..\..\trunk\sources\bin\</OutputPath> 21 21 <DefineConstants>DEBUG;TRACE</DefineConstants> 22 22 <ErrorReport>prompt</ErrorReport> … … 26 26 <DebugType>pdbonly</DebugType> 27 27 <Optimize>true</Optimize> 28 <OutputPath>..\..\ bin\</OutputPath>28 <OutputPath>..\..\..\..\trunk\sources\bin\</OutputPath> 29 29 <DefineConstants>TRACE</DefineConstants> 30 30 <ErrorReport>prompt</ErrorReport> … … 39 39 <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|x86'"> 40 40 <DebugSymbols>true</DebugSymbols> 41 <OutputPath>..\..\ bin\</OutputPath>41 <OutputPath>..\..\..\..\trunk\sources\bin\</OutputPath> 42 42 <DefineConstants>DEBUG;TRACE</DefineConstants> 43 43 <DebugType>full</DebugType> … … 52 52 </PropertyGroup> 53 53 <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|x86'"> 54 <OutputPath>..\..\ bin\</OutputPath>54 <OutputPath>..\..\..\..\trunk\sources\bin\</OutputPath> 55 55 <DefineConstants>TRACE</DefineConstants> 56 56 <Optimize>true</Optimize> … … 69 69 <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|x64'"> 70 70 <DebugSymbols>true</DebugSymbols> 71 <OutputPath>..\..\ bin\</OutputPath>71 <OutputPath>..\..\..\..\trunk\sources\bin\</OutputPath> 72 72 <DefineConstants>DEBUG;TRACE</DefineConstants> 73 73 <DebugType>full</DebugType> … … 82 82 </PropertyGroup> 83 83 <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|x64'"> 84 <OutputPath>..\..\ bin\</OutputPath>84 <OutputPath>..\..\..\..\trunk\sources\bin\</OutputPath> 85 85 <DefineConstants>TRACE</DefineConstants> 86 86 <Optimize>true</Optimize> … … 98 98 </PropertyGroup> 99 99 <ItemGroup> 100 <Reference Include="HeuristicLab.Collections-3.3"> 101 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Collections-3.3.dll</HintPath> 102 <Private>False</Private> 103 </Reference> 104 <Reference Include="HeuristicLab.Common-3.3"> 105 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Common-3.3.dll</HintPath> 106 <Private>False</Private> 107 </Reference> 108 <Reference Include="HeuristicLab.Core-3.3"> 109 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Core-3.3.dll</HintPath> 110 <Private>False</Private> 111 </Reference> 112 <Reference Include="HeuristicLab.Data-3.3"> 113 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Data-3.3.dll</HintPath> 114 <Private>False</Private> 115 </Reference> 116 <Reference Include="HeuristicLab.PluginInfrastructure-3.3"> 117 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.PluginInfrastructure-3.3.dll</HintPath> 118 <Private>False</Private> 119 </Reference> 120 <Reference Include="HeuristicLab.Problems.DataAnalysis-3.4"> 121 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Problems.DataAnalysis-3.4.dll</HintPath> 122 <Private>False</Private> 123 </Reference> 124 <Reference Include="HeuristicLab.Problems.Instances-3.3"> 125 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Problems.Instances-3.3.dll</HintPath> 126 <Private>False</Private> 127 </Reference> 128 <Reference Include="HeuristicLab.Random-3.3"> 129 <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Random-3.3.dll</HintPath> 130 <Private>False</Private> 131 </Reference> 100 132 <Reference Include="ICSharpCode.SharpZipLib"> 101 <HintPath>..\..\ HeuristicLab.PluginInfrastructure\3.3\ICSharpCode.SharpZipLib.dll</HintPath>133 <HintPath>..\..\..\..\trunk\sources\bin\ICSharpCode.SharpZipLib.dll</HintPath> 102 134 <Private>False</Private> 103 135 </Reference> … … 117 149 <Compile Include="Classification\ClassificationInstanceProvider.cs" /> 118 150 <Compile Include="Classification\CSV\ClassifiactionCSVInstanceProvider.cs" /> 151 <Compile Include="Classification\ClassificationImportType.cs" /> 119 152 <Compile Include="Classification\ResourceClassificationDataDescriptor.cs" /> 120 153 <Compile Include="Classification\ResourceClassificationInstanceProvider.cs" /> … … 124 157 <Compile Include="Clustering\ClusteringInstanceProvider.cs" /> 125 158 <Compile Include="Clustering\CSV\ClusteringCSVInstanceProvider.cs" /> 159 <Compile Include="DataAnalysisCSVFormat.cs" /> 126 160 <Compile Include="DataAnalysisImportType.cs" /> 127 161 <Compile Include="DataAnalysisInstanceProvider.cs" /> … … 205 239 <EmbeddedResource Include="Regression\Data\RegressionRealWorld.zip" /> 206 240 </ItemGroup> 207 <ItemGroup>208 <ProjectReference Include="..\..\HeuristicLab.Collections\3.3\HeuristicLab.Collections-3.3.csproj">209 <Project>{958B43BC-CC5C-4FA2-8628-2B3B01D890B6}</Project>210 <Name>HeuristicLab.Collections-3.3</Name>211 <Private>False</Private>212 </ProjectReference>213 <ProjectReference Include="..\..\HeuristicLab.Common\3.3\HeuristicLab.Common-3.3.csproj">214 <Project>{A9AD58B9-3EF9-4CC1-97E5-8D909039FF5C}</Project>215 <Name>HeuristicLab.Common-3.3</Name>216 <Private>False</Private>217 </ProjectReference>218 <ProjectReference Include="..\..\HeuristicLab.Core\3.3\HeuristicLab.Core-3.3.csproj">219 <Project>{C36BD924-A541-4A00-AFA8-41701378DDC5}</Project>220 <Name>HeuristicLab.Core-3.3</Name>221 <Private>False</Private>222 </ProjectReference>223 <ProjectReference Include="..\..\HeuristicLab.Data\3.3\HeuristicLab.Data-3.3.csproj">224 <Project>{BBAB9DF5-5EF3-4BA8-ADE9-B36E82114937}</Project>225 <Name>HeuristicLab.Data-3.3</Name>226 <Private>False</Private>227 </ProjectReference>228 <ProjectReference Include="..\..\HeuristicLab.PluginInfrastructure\3.3\HeuristicLab.PluginInfrastructure-3.3.csproj">229 <Project>{94186A6A-5176-4402-AE83-886557B53CCA}</Project>230 <Name>HeuristicLab.PluginInfrastructure-3.3</Name>231 <Private>False</Private>232 </ProjectReference>233 <ProjectReference Include="..\..\HeuristicLab.Problems.DataAnalysis\3.4\HeuristicLab.Problems.DataAnalysis-3.4.csproj">234 <Project>{DF87C13E-A889-46FF-8153-66DCAA8C5674}</Project>235 <Name>HeuristicLab.Problems.DataAnalysis-3.4</Name>236 <Private>False</Private>237 </ProjectReference>238 <ProjectReference Include="..\..\HeuristicLab.Problems.Instances\3.3\HeuristicLab.Problems.Instances-3.3.csproj">239 <Project>{3540E29E-4793-49E7-8EE2-FEA7F61C3994}</Project>240 <Name>HeuristicLab.Problems.Instances-3.3</Name>241 <Private>False</Private>242 </ProjectReference>243 <ProjectReference Include="..\..\HeuristicLab.Random\3.3\HeuristicLab.Random-3.3.csproj">244 <Project>{F4539FB6-4708-40C9-BE64-0A1390AEA197}</Project>245 <Name>HeuristicLab.Random-3.3</Name>246 <Private>False</Private>247 </ProjectReference>248 </ItemGroup>249 241 <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> 250 242 <PropertyGroup> -
branches/DataAnalysisCSVImport/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/CSV/RegressionCSVInstanceProvider.cs
r8685 r8701 86 86 } 87 87 88 public override IRegressionProblemData ImportData(string path, DataAnalysisImportType type) { 89 TableFileParser csvFileParser = new TableFileParser(); 90 csvFileParser.Parse(path); 91 88 protected override IRegressionProblemData ImportData(string path, DataAnalysisImportType type, TableFileParser csvFileParser) { 92 89 List<IList> values = csvFileParser.Values; 93 90 if (type.Shuffle) { -
branches/DataAnalysisCSVImport/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/RegressionInstanceProvider.cs
r8598 r8701 23 23 24 24 namespace HeuristicLab.Problems.Instances.DataAnalysis { 25 public abstract class RegressionInstanceProvider : DataAnalysisInstanceProvider<IRegressionProblemData > {25 public abstract class RegressionInstanceProvider : DataAnalysisInstanceProvider<IRegressionProblemData, DataAnalysisImportType> { 26 26 } 27 27 }
Note: See TracChangeset
for help on using the changeset viewer.