32 #ifndef ROBUSTNESS_TOOL_H 33 #define ROBUSTNESS_TOOL_H 35 #include <boost/filesystem.hpp> 36 #include <opencv2/opencv.hpp> 47 virtual void computeImage(
const cv::Mat &image, cv::Mat &computed_image) = 0;
54 cv::Mat &computed_segmentation) = 0;
58 virtual bool next() = 0;
80 RobustnessTool(boost::filesystem::path &base_directory, boost::filesystem::path &image_directory,
86 void setFilesToKeep(
const std::vector<std::string> &files);
97 void cleanDirectory(boost::filesystem::path directory);
100 boost::filesystem::path base_directory;
102 boost::filesystem::path image_directory;
104 boost::filesystem::path gt_directory;
107 std::string command_line;
113 std::vector<std::string> files;
132 void computeImage(
const cv::Mat &image, cv::Mat &computed_image);
139 cv::Mat &computed_segmentation);
156 std::vector<float> variances;
175 void computeImage(
const cv::Mat &image, cv::Mat &computed_image);
182 cv::Mat &computed_segmentation);
209 void computeImage(
const cv::Mat &image, cv::Mat &computed_image);
216 cv::Mat &computed_segmentation);
230 std::vector<float> probabilities;
251 void computeImage(
const cv::Mat &image, cv::Mat &computed_image);
258 cv::Mat &computed_segmentation);
272 std::vector<int> sizes;
288 GaussianBlurDriver(
const std::vector<int> &sizes,
const std::vector<float> &variances);
294 void computeImage(
const cv::Mat &image, cv::Mat &computed_image);
301 cv::Mat &computed_segmentation);
315 std::vector<int> sizes;
318 std::vector<float> variances;
339 void computeImage(
const cv::Mat &image, cv::Mat &computed_image);
346 cv::Mat &computed_segmentation);
360 std::vector<int> sizes;
377 const std::vector<float> &space_variances);
383 void computeImage(
const cv::Mat &image, cv::Mat &computed_image);
390 cv::Mat &computed_segmentation);
404 std::vector<int> sizes;
407 std::vector<float> color_variances;
410 std::vector<float> space_variances;
426 MotionBlurDriver(
const std::vector<int> &sizes,
const std::vector<float> &angles);
432 void computeImage(
const cv::Mat &image, cv::Mat &computed_image);
439 cv::Mat &computed_segmentation);
453 std::vector<int> sizes;
456 std::vector<float> angles;
473 ShearDriver(std::string type,
int crop,
const std::vector<float> &m);
479 void computeImage(
const cv::Mat &image, cv::Mat &computed_image);
486 cv::Mat &computed_segmentation);
506 std::vector<float> m;
528 void computeImage(
const cv::Mat &image, cv::Mat &computed_image);
535 cv::Mat &computed_segmentation);
552 std::vector<float> angles;
569 TranslationDriver(
int crop,
const std::vector<int> &x,
const std::vector<int> &y);
575 void computeImage(
const cv::Mat &image, cv::Mat &computed_image);
582 cv::Mat &computed_segmentation);
Poisson noise driver.
Definition: robustness_tool.h:164
Blur driver.
Definition: robustness_tool.h:239
Additive Gaussian noise and Gaussian sampling error driver.
Definition: robustness_tool.h:119
Motion blur driver.
Definition: robustness_tool.h:419
Vertical and horizontal shear driver.
Definition: robustness_tool.h:465
Rotation driver.
Definition: robustness_tool.h:515
Bilateral filter driver.
Definition: robustness_tool.h:368
Salt and pepper noise driver.
Definition: robustness_tool.h:197
Gaussian blur filter.
Definition: robustness_tool.h:281
Translation driver.
Definition: robustness_tool.h:561