[Scipy-svn] r3778 - in branches/testing_cleanup/scipy/sandbox: arpack/tests buildgrid cdavid/tests constants delaunay/tests fdfpack/tests lobpcg/tests maskedarray maskedarray/tests montecarlo/tests numexpr numexpr/tests pyloess pyloess/tests rbf/tests spline/tests timeseries timeseries/lib timeseries/tests

scipy-svn@scip... scipy-svn@scip...
Thu Jan 3 19:30:20 CST 2008


Author: matthew.brett@gmail.com
Date: 2008-01-03 19:29:56 -0600 (Thu, 03 Jan 2008)
New Revision: 3778

Modified:
   branches/testing_cleanup/scipy/sandbox/arpack/tests/test_speigs.py
   branches/testing_cleanup/scipy/sandbox/buildgrid/test_build_grid.py
   branches/testing_cleanup/scipy/sandbox/cdavid/tests/test_autocorr.py
   branches/testing_cleanup/scipy/sandbox/cdavid/tests/test_lpc.py
   branches/testing_cleanup/scipy/sandbox/cdavid/tests/test_segmentaxis.py
   branches/testing_cleanup/scipy/sandbox/constants/constants.py
   branches/testing_cleanup/scipy/sandbox/delaunay/tests/test_triangulate.py
   branches/testing_cleanup/scipy/sandbox/fdfpack/tests/test_fdf.py
   branches/testing_cleanup/scipy/sandbox/lobpcg/tests/large_scale.py
   branches/testing_cleanup/scipy/sandbox/lobpcg/tests/test_lobpcg.py
   branches/testing_cleanup/scipy/sandbox/maskedarray/extras.py
   branches/testing_cleanup/scipy/sandbox/maskedarray/morestats.py
   branches/testing_cleanup/scipy/sandbox/maskedarray/mrecords.py
   branches/testing_cleanup/scipy/sandbox/maskedarray/mstats.py
   branches/testing_cleanup/scipy/sandbox/maskedarray/tests/test_core.py
   branches/testing_cleanup/scipy/sandbox/maskedarray/tests/test_extras.py
   branches/testing_cleanup/scipy/sandbox/maskedarray/tests/test_morestats.py
   branches/testing_cleanup/scipy/sandbox/maskedarray/tests/test_mrecords.py
   branches/testing_cleanup/scipy/sandbox/maskedarray/tests/test_mstats.py
   branches/testing_cleanup/scipy/sandbox/maskedarray/tests/test_subclassing.py
   branches/testing_cleanup/scipy/sandbox/montecarlo/tests/test_dictsampler.py
   branches/testing_cleanup/scipy/sandbox/montecarlo/tests/test_intsampler.py
   branches/testing_cleanup/scipy/sandbox/numexpr/__init__.py
   branches/testing_cleanup/scipy/sandbox/numexpr/compiler.py
   branches/testing_cleanup/scipy/sandbox/numexpr/expressions.py
   branches/testing_cleanup/scipy/sandbox/numexpr/tests/test_numexpr.py
   branches/testing_cleanup/scipy/sandbox/pyloess/mpyloess.py
   branches/testing_cleanup/scipy/sandbox/pyloess/tests/test_mpyloess.py
   branches/testing_cleanup/scipy/sandbox/pyloess/tests/test_pyloess.py
   branches/testing_cleanup/scipy/sandbox/rbf/tests/test_rbf.py
   branches/testing_cleanup/scipy/sandbox/spline/tests/test_fitpack.py
   branches/testing_cleanup/scipy/sandbox/spline/tests/test_spline.py
   branches/testing_cleanup/scipy/sandbox/timeseries/dates.py
   branches/testing_cleanup/scipy/sandbox/timeseries/extras.py
   branches/testing_cleanup/scipy/sandbox/timeseries/lib/filters.py
   branches/testing_cleanup/scipy/sandbox/timeseries/lib/interpolate.py
   branches/testing_cleanup/scipy/sandbox/timeseries/lib/moving_funcs.py
   branches/testing_cleanup/scipy/sandbox/timeseries/report.py
   branches/testing_cleanup/scipy/sandbox/timeseries/tests/test_dates.py
   branches/testing_cleanup/scipy/sandbox/timeseries/tests/test_extras.py
   branches/testing_cleanup/scipy/sandbox/timeseries/tests/test_timeseries.py
   branches/testing_cleanup/scipy/sandbox/timeseries/tests/test_trecords.py
   branches/testing_cleanup/scipy/sandbox/timeseries/trecords.py
   branches/testing_cleanup/scipy/sandbox/timeseries/tseries.py
Log:
Sandbox tests nose compatible as far as they are runnable

Modified: branches/testing_cleanup/scipy/sandbox/arpack/tests/test_speigs.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/arpack/tests/test_speigs.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/arpack/tests/test_speigs.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -1,11 +1,9 @@
 #!/usr/bin/env python
 
-import sys
 from scipy.testing import *
 
-from arpack.speigs import *
+from scipy.sandbox.arpack.speigs import *
 
-
 import numpy as N
 
 class TestEigs(TestCase):
@@ -30,7 +28,7 @@
         nev=4
         eigvs = ARPACK_eigs(matvec, A.shape[0], nev=nev)
         calc_vals = eigvs[0]
-        # Ensure the calculate eigenvectors have the same sign as the refence values
+        # Ensure the calculated eigenvectors have the same sign as the reference values
         calc_vecs = eigvs[1] / [N.sign(x[0]) for x in eigvs[1].T]
         assert_array_almost_equal(calc_vals, vals[0:nev], decimal=7)
         assert_array_almost_equal(calc_vecs,  N.array(vecs)[:,0:nev], decimal=7)

