use of boofcv.struct.image.GrayS16 in project BoofCV by lessthanoptimal.
the class TestHessianThree method compareToConvolve_I8.
// @Test
// public void checkInputShape() {
// GenericDerivativeTests.checkImageDimensionValidation(new HessianThree(), 2);
// }
@Test
public void compareToConvolve_I8() throws NoSuchMethodException {
CompareDerivativeToConvolution validator = new CompareDerivativeToConvolution();
validator.setTarget(HessianThree.class.getMethod("process", GrayU8.class, GrayS16.class, GrayS16.class, GrayS16.class, ImageBorder_S32.class));
validator.setKernel(0, HessianThree.kernelXXYY_I32, true);
validator.setKernel(1, HessianThree.kernelXXYY_I32, false);
validator.setKernel(2, HessianThree.kernelCross_I32);
GrayU8 input = new GrayU8(width, height);
ImageMiscOps.fillUniform(input, rand, 0, 10);
GrayS16 derivXX = new GrayS16(width, height);
GrayS16 derivYY = new GrayS16(width, height);
GrayS16 derivXY = new GrayS16(width, height);
validator.compare(input, derivXX, derivYY, derivXY);
}
use of boofcv.struct.image.GrayS16 in project BoofCV by lessthanoptimal.
the class TestGradientSobel_Naive method compareToKnown_I8.
/**
* Compare the results to a hand computed value
*/
@Test
public void compareToKnown_I8() {
GrayU8 img = new GrayU8(width, height);
ImageMiscOps.fillUniform(img, rand, 0, 100);
GrayS16 derivX = new GrayS16(width, height);
GrayS16 derivY = new GrayS16(width, height);
BoofTesting.checkSubImage(this, "compareToKnown_I8", true, img, derivX, derivY);
}
use of boofcv.struct.image.GrayS16 in project BoofCV by lessthanoptimal.
the class TestConvolveNormalizedStandardSparse method computeExpected.
private float computeExpected(GrayS16 image) {
GrayS16 temp = new GrayS16(image.width, image.height);
GrayS16 temp2 = new GrayS16(image.width, image.height);
ConvolveImageNormalized.horizontal(kernelI32, image, temp);
ConvolveImageNormalized.vertical(kernelI32, temp, temp2);
return temp2.get(targetX, targetY);
}
use of boofcv.struct.image.GrayS16 in project BoofCV by lessthanoptimal.
the class TestGradientTwo1_Standard method compareToConvolve_I8.
@Test
public void compareToConvolve_I8() throws NoSuchMethodException {
CompareDerivativeToConvolution validator = new CompareDerivativeToConvolution();
validator.setTarget(GradientTwo1_Standard.class.getMethod("process", GrayU8.class, GrayS16.class, GrayS16.class));
validator.setKernel(0, GradientTwo1.kernelDeriv_I32, true);
validator.setKernel(1, GradientTwo1.kernelDeriv_I32, false);
GrayU8 input = new GrayU8(width, height);
ImageMiscOps.fillUniform(input, rand, 0, 10);
GrayS16 derivX = new GrayS16(width, height);
GrayS16 derivY = new GrayS16(width, height);
validator.compare(false, input, derivX, derivY);
}
use of boofcv.struct.image.GrayS16 in project BoofCV by lessthanoptimal.
the class TestHessianSobel_Shared method compareToConvolve_I8.
@Test
public void compareToConvolve_I8() throws NoSuchMethodException {
CompareDerivativeToConvolution validator = new CompareDerivativeToConvolution();
validator.setTarget(HessianSobel_Shared.class.getMethod("process", GrayU8.class, GrayS16.class, GrayS16.class, GrayS16.class));
validator.setKernel(0, HessianSobel.kernelXX_I32);
validator.setKernel(1, HessianSobel.kernelYY_I32);
validator.setKernel(2, HessianSobel.kernelXY_I32);
GrayU8 input = new GrayU8(width, height);
ImageMiscOps.fillUniform(input, rand, 0, 10);
GrayS16 derivXX = new GrayS16(width, height);
GrayS16 derivYY = new GrayS16(width, height);
GrayS16 derivXY = new GrayS16(width, height);
validator.compare(false, input, derivXX, derivYY, derivXY);
}
Aggregations