From 3dc39bd9623659158ea65e912236cfe820ce6113 Mon Sep 17 00:00:00 2001
From: Walter Bender <walter.bender@gmail.com>
Date: Thu, 4 Aug 2011 10:58:14 -0400
Subject: [PATCH] removed spam introduced by Commit
efd02466335d8f8677d73b8e04bdeefb310aaa48
Organization: Sugar Labs Foundation
In doing a pep8 cleanup, some f characters got randomly inserted throughout the code. This patch removes them.
---
arange.py | 16 ++++++++--------
1 files changed, 8 insertions(+), 8 deletions(-)
diff --git a/arange.py b/arange.py
index 86bf0c4..0ab8308 100644
a
|
b
|
def compute_mls(R): |
81 | 81 | (32, 31, 30, 10)) |
82 | 82 | |
83 | 83 | n = len(R) |
84 | | return LFSR(Rf, [i - 1 for i in taps[n]], 2**n - 1) |
| 84 | return LFSR(R, [i - 1 for i in taps[n]], 2**n - 1) |
85 | 85 | |
86 | 86 | |
87 | 87 | def LFSR(R, taps, m): |
… |
… |
def start_recording_alsa(): |
168 | 168 | time.sleep(0.02) |
169 | 169 | |
170 | 170 | f = open(fname,'rb') |
171 | | returnf (rec_process, f) |
| 171 | return (rec_process, f) |
172 | 172 | |
173 | 173 | start_recording = start_recording_alsa |
174 | 174 | |
175 | 175 | def stop_recording_alsa(rec_process): |
176 | 176 | os.kill(rec_process.pid, signal.SIGKILL) |
177 | | rec_profcess.wait() |
| 177 | rec_process.wait() |
178 | 178 | |
179 | 179 | stop_recording = stop_recording_alsa |
180 | 180 | |
… |
… |
def read_wav(f): |
193 | 193 | s = w.readframes(n) |
194 | 194 | n = len(s)/(nc*b) |
195 | 195 | a = struct.unpack('<' + str(n*nc) + typecode, s) |
196 | | return nfum.array(a[::nc], num.float) |
| 196 | return num.array(a[::nc], num.float) |
197 | 197 | |
198 | 198 | def read_raw(f): |
199 | 199 | x = f.read() |
… |
… |
def read_raw(f): |
201 | 201 | print "length " + str(n) |
202 | 202 | typecode = 'h' |
203 | 203 | a = struct.unpack('<' + str(n)+typecode, x[:(2*n)]); |
204 | | return nufm.array(a, num.float) |
| 204 | return num.array(a, num.float) |
205 | 205 | |
206 | 206 | read_recorded_file = read_raw |
207 | 207 | |
… |
… |
def cross_cov(a, b, a_id=None): |
221 | 221 | fb = num.fft.rfft(b,n2) |
222 | 222 | fprod = num.conjugate(fa)*fb |
223 | 223 | xc = num.fft.irfft(fprod) |
224 | | return xc[f:n].real |
| 224 | return xc[:n].real |
225 | 225 | |
226 | 226 | def get_room_echo(t): |
227 | 227 | """A test function that can be used to determine the impulse response |
… |
… |
def get_noise_echo(t): |
245 | 245 | |
246 | 246 | rec_array = read_recorded_file(record_wav_file) |
247 | 247 | record_wav_file.close() |
248 | | return crofss_cov(mls - 0.5, rec_array) |
| 248 | return cross_cov(mls - 0.5, rec_array) |
249 | 249 | |
250 | 250 | |
251 | 251 | def do_server_simul(server_address, port): |
252 | | """f |
| 252 | """ |
253 | 253 | Make this computer the server for a distance measurement using |
254 | 254 | measure_dt_simul. |
255 | 255 | """ |