Closed jinwei1660 closed 1 month ago
This was fixed in #1724. If you get an error, please reopen.
LoRA training script has been updated and a bug in LoRA training including Text Encoders has been fixed. Please use the latest version. See https://github.com/kohya-ss/sd-scripts/pull/1719#issuecomment-2439962666 for details.
What should I do if this error occurs during my training? Which configuration is not configured correctly? Traceback (most recent call last): File "D:\pinokio\api\ajfluxlora\sd-scripts-3.5\sd3_train_network.py", line 426, in
trainer.train(args)
File "D:\pinokio\api\ajfluxlora\sd-scripts-3.5\train_network.py", line 1161, in train
encoded_text_encoder_conds = text_encoding_strategy.encode_tokens(
File "D:\pinokio\api\ajfluxlora\sd-scripts-3.5\library\strategy_sd3.py", line 70, in encode_tokens
clip_l, clip_g, t5xxl = models
ValueError: not enough values to unpack (expected 3, got 2)
Here are the specific configurations accelerate launch ^ --mixed_precision bf16 ^ --num_cpu_threads_per_process 1 ^ --num_processes 1 ^ --gpu_ids 0 ^ sd-scripts-3.5/sd3_train_network.py ^ --pretrained_model_name_or_path "D:\ComfyUI_windows_portable_nvidia\ComfyUI\models\checkpoints\sd3.5_large.safetensors" ^ --clip_g "D:\ComfyUI_windows_portable_nvidia\ComfyUI\models\clip\clip_g.safetensors" ^ --clip_l "d:\pinokio\api\ajfluxlora\models\clip\clip_l.safetensors" ^ --t5xxl "d:\pinokio\api\ajfluxlora\models\clip\t5xxl_fp16.safetensors" ^ --cache_latents_to_disk ^ --save_model_as safetensors ^ --sdpa --persistent_data_loader_workers ^ --max_data_loader_n_workers 32 ^ --seed 42 ^ --gradient_checkpointing ^ --mixed_precision bf16 ^ --save_precision bf16 ^ --network_module networks.lora_flux ^ --network_dim 64 ^ --optimizer_type adamw8bit ^--sample_prompts="d:\pinokio\api\ajfluxlora\outputs\my021-sd35\sample_prompts.txt" --sample_every_n_steps="1380" ^ --learning_rate 1e-4 ^ --cache_text_encoder_outputs ^ --cache_text_encoder_outputs_to_disk ^ --fp8_base ^ --highvram ^ --max_train_epochs 5 ^ --save_every_n_epochs 4 ^ --dataset_config "d:\pinokio\api\ajfluxlora\outputs\my021-sd35\dataset.toml" ^ --output_dir "d:\pinokio\api\ajfluxlora\outputs\my021-sd35" ^ --output_name my021-sd35 ^ --loss_type l2 ^