The Very Best OneTrainer Workflow & Config For SD 1.5 Based Models DreamBooth / Full Fine Tuning (Patreon)
Downloads
Content
Join discord and tell me your discord username to get a special rank : SECourses Discord
30 March 2024 Update:
Compared Tier 1 vs Tier 2 quality : https://www.reddit.com/r/StableDiffusion/comments/1br8iyz/compared_my_best_sd_15_config_to_the_newest_7gb/
CONCLUSION : There aren't any noticeable difference between Tier 1 and Tier 2. So use the fastest one according to your GPU VRAM.
28 March 2024 Update:
Please watch this tutorial to learn how to use presets and set concepts : https://youtu.be/yPOadldf6bI
New preset updates
These presets are set to 200 epoch by default and saves a checkpoint every 25 epochs
The difference between Tier 1 and Tier 2 is Attention. Tier 1 uses Default attention and Tier 2 uses xFormers. How much difference it makes is : I am still testing
So what makes speed difference?
Put EMA on CPU or GPU - GPU faster
Enable Gradient Checkpointing or not - Enabling make it slower
Enable Fused Back Pass or not on Adafactor - Enabling make it slower
tier1_SD15_slowest_16.5GB.json : Uses 16 GB VRAM and 2.62 second / it on RTX 3060
tier1_SD15_slow_18.3GB.json : Uses 18.3 GB VRAM and 1.29 second / it on RTX 3060
tier1_SD15_fast_26GB.json and tier1_SD15_fastest_48GB.json uses more than 24 GB
tier2_SD15_slowest_7GB.json : Uses 7 GB VRAM and 5.14 second / it on RTX 3060
tier2_SD15_slower_10.8GB.json : Uses 10.8 GB VRAM and 3.10 second / it on RTX 3060
tier2_SD15_slow_14GB.json : Uses 14 GB VRAM and 1.17 second / it on RTX 3090 TI
tier2_SD15_fast_15GB.json : Uses 145 GB VRAM and 1.03 second / it on RTX 3090 TI
22 March 2024 Update:
All configs are updated and Stochastic Rounding disabled
Stochastic Rounding makes the effect of like FP32 - float training
However, float like training causes overtraining with our currently found best hyper parameters
Therefore, for now, they are disabled until a better hyperparameters are researched and found
How to use these configs quick tutorial : https://www.youtube.com/watch?v=yPOadldf6bI
9 February 2024 Update:
Settings are updated for the latest OneTrainer update
You don't need to put optimizer prefs anymore
You can open configs json file and look inside to understand logic of how it works
You need to change workspace_dir, cache_dir, output_model_destination, edit your training concepts
I did set default model as the most realistic SD 1.5 model which is Hyper Realism V3 hosted on Hugging Face (MonsterMMORPG/sd15_best_realism)
You can change model to any model you want from your computer or Hugging Face repo
Hopefully I will make a full tutorial that includes how to train on Windows and RunPod
Clone the repo into any folder : https://github.com/Nerogar/OneTrainer
Double click install .bat
Then double click start-ui .bat to start it
I have made over 70 full DreamBooth trainings for over 7 days and meticulously analyzed their results to the find very best training hyper parameters.
120 amazing quality images with their prompt info posted on CivitAI
Part 1 , Part 2 , Part 3 , Part 4 , Part 5 , Part 6 . Each Part has 20 images. You can click (i) icon on images to see their prompts.
We have 3 configs.
The configs will not save checkpoints during training but will only save a final checkpoint. Don't forget to change that behaviour or fix your final checkpoint path.
Tier 1 is best quality. Don't use xFormers.
Tier 2 is second best quality. Uses xFormers to reduce VRAM.
All Tier 2 are equal quality and only speed and VRAM usage changes.
xFormers : reduces VRAM, increases speed, reduced quality
Gradient Checkpointing : reduces VRAM, reduces speed, quality same
EMA : increases VRAM, reduces speed, improves quality. You can load EMA on both CPU and GPU. If you load on CPU, it will be slower but VRAM will be same.
Since OneTrainer supports EMA, it is better than Kohya.
Kohya config : https://www.patreon.com/posts/97379147
There are 2 strategies of training. Stylized vs Realism.
To find out very best models for both realism and stylization models, I have made 161 models comparison recently if you remember : https://youtu.be/G-oZn4H-aHQ
Models Downloader Script And The Patreon Post Shown In The Video ⤵️ https://www.patreon.com/posts/1-click-download-96666744
1st:
Training for realism. For this training strategy I have chosen the Hyper Realism V3 model from CivitAI. The config file will download it automatically from Hugging Face or alternatively you can give the local path.
2nd:
Training for stylization like 3d render of yourself. For this task I have chosen RealCartoon-Pixar V8 from CivitAI.
To use this model the key change you need to make is, making Clip skip 2 in Advanced Settings.
I used 15 training images and trained 150 epoch.
My used training images are as below (they are at best medium quality)
For RealCartoon-Pixar V8 hopefully I will add Regularization images to this post soon.
For realism, use our very best real unsplash collected regularization images ⤵️
https://www.patreon.com/posts/massive-4k-woman-87700469
I trained both 768x768 and 1024x1024. 768x768 training works better than 1024x1024. Moreover, generating 1024x1024 works better than 768x768. When fixing faces with ADetailer extension, make the ADetailer extension resolution 768x768 even if you generate images in 1024x1024.