private void createSmoothingKernel() { BestCS.Math.Gaussian g = new BestCS.Math.Gaussian(smoothingSigma); gaussianKernel = g.Kernel(smoothingKernelSize); // Normalize double norm = gaussianKernel.Euclidean(); gaussianKernel = gaussianKernel.Divide(norm); }
private void createGaussian() { double[] aforgeKernel = new BestCS.Math.Gaussian(sigma).Kernel(size); this.kernel = Array.ConvertAll <double, float>(aforgeKernel, Convert.ToSingle); }