Skip to content

Commit b2f7a8d

Browse files
committed
debug
1 parent 283a5db commit b2f7a8d

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

modules/api/api.py

+4
Original file line numberDiff line numberDiff line change
@@ -134,6 +134,7 @@ def decode_base64_to_image(encoding):
134134

135135

136136
def set_img_exif_dict():
137+
print("***&&& set_img_exif_dict Writing exif")
137138
title = "AIRI"
138139
date_taken = "2001:01:01 01:01:01"
139140
global user_input_data
@@ -197,9 +198,11 @@ def set_img_exif_dict():
197198

198199

199200
def encode_pil_to_base64(image):
201+
print("***&&& encode_pil_to_base64")
200202
with io.BytesIO() as output_bytes:
201203

202204
if opts.samples_format.lower() == 'png':
205+
print("***&&& encode_pil_to_base64 PNG")
203206
use_metadata = False
204207
metadata = PngImagePlugin.PngInfo()
205208
for key, value in image.info.items():
@@ -209,6 +212,7 @@ def encode_pil_to_base64(image):
209212
image.save(output_bytes, format="PNG", pnginfo=(metadata if use_metadata else None), quality=opts.jpeg_quality)
210213

211214
elif opts.samples_format.lower() in ("jpg", "jpeg", "webp"):
215+
print("***&&& encode_pil_to_base64 JPG")
212216
if image.mode == "RGBA":
213217
image = image.convert("RGB")
214218
# parameters = image.info.get('parameters', None)

0 commit comments

Comments
 (0)