1
- # PyWorldVocoder< br /> A Python wrapper for World Vocoder
1
+ # PyWorldVocoder - A Python wrapper for World Vocoder
2
2
3
3
4
4
| ** ` Linux ` ** |
9
9
Morise's World Vocoder is a fast and high-quality vocoder.
10
10
World Vocoder parameterizes speech into three components:
11
11
12
- 5 . Pitch (fundamental frequency, F0) contour
13
- 2 . smoothed spectrogram
14
- 3 . aperiodicity
12
+ 1 . Pitch (fundamental frequency, F0) contour
13
+ 2 . Harmonic spectral envelope
14
+ 3 . Aperiodic spectral envelope (relative to the harmonic spectral envelope)
15
15
16
16
It can also resynthesize speech using these features (see examples below).
17
17
18
18
For more information, please visit [ Morise's World repository] ( https://github.com/mmorise/World )
19
19
and the [ official website of World Vocoder] ( http://ml.cs.yamanashi.ac.jp/world/english/ )
20
20
21
- <br />
22
-
23
21
24
22
## I. APIs
25
23
@@ -41,20 +39,20 @@ y = pw.synthesize(f0, sp, ap, fs, pyDioOpt.option['frame_period'])
41
39
f0, sp, ap, pyDioOpt = pw.wav2world(x, fs)
42
40
```
43
41
44
- <br />
45
42
46
43
## II. Installation
47
44
### Environment/Dependencies
48
- - Linux Ubuntu 14.04/16.04
49
- - Python 2.7.6 /3.5
50
- - Cython 0.24 (or later versions; required)
51
- - Scipy
52
- - Numpy
53
- - argparse
54
- - Matplotlib (optional; for demo.py only)
45
+ - Linux Ubuntu 14.04/16.04, Windows
46
+ - Python 2.7/3.5
47
+ - Cython 0.24 (or later versions; required)
48
+ - Numpy
49
+ - argparse (optional; for demo.py only)
50
+ - PySoundFile (optional; for demo.py only)
51
+ - Matplotlib (optional; for demo.py only)
55
52
56
53
You can simply install these by ` pip install -r requirements.txt `
57
54
55
+
58
56
### Installation procedures
59
57
``` bash
60
58
pip install -U pip
@@ -64,49 +62,48 @@ cd Python-Wrapper-for-World-Vocoder
64
62
bash download_vocoder.sh
65
63
python setup.py install
66
64
```
67
- It will automatically ` git clone ` Morise's World Vocoder (C++ version).
68
- <br />
65
+ It will automatically ` git clone ` Morise's World Vocoder (C++ version).< br />
66
+ Alternatively you can clone or download the World repository manually and copy its "src" directory to this repositories directory. <br />
69
67
As for installation mode (the last line), you can choose from the following options.
70
68
71
69
72
70
### Installation Mode
73
- 9 . If you want to "install" this package, try <br />
74
- ` python setup.py install `
75
- (add ` --user ` if you don't have root access)
76
- 0 . If you just want to try out some experiments, execute
77
- ` python setup.py build_ext --inplace ` <br />
71
+ 1 . If you want to "install" this package, try<br />
72
+ ` python setup.py install ` < br />
73
+ (add ` --user ` if you don't have root access)
74
+ 2 . If you just want to try out some experiments, execute< br />
75
+ ` python setup.py build_ext --inplace ` <br />
78
76
Then you can use PyWorld from this directory.<br />
79
- You can also copy the resulting ** pyworld.so** file to
80
- ` ~/.local/lib/python2.7/site-packages ` <br />
81
- so that you can use it everywhere like an installed package.
77
+ You can also copy the resulting ** pyworld.so** (pyworld.{arch}.pyd on Windows) file to
78
+ ` ~/.local/lib/python2.7/site-packages ` (or corresponding Windows directory)
79
+ so that you can use it everywhere like an installed package.<br />
80
+ Alternatively you can copy/symlink the compiled files using pip, e.g. ` pip install -e . `
82
81
83
82
84
83
### Validation
85
- You can validate installation by running
86
- ` python demo.py `
84
+ You can validate installation by running
85
+ ` python demo.py `
87
86
to see if you get results in ` test/ ` direcotry.
88
87
89
- <br />
90
88
91
89
## Troubleshooting
92
- 0 . Upgrade your Cython version to 0.24.<br />
90
+ 1 . Upgrade your Cython version to 0.24.<br />
93
91
(I failed to build it on Cython 0.20.1post0)<br />
94
- It'll require you to download Cython form http://cython.org/ <br />
92
+ It'll require you to download Cython form http://cython.org/ <br />
95
93
Unzip it, and ` python setup.py install ` it.<br />
96
94
(I tried ` pip install Cython ` but the upgrade didn't seem correct)<br />
97
- (Again, add ` --user ` if you don't have root access.)
95
+ (Again, add ` --user ` if you don't have root access.)
96
+ 2 . The following code might be needed in some configurations:
98
97
99
- 1 . The following code might be needed in some configurations:
100
- ``` python
101
- import matplotlib
102
- matplotlib.use(' Agg' )
103
- ```
98
+ ``` python
99
+ import matplotlib
100
+ matplotlib.use(' Agg' )
101
+ ```
104
102
105
- <br />
106
103
107
104
## Note:
108
105
1 . This wrapper is an updated version of sotelo's "world.py"<br />
109
- https://github.com/sotelo/world.py
106
+ https://github.com/sotelo/world.py
110
107
111
108
## TODO List
112
109
0 commit comments