Add-Vishnu commited on
Commit
d038600
·
1 Parent(s): 7e11d63

running installation command using subprocess

Browse files
Files changed (1) hide show
  1. app.py +12 -4
app.py CHANGED
@@ -16,10 +16,18 @@ perm = subprocess.run(command2, shell=True,stdout=subprocess.PIPE,stderr=subproc
16
  # result = subprocess.run(command, shell=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE, text=True)
17
  # print("Wine Installation: ",wine_c)
18
  print("Access Installation: ",perm)
19
- os.system("apt install sudo")
20
- os.system("sudo dpkg --add-architecture i386")
21
- os.system("sudo apt-get update")
22
- os.system("sudo apt-get install wine32:i386")
 
 
 
 
 
 
 
 
23
 
24
 
25
  def resample_to_16k(audio, orig_sr):
 
16
  # result = subprocess.run(command, shell=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE, text=True)
17
  # print("Wine Installation: ",wine_c)
18
  print("Access Installation: ",perm)
19
+ command3 = "apt install sudo"
20
+ command4 = "sudo dpkg --add-architecture i386"
21
+ command5 = "sudo apt-get update"
22
+ command6 = "sudo apt-get install wine32:i386"
23
+ t1= subprocess.run(command3, shell=True,stdout=subprocess.PIPE,stderr=subprocess.PIPE, text=True)
24
+ t2= subprocess.run(command4, shell=True,stdout=subprocess.PIPE,stderr=subprocess.PIPE, text=True)
25
+ t3= subprocess.run(command5, shell=True,stdout=subprocess.PIPE,stderr=subprocess.PIPE, text=True)
26
+ t4= subprocess.run(command6, shell=True,stdout=subprocess.PIPE,stderr=subprocess.PIPE, text=True)
27
+ print("T1: ",t1)
28
+ print("T2: ",t2)
29
+ print("T3: ",t3)
30
+ print("T4: ",t4)
31
 
32
 
33
  def resample_to_16k(audio, orig_sr):