Nodes/FL PixelGen/FL PixelGen Training Config
ComfyUI Node

FL PixelGen Training Config

A ComfyUI node in FL/PixelGen/Training with 18 inputs and 1 output.

By filliptm·Created 5 months ago·Updated 4 months ago· 13
FL PixelGen Training Config
    • config
    lora_rank8
    lora_alpha16
    lora_dropout0.10
    learning_rate0.0001
    epochs100
    batch_size1
    gradient_accumulation4
    save_every10
    max_grad_norm1.0
    seed42
    warmup_steps100
    feat_loss_weight0.5
    lpips_weight1.0
    dino_weight1.0
    percept_ratio1.0
    noise_gating_threshold0.00
    cfg_dropout0.10
    output_dir./output/pixelgen
    CategoryFL/PixelGen/Training

    Inputs (18)

    NameTypeDefaultDescription
    lora_rankINT81–128Number of low-rank dimensions per adapter. Higher rank = more expressive but slower training and larger files. Start with 8, increase to 16-32 for complex styles.
    lora_alphaINT161–256Scaling factor for LoRA weights. Typically set to 2x the rank. Higher values make the LoRA effect stronger during training.
    lora_dropoutFLOAT0.100–0.5Randomly drops LoRA connections during training to prevent overfitting. 0.1 is a good default; increase to 0.2-0.3 for very small datasets.
    learning_rateFLOAT0.00010.000001–0.01How fast the model learns. Too high causes instability, too low learns nothing. 1e-4 is a solid starting point; lower to 5e-5 if loss is noisy.
    epochsINT1001–10000Number of full passes through the dataset. More epochs = more training. Watch the loss curve — if it plateaus or rises, you're overfitting.
    batch_sizeINT11–8Images processed in parallel per step. Higher values give smoother gradients but use more VRAM. Effective batch = batch_size x gradient_accumulation.
    gradient_accumulationINT41–32Simulates a larger batch by accumulating gradients across multiple steps before updating weights. Increase this instead of batch_size to save VRAM.
    save_everyINT101–1000Save a checkpoint every N epochs. Lower values give more recovery points but use more disk space. Also triggers validation inference if a prompt is set.
    max_grad_normFLOAT1.00.1–10Clips large gradients to prevent training explosions. 1.0 is standard. Only increase if training is very stable and loss is stalling.
    seedINT420–18446744073709550000Random seed for reproducibility. Same seed + same settings = same training run.
    warmup_stepsoptINT1000–10000Gradually ramps up the learning rate from 10% to full over this many steps. Prevents early instability. 100 steps is a safe default.
    feat_loss_weightoptFLOAT0.50–10Weight for cosine feature alignment between denoiser and DINOv2 features (REPA). Higher values push the model to match DINOv2's semantic understanding.
    lpips_weightoptFLOAT1.00–10Weight for LPIPS perceptual loss. Encourages outputs that look perceptually similar to the target. Higher values prioritize visual quality over exact pixel matching.
    dino_weightoptFLOAT1.00–10Weight for DINO multi-layer feature matching loss. Guides the model to capture high-level structure and object features from DINOv2.
    percept_ratiooptFLOAT1.00–10Global multiplier for all perceptual losses (LPIPS + DINO). Scale this to balance perceptual quality vs flow matching fidelity.
    noise_gating_thresholdoptFLOAT0.000–1Only apply perceptual losses when timestep t >= this threshold. Focuses perceptual guidance on less noisy samples where image structure is visible. 0 = always apply.
    cfg_dropoutoptFLOAT0.100–1Probability of dropping text conditioning during training. Teaches the model to generate without text guidance, improving classifier-free guidance quality at inference.
    output_diroptSTRING./output/pixelgenDirectory where training checkpoints and validation images are saved.

    Outputs (1)

    NameTypeDescription
    configPIXELGEN_TRAINING_CONFIG