mirror of
https://github.com/ikawrakow/ik_llama.cpp.git
synced 2026-08-12 22:29:39 +04:00
convert : map self-contained DFlash draft embed_tokens (#2062)
DFlashDraftModel.modify_tensors rewrites flat-named norm.weight and layers.N.* to their model.* form but not embed_tokens.weight, so a draft that carries its own (self-contained) token embeddings with flat naming fails with 'Can not map tensor embed_tokens.weight'. Handle it the same way as norm.weight so self-contained drafts convert. Co-authored-by: Joel Farthing <262452229+joelfarthing@users.noreply.github.com>
This commit is contained in:
co-authored by
Joel Farthing
parent
29431b31c8
commit
068b173649
@@ -2592,6 +2592,8 @@ class DFlashDraftModel(Qwen3Model):
|
||||
return [(f"{gguf.TENSOR_NAMES[gguf.MODEL_TENSOR.ATTN_SINKS].format(bid=bid)}.weight", data_torch)]
|
||||
if name == "norm.weight":
|
||||
name = "model.norm.weight"
|
||||
elif name == "embed_tokens.weight":
|
||||
name = "model.embed_tokens.weight"
|
||||
elif name.startswith("layers."):
|
||||
name = f"model.{name}"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user