From 7610284385ce044dc57d7adcf906ccb9cb3d9145 Mon Sep 17 00:00:00 2001 From: Unsloth Date: Sat, 25 Jul 2026 04:50:08 -0700 Subject: [PATCH] Images Train: shorter copy throughout Family notes, example descriptions, precision labels and every helper line are trimmed so they stop wrapping to three lines and colliding with the next column. The nf4 label now fits its select without truncating. --- .../core/training/diffusion_train_common.py | 23 +++----- studio/backend/routes/training.py | 29 +++------- .../images/train/diffusion-train-panel.tsx | 56 +++++++++---------- 3 files changed, 39 insertions(+), 69 deletions(-) diff --git a/studio/backend/core/training/diffusion_train_common.py b/studio/backend/core/training/diffusion_train_common.py index 5c29a6d23d..e56c3f61d5 100644 --- a/studio/backend/core/training/diffusion_train_common.py +++ b/studio/backend/core/training/diffusion_train_common.py @@ -295,22 +295,13 @@ _FAMILY_LABELS = { "flux.2-dev": "FLUX.2-dev", } _FAMILY_VRAM_NOTES = { - "sdxl": "Trains on ~12 GB+ (bf16 LoRA). The lightest, fastest option.", - "flux.1": ( - "12B model, QLoRA (nf4) by default (~16 GB+). Gated on Hugging Face: accept the " - "FLUX.1-dev license and add your HF token before training." - ), - "qwen-image": "20B model, QLoRA (nf4) by default (~24 GB+). The heaviest option.", - "z-image": "6B model, QLoRA (nf4) by default (~12 GB+). bf16 only.", - "krea-2": ( - "12B model, QLoRA (nf4) by default (~18 GB+). bf16 only. Trains on the " - "undistilled Krea-2-Raw (Krea's guidance: train on Raw, run adapters on Turbo)." - ), - "flux.2-klein": "4B model, QLoRA (nf4) by default (~10 GB+). bf16 only.", - "flux.2-dev": ( - "32B model, QLoRA (nf4) by default (~28 GB+). bf16 only. Gated on Hugging Face: " - "accept the FLUX.2-dev license and add your HF token before training." - ), + "sdxl": "~12 GB+. The lightest option.", + "flux.1": "12B, QLoRA by default (~16 GB+). Gated: needs its license and your HF token.", + "qwen-image": "20B, QLoRA by default (~24 GB+). The heaviest option.", + "z-image": "6B, QLoRA by default (~12 GB+).", + "krea-2": "12B, QLoRA by default (~18 GB+). Trains on Krea-2-Raw, runs on Turbo.", + "flux.2-klein": "4B, QLoRA by default (~10 GB+).", + "flux.2-dev": "32B, QLoRA by default (~28 GB+). Gated: needs its license and your HF token.", } # The flow-matching DiT families (run by diffusion_dit_trainer). They expose the base_precision / diff --git a/studio/backend/routes/training.py b/studio/backend/routes/training.py index f34e2f5059..5b585ae446 100644 --- a/studio/backend/routes/training.py +++ b/studio/backend/routes/training.py @@ -2173,11 +2173,8 @@ _DATASET_EXAMPLES: list[dict] = [ "id": "dreambooth-dog", "label": "Dog (DreamBooth subject)", "repo": "diffusers/dog-example", - "description": ( - "5 photos of one dog. The classic DreamBooth subject set: teach the model a " - "specific subject, then summon it with the trigger prompt." - ), - "license": "Released by Google for DreamBooth research/demos", + "description": "5 photos of one dog. Teach a subject, then call it with the trigger.", + "license": "Google, research and demos", "image_cap": 10, "suggested_trigger": "a photo of sks dog", "loader": "hf_dataset", @@ -2188,10 +2185,7 @@ _DATASET_EXAMPLES: list[dict] = [ "id": "tuxemon", "label": "Tuxemon (captioned style set)", "repo": "linoyts/Tuxemon", - "description": ( - "Captioned cartoon monster art. A good style set: each image ships a caption, " - "so the adapter learns the look without a trigger word." - ), + "description": "Captioned cartoon monster art. A style set, no trigger needed.", "license": "cc-by-sa-3.0", "image_cap": 60, "suggested_trigger": None, @@ -2203,10 +2197,7 @@ _DATASET_EXAMPLES: list[dict] = [ "id": "tarot-1920", "label": "1920 Tarot (public domain style set)", "repo": "multimodalart/1920-raider-waite-tarot-public-domain", - "description": ( - "Public-domain 1920 Raider-Waite tarot art with captions. A permissive style " - "set for demoing captioned LoRA training." - ), + "description": "Captioned 1920 Raider-Waite tarot art. A permissive style set.", "license": "public domain", "image_cap": 60, "suggested_trigger": None, @@ -2218,11 +2209,8 @@ _DATASET_EXAMPLES: list[dict] = [ "id": "smithsonian-butterflies", "label": "Smithsonian Butterflies", "repo": "huggan/smithsonian_butterflies_subset", - "description": ( - "100 butterfly specimen photos. The classic diffusers-docs training set. No " - "captions, so pair it with the trigger prompt to teach a butterfly subject." - ), - "license": "CC0 (Smithsonian Open Access)", + "description": "100 butterfly photos. No captions, so use the trigger prompt.", + "license": "CC0", "image_cap": 100, # The metadata columns are species names / boilerplate alt-text, not captions, so train # it as a subject set with the trigger prompt instead. @@ -2235,10 +2223,7 @@ _DATASET_EXAMPLES: list[dict] = [ "id": "pixel-nouns", "label": "Nouns (pixel avatars)", "repo": "m1guelpf/nouns", - "description": ( - "100 captioned Nouns pixel-art avatars. A captioned style set: each image ships " - "a caption, so the adapter learns the pixel look without a trigger word." - ), + "description": "100 captioned pixel-art avatars. A style set, no trigger needed.", "license": "cc0-1.0", "image_cap": 100, "suggested_trigger": None, diff --git a/studio/frontend/src/features/images/train/diffusion-train-panel.tsx b/studio/frontend/src/features/images/train/diffusion-train-panel.tsx index 14921462ae..5dbc545a7c 100644 --- a/studio/frontend/src/features/images/train/diffusion-train-panel.tsx +++ b/studio/frontend/src/features/images/train/diffusion-train-panel.tsx @@ -77,7 +77,7 @@ const FAMILY_PRESETS: FamilyPreset[] = [ label: "FLUX.1-dev (12B)", base_repos: ["black-forest-labs/FLUX.1-dev"], defaults: { rank: 16, lr: 0.0001, resolution: 512 }, - vram_note: "Needs a free Hugging Face license: accept it on the model page, then add your token.", + vram_note: "Gated: needs its license and your HF token.", gated: true, }, { @@ -85,21 +85,21 @@ const FAMILY_PRESETS: FamilyPreset[] = [ label: "Qwen-Image (20B)", base_repos: ["unsloth/Qwen-Image-2512-unsloth-bnb-4bit", "Qwen/Qwen-Image"], defaults: { rank: 16, lr: 0.00005, resolution: 512 }, - vram_note: "The biggest model: needs a large GPU. Start at 512px.", + vram_note: "The biggest: needs a large GPU. Start at 512px.", }, { name: "z-image", label: "Z-Image-Turbo (6B)", base_repos: ["unsloth/Z-Image-Turbo-unsloth-bnb-4bit", "Tongyi-MAI/Z-Image-Turbo"], defaults: { rank: 16, lr: 0.0001, resolution: 768 }, - vram_note: "The smallest and fastest to train. A great first pick.", + vram_note: "The smallest and fastest. A good first pick.", }, { name: "sdxl", label: "SDXL (U-Net)", base_repos: ["stabilityai/stable-diffusion-xl-base-1.0", "stabilityai/sdxl-turbo"], defaults: { rank: 16, lr: 0.0001, resolution: 1024 }, - vram_note: "The classic. Trains comfortably at 1024px.", + vram_note: "The classic. Fine at 1024px.", }, ]; @@ -867,11 +867,11 @@ export function DiffusionTrainPanel({ const precisionLabel = ( m: "nf4" | "bf16" | "int8" | "fp8" | "mxfp8" | "auto", ): string => { - if (m === "auto") return "Auto (recommended)"; - if (m === "nf4") return "nf4 (4-bit QLoRA, lowest VRAM)"; - if (m === "bf16") return "bf16 (fastest, most VRAM)"; - if (m === "int8") return "int8 (8-bit)"; - if (m === "mxfp8") return "mxfp8 (Blackwell, best at high res/batch)"; + if (m === "auto") return "Auto"; + if (m === "nf4") return "nf4 (lowest VRAM)"; + if (m === "bf16") return "bf16 (fastest)"; + if (m === "int8") return "int8"; + if (m === "mxfp8") return "mxfp8 (Blackwell)"; return "fp8 (experimental)"; }; @@ -911,7 +911,7 @@ export function DiffusionTrainPanel({

