Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit e706c7d

Browse files
committed
Changed all references to scipy to numpy
1 parent c14d4fe commit e706c7d

130 files changed

Lines changed: 1009 additions & 1009 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

COMPATIBILITY

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ using PyMemData_FREE(ptr) or PyMemData_XFREE(ptr);
3131
a->descr->zero --> PyArray_Zero(a)
3232
a->descr->one --> PyArray_One(a)
3333

34-
Numeric/arrayobject.h --> scipy/arrayobject.h
34+
Numeric/arrayobject.h --> numpy/arrayobject.h
3535

3636

3737
# These will actually work and are defines for PyArray_BYTE,

README.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,5 +10,5 @@ If fast BLAS and LAPACK cannot be found, then a slower default version is used.
1010

1111
The current version is always available from a Subversion repostiory:
1212

13-
http://svn.scipy.org/svn/scipy_core/trunk
13+
http://svn.numpy.org/svn/numpy_core/trunk
1414

THANKS.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ Eric Jones for weave and other sundry subroutines
1010
Fernando Perez for code snippets, ideas, bufixes, and testing.
1111
John Hunter for code snippets (from matplotlib)
1212
Chris Hanley for help with records.py, testing, and bug fixes.
13-
Travis Vaught and Joe Cooper for administration of scipy.org web site and SVN
13+
Travis Vaught and Joe Cooper for administration of numpy.org web site and SVN
1414
Eric Firing for bugfixes.
1515
Arnd Baecker for 64-bit testing
1616
David Cooke for many code improvements including the auto-generated C-API

benchmarks/sorting.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
N = 10000
44
t1 = timeit.Timer('a=array(None,shape=%d);a.sort()'%N,'from numarray import array')
5-
t2 = timeit.Timer('a=empty(shape=%d);a.sort()'%N,'from scipy import empty')
5+
t2 = timeit.Timer('a=empty(shape=%d);a.sort()'%N,'from numpy import empty')
66
t3 = timeit.Timer('a=empty(shape=%d);sort(a)'%N,'from Numeric import empty,sort')
77

88
print "1-D length = ", N
@@ -12,7 +12,7 @@
1212

1313
N1,N2 = 100,100
1414
t1 = timeit.Timer('a=array(None,shape=(%d,%d));a.sort()'%(N1,N2),'from numarray import array')
15-
t2 = timeit.Timer('a=empty(shape=(%d,%d));a.sort()'%(N1,N2),'from scipy import empty')
15+
t2 = timeit.Timer('a=empty(shape=(%d,%d));a.sort()'%(N1,N2),'from numpy import empty')
1616
t3 = timeit.Timer('a=empty(shape=(%d,%d));sort(a)'%(N1,N2),'from Numeric import empty,sort')
1717

1818
print "2-D shape = (%d,%d), last-axis" % (N1,N2)
@@ -22,7 +22,7 @@
2222

2323
N1,N2 = 100,100
2424
t1 = timeit.Timer('a=array(None,shape=(%d,%d));a.sort(0)'%(N1,N2),'from numarray import array')
25-
t2 = timeit.Timer('a=empty(shape=(%d,%d));a.sort(0)'%(N1,N2),'from scipy import empty')
25+
t2 = timeit.Timer('a=empty(shape=(%d,%d));a.sort(0)'%(N1,N2),'from numpy import empty')
2626
t3 = timeit.Timer('a=empty(shape=(%d,%d));sort(a,0)'%(N1,N2),'from Numeric import empty,sort')
2727

2828
print "2-D shape = (%d,%d), first-axis" % (N1,N2)

numpy/__init__.py

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -135,33 +135,33 @@ def _get_sorted_names(self):
135135
return package_names
136136

137137
def __call__(self,*packages, **options):
138-
"""Load one or more packages into scipy's top-level namespace.
138+
"""Load one or more packages into numpy's top-level namespace.
139139
140140
Usage:
141141
142-
This function is intended to shorten the need to import many of scipy's
142+
This function is intended to shorten the need to import many of numpy's
143143
submodules constantly with statements such as
144144
145-
import scipy.linalg, scipy.fft, scipy.etc...
145+
import numpy.linalg, numpy.fft, numpy.etc...
146146
147147
Instead, you can say:
148148
149-
import scipy
150-
scipy.pkgload('linalg','fft',...)
149+
import numpy
150+
numpy.pkgload('linalg','fft',...)
151151
152152
or
153153
154-
scipy.pkgload()
154+
numpy.pkgload()
155155
156156
to load all of them in one call.
157157
158-
If a name which doesn't exist in scipy's namespace is
158+
If a name which doesn't exist in numpy's namespace is
159159
given, an exception [[WHAT? ImportError, probably?]] is raised.
160160
[NotImplemented]
161161
162162
Inputs:
163163
164-
- the names (one or more strings) of all the scipy modules one wishes to
164+
- the names (one or more strings) of all the numpy modules one wishes to
165165
load into the top-level namespace.
166166
167167
Optional keyword inputs:
@@ -170,7 +170,7 @@ def __call__(self,*packages, **options):
170170
- force - when True, force reloading loaded packages [default: False].
171171
- postpone - when True, don't load packages [default: False]
172172
173-
If no input arguments are given, then all of scipy's subpackages are
173+
If no input arguments are given, then all of numpy's subpackages are
174174
imported.
175175
176176
@@ -297,18 +297,18 @@ def error(self,mess):
297297
pkgload = PackageLoader()
298298

