fix: 修复文档多处不准确 + inference scheduler 越界 bug + SchedulerCallback 回调阶段修正
文档 (6 个文件): - design.md: 15+ 处修正 — persistent_key_values→paged_cache, MLA 字段重写, Server/ParallelSetup 不存在类移除, 关系箭头方向修复, SchedulerCallback 阶段修正等 - dataflow.md: 重写数据流图和描述, 修复训练回调顺序、 数据键名、MLA 归属、MetricTracker 等错误 - introduction.md: 层数 32→24, MLP 图双 Linear 修正, 默认值/响应字段/health 端点修复 - params.md: 补充 grpo 及 4 个 GRPO 参数 - README.md / README-zh-CN.md: generate.py 补全必需参数, 删除重复注释, HuggingFace 声明修正 代码 (2 个文件): - scheduler.py: n_pages 池加 page_size 余量防止越界; decode 前预分配页 - train_callback.py: SchedulerCallback 从 on_step_end 改 回 on_batch_end (按 batch 步进学习率)
This commit is contained in:
@@ -104,7 +104,7 @@ class SchedulerCallback(TrainCallback):
|
||||
if "initial_lr" not in group:
|
||||
group["initial_lr"] = group["lr"]
|
||||
|
||||
def on_step_end(self, context: TrainContext):
|
||||
def on_batch_end(self, context: TrainContext):
|
||||
if context.scheduler:
|
||||
context.scheduler.step()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user