John6666 commited on
Commit
6b3ca21
β€’
1 Parent(s): c5df0f6

Upload 2 files

Browse files
Files changed (2) hide show
  1. app.py +1 -0
  2. multit2i.py +1 -1
app.py CHANGED
@@ -106,6 +106,7 @@ with gr.Blocks(theme="NoCrypt/miku@>=1.2.2", fill_width=True, css=css) as demo:
106
  """
107
  )
108
  gr.DuplicateButton(value="Duplicate Space")
 
109
 
110
  gr.on(triggers=[run_button.click, prompt.submit, random_button.click], fn=lambda: gr.update(interactive=True), inputs=None, outputs=stop_button, show_api=False)
111
  model_name.change(change_model, [model_name], [model_info], queue=False, show_api=False)\
 
106
  """
107
  )
108
  gr.DuplicateButton(value="Duplicate Space")
109
+ gr.Markdown(f"Just a few edits to *model.py* are all it takes to complete your own collection.")
110
 
111
  gr.on(triggers=[run_button.click, prompt.submit, random_button.click], fn=lambda: gr.update(interactive=True), inputs=None, outputs=stop_button, show_api=False)
112
  model_name.change(change_model, [model_name], [model_info], queue=False, show_api=False)\
multit2i.py CHANGED
@@ -180,7 +180,7 @@ def load_model_api(model_name: str):
180
  try:
181
  client = InferenceClient(timeout=5)
182
  status = client.get_model_status(model_name)
183
- if status is None or status.framework != "diffusers" or not status.state in ["Loadable", "Loaded"]:
184
  print(f"Failed to load by API: {model_name}")
185
  return None
186
  else:
 
180
  try:
181
  client = InferenceClient(timeout=5)
182
  status = client.get_model_status(model_name)
183
+ if status is None or status.framework != "diffusers" or status.state not in ["Loadable", "Loaded"]:
184
  print(f"Failed to load by API: {model_name}")
185
  return None
186
  else: