[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
This commit is contained in:
parent
bec81b882d
commit
b8152a5cec
1 changed files with 3 additions and 1 deletions
|
|
@ -2399,7 +2399,9 @@ async def diffusion_generate(
|
|||
# vae_scale_factor * 2 multiples internally, so the actual PNG can
|
||||
# differ from the requested dims. Report the real image size so
|
||||
# the metadata caption matches the bytes on the wire.
|
||||
actual_w, actual_h = (image.size if hasattr(image, "size") else (payload.width, payload.height))
|
||||
actual_w, actual_h = (
|
||||
image.size if hasattr(image, "size") else (payload.width, payload.height)
|
||||
)
|
||||
return DiffusionGenerateResponse(
|
||||
image_b64 = encode_png_base64(image),
|
||||
image_mime = "image/png",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue