upgrade opencv to 3.3.1, complete patch similarity
[trackerpp.git] / include / MultiTracker.h
index 190225d..58ef922 100644 (file)
@@ -6,6 +6,7 @@
 #include "SharedPtr.h"
 #include "PredictorWrapper.h"
 #include <opencv2/opencv.hpp>
+#include <utility>
 
 namespace suanzi {
 
@@ -23,7 +24,7 @@ namespace suanzi {
     private:
         std::vector<TrackerPtr> trackers;
         int max_id = 0;
-        PatchPtr createPatch(const cv::Mat& image);
+        PatchPtr createPatch(const cv::Mat& image, const Detection& d);
         double distance(TrackerPtr t, const cv::Mat& image, const Detection& d);
         PredictorWrapperPtr predictor;
         cv::HOGDescriptor descriptor;
@@ -33,9 +34,12 @@ namespace suanzi {
     {
     public:
         ~Patch(){};
-        // bb_ltrb
         cv::Mat image_crop;
-        std::vector<float> features;
+        //std::vector<double> features;
+        // hog is a hog descriptor of the image (calculated by hog.compute. size is 3780 )
+        // hue is a histogram of the image, (calcHist(), is a Mat with (width x height) 64 x 45)
+        std::pair<std::vector<double>, cv::Mat> features;
+        Detection detection;
     protected:
         friend class MultiTracker;
         Patch(){};