/*
 * Modified version of Keypoint.h
 * Source location: https://github.com/pippy360/transformationInvariantImageSearch/blob/master/fullEndToEndDemo/src/Keypoint.h
*/
#pragma once
#ifndef REVERSE_IMAGE_SEARCH_KEYPOINT_H
#define REVERSE_IMAGE_SEARCH_KEYPOINT_H

#include <iostream>
#include <sstream>
#include <math.h>

using namespace std;

class KeyPoint {
  public:
    double x_, y_;
    KeyPoint(double x, double y) {
        x_ = x;
        y_ = y;
    };

    /**
     * Convert a KeyPoint to a string
     * @return string
     */
    string ToString() {
        std::ostringstream string_stream_;
      string_stream_<< "KeyPoint[ " << x_ << ", " << y_ << "]";
        return string_stream_.str();
    }
};

namespace std {
  template <>
  struct hash<KeyPoint> {
      std::size_t operator()(const KeyPoint &k) const {
        using std::hash;
          return ((hash<double>()(k.x_) ^ (hash<double>()(k.y_) << 1)) >> 1);
      }
  };
}
#endif
/*
 * Modified version of Keypoint.h
 * Source location: https://github.com/pippy360/transformationInvariantImageSearch/blob/master/fullEndToEndDemo/src/Keypoint.h
*/
#pragma once
#ifndef REVERSE_IMAGE_SEARCH_KEYPOINT_H
#define REVERSE_IMAGE_SEARCH_KEYPOINT_H

#include <iostream>
#include <sstream>

using namespace std;

class KeyPoint {
  public:
    double x_, y_;
    KeyPoint(double x, double y) {
        x_ = x;
        y_ = y;
    };

    /**
     * Convert a KeyPoint to a string
     * @return string
     */
    string ToString() {
        std::ostringstream string_stream_;
      string_stream_<< "KeyPoint[ " << x_ << ", " << y_ << "]";
        return string_stream_.str();
    }
};

namespace hash {
  template <>
  struct hash<KeyPoint> {
      std::size_t operator()(const KeyPoint &k) const {
        using std::hash;
          return ((hash<double>()(k.x_) ^ (hash<double>()(k.y_) << 1)) >> 1);
      }
  };
}
#endif
--- 
+++ 
@@ -8,6 +8,7 @@
 
 #include <iostream>
 #include <sstream>
+#include <math.h>
 
 using namespace std;
 
@@ -30,7 +31,7 @@
     }
 };
 
-namespace hash {
+namespace std {
   template <>
   struct hash<KeyPoint> {
       std::size_t operator()(const KeyPoint &k) const {
Resolve compilation issue due to missing math.h inclusion
