Closed ndgrigorian closed 23 hours ago
Deleted rendered PR docs from intelpython.github.com/dpctl, latest should be updated shortly. :crossed_fingers:
Array API standard conformance tests for dpctl=0.18.0dev0=py310h15de555_80 ran successfully. Passed: 894 Failed: 15 Skipped: 105
Array API standard conformance tests for dpctl=0.18.0dev0=py310h15de555_81 ran successfully. Passed: 894 Failed: 15 Skipped: 105
CI failure is unrelated to this PR, I will go ahead and merge it
This PR proposes a change to
dpt.where
to add support for Python scalars, aligning it withclip
and elementwise functions.As has been pointed out by the array API community, an common use-case for
dpt.where
is supporting Python scalars. If the decision to permit them in other elementwise functions is made,where
will likely follow suit.Regardless of the outcome of this decision, it's sensible to support them here.
As the first argument (
condition
) does not participate in the type promotion inwhere
, if both arguments are scalars, the scalars are treated as the default types for the respective kind.