Beta

LoRA training

LoRA training datasets: images, captions, angles, and what to delete

The expensive part of LoRA training is not the GPU. It is discovering, 1,200 steps later, that half the dataset was the same selfie, every image had beauty smoothing, and the only full-body frame was anatomically broken. A good dataset is small enough to inspect by hand and varied enough that identity is the only thing the images consistently share.

Based on official documentation, public benchmarks where relevant, and corroborated practitioner reports where useful. No placement in these guides is paid.

The short answer

What I would pick

Start with 15–40 licensed, high-quality images; for most first character LoRAs, 20–30 is a sensible working set. Cover close, medium, and full-body framing, front/three-quarter/profile angles, expressions, outfits, backgrounds, and light. Caption the attributes you want to change later. Keep a few useful conditions outside training, and delete weak images even when that makes the folder smaller.

If the set only works because you repeated mediocre images ten times, the dataset is not ready.

On this page

Skip to the part you need

  1. Define what the LoRA should learn
  2. How many images you actually need
  3. Build a useful character shot list
  4. What to delete before training
  5. Caption identity without baking in everything else
  6. Crop, resolution, and aspect buckets
  7. Keep a real validation set
  8. Folder layout and dataset audit
  9. Using synthetic images without compounding artifacts
  10. Consent, licensing, and the final checklist

Define what the LoRA should learn

Write one sentence before collecting anything: “This LoRA should reproduce this identity across new clothes, locations, lighting, expressions, and camera distances.” That sentence is a filter. An image belongs only if it helps the model learn the identity or proves that identity can survive a useful variation.

A character LoRA and a style LoRA need opposite kinds of consistency. For a character, keep identity stable and vary treatment. For a style, vary subjects and composition while keeping the visual treatment stable. A product LoRA sits between them: shape, proportions, materials, and logos may need to stay fixed while angle and scene change.

LoRA targetKeep consistentDeliberately vary
CharacterIdentity and stable physical featuresClothes, pose, crop, expression, background, lighting
StylePalette, rendering, texture, line or photographic treatmentPeople, objects, scenes, composition, aspect ratio
ProductShape, materials, proportions, identifying detailsView, context, light, supporting objects, scale cues

This guide is character-first. Its examples refer only to fictional characters or consenting adults. The same culling and caption logic generalizes to products and styles, but do not copy the shot distribution blindly.

How many images you actually need

There is no magic count. LoRA capacity, base model, training resolution, captions, repetition, subject complexity, and intended range all change the answer. The useful number is the smallest set that covers the subject without making unrelated attributes look like identity.

Dataset sizeWhen it can workMain risk
8–14 imagesDistinctive character, narrow framing, clean originalsFragile angles and strong leakage from clothes or backgrounds
15–25 imagesFocused portrait identity with deliberate varietyA missing side, expression, or full-body condition can remain obvious
26–40 imagesBroader pose, wardrobe, light, and framing coverageQuality quietly drops because “more” feels productive
40+ imagesComplex subject or carefully curated multi-look projectDuplicates dominate and training exposure becomes harder to reason about

Start around twenty images and inventory what is missing. Add a new file because it gives you a clean profile, a different crop, a useful expression, or an unseen lighting condition—not because a forum said forty is safe. Perceptual variety matters more than filename count.

Repeats do not create information. Ten repetitions of a near-duplicate close-up tell the optimizer that this view matters ten times more. Use repeats and epochs to control exposure after the dataset is balanced, not to disguise a thin set.

Build a useful character shot list

A dataset should look slightly boring as a gallery and excellent as evidence. You do not need twenty hero shots. You need clean observations of the same identity under conditions the finished LoRA must survive.

