Commit e98de4d
committed
Implemented and deployed validate_type_for_device<T>(q)
This check would produce more succint error message:
```
In [1]: import dpctl.tensor as dpt
In [2]: dpt.arange(0, 10, dtype='f8')
---------------------------------------------------------------------------
RuntimeError Traceback (most recent call last)
Input In [2], in <cell line: 1>()
----> 1 dpt.arange(0, 10, dtype='f8')
File ~/repos/dpctl/dpctl/tensor/_ctors.py:603, in arange(start, stop, step, dtype, device, usm_type, sycl_queue)
601 _step = sc_ty(1)
602 _start = _first
--> 603 hev, _ = ti._linspace_step(_start, _step, res, sycl_queue)
604 hev.wait()
605 if is_bool:
RuntimeError: Device Intel(R) Graphics [0x9a49] does not support type 'double'
```1 parent 7d1904c commit e98de4d
File tree
3 files changed
+44
-0
lines changed- dpctl/tensor/libtensor/include
- kernels
- utils
3 files changed
+44
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
129 | 129 | | |
130 | 130 | | |
131 | 131 | | |
| 132 | + | |
132 | 133 | | |
133 | 134 | | |
134 | 135 | | |
| |||
270 | 271 | | |
271 | 272 | | |
272 | 273 | | |
| 274 | + | |
| 275 | + | |
273 | 276 | | |
274 | 277 | | |
275 | 278 | | |
| |||
378 | 381 | | |
379 | 382 | | |
380 | 383 | | |
| 384 | + | |
381 | 385 | | |
382 | 386 | | |
383 | 387 | | |
| |||
496 | 500 | | |
497 | 501 | | |
498 | 502 | | |
| 503 | + | |
499 | 504 | | |
500 | 505 | | |
501 | 506 | | |
| |||
576 | 581 | | |
577 | 582 | | |
578 | 583 | | |
| 584 | + | |
| 585 | + | |
579 | 586 | | |
580 | 587 | | |
581 | 588 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
215 | 215 | | |
216 | 216 | | |
217 | 217 | | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
218 | 221 | | |
219 | 222 | | |
220 | 223 | | |
| |||
317 | 320 | | |
318 | 321 | | |
319 | 322 | | |
| 323 | + | |
| 324 | + | |
| 325 | + | |
320 | 326 | | |
321 | 327 | | |
322 | 328 | | |
| |||
486 | 492 | | |
487 | 493 | | |
488 | 494 | | |
| 495 | + | |
| 496 | + | |
| 497 | + | |
| 498 | + | |
489 | 499 | | |
490 | 500 | | |
491 | 501 | | |
| |||
637 | 647 | | |
638 | 648 | | |
639 | 649 | | |
| 650 | + | |
| 651 | + | |
640 | 652 | | |
641 | 653 | | |
642 | 654 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
23 | 23 | | |
24 | 24 | | |
25 | 25 | | |
| 26 | + | |
26 | 27 | | |
| 28 | + | |
27 | 29 | | |
28 | 30 | | |
29 | 31 | | |
| |||
68 | 70 | | |
69 | 71 | | |
70 | 72 | | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
71 | 96 | | |
72 | 97 | | |
73 | 98 | | |
0 commit comments