Spaces:
Running
Running
Update fluxai.py
Browse files
fluxai.py
CHANGED
@@ -139,7 +139,7 @@ async def fluxai_image(payload: FluxAI):
|
|
139 |
enhanced_image_bytes = "akeno.jpg"
|
140 |
image.save(enhanced_image_bytes, format="JPEG", quality=95)
|
141 |
with open(enhanced_image_bytes, "rb") as image_file:
|
142 |
-
encoded_string = base64.b64encode(image_file.read())
|
143 |
|
144 |
example_test = "Accurately identify the baked good in the image and provide an appropriate and recipe consistent with your analysis."
|
145 |
x = GeminiLatest(api_keys=GOOGLE_API_KEY)
|
|
|
139 |
enhanced_image_bytes = "akeno.jpg"
|
140 |
image.save(enhanced_image_bytes, format="JPEG", quality=95)
|
141 |
with open(enhanced_image_bytes, "rb") as image_file:
|
142 |
+
encoded_string = base64.b64encode(image_file.read()).decode('utf-8')
|
143 |
|
144 |
example_test = "Accurately identify the baked good in the image and provide an appropriate and recipe consistent with your analysis."
|
145 |
x = GeminiLatest(api_keys=GOOGLE_API_KEY)
|