CoveragePractical share of a 24-image setWhat it teaches
Close portraits4–5 imagesEyes, nose, mouth, hairline, skin, and stable facial proportions
Head-and-torso / medium6–7 imagesFace-to-body relationship, shoulders, hair, gesture, clothing separation
Three-quarter / full body5–6 imagesBody proportions, posture, limbs, and identity at smaller face scale
Clear side and three-quarter angles3–4 images across the setProfile, jaw, nose projection, ear and hair volume
Expression and difficult light4–6 images across the setIdentity beyond one neutral, flattering studio pose

Categories can overlap: a medium three-quarter view under window light can fill several gaps. Across the whole set, include front, three-quarter, and side views; neutral and expressive faces; indoor and outdoor context; soft and harder light; and several outfits.

Change hairstyles carefully. If hair is core to the fictional design, keep its shape mostly stable and vary styling modestly. If users must prompt different hair later, show that variation and caption it. The model cannot infer your character bible from the filename.

What to delete before training

Culling is where the dataset becomes useful. View every image at 100%, then as a contact sheet. A file can be individually beautiful and still harmful because it repeats a pose, introduces a false facial feature, or teaches the same background for the fifteenth time.

Delete or replace images with:

  • Incorrect hands, teeth, pupils, ears, limbs, clothing seams, or body geometry.
  • Beauty filters, waxy skin, aggressive sharpening, face restoration, or smeared detail.
  • Watermarks, captions, UI, logos you do not intend to teach, or heavy compression blocks.
  • Motion blur that obscures identity rather than providing a useful photographic variation.
  • Occlusion covering the exact feature the image is meant to teach.
  • A different apparent age, facial structure, or body proportion caused by generation drift.
  • Near-duplicates, including alternate crops or minor color grades of the same source.
  • A dominant accessory, outfit, room, or camera treatment already overrepresented.

Use duplicate-detection software as a first pass, not an editor. Perceptual hashes can find resized copies; they cannot tell you that six different images have effectively the same front-facing pose and flat window light.

Never keep a bad full-body image because “the model needs full body.” It teaches the bad anatomy too. A missing condition is visible and fixable. A corrupted condition can look like a mysterious training problem for days.

Caption identity without baking in everything else

Use a rare trigger token such as rfgmara and include it consistently. Then describe attributes that should remain promptable: framing, pose, expression, clothing, hairstyle, accessories, lighting, background, and photographic treatment.

photo of rfgmara, adult woman, three-quarter view, medium shot,
calm expression, hair tied back, green knit sweater,
soft window light, plain kitchen background

The caption deliberately names the sweater, tied hair, light, and room. If those appear in several images but go unnamed, the optimizer may attach them to the trigger. It does not need a forensic list of stable facial measurements. Those are what the identity token is supposed to learn.

Caption thisWhyCommon mistake
Crop and angleKeeps close-up, profile, and full-body views controllableCalling every image simply “portrait”
Outfit and accessorySeparates wardrobe from identityOmitting a jacket that appears in half the set
Hair variationExplains ponytail, loose hair, hat, or wet hairAccidentally teaching one styling choice as anatomy
Light and treatmentSeparates flash, studio polish, grain, and color castBaking direct flash or smooth retouching into every output
BackgroundLets the prompt move the character somewhere newIgnoring a repeated bedroom, car, or seamless backdrop

An automatic captioner is an assistant, not an authority. Correct hallucinated age, hair color, emotion, clothing, and camera terms. Keep wording consistent enough that equivalent concepts do not fragment into five synonyms, but do not add a boilerplate paragraph to every file.

Crop, resolution, and aspect buckets

Do not stretch every image into a square. Aspect bucketing groups similar shapes so the trainer can resize and batch them with less destructive cropping. Use the bucket system documented by your exact trainer and model, with a pixel area appropriate to the base. For modern 1024-class image models, buckets centered around that training scale are a sensible starting point when hardware allows.

Crop out empty space only when it contributes nothing. Do not cut through hair, chin, fingers, elbows, knees, or feet to force a ratio. Those crops teach the model that bodies end where your preprocessing got impatient.

