Closed
[Documentation|文档反馈]: CoalesceSparse 将 unique_indices 误述为去重列表,未说明原条目到输出组号的映射 #4235
daishuangshuangAdd on 12 days agoClosed at 4 days ago
11 days ago changed custom category from 任务 to 缺陷
陈思
11 days ago Comments:
11 days ago Comments:
您好,感谢反馈。核对 ae087b184 后,这处参数说明确实需要修正。
README 将 unique_indices 写成“去重后的索引数组”,但 SetIndices / ValueAtomicAdd 都按原条目读取该数组,并把读取值作为输出组号:坐标写入 new_indices[group, :],数值累加到 new_values[group, ...]。确定性分支使用同一映射含义。因此该参数应包含每个原始条目对应的组号,而不是一份去重后的坐标列表。
建议参数表明确:若原始条目数为 nnz,则 unique_indices 为长度 nnz 的映射,第 i 项表示第 i 条原始输入对应的输出组号,满足 0 <= unique_indices[i] < unique_len;同组条目应具有相同坐标。例如原始坐标依次为 A、B、A,可传入 [0, 1, 0]、unique_len=2,输出第 0 组累加两条 A 的值,第 1 组保留 B 的值。还应保留调用前 new_values 已清零的现有约束。
以上结论来自固定版本源码核对,属于文档语义修正;尚未据此修改实现或进行设备验证。


11 days ago Assign chensi79 as responsible person
11 days ago Added label: pending-confirmation
11 days ago Assign yue-ma as responsible person
11 days ago Removed responsible person chensi79
11 days ago Removed label: pending-confirmation
4 days ago Associated pull request
4 days ago Close issue
4 days ago Added label: resolved
1)标题
[Documentation|文档反馈] CoalesceSparse 将 unique_indices 误述为去重列表,未说明原条目到输出组号的映射
2)文档链接
GitCode 文档定位 · 本地快照:conversion/coalesce_sparse/README.md
3)问题文档片段
原文第 44–48 行:
4)存在的问题(选填)
SIMT Kernel 按 uniqueIndices[index/m] 或 uniqueIndices[index/valueSize] 取得输出组号,说明它是长度为原始 nnz 的映射数组,不是一份长度为 unique_len 的去重坐标列表。ACLNN 调用者需要自行准备该参数,当前表述可能导致长度和含义均构造错误。建议写明“第 i 项表示第 i 条原始输入对应的输出组号”、合法范围 [0,unique_len) 及映射示例,例如重复条目可对应 [0,1,0]。