diff options
| author | Matthias Geier <Matthias.Geier@gmail.com> | 2016-08-05 10:01:06 +0200 |
|---|---|---|
| committer | Matthias Geier <Matthias.Geier@gmail.com> | 2016-08-05 10:01:06 +0200 |
| commit | fd9f706b90d5c64d9c7a6903e62724c251da012f (patch) | |
| tree | 15f5363cfe018b4e0cba49d1d2f623b9d3b9b682 /examples/plot_input.py | |
| parent | 5408733e7f7b3ed1f350bbae8d74e758a00f0be7 (diff) | |
Round to integers in plot_input and spectrogram examples
See #21.
Diffstat (limited to 'examples/plot_input.py')
| -rwxr-xr-x | examples/plot_input.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/examples/plot_input.py b/examples/plot_input.py index 26212e5..1210ba3 100755 --- a/examples/plot_input.py +++ b/examples/plot_input.py @@ -86,7 +86,7 @@ try: device_info = sd.query_devices(args.device, 'input') args.samplerate = device_info['default_samplerate'] - length = np.ceil(args.window * args.samplerate / (1000 * args.downsample)) + length = int(args.window * args.samplerate / (1000 * args.downsample)) plotdata = np.zeros((length, len(args.channels))) fig, ax = plt.subplots() |
