Skip to content

CLN: Added static types _libs/algos #33271

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

Merged
merged 4 commits into from
Apr 5, 2020

Conversation

ShaharNaveh
Copy link
Member

  • closes #xxxx
  • tests added / passed
  • passes black pandas
  • passes git diff upstream/master -u -- "*.py" | flake8 --diff
  • whatsnew entry

@@ -261,7 +260,7 @@ def kth_smallest(numeric[:] a, Py_ssize_t k) -> numeric:

@cython.boundscheck(False)
@cython.wraparound(False)
def nancorr(const float64_t[:, :] mat, bint cov=0, minp=None):
def nancorr(const float64_t[:, :] mat, bint cov=False, minp=None):
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The generated C code for this was not changed

float64_t sum_ranks = 0
int tiebreak = 0
bint keep_na = 0
bint keep_na = False
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The generated C code for this was not changed

float64_t sum_ranks = 0
int tiebreak = 0
bint keep_na = 0
bint keep_na = False
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The generated C code for this was not changed

@@ -325,7 +324,7 @@ def nancorr(const float64_t[:, :] mat, bint cov=0, minp=None):

@cython.boundscheck(False)
@cython.wraparound(False)
def nancorr_spearman(const float64_t[:, :] mat, Py_ssize_t minp=1):
def nancorr_spearman(const float64_t[:, :] mat, Py_ssize_t minp=1) -> ndarray:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does adding these return annotations to the def like this change anything?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

for functions that arent cdef/cpdef its ornamental

@WillAyd WillAyd added the Clean label Apr 3, 2020
Copy link
Member

@WillAyd WillAyd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lgtm

@WillAyd WillAyd added this to the 1.1 milestone Apr 4, 2020
@jreback jreback merged commit 213822a into pandas-dev:master Apr 5, 2020
@jreback
Copy link
Contributor

jreback commented Apr 5, 2020

thanks @MomIsBestFriend

@ShaharNaveh ShaharNaveh deleted the CLN-StaticTypes-_libs-algos branch April 6, 2020 08:28
jbrockmendel pushed a commit to jbrockmendel/pandas that referenced this pull request Apr 6, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants