-
Notifications
You must be signed in to change notification settings - Fork 109
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
Implement equivalent numpy median and quantile / percentile #53
Comments
Here do we want to use the |
Good question, depends on how complicated the median code would look like if written in pure PyTensor. If it's messy we can just use np.median under the hood |
I think using numpy under the hood is better. They even handle nans and have also allow inplace median by overwriting the input whenever required. |
For |
If using numpy code, it must always be inside an Op. Normal numpy code won't work with PyTensor symbolic variables (which are just placeholders and don't contain values yet) |
Ohk. So I'll try to write the median in pytensor itself since we want to avoid creating new |
Not anytime, but as much as possible! |
Please describe the purpose of filing this issue
Equivalent symbolic methods to those are missing.
The Numpy
quantile
andpercentile
methods have too many options for theinterpolation
argument, and these are planned to be deprecated for a while now (see numpy/numpy#10736). It should suffice to implement the default"linear"
interpolation.I am confident that these should not require any extra
Ops
.The text was updated successfully, but these errors were encountered: