Node Overview
The native LoRA training system is organized into dataset nodes and training nodes.Dataset Nodes
Used to prepare and manage training data:Training Nodes
Used to run training, save results, and apply the LoRA:Requirements
- A GPU with sufficient VRAM (training typically requires more memory than inference)
- Training images placed in a subfolder under
ComfyUI/input/ - A base model (checkpoint)
Typical Training Workflow
1
Load training images
Place your training images in a subfolder under
ComfyUI/input/.- Use Load Image Dataset from Folder for images only
- Use Load Image and Text Dataset from Folder for image–caption pairs (each image needs a matching
.txtfile with the same base name)
2
Encode the dataset
Connect images and text to Make Training Dataset along with a VAE and CLIP model. This produces
latents and conditioning outputs.To reuse the same dataset across multiple training runs, save it with Save Training Dataset and load it later with Load Training Dataset — no re-encoding needed.3
(Optional) Resolution bucketing
If your images have varying dimensions, pass the encoded data through Resolution Bucket to group them by resolution, then enable bucket_mode in the Train LoRA node for efficient batched training.
4
Configure and run Train LoRA
Connect the model, latents, and conditioning to Train LoRA and adjust parameters as needed.Recommended starting values:
The node outputs trained
lora weights, a loss_map, and the completed steps count.5
Monitor training progress
Connect
loss_map to Plot Loss Graph to visualize the loss curve. Training can be stopped once the loss plateaus.6
Save and test your LoRA
Connect
lora to Save LoRA Weights to export a .safetensors file to ComfyUI/output/loras/.In your inference workflow, use Load LoRA Model to apply the trained LoRA to the base model and test the results.VRAM Optimization
Quantized Model Training
To train a LoRA on a quantized model (FP8/FP4), use these settings in Train LoRA:training_dtype:nonequantized_backward: enabledbypass_mode: enabled
bypass in Load LoRA Model when using the resulting LoRA for inference.
Continuing Training
Setexisting_lora in Train LoRA to an existing saved LoRA file to resume from a checkpoint. The total step count accumulates automatically.
Supported Algorithms
Thealgorithm parameter in Train LoRA selects the weight adapter type: