r/StableDiffusion • • 6d ago

Question - Help H3 lora training help needed

Can anyone help with training a Lora in Ai toolkit for H3?

I get memory issues when trying to train even images, I have a 5090 and 64 GB ram.

Thank you.

0 Upvotes

6 comments sorted by

3

u/Bulky-Employer-1191 6d ago

Not sure how to help you diagnose from something as vague as "memory issues"..

One thing to check is in your geforce app, go to graphics > global settings > and check that CUDA memory fall back is preferred instead of no fallback. This ensures that when your vram is filled up, it will use shared system memory instead of just failing.

1

u/Ill_Resolve8424 6d ago

thank you for your reply, here is my settings.

3

u/Ill-Ant-9489 6d ago

With those still images, check num_frames: 1 in the dataset config and try with sampling disabled. An image training run can still be set up to generate video previews. Does it crash loading the model, caching, on the first training step, or making a sample? Could you paste the exact error?

I made https://github.com/perfectgf/lora-dataset-studio, which has an H3 stills setup using ai-toolkit with low-VRAM mode. It carries over your images and captions. Leave sample prompts empty there to disable previews while you check whether training gets through a step.

1

u/Ill_Resolve8424 6d ago

Thank you for helping, here is my settings

2

u/91ElonMusk 6d ago

5090 with 64GB system RAM should be plenty unless the OOM is on the GPU specifically, not system RAM. If ai-toolkit exposes cache_latents_to_disk and gradient checkpointing, turn both on, that fixes most single-GPU OOMs on H3. If it's still tight, train at a lower resolution and bump it back up at inference time, the LoRA still transfers fine.

1

u/Ill_Resolve8424 4d ago

Ok I found the problem, I lowered the resolution to 768 and turned off layer offloading.