From 9a59c68f70f093482ecba031eefaaa8b90fc2781 Mon Sep 17 00:00:00 2001 From: "per.andreas.brodtkorb" Date: Wed, 21 Dec 2011 07:13:44 +0000 Subject: [PATCH] --- pywafo/src/wafo/kdetools.py | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) diff --git a/pywafo/src/wafo/kdetools.py b/pywafo/src/wafo/kdetools.py index 588c190..9335815 100644 --- a/pywafo/src/wafo/kdetools.py +++ b/pywafo/src/wafo/kdetools.py @@ -3046,11 +3046,11 @@ def unfinished_smoothn(data,s=None, weight=None, robust=False, z0=None, tolz=1e- # Lambda contains the eingenvalues of the difference matrix used in this # penalized least squares process. d = y.ndim - Lambda = zeros(sizy) + Lambda = np.zeros(sizy) siz0 = (1,)*d for i in range(d): siz0[i] = sizy(i) - Lambda = Lambda + cos(pi*np.arange(sizy(i))/sizy[i]).reshape(siz0) + Lambda = Lambda + np.cos(pi*np.arange(sizy(i))/sizy[i]).reshape(siz0) siz0[i] = 1 Lambda = -2*(d-Lambda) @@ -3074,7 +3074,7 @@ def unfinished_smoothn(data,s=None, weight=None, robust=False, z0=None, tolz=1e- Wtot = W; # Initial conditions for z if weight is None: - z = zeros(sizy) + z = np.zeros(sizy) else: # With weighted/missing data # An initial guess is provided to ensure faster convergence. For that @@ -3146,10 +3146,10 @@ def unfinished_smoothn(data,s=None, weight=None, robust=False, z0=None, tolz=1e- # Warning messages if isauto - if abs(log10(s)-log10(sMinBnd))