Error Parsing Hyper Parameters (`HPARAMS`) on Windows

未关闭
#7,175 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 1 天内回复

@Ramnath0521 已经在做这个了。

开始于 2026年11月16日。

  • #7176 来自 @Ramnath0521 —— 未关闭

评估

难度
2/5
预计耗时
1-3 小时
新手友好度
35/100
Issue 类型
缺陷
描述清晰度
描述清楚
活跃度
停滞
技术栈
python, typescript

调研方向

Start with tensorboard/plugins/hparams/metrics.py and inspect run_tag_from_session_and_metric, which the issue identifies as constructing the metric run path. Reproduce with the provided SummaryWriter.add_hparams example on Windows and check the HParams dashboard or JSON export. Done means the recorded metric values appear instead of null; an open pull request is already linked.

由索引模型根据 Issue 内容生成。

描述

Description
When viewing an experiment in TensorBoard’s HParams dashboard on Windows, the metric values are shown as null. Downloading the HParams data as JSON also returns null for the metrics.

The event files contain the expected scalar metrics, and the HParams session and experiment data are present. The issue appears to be in how the HParams plugin constructs the metric run path on Windows.

Steps to reproduce
Write HParams and numeric metrics with SummaryWriter.add_hparams:

from torch.utils.tensorboard import SummaryWriter

writer = SummaryWriter("logs/Model001")
writer.add_hparams(
    {"activation": "ELU"},
    {"train_loss": 0.16, "train_score": 0.95},
)
writer.close()

Launch TensorBoard on Windows and open the HParams dashboard.

View the experiment’s metrics or download the HParams data as JSON.

Expected behavior
The HParams dashboard and JSON export show the recorded metric values, such as 0.16 and 0.95.

Actual behavior
The metrics appear as null, despite being present in the event files.

Environment
OS: Windows
TensorBoard: 2.21.0
Possible cause
In tensorboard/plugins/hparams/metrics.py, run_tag_from_session_and_metric joins the session name and metric group, then only removes a trailing forward slash (/). On Windows, os.path.join(session_name, "") can produce a trailing backslash (), which is not removed. The resulting run path may not match the actual run name, causing the metric lookup to fail.

主要语言
TypeScript
星标
7.2k
派生
1.7k
平均合并
1 天 13 小时
30 天内合并 PR
3

环境准备

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

tensorflow/tensorboard 的其他 Issue

查看 tensorflow/tensorboard 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。