299299
if show_core_config is None:
300-
print >> sys.stderr, 'Running from scipy core source directory.'
300+
print >> sys.stderr, 'Running from numpy core source directory.'
301301
else:
302302
from core_version import version as __core_version__
303303

304304
pkgload('testing','base','corefft','corelinalg','random',
305305
verbose=SCIPY_IMPORT_VERBOSE)
306306

307307

308-
test = ScipyTest('scipy').test
308+
test = ScipyTest('numpy').test
309309
__all__.append('test')
310310

311-
__scipy_doc__ = """
311+
__numpy_doc__ = """
312312
313313
SciPy: A scientific computing package for Python
314314
================================================
@@ -318,18 +318,18 @@ def error(self,mess):
318318
"""
319319

320320
if NO_SCIPY_IMPORT is not None:
321-
print >> sys.stderr, 'Skip importing scipy packages (NO_SCIPY_IMPORT=%s)' % (NO_SCIPY_IMPORT)
322-
show_scipy_config = None
321+
print >> sys.stderr, 'Skip importing numpy packages (NO_SCIPY_IMPORT=%s)' % (NO_SCIPY_IMPORT)
322+
show_numpy_config = None
323323
elif show_core_config is None:
324-
show_scipy_config = None
324+
show_numpy_config = None
325325
else:
326326
try:
327-
from __scipy_config__ import show as show_scipy_config
327+
from __numpy_config__ import show as show_numpy_config
328328
except ImportError:
329-
show_scipy_config = None
329+
show_numpy_config = None
330330

331331

332-
if show_scipy_config is not None:
333-
from scipy_version import scipy_version as __scipy_version__
334-
__doc__ += __scipy_doc__
332+
if show_numpy_config is not None:
333+
from numpy_version import numpy_version as __numpy_version__
334+
__doc__ += __numpy_doc__
335335
pkgload(verbose=SCIPY_IMPORT_VERBOSE,postpone=True)

numpy/_import_tools.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
class PackageImport:
88
""" Import packages from the current directory that implement
9-
info.py. See scipy/doc/DISTUTILS.txt for more info.
9+
info.py. See numpy/doc/DISTUTILS.txt for more info.
1010
"""
1111

1212
imported_packages = []

numpy/core/__init__.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11

22
from info import __doc__
3-
from scipy.core_version import version as __version__
3+
from numpy.core_version import version as __version__
44

55
import multiarray
66
import umath
@@ -33,5 +33,5 @@
3333

3434
__all__ = filter(lambda s:not s.startswith('_'),dir())
3535

36-
from scipy.testing import ScipyTest
36+
from numpy.testing import ScipyTest
3737
test = ScipyTest().test

numpy/core/arrayprint.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
# last revision: 1996-3-13
1111
# modified by Jim Hugunin 1997-3-3 for repr's and str's (and other details)
1212
# and by Perry Greenfield 2000-4-1 for numarray
13-
# and by Travis Oliphant 2005-8-22 for scipy.base
13+
# and by Travis Oliphant 2005-8-22 for numpy.base
1414

1515
import sys
1616
import numeric as _gen

numpy/core/blasdot/_dotblas.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
static char module_doc[] =
2-
"This module provides a BLAS optimized\nmatrix multiply, inner product and dot for scipy arrays";
2+
"This module provides a BLAS optimized\nmatrix multiply, inner product and dot for numpy arrays";
33

44
#include "Python.h"
5-
#include "scipy/arrayobject.h"
5+
#include "numpy/arrayobject.h"
66
#ifndef CBLAS_HEADER
77
#define CBLAS_HEADER "cblas.h"
88
#endif
@@ -128,7 +128,7 @@ dotblas_restoredot(PyObject *dummy, PyObject *args)
128128
}
129129

130130

131-
static char doc_matrixproduct[] = "matrixproduct(a,b)\nReturns the dot product of a and b for arrays of floating point types.\nLike the generic scipy equivalent the product sum is over\nthe last dimension of a and the second-to-last dimension of b.\nNB: The first argument is not conjugated.";
131+
static char doc_matrixproduct[] = "matrixproduct(a,b)\nReturns the dot product of a and b for arrays of floating point types.\nLike the generic numpy equivalent the product sum is over\nthe last dimension of a and the second-to-last dimension of b.\nNB: The first argument is not conjugated.";
132132

133133
static PyObject *
134134
dotblas_matrixproduct(PyObject *dummy, PyObject *args)

numpy/core/code_generators/array_api_order.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# The functions in the scipy_core C API
1+
# The functions in the numpy_core C API
22
# They are defined here so that the order is set.
33
PyArray_SetNumericOps
44
PyArray_GetNumericOps

0 commit comments

Comments
 (0)