Modified: branches/testing_cleanup/scipy/sandbox/buildgrid/test_build_grid.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/buildgrid/test_build_grid.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/buildgrid/test_build_grid.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -1,183 +1,184 @@
-
-""" Tests for BuildGrid.c module.
-To view the grids I used QuikGrid from
-http://www.PerspectiveEdge.com 
-"""
-
-import sys,math,random,time
-random.seed(7)
-
-global ncol,nrow,step,xmin,ymin,simple
-xmin,ymin,step = 0.0,0.0,1.0 
-
-# Surface model:
-simple = True   #  simple: (a1+b1*x)*(a2+b2*y)
-                # This is almost a plain.
-
-simple = False  # !simple: cos(a*x*x)*cos(b*y*y)
-                # In this case only left bottom part of surface
-                # should be believable.
-
-def gridsizes(nodes,ratio=1.0):
-    # ratio = ncol/nrow
-    nodes = max(100,nodes)
-    ratio = max(0.1,min(ratio,10.0))
-    nrow = int(math.sqrt(nodes/ratio))
-    ncol = nodes/nrow+1
-    return ncol,nrow
-
-ncol,nrow = gridsizes(10**5) # I used 10**3 - 10**7 nodes
-
-ax,ay = math.pi/(4*ncol+1),math.pi/(4*nrow+1)
-
-percent = 10.2 # how many data points w.r.t. grid nodes:
-datapoints = int(0.01 * percent * ncol * nrow) or 5
-print "Testing",("complex","simple")[simple],
-print "surface. Grid size %d x %d (%d nodes)" % (ncol,nrow,ncol*nrow)
-print "About %d datapoints (%.2f%% of nodes)" % (datapoints,percent)
-
-# Test flag
-build_only = True  #  no output to files
-build_only = False #  output to files
-
-# Trimming distance
-trimdist = 5*step  # make trimming
-trimdist = 0.0     # do not make trimming
-if trimdist < step:
-    print "No trimming"
-else:
-    print "With trimming",trimdist
-
-def surface(x,y):
-    if simple:
-        return 100+100*(1+float(x)/ncol)*(1+float(y)/nrow)
-    return 100+50*(math.cos(ax*x*x)*math.cos(ay*y*y)+1)
-    
-def surfaceGen():
-    while True:
-        if trimdist < step:
-            x = random.uniform(-1,ncol) # some points may be 
-            y = random.uniform(-1,nrow) # out of grid
-        else:
-            trdist = int(trimdist/step+0.5)
-            x = random.uniform(-1+trdist,ncol-trdist) # all the points 
-            y = random.uniform(-1+trdist,nrow-trdist) # are inside the grid
-        z = surface(x,y)
-        yield x,y,z
-
-def makeInputXYZ(outfile,nvals):
-    surgen = surfaceGen()
-    x,y,z = [],[],[]
-    fo = open(outfile,"wt") # for fromfile()
-    while(nvals > 0):
-        xv,yv,zv = surgen.next()
-        fo.write("%.3f %.3f %.3f\n" % (xv,yv,zv))
-        x.append(xv) # for fromxyz()
-        y.append(yv)
-        z.append(zv)
-        nvals -= 1
-    fo.close()
-    return x,y,z
-
-# create input data file with
-xyzfile = "inpdata.xyz" # input for fromfile()
-xp,yp,zp = makeInputXYZ(xyzfile, datapoints)
-
-
-import BuildGrid
-
-# get file statistics
-nvals,xmin,xmax,ymin,ymax,zmin,zmax,zavrg,zstnd = \
-    BuildGrid.filestatistics(xyzfile)
-print xyzfile,'statistics.  Number of values',nvals
-print 'X min %9.1f   max %9.1f' % (xmin,xmax)
-print 'Y min %9.1f   max %9.1f' % (ymin,ymax)
-print 'S min %9.1f   max %9.1f' % (zmin,zmax)
-print 'S avrg %7.2f   stnd %7.3f' % (zavrg,zstnd)
-
-# build grid 'fromfile'
-t0 = time.clock()
-grid = BuildGrid.fromfile(xyzfile=xyzfile,
-    nx=ncol, ny=nrow, step=step, xmin=xmin, ymin=ymin, 
-    method='Good',      # or 'Best' - not implemented
-    trimming=trimdist,  # if no trimming - full grid
-    unvalue=123.321,    # will be used if trimming > 0
-    abserror=0.001,     # may be == 0
-    relerror=0.0001)    # ignores if abserror > 0
-print 'fromfile():',xyzfile,len(grid)-ncol*nrow,"(%.2f sec, %.0f nodes/sec)" %\
-    (time.clock()-t0,ncol*nrow/(time.clock()-t0))
-
-
-# put grid data to xyz file
-if not build_only:
-    outfile = "outdata1.xyz"
-    t0 = time.clock()
-    rv = BuildGrid.tofile(filename=outfile, griddata=grid, gridtype='xyz',
-        nx=ncol, ny=nrow, step=step, xmin=xmin, ymin=ymin, unvalue=1234.4321)
-    print 'tofile():',outfile,rv,"(%.2f sec)" % (time.clock()-t0)
-
-
-# build grid from xyz lists
-t0 = time.clock()
-grid2 = BuildGrid.fromxyz(xdata=xp,ydata=yp,zdata=zp,
-    nx=ncol, ny=nrow, step=step, xmin=xmin, ymin=ymin, 
-    method='Good',      # or 'Best' (not implemented)
-    trimming=trimdist,  # if no trimming - full grid
-    unvalue=123.321,    # will be used if trimming > 0
-    abserror=0.001,     # may be == 0
-    relerror=0.0001)    # ignores if abserror > 0
-print 'fromxyz():',len(grid)-ncol*nrow,"(%.2f sec, %.0f nodes/sec)" %\
-    (time.clock()-t0,ncol*nrow/(time.clock()-t0))
-
-# put grid to file
-if not build_only:
-    outfile = "outdata2.xyz"
-    t0 = time.clock()
-    rv = BuildGrid.tofile(filename=outfile, griddata=grid2, gridtype='xyz',
-        nx=ncol, ny=nrow, step=step, xmin=xmin, ymin=ymin, unvalue=1234.4321)
-    print 'tofile():',outfile,rv,"(%.2f sec)" % (time.clock()-t0)
-
-
-# write full exact grid
-if not build_only:
-    exactfile = "exactdata.xyz"
-    t0 = time.clock()
-    fo = open(exactfile,"wt")
-    for nr in xrange(nrow):
-        for nc in xrange(ncol):
-            fo.write("%.2f %.2f %.3f\n" % (nc,nr,surface(nc,nr)))
-    fo.close()
-    print 'exact file:',exactfile,"(%.2f sec)" % (time.clock()-t0)
-
-
-if build_only:
-    sys.exit()
-
-# Compare Input & Output:
-layer = max(5,min(ncol,nrow)/10)
-def avst(left,rite,low,top):
-    av = st = 0.0
-    nv = 0
-    for nr in xrange(low,top):
-        for nc in xrange(left,rite):
-            d = grid[nr*ncol+nc]-surface(nc,nr)
-            av += d
-            st += d*d
-            nv += 1
-    av /= nv
-    st = st/nv-av*av
-    if st > 0.0: st = math.sqrt(st)
-    return av,st
-
-print "Comparing %d x %d squares" % (layer,layer),"of grid lines"
-av,st = avst(0,layer,0,layer)
-print "Bottom Left:   av = %8.3f  st = %8.3f" % (av,st)
-av,st = avst(ncol-layer,ncol,0,layer)
-print "Bottom Right:  av = %8.3f  st = %8.3f" % (av,st)
-av,st = avst(0,layer,nrow-layer,nrow)
-print "Top Left:      av = %8.3f  st = %8.3f" % (av,st)
-av,st = avst(ncol-layer,ncol,nrow-layer,nrow)
-print "Top Right:     av = %8.3f  st = %8.3f" % (av,st)
-av,st = avst(ncol/2-layer/2,ncol/2+layer/2,nrow/2-layer/2,nrow/2+layer/2)
-print "Middle:        av = %8.3f  st = %8.3f" % (av,st)
-    
+
+""" Tests for BuildGrid.c module.
+To view the grids I used QuikGrid from
+http://www.PerspectiveEdge.com 
+"""
+
+import sys,math,random,time
+from scipy.sandbox import buildgrid
+
+random.seed(7)
+
+global ncol,nrow,step,xmin,ymin,simple
+xmin,ymin,step = 0.0,0.0,1.0 
+
+# Surface model:
+simple = True   #  simple: (a1+b1*x)*(a2+b2*y)
+                # This is almost a plain.
+
+simple = False  # !simple: cos(a*x*x)*cos(b*y*y)
+                # In this case only left bottom part of surface
+                # should be believable.
+
+def gridsizes(nodes,ratio=1.0):
+    # ratio = ncol/nrow
+    nodes = max(100,nodes)
+    ratio = max(0.1,min(ratio,10.0))
+    nrow = int(math.sqrt(nodes/ratio))
+    ncol = nodes/nrow+1
+    return ncol,nrow
+
+ncol,nrow = gridsizes(10**5) # I used 10**3 - 10**7 nodes
+
+ax,ay = math.pi/(4*ncol+1),math.pi/(4*nrow+1)
+
+percent = 10.2 # how many data points w.r.t. grid nodes:
+datapoints = int(0.01 * percent * ncol * nrow) or 5
+print "Testing",("complex","simple")[simple],
+print "surface. Grid size %d x %d (%d nodes)" % (ncol,nrow,ncol*nrow)
+print "About %d datapoints (%.2f%% of nodes)" % (datapoints,percent)
+
+# Test flag
+build_only = True  #  no output to files
+build_only = False #  output to files
+
+# Trimming distance
+trimdist = 5*step  # make trimming
+trimdist = 0.0     # do not make trimming
+if trimdist < step:
+    print "No trimming"
+else:
+    print "With trimming",trimdist
+
+def surface(x,y):
+    if simple:
+        return 100+100*(1+float(x)/ncol)*(1+float(y)/nrow)
+    return 100+50*(math.cos(ax*x*x)*math.cos(ay*y*y)+1)
+    
+def surfaceGen():
+    while True:
+        if trimdist < step:
+            x = random.uniform(-1,ncol) # some points may be 
+            y = random.uniform(-1,nrow) # out of grid
+        else:
+            trdist = int(trimdist/step+0.5)
+            x = random.uniform(-1+trdist,ncol-trdist) # all the points 
+            y = random.uniform(-1+trdist,nrow-trdist) # are inside the grid
+        z = surface(x,y)
+        yield x,y,z
+
+def makeInputXYZ(outfile,nvals):
+    surgen = surfaceGen()
+    x,y,z = [],[],[]
+    fo = open(outfile,"wt") # for fromfile()
+    while(nvals > 0):
+        xv,yv,zv = surgen.next()
+        fo.write("%.3f %.3f %.3f\n" % (xv,yv,zv))
+        x.append(xv) # for fromxyz()
+        y.append(yv)
+        z.append(zv)
+        nvals -= 1
+    fo.close()
+    return x,y,z
+
+# create input data file with
+xyzfile = "inpdata.xyz" # input for fromfile()
+xp,yp,zp = makeInputXYZ(xyzfile, datapoints)
+
+
+
+# get file statistics
+nvals,xmin,xmax,ymin,ymax,zmin,zmax,zavrg,zstnd = \
+    buildgrid.filestatistics(xyzfile)
+print xyzfile,'statistics.  Number of values',nvals
+print 'X min %9.1f   max %9.1f' % (xmin,xmax)
+print 'Y min %9.1f   max %9.1f' % (ymin,ymax)
+print 'S min %9.1f   max %9.1f' % (zmin,zmax)
+print 'S avrg %7.2f   stnd %7.3f' % (zavrg,zstnd)
+
+# build grid 'fromfile'
+t0 = time.clock()
+grid = buildgrid.fromfile(xyzfile=xyzfile,
+    nx=ncol, ny=nrow, step=step, xmin=xmin, ymin=ymin, 
+    method='Good',      # or 'Best' - not implemented
+    trimming=trimdist,  # if no trimming - full grid
+    unvalue=123.321,    # will be used if trimming > 0
+    abserror=0.001,     # may be == 0
+    relerror=0.0001)    # ignores if abserror > 0
+print 'fromfile():',xyzfile,len(grid)-ncol*nrow,"(%.2f sec, %.0f nodes/sec)" %\
+    (time.clock()-t0,ncol*nrow/(time.clock()-t0))
+
+
+# put grid data to xyz file
+if not build_only:
+    outfile = "outdata1.xyz"
+    t0 = time.clock()
+    rv = buildgrid.tofile(filename=outfile, griddata=grid, gridtype='xyz',
+        nx=ncol, ny=nrow, step=step, xmin=xmin, ymin=ymin, unvalue=1234.4321)
+    print 'tofile():',outfile,rv,"(%.2f sec)" % (time.clock()-t0)
+
+
+# build grid from xyz lists
+t0 = time.clock()
+grid2 = buildgrid.fromxyz(xdata=xp,ydata=yp,zdata=zp,
+    nx=ncol, ny=nrow, step=step, xmin=xmin, ymin=ymin, 
+    method='Good',      # or 'Best' (not implemented)
+    trimming=trimdist,  # if no trimming - full grid
+    unvalue=123.321,    # will be used if trimming > 0
+    abserror=0.001,     # may be == 0
+    relerror=0.0001)    # ignores if abserror > 0
+print 'fromxyz():',len(grid)-ncol*nrow,"(%.2f sec, %.0f nodes/sec)" %\
+    (time.clock()-t0,ncol*nrow/(time.clock()-t0))
+
+# put grid to file
+if not build_only:
+    outfile = "outdata2.xyz"
+    t0 = time.clock()
+    rv = buildgrid.tofile(filename=outfile, griddata=grid2, gridtype='xyz',
+        nx=ncol, ny=nrow, step=step, xmin=xmin, ymin=ymin, unvalue=1234.4321)
+    print 'tofile():',outfile,rv,"(%.2f sec)" % (time.clock()-t0)
+
+
+# write full exact grid
+if not build_only:
+    exactfile = "exactdata.xyz"
+    t0 = time.clock()
+    fo = open(exactfile,"wt")
+    for nr in xrange(nrow):
+        for nc in xrange(ncol):
+            fo.write("%.2f %.2f %.3f\n" % (nc,nr,surface(nc,nr)))
+    fo.close()
+    print 'exact file:',exactfile,"(%.2f sec)" % (time.clock()-t0)
+
+
+if build_only:
+    sys.exit()
+
+# Compare Input & Output:
+layer = max(5,min(ncol,nrow)/10)
+def avst(left,rite,low,top):
+    av = st = 0.0
+    nv = 0
+    for nr in xrange(low,top):
+        for nc in xrange(left,rite):
+            d = grid[nr*ncol+nc]-surface(nc,nr)
+            av += d
+            st += d*d
+            nv += 1
+    av /= nv
+    st = st/nv-av*av
+    if st > 0.0: st = math.sqrt(st)
+    return av,st
+
+print "Comparing %d x %d squares" % (layer,layer),"of grid lines"
+av,st = avst(0,layer,0,layer)
+print "Bottom Left:   av = %8.3f  st = %8.3f" % (av,st)
+av,st = avst(ncol-layer,ncol,0,layer)
+print "Bottom Right:  av = %8.3f  st = %8.3f" % (av,st)
+av,st = avst(0,layer,nrow-layer,nrow)
+print "Top Left:      av = %8.3f  st = %8.3f" % (av,st)
+av,st = avst(ncol-layer,ncol,nrow-layer,nrow)
+print "Top Right:     av = %8.3f  st = %8.3f" % (av,st)
+av,st = avst(ncol/2-layer/2,ncol/2+layer/2,nrow/2-layer/2,nrow/2+layer/2)
+print "Middle:        av = %8.3f  st = %8.3f" % (av,st)
+    

