diff --git a/include/falkolib/Matching/AHTMatcher.h b/include/falkolib/Matching/AHTMatcher.h
index 8dcd985fba4fdfd2e77ef088ab69b00be2f01435..08f2def2908d36d564f6011a6451ce6c8166d0ef 100644
--- a/include/falkolib/Matching/AHTMatcher.h
+++ b/include/falkolib/Matching/AHTMatcher.h
@@ -138,6 +138,8 @@ namespace falkolib {
 
 		/** @brief get best matching given point and an initial guest associations list*/
 		int getBestMatching(const std::vector<T>& v1, const std::vector<T>& v2, const std::vector<std::pair<int, int> >& init, std::vector<std::pair<int, int> >& match) {
+			for (auto &cell : matchesGrid)
+		        cell.clear();
 			for (auto& asso : init) {
 				for (int it = 0; it < thetaSize; ++it) {
 					double theta = thetaRes * (it - thetaSize / 2);