Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -13,7 +13,7 @@ def generate_caption_fuyu(image_path, caption_bool):
|
|
| 13 |
try:
|
| 14 |
from gradio_client import Client
|
| 15 |
|
| 16 |
-
client = Client("
|
| 17 |
result = client.predict(
|
| 18 |
image_path,
|
| 19 |
caption_bool,
|
|
@@ -29,7 +29,7 @@ def generate_answer_fuyu(image_path, question):
|
|
| 29 |
try:
|
| 30 |
from gradio_client import Client
|
| 31 |
|
| 32 |
-
client = Client("
|
| 33 |
result = client.predict(
|
| 34 |
image_path,
|
| 35 |
question,
|
|
@@ -45,7 +45,7 @@ def generate_answer_fuyu(image_path, question):
|
|
| 45 |
|
| 46 |
def generate_caption_kosmos(image_path, caption_bool):
|
| 47 |
|
| 48 |
-
client = Client("
|
| 49 |
try:
|
| 50 |
if caption_bool:
|
| 51 |
caption = "Detailed"
|
|
@@ -64,7 +64,7 @@ def generate_answer_kosmos(image_path, question):
|
|
| 64 |
try:
|
| 65 |
from gradio_client import Client
|
| 66 |
|
| 67 |
-
client = Client("
|
| 68 |
result = client.predict(
|
| 69 |
image_path,
|
| 70 |
None,
|
|
|
|
| 13 |
try:
|
| 14 |
from gradio_client import Client
|
| 15 |
|
| 16 |
+
client = Client("adept/fuyu-8b-demo")
|
| 17 |
result = client.predict(
|
| 18 |
image_path,
|
| 19 |
caption_bool,
|
|
|
|
| 29 |
try:
|
| 30 |
from gradio_client import Client
|
| 31 |
|
| 32 |
+
client = Client("adept/fuyu-8b-demo")
|
| 33 |
result = client.predict(
|
| 34 |
image_path,
|
| 35 |
question,
|
|
|
|
| 45 |
|
| 46 |
def generate_caption_kosmos(image_path, caption_bool):
|
| 47 |
|
| 48 |
+
client = Client("merve/kosmos2")
|
| 49 |
try:
|
| 50 |
if caption_bool:
|
| 51 |
caption = "Detailed"
|
|
|
|
| 64 |
try:
|
| 65 |
from gradio_client import Client
|
| 66 |
|
| 67 |
+
client = Client("merve/kosmos2")
|
| 68 |
result = client.predict(
|
| 69 |
image_path,
|
| 70 |
None,
|