2 * folded-ctf is an implementation of the folded hierarchy of
3 * classifiers for object detection, developed by Francois Fleuret
6 * Copyright (c) 2008 Idiap Research Institute, http://www.idiap.ch/
7 * Written by Francois Fleuret <francois.fleuret@idiap.ch>
9 * This file is part of folded-ctf.
11 * folded-ctf is free software: you can redistribute it and/or modify
12 * it under the terms of the GNU General Public License as published
13 * by the Free Software Foundation, either version 3 of the License,
14 * or (at your option) any later version.
16 * folded-ctf is distributed in the hope that it will be useful, but
17 * WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19 * General Public License for more details.
21 * You should have received a copy of the GNU General Public License
22 * along with folded-ctf. If not, see <http://www.gnu.org/licenses/>.
28 We stuff all the global values in there.
40 #include "param_parser.h"
41 #include "progress_bar.h"
43 enum { LOSS_EXPONENTIAL,
51 int pictures_for_article;
53 char pool_name[buffer_size];
54 char test_pool_name[buffer_size];
55 char detector_name[buffer_size];
56 char result_path[buffer_size];
61 int material_feature_nb;
65 int nb_weak_learners_per_classifier;
66 int nb_classifiers_per_level;
69 scalar_t proportion_negative_cells_for_training;
70 int nb_negative_samples_per_positive;
71 int nb_features_for_boosting_optimization;
72 int force_head_belly_independence;
74 scalar_t proportion_for_train;
75 scalar_t proportion_for_validation;
76 scalar_t proportion_for_test;
77 bool write_validation_rocs;
78 bool write_parse_images;
79 bool write_tag_images;
80 scalar_t wanted_true_positive_rate;
81 int nb_wanted_true_positive_rates;
83 int nb_scales_per_power_of_two;
84 scalar_t min_head_radius;
85 scalar_t max_head_radius;
86 int root_cell_nb_xy_per_radius;
88 scalar_t pi_feature_window_min_size;
95 void init_parser(ParamParser *parser);
96 void read_parser(ParamParser *parser);
100 inline int scale_to_discrete_log_scale(scalar_t scale_ratio) {
101 return int(floor(log(scale_ratio) / log(2.0) * nb_scales_per_power_of_two));
104 inline scalar_t discrete_log_scale_to_scale(int discrete_scale) {
105 return exp( - scalar_t(discrete_scale) * log(2.0) / scalar_t(nb_scales_per_power_of_two));
109 extern Global global;