Instructions to use jhtwosuin/sd15-sg-fullft-75k with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use jhtwosuin/sd15-sg-fullft-75k with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("jhtwosuin/sd15-sg-fullft-75k", dtype=torch.bfloat16, device_map="cuda") prompt = "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k" image = pipe(prompt).images[0] - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- Draw Things
- DiffusionBee
SD1.5 full-finetune: guidance-free (GFT) + self-guidance (SG), 75k steps β EMA UNet
Full-finetuned (no LoRA) Stable Diffusion 1.5 UNet that internalizes two guidance signals in a single forward pass:
- rm / gft (guidance-free): CFG scale distilled into the model. Eval knob:
cfg(beta = 1/cfg). - sg (self-guidance): patch-perturbed self-prediction mixing. Eval knob:
alpha.
Both are injected through a doubled time_embedding.cond_proj
(time_cond_proj_dim = 2 x 512 = 1024):
timestep_cond = concat([gse(1/beta - 1), gse(1/alpha - 1)]).
These are the EMA weights (ema_decay 0.9999) from checkpoint-75000.
Training
| item | value |
|---|---|
| init | sd-legacy/stable-diffusion-v1-5 UNet (cond_proj zero-init) |
| data | LAION Aesthetics 5+ subset, 19.1M images, WebDataset |
| steps | 75,000 (fp16, global batch 256, lr 1e-5 constant + 1k warmup) |
| objective | dual-guidance distillation (--rm_guidance --sg_guidance), min_alpha 0.25, mixup_ratio 0.2 |
| alpha range | trained on alpha β [0.25, 1.0] β evaluating below 0.25 is extrapolation |
Usage
The stock StableDiffusionPipeline cannot express the dual (rm, sg) conditioning β
use the custom denoise loop (sample_sg_fullft.py::sg_generate in the training repo),
which does a single UNet forward per step (no CFG doubling):
from diffusers import UNet2DConditionModel
unet = UNet2DConditionModel.from_pretrained("jhtwosuin/sd15-sg-fullft-75k")
# vae / text_encoder / tokenizer / scheduler come frozen from sd-legacy/stable-diffusion-v1-5
# timestep_cond = cat([gse(cfg-1), gse(1/alpha-1)]) ; recommended cfg 7.5, alpha β {0.8, 0.5, 0.25}
Non-EMA weights and full training state (optimizer/EMA shadow) exist separately; ask the author if you need them for training resumption.
- Downloads last month
- 33
Model tree for jhtwosuin/sd15-sg-fullft-75k
Base model
stable-diffusion-v1-5/stable-diffusion-v1-5