[FEA]: Support inheritance from Buffer
还没有人认领这个 Issue。
评估
调研方向
首先定位 cuda.core 的 Buffer 实现及其 from_handle() 和 _reduce_helper() 方法,然后检查返回的实例是如何构造的。查看相关 issue #750 和 Buffer 的相关行为;当子类继承这两个方法并获得子类实例,同时不破坏现有的 Buffer 行为时,即完成此项工作。
由索引模型根据 Issue 内容生成。
描述
Is this a duplicate?
- I confirmed there appear to be no duplicate issues for this request and that I agree to the Code of Conduct
Area
cuda.core
Is your feature request related to a problem? Please describe.
nvmath-python is considering creating a subclass of Buffer specific to NVSHMEM because we want to mostly follow cuda.core's semantics for Buffer/MemoryResource, but need some different behavior regarding garbage collection.
Describe the solution you'd like
Buffer should use classmethod instead of staticmethod for all methods that return an instance of the class. i.e. from_handle() and _reduce_helper()
Describe alternatives you've considered
Composing Buffer with our Buffer.
Replicating the Buffer protocol with an unrelated class.
Rolling our own MemoryResource/Buffer abstraction that is unique to nvmath's distributed APIs.
Additional context
Related to: https://github.com/NVIDIA/cuda-python/issues/750
- 主要语言
- Cython
- 星标
- 3.4k
- 派生
- 329
- 平均合并
- 1 天 21 小时
- 30 天内合并 PR
- 113
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
NVIDIA/cuda-python 的其他 Issue
-
bug cuda.core
难度 2/5 1-3 小时 新手友好度 76/100
NVIDIA/cuda-python#2886 · 1 条评论 ·
-
triage
难度 1/5 1 小时以内 新手友好度 88/100
NVIDIA/cuda-python#2717 ·
-
triage
难度 1/5 1-3 小时 新手友好度 90/100
NVIDIA/cuda-python#2712 ·
-
triage
难度 2/5 1-3 小时 新手友好度 82/100
NVIDIA/cuda-python#2646 · 1 个 reaction ·
-
CI/CD
NVIDIA/cuda-python#2926 · 已指派 1 人 ·
查看 NVIDIA/cuda-python 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 78/100
use-agent-os/agent-os#3276 ·
-
good first issue refactor
难度 2/5 1-3 小时 新手友好度 72/100
-
难度 1/5 1 小时以内 新手友好度 90/100
-
难度 2/5 1-3 小时 新手友好度 86/100
-
area/sessions comp/agent P2 tool/skills type/perf
难度 2/5 1-3 小时 新手友好度 82/100
NousResearch/hermes-agent#117788 ·