test_relpos_attention_local: local (rel_pos_local_attn) attention diverges from NeMo
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 52/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Ít trao đổi
- Lĩnh vực
- machine-learning, testing-qa
Hướng nghiên cứu
Bắt đầu với forward_local và tệp thực thi test_relpos_attention_local, sau đó so sánh cách nó xử lý layout pos_emb đã dump và cửa sổ attention với scripts/gen_nemo_baseline.py. Tái hiện sai khác CPU f32 tại W=64 và W=32; được xem là hoàn tất khi đầu ra C++ phản hồi với W và khớp với NeMo baseline, trong khi các kiểm thử chunked và memory vẫn pass.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
While building a full NeMo-baseline set to run the model-dependent test suite, I
hit a divergence in the local (Longformer) attention path that looks separate
from #39 (the streaming O(N²) fix) — filing it on its own.
Symptom
test_relpos_attention_local fails on the 110m anchor, on CPU (PARAKEET_DEVICE=cpu,
f32 GGUF), so it isn't iGPU fp16 tolerance:
[relpos_attention_local] n=47616 max|d|=3.349e+02 mean|d|=9.779e+00 (worst@47338 got=0.44526 ref=335.37750) -> FAIL
The divergence is broad (mean |d| ≈ 10, not a single element) and the worst point
is the last time frame (worst index 47338 = frame 92 of T=93, d_model=512).
It's not the --att-context-size (W) chosen for the baseline
I regenerated PARAKEET_TEST_BASELINE_LOCAL at two windows and re-ran:
| W | result |
|---|---|
| 64 | worst@47338 got=0.44526 ref=335.37750 |
| 32 | worst@47338 got=0.44526 ref=356.31686 |
The C++ output (got) is identical across W while NeMo's ref changes — i.e.
forward_local does not respond to the window the baseline encodes. (W=128 is
correctly rejected by the test since W ≥ T.)
test_relpos_attention_local_chunked and test_relpos_attention_local_memory
pass (they use an internal brute-force reference), so the gap is specific to
the non-chunked forward_local vs the NeMo rel_pos_local_attn baseline.
Reproduce
# baseline (NeMo): local attention with a finite window over speech.wav
python scripts/gen_nemo_baseline.py \
--model nvidia/parakeet-tdt_ctc-110m \
--audio tests/fixtures/speech.wav \
--att-context-size 64 --output /tmp/baseline_local.gguf
# convert the 110m anchor to f32 gguf -> PARAKEET_TEST_GGUF
PARAKEET_DEVICE=cpu \
PARAKEET_TEST_GGUF=/tmp/pk110m-f32.gguf \
PARAKEET_TEST_BASELINE_LOCAL=/tmp/baseline_local.gguf \
./build/tests/test_relpos_attention_local
Question
Is this a known limitation, a layout/convention mismatch between the dumped
pos_emb ([2W+1, d_model]) and what forward_local expects, or a real bug in
the non-chunked local path? Happy to dig into forward_local if it's worth a fix.
- Ngôn ngữ chính
- C++
- Star
- 786
- Fork
- 93
- Merge trung bình
- 9 ngày 19 giờ
- Pull request đã merge (30 ngày)
- 4
Chuẩn bị môi trường
Chúng tôi chưa kiểm tra các tệp thiết lập môi trường của dự án này. Hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của mudler/parakeet.cpp
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 55/100
mudler/parakeet.cpp#68 ·
-
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 58/100
mudler/parakeet.cpp#62 ·
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 58/100
mudler/parakeet.cpp#61 ·
-
Real streaming from a micĐang mở
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 48/100
mudler/parakeet.cpp#60 ·
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 48/100
mudler/parakeet.cpp#59 · 3 bình luận ·
Tất cả issue của mudler/parakeet.cpp
Issue tương tự
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 92/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
cp-algorithms/cp-algorithms#1715 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
Icinga/icinga2#11058 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
status:needs-triage
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100
PX4/PX4-Autopilot#28924 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
component: split-view platform: windows
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 74/100
zen-browser/desktop#15616 · 1 reaction ·
Maintainer thường phản hồi trong vòng 1 ngày