Spaces:
Runtime error
Runtime error
Shrirang20
commited on
Commit
•
b8b18f8
1
Parent(s):
03cacd6
Update app.py
Browse files
app.py
CHANGED
@@ -23,14 +23,19 @@ import subprocess
|
|
23 |
import sys
|
24 |
|
25 |
print("CURRENT WORKING DIRECTORY:",os.getcwd())
|
26 |
-
|
27 |
-
os.
|
28 |
-
os.
|
29 |
-
|
30 |
-
os.
|
31 |
-
|
32 |
-
|
33 |
-
os.
|
|
|
|
|
|
|
|
|
|
|
34 |
|
35 |
# Commented out IPython magic to ensure Python compatibility.
|
36 |
# %%capture
|
|
|
23 |
import sys
|
24 |
|
25 |
print("CURRENT WORKING DIRECTORY:",os.getcwd())
|
26 |
+
setup_flag = 'setup_complete.flag'
|
27 |
+
if not os.path.exists(setup_flag):
|
28 |
+
os.system('wget https://indic-asr-public.objectstore.e2enetworks.net/ai4b_nemo.zip')
|
29 |
+
os.system('unzip -q ai4b_nemo.zip')
|
30 |
+
os.chdir('NeMo')
|
31 |
+
subprocess.run([sys.executable, '-m', 'pip', 'install', '-e', '.'])
|
32 |
+
os.system('bash reinstall.sh')
|
33 |
+
os.chdir('..')
|
34 |
+
|
35 |
+
with open(setup_flag, 'w') as f:
|
36 |
+
f.write('Setup complete')
|
37 |
+
|
38 |
+
os.execv(sys.executable, ['python'] + sys.argv)
|
39 |
|
40 |
# Commented out IPython magic to ensure Python compatibility.
|
41 |
# %%capture
|