Spaces:
Runtime error
Runtime error
Update app/services/image_service.py
Browse files
app/services/image_service.py
CHANGED
|
@@ -119,7 +119,7 @@ def update_image_with_text(text_instruction: str, image_bytes: bytes) -> tuple[O
|
|
| 119 |
|
| 120 |
try:
|
| 121 |
response = genai_client.models.generate_content(
|
| 122 |
-
model="gemini-2.
|
| 123 |
contents=[text_instruction, image],
|
| 124 |
config=generation_config
|
| 125 |
)
|
|
@@ -168,7 +168,7 @@ def virtual_try_on(dress_image_bytes: bytes, person_image_bytes: bytes) -> tuple
|
|
| 168 |
try:
|
| 169 |
config = types.GenerateContentConfig(response_modalities=["Text", "Image"])
|
| 170 |
response = genai_client1.models.generate_content(
|
| 171 |
-
model="gemini-2.
|
| 172 |
contents=[VIRTUAL_TRY_ON_PROMPT, dress_image, person_image],
|
| 173 |
config=config
|
| 174 |
)
|
|
@@ -234,7 +234,7 @@ Details:
|
|
| 234 |
|
| 235 |
try:
|
| 236 |
response = genai_client.models.generate_content(
|
| 237 |
-
model="gemini-2.
|
| 238 |
contents=shoe_prompt,
|
| 239 |
config=config
|
| 240 |
)
|
|
|
|
| 119 |
|
| 120 |
try:
|
| 121 |
response = genai_client.models.generate_content(
|
| 122 |
+
model="gemini-2.5-flash-image",
|
| 123 |
contents=[text_instruction, image],
|
| 124 |
config=generation_config
|
| 125 |
)
|
|
|
|
| 168 |
try:
|
| 169 |
config = types.GenerateContentConfig(response_modalities=["Text", "Image"])
|
| 170 |
response = genai_client1.models.generate_content(
|
| 171 |
+
model="gemini-2.5-flash-image",
|
| 172 |
contents=[VIRTUAL_TRY_ON_PROMPT, dress_image, person_image],
|
| 173 |
config=config
|
| 174 |
)
|
|
|
|
| 234 |
|
| 235 |
try:
|
| 236 |
response = genai_client.models.generate_content(
|
| 237 |
+
model="gemini-2.5-flash-image",
|
| 238 |
contents=shoe_prompt,
|
| 239 |
config=config
|
| 240 |
)
|