23 #include <boost/filesystem.hpp>
24 #include <boost/algorithm/string.hpp>
26 #include <boost/regex.hpp>
28 using boost::regex_match;
37 namespace po = boost::program_options;
38 namespace fs = boost::filesystem;
41 namespace SourceXtractor {
59 return {{
"External flag options", {
61 "The FITS file containing the external flag, several images can be provided, replace * by any identifier (ex. use numbers)"},
63 "The combination type of the external flag (OR, AND, MIN, MAX, MOST)"}
84 if (available_types.count(type) == 0) {
96 boost::regex hdu_regex(
".*\\[[0-9]*\\]$");
100 if (boost::regex_match(
filename, hdu_regex)) {
114 if (flag_images.size() == 0) {
131 Type type = available_types.at(type_str);
static std::string wildcard(const std::string &name, const std::string &instance="*")
static std::set< std::string > findWildcardNames(const std::vector< std::string > &option_name_list, const std::map< std::string, boost::program_options::variable_value > &options)