Repository navigation
convert: add option to create separate dspark GGUF - #26452
Conversation
|
I tried this out, and there seemed to be a mismatch in |
|
Yes, I had #25784 in my build. When I launched llama-server, I saw an error: This fixed it for me, and DSpark worked correctly after that. |
|
Can you try the latest commit? |
|
@am17an yes, that fixed it! |
|
Btw, the base model https://huggingface.co/deepseek-ai/DeepSeek-V4-Flash-Base is in FP8 format and it fails to convert: Would be nice to fix this so we can run PPL measurements. |
|
@ggerganov I only ever convert the MXFP4 stuff, I think that's currently hardcoded, we would need to add some logic to disambiguate FP8/MXFP4 |
Thank you for your work on this, @am17an! I tried to use this together with the UD-Q8_K_XL from Unsloth, but it triggers an assertion on llama-server startup: System is a dual RTX PRO 6000 Max-Q. Full backtrace: Cmdline used: The draft model loads perfectly fine (and stays unused) when removing the draft-dspark cmdline argument: I'm currently running commit 221f0f6 So I guess the GGUF is not compatible with the UD-Q8_K_XL or is this some other issue? |
|
No, I’ve used it with the UD-Q8_K_XL just fine. I ran into an assertion when the output_weights weren’t on the same CUDA device as the DSpark model, so I had to override the placement of those weights. Maybe that’s what you’re running into? |
|
Found the same report here with dual RTX Pro 6000: #25784 (comment) The trick was to slightly raise GGML_SCHED_MAX_SPLIT_INPUTS: diff --git a/ggml/src/ggml-backend.cpp b/ggml/src/ggml-backend.cpp
index 7f4e252dc..02e56711a 100644
--- a/ggml/src/ggml-backend.cpp
+++ b/ggml/src/ggml-backend.cpp
@@ -754,7 +754,7 @@ static bool ggml_is_view_op(enum ggml_op op) {
#endif
#ifndef GGML_SCHED_MAX_SPLIT_INPUTS
-#define GGML_SCHED_MAX_SPLIT_INPUTS 30
+#define GGML_SCHED_MAX_SPLIT_INPUTS 40
#endif
#ifndef GGML_SCHED_MAX_COPIESToks/s almost doubled with DSpark! It was 54 toks/s before, now it once hit 101 toks/s and seems to stay around 88 toks/s. Wow! 🥳 |
|
I'm noticing that llama-imatrix has flags to turn on speculative decoding. Should I re-convert the GGUF with dpark/mtp bundled and regenerate imatrix or can I just re-run convert-hf-to-ggu.py passing |
|
Just saw that the separate dspark q8_0 gguf is about 10G. I guess that rules out using dspark if close to memory limit. |
|
That is when it's all in q8. q4 would be half its size |
It seems that the --dspark output GGUF is mostly MXFP4. When I tried to requantize to Q4_K the size actually increased. I also tried to re-convert the gguf without specifying |
|
Ah right I forgot everything is in MXFP4. I think |
|
Yea what I meant is that |
* convert: add option to create separate dspark GGUF * add --no-nextn * fix convert bug
* convert: add option to create separate dspark GGUF * add --no-nextn * fix convert bug
* convert: add option to create separate dspark GGUF * add --no-nextn * fix convert bug
* convert: add option to create separate dspark GGUF * add --no-nextn * fix convert bug
…ggml-org#961) main() has read args.dspark (:261) since the DeepSeek-V4/V4.1 DSpark draft path landed, but parse_args() never registered the flag, so every conversion from this branch -- every model, every outtype -- died with AttributeError: 'Namespace' object has no attribute 'dspark' before it reached the model. The block is upstream's verbatim: ggml-org/llama.cpp 3581ba0 "convert: add option to create separate dspark GGUF (ggml-org#26452)". This branch carries the caller and none of the flag, so this restores it rather than inventing a new one. Inert for every non-dspark conversion: converting Zyphra/ZR1-1.5B@6108a26d0cd7 to bf16 with this patch produces a file byte-identical to the reference built with the same four lines applied in a local workaround (3,560,417,696 B, sha256 d817473c0e56d2...). --dspark on a non-Deepseek model now reaches its own guard ("--dspark is only supported for DeepseekV4ForCausalLM and DeepseekV41ForCausalLM", exit 1) instead of dying on the attribute.
…ggml-org#961) main() has read args.dspark (:261) since the DeepSeek-V4/V4.1 DSpark draft path landed, but parse_args() never registered the flag, so every conversion from this branch -- every model, every outtype -- died with AttributeError: 'Namespace' object has no attribute 'dspark' before it reached the model. The block is upstream's verbatim: ggml-org/llama.cpp 3581ba0 "convert: add option to create separate dspark GGUF (ggml-org#26452)". This branch carries the caller and none of the flag, so this restores it rather than inventing a new one. Inert for every non-dspark conversion: converting Zyphra/ZR1-1.5B@6108a26d0cd7 to bf16 with this patch produces a file byte-identical to the reference built with the same four lines applied in a local workaround (3,560,417,696 B, sha256 d817473c0e56d2...). --dspark on a non-Deepseek model now reaches its own guard ("--dspark is only supported for DeepseekV4ForCausalLM and DeepseekV41ForCausalLM", exit 1) instead of dying on the attribute.
…ggml-org#961) (#187) main() has read args.dspark (:261) since the DeepSeek-V4/V4.1 DSpark draft path landed, but parse_args() never registered the flag, so every conversion from this branch -- every model, every outtype -- died with AttributeError: 'Namespace' object has no attribute 'dspark' before it reached the model. The block is upstream's verbatim: ggml-org/llama.cpp 3581ba0 "convert: add option to create separate dspark GGUF (ggml-org#26452)". This branch carries the caller and none of the flag, so this restores it rather than inventing a new one. Inert for every non-dspark conversion: converting Zyphra/ZR1-1.5B@6108a26d0cd7 to bf16 with this patch produces a file byte-identical to the reference built with the same four lines applied in a local workaround (3,560,417,696 B, sha256 d817473c0e56d2...). --dspark on a non-Deepseek model now reaches its own guard ("--dspark is only supported for DeepseekV4ForCausalLM and DeepseekV41ForCausalLM", exit 1) instead of dying on the attribute. Co-authored-by: bong-water-water-bong <[email protected]>
Overview
Additional information
Requirements