{"action":"created","comment":{"url":"https://api.github.com/repos/pytorch/vision/pulls/comments/214446226","pull_request_review_id":151513681,"id":214446226,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIxNDQ0NjIyNg==","diff_hunk":"@@ -75,34 +73,35 @@ __global__ void RoIPoolFForward(const int nthreads, const T* bottom_data,\n }\n \n template <typename T>\n-__global__ void RoIPoolFBackward(const int nthreads, const T* top_diff,\n+__global__ void RoIPoolBackward(const int nthreads, const T* top_grad,\n     const int* argmax_data, const int num_rois, const T spatial_scale,\n     const int channels, const int height, const int width,\n-    const int pooled_height, const int pooled_width, T* bottom_diff,\n-    const T* bottom_rois) {\n-  CUDA_1D_KERNEL_LOOP(index, nthreads) {\n-    // (n, c, ph, pw) is an element in the pooled output\n-    int pw = index % pooled_width;\n-    int ph = (index / pooled_width) % pooled_height;\n-    int c = (index / pooled_width / pooled_height) % channels;\n-    int n = index / pooled_width / pooled_height / channels;\n-\n-    const T* offset_bottom_rois = bottom_rois + n * 5;\n-    int roi_batch_ind = offset_bottom_rois[0];\n-    int bottom_offset = (roi_batch_ind * channels + c) * height * width;\n-    int top_offset    = (n * channels + c) * pooled_height * pooled_width;\n-    const T* offset_top_diff = top_diff + top_offset;\n-    T* offset_bottom_diff = bottom_diff + bottom_offset;\n-    const int* offset_argmax_data = argmax_data + top_offset;\n-\n-    int argmax = offset_argmax_data[ph * pooled_width + pw];\n-    if (argmax != -1) {\n-      atomicAdd(\n-          offset_bottom_diff + argmax,\n-          static_cast<T>(offset_top_diff[ph * pooled_width + pw]));\n-\n+    const int pooled_height, const int pooled_width, T* bottom_data,","path":"torchvision/csrc/cuda/ROIPool_cuda.cu","position":63,"original_position":63,"commit_id":"7b6d1d273c6e82e64b97e32cbefdf608be5b9d51","original_commit_id":"7b6d1d273c6e82e64b97e32cbefdf608be5b9d51","user":{"login":"varunagrawal","id":975964,"node_id":"MDQ6VXNlcjk3NTk2NA==","avatar_url":"https://avatars2.githubusercontent.com/u/975964?v=4","gravatar_id":"","url":"https://api.github.com/users/varunagrawal","html_url":"https://github.com/varunagrawal","followers_url":"https://api.github.com/users/varunagrawal/followers","following_url":"https://api.github.com/users/varunagrawal/following{/other_user}","gists_url":"https://api.github.com/users/varunagrawal/gists{/gist_id}","starred_url":"https://api.github.com/users/varunagrawal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/varunagrawal/subscriptions","organizations_url":"https://api.github.com/users/varunagrawal/orgs","repos_url":"https://api.github.com/users/varunagrawal/repos","events_url":"https://api.github.com/users/varunagrawal/events{/privacy}","received_events_url":"https://api.github.com/users/varunagrawal/received_events","type":"User","site_admin":false},"body":"I actually wanted to update the names to be more torch-like e.g. `input`, `output`, `grad_input` and `grad_output`, since that would lead to minimum confusion. Should I just do that?","created_at":"2018-08-31T18:54:45Z","updated_at":"2018-08-31T18:54:45Z","html_url":"https://github.com/pytorch/vision/pull/592#discussion_r214446226","pull_request_url":"https://api.github.com/repos/pytorch/vision/pulls/592","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/pytorch/vision/pulls/comments/214446226"},"html":{"href":"https://github.com/pytorch/vision/pull/592#discussion_r214446226"},"pull_request":{"href":"https://api.github.com/repos/pytorch/vision/pulls/592"}},"in_reply_to_id":214281430},"pull_request":{"url":"https://api.github.com/repos/pytorch/vision/pulls/592","id":212180329,"node_id":"MDExOlB1bGxSZXF1ZXN0MjEyMTgwMzI5","html_url":"https://github.com/pytorch/vision/pull/592","diff_url":"https://github.com/pytorch/vision/pull/592.diff","patch_url":"https://github.com/pytorch/vision/pull/592.patch","issue_url":"https://api.github.com/repos/pytorch/vision/issues/592","number":592,"state":"open","locked":false,"title":"Support for ROI Pooling","user":{"login":"varunagrawal","id":975964,"node_id":"MDQ6VXNlcjk3NTk2NA==","avatar_url":"https://avatars2.githubusercontent.com/u/975964?v=4","gravatar_id":"","url":"https://api.github.com/users/varunagrawal","html_url":"https://github.com/varunagrawal","followers_url":"https://api.github.com/users/varunagrawal/followers","following_url":"https://api.github.com/users/varunagrawal/following{/other_user}","gists_url":"https://api.github.com/users/varunagrawal/gists{/gist_id}","starred_url":"https://api.github.com/users/varunagrawal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/varunagrawal/subscriptions","organizations_url":"https://api.github.com/users/varunagrawal/orgs","repos_url":"https://api.github.com/users/varunagrawal/repos","events_url":"https://api.github.com/users/varunagrawal/events{/privacy}","received_events_url":"https://api.github.com/users/varunagrawal/received_events","type":"User","site_admin":false},"body":"ROI Pooling with tests. Fix for cuda context in ROI Align.\r\n\r\n@fmassa please can you review this?","created_at":"2018-08-30T19:05:34Z","updated_at":"2018-08-31T18:54:45Z","closed_at":null,"merged_at":null,"merge_commit_sha":"88a1030e0c35acc7a1ce0608577388119f2f0a89","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/pytorch/vision/pulls/592/commits","review_comments_url":"https://api.github.com/repos/pytorch/vision/pulls/592/comments","review_comment_url":"https://api.github.com/repos/pytorch/vision/pulls/comments{/number}","comments_url":"https://api.github.com/repos/pytorch/vision/issues/592/comments","statuses_url":"https://api.github.com/repos/pytorch/vision/statuses/7b6d1d273c6e82e64b97e32cbefdf608be5b9d51","head":{"label":"varunagrawal:layers","ref":"layers","sha":"7b6d1d273c6e82e64b97e32cbefdf608be5b9d51","user":{"login":"varunagrawal","id":975964,"node_id":"MDQ6VXNlcjk3NTk2NA==","avatar_url":"https://avatars2.githubusercontent.com/u/975964?v=4","gravatar_id":"","url":"https://api.github.com/users/varunagrawal","html_url":"https://github.com/varunagrawal","followers_url":"https://api.github.com/users/varunagrawal/followers","following_url":"https://api.github.com/users/varunagrawal/following{/other_user}","gists_url":"https://api.github.com/users/varunagrawal/gists{/gist_id}","starred_url":"https://api.github.com/users/varunagrawal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/varunagrawal/subscriptions","organizations_url":"https://api.github.com/users/varunagrawal/orgs","repos_url":"https://api.github.com/users/varunagrawal/repos","events_url":"https://api.github.com/users/varunagrawal/events{/privacy}","received_events_url":"https://api.github.com/users/varunagrawal/received_events","type":"User","site_admin":false},"repo":{"id":86637560,"node_id":"MDEwOlJlcG9zaXRvcnk4NjYzNzU2MA==","name":"vision","full_name":"varunagrawal/vision","owner":{"login":"varunagrawal","id":975964,"node_id":"MDQ6VXNlcjk3NTk2NA==","avatar_url":"https://avatars2.githubusercontent.com/u/975964?v=4","gravatar_id":"","url":"https://api.github.com/users/varunagrawal","html_url":"https://github.com/varunagrawal","followers_url":"https://api.github.com/users/varunagrawal/followers","following_url":"https://api.github.com/users/varunagrawal/following{/other_user}","gists_url":"https://api.github.com/users/varunagrawal/gists{/gist_id}","starred_url":"https://api.github.com/users/varunagrawal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/varunagrawal/subscriptions","organizations_url":"https://api.github.com/users/varunagrawal/orgs","repos_url":"https://api.github.com/users/varunagrawal/repos","events_url":"https://api.github.com/users/varunagrawal/events{/privacy}","received_events_url":"https://api.github.com/users/varunagrawal/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/varunagrawal/vision","description":"Datasets, Transforms and Models specific to Computer Vision","fork":true,"url":"https://api.github.com/repos/varunagrawal/vision","forks_url":"https://api.github.com/repos/varunagrawal/vision/forks","keys_url":"https://api.github.com/repos/varunagrawal/vision/keys{/key_id}","collaborators_url":"https://api.github.com/repos/varunagrawal/vision/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/varunagrawal/vision/teams","hooks_url":"https://api.github.com/repos/varunagrawal/vision/hooks","issue_events_url":"https://api.github.com/repos/varunagrawal/vision/issues/events{/number}","events_url":"https://api.github.com/repos/varunagrawal/vision/events","assignees_url":"https://api.github.com/repos/varunagrawal/vision/assignees{/user}","branches_url":"https://api.github.com/repos/varunagrawal/vision/branches{/branch}","tags_url":"https://api.github.com/repos/varunagrawal/vision/tags","blobs_url":"https://api.github.com/repos/varunagrawal/vision/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/varunagrawal/vision/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/varunagrawal/vision/git/refs{/sha}","trees_url":"https://api.github.com/repos/varunagrawal/vision/git/trees{/sha}","statuses_url":"https://api.github.com/repos/varunagrawal/vision/statuses/{sha}","languages_url":"https://api.github.com/repos/varunagrawal/vision/languages","stargazers_url":"https://api.github.com/repos/varunagrawal/vision/stargazers","contributors_url":"https://api.github.com/repos/varunagrawal/vision/contributors","subscribers_url":"https://api.github.com/repos/varunagrawal/vision/subscribers","subscription_url":"https://api.github.com/repos/varunagrawal/vision/subscription","commits_url":"https://api.github.com/repos/varunagrawal/vision/commits{/sha}","git_commits_url":"https://api.github.com/repos/varunagrawal/vision/git/commits{/sha}","comments_url":"https://api.github.com/repos/varunagrawal/vision/comments{/number}","issue_comment_url":"https://api.github.com/repos/varunagrawal/vision/issues/comments{/number}","contents_url":"https://api.github.com/repos/varunagrawal/vision/contents/{+path}","compare_url":"https://api.github.com/repos/varunagrawal/vision/compare/{base}...{head}","merges_url":"https://api.github.com/repos/varunagrawal/vision/merges","archive_url":"https://api.github.com/repos/varunagrawal/vision/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/varunagrawal/vision/downloads","issues_url":"https://api.github.com/repos/varunagrawal/vision/issues{/number}","pulls_url":"https://api.github.com/repos/varunagrawal/vision/pulls{/number}","milestones_url":"https://api.github.com/repos/varunagrawal/vision/milestones{/number}","notifications_url":"https://api.github.com/repos/varunagrawal/vision/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/varunagrawal/vision/labels{/name}","releases_url":"https://api.github.com/repos/varunagrawal/vision/releases{/id}","deployments_url":"https://api.github.com/repos/varunagrawal/vision/deployments","created_at":"2017-03-29T23:12:10Z","updated_at":"2018-08-23T20:01:00Z","pushed_at":"2018-08-30T19:03:56Z","git_url":"git://github.com/varunagrawal/vision.git","ssh_url":"git@github.com:varunagrawal/vision.git","clone_url":"https://github.com/varunagrawal/vision.git","svn_url":"https://github.com/varunagrawal/vision","homepage":null,"size":2141,"stargazers_count":0,"watchers_count":0,"language":"Jupyter Notebook","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","node_id":"MDc6TGljZW5zZTU="},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"pytorch:layers","ref":"layers","sha":"0b5c026cf8649ba4dcafab1d5b04e505af0b282e","user":{"login":"pytorch","id":21003710,"node_id":"MDEyOk9yZ2FuaXphdGlvbjIxMDAzNzEw","avatar_url":"https://avatars3.githubusercontent.com/u/21003710?v=4","gravatar_id":"","url":"https://api.github.com/users/pytorch","html_url":"https://github.com/pytorch","followers_url":"https://api.github.com/users/pytorch/followers","following_url":"https://api.github.com/users/pytorch/following{/other_user}","gists_url":"https://api.github.com/users/pytorch/gists{/gist_id}","starred_url":"https://api.github.com/users/pytorch/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pytorch/subscriptions","organizations_url":"https://api.github.com/users/pytorch/orgs","repos_url":"https://api.github.com/users/pytorch/repos","events_url":"https://api.github.com/users/pytorch/events{/privacy}","received_events_url":"https://api.github.com/users/pytorch/received_events","type":"Organization","site_admin":false},"repo":{"id":73328905,"node_id":"MDEwOlJlcG9zaXRvcnk3MzMyODkwNQ==","name":"vision","full_name":"pytorch/vision","owner":{"login":"pytorch","id":21003710,"node_id":"MDEyOk9yZ2FuaXphdGlvbjIxMDAzNzEw","avatar_url":"https://avatars3.githubusercontent.com/u/21003710?v=4","gravatar_id":"","url":"https://api.github.com/users/pytorch","html_url":"https://github.com/pytorch","followers_url":"https://api.github.com/users/pytorch/followers","following_url":"https://api.github.com/users/pytorch/following{/other_user}","gists_url":"https://api.github.com/users/pytorch/gists{/gist_id}","starred_url":"https://api.github.com/users/pytorch/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pytorch/subscriptions","organizations_url":"https://api.github.com/users/pytorch/orgs","repos_url":"https://api.github.com/users/pytorch/repos","events_url":"https://api.github.com/users/pytorch/events{/privacy}","received_events_url":"https://api.github.com/users/pytorch/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/pytorch/vision","description":"Datasets, Transforms and Models specific to Computer Vision","fork":false,"url":"https://api.github.com/repos/pytorch/vision","forks_url":"https://api.github.com/repos/pytorch/vision/forks","keys_url":"https://api.github.com/repos/pytorch/vision/keys{/key_id}","collaborators_url":"https://api.github.com/repos/pytorch/vision/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/pytorch/vision/teams","hooks_url":"https://api.github.com/repos/pytorch/vision/hooks","issue_events_url":"https://api.github.com/repos/pytorch/vision/issues/events{/number}","events_url":"https://api.github.com/repos/pytorch/vision/events","assignees_url":"https://api.github.com/repos/pytorch/vision/assignees{/user}","branches_url":"https://api.github.com/repos/pytorch/vision/branches{/branch}","tags_url":"https://api.github.com/repos/pytorch/vision/tags","blobs_url":"https://api.github.com/repos/pytorch/vision/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/pytorch/vision/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/pytorch/vision/git/refs{/sha}","trees_url":"https://api.github.com/repos/pytorch/vision/git/trees{/sha}","statuses_url":"https://api.github.com/repos/pytorch/vision/statuses/{sha}","languages_url":"https://api.github.com/repos/pytorch/vision/languages","stargazers_url":"https://api.github.com/repos/pytorch/vision/stargazers","contributors_url":"https://api.github.com/repos/pytorch/vision/contributors","subscribers_url":"https://api.github.com/repos/pytorch/vision/subscribers","subscription_url":"https://api.github.com/repos/pytorch/vision/subscription","commits_url":"https://api.github.com/repos/pytorch/vision/commits{/sha}","git_commits_url":"https://api.github.com/repos/pytorch/vision/git/commits{/sha}","comments_url":"https://api.github.com/repos/pytorch/vision/comments{/number}","issue_comment_url":"https://api.github.com/repos/pytorch/vision/issues/comments{/number}","contents_url":"https://api.github.com/repos/pytorch/vision/contents/{+path}","compare_url":"https://api.github.com/repos/pytorch/vision/compare/{base}...{head}","merges_url":"https://api.github.com/repos/pytorch/vision/merges","archive_url":"https://api.github.com/repos/pytorch/vision/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/pytorch/vision/downloads","issues_url":"https://api.github.com/repos/pytorch/vision/issues{/number}","pulls_url":"https://api.github.com/repos/pytorch/vision/pulls{/number}","milestones_url":"https://api.github.com/repos/pytorch/vision/milestones{/number}","notifications_url":"https://api.github.com/repos/pytorch/vision/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/pytorch/vision/labels{/name}","releases_url":"https://api.github.com/repos/pytorch/vision/releases{/id}","deployments_url":"https://api.github.com/repos/pytorch/vision/deployments","created_at":"2016-11-09T23:11:43Z","updated_at":"2018-08-31T17:49:45Z","pushed_at":"2018-08-30T19:05:34Z","git_url":"git://github.com/pytorch/vision.git","ssh_url":"git@github.com:pytorch/vision.git","clone_url":"https://github.com/pytorch/vision.git","svn_url":"https://github.com/pytorch/vision","homepage":null,"size":2131,"stargazers_count":1933,"watchers_count":1933,"language":"Jupyter Notebook","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":906,"mirror_url":null,"archived":false,"open_issues_count":106,"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","node_id":"MDc6TGljZW5zZTU="},"forks":906,"open_issues":106,"watchers":1933,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/pytorch/vision/pulls/592"},"html":{"href":"https://github.com/pytorch/vision/pull/592"},"issue":{"href":"https://api.github.com/repos/pytorch/vision/issues/592"},"comments":{"href":"https://api.github.com/repos/pytorch/vision/issues/592/comments"},"review_comments":{"href":"https://api.github.com/repos/pytorch/vision/pulls/592/comments"},"review_comment":{"href":"https://api.github.com/repos/pytorch/vision/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/pytorch/vision/pulls/592/commits"},"statuses":{"href":"https://api.github.com/repos/pytorch/vision/statuses/7b6d1d273c6e82e64b97e32cbefdf608be5b9d51"}},"author_association":"NONE"}}
{"actor":{"display_login":"varunagrawal"}}