ComplexFftInverse
Computes the Fast Fourier inverse Transform of an image.
Access to parameter description
For an introduction: see section Frequency Domain.
This algorithm computes the inverse FFT of an image. The result is two floating point images, respectively the real and imaginary parts of the complex inverse Fourier Transform.
Remarks
Access to parameter description
For an introduction: see section Frequency Domain.
This algorithm computes the inverse FFT of an image. The result is two floating point images, respectively the real and imaginary parts of the complex inverse Fourier Transform.
Remarks
- A classical operation is to first filter the spectrum of an image (especially to suppress high frequencies usually associated with noise), and then reconstruct the input image using ComplexFftInverse with the filtered spectrum and unchanged phase as input images.
- Images are centered in the upper left corner. The ComplexCenteredFft algorithm can be used to directly get a centered FFT.
Function Syntax
This function returns a ComplexFftInverseOutput structure containing the outputRealImage and outputImaginaryImage output parameters.
// Output structure. struct ComplexFftInverseOutput { std::shared_ptr< iolink::ImageView > outputRealImage; std::shared_ptr< iolink::ImageView > outputImaginaryImage; }; // Function prototype. ComplexFftInverseOutput complexFftInverse( std::shared_ptr< iolink::ImageView > inputRealImage, std::shared_ptr< iolink::ImageView > inputImaginaryImage, std::shared_ptr< iolink::ImageView > outputRealImage = NULL, std::shared_ptr< iolink::ImageView > outputImaginaryImage = NULL );
This function returns a tuple containing the output_real_image and output_imaginary_image output parameters.
// Function prototype. complex_fft_inverse( input_real_image, input_imaginary_image, output_real_image = None, output_imaginary_image = None )
This function returns a ComplexFftInverseOutput structure containing the outputRealImage and outputImaginaryImage output parameters.
/// Output structure of the ComplexFftInverse function. public struct ComplexFftInverseOutput { public IOLink.ImageView outputRealImage; public IOLink.ImageView outputImaginaryImage; }; // Function prototype. public static ComplexFftInverseOutput ComplexFftInverse( IOLink.ImageView inputRealImage, IOLink.ImageView inputImaginaryImage, IOLink.ImageView outputRealImage = null, IOLink.ImageView outputImaginaryImage = null );
Class Syntax
Parameters
Class Name | ComplexFftInverse |
---|
Parameter Name | Description | Type | Supported Values | Default Value | |
---|---|---|---|---|---|
inputRealImage |
The real part input image. It must be a floating point image. | Image | Grayscale or Multispectral | nullptr | |
inputImaginaryImage |
The imaginary part input image. This image must have same dimensions and data type as the real input image. | Image | Grayscale or Multispectral | nullptr | |
outputRealImage |
The output real part image. Its dimensions are forced to the same values as the input. Its data type is forced to floating point. | Image | nullptr | ||
outputImaginaryImage |
The output imaginary part image. Its dimensions are forced to the same values as the input. Its data type is forced to floating point. | Image | nullptr |
Object Examples
auto polystyrene_float = readVipImage( std::string( IMAGEDEVDATA_IMAGES_FOLDER ) + "polystyrene_float.vip" ); ComplexFftInverse complexFftInverseAlgo; complexFftInverseAlgo.setInputRealImage( polystyrene_float ); complexFftInverseAlgo.setInputImaginaryImage( polystyrene_float ); complexFftInverseAlgo.execute(); std::cout << "outputRealImage:" << complexFftInverseAlgo.outputRealImage()->toString(); std::cout << "outputImaginaryImage:" << complexFftInverseAlgo.outputImaginaryImage()->toString();
polystyrene_float = imagedev.read_vip_image(imagedev_data.get_image_path("polystyrene_float.vip")) complex_fft_inverse_algo = imagedev.ComplexFftInverse() complex_fft_inverse_algo.input_real_image = polystyrene_float complex_fft_inverse_algo.input_imaginary_image = polystyrene_float complex_fft_inverse_algo.execute() print( "output_real_image:", str( complex_fft_inverse_algo.output_real_image ) ); print( "output_imaginary_image:", str( complex_fft_inverse_algo.output_imaginary_image ) );
ImageView polystyrene_float = Data.ReadVipImage( @"Data/images/polystyrene_float.vip" ); ComplexFftInverse complexFftInverseAlgo = new ComplexFftInverse { inputRealImage = polystyrene_float, inputImaginaryImage = polystyrene_float }; complexFftInverseAlgo.Execute(); Console.WriteLine( "outputRealImage:" + complexFftInverseAlgo.outputRealImage.ToString() ); Console.WriteLine( "outputImaginaryImage:" + complexFftInverseAlgo.outputImaginaryImage.ToString() );
Function Examples
auto polystyrene_float = readVipImage( std::string( IMAGEDEVDATA_IMAGES_FOLDER ) + "polystyrene_float.vip" ); auto result = complexFftInverse( polystyrene_float, polystyrene_float ); std::cout << "outputRealImage:" << result.outputRealImage->toString(); std::cout << "outputImaginaryImage:" << result.outputImaginaryImage->toString();
polystyrene_float = imagedev.read_vip_image(imagedev_data.get_image_path("polystyrene_float.vip")) result_output_real_image, result_output_imaginary_image = imagedev.complex_fft_inverse( polystyrene_float, polystyrene_float ) print( "output_real_image:", str( result_output_real_image ) ); print( "output_imaginary_image:", str( result_output_imaginary_image ) );
ImageView polystyrene_float = Data.ReadVipImage( @"Data/images/polystyrene_float.vip" ); Processing.ComplexFftInverseOutput result = Processing.ComplexFftInverse( polystyrene_float, polystyrene_float ); Console.WriteLine( "outputRealImage:" + result.outputRealImage.ToString() ); Console.WriteLine( "outputImaginaryImage:" + result.outputImaginaryImage.ToString() );