mirror of https://github.com/malarinv/tacotron2
add WORKFLOW.md and update final.py
parent
81d15abb4d
commit
102c424eac
|
|
@ -0,0 +1,23 @@
|
|||
|
||||
## Setup
|
||||
- clone the repo
|
||||
|
||||
`git clone https://github.com/agaralabs/tacotron2`
|
||||
- cd to `tacotron2` copy models from wolverine:
|
||||
|
||||
`scp wolverine:/home/ubuntu/tacotron2/{checkpoint_15000,waveglow_256channels.pt} ./`
|
||||
|
||||
`scp wolverine:/home/ubuntu/tacotron2/waveglow ./`
|
||||
|
||||
**Wolverine Details:**
|
||||
```
|
||||
Host wolverine
|
||||
Hostname 54.71.137.17
|
||||
User ubuntu
|
||||
IdentityFile ~/.ssh/id_hip_ml
|
||||
```
|
||||
install the dependencies
|
||||
`pip install requirements.txt`
|
||||
|
||||
## Running:
|
||||
`python final.py`
|
||||
17
final.py
17
final.py
|
|
@ -18,7 +18,7 @@ from text import text_to_sequence
|
|||
# from denoiser import Denoiser
|
||||
import os
|
||||
import soundfile as sf
|
||||
# import pyaudio
|
||||
import pyaudio
|
||||
import time
|
||||
|
||||
sys.path.append('waveglow/')
|
||||
|
|
@ -35,10 +35,6 @@ waveglow.eval()
|
|||
for k in waveglow.convinv:
|
||||
k.float()
|
||||
|
||||
# audio_interface = pyaudio.PyAudio()
|
||||
# # _audio_stream = audio_interface.open(format=pyaudio.paFloat32,channels=1, rate=22050,output=True)
|
||||
# _audio_stream = audio_interface.open(format=pyaudio.paInt16,channels=1, rate=16000,output=True)
|
||||
|
||||
# https://github.com/NVIDIA/waveglow/issues/127
|
||||
for m in waveglow.modules():
|
||||
if 'Conv' in str(type(m)):
|
||||
|
|
@ -72,12 +68,11 @@ def speech(t):
|
|||
|
||||
|
||||
def main():
|
||||
speech(
|
||||
('I understand your frustration and disappointment. I am sorry that'
|
||||
' its happening and I would like to help prevent it in the future. '
|
||||
'What style of diapers did you buy? For instance, was it the '
|
||||
'snugglers, pull ups or baby dry.'))
|
||||
|
||||
data = speech('Hi I am Sia How may I help you today'.lower())
|
||||
audio_interface = pyaudio.PyAudio()
|
||||
_audio_stream = audio_interface.open(format=pyaudio.paInt16,channels=1, rate=16000,output=True)
|
||||
_audio_stream.write(data)
|
||||
import pdb; pdb.set_trace()
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
|
|
|
|||
Loading…
Reference in New Issue