XuminYu commited on
Commit
9450a47
1 Parent(s): 3a7c4cb

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -15
app.py CHANGED
@@ -108,21 +108,7 @@ def predict(prompt, style, audio_file_pth, agree):
108
 
109
  print(f'Get response successfully within {time.time() - start}')
110
 
111
- try:
112
- json_data = json.loads(response)
113
- text_hint += f"[ERROR] {json_data['error']} \n"
114
- gr.Warning(
115
- f"[ERROR] {json_data['error']} \n"
116
- )
117
- return (
118
- text_hint,
119
- None,
120
- None,
121
- )
122
- except:
123
- with open(save_path, 'wb') as f:
124
- f.write(response)
125
-
126
  # Check the response
127
  if response.status_code == 200:
128
  try:
 
108
 
109
  print(f'Get response successfully within {time.time() - start}')
110
 
111
+
 
 
 
 
 
 
 
 
 
 
 
 
 
 
112
  # Check the response
113
  if response.status_code == 200:
114
  try: