[SciPy-dev] ANN: NumPy/SciPy Documentation Marathon 2008

Stéfan van der Walt stefan@sun.ac...
Sun May 18 11:12:58 CDT 2008


2008/5/18 Matthew Brett <matthew.brett@gmail.com>:
> Hi,
>
>> 1) Assume 'from numpy import *'
>> 2) Assume 'import numpy'
>> 3) Assume 'import numpy as np'
>
> Strong vote against 1), for 3).  I think we'll end up just having to
> retrain people out of import * later, as did wx and others.

I'm also not in favour of 1; we don't want to encourage people to do
"from numpy import *" -- ever.  The argument against 3 is that many
(some?) people use different shorthand forms for numpy.  If we simply
rely on 'numpy' being called 'numpy', no one gets confused.  Even so,
I'd be ok with either 'numpy' or 'np' ('np' has the additional [and
maybe obvious] advantage of being a lot shorter).

Regards
Stéfan


More information about the Scipy-dev mailing list