Skip to content

Commit

Permalink
fix(api): remove inpaint post-multiply (#150)
Browse files Browse the repository at this point in the history
  • Loading branch information
ssube committed Feb 15, 2023
1 parent df5fb93 commit b5eeb44
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 9 deletions.
6 changes: 3 additions & 3 deletions api/logging.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,14 @@ formatters:
handlers:
console:
class: logging.StreamHandler
level: DEBUG
level: INFO
formatter: simple
stream: ext://sys.stdout
loggers:
'':
level: DEBUG
level: INFO
handlers: [console]
propagate: True
root:
level: DEBUG
level: INFO
handlers: [console]
7 changes: 1 addition & 6 deletions api/onnx_web/diffusion/run.py
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,7 @@ def run_inpaint_pipeline(
# calling the upscale_outpaint stage directly needs accumulating progress
progress = ChainProgress.from_progress(progress)

logger.debug("applying mask filter and generating noise source")
image = upscale_outpaint(
job,
server,
Expand All @@ -190,12 +191,6 @@ def run_inpaint_pipeline(
noise_source=noise_source,
callback=progress,
)
logger.info("applying mask filter and generating noise source")

if image.size == source_image.size:
image = ImageChops.blend(source_image, image, strength)
else:
logger.info("output image size does not match source, skipping post-blend")

image = run_upscale_correction(
job, server, stage, params, image, upscale=upscale, callback=progress
Expand Down

0 comments on commit b5eeb44

Please sign in to comment.