From 46eb8d1c8d825d31187aca0181b39c9c17ef6463 Mon Sep 17 00:00:00 2001 From: Davis King Date: Tue, 9 Aug 2011 17:06:01 -0400 Subject: [PATCH] added more unit tests for hog coordinate transforms --- dlib/test/hog_image.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/dlib/test/hog_image.cpp b/dlib/test/hog_image.cpp index 1f36d3165..cabc66cf8 100644 --- a/dlib/test/hog_image.cpp +++ b/dlib/test/hog_image.cpp @@ -78,8 +78,15 @@ namespace DLIB_TEST(hog1.feat_to_image_space(point(0,0)) == point(5,5)); DLIB_TEST(hog2.feat_to_image_space(point(0,0)) == point(9,9)); + DLIB_TEST(hog1.feat_to_image_space(point(1,1)) == point(8,8)); + DLIB_TEST(hog2.feat_to_image_space(point(1,1)) == point(17,17)); + DLIB_TEST(hog1.image_to_feat_space(hog1.feat_to_image_space(point(0,0))) == point(0,0)); DLIB_TEST(hog2.image_to_feat_space(hog2.feat_to_image_space(point(0,0))) == point(0,0)); + DLIB_TEST(hog1.image_to_feat_space(hog1.feat_to_image_space(point(1,1))) == point(1,1)); + DLIB_TEST(hog2.image_to_feat_space(hog2.feat_to_image_space(point(1,1))) == point(1,1)); + DLIB_TEST(hog1.image_to_feat_space(hog1.feat_to_image_space(point(1,2))) == point(1,2)); + DLIB_TEST(hog2.image_to_feat_space(hog2.feat_to_image_space(point(1,2))) == point(1,2)); } } a;