-
Notifications
You must be signed in to change notification settings - Fork 135
Rename sgn
to sign
#228
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
Rename sgn
to sign
#228
Conversation
@sudarsan2k5 Thanks! Note the conflicts, you need to rebase from main. |
45549f6
to
41ce74d
Compare
by mistakenly converted to draft |
41ce74d
to
5287ab0
Compare
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## main #228 +/- ##
=======================================
Coverage 80.43% 80.43%
=======================================
Files 170 170
Lines 45326 45326
Branches 9687 9687
=======================================
Hits 36457 36457
Misses 6643 6643
Partials 2226 2226
|
@@ -1092,7 +1092,7 @@ def log1p(a): | |||
|
|||
|
|||
@scalar_elemwise | |||
def sgn(a): | |||
def sign(a): | |||
"""sign of a""" | |||
|
|||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you mind adding a compatible sgn
like this (and make it accessible from pytensor.tensor
as before.
def sgn(a): | |
warnings.warn( | |
"sgn is deprecated and will stop working in the future, use sign instead.", | |
FutureWarning, | |
) | |
return sign(a) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @ricardoV94 I have implemented the suggested changes, could you please check if we need anything else in this PR?
@sudarsan2k5 Sorry I just wanted to check locally the old import is still working. I'll do it tomorrow and merge after |
Thanks @sudarsan2k5, merged! |
fixes #162
Checklist