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
Check if variable is None inside njitted function is neither True nor False with parallel=True #5747
Comments
@jtilly thanks for submitting this to the Numba issue tracker. I will label it as needing triage for now. |
O.K. it seems like I can reproduce this locally, it is likely a bug in the parallel accelerator. Probably one of the next steps will be to use |
I took a stab at it. Last good commit that I could find: 868b8e3 First commit that throws no error but produces the result I'm reporting above: 2d33fb1
The diff between good and bad is here. For commits in between I get two types of error messages:
|
CC @DrTodd13, I can reproduce this on mainline for ~0.54 series releases. Doesn't appear to be related to the branch pruner, could be an SSA interaction with parfors, perhaps a versioned variable that needs to be unversioned? |
the change log (https://github.com/numba/numba/blob/master/CHANGE_LOG).
to write one see http://matthewrocklin.com/blog/work/2018/02/28/minimal-bug-reports).
This problem is new in v0.49.x. It only occurs when using
parallel=True
.I have two functions
test
andtest2
that are identical except for thattest
checksif weight is not None
andtest2
checksif weight is None
.test
produces the correct result, i.e. it sums up the weights (=2.5).test2
thinks thatweight is not None
is neitherTrue
norFalse
and returns 0.Environments
I'm running this on Linux with the conda-forge versions of numba and numpy.
The text was updated successfully, but these errors were encountered: