PyWorld: a Python wrapper for WORLD vocoder
Low maintenance activity. Last release 3 months ago, commits in 1 of the last 26 weeks. Weaker on commit activity and release cadence.
pip install pyworldPyWORLD - A Python wrapper of WORLD Vocoder
Linux | Windows |
|---|---|
WORLD Vocoder is a fast and high-quality vocoder which parameterizes speech into three components:
f0: Pitch contoursp: Harmonic spectral envelopeap: Aperiodic spectral envelope (relative to the harmonic spectral envelope)
It can also (re)synthesize speech using these features (see examples below).
For more information, please visit Dr. Morise's WORLD repository and the official website of WORLD Vocoder
APIs
Vocoder Functions
import pyworld as pw
_f0, t = pw.dio(x, fs) # raw pitch extractor
f0 = pw.stonemask(x, _f0, t, fs) # pitch refinement
sp = pw.cheaptrick(x, f0, t, fs) # extract smoothed spectrogram
ap = pw.d4c(x, f0, t, fs) # extract aperiodicity
y = pw.synthesize(f0, sp, ap, fs) # synthesize an utterance using the parameters
Utility
# Convert speech into features (using default arguments)
f0, sp, ap = pw.wav2world(x, fs)
You can change the default arguments of the function, too.
See more info using help.
Installation
Using Pip
pip install pyworld
Building from Source
git clone https://github.com/JeremyCCHsu/Python-Wrapper-for-World-Vocoder.git
cd Python-Wrapper-for-World-Vocoder
git submodule update --init
pip install -U pip
pip install -r requirements.txt
pip install .
It will automatically git clone Morise's World Vocoder (C++ version).
(It seems to me that using or is the best practice.)