1 #ifndef _SLIDING_WINDOW_OBJECT_DETECTOR_TRAINER_H_ 2 #define _SLIDING_WINDOW_OBJECT_DETECTOR_TRAINER_H_ 11 #include <boost/foreach.hpp> 12 #include <opencv2/opencv.hpp> 14 #include <sensor_msgs/Image.h> 15 #include <sensor_msgs/CameraInfo.h> 47 #if CV_MAJOR_VERSION >= 3 // http://answers.opencv.org/question/46770/cvknearest-missing-in-300-cvmlknearest-abstract/ 54 const cv::Mat &,
const cv::Mat &, cv::Mat &,
bool =
true);
61 std::string, std::string);
63 std::string, std::string, cv::Mat &,
64 cv::Mat &,
bool =
false,
const int = 0);
66 cv::Mat &, cv::Mat &);
68 const cv::Mat &,
const cv::Mat &);
72 cv::Mat &, cv::Mat &,
const int = 64,
const int = 32,
bool =
true);
77 #endif // _SLIDING_WINDOW_OBJECT_DETECTOR_TRAINER_H_
virtual void trainBinaryClassSVM(const cv::Mat &, const cv::Mat &)
SlidingWindowObjectDetectorTrainer()
std::string dataset_path_
std::string nonobject_dataset_topic_
boost::shared_ptr< cv::SVM > supportVectorMachine_
virtual void concatenateCVMat(const cv::Mat &, const cv::Mat &, cv::Mat &, bool=true)
virtual void readDataset(std::string, std::string, cv::Mat &, cv::Mat &, bool=false, const int=0)
std::string nonobject_dataset_filename_
std::string object_dataset_topic_
virtual void trainObjectClassifier(std::string, std::string)
std::string manifest_filename_
boost::shared_ptr< rosbag::Bag > rosbag_
virtual void extractFeatures(cv::Mat &, cv::Mat &)
std::string trained_classifier_name_
virtual void computeHSHistogram(cv::Mat &, cv::Mat &, const int=64, const int=32, bool=true)
void writeTrainingManifestToDirectory(cv::FileStorage &)
std::string object_dataset_filename_