Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -4,7 +4,7 @@ from gradio_client import Client
|
|
4 |
|
5 |
MY_HF_TOKEN_KEY = os.environ["MY_HF_TOKEN_KEY"]
|
6 |
|
7 |
-
client = Client("Ghana-NLP/Khaya-image-caption-backend-infer-api",hf_token=MY_HF_TOKEN_KEY)
|
8 |
|
9 |
def generate(filepath,language):
|
10 |
output = client.predict(filepath,language,api_name="/predict")
|
|
|
4 |
|
5 |
MY_HF_TOKEN_KEY = os.environ["MY_HF_TOKEN_KEY"]
|
6 |
|
7 |
+
client = Client("Ghana-NLP/Khaya-image-caption-backend-infer-api",hf_token=MY_HF_TOKEN_KEY,upload_files=True)
|
8 |
|
9 |
def generate(filepath,language):
|
10 |
output = client.predict(filepath,language,api_name="/predict")
|