humair025/kikiri-tts-urdu-pipeline main
Module built on the numeric Python stackImports the NumPy array library
SHA-2567f62605f2c77bf306d2bb48c80cc09a90670050393e6bf41728a4dfb99ffb69b
MaleculeH₂(DbOs)
Evidence
1"""
2monotonic_align — pure-Python fallback for the Cython `monotonic_align` package
3used by StyleTTS2's `utils.py`.
4
5Provides:
6 - maximum_path(ne …
8:15… um_path_c — alias to maximum_path (for compat with utils.py imports)
9
10The Cython version from resemble-ai/monotonic_align is faster, but this
11numpy fallback gives identical results and works on machines without
12a Cython compiler.
13"""
14import numpy as np
15import torch
16
⋯6 lines
44:11… = np.full((T, S), -np.inf, dtype=np.float32)
45 backptr = np.zeros((T, S), dtype=np.int32)
46 # Initialize first row.
47 dp[0, :] = np.cumsum(nc[0, :])
48 for j in range(S):
49 …
125:13… eSubpackage()
126_core.maximum_path_c = _CoreModule.maximum_path_c
127sys.modules[__name__ + ".core"] = _core
1"""
2monotonic_align — pure-Python fallback for the Cython `monotonic_align` package
3used by StyleTTS2's `utils.py`.
4
5Provides:
6 - maximum_path(ne …
8:15… um_path_c — alias to maximum_path (for compat with utils.py imports)
9
10The Cython version from resemble-ai/monotonic_align is faster, but this
11numpy fallback gives identical results and works on machines without
12a Cython compiler.
13"""
14import numpy as np
15import torch
16
⋯6 lines
44:11… = np.full((T, S), -np.inf, dtype=np.float32)
45 backptr = np.zeros((T, S), dtype=np.int32)
46 # Initialize first row.
47 dp[0, :] = np.cumsum(nc[0, :])
48 for j in range(S):
49 …
125:13… eSubpackage()
126_core.maximum_path_c = _CoreModule.maximum_path_c
127sys.modules[__name__ + ".core"] = _core