Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -16,7 +16,7 @@ def generate_ad_post(image):
|
|
16 |
image = Image.fromarray(image)
|
17 |
|
18 |
# Более конкретный текст запроса для генерации рекламного поста
|
19 |
-
inputs = florence_processor(text="describe this image
|
20 |
generated_ids = florence_model.generate(
|
21 |
input_ids=inputs["input_ids"],
|
22 |
pixel_values=inputs["pixel_values"],
|
|
|
16 |
image = Image.fromarray(image)
|
17 |
|
18 |
# Более конкретный текст запроса для генерации рекламного поста
|
19 |
+
inputs = florence_processor(text="describe absolutely all the details are in this image. ", images=image, return_tensors="pt").to(device)
|
20 |
generated_ids = florence_model.generate(
|
21 |
input_ids=inputs["input_ids"],
|
22 |
pixel_values=inputs["pixel_values"],
|