{"action":"created","comment":{"url":"https://api.github.com/repos/tensorflow/tfjs-core/pulls/comments/218636488","pull_request_review_id":156619448,"id":218636488,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIxODYzNjQ4OA==","diff_hunk":"@@ -44,7 +44,7 @@ export class ArgMinMaxProgram implements GPGPUProgram {\n         int outIdx = coords[1];\n         int inOffset = outIdx * ${windowSize};\n \n-        int bestIndex = 0;\n+        int bestIndex = inOffset;","path":"src/kernels/webgl/argminmax_gpu.ts","position":5,"original_position":5,"commit_id":"4b524378a9738e7852c53d18ad398a7995fb4c7f","original_commit_id":"f6bc8f90e78f0eaa759da0517b5cdc96fd074f34","user":{"login":"pvaneck","id":1868861,"node_id":"MDQ6VXNlcjE4Njg4NjE=","avatar_url":"https://avatars2.githubusercontent.com/u/1868861?v=4","gravatar_id":"","url":"https://api.github.com/users/pvaneck","html_url":"https://github.com/pvaneck","followers_url":"https://api.github.com/users/pvaneck/followers","following_url":"https://api.github.com/users/pvaneck/following{/other_user}","gists_url":"https://api.github.com/users/pvaneck/gists{/gist_id}","starred_url":"https://api.github.com/users/pvaneck/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pvaneck/subscriptions","organizations_url":"https://api.github.com/users/pvaneck/orgs","repos_url":"https://api.github.com/users/pvaneck/repos","events_url":"https://api.github.com/users/pvaneck/events{/privacy}","received_events_url":"https://api.github.com/users/pvaneck/received_events","type":"User","site_admin":false},"body":"Hey, thanks for the suggestion. I went ahead an added a test case for both argMin and argMax which this change affects.","created_at":"2018-09-19T00:31:42Z","updated_at":"2018-09-19T00:31:42Z","html_url":"https://github.com/tensorflow/tfjs-core/pull/1271#discussion_r218636488","pull_request_url":"https://api.github.com/repos/tensorflow/tfjs-core/pulls/1271","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/tensorflow/tfjs-core/pulls/comments/218636488"},"html":{"href":"https://github.com/tensorflow/tfjs-core/pull/1271#discussion_r218636488"},"pull_request":{"href":"https://api.github.com/repos/tensorflow/tfjs-core/pulls/1271"}},"in_reply_to_id":217333441},"pull_request":{"url":"https://api.github.com/repos/tensorflow/tfjs-core/pulls/1271","id":213508073,"node_id":"MDExOlB1bGxSZXF1ZXN0MjEzNTA4MDcz","html_url":"https://github.com/tensorflow/tfjs-core/pull/1271","diff_url":"https://github.com/tensorflow/tfjs-core/pull/1271.diff","patch_url":"https://github.com/tensorflow/tfjs-core/pull/1271.patch","issue_url":"https://api.github.com/repos/tensorflow/tfjs-core/issues/1271","number":1271,"state":"open","locked":false,"title":"Fix ArgMinMaxProgram bestIndex initialization","user":{"login":"pvaneck","id":1868861,"node_id":"MDQ6VXNlcjE4Njg4NjE=","avatar_url":"https://avatars2.githubusercontent.com/u/1868861?v=4","gravatar_id":"","url":"https://api.github.com/users/pvaneck","html_url":"https://github.com/pvaneck","followers_url":"https://api.github.com/users/pvaneck/followers","following_url":"https://api.github.com/users/pvaneck/following{/other_user}","gists_url":"https://api.github.com/users/pvaneck/gists{/gist_id}","starred_url":"https://api.github.com/users/pvaneck/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pvaneck/subscriptions","organizations_url":"https://api.github.com/users/pvaneck/orgs","repos_url":"https://api.github.com/users/pvaneck/repos","events_url":"https://api.github.com/users/pvaneck/events{/privacy}","received_events_url":"https://api.github.com/users/pvaneck/received_events","type":"User","site_admin":false},"body":"\r\n\r\n#### Description\r\nCurrently, bestIndex is initialized to zero, but should be set to inOffset to match how bestValue is initialized.\r\n\r\nThis fixes issues when an array is split into multiple windows, and the first value of a non-first window happens to be the largest value.\r\n\r\nFixes https://github.com/tensorflow/tfjs/issues/665\r\n\r\n---\r\n<!-- Please do not delete this section -->\r\n##### For repository owners only:\r\n\r\nPlease remember to apply all applicable tags to your pull request.\r\nTags: FEATURE, BREAKING, BUG, PERF, DEV, DOC, SECURITY\r\n\r\nFor more info see: https://github.com/tensorflow/tfjs/blob/master/DEVELOPMENT.md\n\n<!-- Reviewable:start -->\n---\nThis change is [<img src=\"https://reviewable.io/review_button.svg\" height=\"34\" align=\"absmiddle\" alt=\"Reviewable\"/>](https://reviewable.io/reviews/tensorflow/tfjs-core/1271)\n<!-- Reviewable:end -->\n","created_at":"2018-09-06T06:29:15Z","updated_at":"2018-09-19T00:31:42Z","closed_at":null,"merged_at":null,"merge_commit_sha":"eaeeb2a939a89e3ae1ec4e93c11c2226721296ef","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/tensorflow/tfjs-core/pulls/1271/commits","review_comments_url":"https://api.github.com/repos/tensorflow/tfjs-core/pulls/1271/comments","review_comment_url":"https://api.github.com/repos/tensorflow/tfjs-core/pulls/comments{/number}","comments_url":"https://api.github.com/repos/tensorflow/tfjs-core/issues/1271/comments","statuses_url":"https://api.github.com/repos/tensorflow/tfjs-core/statuses/4b524378a9738e7852c53d18ad398a7995fb4c7f","head":{"label":"pvaneck:argminmax-fix","ref":"argminmax-fix","sha":"4b524378a9738e7852c53d18ad398a7995fb4c7f","user":{"login":"pvaneck","id":1868861,"node_id":"MDQ6VXNlcjE4Njg4NjE=","avatar_url":"https://avatars2.githubusercontent.com/u/1868861?v=4","gravatar_id":"","url":"https://api.github.com/users/pvaneck","html_url":"https://github.com/pvaneck","followers_url":"https://api.github.com/users/pvaneck/followers","following_url":"https://api.github.com/users/pvaneck/following{/other_user}","gists_url":"https://api.github.com/users/pvaneck/gists{/gist_id}","starred_url":"https://api.github.com/users/pvaneck/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pvaneck/subscriptions","organizations_url":"https://api.github.com/users/pvaneck/orgs","repos_url":"https://api.github.com/users/pvaneck/repos","events_url":"https://api.github.com/users/pvaneck/events{/privacy}","received_events_url":"https://api.github.com/users/pvaneck/received_events","type":"User","site_admin":false},"repo":{"id":147623779,"node_id":"MDEwOlJlcG9zaXRvcnkxNDc2MjM3Nzk=","name":"tfjs-core","full_name":"pvaneck/tfjs-core","private":false,"owner":{"login":"pvaneck","id":1868861,"node_id":"MDQ6VXNlcjE4Njg4NjE=","avatar_url":"https://avatars2.githubusercontent.com/u/1868861?v=4","gravatar_id":"","url":"https://api.github.com/users/pvaneck","html_url":"https://github.com/pvaneck","followers_url":"https://api.github.com/users/pvaneck/followers","following_url":"https://api.github.com/users/pvaneck/following{/other_user}","gists_url":"https://api.github.com/users/pvaneck/gists{/gist_id}","starred_url":"https://api.github.com/users/pvaneck/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pvaneck/subscriptions","organizations_url":"https://api.github.com/users/pvaneck/orgs","repos_url":"https://api.github.com/users/pvaneck/repos","events_url":"https://api.github.com/users/pvaneck/events{/privacy}","received_events_url":"https://api.github.com/users/pvaneck/received_events","type":"User","site_admin":false},"html_url":"https://github.com/pvaneck/tfjs-core","description":"WebGL-accelerated ML // linear algebra // automatic differentiation for JavaScript.","fork":true,"url":"https://api.github.com/repos/pvaneck/tfjs-core","forks_url":"https://api.github.com/repos/pvaneck/tfjs-core/forks","keys_url":"https://api.github.com/repos/pvaneck/tfjs-core/keys{/key_id}","collaborators_url":"https://api.github.com/repos/pvaneck/tfjs-core/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/pvaneck/tfjs-core/teams","hooks_url":"https://api.github.com/repos/pvaneck/tfjs-core/hooks","issue_events_url":"https://api.github.com/repos/pvaneck/tfjs-core/issues/events{/number}","events_url":"https://api.github.com/repos/pvaneck/tfjs-core/events","assignees_url":"https://api.github.com/repos/pvaneck/tfjs-core/assignees{/user}","branches_url":"https://api.github.com/repos/pvaneck/tfjs-core/branches{/branch}","tags_url":"https://api.github.com/repos/pvaneck/tfjs-core/tags","blobs_url":"https://api.github.com/repos/pvaneck/tfjs-core/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/pvaneck/tfjs-core/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/pvaneck/tfjs-core/git/refs{/sha}","trees_url":"https://api.github.com/repos/pvaneck/tfjs-core/git/trees{/sha}","statuses_url":"https://api.github.com/repos/pvaneck/tfjs-core/statuses/{sha}","languages_url":"https://api.github.com/repos/pvaneck/tfjs-core/languages","stargazers_url":"https://api.github.com/repos/pvaneck/tfjs-core/stargazers","contributors_url":"https://api.github.com/repos/pvaneck/tfjs-core/contributors","subscribers_url":"https://api.github.com/repos/pvaneck/tfjs-core/subscribers","subscription_url":"https://api.github.com/repos/pvaneck/tfjs-core/subscription","commits_url":"https://api.github.com/repos/pvaneck/tfjs-core/commits{/sha}","git_commits_url":"https://api.github.com/repos/pvaneck/tfjs-core/git/commits{/sha}","comments_url":"https://api.github.com/repos/pvaneck/tfjs-core/comments{/number}","issue_comment_url":"https://api.github.com/repos/pvaneck/tfjs-core/issues/comments{/number}","contents_url":"https://api.github.com/repos/pvaneck/tfjs-core/contents/{+path}","compare_url":"https://api.github.com/repos/pvaneck/tfjs-core/compare/{base}...{head}","merges_url":"https://api.github.com/repos/pvaneck/tfjs-core/merges","archive_url":"https://api.github.com/repos/pvaneck/tfjs-core/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/pvaneck/tfjs-core/downloads","issues_url":"https://api.github.com/repos/pvaneck/tfjs-core/issues{/number}","pulls_url":"https://api.github.com/repos/pvaneck/tfjs-core/pulls{/number}","milestones_url":"https://api.github.com/repos/pvaneck/tfjs-core/milestones{/number}","notifications_url":"https://api.github.com/repos/pvaneck/tfjs-core/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/pvaneck/tfjs-core/labels{/name}","releases_url":"https://api.github.com/repos/pvaneck/tfjs-core/releases{/id}","deployments_url":"https://api.github.com/repos/pvaneck/tfjs-core/deployments","created_at":"2018-09-06T05:46:14Z","updated_at":"2018-09-06T05:46:17Z","pushed_at":"2018-09-19T00:21:09Z","git_url":"git://github.com/pvaneck/tfjs-core.git","ssh_url":"git@github.com:pvaneck/tfjs-core.git","clone_url":"https://github.com/pvaneck/tfjs-core.git","svn_url":"https://github.com/pvaneck/tfjs-core","homepage":"https://js.tensorflow.org","size":62014,"stargazers_count":0,"watchers_count":0,"language":"TypeScript","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"tensorflow:master","ref":"master","sha":"8cfa867c4c54600b3d42104a666b7d445f1172b4","user":{"login":"tensorflow","id":15658638,"node_id":"MDEyOk9yZ2FuaXphdGlvbjE1NjU4NjM4","avatar_url":"https://avatars1.githubusercontent.com/u/15658638?v=4","gravatar_id":"","url":"https://api.github.com/users/tensorflow","html_url":"https://github.com/tensorflow","followers_url":"https://api.github.com/users/tensorflow/followers","following_url":"https://api.github.com/users/tensorflow/following{/other_user}","gists_url":"https://api.github.com/users/tensorflow/gists{/gist_id}","starred_url":"https://api.github.com/users/tensorflow/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tensorflow/subscriptions","organizations_url":"https://api.github.com/users/tensorflow/orgs","repos_url":"https://api.github.com/users/tensorflow/repos","events_url":"https://api.github.com/users/tensorflow/events{/privacy}","received_events_url":"https://api.github.com/users/tensorflow/received_events","type":"Organization","site_admin":false},"repo":{"id":99127696,"node_id":"MDEwOlJlcG9zaXRvcnk5OTEyNzY5Ng==","name":"tfjs-core","full_name":"tensorflow/tfjs-core","private":false,"owner":{"login":"tensorflow","id":15658638,"node_id":"MDEyOk9yZ2FuaXphdGlvbjE1NjU4NjM4","avatar_url":"https://avatars1.githubusercontent.com/u/15658638?v=4","gravatar_id":"","url":"https://api.github.com/users/tensorflow","html_url":"https://github.com/tensorflow","followers_url":"https://api.github.com/users/tensorflow/followers","following_url":"https://api.github.com/users/tensorflow/following{/other_user}","gists_url":"https://api.github.com/users/tensorflow/gists{/gist_id}","starred_url":"https://api.github.com/users/tensorflow/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tensorflow/subscriptions","organizations_url":"https://api.github.com/users/tensorflow/orgs","repos_url":"https://api.github.com/users/tensorflow/repos","events_url":"https://api.github.com/users/tensorflow/events{/privacy}","received_events_url":"https://api.github.com/users/tensorflow/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/tensorflow/tfjs-core","description":"WebGL-accelerated ML // linear algebra // automatic differentiation for JavaScript.","fork":false,"url":"https://api.github.com/repos/tensorflow/tfjs-core","forks_url":"https://api.github.com/repos/tensorflow/tfjs-core/forks","keys_url":"https://api.github.com/repos/tensorflow/tfjs-core/keys{/key_id}","collaborators_url":"https://api.github.com/repos/tensorflow/tfjs-core/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/tensorflow/tfjs-core/teams","hooks_url":"https://api.github.com/repos/tensorflow/tfjs-core/hooks","issue_events_url":"https://api.github.com/repos/tensorflow/tfjs-core/issues/events{/number}","events_url":"https://api.github.com/repos/tensorflow/tfjs-core/events","assignees_url":"https://api.github.com/repos/tensorflow/tfjs-core/assignees{/user}","branches_url":"https://api.github.com/repos/tensorflow/tfjs-core/branches{/branch}","tags_url":"https://api.github.com/repos/tensorflow/tfjs-core/tags","blobs_url":"https://api.github.com/repos/tensorflow/tfjs-core/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/tensorflow/tfjs-core/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/tensorflow/tfjs-core/git/refs{/sha}","trees_url":"https://api.github.com/repos/tensorflow/tfjs-core/git/trees{/sha}","statuses_url":"https://api.github.com/repos/tensorflow/tfjs-core/statuses/{sha}","languages_url":"https://api.github.com/repos/tensorflow/tfjs-core/languages","stargazers_url":"https://api.github.com/repos/tensorflow/tfjs-core/stargazers","contributors_url":"https://api.github.com/repos/tensorflow/tfjs-core/contributors","subscribers_url":"https://api.github.com/repos/tensorflow/tfjs-core/subscribers","subscription_url":"https://api.github.com/repos/tensorflow/tfjs-core/subscription","commits_url":"https://api.github.com/repos/tensorflow/tfjs-core/commits{/sha}","git_commits_url":"https://api.github.com/repos/tensorflow/tfjs-core/git/commits{/sha}","comments_url":"https://api.github.com/repos/tensorflow/tfjs-core/comments{/number}","issue_comment_url":"https://api.github.com/repos/tensorflow/tfjs-core/issues/comments{/number}","contents_url":"https://api.github.com/repos/tensorflow/tfjs-core/contents/{+path}","compare_url":"https://api.github.com/repos/tensorflow/tfjs-core/compare/{base}...{head}","merges_url":"https://api.github.com/repos/tensorflow/tfjs-core/merges","archive_url":"https://api.github.com/repos/tensorflow/tfjs-core/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/tensorflow/tfjs-core/downloads","issues_url":"https://api.github.com/repos/tensorflow/tfjs-core/issues{/number}","pulls_url":"https://api.github.com/repos/tensorflow/tfjs-core/pulls{/number}","milestones_url":"https://api.github.com/repos/tensorflow/tfjs-core/milestones{/number}","notifications_url":"https://api.github.com/repos/tensorflow/tfjs-core/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/tensorflow/tfjs-core/labels{/name}","releases_url":"https://api.github.com/repos/tensorflow/tfjs-core/releases{/id}","deployments_url":"https://api.github.com/repos/tensorflow/tfjs-core/deployments","created_at":"2017-08-02T14:45:47Z","updated_at":"2018-09-18T20:36:32Z","pushed_at":"2018-09-19T00:21:15Z","git_url":"git://github.com/tensorflow/tfjs-core.git","ssh_url":"git@github.com:tensorflow/tfjs-core.git","clone_url":"https://github.com/tensorflow/tfjs-core.git","svn_url":"https://github.com/tensorflow/tfjs-core","homepage":"https://js.tensorflow.org","size":359008,"stargazers_count":7975,"watchers_count":7975,"language":"TypeScript","has_issues":false,"has_projects":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":841,"mirror_url":null,"archived":false,"open_issues_count":16,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":841,"open_issues":16,"watchers":7975,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/tensorflow/tfjs-core/pulls/1271"},"html":{"href":"https://github.com/tensorflow/tfjs-core/pull/1271"},"issue":{"href":"https://api.github.com/repos/tensorflow/tfjs-core/issues/1271"},"comments":{"href":"https://api.github.com/repos/tensorflow/tfjs-core/issues/1271/comments"},"review_comments":{"href":"https://api.github.com/repos/tensorflow/tfjs-core/pulls/1271/comments"},"review_comment":{"href":"https://api.github.com/repos/tensorflow/tfjs-core/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/tensorflow/tfjs-core/pulls/1271/commits"},"statuses":{"href":"https://api.github.com/repos/tensorflow/tfjs-core/statuses/4b524378a9738e7852c53d18ad398a7995fb4c7f"}},"author_association":"NONE"}}
{"actor":{"display_login":"pvaneck"}}