Showing the changes to python (1 of 1 file). Show all
Unified · Split
| @@ -54,13 +54,16 @@ def slice_source_at_stamps(source_file, timestamps, timestamps_end=None, · 53 unmodified lines | ||
| 54 | 54 | |
| 55 | 55 | Examples |
| 56 | 56 | -------- |
| 57 | − Create two slices, the first second of a file and the rest of it: | |
| 57 | + Create two slices: the first slice starts at the beginning of the | |
| 58 | + input file `loop.wav` and lasts exactly one second, starting at | |
| 59 | + sample `0` and ending at sample `44099`; the second slice starts | |
| 60 | + at sample `44100` and lasts until the end of the input file: | |
| 58 | 61 | |
| 59 | 62 | >>> aubio.slice_source_at_stamps('loop.wav', [0, 44100]) |
| 60 | 63 | |
| 61 | 64 | Create one slice, from 1 second to 2 seconds: |
| 62 | 65 | |
| 63 | − >>> aubio.slice_source_at_stamps('loop.wav', [44100], [44100*2]) | |
| 66 | + >>> aubio.slice_source_at_stamps('loop.wav', [44100], [44100 * 2 - 1]) | |
| 64 | 67 | |
| 65 | 68 | Notes |
| 66 | 69 | ----- |