Generate Photos Of Yourself In Different Cities & Different Fancy Suits With SDXL DreamBooth Training For Free
Tags: sdxl, dreambooth, stablediffusion, ai
Published: 2023-12-27 23:30:05

<p>To train this model I have used Stable Diffusion XL (SDXL) 1.0 Base model. I still find base model best for realism.</p>

<p>I used the configuration I shared here currently. It has been discovered after 120 different full trainings experimentation :&nbsp;<a href="https://www.patreon.com/posts/very-best-for-of-89213064" rel="noopener ugc nofollow" target="_blank"><strong>https://www.patreon.com/posts/very-best-for-of-89213064</strong></a></p>

<p>Hopefully I will make a full big tutorial of DreamBooth training and show all the settings.</p>

<p>For training Kohya SS GUI is used. If you don&rsquo;t know how to install and use Kohya SS GUI here the tutorial you need &gt;&nbsp;<a href="https://youtu.be/sBFGitIvD2A" rel="noopener ugc nofollow" target="_blank"><strong>https://youtu.be/sBFGitIvD2A</strong></a></p>

<p>And here is the tutorial that shows how to use shared configuration both on Windows and RunPod &gt;&nbsp;<a href="https://www.youtube.com/watch?v=EEV8RPohsbw" rel="noopener ugc nofollow" target="_blank"><strong>https://www.youtube.com/watch?v=EEV8RPohsbw</strong></a></p>

