private void button9_Click(object sender, EventArgs e) { var tmp = TestImageGenerator.GetTestPair(size0, size1, 5, 15); image = tmp.Item1.images[0]; image_res = tmp.Item2; fft_image = Complex.CreateComplexArray(image); FourierTransform.FFT2(fft_image, FourierTransform.Direction.Forward); CreateHilbertFilter(); Complex.ApplyFilter(fft_image, filter_image); FourierTransform.FFT2(fft_image, FourierTransform.Direction.Backward); image = Tools.CalculatePhaseImageByHilbert(fft_image); unwrapper.UpdateParamsIfNeed(image); unwrapper.UnwrapParallel(image, out var scr); ImageSource.subtract_min(image); ImageSource.subtract_min(image_res); var d = ImageSource.diff(image, image_res); label1.Text = Math.Round(ImageSource.max(d), 5).ToString();; label2.Text = Math.Round(ImageSource.min(d), 5).ToString();; label3.Text = Math.Round(ImageSource.std(image, image_res), 5).ToString();; label1.Update(); label2.Update(); label3.Update(); plot(d); }
public virtual void Unwrapp() { Unwrapping3 unwrapper = new Unwrapping3(images[0]); foreach (double[,] image in images) { unwrapper.UnwrapParallel(image, out var t); } DelTrend(); }