Archived
Cover Spark configuration refusals and CPU isolation caveat
This commit is contained in:
1 parent
125854df79
commit
48407fb52d
3 files changed
+12
-3
No files matched your search
@@ -101,8 +101,10 @@ SPARK25_REFERENCE_TEMPLATE=/path/to/XHToken-Spark-X2.6-4B/chat_template.jinja \
|
||||
```
|
||||
|
||||
The first builds a small deterministic checkpoint and compares prefill, chunked prefill and cached
|
||||
decode against the reference without a GPU. The second also exercises the checkpoint's actual chat
|
||||
template, which is not redistributed in this tree.
|
||||
decode against the reference with GPUs hidden. ROCm may still open GPU device nodes while probing
|
||||
even with visibility masks; on a shared machine run the CPU comparison in a device cgroup that
|
||||
denies access to `/dev/kfd` and the GPU render nodes. The second also exercises the checkpoint's
|
||||
actual chat template, which is not redistributed in this tree.
|
||||
|
||||
---
|
||||
|
||||
|
||||
@@ -96,7 +96,9 @@ TEST(refuses_unimplemented_variants) {
|
||||
std::pair{"gate_attn_act_mode", "silu"},
|
||||
std::pair{"hidden_act", "silu"},
|
||||
std::pair{"attention_bias", "1"},
|
||||
std::pair{"mlp_bias", "1"},
|
||||
std::pair{"layer_types", "sliding_attention"},
|
||||
std::pair{"rope_parameters.full_attention.rope_type", "dynamic"},
|
||||
std::pair{"rope_parameters.full_attention.partial_rotary_factor", "0.3"}}) {
|
||||
MetaKV k = spark_meta();
|
||||
k.set(change.first, change.second);
|
||||
@@ -104,6 +106,10 @@ TEST(refuses_unimplemented_variants) {
|
||||
CHECK(stderr_of_rc([&] { return spark25_bf16::declare(&b, k.meta(), &ctx); }) != RAD_OK);
|
||||
}
|
||||
MetaKV k = spark_meta();
|
||||
k.set("rope_scaling.rope_type", "linear").set("rope_scaling.factor", "2");
|
||||
RadBuilder scaled;
|
||||
CHECK(stderr_of_rc([&] { return spark25_bf16::declare(&scaled, k.meta(), &ctx); }) == RAD_E_UNSUPPORTED);
|
||||
k = spark_meta();
|
||||
RadBuilder b;
|
||||
ctx.world_size = 2;
|
||||
CHECK(stderr_of_rc([&] { return spark25_bf16::declare(&b, k.meta(), &ctx); }) == RAD_E_UNSUPPORTED);
|
||||
|
||||
@@ -3,7 +3,8 @@
|
||||
|
||||
Requires torch, transformers and safetensors. It creates a tiny two-layer random checkpoint,
|
||||
converts and serves it on the host, then compares prefill and cached decode with the HF reference.
|
||||
No model weights are copied from the reference checkpoint, and no GPU is visible to either process.
|
||||
No model weights are copied from the reference checkpoint, and GPUs are hidden from both processes.
|
||||
ROCm may still open device nodes when probing; use a GPU-denying device cgroup on shared machines.
|
||||
"""
|
||||
import argparse
|
||||
import importlib.util
|
||||
|
||||
Reference in new issue
Block a user