{"action":"created","comment":{"url":"https://api.github.com/repos/pandas-dev/pandas/pulls/comments/181687917","pull_request_review_id":112357591,"id":181687917,"diff_hunk":"@@ -6,6 +6,7 @@\n from datetime import datetime, timedelta\n from numpy.random import randn\n import numpy as np\n+from scipy._lib._version import NumpyVersion","path":"pandas/tests/test_window.py","position":4,"original_position":4,"commit_id":"d6b68cbc71c0e8b9880748b7a2bcffdc7bbf1a11","original_commit_id":"d6b68cbc71c0e8b9880748b7a2bcffdc7bbf1a11","user":{"login":"jreback","id":953992,"avatar_url":"https://avatars2.githubusercontent.com/u/953992?v=4","gravatar_id":"","url":"https://api.github.com/users/jreback","html_url":"https://github.com/jreback","followers_url":"https://api.github.com/users/jreback/followers","following_url":"https://api.github.com/users/jreback/following{/other_user}","gists_url":"https://api.github.com/users/jreback/gists{/gist_id}","starred_url":"https://api.github.com/users/jreback/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jreback/subscriptions","organizations_url":"https://api.github.com/users/jreback/orgs","repos_url":"https://api.github.com/users/jreback/repos","events_url":"https://api.github.com/users/jreback/events{/privacy}","received_events_url":"https://api.github.com/users/jreback/received_events","type":"User","site_admin":false},"body":"use ``from pandas import _np_version_under1p12``\r\n","created_at":"2018-04-16T10:25:13Z","updated_at":"2018-04-16T10:25:19Z","html_url":"https://github.com/pandas-dev/pandas/pull/20497#discussion_r181687917","pull_request_url":"https://api.github.com/repos/pandas-dev/pandas/pulls/20497","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/pandas-dev/pandas/pulls/comments/181687917"},"html":{"href":"https://github.com/pandas-dev/pandas/pull/20497#discussion_r181687917"},"pull_request":{"href":"https://api.github.com/repos/pandas-dev/pandas/pulls/20497"}}},"pull_request":{"url":"https://api.github.com/repos/pandas-dev/pandas/pulls/20497","id":177682243,"html_url":"https://github.com/pandas-dev/pandas/pull/20497","diff_url":"https://github.com/pandas-dev/pandas/pull/20497.diff","patch_url":"https://github.com/pandas-dev/pandas/pull/20497.patch","issue_url":"https://api.github.com/repos/pandas-dev/pandas/issues/20497","number":20497,"state":"open","locked":false,"title":"Add interpolation options to rolling quantile","user":{"login":"kornilova-l","id":23450724,"avatar_url":"https://avatars2.githubusercontent.com/u/23450724?v=4","gravatar_id":"","url":"https://api.github.com/users/kornilova-l","html_url":"https://github.com/kornilova-l","followers_url":"https://api.github.com/users/kornilova-l/followers","following_url":"https://api.github.com/users/kornilova-l/following{/other_user}","gists_url":"https://api.github.com/users/kornilova-l/gists{/gist_id}","starred_url":"https://api.github.com/users/kornilova-l/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kornilova-l/subscriptions","organizations_url":"https://api.github.com/users/kornilova-l/orgs","repos_url":"https://api.github.com/users/kornilova-l/repos","events_url":"https://api.github.com/users/kornilova-l/events{/privacy}","received_events_url":"https://api.github.com/users/kornilova-l/received_events","type":"User","site_admin":false},"body":"It version 0.21.0 rolling quantile started to use linear interpolation, it broke backward compatibility.\r\n\r\nRegular (not rolling) quantile supports these interpolation options: `linear`, `lower`, `higher`, `nearest` and `midpoint`.\r\nThis commit adds the same options to moving quantile.\r\n\r\nPerformance issues of this commit (note: I re-run benchmarks, see message below) \r\nThis code has 15% worse performance on benchmarks with small values of window (`window=10`). This is because loop inside `roll_quantile` now contains switch.\r\nI tried to replace switch with callback but it led to even worse performance. Even if I move some of the code to new function (without any change in logic) it still makes performance much worse.\r\nHow bad is it? Could you please give me an advice on how to arrange the code such that it has the same performance?\r\n\r\n- [ ] closes #xxxx\r\n- [ ] tests added / passed\r\n- [ ] passes `git diff upstream/master -u -- \"*.py\" | flake8 --diff`\r\n- [ ] whatsnew entry\r\n","created_at":"2018-03-27T09:34:52Z","updated_at":"2018-04-16T10:25:19Z","closed_at":null,"merged_at":null,"merge_commit_sha":"96ab492c5edf23bf66c5e85a02f95421411d9df2","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":76812,"url":"https://api.github.com/repos/pandas-dev/pandas/labels/Enhancement","name":"Enhancement","color":"4E9A06","default":false},{"id":13098779,"url":"https://api.github.com/repos/pandas-dev/pandas/labels/Reshaping","name":"Reshaping","color":"02d7e1","default":false}],"milestone":null,"commits_url":"https://api.github.com/repos/pandas-dev/pandas/pulls/20497/commits","review_comments_url":"https://api.github.com/repos/pandas-dev/pandas/pulls/20497/comments","review_comment_url":"https://api.github.com/repos/pandas-dev/pandas/pulls/comments{/number}","comments_url":"https://api.github.com/repos/pandas-dev/pandas/issues/20497/comments","statuses_url":"https://api.github.com/repos/pandas-dev/pandas/statuses/d6b68cbc71c0e8b9880748b7a2bcffdc7bbf1a11","head":{"label":"kornilova-l:add-interpolation-options-to-rolling-quantile","ref":"add-interpolation-options-to-rolling-quantile","sha":"d6b68cbc71c0e8b9880748b7a2bcffdc7bbf1a11","user":{"login":"kornilova-l","id":23450724,"avatar_url":"https://avatars2.githubusercontent.com/u/23450724?v=4","gravatar_id":"","url":"https://api.github.com/users/kornilova-l","html_url":"https://github.com/kornilova-l","followers_url":"https://api.github.com/users/kornilova-l/followers","following_url":"https://api.github.com/users/kornilova-l/following{/other_user}","gists_url":"https://api.github.com/users/kornilova-l/gists{/gist_id}","starred_url":"https://api.github.com/users/kornilova-l/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kornilova-l/subscriptions","organizations_url":"https://api.github.com/users/kornilova-l/orgs","repos_url":"https://api.github.com/users/kornilova-l/repos","events_url":"https://api.github.com/users/kornilova-l/events{/privacy}","received_events_url":"https://api.github.com/users/kornilova-l/received_events","type":"User","site_admin":false},"repo":{"id":126317950,"name":"pandas","full_name":"kornilova-l/pandas","owner":{"login":"kornilova-l","id":23450724,"avatar_url":"https://avatars2.githubusercontent.com/u/23450724?v=4","gravatar_id":"","url":"https://api.github.com/users/kornilova-l","html_url":"https://github.com/kornilova-l","followers_url":"https://api.github.com/users/kornilova-l/followers","following_url":"https://api.github.com/users/kornilova-l/following{/other_user}","gists_url":"https://api.github.com/users/kornilova-l/gists{/gist_id}","starred_url":"https://api.github.com/users/kornilova-l/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kornilova-l/subscriptions","organizations_url":"https://api.github.com/users/kornilova-l/orgs","repos_url":"https://api.github.com/users/kornilova-l/repos","events_url":"https://api.github.com/users/kornilova-l/events{/privacy}","received_events_url":"https://api.github.com/users/kornilova-l/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/kornilova-l/pandas","description":"Flexible and powerful data analysis / manipulation library for Python, providing labeled data structures similar to R data.frame objects, statistical functions, and much more","fork":true,"url":"https://api.github.com/repos/kornilova-l/pandas","forks_url":"https://api.github.com/repos/kornilova-l/pandas/forks","keys_url":"https://api.github.com/repos/kornilova-l/pandas/keys{/key_id}","collaborators_url":"https://api.github.com/repos/kornilova-l/pandas/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/kornilova-l/pandas/teams","hooks_url":"https://api.github.com/repos/kornilova-l/pandas/hooks","issue_events_url":"https://api.github.com/repos/kornilova-l/pandas/issues/events{/number}","events_url":"https://api.github.com/repos/kornilova-l/pandas/events","assignees_url":"https://api.github.com/repos/kornilova-l/pandas/assignees{/user}","branches_url":"https://api.github.com/repos/kornilova-l/pandas/branches{/branch}","tags_url":"https://api.github.com/repos/kornilova-l/pandas/tags","blobs_url":"https://api.github.com/repos/kornilova-l/pandas/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/kornilova-l/pandas/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/kornilova-l/pandas/git/refs{/sha}","trees_url":"https://api.github.com/repos/kornilova-l/pandas/git/trees{/sha}","statuses_url":"https://api.github.com/repos/kornilova-l/pandas/statuses/{sha}","languages_url":"https://api.github.com/repos/kornilova-l/pandas/languages","stargazers_url":"https://api.github.com/repos/kornilova-l/pandas/stargazers","contributors_url":"https://api.github.com/repos/kornilova-l/pandas/contributors","subscribers_url":"https://api.github.com/repos/kornilova-l/pandas/subscribers","subscription_url":"https://api.github.com/repos/kornilova-l/pandas/subscription","commits_url":"https://api.github.com/repos/kornilova-l/pandas/commits{/sha}","git_commits_url":"https://api.github.com/repos/kornilova-l/pandas/git/commits{/sha}","comments_url":"https://api.github.com/repos/kornilova-l/pandas/comments{/number}","issue_comment_url":"https://api.github.com/repos/kornilova-l/pandas/issues/comments{/number}","contents_url":"https://api.github.com/repos/kornilova-l/pandas/contents/{+path}","compare_url":"https://api.github.com/repos/kornilova-l/pandas/compare/{base}...{head}","merges_url":"https://api.github.com/repos/kornilova-l/pandas/merges","archive_url":"https://api.github.com/repos/kornilova-l/pandas/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/kornilova-l/pandas/downloads","issues_url":"https://api.github.com/repos/kornilova-l/pandas/issues{/number}","pulls_url":"https://api.github.com/repos/kornilova-l/pandas/pulls{/number}","milestones_url":"https://api.github.com/repos/kornilova-l/pandas/milestones{/number}","notifications_url":"https://api.github.com/repos/kornilova-l/pandas/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/kornilova-l/pandas/labels{/name}","releases_url":"https://api.github.com/repos/kornilova-l/pandas/releases{/id}","deployments_url":"https://api.github.com/repos/kornilova-l/pandas/deployments","created_at":"2018-03-22T10:23:47Z","updated_at":"2018-03-22T10:23:55Z","pushed_at":"2018-04-16T10:17:59Z","git_url":"git://github.com/kornilova-l/pandas.git","ssh_url":"git@github.com:kornilova-l/pandas.git","clone_url":"https://github.com/kornilova-l/pandas.git","svn_url":"https://github.com/kornilova-l/pandas","homepage":"http://pandas.pydata.org","size":121414,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"bsd-3-clause","name":"BSD 3-Clause \"New\" or \"Revised\" License","spdx_id":"BSD-3-Clause","url":"https://api.github.com/licenses/bsd-3-clause"},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"pandas-dev:master","ref":"master","sha":"6a22cf786e9e09ceb8ca44b712dce4af5bbcfd65","user":{"login":"pandas-dev","id":21206976,"avatar_url":"https://avatars2.githubusercontent.com/u/21206976?v=4","gravatar_id":"","url":"https://api.github.com/users/pandas-dev","html_url":"https://github.com/pandas-dev","followers_url":"https://api.github.com/users/pandas-dev/followers","following_url":"https://api.github.com/users/pandas-dev/following{/other_user}","gists_url":"https://api.github.com/users/pandas-dev/gists{/gist_id}","starred_url":"https://api.github.com/users/pandas-dev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pandas-dev/subscriptions","organizations_url":"https://api.github.com/users/pandas-dev/orgs","repos_url":"https://api.github.com/users/pandas-dev/repos","events_url":"https://api.github.com/users/pandas-dev/events{/privacy}","received_events_url":"https://api.github.com/users/pandas-dev/received_events","type":"Organization","site_admin":false},"repo":{"id":858127,"name":"pandas","full_name":"pandas-dev/pandas","owner":{"login":"pandas-dev","id":21206976,"avatar_url":"https://avatars2.githubusercontent.com/u/21206976?v=4","gravatar_id":"","url":"https://api.github.com/users/pandas-dev","html_url":"https://github.com/pandas-dev","followers_url":"https://api.github.com/users/pandas-dev/followers","following_url":"https://api.github.com/users/pandas-dev/following{/other_user}","gists_url":"https://api.github.com/users/pandas-dev/gists{/gist_id}","starred_url":"https://api.github.com/users/pandas-dev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pandas-dev/subscriptions","organizations_url":"https://api.github.com/users/pandas-dev/orgs","repos_url":"https://api.github.com/users/pandas-dev/repos","events_url":"https://api.github.com/users/pandas-dev/events{/privacy}","received_events_url":"https://api.github.com/users/pandas-dev/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/pandas-dev/pandas","description":"Flexible and powerful data analysis / manipulation library for Python, providing labeled data structures similar to R data.frame objects, statistical functions, and much more","fork":false,"url":"https://api.github.com/repos/pandas-dev/pandas","forks_url":"https://api.github.com/repos/pandas-dev/pandas/forks","keys_url":"https://api.github.com/repos/pandas-dev/pandas/keys{/key_id}","collaborators_url":"https://api.github.com/repos/pandas-dev/pandas/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/pandas-dev/pandas/teams","hooks_url":"https://api.github.com/repos/pandas-dev/pandas/hooks","issue_events_url":"https://api.github.com/repos/pandas-dev/pandas/issues/events{/number}","events_url":"https://api.github.com/repos/pandas-dev/pandas/events","assignees_url":"https://api.github.com/repos/pandas-dev/pandas/assignees{/user}","branches_url":"https://api.github.com/repos/pandas-dev/pandas/branches{/branch}","tags_url":"https://api.github.com/repos/pandas-dev/pandas/tags","blobs_url":"https://api.github.com/repos/pandas-dev/pandas/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/pandas-dev/pandas/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/pandas-dev/pandas/git/refs{/sha}","trees_url":"https://api.github.com/repos/pandas-dev/pandas/git/trees{/sha}","statuses_url":"https://api.github.com/repos/pandas-dev/pandas/statuses/{sha}","languages_url":"https://api.github.com/repos/pandas-dev/pandas/languages","stargazers_url":"https://api.github.com/repos/pandas-dev/pandas/stargazers","contributors_url":"https://api.github.com/repos/pandas-dev/pandas/contributors","subscribers_url":"https://api.github.com/repos/pandas-dev/pandas/subscribers","subscription_url":"https://api.github.com/repos/pandas-dev/pandas/subscription","commits_url":"https://api.github.com/repos/pandas-dev/pandas/commits{/sha}","git_commits_url":"https://api.github.com/repos/pandas-dev/pandas/git/commits{/sha}","comments_url":"https://api.github.com/repos/pandas-dev/pandas/comments{/number}","issue_comment_url":"https://api.github.com/repos/pandas-dev/pandas/issues/comments{/number}","contents_url":"https://api.github.com/repos/pandas-dev/pandas/contents/{+path}","compare_url":"https://api.github.com/repos/pandas-dev/pandas/compare/{base}...{head}","merges_url":"https://api.github.com/repos/pandas-dev/pandas/merges","archive_url":"https://api.github.com/repos/pandas-dev/pandas/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/pandas-dev/pandas/downloads","issues_url":"https://api.github.com/repos/pandas-dev/pandas/issues{/number}","pulls_url":"https://api.github.com/repos/pandas-dev/pandas/pulls{/number}","milestones_url":"https://api.github.com/repos/pandas-dev/pandas/milestones{/number}","notifications_url":"https://api.github.com/repos/pandas-dev/pandas/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/pandas-dev/pandas/labels{/name}","releases_url":"https://api.github.com/repos/pandas-dev/pandas/releases{/id}","deployments_url":"https://api.github.com/repos/pandas-dev/pandas/deployments","created_at":"2010-08-24T01:37:33Z","updated_at":"2018-04-16T09:14:36Z","pushed_at":"2018-04-16T10:18:02Z","git_url":"git://github.com/pandas-dev/pandas.git","ssh_url":"git@github.com:pandas-dev/pandas.git","clone_url":"https://github.com/pandas-dev/pandas.git","svn_url":"https://github.com/pandas-dev/pandas","homepage":"http://pandas.pydata.org","size":121778,"stargazers_count":13843,"watchers_count":13843,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":5621,"mirror_url":null,"archived":false,"open_issues_count":2539,"license":{"key":"bsd-3-clause","name":"BSD 3-Clause \"New\" or \"Revised\" License","spdx_id":"BSD-3-Clause","url":"https://api.github.com/licenses/bsd-3-clause"},"forks":5621,"open_issues":2539,"watchers":13843,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/pandas-dev/pandas/pulls/20497"},"html":{"href":"https://github.com/pandas-dev/pandas/pull/20497"},"issue":{"href":"https://api.github.com/repos/pandas-dev/pandas/issues/20497"},"comments":{"href":"https://api.github.com/repos/pandas-dev/pandas/issues/20497/comments"},"review_comments":{"href":"https://api.github.com/repos/pandas-dev/pandas/pulls/20497/comments"},"review_comment":{"href":"https://api.github.com/repos/pandas-dev/pandas/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/pandas-dev/pandas/pulls/20497/commits"},"statuses":{"href":"https://api.github.com/repos/pandas-dev/pandas/statuses/d6b68cbc71c0e8b9880748b7a2bcffdc7bbf1a11"}},"author_association":"NONE"}}
{"actor":{"display_login":"jreback"}}