Merge pull request #156585 from mweinelt/tts

tts: 0.4.2 -> 0.5.0
This commit is contained in:
Jörg Thalheim 2022-02-05 08:22:26 +00:00 committed by GitHub
commit 415bdaa0ff
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -15,23 +15,32 @@
python3.pkgs.buildPythonApplication rec {
pname = "tts";
version = "0.4.2";
version = "0.5.0";
format = "setuptools";
src = fetchFromGitHub {
owner = "coqui-ai";
repo = "TTS";
rev = "v${version}";
sha256 = "sha256-8a68iFbqqKwtZvufu1Vnv6hGHIQ3HU34wjuQsmr1NUA=";
sha256 = "sha256-9fNYNhHS9wqrk2bZnrkkGU1OaDu/16RA8fz+Zj9xsyQ=";
};
postPatch = ''
sed -i requirements.txt \
-e 's!librosa==[^"]*!librosa!' \
-e 's!gruut\[.*\]~=2.0.0!gruut!' \
-e 's!mecab-python3==[^"]*!mecab-python3!' \
-e 's!numba==[^"]*!numba!' \
-e 's!numpy==[^"]*!numpy!' \
-e 's!umap-learn==[^"]*!umap-learn!'
postPatch = let
relaxedConstraints = [
"gruut"
"librosa"
"mecab-python3"
"numba"
"numpy"
"umap-learn"
"torch"
];
in ''
sed -r -i \
${lib.concatStringsSep "\n" (map (package:
''-e 's/${package}.*[<>=]+.*/${package}/g' \''
) relaxedConstraints)}
requirements.txt
'';
nativeBuildInputs = with python3.pkgs; [
@ -43,8 +52,8 @@ python3.pkgs.buildPythonApplication rec {
coqpit
flask
fsspec
gruut
gdown
gruut
inflect
jieba
librosa
@ -54,15 +63,17 @@ python3.pkgs.buildPythonApplication rec {
pandas
pypinyin
pysbd
pytorch
pytorch-bin
pyworld
scipy
soundfile
tensorboardx
tensorflow
torchaudio-bin
tqdm
umap-learn
unidic-lite
webrtcvad
];
postInstall = ''