{% embed https://www.youtube.com/watch?v=EEV8RPohsbw %}

<p>&nbsp;</p>

<p>If you are&nbsp;<strong>not my Patreon supporter</strong>&nbsp;currently I have full public tutorial for LoRA training of SDXL that requires 12 GB VRAM &gt;&nbsp;<a href="https://youtu.be/sBFGitIvD2A" rel="noopener ugc nofollow" target="_blank"><strong>https://youtu.be/sBFGitIvD2A</strong></a></p>

<p>If you don&rsquo;t have a strong GPU and PC you can use Free Kaggle notebook for SDXL DreamBooth training &gt;&nbsp;<a href="https://youtu.be/16-b1AjvyBE" rel="noopener ugc nofollow" target="_blank"><strong>https://youtu.be/16-b1AjvyBE</strong></a></p>

<p>So I used the below images as training images dataset.</p>

<p>This training dataset is at best medium quality because it has repeating backgrounds, repeating clothing and missing fully body pose. All these causes overtraining and lesser generalization.</p>

<p><img alt="" src="https://miro.medium.com/v2/resize:fit:875/1*UDQgkWt1IevNLyUSCSx2aw.png" style="height:185px; width:700px" /></p>

<p>Then for training configuration I did the following.</p>

<p>When training with regularization images, I did 1 epoch and 150 repeating. So more regularization images are used. And saved checkpoints at every 30 epochs. To make it that way calculate the number of steps you need to save. It is easy. 15 * 30 * 2 + 1</p>

<p>The images are generated from epoch 150 so it is a little bit overtrained.</p>

<p>I have used ultra high quality manually picked Unsplash real images having man dataset as regularization images dataset. This means they were ground truth regularization images like how Stable Diffusion was initially trained.</p>

<p>You can download dataset from &gt;&nbsp;<a href="https://www.patreon.com/posts/massive-4k-woman-87700469" rel="noopener ugc nofollow" target="_blank"><strong>https://www.patreon.com/posts/massive-4k-woman-87700469</strong></a></p>

<p>5200 images for both man and woman. Perfect quality cropped and resized to many common resolutions.</p>

<p><img alt="" src="https://miro.medium.com/v2/resize:fit:875/1*-R_vx1C_FjdJceD6P6wSGA.png" style="height:340px; width:700px" /></p>

<p>All training images and reg images were 1024x1024 pixels.</p>

<p>Used dynamic prompting so multiple color suits are generated.</p>

<p>Used prompts are as below.</p>

<p><strong>Positive</strong></p>

<blockquote>
<p>ohwx:0.98 man slightly smiling wearing and wearing an expensive {red|blue|white|black|brown|gold} suit , photoshoot in a sunny day in a city , hd, hdr, uhd, 2k, 4k, 8k</p>
</blockquote>

<p><strong>Negative</strong></p>

<blockquote>
<p>sunglasses, illustration, 3d, 2d, painting, cartoons, sketch, squinting eyes, blurry</p>
</blockquote>

<p>In the after detailer (ADetailer) the following settings are used.</p>

<p><strong>Prompt</strong></p>

<blockquote>
<p>photo of ohwx man slightly smiling</p>
</blockquote>

<p>0.7 denoiose and 29 steps. Rest are default.</p>

<p>Here below full png info</p>

<pre>
parameters

ohwx:0.98 man slightly smiling wearing and wearing an expensive gold suit , photoshoot in a sunny day in a city , hd, hdr, uhd, 2k, 4k, 8k,
Negative prompt: sunglasses, illustration, 3d, 2d, painting, cartoons, sketch, squinting eyes, blurry
Steps: 20, Sampler: DPM++ 2M SDE Karras, CFG scale: 7, Seed: 744692608, Size: 1024x1024, Model hash: eef545047f, Model: me15img_150repeat, ADetailer model: face_yolov8n.pt, ADetailer prompt: photo of ohwx man slightly smiling, ADetailer confidence: 0.3, ADetailer mask only top k largest: 1, ADetailer dilate erode: 4, ADetailer mask blur: 4, ADetailer denoising strength: 0.7, ADetailer inpaint only masked: True, ADetailer inpaint padding: 32, ADetailer use separate steps: True, ADetailer steps: 29, ADetailer version: 23.11.1, Version: v1.7.0-133-gde03882d</pre>

<p>And here the results.</p>

<p><img alt="" src="https://miro.medium.com/v2/resize:fit:1250/1*7idf6CZGiVg21H6O2C9Ofw.png" style="height:1000px; width:1000px" /></p>

<p><img alt="" src="https://miro.medium.com/v2/resize:fit:1250/1*Y0JGf84Zh-rg3a1owE_EeQ.png" style="height:1000px; width:1000px" /></p>

<p><img alt="" src="https://miro.medium.com/v2/resize:fit:875/1*SqZUJzvGPUGuryN0d4Px1Q.png" style="height:700px; width:700px" /></p>

<p><img alt="" src="https://miro.medium.com/v2/resize:fit:1250/1*22lVY7NTwo6Em4MAH9RarQ.png" style="height:1000px; width:1000px" /></p>

<p><img alt="" src="https://miro.medium.com/v2/resize:fit:1250/1*dEXz0t6sTuhdA2wWZixb0w.png" style="height:1000px; width:1000px" /></p>

<p><img alt="" src="https://miro.medium.com/v2/resize:fit:875/1*jgKHdPNBhrNcTHpzJJKxRA.png" style="height:700px; width:700px" /></p>

<p><img alt="" src="https://miro.medium.com/v2/resize:fit:1250/1*DEJcGIttQEDiXYb93Hek-A.png" style="height:1000px; width:1000px" /></p>

<p><img alt="" src="https://miro.medium.com/v2/resize:fit:1250/1*qlKvNKLuSzgaNoqr52cbRg.png" style="height:1000px; width:1000px" /></p>

<p><img alt="" src="https://miro.medium.com/v2/resize:fit:875/1*nF6NZFAWSJds1oIeN2NHJg.png" style="height:700px; width:700px" /></p>

<p><img alt="" src="https://miro.medium.com/v2/resize:fit:1250/1*kS40t5dCLuoiHlD39UwU9w.png" style="height:1000px; width:1000px" /></p>

<p><img alt="" src="https://miro.medium.com/v2/resize:fit:1250/1*cwDn9qg6Eiz0Xxoy5ZbpmA.png" style="height:1000px; width:1000px" /></p>

<p><img alt="" src="https://miro.medium.com/v2/resize:fit:875/1*9ZKzt8nYnqmUWSktm9DiXg.png" style="height:700px; width:700px" /></p>

<p><img alt="" src="https://miro.medium.com/v2/resize:fit:1250/1*J5I6Sgw6BA8MnAcLasV-Tg.png" style="height:1000px; width:1000px" /></p>

<p><img alt="" src="https://miro.medium.com/v2/resize:fit:1250/1*39V5pbNnnbfR6YsptQqE4A.png" style="height:1000px; width:1000px" /></p>

<p><img alt="" src="https://miro.medium.com/v2/resize:fit:875/1*sk_hwsMXobf4hKtiXVXvfQ.png" style="height:700px; width:700px" /></p>

<p><img alt="" src="https://miro.medium.com/v2/resize:fit:1250/1*W4rCZmhOopCiMaUIue-7YA.png" style="height:1000px; width:1000px" /></p>

<p><img alt="" src="https://miro.medium.com/v2/resize:fit:1250/1*FeR_T8D6ZCsVWzArupKN8g.png" style="height:1000px; width:1000px" /></p>

<p><img alt="" src="https://miro.medium.com/v2/resize:fit:875/1*1w4pyNPQZedd6bpE4q2QCg.png" style="height:700px; width:700px" /></p>

<p><img alt="" src="https://miro.medium.com/v2/resize:fit:1250/1*DYD3FncK1JJEEvbALcHNMQ.png" style="height:1000px; width:1000px" /></p>

<p><img alt="" src="https://miro.medium.com/v2/resize:fit:875/1*89CZzxVAG9wE6k9TlEq12w.png" style="height:700px; width:700px" /></p>