{"action":"created","comment":{"url":"https://api.github.com/repos/scikit-image/scikit-image/pulls/comments/37047089","id":37047089,"diff_hunk":"@@ -163,3 +163,14 @@ def assert_nD(array, ndim, arg_name='image'):\n         ndim = [ndim]\n     if not array.ndim in ndim:\n         raise ValueError(msg % (arg_name, '-or-'.join([str(n) for n in ndim])))\n+\n+\n+def _mode_deprecations(mode):\n+    \"\"\" to be used by functions to update deprecated mode names in\n+    `skimage._shared.interpolation.pyx`.\"\"\"\n+    if mode.lower() == 'nearest':\n+        warnings.warn(skimage_deprecation(\n+            \"Mode 'nearest' has been renamed 'edge'. Mode 'nearest' will be \"","path":"skimage/_shared/utils.py","position":11,"original_position":11,"commit_id":"ad0902940f85cb81bd3f9321bfc4b629b8fc50b6","original_commit_id":"ad0902940f85cb81bd3f9321bfc4b629b8fc50b6","user":{"login":"ahojnnes","id":134307,"avatar_url":"https://avatars.githubusercontent.com/u/134307?v=3","gravatar_id":"","url":"https://api.github.com/users/ahojnnes","html_url":"https://github.com/ahojnnes","followers_url":"https://api.github.com/users/ahojnnes/followers","following_url":"https://api.github.com/users/ahojnnes/following{/other_user}","gists_url":"https://api.github.com/users/ahojnnes/gists{/gist_id}","starred_url":"https://api.github.com/users/ahojnnes/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ahojnnes/subscriptions","organizations_url":"https://api.github.com/users/ahojnnes/orgs","repos_url":"https://api.github.com/users/ahojnnes/repos","events_url":"https://api.github.com/users/ahojnnes/events{/privacy}","received_events_url":"https://api.github.com/users/ahojnnes/received_events","type":"User","site_admin":false},"body":"Please, add a new item to TODO.txt","created_at":"2015-08-14T03:26:32Z","updated_at":"2015-08-14T03:26:32Z","html_url":"https://github.com/scikit-image/scikit-image/pull/1583#discussion_r37047089","pull_request_url":"https://api.github.com/repos/scikit-image/scikit-image/pulls/1583","_links":{"self":{"href":"https://api.github.com/repos/scikit-image/scikit-image/pulls/comments/37047089"},"html":{"href":"https://github.com/scikit-image/scikit-image/pull/1583#discussion_r37047089"},"pull_request":{"href":"https://api.github.com/repos/scikit-image/scikit-image/pulls/1583"}}},"pull_request":{"url":"https://api.github.com/repos/scikit-image/scikit-image/pulls/1583","id":39428557,"html_url":"https://github.com/scikit-image/scikit-image/pull/1583","diff_url":"https://github.com/scikit-image/scikit-image/pull/1583.diff","patch_url":"https://github.com/scikit-image/scikit-image/pull/1583.patch","issue_url":"https://api.github.com/repos/scikit-image/scikit-image/issues/1583","number":1583,"state":"open","locked":false,"title":"FIX:  bug in 'reflect' and 'wrap' coordinate mapping","user":{"login":"grlee77","id":6528957,"avatar_url":"https://avatars.githubusercontent.com/u/6528957?v=3","gravatar_id":"","url":"https://api.github.com/users/grlee77","html_url":"https://github.com/grlee77","followers_url":"https://api.github.com/users/grlee77/followers","following_url":"https://api.github.com/users/grlee77/following{/other_user}","gists_url":"https://api.github.com/users/grlee77/gists{/gist_id}","starred_url":"https://api.github.com/users/grlee77/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/grlee77/subscriptions","organizations_url":"https://api.github.com/users/grlee77/orgs","repos_url":"https://api.github.com/users/grlee77/repos","events_url":"https://api.github.com/users/grlee77/events{/privacy}","received_events_url":"https://api.github.com/users/grlee77/received_events","type":"User","site_admin":false},"body":"This pull request fixes subtle indexing errors in ``coord_map`` from ``_shared.interpolation.pyx``\r\nfor modes 'reflect' and 'mirror'.\r\n\r\nI added a small python wrapper to coord_map so I could create a test.  The image example shown below was added to the documentation.\r\n\r\nThe following lists output for a set of 1D coordinates before and after the PR:\r\n\r\n```python\r\nwrap = [coord_map(4, n, 'W') for n in range(-6, 6)]\r\n# before PR, wrap = [3, 1, 2, 3, 1, 2, 0, 1, 2, 3, 1, 2]\r\n# after PR, wrap  = [2, 3, 0, 1, 2, 3, 0, 1, 2, 3, 0, 1]\r\n```\r\nNote that coordinate 0 was not wrapped!\r\n\r\n```python\r\nreflect = [coord_map(4, n, 'R') for n in range(-6, 6)]\r\n# before PR, reflect = [0, 1, 2, 3, 2, 1, 0, 1, 2, 3, 2, 1]\r\n# after PR, reflect  = [2, 3, 3, 2, 1, 0, 0, 1, 2, 3, 3, 2]\r\n```\r\nnote that the edge coordinates 0 and 3 were not being duplicated in the mirrors\r\n\r\nThe difference is perhaps easier to see in images than the 1D example above. The original image extent is indicated by the region inside the yellow lines.\r\n\r\n**Prior to the PR:**\r\n![buggy_edge_modesv2](https://cloud.githubusercontent.com/assets/6528957/8559764/c94252a8-24de-11e5-9506-4314de1017cc.png)\r\n\r\n**After this PR:**\r\n![fixed_edge_modesv2](https://cloud.githubusercontent.com/assets/6528957/8559765/cdfc4448-24de-11e5-9554-514c528ce03b.png)\r\n","created_at":"2015-07-07T23:39:36Z","updated_at":"2015-08-14T03:26:32Z","closed_at":null,"merged_at":null,"merge_commit_sha":"a93355ef2d4f36832953b5b79b90fdc84d16dcfd","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/scikit-image/scikit-image/pulls/1583/commits","review_comments_url":"https://api.github.com/repos/scikit-image/scikit-image/pulls/1583/comments","review_comment_url":"https://api.github.com/repos/scikit-image/scikit-image/pulls/comments{/number}","comments_url":"https://api.github.com/repos/scikit-image/scikit-image/issues/1583/comments","statuses_url":"https://api.github.com/repos/scikit-image/scikit-image/statuses/ad0902940f85cb81bd3f9321bfc4b629b8fc50b6","head":{"label":"grlee77:fix_interp_modes","ref":"fix_interp_modes","sha":"ad0902940f85cb81bd3f9321bfc4b629b8fc50b6","user":{"login":"grlee77","id":6528957,"avatar_url":"https://avatars.githubusercontent.com/u/6528957?v=3","gravatar_id":"","url":"https://api.github.com/users/grlee77","html_url":"https://github.com/grlee77","followers_url":"https://api.github.com/users/grlee77/followers","following_url":"https://api.github.com/users/grlee77/following{/other_user}","gists_url":"https://api.github.com/users/grlee77/gists{/gist_id}","starred_url":"https://api.github.com/users/grlee77/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/grlee77/subscriptions","organizations_url":"https://api.github.com/users/grlee77/orgs","repos_url":"https://api.github.com/users/grlee77/repos","events_url":"https://api.github.com/users/grlee77/events{/privacy}","received_events_url":"https://api.github.com/users/grlee77/received_events","type":"User","site_admin":false},"repo":{"id":23844497,"name":"scikit-image","full_name":"grlee77/scikit-image","owner":{"login":"grlee77","id":6528957,"avatar_url":"https://avatars.githubusercontent.com/u/6528957?v=3","gravatar_id":"","url":"https://api.github.com/users/grlee77","html_url":"https://github.com/grlee77","followers_url":"https://api.github.com/users/grlee77/followers","following_url":"https://api.github.com/users/grlee77/following{/other_user}","gists_url":"https://api.github.com/users/grlee77/gists{/gist_id}","starred_url":"https://api.github.com/users/grlee77/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/grlee77/subscriptions","organizations_url":"https://api.github.com/users/grlee77/orgs","repos_url":"https://api.github.com/users/grlee77/repos","events_url":"https://api.github.com/users/grlee77/events{/privacy}","received_events_url":"https://api.github.com/users/grlee77/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/grlee77/scikit-image","description":"Image Processing SciKit (Toolbox for SciPy)","fork":true,"url":"https://api.github.com/repos/grlee77/scikit-image","forks_url":"https://api.github.com/repos/grlee77/scikit-image/forks","keys_url":"https://api.github.com/repos/grlee77/scikit-image/keys{/key_id}","collaborators_url":"https://api.github.com/repos/grlee77/scikit-image/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/grlee77/scikit-image/teams","hooks_url":"https://api.github.com/repos/grlee77/scikit-image/hooks","issue_events_url":"https://api.github.com/repos/grlee77/scikit-image/issues/events{/number}","events_url":"https://api.github.com/repos/grlee77/scikit-image/events","assignees_url":"https://api.github.com/repos/grlee77/scikit-image/assignees{/user}","branches_url":"https://api.github.com/repos/grlee77/scikit-image/branches{/branch}","tags_url":"https://api.github.com/repos/grlee77/scikit-image/tags","blobs_url":"https://api.github.com/repos/grlee77/scikit-image/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/grlee77/scikit-image/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/grlee77/scikit-image/git/refs{/sha}","trees_url":"https://api.github.com/repos/grlee77/scikit-image/git/trees{/sha}","statuses_url":"https://api.github.com/repos/grlee77/scikit-image/statuses/{sha}","languages_url":"https://api.github.com/repos/grlee77/scikit-image/languages","stargazers_url":"https://api.github.com/repos/grlee77/scikit-image/stargazers","contributors_url":"https://api.github.com/repos/grlee77/scikit-image/contributors","subscribers_url":"https://api.github.com/repos/grlee77/scikit-image/subscribers","subscription_url":"https://api.github.com/repos/grlee77/scikit-image/subscription","commits_url":"https://api.github.com/repos/grlee77/scikit-image/commits{/sha}","git_commits_url":"https://api.github.com/repos/grlee77/scikit-image/git/commits{/sha}","comments_url":"https://api.github.com/repos/grlee77/scikit-image/comments{/number}","issue_comment_url":"https://api.github.com/repos/grlee77/scikit-image/issues/comments{/number}","contents_url":"https://api.github.com/repos/grlee77/scikit-image/contents/{+path}","compare_url":"https://api.github.com/repos/grlee77/scikit-image/compare/{base}...{head}","merges_url":"https://api.github.com/repos/grlee77/scikit-image/merges","archive_url":"https://api.github.com/repos/grlee77/scikit-image/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/grlee77/scikit-image/downloads","issues_url":"https://api.github.com/repos/grlee77/scikit-image/issues{/number}","pulls_url":"https://api.github.com/repos/grlee77/scikit-image/pulls{/number}","milestones_url":"https://api.github.com/repos/grlee77/scikit-image/milestones{/number}","notifications_url":"https://api.github.com/repos/grlee77/scikit-image/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/grlee77/scikit-image/labels{/name}","releases_url":"https://api.github.com/repos/grlee77/scikit-image/releases{/id}","created_at":"2014-09-09T18:00:05Z","updated_at":"2015-03-05T22:53:39Z","pushed_at":"2015-08-14T03:01:35Z","git_url":"git://github.com/grlee77/scikit-image.git","ssh_url":"git@github.com:grlee77/scikit-image.git","clone_url":"https://github.com/grlee77/scikit-image.git","svn_url":"https://github.com/grlee77/scikit-image","homepage":"http://scikit-image.org","size":39453,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"scikit-image:master","ref":"master","sha":"3ce57f244bbc086f90ec86af16cb4e2f3558d2a1","user":{"login":"scikit-image","id":897180,"avatar_url":"https://avatars.githubusercontent.com/u/897180?v=3","gravatar_id":"","url":"https://api.github.com/users/scikit-image","html_url":"https://github.com/scikit-image","followers_url":"https://api.github.com/users/scikit-image/followers","following_url":"https://api.github.com/users/scikit-image/following{/other_user}","gists_url":"https://api.github.com/users/scikit-image/gists{/gist_id}","starred_url":"https://api.github.com/users/scikit-image/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/scikit-image/subscriptions","organizations_url":"https://api.github.com/users/scikit-image/orgs","repos_url":"https://api.github.com/users/scikit-image/repos","events_url":"https://api.github.com/users/scikit-image/events{/privacy}","received_events_url":"https://api.github.com/users/scikit-image/received_events","type":"Organization","site_admin":false},"repo":{"id":2014929,"name":"scikit-image","full_name":"scikit-image/scikit-image","owner":{"login":"scikit-image","id":897180,"avatar_url":"https://avatars.githubusercontent.com/u/897180?v=3","gravatar_id":"","url":"https://api.github.com/users/scikit-image","html_url":"https://github.com/scikit-image","followers_url":"https://api.github.com/users/scikit-image/followers","following_url":"https://api.github.com/users/scikit-image/following{/other_user}","gists_url":"https://api.github.com/users/scikit-image/gists{/gist_id}","starred_url":"https://api.github.com/users/scikit-image/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/scikit-image/subscriptions","organizations_url":"https://api.github.com/users/scikit-image/orgs","repos_url":"https://api.github.com/users/scikit-image/repos","events_url":"https://api.github.com/users/scikit-image/events{/privacy}","received_events_url":"https://api.github.com/users/scikit-image/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/scikit-image/scikit-image","description":"Image Processing SciKit (Toolbox for SciPy)","fork":false,"url":"https://api.github.com/repos/scikit-image/scikit-image","forks_url":"https://api.github.com/repos/scikit-image/scikit-image/forks","keys_url":"https://api.github.com/repos/scikit-image/scikit-image/keys{/key_id}","collaborators_url":"https://api.github.com/repos/scikit-image/scikit-image/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/scikit-image/scikit-image/teams","hooks_url":"https://api.github.com/repos/scikit-image/scikit-image/hooks","issue_events_url":"https://api.github.com/repos/scikit-image/scikit-image/issues/events{/number}","events_url":"https://api.github.com/repos/scikit-image/scikit-image/events","assignees_url":"https://api.github.com/repos/scikit-image/scikit-image/assignees{/user}","branches_url":"https://api.github.com/repos/scikit-image/scikit-image/branches{/branch}","tags_url":"https://api.github.com/repos/scikit-image/scikit-image/tags","blobs_url":"https://api.github.com/repos/scikit-image/scikit-image/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/scikit-image/scikit-image/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/scikit-image/scikit-image/git/refs{/sha}","trees_url":"https://api.github.com/repos/scikit-image/scikit-image/git/trees{/sha}","statuses_url":"https://api.github.com/repos/scikit-image/scikit-image/statuses/{sha}","languages_url":"https://api.github.com/repos/scikit-image/scikit-image/languages","stargazers_url":"https://api.github.com/repos/scikit-image/scikit-image/stargazers","contributors_url":"https://api.github.com/repos/scikit-image/scikit-image/contributors","subscribers_url":"https://api.github.com/repos/scikit-image/scikit-image/subscribers","subscription_url":"https://api.github.com/repos/scikit-image/scikit-image/subscription","commits_url":"https://api.github.com/repos/scikit-image/scikit-image/commits{/sha}","git_commits_url":"https://api.github.com/repos/scikit-image/scikit-image/git/commits{/sha}","comments_url":"https://api.github.com/repos/scikit-image/scikit-image/comments{/number}","issue_comment_url":"https://api.github.com/repos/scikit-image/scikit-image/issues/comments{/number}","contents_url":"https://api.github.com/repos/scikit-image/scikit-image/contents/{+path}","compare_url":"https://api.github.com/repos/scikit-image/scikit-image/compare/{base}...{head}","merges_url":"https://api.github.com/repos/scikit-image/scikit-image/merges","archive_url":"https://api.github.com/repos/scikit-image/scikit-image/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/scikit-image/scikit-image/downloads","issues_url":"https://api.github.com/repos/scikit-image/scikit-image/issues{/number}","pulls_url":"https://api.github.com/repos/scikit-image/scikit-image/pulls{/number}","milestones_url":"https://api.github.com/repos/scikit-image/scikit-image/milestones{/number}","notifications_url":"https://api.github.com/repos/scikit-image/scikit-image/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/scikit-image/scikit-image/labels{/name}","releases_url":"https://api.github.com/repos/scikit-image/scikit-image/releases{/id}","created_at":"2011-07-07T22:07:20Z","updated_at":"2015-08-14T01:33:03Z","pushed_at":"2015-08-14T03:01:36Z","git_url":"git://github.com/scikit-image/scikit-image.git","ssh_url":"git@github.com:scikit-image/scikit-image.git","clone_url":"https://github.com/scikit-image/scikit-image.git","svn_url":"https://github.com/scikit-image/scikit-image","homepage":"http://scikit-image.org","size":72556,"stargazers_count":783,"watchers_count":783,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":395,"mirror_url":null,"open_issues_count":198,"forks":395,"open_issues":198,"watchers":783,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/scikit-image/scikit-image/pulls/1583"},"html":{"href":"https://github.com/scikit-image/scikit-image/pull/1583"},"issue":{"href":"https://api.github.com/repos/scikit-image/scikit-image/issues/1583"},"comments":{"href":"https://api.github.com/repos/scikit-image/scikit-image/issues/1583/comments"},"review_comments":{"href":"https://api.github.com/repos/scikit-image/scikit-image/pulls/1583/comments"},"review_comment":{"href":"https://api.github.com/repos/scikit-image/scikit-image/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/scikit-image/scikit-image/pulls/1583/commits"},"statuses":{"href":"https://api.github.com/repos/scikit-image/scikit-image/statuses/ad0902940f85cb81bd3f9321bfc4b629b8fc50b6"}}}}