Skip to content

Commit dbd8912

Browse files
committed
remove uutdated deprecations from pytensor/tensor/math.py
1 parent f7ea8df commit dbd8912

File tree

1 file changed

+0
-25
lines changed

1 file changed

+0
-25
lines changed

pytensor/tensor/math.py

Lines changed: 0 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -3133,28 +3133,3 @@ def matmul(x1: "ArrayLike", x2: "ArrayLike", dtype: Optional["DTypeLike"] = None
31333133
"logaddexp",
31343134
"logsumexp",
31353135
]
3136-
3137-
DEPRECATED_NAMES = [
3138-
("abs_", "`abs_` is deprecated; use `abs` instead.", abs),
3139-
("inv", "`inv` is deprecated; use `reciprocal` instead.", reciprocal),
3140-
]
3141-
3142-
3143-
def __getattr__(name):
3144-
"""Intercept module-level attribute access of deprecated symbols.
3145-
3146-
Adapted from https://stackoverflow.com/a/55139609/3006474.
3147-
3148-
"""
3149-
from warnings import warn
3150-
3151-
for old_name, msg, old_object in DEPRECATED_NAMES:
3152-
if name == old_name:
3153-
warn(msg, DeprecationWarning, stacklevel=2)
3154-
return old_object
3155-
3156-
raise AttributeError(f"module {__name__} has no attribute {name}")
3157-
3158-
3159-
def __dir__():
3160-
return sorted(__all__ + [names[0] for names in DEPRECATED_NAMES])

0 commit comments

Comments
 (0)