{"action":"created","comment":{"url":"https://api.github.com/repos/numpy/numpy/pulls/comments/171946319","pull_request_review_id":100893005,"id":171946319,"diff_hunk":"@@ -579,10 +604,15 @@ def nansum(a, axis=None, dtype=None, out=None, keepdims=np._NoValue):\n \n     \"\"\"\n     a, mask = _replace_nan(a, 0)\n-    return np.sum(a, axis=axis, dtype=dtype, out=out, keepdims=keepdims)\n+\n+    if initializer is not np._NoValue:\n+        initializer, mask = _replace_nan(initializer, 0)","path":"numpy/lib/nanfunctions.py","position":143,"original_position":143,"commit_id":"21521f6bf031f9bc1f6a054d119c4065100d3dc5","original_commit_id":"21521f6bf031f9bc1f6a054d119c4065100d3dc5","user":{"login":"hameerabbasi","id":2190658,"avatar_url":"https://avatars3.githubusercontent.com/u/2190658?v=4","gravatar_id":"","url":"https://api.github.com/users/hameerabbasi","html_url":"https://github.com/hameerabbasi","followers_url":"https://api.github.com/users/hameerabbasi/followers","following_url":"https://api.github.com/users/hameerabbasi/following{/other_user}","gists_url":"https://api.github.com/users/hameerabbasi/gists{/gist_id}","starred_url":"https://api.github.com/users/hameerabbasi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hameerabbasi/subscriptions","organizations_url":"https://api.github.com/users/hameerabbasi/orgs","repos_url":"https://api.github.com/users/hameerabbasi/repos","events_url":"https://api.github.com/users/hameerabbasi/events{/privacy}","received_events_url":"https://api.github.com/users/hameerabbasi/received_events","type":"User","site_admin":false},"body":"For @mhvk's suggestion, it isn't maintained for `initializer=nan`","created_at":"2018-03-02T19:49:31Z","updated_at":"2018-03-02T19:49:31Z","html_url":"https://github.com/numpy/numpy/pull/10635#discussion_r171946319","pull_request_url":"https://api.github.com/repos/numpy/numpy/pulls/10635","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/numpy/numpy/pulls/comments/171946319"},"html":{"href":"https://github.com/numpy/numpy/pull/10635#discussion_r171946319"},"pull_request":{"href":"https://api.github.com/repos/numpy/numpy/pulls/10635"}},"in_reply_to_id":171910295},"pull_request":{"url":"https://api.github.com/repos/numpy/numpy/pulls/10635","id":170234410,"html_url":"https://github.com/numpy/numpy/pull/10635","diff_url":"https://github.com/numpy/numpy/pull/10635.diff","patch_url":"https://github.com/numpy/numpy/pull/10635.patch","issue_url":"https://api.github.com/repos/numpy/numpy/issues/10635","number":10635,"state":"open","locked":false,"title":"ENH: Implement initializer kwarg for ufunc.add.reduce","user":{"login":"hameerabbasi","id":2190658,"avatar_url":"https://avatars3.githubusercontent.com/u/2190658?v=4","gravatar_id":"","url":"https://api.github.com/users/hameerabbasi","html_url":"https://github.com/hameerabbasi","followers_url":"https://api.github.com/users/hameerabbasi/followers","following_url":"https://api.github.com/users/hameerabbasi/following{/other_user}","gists_url":"https://api.github.com/users/hameerabbasi/gists{/gist_id}","starred_url":"https://api.github.com/users/hameerabbasi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hameerabbasi/subscriptions","organizations_url":"https://api.github.com/users/hameerabbasi/orgs","repos_url":"https://api.github.com/users/hameerabbasi/repos","events_url":"https://api.github.com/users/hameerabbasi/events{/privacy}","received_events_url":"https://api.github.com/users/hameerabbasi/received_events","type":"User","site_admin":false},"body":"As discussed in #5032: Adds an `identity` kwarg for `ufunc.reduce`, plus changes in `min`, `max`, `nanmin`, `nanmax`.\r\n\r\nOne test is failing and I have no idea why, if someone could point me to where, that'd be great.","created_at":"2018-02-20T16:01:37Z","updated_at":"2018-03-02T19:49:31Z","closed_at":null,"merged_at":null,"merge_commit_sha":"fc31b91816250fd2e3a343ae8addb2ba1b97a7cd","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":6359239,"url":"https://api.github.com/repos/numpy/numpy/labels/01%20-%20Enhancement","name":"01 - Enhancement","color":"fef2c0","default":false},{"id":16917029,"url":"https://api.github.com/repos/numpy/numpy/labels/component:%20numpy.core","name":"component: numpy.core","color":"009800","default":false}],"milestone":{"url":"https://api.github.com/repos/numpy/numpy/milestones/52","html_url":"https://github.com/numpy/numpy/milestone/52","labels_url":"https://api.github.com/repos/numpy/numpy/milestones/52/labels","id":2844628,"number":52,"title":"1.15.0 release","description":"","creator":{"login":"charris","id":77272,"avatar_url":"https://avatars3.githubusercontent.com/u/77272?v=4","gravatar_id":"","url":"https://api.github.com/users/charris","html_url":"https://github.com/charris","followers_url":"https://api.github.com/users/charris/followers","following_url":"https://api.github.com/users/charris/following{/other_user}","gists_url":"https://api.github.com/users/charris/gists{/gist_id}","starred_url":"https://api.github.com/users/charris/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/charris/subscriptions","organizations_url":"https://api.github.com/users/charris/orgs","repos_url":"https://api.github.com/users/charris/repos","events_url":"https://api.github.com/users/charris/events{/privacy}","received_events_url":"https://api.github.com/users/charris/received_events","type":"User","site_admin":false},"open_issues":27,"closed_issues":22,"state":"open","created_at":"2017-10-17T21:13:32Z","updated_at":"2018-02-28T08:11:50Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/numpy/numpy/pulls/10635/commits","review_comments_url":"https://api.github.com/repos/numpy/numpy/pulls/10635/comments","review_comment_url":"https://api.github.com/repos/numpy/numpy/pulls/comments{/number}","comments_url":"https://api.github.com/repos/numpy/numpy/issues/10635/comments","statuses_url":"https://api.github.com/repos/numpy/numpy/statuses/21521f6bf031f9bc1f6a054d119c4065100d3dc5","head":{"label":"hameerabbasi:ufunc-reduce-identity","ref":"ufunc-reduce-identity","sha":"21521f6bf031f9bc1f6a054d119c4065100d3dc5","user":{"login":"hameerabbasi","id":2190658,"avatar_url":"https://avatars3.githubusercontent.com/u/2190658?v=4","gravatar_id":"","url":"https://api.github.com/users/hameerabbasi","html_url":"https://github.com/hameerabbasi","followers_url":"https://api.github.com/users/hameerabbasi/followers","following_url":"https://api.github.com/users/hameerabbasi/following{/other_user}","gists_url":"https://api.github.com/users/hameerabbasi/gists{/gist_id}","starred_url":"https://api.github.com/users/hameerabbasi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hameerabbasi/subscriptions","organizations_url":"https://api.github.com/users/hameerabbasi/orgs","repos_url":"https://api.github.com/users/hameerabbasi/repos","events_url":"https://api.github.com/users/hameerabbasi/events{/privacy}","received_events_url":"https://api.github.com/users/hameerabbasi/received_events","type":"User","site_admin":false},"repo":{"id":118579745,"name":"numpy","full_name":"hameerabbasi/numpy","owner":{"login":"hameerabbasi","id":2190658,"avatar_url":"https://avatars3.githubusercontent.com/u/2190658?v=4","gravatar_id":"","url":"https://api.github.com/users/hameerabbasi","html_url":"https://github.com/hameerabbasi","followers_url":"https://api.github.com/users/hameerabbasi/followers","following_url":"https://api.github.com/users/hameerabbasi/following{/other_user}","gists_url":"https://api.github.com/users/hameerabbasi/gists{/gist_id}","starred_url":"https://api.github.com/users/hameerabbasi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hameerabbasi/subscriptions","organizations_url":"https://api.github.com/users/hameerabbasi/orgs","repos_url":"https://api.github.com/users/hameerabbasi/repos","events_url":"https://api.github.com/users/hameerabbasi/events{/privacy}","received_events_url":"https://api.github.com/users/hameerabbasi/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/hameerabbasi/numpy","description":"Numpy main repository","fork":true,"url":"https://api.github.com/repos/hameerabbasi/numpy","forks_url":"https://api.github.com/repos/hameerabbasi/numpy/forks","keys_url":"https://api.github.com/repos/hameerabbasi/numpy/keys{/key_id}","collaborators_url":"https://api.github.com/repos/hameerabbasi/numpy/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/hameerabbasi/numpy/teams","hooks_url":"https://api.github.com/repos/hameerabbasi/numpy/hooks","issue_events_url":"https://api.github.com/repos/hameerabbasi/numpy/issues/events{/number}","events_url":"https://api.github.com/repos/hameerabbasi/numpy/events","assignees_url":"https://api.github.com/repos/hameerabbasi/numpy/assignees{/user}","branches_url":"https://api.github.com/repos/hameerabbasi/numpy/branches{/branch}","tags_url":"https://api.github.com/repos/hameerabbasi/numpy/tags","blobs_url":"https://api.github.com/repos/hameerabbasi/numpy/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/hameerabbasi/numpy/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/hameerabbasi/numpy/git/refs{/sha}","trees_url":"https://api.github.com/repos/hameerabbasi/numpy/git/trees{/sha}","statuses_url":"https://api.github.com/repos/hameerabbasi/numpy/statuses/{sha}","languages_url":"https://api.github.com/repos/hameerabbasi/numpy/languages","stargazers_url":"https://api.github.com/repos/hameerabbasi/numpy/stargazers","contributors_url":"https://api.github.com/repos/hameerabbasi/numpy/contributors","subscribers_url":"https://api.github.com/repos/hameerabbasi/numpy/subscribers","subscription_url":"https://api.github.com/repos/hameerabbasi/numpy/subscription","commits_url":"https://api.github.com/repos/hameerabbasi/numpy/commits{/sha}","git_commits_url":"https://api.github.com/repos/hameerabbasi/numpy/git/commits{/sha}","comments_url":"https://api.github.com/repos/hameerabbasi/numpy/comments{/number}","issue_comment_url":"https://api.github.com/repos/hameerabbasi/numpy/issues/comments{/number}","contents_url":"https://api.github.com/repos/hameerabbasi/numpy/contents/{+path}","compare_url":"https://api.github.com/repos/hameerabbasi/numpy/compare/{base}...{head}","merges_url":"https://api.github.com/repos/hameerabbasi/numpy/merges","archive_url":"https://api.github.com/repos/hameerabbasi/numpy/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/hameerabbasi/numpy/downloads","issues_url":"https://api.github.com/repos/hameerabbasi/numpy/issues{/number}","pulls_url":"https://api.github.com/repos/hameerabbasi/numpy/pulls{/number}","milestones_url":"https://api.github.com/repos/hameerabbasi/numpy/milestones{/number}","notifications_url":"https://api.github.com/repos/hameerabbasi/numpy/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/hameerabbasi/numpy/labels{/name}","releases_url":"https://api.github.com/repos/hameerabbasi/numpy/releases{/id}","deployments_url":"https://api.github.com/repos/hameerabbasi/numpy/deployments","created_at":"2018-01-23T08:18:57Z","updated_at":"2018-01-23T08:19:03Z","pushed_at":"2018-03-02T06:44:05Z","git_url":"git://github.com/hameerabbasi/numpy.git","ssh_url":"git@github.com:hameerabbasi/numpy.git","clone_url":"https://github.com/hameerabbasi/numpy.git","svn_url":"https://github.com/hameerabbasi/numpy","homepage":"http://www.numpy.org/","size":54516,"stargazers_count":0,"watchers_count":0,"language":"C","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":null,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"numpy:master","ref":"master","sha":"042886c4369956db23d4d05a5cbe7baa4fb9f86b","user":{"login":"numpy","id":288276,"avatar_url":"https://avatars2.githubusercontent.com/u/288276?v=4","gravatar_id":"","url":"https://api.github.com/users/numpy","html_url":"https://github.com/numpy","followers_url":"https://api.github.com/users/numpy/followers","following_url":"https://api.github.com/users/numpy/following{/other_user}","gists_url":"https://api.github.com/users/numpy/gists{/gist_id}","starred_url":"https://api.github.com/users/numpy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/numpy/subscriptions","organizations_url":"https://api.github.com/users/numpy/orgs","repos_url":"https://api.github.com/users/numpy/repos","events_url":"https://api.github.com/users/numpy/events{/privacy}","received_events_url":"https://api.github.com/users/numpy/received_events","type":"Organization","site_admin":false},"repo":{"id":908607,"name":"numpy","full_name":"numpy/numpy","owner":{"login":"numpy","id":288276,"avatar_url":"https://avatars2.githubusercontent.com/u/288276?v=4","gravatar_id":"","url":"https://api.github.com/users/numpy","html_url":"https://github.com/numpy","followers_url":"https://api.github.com/users/numpy/followers","following_url":"https://api.github.com/users/numpy/following{/other_user}","gists_url":"https://api.github.com/users/numpy/gists{/gist_id}","starred_url":"https://api.github.com/users/numpy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/numpy/subscriptions","organizations_url":"https://api.github.com/users/numpy/orgs","repos_url":"https://api.github.com/users/numpy/repos","events_url":"https://api.github.com/users/numpy/events{/privacy}","received_events_url":"https://api.github.com/users/numpy/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/numpy/numpy","description":"Numpy main repository","fork":false,"url":"https://api.github.com/repos/numpy/numpy","forks_url":"https://api.github.com/repos/numpy/numpy/forks","keys_url":"https://api.github.com/repos/numpy/numpy/keys{/key_id}","collaborators_url":"https://api.github.com/repos/numpy/numpy/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/numpy/numpy/teams","hooks_url":"https://api.github.com/repos/numpy/numpy/hooks","issue_events_url":"https://api.github.com/repos/numpy/numpy/issues/events{/number}","events_url":"https://api.github.com/repos/numpy/numpy/events","assignees_url":"https://api.github.com/repos/numpy/numpy/assignees{/user}","branches_url":"https://api.github.com/repos/numpy/numpy/branches{/branch}","tags_url":"https://api.github.com/repos/numpy/numpy/tags","blobs_url":"https://api.github.com/repos/numpy/numpy/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/numpy/numpy/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/numpy/numpy/git/refs{/sha}","trees_url":"https://api.github.com/repos/numpy/numpy/git/trees{/sha}","statuses_url":"https://api.github.com/repos/numpy/numpy/statuses/{sha}","languages_url":"https://api.github.com/repos/numpy/numpy/languages","stargazers_url":"https://api.github.com/repos/numpy/numpy/stargazers","contributors_url":"https://api.github.com/repos/numpy/numpy/contributors","subscribers_url":"https://api.github.com/repos/numpy/numpy/subscribers","subscription_url":"https://api.github.com/repos/numpy/numpy/subscription","commits_url":"https://api.github.com/repos/numpy/numpy/commits{/sha}","git_commits_url":"https://api.github.com/repos/numpy/numpy/git/commits{/sha}","comments_url":"https://api.github.com/repos/numpy/numpy/comments{/number}","issue_comment_url":"https://api.github.com/repos/numpy/numpy/issues/comments{/number}","contents_url":"https://api.github.com/repos/numpy/numpy/contents/{+path}","compare_url":"https://api.github.com/repos/numpy/numpy/compare/{base}...{head}","merges_url":"https://api.github.com/repos/numpy/numpy/merges","archive_url":"https://api.github.com/repos/numpy/numpy/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/numpy/numpy/downloads","issues_url":"https://api.github.com/repos/numpy/numpy/issues{/number}","pulls_url":"https://api.github.com/repos/numpy/numpy/pulls{/number}","milestones_url":"https://api.github.com/repos/numpy/numpy/milestones{/number}","notifications_url":"https://api.github.com/repos/numpy/numpy/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/numpy/numpy/labels{/name}","releases_url":"https://api.github.com/repos/numpy/numpy/releases{/id}","deployments_url":"https://api.github.com/repos/numpy/numpy/deployments","created_at":"2010-09-13T23:02:39Z","updated_at":"2018-03-02T15:43:29Z","pushed_at":"2018-03-02T15:13:17Z","git_url":"git://github.com/numpy/numpy.git","ssh_url":"git@github.com:numpy/numpy.git","clone_url":"https://github.com/numpy/numpy.git","svn_url":"https://github.com/numpy/numpy","homepage":"http://www.numpy.org/","size":55746,"stargazers_count":6573,"watchers_count":6573,"language":"C","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2615,"mirror_url":null,"archived":false,"open_issues_count":1826,"license":{"key":"other","name":"Other","spdx_id":null,"url":null},"forks":2615,"open_issues":1826,"watchers":6573,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/numpy/numpy/pulls/10635"},"html":{"href":"https://github.com/numpy/numpy/pull/10635"},"issue":{"href":"https://api.github.com/repos/numpy/numpy/issues/10635"},"comments":{"href":"https://api.github.com/repos/numpy/numpy/issues/10635/comments"},"review_comments":{"href":"https://api.github.com/repos/numpy/numpy/pulls/10635/comments"},"review_comment":{"href":"https://api.github.com/repos/numpy/numpy/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/numpy/numpy/pulls/10635/commits"},"statuses":{"href":"https://api.github.com/repos/numpy/numpy/statuses/21521f6bf031f9bc1f6a054d119c4065100d3dc5"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"hameerabbasi"}}