Pydiogment
Pydiogment aims to simplify audio augmentation. It generates multiple audio files based on a starting mono audio file. The library can generates files with higher speed, slower, and different tones etc.
Installation
Dependencies
Pydiogment requires:
-
Python (>= 3.5)
-
NumPy (>= 1.17.2)
pip install numpy -
SciPy (>= 1.3.1)
pip install scipy -
FFmpeg
sudo apt install ffmpeg
Installation
If you already have a working installation of NumPy and SciPy , you can simply install Pydiogment using pip:
pip install pydiogment
To update an existing version of Pydiogment, use:
pip install -U pydiogment
How to use
-
Amplitude related augmentation
-
Apply a fade in and fade out effect
from pydiogment.auga import fade_in_and_out test_file = "path/test.wav" fade_in_and_out(test_file)
-
Apply gain to file
from pydiogment.auga import apply_gain test_file = "path/test.wav" apply_gain(test_file, -100) apply_gain(test_file, -50)
-
Add Random Gaussian Noise based on SNR to file
from pydiogment.auga import add_noise test_file = "path/test.wav" add_noise(test_file, 10)
-
-
Frequency related augmentation
-
Time related augmentation
-
Slow-down/ speed-up file
from pydiogment.augt import slowdown, speed test_file = "path/test.wav" slowdown(test_file, 0.8) speed(test_file, 1.2)
-
Apply random cropping to the file
from pydiogment.augt import random_cropping test_file = "path/test.wav" random_cropping(test_file, 1)
-
Change shift data on the time axis in a certain direction
from pydiogment.augt import shift_time test_file = "path/test.wav" shift_time(test_file, 1, "right") shift_time(test_file, 1, "left")
-
Documentation
A thorough documentation of the library is available under pydiogment.readthedocs.io.
Contributing
Contributions are welcome and encouraged. To learn more about how to contribute to Pydiogment please refer to the Contributing guidelines
Acknowledgment and credits
- The test file used in the pytests is OSR_us_000_0060_8k.wav from the Open Speech Repository.
Metadata
Release files for pydiogment 0.1.0
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 | Actions |
|---|---|---|---|---|
| pydiogment-0.1.0.tar.gz | 9.7 kB | Without provenance | Details for pydiogment-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| pydiogment-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for pydiogment-0.1.0-py3-none-any.whl |
Total release size: 22.8 kB
Release files / pydiogment-0.1.0.tar.gz
| Download URL | pydiogment-0.1.0.tar.gz |
|---|---|
| Size | 9.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
95321a317d84e8a899135845f258c05dac23ae2f3bac790130c4bd375ff05fc9
|
|
BLAKE2b-256 checksum How to use checksums |
497202f93b3efdf5f374cb7d2aa33ecfa765b6b0af69c0a2737076055c4155e8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/42.0.2.post20191203 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.7.5
|
Release files / pydiogment-0.1.0-py3-none-any.whl
| Download URL | pydiogment-0.1.0-py3-none-any.whl |
|---|---|
| Size | 13.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
0aeee4f438a884f9ac28b907921de946128558cf77f3a062075125cd1ef2ab18
|
|
BLAKE2b-256 checksum How to use checksums |
582798e4eb916ef86e9b6dded28c771fab5d35e48555d618496292470f19da08
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/42.0.2.post20191203 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.7.5
|
Security for pydiogment 0.1.0
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.