Search in sources :

Example 1 with GenericOrientationImageTests

use of boofcv.alg.feature.orientation.GenericOrientationImageTests in project BoofCV by lessthanoptimal.

the class TestOrientationSiftToImage method generic.

/**
 * Tests using generic tests for image orientation
 */
@Test
public void generic() {
    ConfigSiftOrientation config = new ConfigSiftOrientation();
    double pixelRadiusAtRadius1 = config.sigmaEnlarge / BoofDefaults.SIFT_SCALE_TO_RADIUS;
    SiftScaleSpace ss = new SiftScaleSpace(-1, 5, 3, 1.6);
    OrientationHistogramSift<GrayF32> orig = FactoryOrientationAlgs.sift(null, GrayF32.class);
    OrientationSiftToImage<GrayF32> alg = new OrientationSiftToImage<>(orig, ss, GrayF32.class);
    GenericOrientationImageTests tests = new GenericOrientationImageTests();
    tests.setup(angleTol, (int) (pixelRadiusAtRadius1 + 0.5), alg, GrayF32.class);
    tests.performAll();
}
Also used : GenericOrientationImageTests(boofcv.alg.feature.orientation.GenericOrientationImageTests) GrayF32(boofcv.struct.image.GrayF32) SiftScaleSpace(boofcv.alg.feature.detect.interest.SiftScaleSpace) Test(org.junit.Test)

Example 2 with GenericOrientationImageTests

use of boofcv.alg.feature.orientation.GenericOrientationImageTests in project BoofCV by lessthanoptimal.

the class TestOrientationIntegralToImage method generic.

/**
 * Tests using generic tests for image orientation
 */
@Test
public void generic() {
    ConfigAverageIntegral config = new ConfigAverageIntegral();
    config.radius = r;
    config.objectRadiusToScale = 1 / 3.0;
    OrientationIntegral<GrayF32> orig = FactoryOrientationAlgs.average_ii(config, GrayF32.class);
    OrientationIntegralToImage<GrayF32, GrayF32> alg = new OrientationIntegralToImage<>(orig, GrayF32.class, GrayF32.class);
    GenericOrientationImageTests tests = new GenericOrientationImageTests();
    tests.setup(angleTol, r * 2 + 1, alg, GrayF32.class);
    tests.performAll();
}
Also used : GenericOrientationImageTests(boofcv.alg.feature.orientation.GenericOrientationImageTests) GrayF32(boofcv.struct.image.GrayF32) Test(org.junit.Test)

Example 3 with GenericOrientationImageTests

use of boofcv.alg.feature.orientation.GenericOrientationImageTests in project BoofCV by lessthanoptimal.

the class TestOrientationGradientToImage method generic.

/**
 * Tests using generic tests for image orientation
 */
@Test
public void generic() {
    OrientationGradient<GrayF32> orig = FactoryOrientationAlgs.average(1.0 / 2.0, r, false, GrayF32.class);
    ImageGradient<GrayF32, GrayF32> gradient = FactoryDerivative.sobel(GrayF32.class, null);
    OrientationGradientToImage<GrayF32, GrayF32> alg = new OrientationGradientToImage<>(orig, gradient, GrayF32.class, GrayF32.class);
    GenericOrientationImageTests tests = new GenericOrientationImageTests();
    tests.setup(angleTol, r * 2 + 1, alg, GrayF32.class);
    tests.performAll();
}
Also used : GenericOrientationImageTests(boofcv.alg.feature.orientation.GenericOrientationImageTests) GrayF32(boofcv.struct.image.GrayF32) Test(org.junit.Test)

Aggregations

GenericOrientationImageTests (boofcv.alg.feature.orientation.GenericOrientationImageTests)3 GrayF32 (boofcv.struct.image.GrayF32)3 Test (org.junit.Test)3 SiftScaleSpace (boofcv.alg.feature.detect.interest.SiftScaleSpace)1