pytensor
pytensor copied to clipboard
Remove redundant code after numpy < 2.0 is deprecated
I've noticed that some of the code like this is redundant now. E.g.
x * np.array(math.log(2.0)).astype(x.dtype)is now the same asx * math.log(2.0)because numpy now uses the type ofxhere. For backwards compatibility, maybe we should leave theastypeconversion for now, but once numpy 1.26 support is dropped, this won't be needed.
Originally posted by @brendan-m-murphy in https://github.com/pymc-devs/pytensor/pull/1194#discussion_r1954233758
Depends on:
- #1216