Omnibus commited on
Commit
838b0a0
1 Parent(s): efb5973

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -5
app.py CHANGED
@@ -29,16 +29,16 @@ client_z=[]
29
  def load_models(inp):
30
  print(type(inp))
31
  print(inp)
 
32
  client_z.clear()
33
  if inp[0]:
34
- client_z[0]=InferenceClient(models[inp[0]])
35
-
36
  if inp[1]:
37
- client_z[1]=InferenceClient(models[inp[1]])
38
  if inp[2]:
39
- client_z[2]=InferenceClient(models[inp[2]])
40
  if inp[3]:
41
- client_z[3]=InferenceClient(models[inp[3]])
42
  return gr.update(label=models[inp[0]])
43
 
44
 
 
29
  def load_models(inp):
30
  print(type(inp))
31
  print(inp)
32
+ print(models[inp[0]])
33
  client_z.clear()
34
  if inp[0]:
35
+ client_z.append(InferenceClient(models[inp[0]]))
 
36
  if inp[1]:
37
+ client_z.append(InferenceClient(models[inp[1]]))
38
  if inp[2]:
39
+ client_z.append(InferenceClient(models[inp[2]]))
40
  if inp[3]:
41
+ client_z.append(InferenceClient(models[inp[3]]))
42
  return gr.update(label=models[inp[0]])
43
 
44