Ad Photos With SDXL v1

Download as pdf or txt
Download as pdf or txt
You are on page 1of 6

Advertising Photos with Invoke AI 3.1.

Hi there, my name is Daniel Schweinert and Im a commercial photographer & technerd based in
Bavaria, Germany. I started to play with Stable Di usion since last year in 2022 and I’m really
impressed what this technology can do. Since then I’ve always wanted to use AI in my
professional work ow. If you want to check my work you’re welcome: www.schweinert.com
Without further ado, let’s get started.

How to create realistic advertising photos in Invoke AI with matching backgrounds?

In a nutshell:

We use a real photo of a person or object and remove the background. Then we save it as a PNG
le with transparent background. In Invoke AI 3.1.0 we drop it into the Uni ed Canvas adjust
some settings add a Control Net and let the AI create matching backgrounds based on our PNG
le and prompt.

1. Take your favorite image editing app (Photoshop, A nity, Gimp, etc.) and thoroughly remove
the background from your photo. Important - crop it so you get a square, 1:1 aspect ratio. (It
works with di erent aspect ratios too but right now this way it’s easier to overlap the Control
Net image, later on). On step 7 I will show you how to create di erent aspect ratios.

If using SDXL models, resize your PNG le to 1024x1024px.


For SD 1.5 models resize it to 768x768px.

Advertising Photos with SDXL & SD1.5 Page 1 of 6 www.schweinert.com


fi
fi
ff
fl
fi
ff
ffi
ff
fi
2. With Invoke AI 3.1.0 open, drag and drop your PNG le on the canvas. This adds it to the
assets folder in the image browser on the right side. Right click on it and select “Send To
Uni ed Canvas”.

3. In the Uni ed Canvas make a bounding box the same size as your PNG image (1024x1024px
or 768x768px). It should be pretty easy by using the “snap to grid” setting. Now center your
bounding box around your object. If it is o -centre the Control Net will produce later a
duplicate bottle next to it. So it needs to overlap correctly.

4. Let’s create a prompt and adjust some settings:

Positive prompt:
RAW photo of a whisky bottle surrounded by grass, autumn, brown leaves lying around,
landscape photography, award winning photo, masterpiece, highly detailed, cinematic lighting

Negative prompt:
(3d render), cgi, cartoon, anime, painting, (3d modeling), crayon

Model:
When using SD1.5 models I noticed that I get better results when using special “INPAINTING”
models. They tend to integrate the PNG object way better into the scene. But with the newer
models like RealisticVision 5.1, CyberRealistic3.3, AbsoluteReality_v1.8.1, etc. the normal
ones work also great. Try it for yourself and see which produces better results.

For SDXL I found Crystal Clear XL, Juggernaut XL and NightVision XL worked fantastic!

Advertising Photos with SDXL & SD1.5 Page 2 of 6 www.schweinert.com


fi
fi
ff
fi
Denoising Strength: 0.8 - 1.0 (if this is below 0.8 it will produce strange results - somewhat
duplicating details of the “Initial image”). Play around with it and see if you like the outcome.

5. ControlNet:

For SD1.5 models enable ControlNet and select “softedge”. Use the same PNG le as the
control image. Drag and drop it from the assets folder into the small square (don’t use the
new option “import from canvas” or it will mess up your alignment). ControlNet is used to
guide the AI on how to create the bottle. Without ControlNet most of the time it will add a
di erent bottle cap or change the shape of it, etc.

Advertising Photos with SDXL & SD1.5 Page 3 of 6 www.schweinert.com


ff
fi
Weight: 1.0

Begin / End Step Percentage: Set Begin to 0% - 30% < play with the “Begin” value!
When using SD1.5 models it usually stays at 0% but especially with SDXL, I found that all my
backgrounds were blurry and the things that I prompted were not considered at all. When I
increased the percentage to 15%, the prompt had enough time to generate the scene before
the Control Image kicked in. Try di erent values and see what works best for you.

Control Mode: Control


Resize Mode: Fill
Processor: HED

For SDXL enable ControlNet and select “softedge-sd-xl-1.0-dexined”. I don’t know if this is
a bug with this version of the ControlNet model but I have to increase the “Begin Step
Percentage” a little bit, else I always get solid or blurry backgrounds. See the picture
comparison below. You can download the ControlNet models for SDXL from here and add
them through the Model Manager: https://models.invoke.ai/

Control Mode: Prompt


This worked best with SDXL, the other control modes produced strange results.

Hint: Click on the small arrow “Show Advanced” next to the red trash can icon. Set the
“Detect Resolution” to the size of your PNG le 1024x1024px. This produces much better
edges.

The rest of the settings are the same as for SD1.5.

6. In ll and Scaling
Select as “In ll Method” patchmatch or tile. Patchmatch delivers cleaner results around the
edges of the bottle but it takes way longer to process, especially in SDXL. Tile 16-32 is much
faster but it sometimes creates a rough edge around the object that does not look good.

Compositing Settings
Mask Adjustment Blur: 0 (everything above zero produced a bad edge around the bottle)
Coherence Pass Steps 10 (if this value is too big it adds things around the bottle)
Strength 0.15 (if too big it changes the shape of the bottle, if too low the edge looks ugly)

Advertising Photos with SDXL & SD1.5 Page 4 of 6 www.schweinert.com


fi
fi
ff
fi
7. Here is how to create di erent aspect ratios like vertical pictures, panoramas, etc.:
Now that you have experience with the bounding box just try to expand only the width of the
bounding box but the bottle needs to stay in the middle. For SDXL models try a “width” of
768px and up to 1920px. The “height” has to stay at 1024px otherwise the ControlNet image
will be stretched and therefore misaligned. You can still expand the photo later by outpainting.

Btw. the ControlNet Resize Mode should be set to “Fill”.

These were the settings I used to create the images. Feel free to experiment. Depending on your
model try out di erent sampling methods, they will produce quite di erent results - DDIM, Euler A,
DPM++ 2M Karras, DPM++ 2M SDE Karras, etc. If you nd a better work ow or settings, please
let me know, I’m all ears. Happy denoising :-)

Made with di erent SDXL models

Advertising Photos with SDXL & SD1.5 Page 5 of 6 www.schweinert.com


ff
ff
ff
fi
ff
fl
Made with di erent SD1.5 models

Made with different SD1.5 INPAINTING models

Advertising Photos with SDXL & SD1.5 Page 6 of 6 www.schweinert.com


ff

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy