[SciPy-dev] weave

Arnd Baecker arnd.baecker at web.de
Fri Jun 9 05:36:21 CDT 2006


for some reason one of our code, which should have
been fully converted to numpy, lead to the inclusion of Numeric
in sys.modules.

We tracked this down to the following minimal example
  from weave import inline
  import sys
  print sys.modules["Numeric"]

In the end this is caused by
which does an
  import weave
at the beginning.
When both new scipy and old scipy (at a different place)
are installed, the above line fetches the weave from old
scipy and therefore a bunch of Numeric stuff.
It seems that a
  from scipy.weave import weave
in scipy/weave/accelerate_tools.py
fixes the problem.

I could commit the change, but before that I would like
to make sure that I am not messing up anything with the above change.

Any comments?

Best, Arnd

P.S.: In case you wonder why a non-existing weave does not
not lead an error: the reason is that in scipy/weave/__init__.py
the construct

    from accelerate_tools import accelerate

is used.

More information about the Scipy-dev mailing list