sampling: use raised cosine window.

This commit is contained in:
Roman Zeyde
2015-02-16 19:12:05 +02:00
parent 90dd3e55f0
commit fdf6e7e882

View File

@@ -14,7 +14,7 @@ class Interpolator(object):
N = resolution * width
u = np.arange(-N, N, dtype=float)
window = (1 + np.cos(0.5 * np.pi * u / N)) / 2.0 # (Hann window)
window = np.cos(0.5 * np.pi * u / N) ** 2.0 # raised cosine
h = np.sinc(u / resolution) * window
self.filt = []