DeadlineExceeded failures in test_eye/test_linspace
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 2/5
- Thời gian dự kiến
- 1-3 giờ
- Mức phù hợp với người mới
- 45/100
Hướng nghiên cứu
Chạy lệnh pytest được liệt kê và kiểm tra array_api_tests/test_creation_functions.py, tập trung vào test_eye và test_linspace. Theo dõi kích thước các chiều được tạo ra và áp dụng giới hạn về kích thước tối đa được đề xuất trong issue. Hoàn tất khi cả hai test kết thúc mà không có lỗi Hypothesis DeadlineExceeded.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Running array-api-tests suite on dpctl.tensor (https://github.com/IntelPython/dpctl):
ONEAPI_DEVICE_SELECTOR=*:cpu ARRAY_API_TESTS_MODULE=dpctl.tensor python -m pytest array_api_tests/test_creation_functions.py
two test new failures consistently occur (after updating from f82c7bc8627cc2c3a44fa3e425f53a253a609aa8 to recent tip of main, i.e. 9d7777bc60d45a35124b0de084ff8edbd284c06b), e.g.:
FAILED array_api_tests/test_creation_functions.py::test_eye - hypothesis.errors.DeadlineExceeded: Test took 1470.80ms, which exceeds the deadline of 800.00ms
FAILED array_api_tests/test_creation_functions.py::test_linspace - hypothesis.errors.DeadlineExceeded: Test took 864.40ms, which exceeds the deadline of 800.00ms
Here is my understanding of what happens.
Hypothesis would generate a sufficiently large array, i.e. eye(47, 100) but testing of the output correctness is is done one element at the time (suboptimal usage for offloading libraries as it triggers 4700 submissions of small kernels) and this testing would take much longer than the creation of the array itself:
In [7]: import dpctl, dpctl.tensor as dpt
In [8]: %time eye_m = dpt.eye(47,100)
CPU times: user 3.23 ms, sys: 0 ns, total: 3.23 ms
Wall time: 2.76 ms
In [9]: %time all(eye_m[i, j] == (1 if i == j else 0) for i in range(eye_m.shape[0]) for j in range(eye_m.shape[1]))
CPU times: user 6.68 s, sys: 1.98 s, total: 8.67 s
Wall time: 2.09 s
Out[9]: True
The remedy would be to restrict the maximal dimension size.
- Ngôn ngữ chính
- Python
- Star
- 74
- Fork
- 54
- Merge trung bình
- 4 giờ 35 phút
- Pull request đã merge (30 ngày)
- 4
Hướng dẫn đóng góp
Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này
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 data-apis/array-api-tests
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 87/100
data-apis/array-api-tests#465 · 1 bình luận ·
-
Test reflected operators? Đang mở
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 68/100
data-apis/array-api-tests#460 · 1 bình luận ·
-
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 68/100
data-apis/array-api-tests#455 · 2 bình luận ·
-
tracking
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 25/100
data-apis/array-api-tests#381 · 9 bình luận ·
-
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 38/100
data-apis/array-api-tests#379 · 10 bình luận ·
Tất cả issue của data-apis/array-api-tests
Issue tương tự
-
bug confirmed issue
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
open-webui/open-webui#30750 · 1 bình luận ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
-
enhancement
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
OpenwaterHealth/openmotion-bloodflow-app#604 · 1 bình luận ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
-
good first issue
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 90/100