{"course":{"slug":"ai-images","title":"Image Generation, in Practice","url":"https://addaly.com/learn/ai-images","level":"beginner","track":"create"},"lesson":{"slug":"dataset-hygiene","title":"Four dataset faults, and the LoRA each one ruins","url":"https://addaly.com/learn/ai-images/dataset-hygiene","position":55,"of":69,"minutes":8,"answer":"A LoRA learns whatever is constant across its training images, so variety in everything except the subject is the property that decides whether it works.","keyIdea":"A LoRA learns whatever is constant across its training images, so variety in everything except the subject is the property that decides whether it works, and no training setting compensates for a set that lacks it."},"body":{"format":"markdown","text":"## The rule that explains every failure\n\n**A LoRA learns what does not change.**\n\nThat is the whole thing. If the face is the only constant, the face is what it learns. If the face *and* the lighting *and* the background *and* the camera angle are all constant, it learns all four as one inseparable concept, and you get a LoRA that can only produce your character in that light, in that place, from that angle.\n\nEvery dataset fault is a violation of this rule.\n\n## Fault one: no variety in lighting\n\nTwenty images shot in the same session under the same light. The LoRA now believes soft frontal window light is part of the person's identity. Prompt for dramatic side lighting and you get a fight between the LoRA and the prompt, which the LoRA usually wins, producing a flat face awkwardly embedded in a dramatic scene.\n\n**Fix:** vary it deliberately. Some soft, some hard, some outdoors, some indoors, some backlit. If you are generating the training images from a character sheet, generate them under different lighting on purpose.\n\n## Fault two: no variety in angle and distance\n\nAll front-facing at the same crop. The LoRA produces a good front view and falls apart in profile, because it has never seen one.\n\n**Fix:** roughly half front and three-quarter, a quarter profile or near-profile, a quarter at greater distance including full body. The distant ones matter more than people expect: without them, the LoRA has no idea what the character's proportions are and will produce a correct face on an arbitrary body.\n\n## Fault three: near-duplicate images\n\nFive frames from the same burst, or the same image cropped five ways. These are nearly identical, so they count five times toward whatever they have in common, and the set is effectively much smaller than its file count.\n\n**Fix:** one image per moment. Fifteen different images beat forty near-duplicates comfortably. If you are unsure, lay the set out as a contact sheet and look for anything that reads as the same picture twice.\n\n## Fault four: other people, or other versions of the subject\n\nA second face in the background. A reflection. A photograph of the person at a very different age or with a very different haircut, mixed into a set that is otherwise consistent.\n\n**Fix:** crop out other faces or discard the image. Pick one era and stay in it: a LoRA trained across a fifteen-year span learns an average that resembles neither.\n\n## The quality floor\n\nResolution: at least your training resolution, so 1024 for SDXL. Upscaling a small image to meet it teaches the model upscaling artefacts as part of the identity.\n\nSharpness: avoid heavily blurred or motion-blurred images. Some softness is fine and even useful, but a set full of soft images produces a soft LoRA.\n\nCompression: avoid heavily compressed JPEGs. The blocking gets learned. This matters more than it sounds, and it is why a LoRA trained from images saved off a messaging app often looks subtly bad in a way nobody can identify.\n\n## A checklist before you train\n\nLay the set out as a grid and ask:\n\n1. Is the subject the only thing constant across all of these?\n2. Are there at least three distinct lighting situations?\n3. Are there at least three distinct angles, including one distant?\n4. Would any two of these be described as the same picture?\n5. Is there another face anywhere in frame?\n6. Is every image at or above training resolution, and reasonably sharp?\n7. Do the captions name everything that varies and nothing that should not?\n\nTen minutes on this checklist saves the two hours of training and testing a bad LoRA and then working out why it is bad.\n\n## The honest constraint\n\nYou cannot always get variety. Sometimes you have eight photographs of a real person, all from one afternoon, and that is all that exists. Train on them anyway (a limited LoRA is better than none), but know what you have: a LoRA that works in that lighting and fails elsewhere, and a job where you should plan to match the scene lighting to the training lighting rather than the other way round.\n\nAnd a note that belongs here rather than in the legal block, because it is a working decision rather than a legal one. If the training images are of a real person, you need their agreement, and \"I found them online\" is not agreement. The images also carry the rights of whoever took them. A dataset assembled from a search engine is a problem you are building into an asset you intend to reuse, and it is much cheaper to resolve before training than after a campaign has shipped."},"check":{"question":"Why does a training set shot entirely in one lighting setup produce a LoRA that resists prompted lighting changes?","options":[{"text":"Because the adapter's weights are optimised for the tonal range present in the training images, so other ranges fall outside what it can reproduce.","correct":false,"tempting":"Frames the problem as a limitation of range rather than of association; the LoRA renders other tonal ranges perfectly well in regions it did not learn."},{"text":"Because lighting information is encoded in the same layers as identity, so the two cannot be separated by any captioning strategy.","correct":false,"tempting":"They share layers but remain separable in practice, which is exactly why a varied set produces a LoRA that takes prompted lighting."},{"text":"Because a LoRA learns whatever is constant, so with lighting held fixed it becomes part of the concept rather than a separable attribute.","correct":true},{"text":"Because the captions described the subject but not the lighting, and any attribute left uncaptioned is excluded from the learned concept entirely.","correct":false,"tempting":"Inverts the captioning rule: an uncaptioned constant is absorbed into the concept, not excluded from it."}]},"prev":{"slug":"training-a-lora-in-practice","title":"Training a character LoRA on hardware you can borrow","url":"https://addaly.com/learn/ai-images/training-a-lora-in-practice"},"next":{"slug":"adapter-or-lora","title":"The decision, with the numbers","url":"https://addaly.com/learn/ai-images/adapter-or-lora"},"authorship":"Founder and series editor: Dr Mustafa Mun. Written by AI models to a written standard. Exam keys checked blind by a second model: 3,665 of 3,666 agreed. Academic review invited.","review":{"status":"Draft, open for academic review"},"cite":"Addaly (2026) 'Four dataset faults, and the LoRA each one ruins', in Image Generation, in Practice. Edited by M. Mun. Addaly. Available at: https://addaly.com/learn/ai-images/dataset-hygiene (Accessed: 13 October 2026).","licence":{"name":"CC BY-NC-SA 4.0","url":"https://creativecommons.org/licenses/by-nc-sa/4.0/"},"reader":{"schema":1,"title":"Four dataset faults, and the LoRA each one ruins","courseTitle":"Image Generation, in Practice","module":{"index":6,"slug":"consistency","title":"The same thing, twelve times"},"answer":null,"keyIdea":"A LoRA learns whatever is constant across its training images, so variety in everything except the subject is the property that decides whether it works, and no training setting compensates for a set that lacks it.","hero":{"kind":"plate","image":null,"alt":null,"caption":null},"blocks":[{"t":"h2","id":"the-rule-that-explains-every-failure","runs":[{"text":"The rule that explains every failure"}]},{"t":"p","runs":[{"text":"A LoRA learns what does not change.","b":true}]},{"t":"p","runs":[{"text":"That is the whole thing. If the face is the only constant, the face is what it learns. If the face "},{"text":"and","i":true},{"text":" the lighting "},{"text":"and","i":true},{"text":" the background "},{"text":"and","i":true},{"text":" the camera angle are all constant, it learns all four as one inseparable concept, and you get a LoRA that can only produce your character in that light, in that place, from that angle."}]},{"t":"p","runs":[{"text":"Every dataset fault is a violation of this rule."}]},{"t":"h2","id":"fault-one-no-variety-in-lighting","runs":[{"text":"Fault one: no variety in lighting"}]},{"t":"p","runs":[{"text":"Twenty images shot in the same session under the same light. The LoRA now believes soft frontal window light is part of the person’s identity. Prompt for dramatic side lighting and you get a fight between the LoRA and the prompt, which the LoRA usually wins, producing a flat face awkwardly embedded in a dramatic scene."}]},{"t":"p","runs":[{"text":"Fix:","b":true},{"text":" vary it deliberately. Some soft, some hard, some outdoors, some indoors, some backlit. If you are generating the training images from a character sheet, generate them under different lighting on purpose."}]},{"t":"h2","id":"fault-two-no-variety-in-angle-and-distance","runs":[{"text":"Fault two: no variety in angle and distance"}]},{"t":"p","runs":[{"text":"All front-facing at the same crop. The LoRA produces a good front view and falls apart in profile, because it has never seen one."}]},{"t":"p","runs":[{"text":"Fix:","b":true},{"text":" roughly half front and three-quarter, a quarter profile or near-profile, a quarter at greater distance including full body. The distant ones matter more than people expect: without them, the LoRA has no idea what the character’s proportions are and will produce a correct face on an arbitrary body."}]},{"t":"h2","id":"fault-three-near-duplicate-images","runs":[{"text":"Fault three: near-duplicate images"}]},{"t":"p","runs":[{"text":"Five frames from the same burst, or the same image cropped five ways. These are nearly identical, so they count five times toward whatever they have in common, and the set is effectively much smaller than its file count."}]},{"t":"p","runs":[{"text":"Fix:","b":true},{"text":" one image per moment. Fifteen different images beat forty near-duplicates comfortably. If you are unsure, lay the set out as a contact sheet and look for anything that reads as the same picture twice."}]},{"t":"h2","id":"fault-four-other-people-or-other-versions-of-the-subject","runs":[{"text":"Fault four: other people, or other versions of the subject"}]},{"t":"p","runs":[{"text":"A second face in the background. A reflection. A photograph of the person at a very different age or with a very different haircut, mixed into a set that is otherwise consistent."}]},{"t":"p","runs":[{"text":"Fix:","b":true},{"text":" crop out other faces or discard the image. Pick one era and stay in it: a LoRA trained across a fifteen-year span learns an average that resembles neither."}]},{"t":"h2","id":"the-quality-floor","runs":[{"text":"The quality floor"}]},{"t":"p","runs":[{"text":"Resolution: at least your training resolution, so 1024 for SDXL. Upscaling a small image to meet it teaches the model upscaling artefacts as part of the identity."}]},{"t":"p","runs":[{"text":"Sharpness: avoid heavily blurred or motion-blurred images. Some softness is fine and even useful, but a set full of soft images produces a soft LoRA."}]},{"t":"p","runs":[{"text":"Compression: avoid heavily compressed JPEGs. The blocking gets learned. This matters more than it sounds, and it is why a LoRA trained from images saved off a messaging app often looks subtly bad in a way nobody can identify."}]},{"t":"h2","id":"a-checklist-before-you-train","runs":[{"text":"A checklist before you train"}]},{"t":"p","runs":[{"text":"Lay the set out as a grid and ask:"}]},{"t":"ol","start":1,"items":[[{"text":"Is the subject the only thing constant across all of these?"}],[{"text":"Are there at least three distinct lighting situations?"}],[{"text":"Are there at least three distinct angles, including one distant?"}],[{"text":"Would any two of these be described as the same picture?"}],[{"text":"Is there another face anywhere in frame?"}],[{"text":"Is every image at or above training resolution, and reasonably sharp?"}],[{"text":"Do the captions name everything that varies and nothing that should not?"}]]},{"t":"p","runs":[{"text":"Ten minutes on this checklist saves the two hours of training and testing a bad LoRA and then working out why it is bad."}]},{"t":"h2","id":"the-honest-constraint","runs":[{"text":"The honest constraint"}]},{"t":"p","runs":[{"text":"You cannot always get variety. Sometimes you have eight photographs of a real person, all from one afternoon, and that is all that exists. Train on them anyway (a limited LoRA is better than none), but know what you have: a LoRA that works in that lighting and fails elsewhere, and a job where you should plan to match the scene lighting to the training lighting rather than the other way round."}]},{"t":"p","runs":[{"text":"And a note that belongs here rather than in the legal block, because it is a working decision rather than a legal one. If the training images are of a real person, you need their agreement, and “I found them online” is not agreement. The images also carry the rights of whoever took them. A dataset assembled from a search engine is a problem you are building into an asset you intend to reuse, and it is much cheaper to resolve before training than after a campaign has shipped."}]}],"check":{"question":[{"text":"Why does a training set shot entirely in one lighting setup produce a LoRA that resists prompted lighting changes?"}],"options":[{"text":[{"text":"Because the adapter’s weights are optimised for the tonal range present in the training images, so other ranges fall outside what it can reproduce."}],"correct":false,"tempting":[{"text":"Frames the problem as a limitation of range rather than of association; the LoRA renders other tonal ranges perfectly well in regions it did not learn."}]},{"text":[{"text":"Because lighting information is encoded in the same layers as identity, so the two cannot be separated by any captioning strategy."}],"correct":false,"tempting":[{"text":"They share layers but remain separable in practice, which is exactly why a varied set produces a LoRA that takes prompted lighting."}]},{"text":[{"text":"Because a LoRA learns whatever is constant, so with lighting held fixed it becomes part of the concept rather than a separable attribute."}],"correct":true,"tempting":null},{"text":[{"text":"Because the captions described the subject but not the lighting, and any attribute left uncaptioned is excluded from the learned concept entirely."}],"correct":false,"tempting":[{"text":"Inverts the captioning rule: an uncaptioned constant is absorbed into the concept, not excluded from it."}]}],"order":[1,2,3,0],"why":null},"prev":{"slug":"training-a-lora-in-practice","title":"Training a character LoRA on hardware you can borrow","minutes":9},"next":{"slug":"adapter-or-lora","title":"The decision, with the numbers","minutes":7}}}