kaoruhotarubi commited on
Commit
cd21f4a
·
1 Parent(s): 86e4e7d
Files changed (1) hide show
  1. app.py +5 -0
app.py CHANGED
@@ -19,6 +19,11 @@ if not os.path.exists("vits"):
19
  # Add VITS directory to the Python path
20
  sys.path.append("vits")
21
 
 
 
 
 
 
22
  # Import VITS modules
23
  from vits.models import SynthesizerTrn
24
  from vits.utils import load_checkpoint
 
19
  # Add VITS directory to the Python path
20
  sys.path.append("vits")
21
 
22
+ monotonic_align_path = "vits/monotonic_align"
23
+ if not os.path.exists(f"{monotonic_align_path}/monotonic_align/core.so"):
24
+ print("🔧 Compiling monotonic_align...")
25
+ subprocess.run(["python3", "setup.py", "build_ext", "--inplace"], cwd=monotonic_align_path, check=True)
26
+
27
  # Import VITS modules
28
  from vits.models import SynthesizerTrn
29
  from vits.utils import load_checkpoint