[BUG] Rust DatasetView::new fails on padded rows: cuvsDatasetMakePaddedView only accepts packed rows
Maintainer thường phản hồi trong vòng 1 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức phù hợp với người mới
- 45/100
Hướng nghiên cứu
Start with is_cagra_padded_layout in rust/cuvs/src/dataset.rs, which decides when DatasetView::new calls cuvsDatasetMakePaddedView, then read the packed-row check in c/src/core/detail/interop.hpp around line 99. Reproduce with a 3-column f32 tensor whose strides are [4, 1]. Done means either the padded path accepts that layout, matching the C++ make_device_padded_dataset_view, or DatasetView::new rejects it with a clear error and the docs say so. Pick the direction first, since it decides whether the change is in C or in Rust.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Describe the bug
DatasetView::new decides whether a tensor is padded by reading its row stride (is_cagra_padded_layout). A padded tensor goes to cuvsDatasetMakePaddedView. But that function only accepts packed rows, so a tensor with padded rows always fails:
| Tensor | DatasetView::new picks |
Result |
|---|---|---|
4 f32 columns, packed |
padded view | ✓ |
3 f32 columns, packed |
standard view | ✓ |
3 f32 columns, rows padded to 4 (strides [4, 1]) |
padded view | ✗ Expected a row-major matrix |
Steps/Code to reproduce bug
let res = Resources::new().unwrap();
let mut data = std::ptr::null_mut();
unsafe { cudaMalloc(&mut data, 8 * 4 * size_of::<f32>()) };
let device = DLDevice { device_type: DLDeviceType::kDLCUDA, device_id: 0 };
// 8 rows of 3 columns, each row padded to 4 values.
let view = unsafe {
DLTensorView::from_raw_parts(data, device, &[8, 3], Some(&[4, 1]), f32::dl_dtype())
}
.unwrap();
DatasetView::new(&res, &view).unwrap();
// RAFT failure at .../c/src/core/detail/interop.hpp line=99: Expected a row-major matrix
Expected behavior
Either cuvsDatasetMakePaddedView accepts padded rows, as the C++ make_device_padded_dataset_view does, or DatasetView::new rejects a strided tensor with a clear error and its docs say so.
Environment details
- Bare-metal, RTX 1000 Ada
- conda
libcuvs 26.10.00a61(CUDA 13.3); the code is unchanged at24b0b170
Additional context
Might be related: #2482, #2394 (tracker #2402).
- Ngôn ngữ chính
- Cuda
- Star
- 902
- Fork
- 267
- Merge trung bình
- 2 ngày 21 giờ
- Pull request đã merge (30 ngày)
- 57
Chuẩn bị môi trường
- Có Dockerfile hoặc tệp Docker Compose
- Có mẫu pull request
- Đọc hướng dẫn đóng góp
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 NVIDIA/cuvs
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100
Maintainer thường phản hồi trong vòng 1 ngày
-
[BUG] CAGRA multi-CTA and multi-kernel search over-allocate the hashmap they useCó thể đã có người làm @mc8max đã nhận 12 ngày trước. Đang mởbug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
NVIDIA/cuvs#2856 · 2 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
[BUG] cuVS Bench Faiss CAGRA b_ratio reads the wrong JSON keyCó thể đã có người làm @arcusbuilds đã nhận 55 ngày trước. Đang mởbug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 84/100
Maintainer thường phản hồi trong vòng 1 ngày
-
doc
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Upgrade faiss to v1.16.0Có thể đã có người làm @aamijar đã nhận 8 ngày trước. Đang mởfaiss improvement
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 86/100
Maintainer thường phản hồi trong vòng 1 ngày
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
vllm-project/vllm#70030 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
help wanted small extra
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
Maintainer thường phản hồi trong vòng 1 ngày
-
t: bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
Maintainer thường phản hồi trong vòng 3 ngày
-
Retry an empty final answer when Gemini reports MALFORMED_RESPONSE (gemini-4-hydrogen)Có thể đã có người làm @waleedkadous đã nhận hôm nay. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 62/100
iaser-ai/ansari#444 · 1 bình luận ·
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 66/100
Maintainer thường phản hồi trong vòng 1 ngày