feat: numpy 2+ support (#937)

Co-authored-by: 源文雨 <41315874+fumiama@users.noreply.github.com>
This commit is contained in:
BBC-Esq
2025-05-23 08:59:02 -04:00
committed by GitHub
parent 46ad65f903
commit 1092c1ffca
3 changed files with 4 additions and 3 deletions
+2 -1
View File
@@ -259,9 +259,10 @@ class Chat:
return res_gen
elif not refine_text_only:
stripped_wavs = []
thr = np.float32(1e-5)
for wavs in res_gen:
for wav in wavs:
stripped_wavs.append(wav[np.abs(wav) > 1e-5])
stripped_wavs.append(wav[np.abs(wav) > thr])
if split_text:
return [np.concatenate(stripped_wavs)]
return stripped_wavs
+1 -1
View File
@@ -1,4 +1,4 @@
numpy<2.0.0
numpy<3.0.0
numba
torch>=2.1.0
torchaudio
+1 -1
View File
@@ -20,7 +20,7 @@ setup(
license="AGPLv3+",
install_requires=[
"numba",
"numpy<2.0.0",
"numpy<3.0.0",
"pybase16384",
"torch>=2.1.0",
"torchaudio",