Upscaling a tiny, compressed source does not recover identity detail. It creates new pixels from an upscaler’s prior and may add synthetic pores, eyelashes, or sharpening that every training image then repeats. Prefer a clean source at sufficient resolution. If one irreplaceable image needs restoration, compare it carefully to the subject and record the intervention.

Extremely wide or tall images can create inefficient buckets and tiny subject scale. Keep them only when that composition is part of the intended output range. Otherwise use a respectful crop that preserves anatomy and the relevant environment.

Keep a real validation set

A training preview is not validation if it recreates a training caption and seed. Write validation prompts before training and do not edit them to flatter each checkpoint. They should cover conditions the dataset implies the LoRA can generalize to.

A compact character validation grid includes:

  1. A neutral close portrait in unseen lighting.
  2. A side or strong three-quarter view with a new expression.
  3. A medium shot in clothing absent from the dataset.
  4. A full-body scene in an unseen location.
  5. A difficult but realistic camera treatment such as direct flash or backlight.
  6. A prompt without the trigger, confirming the base model still behaves normally.

Keep seeds, dimensions, guidance, sampler, and base model fixed. Render the same grid for several checkpoints and adapter strengths. Score identity, prompt obedience, anatomy, scene leakage, texture, and diversity separately.

If you have enough authorized material, keep two or three good source images fully outside training as visual references. Do not use face-similarity software as the only judge; it can reward a copied frontal arrangement and miss whether the LoRA works as a generative tool.

Folder layout and dataset audit

AI Toolkit commonly works with an image and a same-name caption sidecar. Other trainers may use concept folders, metadata JSONL, repeat counts in directory names, or a separate dataset configuration. Choose one convention from the current tool documentation and make the loader prove it found every caption.

mara-character-v01/
  train/
    mara_001.jpg
    mara_001.txt
    mara_002.png
    mara_002.txt
  validation/
    prompts.txt
    reference-notes.md
  manifests/
    dataset.csv
    consent-and-license.md
  config/
    klein4b-r16-v01.yaml

The manifest should record filename, source or creator, permission/license, subject age confirmation where relevant, crop or restoration notes, caption status, and a short reason the image remains in the set. Hashes help detect silent replacement without forcing you to publish private originals.

Run this audit before renting a GPU:

  • Every image opens, has the expected color orientation, and is assigned one caption.
  • The trigger is spelled identically in all intended captions.
  • No train image accidentally lives in validation or vice versa.
  • Angles, crops, clothes, backgrounds, and lighting have been counted, not guessed.
  • Near-duplicates and alternate exports have been removed.
  • The loader preview shows the crop and caption the trainer will really see.

Using synthetic images without compounding artifacts

Synthetic images are useful when the character itself is fictional, when you own the generation rights, or when a licensed source set lacks a specific angle. They are also dangerous because a generator’s mistake can become the LoRA’s stable anatomy.

Inspect synthetic sources more aggressively than photographs. Look for repeated pore patterns, symmetrical flyaway hair, fused jewelry, drifting eye color, inconsistent ears, extra teeth, impossible cloth, and identity changes hidden by the same makeup or lighting. Zoom out too: a face can look consistent while head size and body proportions drift.

Avoid generating the entire dataset with one seed neighborhood, prompt template, camera angle, and model. That teaches the teacher model’s local groove. Vary seeds and conditioning deliberately, then cull back to one coherent identity. Using multiple source models can add diversity, but only if the character stays stable; variety is not useful when it becomes several people sharing a hairstyle.

Do not repeatedly train, generate, and feed those outputs back without a human-controlled reference. Each cycle can amplify smooth skin, anatomy shortcuts, and compositional bias. Keep a character sheet or authorized photographic reference outside the loop and compare every new batch against it.

Research notes

Primary sources and further reading

Model names, licenses, limits, and prices move quickly. These are the sources used for the dated market check above; confirm live pricing and terms before spending money.