def calculate_FFT(self): imaginary_workspace_index = 0 real_workspace_padding_parameters = self.get_pre_inputs() imaginary_workspace_padding_parameters = self.get_imaginary_inputs() real_workspace_input = run_PaddingAndApodization( real_workspace_padding_parameters) if self.view.imaginary_data: if 'PhaseQuad' in self.view.workspace: imaginary_workspace_input = real_workspace_input imaginary_workspace_padding_parameters[ 'InputWorkspace'] = real_workspace_padding_parameters[ 'InputWorkspace'] imaginary_workspace_index = 1 else: imaginary_workspace_input = run_PaddingAndApodization( imaginary_workspace_padding_parameters) else: imaginary_workspace_input = None imaginary_workspace_padding_parameters['InputWorkspace'] = "" fft_parameters = self.get_fft_inputs(real_workspace_input, imaginary_workspace_input, imaginary_workspace_index) frequency_domain_workspace = convert_to_field(run_FFT(fft_parameters)) self.add_fft_workspace_to_ADS( real_workspace_padding_parameters['InputWorkspace'], imaginary_workspace_padding_parameters['InputWorkspace'], frequency_domain_workspace)
def calculate_FFT(self): imaginary_workspace_index = 0 real_workspace_padding_parameters = self.get_pre_inputs() imaginary_workspace_padding_parameters = self.get_imaginary_inputs() real_workspace_input = run_PaddingAndApodization(real_workspace_padding_parameters) if self.view.imaginary_data: if 'PhaseQuad' in self.view.workspace: imaginary_workspace_input = real_workspace_input imaginary_workspace_padding_parameters['InputWorkspace'] = real_workspace_padding_parameters['InputWorkspace'] imaginary_workspace_index = 1 else: imaginary_workspace_input = run_PaddingAndApodization(imaginary_workspace_padding_parameters) else: imaginary_workspace_input = None fft_parameters = self.get_fft_inputs(real_workspace_input, imaginary_workspace_input, imaginary_workspace_index) frequency_domain_workspace = run_FFT(fft_parameters) self.add_fft_workspace_to_ADS(real_workspace_padding_parameters['InputWorkspace'], imaginary_workspace_padding_parameters['InputWorkspace'], frequency_domain_workspace)