mirror of
https://github.com/kvcache-ai/ktransformers.git
synced 2026-11-05 01:07:28 +00:00
[GH-ISSUE #1259] [Bug] "ValueError: too many values to unpack" when trying to run Qwen3-30B-A3B with v0.3 ktransformers #850
Labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
kvcache-ai/ktransformers#850
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @zondie17 on GitHub (May 6, 2025).
Original GitHub issue: https://github.com/kvcache-ai/ktransformers/issues/1259
Checklist
Describe the bug
First run I got
AttributeError: 'Qwen3MoeForCausalLM' object has no attribute '_get_logits_warper'. Did you mean: '_get_logits_processor'?like https://github.com/kvcache-ai/ktransformers/issues/1238, so I tried the fix @vickiegpt provided and @createthis provided, then got another error:Reproduction
Qwen3: https://huggingface.co/lmstudio-community/Qwen3-30B-A3B-GGUF/resolve/main/Qwen3-30B-A3B-Q4_K_M.gguf
ktransformers version:
753049Modifications made are as follows:
Environment
OS: Ubuntu 22.04.1
Hardware: AMD EPYC 7V13, A100 80GB
Software: python 3.11, pytorch 2.7.0, cuda 12.8, cmake 3.29.6
@createthis commented on GitHub (May 6, 2025):
I'm not a member of the ktransformers team, just a user, but I'm pretty sure Qwen3 was never intended to work with the ktransformers backend. It works with the balance_serve backend though.
@zondie17 commented on GitHub (May 8, 2025):
Thanks, but after making the above modifications and reinstalling ktransformers, I still encountered the same ValueError when using the balance_serve backend. Have you ever encountered this issue?
@createthis commented on GitHub (May 8, 2025):
@zondie17 have you tried reverting your patch? It shouldn't be necessary for
balance_serve. I patchedktransformers/models/modeling_deepseek_v3.pyto run deepseek-v3 under thektransformersbackend, but I didn't have to patchktransformers/models/modeling_qwen3_moe.py.It's been a while since I was using that version, so I'm going off memory and my patch notes.
@zondie17 commented on GitHub (May 8, 2025):
Thanks, may I ask which version you are using now?
@createthis commented on GitHub (May 8, 2025):
I'm not using Qwen3. I tried it with
balance_serve, and it was ok, but it lacked long context, which I need for agentic purposes. I also tried it withllama.cppand long context. It didn't work well though. It just kept looping on a file I told it to read.I'm currently running Deepseek-V3-0324:671b-Q4_K_M with ktransformers using the
ktransformersbackend. I have it checked out frommainat commit8dc1abright now, which is somewhere between0.2.4-post1and0.3.It's not perfect. It crashes a lot. But it gives me long context and it's pretty fast on my machine and it follows instructions really well, so I like it.
@visuOwO commented on GitHub (Aug 15, 2025):
It‘s probably that you are using KQwen3MoeRMSNorm in the optimiaze rules. I think there are some differents in the interfaces for different methods, you can try modify it with DeepseekV3RMSNormTorch in the optimize rules yaml file.
@PPXGS commented on GitHub (Aug 29, 2025):
我的ktransformers版本是v0.3.1,不论加不加--backend_type balance_serce,也有ValueError: too many values to unpack (expected 2)的报错。后续你用这个local_chat方式成功运行qwen3-moe模型了吗?