diff --git a/TTS/utils/audio.py b/TTS/utils/audio.py index 93a5880f..87ae4f5b 100644 --- a/TTS/utils/audio.py +++ b/TTS/utils/audio.py @@ -3,7 +3,7 @@ import soundfile as sf import numpy as np import scipy.io.wavfile import scipy.signal -import pyworld as pw +# import pyworld as pw from TTS.tts.utils.data import StandardScaler @@ -292,15 +292,16 @@ class AudioProcessor(object): return pad // 2, pad // 2 + pad % 2 ### Compute F0 ### - def compute_f0(self, x): - f0, t = pw.dio( - x.astype(np.double), - fs=self.sample_rate, - f0_ceil=self.mel_fmax, - frame_period=1000 * self.hop_length / self.sample_rate, - ) - f0 = pw.stonemask(x.astype(np.double), f0, t, self.sample_rate) - return f0 + # TODO: pw causes some dep issues + # def compute_f0(self, x): + # f0, t = pw.dio( + # x.astype(np.double), + # fs=self.sample_rate, + # f0_ceil=self.mel_fmax, + # frame_period=1000 * self.hop_length / self.sample_rate, + # ) + # f0 = pw.stonemask(x.astype(np.double), f0, t, self.sample_rate) + # return f0 ### Audio Processing ### def find_endpoint(self, wav, threshold_db=-40, min_silence_sec=0.8): diff --git a/requirements.txt b/requirements.txt index b1baadd7..1e92f17e 100644 --- a/requirements.txt +++ b/requirements.txt @@ -21,5 +21,5 @@ cardboardlint==1.3.0 pylint==2.5.3 gdown umap-learn -cython==0.29.20 # > 0.29.20 breaks pyworld installation with the min numpy req of Tensorflow 2.4.1 +cython pyyaml \ No newline at end of file