Modified: branches/testing_cleanup/scipy/sandbox/cdavid/tests/test_autocorr.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/cdavid/tests/test_autocorr.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/cdavid/tests/test_autocorr.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -9,13 +9,12 @@
 from numpy.ctypeslib import ndpointer, load_library
 from ctypes import c_uint
 
+from scipy.sandbox.cdavid.autocorr import _raw_autocorr_1d, \
+     _raw_autocorr_1d_noncontiguous, \
+     autocorr_oneside_nofft as autocorr,\
+     autocorr_fft , nextpow2, \
+     _autocorr_oneside_nofft_py as autocorr_py
 
-from cdavid.autocorr import _raw_autocorr_1d, _raw_autocorr_1d_noncontiguous
-from cdavid.autocorr import autocorr_oneside_nofft as autocorr
-from cdavid.autocorr import autocorr_fft , nextpow2
-from cdavid.autocorr import _autocorr_oneside_nofft_py as autocorr_py
-
-
 import numpy
 
 # number of decimals to check

Modified: branches/testing_cleanup/scipy/sandbox/cdavid/tests/test_lpc.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/cdavid/tests/test_lpc.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/cdavid/tests/test_lpc.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -7,13 +7,9 @@
 
 from numpy.ctypeslib import ndpointer, load_library
 from ctypes import c_uint
