0

I am having some trouble getting the filter design tool to even start. When starting the application I get

"This example requires a Numerical Python Extension, but
 failed to import either NumPy, or numarray, or Numeric.
 NumPy is available at http://sourceforge.net/projects/numpy". 

I have rebuild GNU Radio a couple of times now, and I am fairly sure that I have every thing installed that is required. I do have numpy installed, and I have tried a couple of versions just to be safe.

Has some one else had this problem?

Marcus Müller
  • 34,677
  • 4
  • 53
  • 94

3 Answers3

1

You are getting this error as

from PyQt4.Qwt5.anynumpy import * 

in polezero_plot.py (/usr/lib/python2.7/site-packages/gnuradio/filter) is failing.

Just try replacing

from PyQt4.Qwt5.anynumpy import * ( line no 25) 

with

from scipy import zeros 

or

from numpy import zeros
Ndech
  • 965
  • 10
  • 21
  • Very quick fix, there has to be some sort of down side or why would line 25 be just directly importing scipy or numpy? – thewyliestcoyote Oct 14 '14 at 21:46
  • You might also want to change dtype definitions wherever zeros(...,Float) are used. May be by importing `import numpy.float as Float` or by replacing "Float" directly. These are important if you are going to manually move poles and zeros in the plot. I suspect this is some Qwt version issue, as the code is not able to import from anynumpy. – Sreeraj Rajendran Oct 17 '14 at 09:37
0

If you have a recent version of NumPy installed, you're most likely running into problems because of this line in anynumpy:

from numpy.oldnumeric.compat import *

oldnumeric provided backwards-compatibility support for code written using NumPy's predecessor Numeric, and was removed in NumPy 1.9 which was released at about the time of your question. It looks like the GNU Radio filter design tool simply isn't compatible with NumPy 1.9 right now.

makomk
  • 151
  • 3
0

I ran into a similar issue just now, and had to import fftpack from SciPy instead of NumPy. NumPy was still needed for actually generating the filters (removing import numpy would cause gr_filter_design to crash when clicking the "Design" button).

/usr/lib/python3.8/site-packages/gnuradio/filter/filter_design.py:

#    import numpy
#    from numpy.fft import fftpack
#    from scipy import poly1d, signal

    import numpy
    from scipy import fftpack, poly1d, signal

Versions: Manjaro Linux, numpy 1.18.1, scipy 1.4.1, and gnuradio 3.8.0.0.

remcycles
  • 1,246
  • 13
  • 14