DeadlineExceeded failures in test_eye/test_linspace
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 2/5
- Tiempo estimado
- 1-3 horas
- Aptitud para principiantes
- 45/100
Línea de trabajo
Ejecuta el comando de pytest indicado e inspecciona array_api_tests/test_creation_functions.py, centrándote en test_eye y test_linspace. Traza los tamaños de dimensión generados y aplica la restricción sobre el tamaño máximo propuesta en el issue. Se considera completado cuando ambas pruebas terminan sin fallos Hypothesis DeadlineExceeded.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
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.
- Lenguaje dominante
- Python
- Estrellas
- 74
- Forks
- 54
- Merge medio
- 4 h 35 min
- PR fusionados (30 d)
- 4
Guía de contribución
No hay ninguna guía de contribución indexada para este repositorio
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de data-apis/array-api-tests
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 87/100
data-apis/array-api-tests#465 · 1 comentario ·
-
Test reflected operators? Abierto
Dificultad 3/5 1-2 días Aptitud para principiantes 68/100
data-apis/array-api-tests#460 · 1 comentario ·
-
Dificultad 3/5 1-2 días Aptitud para principiantes 68/100
data-apis/array-api-tests#455 · 2 comentarios ·
-
tracking
Dificultad 5/5 Más de una semana Aptitud para principiantes 25/100
data-apis/array-api-tests#381 · 9 comentarios ·
-
Dificultad 5/5 Más de una semana Aptitud para principiantes 38/100
data-apis/array-api-tests#379 · 10 comentarios ·
Todos los issues de data-apis/array-api-tests
Issues similares
-
bug confirmed issue
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
open-webui/open-webui#30750 · 1 comentario ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
-
enhancement
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
OpenwaterHealth/openmotion-bloodflow-app#604 · 1 comentario ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
-
good first issue
Dificultad 1/5 Menos de una hora Aptitud para principiantes 90/100