A real-time audio time-scale modification library
AudioTSM is a python library for real-time audio time-scale modification procedures, i.e. algorithms that change the speed of an audio signal without changing its pitch.
- Documentation:
- Examples:
- Source code repository and issue tracker:
- Python Package Index:
- License:
MIT – see the file LICENSE for details.
Installation
Audiotsm should work with python 2.7 and python 3.4+.
You can install the latest version of audiotsm with pip:
pip install audiotsm
If you want to use the gstreamer plugins, you should install PyGObject and python-gst, and use the following command to install audiotsm:
pip install audiotsm[gstreamer]
If you want to play the output of the TSM procedures in real time, or to use the examples, you should install audiotsm as follow:
pip install audiotsm[stream]
Basic usage
The audiotsm package implements several time-scale modification procedures:
OLA (Overlap-Add);
WSOLA (Waveform Similarity-based Overlap-Add);
Phase Vocoder.
The OLA procedure should only be used on percussive audio signals. The WSOLA and the Phase Vocoder procedures are improvements of the OLA procedure, and should both give good results in most cases.
If you are unsure which procedure to choose, the Phase Vocoder should sound best in most cases. You can listen to the output of the different procedures on various audio files and at various speeds on the examples page.
Below is a basic example showing how to reduce the speed of a wav file by half using the WSOLA procedure:
from audiotsm import phasevocoder
from audiotsm.io.wav import WavReader, WavWriter
with WavReader(input_filename) as reader:
with WavWriter(output_filename, reader.channels, reader.samplerate) as writer:
tsm = phasevocoder(reader.channels, speed=0.5)
tsm.run(reader, writer)
Thanks
If you are interested in time-scale modification procedures, I highly recommend reading A Review of Time-Scale Modification of Music Signals by Jonathan Driedger and Meinard Müller.
Metadata
Release files for audiotsm 0.1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| audiotsm-0.1.2.tar.gz | 6.6 MB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| audiotsm-0.1.2-py2.py3-none-any.whl | Python 3, Python 2 | none | any | Details |
Total release size: 6.6 MB
Release files / audiotsm-0.1.2.tar.gz
| Download URL | audiotsm-0.1.2.tar.gz |
|---|---|
| Size | 6.6 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
8870af28fad0a76cac1d2bb2b55e7eac6ad5d1ad5416293eb16120dece6c0281
|
|
BLAKE2b-256 checksum How to use checksums |
f8b8721a9c613641c938a6fb9c7c3efb173b7f77b519de066e9cd2eeb27c3289
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Release files / audiotsm-0.1.2-py2.py3-none-any.whl
| Download URL | audiotsm-0.1.2-py2.py3-none-any.whl |
|---|---|
| Size | 32.2 kB |
| Tags | Python 2 Python 3 |
|
SHA-256 checksum How to use checksums |
f6041b2a38326d1449ca84218c258c54ee126868fe864e12a17e425365ec93be
|
|
BLAKE2b-256 checksum How to use checksums |
9c7da214ff529fed9501452252d24231f54ab5afe8691b4f81e5d07d204070b4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for audiotsm 0.1.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.