sonusai 1.0.2__py3-none-any.whl → 1.0.4__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- sonusai/genmixdb.py +6 -0
- sonusai/mixture/effects.py +1 -1
- sonusai/mixture/generation.py +2 -1
- {sonusai-1.0.2.dist-info → sonusai-1.0.4.dist-info}/METADATA +2 -1
- {sonusai-1.0.2.dist-info → sonusai-1.0.4.dist-info}/RECORD +7 -7
- {sonusai-1.0.2.dist-info → sonusai-1.0.4.dist-info}/WHEEL +0 -0
- {sonusai-1.0.2.dist-info → sonusai-1.0.4.dist-info}/entry_points.txt +0 -0
sonusai/genmixdb.py
CHANGED
@@ -91,6 +91,9 @@ def genmixdb(
|
|
91
91
|
if len([file for file in source_files if file.category == "primary"]) == 0:
|
92
92
|
raise RuntimeError("Canceled due to no primary sources")
|
93
93
|
|
94
|
+
if logging:
|
95
|
+
logger.info("Populating source file table")
|
96
|
+
|
94
97
|
populate_source_file_table(location, source_files, test)
|
95
98
|
|
96
99
|
if logging:
|
@@ -123,6 +126,9 @@ def genmixdb(
|
|
123
126
|
ir_files = get_ir_files(config, show_progress=show_progress)
|
124
127
|
logger.info("")
|
125
128
|
|
129
|
+
if logging:
|
130
|
+
logger.info("Populating impulse response file table")
|
131
|
+
|
126
132
|
populate_impulse_response_file_table(location, ir_files, test)
|
127
133
|
|
128
134
|
if logging:
|
sonusai/mixture/effects.py
CHANGED
@@ -308,7 +308,7 @@ def evaluate_sai_random_ir(mixdb: MixtureDatabase, text: str) -> str:
|
|
308
308
|
return m.group(1)
|
309
309
|
|
310
310
|
if re.match(rand_pattern, text):
|
311
|
-
return f"ir {randint(0, mixdb.num_ir_files)}" # noqa: S311
|
311
|
+
return f"ir {randint(0, mixdb.num_ir_files - 1)}" # noqa: S311
|
312
312
|
|
313
313
|
if re.match(rand_range_pattern, text):
|
314
314
|
try:
|
sonusai/mixture/generation.py
CHANGED
@@ -437,6 +437,7 @@ def populate_mixture_table(
|
|
437
437
|
# Populate source table
|
438
438
|
if logging:
|
439
439
|
logger.info("Populating source table")
|
440
|
+
# TODO: refactor this to not load all sources into list; maybe us UNIQUE table modifier?
|
440
441
|
sources: list[tuple[str, int, float, bool, float, float, bool, int]] = []
|
441
442
|
for mixture in mixtures:
|
442
443
|
for source in mixture.all_sources.values():
|
@@ -577,7 +578,7 @@ def _initialize_mixture_gains(mixdb: MixtureDatabase, mixture: Mixture, sources_
|
|
577
578
|
# Special case for zeroing out noise data
|
578
579
|
mixture.all_sources[category].snr_gain = 0
|
579
580
|
elif category != "primary":
|
580
|
-
if sources_energy["primary"] == 0:
|
581
|
+
if sources_energy["primary"] == 0 or sources_energy[category] == 0:
|
581
582
|
# Avoid divide-by-zero
|
582
583
|
mixture.all_sources[category].snr_gain = 1
|
583
584
|
else:
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.3
|
2
2
|
Name: sonusai
|
3
|
-
Version: 1.0.
|
3
|
+
Version: 1.0.4
|
4
4
|
Summary: Framework for building deep neural network models for sound, speech, and voice AI
|
5
5
|
Home-page: https://aaware.com
|
6
6
|
License: GPL-3.0-only
|
@@ -36,6 +36,7 @@ Requires-Dist: pyyaml (>=6.0.2,<7.0.0)
|
|
36
36
|
Requires-Dist: requests (>=2.32.3,<3.0.0)
|
37
37
|
Requires-Dist: rich (>=13.9.4,<14.0.0)
|
38
38
|
Requires-Dist: samplerate (>=0.2.1,<0.3.0)
|
39
|
+
Requires-Dist: scikit-learn (>=1.6.1,<2.0.0)
|
39
40
|
Requires-Dist: sh (>=2.2.2,<3.0.0)
|
40
41
|
Requires-Dist: soundfile (>=0.12.1,<0.13.0)
|
41
42
|
Requires-Dist: sox (>=1.5.0,<2.0.0)
|
@@ -23,7 +23,7 @@ sonusai/doc.py,sha256=ZgFSSI56oNDb-yC3xi-RHMClMjryR2VrgGyi3ggX8gM,1098
|
|
23
23
|
sonusai/genft.py,sha256=jGjtjQQEuPunROkoDOYZ7gdyZEa09EMCVhpHrkBZ7A0,5571
|
24
24
|
sonusai/genmetrics.py,sha256=sbcqbjI4YOJd5_Lzor4Re_TK6GUQ5zJuYbhDux8odI0,6184
|
25
25
|
sonusai/genmix.py,sha256=U62GPgejGfnDfRgXUosmnVVWvTV07sg46JQEIew0nPg,5744
|
26
|
-
sonusai/genmixdb.py,sha256
|
26
|
+
sonusai/genmixdb.py,sha256=_YPIwBn_yqbE6Nik0j_-3vT0lO35Jemq_xDsA7zoCi4,11132
|
27
27
|
sonusai/ir_metric.py,sha256=nxS_mARPSZG5Y0G3L8HysOnkPj4v-RGxAxAVBYe-gJI,19600
|
28
28
|
sonusai/lsdb.py,sha256=86t6PpsyardRa6VcSJ-KyU1NiTmlg59VUlcSTptJbn0,5078
|
29
29
|
sonusai/main.py,sha256=72feJv5XEVJE_CQatmNIL1VD9ca-Mo0QNDbXxLrHrbQ,2619
|
@@ -52,9 +52,9 @@ sonusai/mixture/config.py,sha256=2_hEndyRXxyBpGzyBFaDT9REYGoK9Q7HQy8vDqPozus,233
|
|
52
52
|
sonusai/mixture/constants.py,sha256=Kklzhf5DL30yb3TpqRbvRUhcFrEXJ4s2S3D_nw4ARxM,1498
|
53
53
|
sonusai/mixture/data_io.py,sha256=DV48sFcP2Qp3NBzvcnlptQOXU3aUEcAeLuh3XOtC5jI,5341
|
54
54
|
sonusai/mixture/db_datatypes.py,sha256=VvNtbOgt5WSeSnBoVcNGC5gs_7hX_38pDUPjy5KRbG4,1471
|
55
|
-
sonusai/mixture/effects.py,sha256=
|
55
|
+
sonusai/mixture/effects.py,sha256=ghMO-WiSMQc1CvafD0wkt_DGsM2A6Hi_oZS6j-jeZh8,11784
|
56
56
|
sonusai/mixture/feature.py,sha256=7GJvFhfqeqerfjy9Vq9aKt-cecgYblK0IypNNo5hgwY,2285
|
57
|
-
sonusai/mixture/generation.py,sha256=
|
57
|
+
sonusai/mixture/generation.py,sha256=iozYcur9oGFDOgovph-F7mzuaD7ie-2ED4NE7kpAPWY,32559
|
58
58
|
sonusai/mixture/helpers.py,sha256=dmyHwf1C5dZjYOd11kVV16KI33CaM-dU_fyaxOrrKt8,11642
|
59
59
|
sonusai/mixture/ir_delay.py,sha256=aiC23HMWQ08-v5wORgMx1_DOJSdh4kunULqiQ-SGuMo,2026
|
60
60
|
sonusai/mixture/ir_effects.py,sha256=PqiqD4PS42-7kD6ESnsZi2a3tnKCFa4E0xqUujRBvGg,2152
|
@@ -132,7 +132,7 @@ sonusai/utils/tokenized_shell_vars.py,sha256=EDrrAgz5lJ0RBAjLcTJt1MeyjhbNZiqXkym
|
|
132
132
|
sonusai/utils/write_audio.py,sha256=IHzrJoFtFcea_J6wo6QSiojRkgnNOzAEcg-z0rFV7nU,810
|
133
133
|
sonusai/utils/yes_or_no.py,sha256=0h1okjXmDNbJp7rZJFR2V-HFU1GJDm3YFTUVmYExkOU,263
|
134
134
|
sonusai/vars.py,sha256=m8pdgfR4A6A9TCGf_rok6jPAT5BgrEsYXTSISIh1nrI,1163
|
135
|
-
sonusai-1.0.
|
136
|
-
sonusai-1.0.
|
137
|
-
sonusai-1.0.
|
138
|
-
sonusai-1.0.
|
135
|
+
sonusai-1.0.4.dist-info/METADATA,sha256=zoOsV6OKVVFihoDmuEyN9mDCLoNPww_3WdB3d-YsJ3Y,2652
|
136
|
+
sonusai-1.0.4.dist-info/WHEEL,sha256=RaoafKOydTQ7I_I3JTrPCg6kUmTgtm4BornzOqyEfJ8,88
|
137
|
+
sonusai-1.0.4.dist-info/entry_points.txt,sha256=zMNjEphEPO6B3cD1GNpit7z-yA9tUU5-j3W2v-UWstU,92
|
138
|
+
sonusai-1.0.4.dist-info/RECORD,,
|
File without changes
|
File without changes
|