arviz icon indicating copy to clipboard operation
arviz copied to clipboard

Make use of numba opt-in not opt-out

Open ricardoV94 opened this issue 2 years ago • 3 comments

Calling forest_plot when numba is installed ends up with cryptic errors: ValueError: Failed in object mode pipeline (step: remove phis nodes) This is a PITA.

Please consider making the use of numba opt-in (not simply by having numba installed).

ricardoV94 avatar Feb 21 '24 11:02 ricardoV94

If we wanted to do this, I think (almost?) everything is already there. We just need to make sure that

https://github.com/arviz-devs/arviz/blob/7c1637f6d4574bc8ba5757165f9e7bb02e202621/arviz/utils.py#L200

is not True by default when numba is installed (which is the case now)

tomicapretto avatar Feb 22 '24 15:02 tomicapretto

Sounds good to me, the only change would be in https://github.com/arviz-devs/arviz/blob/7c1637f6d4574bc8ba5757165f9e7bb02e202621/arviz/utils.py#L328 make it False instead of the result of numba_check.

I'll also look into the error, it might not change much between using numba there or not if its in object mode.

OriolAbril avatar Feb 22 '24 17:02 OriolAbril

+1: I'm hitting this error as well

drbenvincent avatar Feb 28 '24 12:02 drbenvincent