Spaces:
Running
on
Zero
Running
on
Zero
Upload mod.py
Browse files
mod.py
CHANGED
@@ -73,7 +73,7 @@ def get_repo_safetensors(repo_id: str):
|
|
73 |
api = HfApi(token=HF_TOKEN)
|
74 |
try:
|
75 |
tag = "None"
|
76 |
-
if not is_repo_name(repo_id) or not is_repo_exists(repo_id): return gr.update(value="", choices=[]),
|
77 |
files = api.list_repo_files(repo_id=repo_id)
|
78 |
model_card = ModelCard.load(repo_id, token=HF_TOKEN)
|
79 |
tag = model_card.data.get("instance_prompt", "")
|
|
|
73 |
api = HfApi(token=HF_TOKEN)
|
74 |
try:
|
75 |
tag = "None"
|
76 |
+
if not is_repo_name(repo_id) or not is_repo_exists(repo_id): return gr.update(value="", choices=[]), gr.update()
|
77 |
files = api.list_repo_files(repo_id=repo_id)
|
78 |
model_card = ModelCard.load(repo_id, token=HF_TOKEN)
|
79 |
tag = model_card.data.get("instance_prompt", "")
|