docs: add PassBench evaluation pipeline documentation (#95)
- docs: add PassBench evaluation pipeline documentation
- Add pass_bench/README.md with 5-step pipeline overview, pass file format (interface table), pass_dir placement, single-sample and batch evaluation instructions
- Update README.md and README_cn.md to include the 5-step pipeline and link to pass_bench/README.md
- Update pass_agent/README.md to reference the new doc location
Co-Authored-By: Claude Sonnet 4.6 noreply@anthropic.com
- docs: expand PassBench evaluation pipeline documentation
- Add Chinese READMEs for pass_bench/ and pass_agent/
- Detail 5-step pipeline with dtype-specific correctness thresholds, pass file format, pass_mgr matching flow, and ES(t) scoring
- Clarify pass_evaluator is the PassBench backend in PassAgent
- Simplify outer README pipeline summary (LLM generates pass, copy to pass_dir)
- Add English/Chinese toggle links in pass_bench and pass_agent READMEs
Co-Authored-By: Claude Sonnet 4.6 noreply@anthropic.com
Co-authored-by: Claude Sonnet 4.6 noreply@anthropic.com
版权所有:中国计算机学会技术支持:开源发展技术委员会
京ICP备13000930号-9
京公网安备 11010802047560号
PassNet
PassNet 是一个面向编译器优化的 AI 系统,利用大语言模型(LLM)驱动的 Agent 自动生成高性能 GPU 算子,通过编译器 Pass 机制实现计算图优化。PassNet 包含完整的优化工具链、评测基准 PassBench 以及 Agent 评估框架 PassAgent。
English | 中文
目录
项目结构
架构概览
核心组件
PassBench — 编译器评测框架
提供算子编译、正确性验证与性能评测能力,既可独立使用,也作为 PassAgent 的评测后端:
pass_mgr编译器方法执行 Pass 匹配与替换aggregated_score.jsonaggregate_es_scores.py计算样本内所有计算图的 ES(t) 分数PassAgent — R2E-Gym Agent 评估框架
基于 R2E-Gym 框架评估 Agent 的编译器优化能力。详见 pass_agent/README.md。
数据集
graphs — 子图原始数据
存放从深度学习模型中提取的原始计算子图,作为 PassBench 样本的生成来源:
sole_op_subgraphs:单算子子图(5,939 个)fusible_subgraphs:可融合子图(22,870 个)typical_subgraphs:经典子图(25,151 个)graph_lists — 子图列表与分组
存放子图的路径列表、UID 分组等信息,用于样本筛选和分组管理:
子图路径列表(每行格式:
子图UID\t子图相对路径)fusible_subgraphs.txthf_sole_op_subgraphs.txthf_fusible_subgraphs.txthf_typical_subgraphs.txthf_sole_op_subgraphs_v2.txthf_fusible_subgraphs_v2.txthf_typical_subgraphs_v2.txtsamples — PassBench 评测样本
从
graphs/中加工生成的评测样本,每个样本为独立可执行的评测单元:模型名/子图编号组织xx/yy/hash/组织,子图数据集发布于 PassNet/PassNet每个样本目录包含:
entry.shgraph_list.txtgraphs/pass_dir/pass_bench/sample_uids.txtsample_lists — 评测/训练样本划分
存放用于评测和训练的样本路径列表,按用途和子图类型组织,同时提供 txt 和 csv 格式:
**train/**(训练集)
hf_sole_op_train_samples_v2.txthf_fusible_train_samples_v2.txthf_typical_train_samples_v2.txthf_sole_op_train_samples.txt(Legacy)hf_fusible_train_samples.txt(Legacy)hf_typical_train_samples.txt(Legacy)**eval/**(评估集)
hf_fusible_eval_samples_v2.txthf_typical_eval_samples_v2.txthf_fusible_eval_samples.txt(Legacy)hf_typical_eval_samples.txt(Legacy)快速开始
环境要求
安装
运行示例
Docker 使用
构建镜像
容器内验证单个样本执行
PassBench评测流程
PassNet 的评测流程如下:
model.py和weight_meta.py,理解目标子图的算子结构、张量形状及数据类型pass_dir/目录下pass_mgr在 FX 图中匹配目标模式,将其替换为优化算子aggregated_score.jsonPass 文件格式及批量评测说明见 **pass_bench/README.md**。
PassAgent 评估
使用 PassAgent 框架评估 Agent:
详见 pass_agent/README.md。
许可证
请参阅项目根目录下的许可证文件。