Spaces:
Running
Running
imseldrith
commited on
Commit
·
a1f5a00
1
Parent(s):
d65cd03
Update app.py
Browse files
app.py
CHANGED
@@ -67,7 +67,7 @@ def api_generate_image():
|
|
67 |
return jsonify({'error': "An error occurred while upscaling the image."}), 500
|
68 |
|
69 |
try:
|
70 |
-
with open("
|
71 |
img_file.write(img_data)
|
72 |
except Exception as e:
|
73 |
return jsonify({'error': f"An error occurred while writing the image to file: {e}"}), 500
|
|
|
67 |
return jsonify({'error': "An error occurred while upscaling the image."}), 500
|
68 |
|
69 |
try:
|
70 |
+
with open("generated.jpeg", mode="wb") as img_file:
|
71 |
img_file.write(img_data)
|
72 |
except Exception as e:
|
73 |
return jsonify({'error': f"An error occurred while writing the image to file: {e}"}), 500
|