kohya-ss / kohya-ss/sd-scripts

Encountering _IncompatibleKeys while training LoRA for flux

Open
#1,880 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
7.2k
Forks
1.2k
Avg merge
11m
Merged PRs (30d)
2

Description

I encountered the following output while training LoRA for Flux, should I ignore it?
`INFO Loaded T5xxl: _IncompatibleKeys(missing_keys=['encoder.embed_tokens.weight'], unexpected_keys=[]) `
Among them, T5. safetensors is obtained by merging two safetensors files in the text_decoder_2 directory of the huggingface model.

![Image](https://github.com/user-attachments/assets/741cfff2-6906-4dda-910d-0c22343fb598)

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reproducing Flux LoRA training with the T5.safetensors file assembled from the two files in the text_decoder_2 directory. Inspect the loader output containing the missing encoder.embed_tokens.weight key and compare it with the expected model contents. Done means establishing whether the message is expected or identifying a reproducible loading problem and the affected handling.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
machine-learning
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.