From 469ae0ee57b29563a82ab65e272c774f548f048d Mon Sep 17 00:00:00 2001 From: Martin Reinecke <martin@mpa-garching.mpg.de> Date: Sun, 21 May 2017 11:13:20 +0200 Subject: [PATCH] remove aggressive warnings --- .../fft_operator/transformations/gllmtransformation.py | 5 ----- .../fft_operator/transformations/hplmtransformation.py | 5 ----- .../fft_operator/transformations/lmgltransformation.py | 5 ----- .../fft_operator/transformations/lmhptransformation.py | 5 ----- .../fft_operator/transformations/rg_transforms.py | 10 ---------- 5 files changed, 30 deletions(-) diff --git a/nifty/operators/fft_operator/transformations/gllmtransformation.py b/nifty/operators/fft_operator/transformations/gllmtransformation.py index a0e47652b..7029f80ea 100644 --- a/nifty/operators/fft_operator/transformations/gllmtransformation.py +++ b/nifty/operators/fft_operator/transformations/gllmtransformation.py @@ -100,11 +100,6 @@ class GLLMTransformation(SlicingTransformation): super(GLLMTransformation, cls).check_codomain(domain, codomain) def _transformation_of_slice(self, inp, **kwargs): - if inp.dtype not in (np.float, np.complex): - self.logger.warn("The input array has dtype: %s. The FFT will " - "be performed at double precision." % - str(inp.dtype)) - nlat = self.domain.nlat nlon = self.domain.nlon lmax = self.codomain.lmax diff --git a/nifty/operators/fft_operator/transformations/hplmtransformation.py b/nifty/operators/fft_operator/transformations/hplmtransformation.py index 314caa008..c8cb15710 100644 --- a/nifty/operators/fft_operator/transformations/hplmtransformation.py +++ b/nifty/operators/fft_operator/transformations/hplmtransformation.py @@ -92,11 +92,6 @@ class HPLMTransformation(SlicingTransformation): super(HPLMTransformation, cls).check_codomain(domain, codomain) def _transformation_of_slice(self, inp, **kwargs): - if inp.dtype not in (np.float, np.complex): - self.logger.warn("The input array has dtype: %s. The FFT will " - "be performed at double precision." % - str(inp.dtype)) - lmax = self.codomain.lmax mmax = lmax diff --git a/nifty/operators/fft_operator/transformations/lmgltransformation.py b/nifty/operators/fft_operator/transformations/lmgltransformation.py index 5e743c4da..44e5c54e8 100644 --- a/nifty/operators/fft_operator/transformations/lmgltransformation.py +++ b/nifty/operators/fft_operator/transformations/lmgltransformation.py @@ -106,11 +106,6 @@ class LMGLTransformation(SlicingTransformation): super(LMGLTransformation, cls).check_codomain(domain, codomain) def _transformation_of_slice(self, inp, **kwargs): - if inp.dtype not in (np.float, np.complex): - self.logger.warn("The input array has dtype: %s. The FFT will " - "be performed at double precision." % - str(inp.dtype)) - nlat = self.codomain.nlat nlon = self.codomain.nlon lmax = self.domain.lmax diff --git a/nifty/operators/fft_operator/transformations/lmhptransformation.py b/nifty/operators/fft_operator/transformations/lmhptransformation.py index 6aa87e973..0e9d1e392 100644 --- a/nifty/operators/fft_operator/transformations/lmhptransformation.py +++ b/nifty/operators/fft_operator/transformations/lmhptransformation.py @@ -94,11 +94,6 @@ class LMHPTransformation(SlicingTransformation): super(LMHPTransformation, cls).check_codomain(domain, codomain) def _transformation_of_slice(self, inp, **kwargs): - if inp.dtype not in (np.float, np.complex): - self.logger.warn("The input array has dtype: %s. The FFT will " - "be performed at double precision." % - str(inp.dtype)) - nside = self.codomain.nside lmax = self.domain.lmax mmax = lmax diff --git a/nifty/operators/fft_operator/transformations/rg_transforms.py b/nifty/operators/fft_operator/transformations/rg_transforms.py index acc072291..0ccdb22c5 100644 --- a/nifty/operators/fft_operator/transformations/rg_transforms.py +++ b/nifty/operators/fft_operator/transformations/rg_transforms.py @@ -433,11 +433,6 @@ class FFTW(Transform): not all(axis in range(len(val.shape)) for axis in axes): raise ValueError("Provided axes does not match array shape") - #if val.dtype not in (np.float, np.complex): - # self.logger.warn("The input array has dtype: %s. The FFT will " - # "be performed at double precision." % - # str(val.dtype)) - # If the input is a numpy array we transform it locally if not isinstance(val, distributed_data_object): # Cast to a np.ndarray @@ -582,11 +577,6 @@ class NUMPYFFT(Transform): not all(axis in range(len(val.shape)) for axis in axes): raise ValueError("Provided axes does not match array shape") - if val.dtype not in (np.float, np.complex): - self.logger.warn("The input array has dtype: %s. The FFT will " - "be performed at double precision." % - str(val.dtype)) - return_val = val.copy_empty(global_shape=val.shape, dtype=np.complex) -- GitLab