- How fast the model learns over time. Constant is fine for most runs. + Constant is fine for most runs.

{lrScheduler !== "constant" && @@ -934,7 +934,7 @@ export function DiffusionTrainPanel({

- Saves a lot of GPU memory in exchange for slightly slower steps. + Less VRAM, slightly slower steps.

@@ -971,8 +971,7 @@ export function DiffusionTrainPanel({ <>This GPU cannot train this model family. ) : ( <> - How the base model is stored while training. Auto picks the best fit - for your GPU. + Auto picks the best fit for your GPU. {basePrequantized && ( <> This base is already 4-bit, so only nf4/auto apply. )} @@ -997,7 +996,7 @@ export function DiffusionTrainPanel({

- How the math runs during training. bf16 is right for modern GPUs. + bf16 is right for modern GPUs.

)} @@ -1020,7 +1019,7 @@ export function DiffusionTrainPanel({

- Warms up once at the start, then every training step runs faster. + Slower first step, faster after.

)} @@ -1038,8 +1037,7 @@ export function DiffusionTrainPanel({

Train a LoRA

- Teach an image model a style, character, or subject from your own images. The - finished adapter shows up in the Create tab's LoRA picker. + Teach a model a style or subject from your own images.

@@ -1081,7 +1079,7 @@ export function DiffusionTrainPanel({ {effectiveBase === CUSTOM_BASE && ( setCustomBase(e.target.value)} className="h-8 text-xs" @@ -1191,8 +1189,7 @@ export function DiffusionTrainPanel({ )}

- 10-50 images are plenty. Captions are optional: without them, the trigger - prompt below describes every image. + 10-50 images is plenty. Captions are optional.

) : ( @@ -1219,9 +1216,8 @@ export function DiffusionTrainPanel({ /> )} {selectedDataset.caption_count === 0 && !gridOpen && ( -

- No captions yet: the trigger prompt below will describe every image, - or open Review captions to write your own. +

+ No captions yet, so the trigger prompt describes every image.

)} @@ -1239,8 +1235,8 @@ export function DiffusionTrainPanel({ just labels the output) */} {fullyCaptioned ? (

- All {selectedDataset?.image_count} images have captions - no trigger prompt needed. - The style applies to any prompt after training. + All {selectedDataset?.image_count} images have captions, so no trigger prompt + is needed.

) : (
@@ -1252,8 +1248,7 @@ export function DiffusionTrainPanel({ className="h-8 text-xs" />

- What every image is described as while training. Put these words in a - prompt later to get the style back. + The words you will use later to get this style back.

)} @@ -1267,7 +1262,7 @@ export function DiffusionTrainPanel({ className="h-8 text-xs" />

- The name this LoRA gets in the Create tab's picker. + Its name in the Create tab's picker.

@@ -1370,13 +1365,12 @@ export function DiffusionTrainPanel({ Training settings - Applied when you press Start training + Applied on Start training {trainingSettings}

- Once training starts, live progress and the Training Loss / Gradient Norm - charts take over this area. + Progress and charts take over here once training starts.