BALL
1.4.2
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Groups
Pages
include
BALL
QSAR
configIO.h
Go to the documentation of this file.
1
/* configIO.h
2
*
3
* Copyright (C) 2009 Marcel Schumann
4
*
5
* This file is part of QuEasy -- A Toolbox for Automated QSAR Model
6
* Construction and Validation.
7
* QuEasy 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 (at
10
* your option) any later version.
11
*
12
* QuEasy is distributed in the hope that it will be useful, but
13
* WITHOUT ANY WARRANTY; without even the implied warranty of
14
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15
* General Public License for more details.
16
*
17
* You should have received a copy of the GNU General Public License
18
* along with this program; if not, see <http://www.gnu.org/licenses/>.
19
*/
20
21
#ifndef CONFIG_IO_H
22
#define CONFIG_IO_H
23
24
#include <istream>
25
#include <
BALL/DATATYPE/string.h
>
26
#include <istream>
27
#include <set>
28
29
namespace
BALL
30
{
31
namespace
QSAR
32
{
33
struct
BALL_EXPORT
InputConfiguration
34
{
35
InputConfiguration
();
36
37
String
sd_file
;
38
std::multiset<int>
activities
;
39
bool
read_sd_descriptors
;
40
bool
center_data
;
41
bool
center_y
;
42
String
output
;
43
double
validation_fraction
;
44
bool
separate_activity_file
;
45
bool
within_section
;
46
vector<String>
csv_file
;
47
vector<int>
csv_no_response
;
48
vector<bool>
csv_desc_labels
;
49
vector<bool>
csv_compound_labels
;
50
vector<String>
csv_separator
;
51
bool
nonnumeric_class_names
;
52
bool
done
;
53
};
54
55
struct
BALL_EXPORT
InputPartitioningConfiguration
56
{
57
InputPartitioningConfiguration
();
58
59
String
input_file
;
60
double
validation_fraction
;
61
int
no_folds
;
62
int
ID
;
63
bool
done
;
64
};
65
66
struct
BALL_EXPORT
ModelConfiguration
67
{
68
ModelConfiguration
();
69
70
bool
done
;
71
String
data_file
;
72
String
output
;
73
String
descriptor_source_model
;
74
vector<double>
model_parameters
;
75
int
model_no
;
76
int
kernel_type
;
77
double
kernel_par1
;
78
double
kernel_par2
;
79
int
k_fold
;
80
bool
optimize_model_parameters
;
81
double
grid_search_stepwidth
;
82
int
grid_search_steps
;
83
int
grid_search_recursions
;
84
bool
within_section
;
85
bool
no_training
;
86
};
87
88
struct
BALL_EXPORT
FeatureSelectionConfiguration
89
{
90
FeatureSelectionConfiguration
();
91
92
String
model
;
93
String
data_file
;
94
int
feat_type
;
95
String
output
;
96
int
k_fold
;
97
bool
within_section
;
98
String
statistic_name
;
99
String
selection_name
;
100
int
statistic
;
101
bool
remove_correlated
;
102
double
cor_threshold
;
103
bool
opt_model_after_fs
;
104
bool
opt_kernel_after_fs
;
105
double
quality_increase_cutoff
;
106
bool
opt
;
107
bool
done
;
108
int
grid_search_steps
;
109
int
grid_search_recursions
;
110
double
grid_search_stepwidth
;
111
int
opt_k_fold
;
112
};
113
114
struct
BALL_EXPORT
ValidationConfiguration
115
{
116
ValidationConfiguration
();
117
118
String
model
;
119
String
data
;
120
String
validation_data
;
121
int
val_type
;
122
String
output
;
123
int
k_folds
;
124
int
bootstrap_samples
;
125
int
no_of_permutation_tests
;
126
int
statistic
;
127
String
statistic_name
;
128
vector<String>
external_predictions
;
129
bool
for_visualization_only
;
130
bool
done
;
131
};
132
133
struct
BALL_EXPORT
PredictionConfiguration
134
{
135
PredictionConfiguration
();
136
137
String
model
;
138
String
data
;
139
String
output
;
140
int
statistic
;
141
String
statistic_name
;
142
bool
print_expected
;
143
bool
done
;
144
};
145
146
147
class
BALL_EXPORT
ConfigIO
148
{
149
public
:
150
151
static
void
putbackLine(std::istream* input,
String
& line);
152
153
static
ModelConfiguration
readModelConfiguration(std::istream* input);
154
155
static
FeatureSelectionConfiguration
readFeatureSelectionConfiguration(std::istream* input);
156
157
static
InputConfiguration
readInputConfiguration(std::istream* input);
158
159
static
InputPartitioningConfiguration
readInputPartitioningConfiguration(std::istream* input);
160
161
static
ValidationConfiguration
readValidationConfiguration(std::istream* input);
162
163
static
PredictionConfiguration
readPredictionConfiguration(std::istream* input);
164
};
165
}
166
}
167
168
169
#endif // CONFIG_IO_H
Generated by
1.8.3.1