[obspy-users] Obspy can't find np.fft.fftpack

Tobias Megies megies at geophysik.uni-muenchen.de
Mon Mar 27 11:06:30 CEST 2017


Hi Phil,

I just tried current conda packages (Linux 64bit) for numpy (version
1.12.1) from both defaults and conda-forge channel and in both the
numpy.fft.fftpack submodule is present.

Can you do..?
 - conda list numpy
 - python -c 'import numpy; print(numpy.__version__);
print(numpy.__file__); print(numpy.fft.fftpack)'

You could also try to remove numpy ("conda remove --force numpy"; option
--force to not remove other packages that depend on numpy) and install
it again ("conda install --force numpy"), this might fix it if your
package installation is broken somehow..


cheers,
T


On 24/03/17 07:53, Phil Cummins wrote:
> Hi,
> 
> 
> I am running obspy version 1.0.3 under anaconda, and am using
> numpy version 1.12.1. My OS is Ubuntu 14.04. A friend sent me an
> obspy script that does instrument deconvolution using
> tr.remove_response, but it encounters the following error:
> 
> 
>   File
> "/home/ryanign/ANU-RSES-u5484353/Academics/PhD_research/02_HistoricalTsunamis/1992_Flores/seismic/neic/get_data_neic.py",
> line 544, in getobs
>     tr.remove_response(pre_filt=frq4[phase],output='DISP')
> 
>   File "<decorator-gen-162>", line 2, in remove_response
> 
>   File
> "/home/ryanign/APPS/anaconda/lib/python2.7/site-packages/obspy/core/trace.py",
> line 232, in _add_processing_info
>     result = func(*args, **kwargs)
> 
>   File
> "/home/ryanign/APPS/anaconda/lib/python2.7/site-packages/obspy/core/trace.py",
> line 2596, in remove_response
>     limit_numpy_fft_cache()
> 
>   File
> "/home/ryanign/APPS/anaconda/lib/python2.7/site-packages/obspy/core/util/misc.py",
> line 511, in limit_numpy_fft_cache
>     if not hasattr(np.fft.fftpack, cache):
> 
> AttributeError: 'module' object has no attribute 'fftpack
> 
> When I import numpy.fft, I can see that it indeed does not have the
> package fftpack. Can anyone suggest a way to work around this problem?
> 
> Thanks,
> 
> 
> - Phil
> 
> 
> 
> _______________________________________________
> obspy-users mailing list
> obspy-users at lists.swapbytes.de
> http://lists.swapbytes.de/mailman/listinfo/obspy-users
> 

-- 
Dipl.-Geophys. Tobias Megies

EMail: tobias.megies at lmu.de
WWW: https://www.geophysik.uni-muenchen.de

Geophysikalisches Observatorium
Ludwigshöhe 8
82256 Fürstenfeldbruck

Tel: +49 (0) 89 2180-73981
Fax: +49 (0) 89 2180-73970

Ludwig-Maximilians-Universität
Department für Geo- und Umweltwissenschaften
Sektion Geophysik
Theresienstrasse 41/IV
80333 München

Tel: +49 (0) 89 2180-4326
Fax: +49 (0) 89 2180-4205


More information about the obspy-users mailing list