/** * Compute a Fourier space based convolution * The image will be extended by mirroring with single boundary, the kernel will be zero-padded. * The {@link ImgFactory} for creating the FFT will be identical to the one used by the 'img' if * possible, otherwise an {@link ArrayImgFactory} or {@link CellImgFactory} depending on the size. * * @param img - the image * @param kernel - the convolution kernel * @param output - the result of the convolution */ public FFTConvolution( final Img< R > img, final Img< R > kernel, final RandomAccessibleInterval< R > output ) { this ( img, kernel, output, getFFTFactory( img ) ); }
/** * Compute a Fourier space based convolution The image will be extended by * mirroring with single boundary, the kernel will be zero-padded. The * {@link ImgFactory} for creating the FFT will be identical to the one used * by the 'img' if possible, otherwise an {@link ArrayImgFactory} or * {@link CellImgFactory} depending on the size. * * @param img * - the image * @param kernel * - the convolution kernel * @param output * - the result of the convolution * @param service * - service providing threads for multi-threading */ public FFTConvolution( final Img< R > img, final Img< R > kernel, final RandomAccessibleInterval< R > output, final ExecutorService service ) { this( img, kernel, output, getFFTFactory( img ), service ); }
/** * Compute a Fourier space based convolution The image will be extended by * mirroring with single boundary, the kernel will be zero-padded. The * {@link ImgFactory} for creating the FFT will be identical to the one used * by the 'img' if possible, otherwise an {@link ArrayImgFactory} or * {@link CellImgFactory} depending on the size. * * ExecutorService will be created on {@link #convolve()} with threads equal * to number of processors equal to the runtime. * * @param img * - the image * @param kernel * - the convolution kernel * @param output * - the result of the convolution */ public FFTConvolution( final Img< R > img, final Img< R > kernel, final RandomAccessibleInterval< R > output ) { this( img, kernel, output, getFFTFactory( img ), null ); }