+from scipy.sandbox.cdavid.lpc import _lpc2_py as lpc_py, \
+     lpc_ref, lpc2, autocorr_oneside_nofft
 
-
-from cdavid.lpc import _lpc2_py as lpc_py
-from cdavid.lpc import lpc_ref, lpc2
-from cdavid.autocorr import autocorr_oneside_nofft
-
-
 import numpy
 
 # number of decimals to check

Modified: branches/testing_cleanup/scipy/sandbox/cdavid/tests/test_segmentaxis.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/cdavid/tests/test_segmentaxis.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/cdavid/tests/test_segmentaxis.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -6,7 +6,7 @@
 import numpy as N
 
 
-from cdavid.segmentaxis import segment_axis
+from scipy.sandbox.cdavid.segmentaxis import segment_axis
 
 
 # #Optional:

Modified: branches/testing_cleanup/scipy/sandbox/constants/constants.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/constants/constants.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/constants/constants.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -12,7 +12,7 @@
 physical constants: imported from CODATA
 unit conversion: see e.g. NIST special publication 811
 Use at own risk: double-check values before calculating your Mars orbit-insertion burn.
-Some constants exist in a few variants, which are marked with sufixes.
+Some constants exist in a few variants, which are marked with suffixes.
 The ones without any suffix should be the most common one.
 """
 

Modified: branches/testing_cleanup/scipy/sandbox/delaunay/tests/test_triangulate.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/delaunay/tests/test_triangulate.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/delaunay/tests/test_triangulate.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -1,6 +1,7 @@
 from scipy.sandbox import delaunay as dlny
 from numpy import random
 import scipy as sp
+from scipy.testing import *
 
 def onright(x0, y0, x1, y1, x, y):
     """Return True if (x,y) is to the right of the vector from (x0,y0) to
@@ -16,12 +17,11 @@
     assert r2 < r
 
 
-class TestSanity(object):
-    def setup_method(self, method):
+class TestSanity(TestCase):
+    def setUp(self):
         self.rs = random.RandomState(1234567890)
 
     def test_counts(self):
-        assert False
         for n in (10, 30, 100, 300, 1000, 3000):
             x, y = self.rs.uniform(0, 100, size=(2, n))
             tri = dlny.Triangulation(x, y)
@@ -35,7 +35,6 @@
             assert sp.sum((tri.triangle_neighbors == -1).astype(sp.int32).flat) == k
 
     def test_ccw_triangles(self):
-        assert False
         for n in (10, 30, 100, 300, 1000, 3000):
             x, y = self.rs.uniform(0, 100, size=(2, n))
             tri = dlny.Triangulation(x, y)
@@ -44,7 +43,6 @@
                 assert not onright(x[i], y[i], x[j], y[j], x[k], y[k])
 
     def test_ccw_hull(self):
-        assert False
         for n in (10, 30, 100, 300, 1000, 3000):
             x, y = self.rs.uniform(0, 100, size=(2, n))
             tri = dlny.Triangulation(x, y)
@@ -57,7 +55,6 @@
                 assert not onright(x[i], y[i], x[j], y[j], x[k], y[k])
 
     def test_circle_condition(self):
-        assert False
         for n in (10, 30, 100, 300, 1000, 3000):
             x, y = self.rs.uniform(0, 100, size=(2, n))
             tri = dlny.Triangulation(x, y)
@@ -68,3 +65,8 @@
             alldist2 = (sp.subtract.outer(x, tri.circumcenters[:,0])**2
                       + sp.subtract.outer(y, tri.circumcenters[:,1])**2)
             assert sp.alltrue(r2 <= alldist2)
+
+
+if __name__ == '__main__':
+    unittest.main()
+    

Modified: branches/testing_cleanup/scipy/sandbox/fdfpack/tests/test_fdf.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/fdfpack/tests/test_fdf.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/fdfpack/tests/test_fdf.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -1,8 +1,7 @@
 
-
 from scipy.testing import *
 
-from fdfpack import periodic_finite_difference as diff
+from scipy.sandbox.fdfpack import periodic_finite_difference as diff
 
 
 from numpy import arange, add, array,sin,cos,pi

Modified: branches/testing_cleanup/scipy/sandbox/lobpcg/tests/large_scale.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/lobpcg/tests/large_scale.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/lobpcg/tests/large_scale.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -1,4 +1,5 @@
-from scipy import *
+from scipy import array, arange, ones, sort, cos, pi, rand, \
+     set_printoptions, r_
 from scipy.sandbox import lobpcg
 from scipy.sparse import spdiags, speye
 from pylab import loglog, show, xlabel, ylabel, title

