-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
mapreduce(abs, max, Int[]) returns 0 #28028
Comments
See also #27845. Cc: @andreasnoack |
To handle the empty case in general, we'd probably have to be able to reason about the range of the function which isn't and probably won't ever be possible. However, the current special casing behavior isn't wrong. Maybe just not that elegant. Returning |
This is also discussed in #28535. |
Triage approved and will merge this in #29919 |
I see the mathematical justification for these two special cases, but they seem too clever for me. They also raise several questions:
exp
)?Inf
/-Inf
ortypemax(T)
/typemin(T)
for all functions?See also this discussion in Numpy: numpy/numpy#5032
The text was updated successfully, but these errors were encountered: