Qualcomm AI Engine Direct: a delegated mutable buffer starts from leftover memory
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 48/100
- issue の種類
- バグ
- 明瞭さ
- おおむね明確
- 活発さ
- 活発
- 技術スタック
- python
調査の方向性
Start by reading the QNN partitioner logic that decides whether mutable buffers are delegated, including the int64 special case, and trace how delegated buffers are initialized before their first run. Reproduce the counter example with the QNN SDK 2.51 x86 simulator and compare delegated results with CPU results. Done means delegated buffers begin with the registered value across dtypes, and the int64 special case can be removed.
索引モデルが issue の本文から書いたものです。
説明
When the QNN partitioner delegates a mutable buffer (the default,
skip_mutable_buffer=False), the buffer lives in memory that the QNN delegate
owns. Nothing sets that memory before the first run, so the buffer starts from
whatever the memory held. The result is wrong with no error.
Example: a counter that should start at zero.
class Int32Counter(torch.nn.Module):
def __init__(self):
super().__init__()
self.register_buffer("count", torch.zeros(2, dtype=torch.int32))
def forward(self, x):
self.count.add_(x.argmax(-1).to(torch.int32))
return x * 2, self.count + 0
With x = [[0.1, 0.9, 0.2], [0.7, 0.1, 0.3]] the first run should return
count = [1, 0]. Lowered for HTP float16 and run on the QNN SDK 2.51 x86
simulator, it returns values like [-1486893823, 32716], different on every
run.
Int64 buffers already stay on CPU for this reason, and the same counter with
an int64 buffer comes out right. Buffers of other dtypes,
including float buffers such as KV caches, are still delegated.
Expected: a delegated buffer starts from the same value as a CPU one, so the
int64 special case in the partitioner can go.
cc @cccclai @winskuo-quic @shewu-quic @haowhsu-quic @DannyYuyang-quic @qti-horodnic @cbilgin @abhinaykukkadapu @psiddh
- 主要言語
- Python
- スター
- 5.2k
- フォーク
- 1.2k
- 平均マージ
- 1日 23時間
- マージ済み PR(30日)
- 696
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
pytorch/executorch のほかの issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 74/100
pytorch/executorch#24434 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
pytorch/executorch#24410 ·
メンテナーはふだん 1 日以内に返信
-
enhancement triaged
難易度 2/5 半日 初心者へのやさしさ 68/100
pytorch/executorch#21640 ·
メンテナーはふだん 1 日以内に返信
-
module: qnn partner: qualcomm
難易度 4/5 3〜5日 初心者へのやさしさ 45/100
pytorch/executorch#24750 ·
メンテナーはふだん 1 日以内に返信
-
CUDA AOTI:`reinterpret_tensor` drops the source tensor's storage offset対応中かも @mshr-h が今日担当しました。 オープン
難易度 3/5 1〜2日 初心者へのやさしさ 35/100
pytorch/executorch#24737 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
pytorch/executorch の issue をすべて見る
似ている issue
-
bug
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
Textualize/textual#6753 · コメント 1 件 ·
-
priority:low size:small
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
RonaldHensbergen/composable-data-stack#1177 ·
メンテナーはふだん 1 日以内に返信
-
Use registered media types for HDF5 and NetCDF, and stop claiming media_type must be IANA-registeredオープンdocumentation metadata
難易度 2/5 1〜3時間 初心者へのやさしさ 87/100
メンテナーはふだん 1 日以内に返信
-
check-typing: ty 0.0.98+ fails on the renamed rule `unresolved-import` (now `import-not-found`)対応中かも @oberstet が今日担当しました。 オープン
難易度 1/5 1時間未満 初心者へのやさしさ 91/100
crossbario/cfxdb#145 ·