Modified: branches/testing_cleanup/scipy/sandbox/lobpcg/tests/test_lobpcg.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/lobpcg/tests/test_lobpcg.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/lobpcg/tests/test_lobpcg.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -1,4 +1,5 @@
-from scipy import *
+from scipy import array, arange, ones, sort, cos, pi, rand, \
+     set_printoptions, r_, diag, linalg
 from scipy.sandbox import lobpcg
 from symeig import symeig
 from pylab import plot, show, legend, xlabel, ylabel

Modified: branches/testing_cleanup/scipy/sandbox/maskedarray/extras.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/maskedarray/extras.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/maskedarray/extras.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -35,7 +35,7 @@
 from numpy.core.numeric import array as nxarray
 from numpy.core.fromnumeric import asarray as nxasarray
 
-from numpy.lib.index_tricks import concatenator
+from numpy.lib.index_tricks import AxisConcatenator
 import numpy.lib.function_base as function_base
 
 #...............................................................................
@@ -568,11 +568,11 @@
 #---- --- Concatenation helpers ---
 #####--------------------------------------------------------------------------
 
-class mconcatenator(concatenator):
+class mconcatenator(AxisConcatenator):
     """Translates slice objects to concatenation along an axis."""
 
     def __init__(self, axis=0):
-        concatenator.__init__(self, axis, matrix=False)
+        AxisConcatenator.__init__(self, axis, matrix=False)
 
     def __getitem__(self,key):
         if isinstance(key, str):

Modified: branches/testing_cleanup/scipy/sandbox/maskedarray/morestats.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/maskedarray/morestats.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/maskedarray/morestats.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -21,10 +21,10 @@
 import numpy.core.numeric as numeric
 from numpy.core.numeric import concatenate
 
-import maskedarray as MA
-from maskedarray.core import masked, nomask, MaskedArray, masked_array
-from maskedarray.extras import apply_along_axis, dot
-from maskedarray.mstats import trim_both, trimmed_stde, mquantiles, mmedian, stde_median
+import scipy.sandbox.maskedarray as MA
+from scipy.sandbox.maskedarray.core import masked, nomask, MaskedArray, masked_array
+from scipy.sandbox.maskedarray.extras import apply_along_axis, dot
+from scipy.sandbox.maskedarray.mstats import trim_both, trimmed_stde, mquantiles, mmedian, stde_median
 
 from scipy.stats.distributions import norm, beta, t, binom
 from scipy.stats.morestats import find_repeats

Modified: branches/testing_cleanup/scipy/sandbox/maskedarray/mrecords.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/maskedarray/mrecords.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/maskedarray/mrecords.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -28,10 +28,10 @@
 _byteorderconv = numpy.core.records._byteorderconv
 _typestr = ntypes._typestr
 
-import maskedarray
-from maskedarray import MaskedArray, masked, nomask, masked_array,\
+import scipy.sandbox.maskedarray
+from scipy.sandbox.maskedarray import MaskedArray, masked, nomask, masked_array,\
     make_mask, mask_or, getmask, getmaskarray, filled
-from maskedarray.core import default_fill_value, masked_print_option
+from scipy.sandbox.maskedarray.core import default_fill_value, masked_print_option
 
 import warnings
 

Modified: branches/testing_cleanup/scipy/sandbox/maskedarray/mstats.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/maskedarray/mstats.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/maskedarray/mstats.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -19,9 +19,9 @@
 import numpy.core.numeric as numeric
 from numpy.core.numeric import concatenate
 
-import maskedarray
-from maskedarray.core import masked, nomask, MaskedArray, masked_array
-from maskedarray.extras import apply_along_axis, dot
+import scipy.sandbox.maskedarray
+from scipy.sandbox.maskedarray.core import masked, nomask, MaskedArray, masked_array
+from scipy.sandbox.maskedarray.extras import apply_along_axis, dot
 
 __all__ = ['cov','meppf','plotting_positions','meppf','mmedian','mquantiles',
            'stde_median','trim_tail','trim_both','trimmed_mean','trimmed_stde',

Modified: branches/testing_cleanup/scipy/sandbox/maskedarray/tests/test_core.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/maskedarray/tests/test_core.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/maskedarray/tests/test_core.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -14,15 +14,13 @@
 
 import numpy
 import numpy.core.fromnumeric  as fromnumeric
-from scipy.testing import NumpyTest, TestCase
-from scipy.testing.utils import build_err_msg
+from scipy.testing import *
 from numpy import array as narray
 
-import maskedarray.testutils
-from maskedarray.testutils import *
+from scipy.sandbox.maskedarray.testutils import *
 
-import maskedarray.core as coremodule
-from maskedarray.core import *
+import scipy.sandbox.maskedarray.core as coremodule
+from scipy.sandbox.maskedarray.core import *
 
 pi = numpy.pi
 

Modified: branches/testing_cleanup/scipy/sandbox/maskedarray/tests/test_extras.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/maskedarray/tests/test_extras.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/maskedarray/tests/test_extras.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -12,16 +12,13 @@
 __date__     = '$Date$'
 
 import numpy as N
-from scipy.testing import NumpyTest, TestCase
-from scipy.testing.utils import build_err_msg
+from scipy.testing import *
 
-import maskedarray.testutils
-from maskedarray.testutils import *
+import scipy.sandbox.maskedarray.testutils
+from scipy.sandbox.maskedarray.testutils import *
 
-import maskedarray.core
-from maskedarray.core import *
-import maskedarray.extras
-from maskedarray.extras import *
+from scipy.sandbox.maskedarray.core import *
+from scipy.sandbox.maskedarray.extras import *
 
 class TestAverage(TestCase):
     "Several tests of average. Why so many ? Good point..."

Modified: branches/testing_cleanup/scipy/sandbox/maskedarray/tests/test_morestats.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/maskedarray/tests/test_morestats.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/maskedarray/tests/test_morestats.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -11,19 +11,14 @@
 __date__     = '$Date: 2007-10-04 15:31:14 -0400 (Thu, 04 Oct 2007) $'
 
 import numpy
+from scipy.testing import *
+from scipy.sandbox.maskedarray import masked, masked_array
+import scipy.sandbox.maskedarray.mstats
+from scipy.sandbox.maskedarray.mstats import *
+from scipy.sandbox.maskedarray.morestats import *
+from scipy.sandbox.maskedarray.testutils import *
 
-import maskedarray
-from maskedarray import masked, masked_array
 
-import maskedarray.mstats
-from maskedarray.mstats import *
-import maskedarray.morestats
-from maskedarray.morestats import *
-
-import maskedarray.testutils
-from maskedarray.testutils import *
-
-
 class TestMisc(TestCase):
     #
     def __init__(self, *args, **kwargs):

Modified: branches/testing_cleanup/scipy/sandbox/maskedarray/tests/test_mrecords.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/maskedarray/tests/test_mrecords.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/maskedarray/tests/test_mrecords.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -14,19 +14,15 @@
 
 import numpy as N
 import numpy.core.fromnumeric  as fromnumeric
-from scipy.testing import NumpyTest, TestCase
-from scipy.testing.utils import build_err_msg
+from scipy.testing import *
 
-import maskedarray.testutils
-from maskedarray.testutils import *
+from scipy.sandbox.maskedarray.testutils import *
+from scipy.sandbox import maskedarray
+from scipy.sandbox.maskedarray import masked_array, masked, nomask
 
-import maskedarray
-from maskedarray import masked_array, masked, nomask
-
 #import maskedarray.mrecords
 #from maskedarray.mrecords import mrecarray, fromarrays, fromtextfile, fromrecords
-import maskedarray.mrecords
-from maskedarray.mrecords import MaskedRecords, \
+from scipy.sandbox.maskedarray.mrecords import MaskedRecords, \
     fromarrays, fromtextfile, fromrecords, addfield
 
 #..............................................................................

Modified: branches/testing_cleanup/scipy/sandbox/maskedarray/tests/test_mstats.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/maskedarray/tests/test_mstats.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/maskedarray/tests/test_mstats.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -12,14 +12,13 @@
 
 import numpy
 
-import maskedarray
-from maskedarray import masked, masked_array
+from scipy.testing import *
+from scipy.sandbox import maskedarray
+from scipy.sandbox.maskedarray import masked, masked_array
 
-import maskedarray.testutils
-from maskedarray.testutils import *
+from scipy.sandbox.maskedarray.testutils import *
+from scipy.sandbox.maskedarray.mstats import *
 
-from maskedarray.mstats import *
-
 #..............................................................................
 class TestQuantiles(TestCase):
     "Base test class for MaskedArrays."

Modified: branches/testing_cleanup/scipy/sandbox/maskedarray/tests/test_subclassing.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/maskedarray/tests/test_subclassing.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/maskedarray/tests/test_subclassing.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -13,13 +13,12 @@
 import numpy as N
 import numpy.core.numeric as numeric
 
-from scipy.testing import NumpyTest, TestCase
+from scipy.testing import *
 
-import maskedarray.testutils
-from maskedarray.testutils import *
+from scipy.sandbox.maskedarray.testutils import *
 
-import maskedarray.core as coremodule
-from maskedarray.core import *
+import scipy.sandbox.maskedarray.core as coremodule
+from scipy.sandbox.maskedarray.core import *
 
 
 class SubArray(N.ndarray):

Modified: branches/testing_cleanup/scipy/sandbox/montecarlo/tests/test_dictsampler.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/montecarlo/tests/test_dictsampler.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/montecarlo/tests/test_dictsampler.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -12,15 +12,12 @@
 import sys
 from scipy.testing import *
 
-from numpy import *
+from numpy import sum, array, average, sqrt
 #from scipy.montecarlo import *
 from scipy.sandbox.montecarlo import *
 from scipy import stats
 
 
-import unittest
-
-
 class test_dict_sampler(TestCase):
     def test_simple(self):
         """

Modified: branches/testing_cleanup/scipy/sandbox/montecarlo/tests/test_intsampler.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/montecarlo/tests/test_intsampler.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/montecarlo/tests/test_intsampler.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -20,12 +20,10 @@
 import sys
 from scipy.testing import *
 
-from numpy import *
 from scipy.sandbox.montecarlo import *
 from scipy import stats
 
 
-
 class test_int_sampler(TestCase):
     def test_simple(self):
         # Sample from a Poisson distribution, P(lambda = 10.0)

Modified: branches/testing_cleanup/scipy/sandbox/numexpr/__init__.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/numexpr/__init__.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/numexpr/__init__.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -1,7 +1,4 @@
-from numexpr.info import __doc__
-from numexpr.expressions import E
-from numexpr.compiler import numexpr, disassemble, evaluate
+from scipy.sandbox.numexpr.info import __doc__
+from scipy.sandbox.numexpr.expressions import E
+from scipy.sandbox.numexpr.compiler import numexpr, disassemble, evaluate
 
-def test(level=1, verbosity=1):
-    from numpy.testing import NumpyTest
-    NumpyTest().test(level, verbosity)

Modified: branches/testing_cleanup/scipy/sandbox/numexpr/compiler.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/numexpr/compiler.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/numexpr/compiler.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -1,7 +1,7 @@
 import sys
 import numpy
 
-from numexpr import interpreter, expressions
+from scipy.sandbox.numexpr import interpreter, expressions
 
 typecode_to_kind = {'b': 'bool', 'i': 'int', 'l': 'long', 'f': 'float',
                     'c': 'complex', 's': 'str', 'n' : 'none'}

Modified: branches/testing_cleanup/scipy/sandbox/numexpr/expressions.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/numexpr/expressions.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/numexpr/expressions.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -6,7 +6,7 @@
 
 import numpy
 
-from numexpr import interpreter
+from scipy.sandbox.numexpr import interpreter
 
 class Expression(object):
     def __init__(self):

Modified: branches/testing_cleanup/scipy/sandbox/numexpr/tests/test_numexpr.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/numexpr/tests/test_numexpr.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/numexpr/tests/test_numexpr.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -1,9 +1,10 @@
 import new
-from numpy import *
+from numpy import array, arange, sin, zeros, sum, int32, empty, \
+     prod, uint16, complex_, float64, rec
 from scipy.testing import *
 
 
-from numexpr import E, numexpr, evaluate, disassemble
+from scipy.sandbox.numexpr import E, numexpr, evaluate, disassemble
 
 
 class test_numexpr(TestCase):

Modified: branches/testing_cleanup/scipy/sandbox/pyloess/mpyloess.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/pyloess/mpyloess.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/pyloess/mpyloess.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -42,9 +42,8 @@
 nempty = numeric.empty
 nlogical_not = numpy.logical_not
 
-import maskedarray.core
-from maskedarray.core import masked, nomask, mask_or
-from maskedarray.core import masked_array as marray
+from scipy.sandbox.maskedarray.core import masked, nomask, mask_or, \
+     masked_array as marray
 
 import _lowess, _stl, _mloess
 

Modified: branches/testing_cleanup/scipy/sandbox/pyloess/tests/test_mpyloess.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/pyloess/tests/test_mpyloess.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/pyloess/tests/test_mpyloess.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -18,19 +18,16 @@
 import numpy.core.numeric as numeric
 fromiter = numpy.fromiter
 
-import maskedarray
+from scipy.sandbox import maskedarray
 marray = maskedarray.masked_array
 masked_values = maskedarray.masked_values
 
-from scipy.testing import NumpyTest, TestCase
-from maskedarray.testutils import build_err_msg, \
+from scipy.testing import *
+from scipy.sandbox.maskedarray.testutils import build_err_msg, \
         assert_equal, assert_almost_equal
 
+from scipy.sandbox.pyloess.mpyloess import lowess, stl, loess, loess_anova
 
-import mpyloess
-reload(mpyloess)
-from mpyloess import lowess, stl, loess, loess_anova
-
 #####---------------------------------------------------------------------------
 #---- --- LOWESS ---
 #####---------------------------------------------------------------------------

Modified: branches/testing_cleanup/scipy/sandbox/pyloess/tests/test_pyloess.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/pyloess/tests/test_pyloess.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/pyloess/tests/test_pyloess.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -21,13 +21,9 @@
 narray = numpy.array
 
 
-from scipy.testing import NumpyTest, TestCase
-from scipy.testing.utils import build_err_msg, \
-        assert_equal, assert_almost_equal
+from scipy.testing import *
 
-import pyloess
-reload(pyloess)
-from pyloess import lowess, stl, loess, loess_anova
+from scipy.sandbox.pyloess import lowess, stl, loess, loess_anova
 
 #####---------------------------------------------------------------------------
 #---- --- LOWESS ---

Modified: branches/testing_cleanup/scipy/sandbox/rbf/tests/test_rbf.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/rbf/tests/test_rbf.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/rbf/tests/test_rbf.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -6,7 +6,7 @@
 from numpy import linspace, sin, random, exp
 
 
-from rbf.rbf import Rbf
+from scipy.sandbox.rbf.rbf import Rbf
 
 
 class TestRbf1d(TestCase):

Modified: branches/testing_cleanup/scipy/sandbox/spline/tests/test_fitpack.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/spline/tests/test_fitpack.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/spline/tests/test_fitpack.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -16,14 +16,14 @@
 from numpy import array, arange, around, pi, sin, ravel, zeros, asarray
 
 
-from spline.fitpack import splprep, splrep, splev, sproot, splint, spalde
-from spline.fitpack import bisplev, bisplrep, splprep
+from scipy.sandbox.spline.fitpack import splprep, splrep, splev, sproot, \
+     splint, spalde, bisplev, bisplrep, splprep
 
 
 set_local_path()
 from dierckx_test_data import *
+restore_path()
 
-
 class TestSplrepSplev(TestCase):
     def test_curfit_against_dierckx_smth(self):
         x,y = curfit_test['x'],curfit_test['y']

Modified: branches/testing_cleanup/scipy/sandbox/spline/tests/test_spline.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/spline/tests/test_spline.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/spline/tests/test_spline.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -17,16 +17,14 @@
 from numpy import array, arange, around, pi, sin, cos
 
 
-from spline.spline import UnivariateSpline,LSQUnivariateSpline,\
-     InterpolatedUnivariateSpline
-from spline.spline import LSQBivariateSpline, SmoothBivariateSpline,\
+from scipy.sandbox.spline.spline import UnivariateSpline,LSQUnivariateSpline,\
+     InterpolatedUnivariateSpline, LSQBivariateSpline, SmoothBivariateSpline,\
      RectBivariateSpline
 
-
 set_local_path()
 from dierckx_test_data import *
+restore_path()
 
-
 class TestUnivariateSpline(TestCase):
     def test_linear_constant(self):
         x = [1,2,3]

Modified: branches/testing_cleanup/scipy/sandbox/timeseries/dates.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/timeseries/dates.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/timeseries/dates.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -25,7 +25,7 @@
 import numpy.core.numerictypes as ntypes
 from numpy.core.numerictypes import generic
 
-import maskedarray as MA
+import scipy.sandbox.maskedarray as MA
 
 from parser import DateFromString, DateTimeFromString
 

Modified: branches/testing_cleanup/scipy/sandbox/timeseries/extras.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/timeseries/extras.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/timeseries/extras.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -12,8 +12,8 @@
 
 
 import numpy
-import maskedarray
-from maskedarray import masked
+import scipy.sandbox.maskedarray
+from scipy.sandbox.maskedarray import masked
 
 import const as _c
 from tseries import TimeSeries

Modified: branches/testing_cleanup/scipy/sandbox/timeseries/lib/filters.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/timeseries/lib/filters.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/timeseries/lib/filters.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -17,8 +17,8 @@
 
 from scipy.signal import convolve, get_window
 
-import maskedarray as MA
-from maskedarray import MaskedArray, nomask, getmask, getmaskarray, masked
+import scipy.sandbox.maskedarray as MA
+from scipy.sandbox.maskedarray import MaskedArray, nomask, getmask, getmaskarray, masked
 marray = MA.array
 
 from moving_funcs import mov_average_expw, cmov_average, cmov_mean, \

Modified: branches/testing_cleanup/scipy/sandbox/timeseries/lib/interpolate.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/timeseries/lib/interpolate.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/timeseries/lib/interpolate.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -14,9 +14,9 @@
 
 from scipy.interpolate import fitpack
 
-import maskedarray as MA
-from maskedarray.core import masked, nomask, getmask
-from maskedarray.extras import flatnotmasked_edges
+import scipy.sandbox.maskedarray as MA
+from scipy.sandbox.maskedarray.core import masked, nomask, getmask
+from scipy.sandbox.maskedarray.extras import flatnotmasked_edges
 marray = MA.array
 
 __all__ = [

Modified: branches/testing_cleanup/scipy/sandbox/timeseries/lib/moving_funcs.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/timeseries/lib/moving_funcs.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/timeseries/lib/moving_funcs.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -23,11 +23,11 @@
 
 from scipy.signal import convolve, get_window
 
-import maskedarray as MA
-from maskedarray import MaskedArray, nomask, getmask, getmaskarray, masked
+import scipy.sandbox.maskedarray as MA
+from scipy.sandbox.maskedarray import MaskedArray, nomask, getmask, getmaskarray, masked
 marray = MA.array
 
-from timeseries.cseries import MA_mov_sum, MA_mov_median, MA_mov_min, \
+from scipy.sandbox.timeseries.cseries import MA_mov_sum, MA_mov_median, MA_mov_min, \
                                MA_mov_max
 
 def _process_result_dict(orig_data, result_dict):

Modified: branches/testing_cleanup/scipy/sandbox/timeseries/report.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/timeseries/report.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/timeseries/report.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -59,8 +59,8 @@
 
 import sys
 import operator, types, copy
-import timeseries as ts
-import maskedarray as ma
+import tseries as ts
+import scipy.sandbox.maskedarray as ma
 
 __all__ = [
     'Report', 'wrap_onspace', 'wrap_onspace_strict',

Modified: branches/testing_cleanup/scipy/sandbox/timeseries/tests/test_dates.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/timeseries/tests/test_dates.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/timeseries/tests/test_dates.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -16,21 +16,17 @@
 import numpy
 import numpy.core.fromnumeric  as fromnumeric
 import numpy.core.numeric as numeric
-from scipy.testing import NumpyTest, TestCase
-from scipy.testing.utils import build_err_msg
+from scipy.testing import *
 
-import maskedarray
-from maskedarray import masked_array
+from scipy.sandbox.maskedarray import masked_array
 
-import maskedarray.testutils
-from maskedarray.testutils import assert_equal, assert_array_equal
+from scipy.sandbox.maskedarray.testutils import assert_equal, assert_array_equal
 
-import timeseries as ts
-from timeseries import const as C
-from timeseries.parser import DateFromString, DateTimeFromString
-from timeseries import Date, DateArray,\
-    now, date_array, date_array_fromlist
-from timeseries.cseries import freq_dict
+import scipy.sandbox.timeseries as ts
+from scipy.sandbox.timeseries import const as C, Date, DateArray,\
+     now, date_array, date_array_fromlist
+from scipy.sandbox.timeseries.parser import DateFromString, DateTimeFromString
+from scipy.sandbox.timeseries.cseries import freq_dict
 
 
 class TestCreation(TestCase):

Modified: branches/testing_cleanup/scipy/sandbox/timeseries/tests/test_extras.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/timeseries/tests/test_extras.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/timeseries/tests/test_extras.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -13,14 +13,13 @@
 
 
 import numpy
-from scipy.testing import NumpyTest, TestCase
-import maskedarray
-from maskedarray import masked
-from maskedarray.testutils import assert_equal, assert_almost_equal
+from scipy.testing import *
+import scipy.sandbox.maskedarray
+from scipy.sandbox.maskedarray import masked
+from scipy.sandbox.maskedarray.testutils import assert_equal, assert_almost_equal
 
-from timeseries import time_series, Date
-from timeseries import extras
-from timeseries.extras import *
+from scipy.sandbox.timeseries import time_series, Date, extras
+from scipy.sandbox.timeseries.extras import *
 
 #..............................................................................
 class TestMisc(TestCase):

Modified: branches/testing_cleanup/scipy/sandbox/timeseries/tests/test_timeseries.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/timeseries/tests/test_timeseries.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/timeseries/tests/test_timeseries.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -15,21 +15,18 @@
 from numpy import bool_, complex_, float_, int_, object_
 import numpy.core.fromnumeric  as fromnumeric
 import numpy.core.numeric as numeric
-from scipy.testing import NumpyTest, TestCase
-from scipy.testing.utils import build_err_msg
+from scipy.testing import *
 
-import maskedarray
-import maskedarray as MA
-from maskedarray import masked_array, masked, nomask
+import scipy.sandbox.maskedarray
+import scipy.sandbox.maskedarray as MA
+from scipy.sandbox.maskedarray import masked_array, masked, nomask
 
-import maskedarray.testutils
-from maskedarray.testutils import assert_equal, assert_array_equal
+from scipy.sandbox.maskedarray.testutils import assert_equal, assert_array_equal
 
-from timeseries import tseries
-from timeseries import Date, date_array_fromlist, date_array_fromrange, date_array, thisday
-from timeseries import time_series, TimeSeries, adjust_endpoints, \
-    mask_period, align_series, align_with, fill_missing_dates, tsmasked, \
-    concatenate, stack, split
+from scipy.sandbox.timeseries import tseries, Date, date_array_fromlist, \
+     date_array_fromrange, date_array, thisday, time_series, TimeSeries, \
+     adjust_endpoints, mask_period, align_series, align_with, \
+     fill_missing_dates, tsmasked, concatenate, stack, split
 
 class TestCreation(TestCase):
     "Base test class for MaskedArrays."

Modified: branches/testing_cleanup/scipy/sandbox/timeseries/tests/test_trecords.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/timeseries/tests/test_trecords.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/timeseries/tests/test_trecords.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -14,22 +14,20 @@
 
 import numpy
 import numpy.core.fromnumeric  as fromnumeric
-from scipy.testing import NumpyTest, TestCase
-from scipy.testing.utils import build_err_msg
+from scipy.testing import *
 
-import maskedarray.testutils
-from maskedarray.testutils import assert_equal, assert_array_equal, assert_equal_records
+from scipy.sandbox.maskedarray.testutils import assert_equal, assert_array_equal, assert_equal_records
 
-import maskedarray.core as MA
-import maskedarray.mrecords as MR
-from maskedarray.mrecords import addfield
+import scipy.sandbox.maskedarray.core as MA
+import scipy.sandbox.maskedarray.mrecords as MR
+from scipy.sandbox.maskedarray.mrecords import addfield
 
-from maskedarray.core import getmaskarray, nomask, masked_array
+from scipy.sandbox.maskedarray.core import getmaskarray, nomask, masked_array
 
-from timeseries import trecords
-from timeseries.trecords import TimeSeriesRecords, TimeSeries,\
-    fromarrays, fromtextfile, fromrecords, \
-    date_array, time_series
+from scipy.sandbox.timeseries.trecords import \
+     TimeSeriesRecords, TimeSeries,\
+     fromarrays, fromtextfile, fromrecords, \
+     date_array, time_series
 
 
 #..............................................................................

Modified: branches/testing_cleanup/scipy/sandbox/timeseries/trecords.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/timeseries/trecords.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/timeseries/trecords.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -26,17 +26,15 @@
 from numpy.core.records import format_parser, recarray, record
 from numpy.core.records import fromarrays as recfromarrays
 
-import maskedarray as MA
+import scipy.sandbox.maskedarray as MA
 #MaskedArray = MA.MaskedArray
-from maskedarray.core import MaskedArray, MAError, default_fill_value, \
-    masked_print_option
-from maskedarray.core import masked, nomask, getmask, getmaskarray, make_mask,\
+from scipy.sandbox.maskedarray.core import MaskedArray, MAError, default_fill_value, \
+    masked_print_option, masked, nomask, getmask, getmaskarray, make_mask,\
     make_mask_none, mask_or, masked_array, filled
 
-import maskedarray.mrecords as MR
-from maskedarray.mrecords import _checknames, _guessvartypes, openfile,\
-    MaskedRecords
-from maskedarray.mrecords import fromrecords as mrecfromrecords
+import scipy.sandbox.maskedarray.mrecords as MR
+from scipy.sandbox.maskedarray.mrecords import _checknames, _guessvartypes, openfile,\
+    MaskedRecords, fromrecords as mrecfromrecords
 
 from tseries import TimeSeries, time_series, _getdatalength
 from dates import Date, DateArray, date_array

Modified: branches/testing_cleanup/scipy/sandbox/timeseries/tseries.py
===================================================================
--- branches/testing_cleanup/scipy/sandbox/timeseries/tseries.py	2008-01-04 00:20:17 UTC (rev 3777)
+++ branches/testing_cleanup/scipy/sandbox/timeseries/tseries.py	2008-01-04 01:29:56 UTC (rev 3778)
@@ -25,8 +25,8 @@
 from numpy.core.records import recarray
 from numpy.core.records import fromarrays as recfromarrays
 
-import maskedarray
-from maskedarray import MaskedArray, MAError, masked, nomask, \
+import scipy.sandbox.maskedarray as maskedarray
+from scipy.sandbox.maskedarray import MaskedArray, MAError, masked, nomask, \
     filled, getmask, getmaskarray, hsplit, make_mask_none, mask_or, make_mask, \
     masked_array
     



More information about the Scipy-svn mailing list