{"action":"created","comment":{"url":"https://api.github.com/repos/DGtal-team/DGtal/pulls/comments/48943462","id":48943462,"diff_hunk":"@@ -509,7 +610,7 @@ namespace DGtal\n      * @return the cell having the topology of [c] and the given\n      * digital coordinates [p].\n      */\n-    Cell uCell( const Point & p, const Cell & c ) const;\n+    Cell uCell( Point p, const Cell & c ) const;","path":"src/DGtal/topology/KhalimskySpaceND.h","position":187,"original_position":187,"commit_id":"e2381b590e5b2e28f1309fe36587e25ab03633b1","original_commit_id":"e2381b590e5b2e28f1309fe36587e25ab03633b1","user":{"login":"JacquesOlivierLachaud","id":793707,"avatar_url":"https://avatars.githubusercontent.com/u/793707?v=3","gravatar_id":"","url":"https://api.github.com/users/JacquesOlivierLachaud","html_url":"https://github.com/JacquesOlivierLachaud","followers_url":"https://api.github.com/users/JacquesOlivierLachaud/followers","following_url":"https://api.github.com/users/JacquesOlivierLachaud/following{/other_user}","gists_url":"https://api.github.com/users/JacquesOlivierLachaud/gists{/gist_id}","starred_url":"https://api.github.com/users/JacquesOlivierLachaud/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JacquesOlivierLachaud/subscriptions","organizations_url":"https://api.github.com/users/JacquesOlivierLachaud/orgs","repos_url":"https://api.github.com/users/JacquesOlivierLachaud/repos","events_url":"https://api.github.com/users/JacquesOlivierLachaud/events{/privacy}","received_events_url":"https://api.github.com/users/JacquesOlivierLachaud/received_events","type":"User","site_admin":false},"body":"Why passing Point by value ? It could be costly for spaces of large dimension.","created_at":"2016-01-06T10:18:41Z","updated_at":"2016-01-06T10:18:41Z","html_url":"https://github.com/DGtal-team/DGtal/pull/1086#discussion_r48943462","pull_request_url":"https://api.github.com/repos/DGtal-team/DGtal/pulls/1086","_links":{"self":{"href":"https://api.github.com/repos/DGtal-team/DGtal/pulls/comments/48943462"},"html":{"href":"https://github.com/DGtal-team/DGtal/pull/1086#discussion_r48943462"},"pull_request":{"href":"https://api.github.com/repos/DGtal-team/DGtal/pulls/1086"}}},"pull_request":{"url":"https://api.github.com/repos/DGtal-team/DGtal/pulls/1086","id":53241280,"html_url":"https://github.com/DGtal-team/DGtal/pull/1086","diff_url":"https://github.com/DGtal-team/DGtal/pull/1086.diff","patch_url":"https://github.com/DGtal-team/DGtal/pull/1086.patch","issue_url":"https://api.github.com/repos/DGtal-team/DGtal/issues/1086","number":1086,"state":"open","locked":false,"title":"Periodic Khalimsky space and per-dimension closure type.","user":{"login":"rolanddenis","id":10435058,"avatar_url":"https://avatars.githubusercontent.com/u/10435058?v=3","gravatar_id":"","url":"https://api.github.com/users/rolanddenis","html_url":"https://github.com/rolanddenis","followers_url":"https://api.github.com/users/rolanddenis/followers","following_url":"https://api.github.com/users/rolanddenis/following{/other_user}","gists_url":"https://api.github.com/users/rolanddenis/gists{/gist_id}","starred_url":"https://api.github.com/users/rolanddenis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rolanddenis/subscriptions","organizations_url":"https://api.github.com/users/rolanddenis/orgs","repos_url":"https://api.github.com/users/rolanddenis/repos","events_url":"https://api.github.com/users/rolanddenis/events{/privacy}","received_events_url":"https://api.github.com/users/rolanddenis/received_events","type":"User","site_admin":false},"body":"This PR adds the possibility to specify a different closure type for each dimension, and to define periodic dimensions. In addition, some bugs in `KhalimskySpaceND` have been fixed.\r\n\r\nAlong a periodic dimension, it is always possible to translate a cell without going out of space (`(u|s)IsInside` returns always true and `IsMin` & `IsMax` return always false). The Khalimsky coordinates returned by `(u|s)KCoords` are always between `2*myLower[k]` (like a closed dimension) and `2*myUpper[k]+1` (like an open dimension) where `myLower` and `myUpper` are the digital bounds given in the `init` method. `(u|s)GetMin`, `(u|s)GetMax`, `(u|s)First` and `(u|s)Last` return cells based on the reference domain bounds (like `(u|s)KCoords`).\r\n\r\nThus, storage classes based on a periodic Khalimsky space will only see cells in the reference domain (unless for cells whose coordinates were modified by hand, without using `KhalimskySpaceND` methods). In particular, the cubical complex PR #1079 is compatible with periodic Khalimsky space, at least for the collapsing function.\r\n\r\nThe previous interface is kept unchanged (in particular the `init` method with only a bool to specify closed space) and thus, current code using `KhalimskySpaceND` should work like before.\r\n\r\nWhen using different closure type per dimension, or for periodic spaces, the method `isSpaceClosed` returns true if every dimension is closed (non-periodic) or periodic. Thus, if `isSpaceClosed` returns false, it doesn't mean that the space is open. \r\n\r\nThe todo list:\r\n- [ ] Documenting `KhalimskySpaceND`, especially the behaviour of each method with periodic dimension.\r\n- [ ] Updating user guide to `KhalimskySpaceND`.\r\n- [ ] Modifying `CCellularGridSpaceND` ?\r\n- [ ] Adding a template parameter to optimize the code when periodicity is not needed (the current performance impact must be tested).\r\n- [ ] Less coordinates verification for periodic dimension in some methods ?\r\n- [ ] Test file.\r\n- [ ] Checking compatibility of DGtal with periodic Khalimsky spaces (syntax checking):\r\n  * [x] `SurfelNeighborhood` (comparison with `KhalimskySpaceND::min` & `KhalimskySpaceND::max`),\r\n  * [x] `SurfelAdjacency`,\r\n  * [x] `ExplicitDigitalSurface`,\r\n  * [ ] `Surfaces`:\r\n     * [ ] `extractAllPointContours4C` (direct coordinates manipulation),\r\n     * [ ] `sWriteBoundary` (direct coordinates manipulation),\r\n     * [x] `uFillInterior` (comparison with `uGetMax`),\r\n     * [x] others.\r\n\r\n\r\n","created_at":"2015-12-10T10:40:46Z","updated_at":"2016-01-06T10:18:41Z","closed_at":null,"merged_at":null,"merge_commit_sha":"b39d3008c77742555f5f4c5b421de9bb56ea8e7c","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/DGtal-team/DGtal/pulls/1086/commits","review_comments_url":"https://api.github.com/repos/DGtal-team/DGtal/pulls/1086/comments","review_comment_url":"https://api.github.com/repos/DGtal-team/DGtal/pulls/comments{/number}","comments_url":"https://api.github.com/repos/DGtal-team/DGtal/issues/1086/comments","statuses_url":"https://api.github.com/repos/DGtal-team/DGtal/statuses/e2381b590e5b2e28f1309fe36587e25ab03633b1","head":{"label":"rolanddenis:dev_periodicKhalimsky","ref":"dev_periodicKhalimsky","sha":"e2381b590e5b2e28f1309fe36587e25ab03633b1","user":{"login":"rolanddenis","id":10435058,"avatar_url":"https://avatars.githubusercontent.com/u/10435058?v=3","gravatar_id":"","url":"https://api.github.com/users/rolanddenis","html_url":"https://github.com/rolanddenis","followers_url":"https://api.github.com/users/rolanddenis/followers","following_url":"https://api.github.com/users/rolanddenis/following{/other_user}","gists_url":"https://api.github.com/users/rolanddenis/gists{/gist_id}","starred_url":"https://api.github.com/users/rolanddenis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rolanddenis/subscriptions","organizations_url":"https://api.github.com/users/rolanddenis/orgs","repos_url":"https://api.github.com/users/rolanddenis/repos","events_url":"https://api.github.com/users/rolanddenis/events{/privacy}","received_events_url":"https://api.github.com/users/rolanddenis/received_events","type":"User","site_admin":false},"repo":{"id":30013981,"name":"DGtal","full_name":"rolanddenis/DGtal","owner":{"login":"rolanddenis","id":10435058,"avatar_url":"https://avatars.githubusercontent.com/u/10435058?v=3","gravatar_id":"","url":"https://api.github.com/users/rolanddenis","html_url":"https://github.com/rolanddenis","followers_url":"https://api.github.com/users/rolanddenis/followers","following_url":"https://api.github.com/users/rolanddenis/following{/other_user}","gists_url":"https://api.github.com/users/rolanddenis/gists{/gist_id}","starred_url":"https://api.github.com/users/rolanddenis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rolanddenis/subscriptions","organizations_url":"https://api.github.com/users/rolanddenis/orgs","repos_url":"https://api.github.com/users/rolanddenis/repos","events_url":"https://api.github.com/users/rolanddenis/events{/privacy}","received_events_url":"https://api.github.com/users/rolanddenis/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/rolanddenis/DGtal","description":"Digital Geometry Tools and Algorithm Library","fork":true,"url":"https://api.github.com/repos/rolanddenis/DGtal","forks_url":"https://api.github.com/repos/rolanddenis/DGtal/forks","keys_url":"https://api.github.com/repos/rolanddenis/DGtal/keys{/key_id}","collaborators_url":"https://api.github.com/repos/rolanddenis/DGtal/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/rolanddenis/DGtal/teams","hooks_url":"https://api.github.com/repos/rolanddenis/DGtal/hooks","issue_events_url":"https://api.github.com/repos/rolanddenis/DGtal/issues/events{/number}","events_url":"https://api.github.com/repos/rolanddenis/DGtal/events","assignees_url":"https://api.github.com/repos/rolanddenis/DGtal/assignees{/user}","branches_url":"https://api.github.com/repos/rolanddenis/DGtal/branches{/branch}","tags_url":"https://api.github.com/repos/rolanddenis/DGtal/tags","blobs_url":"https://api.github.com/repos/rolanddenis/DGtal/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/rolanddenis/DGtal/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/rolanddenis/DGtal/git/refs{/sha}","trees_url":"https://api.github.com/repos/rolanddenis/DGtal/git/trees{/sha}","statuses_url":"https://api.github.com/repos/rolanddenis/DGtal/statuses/{sha}","languages_url":"https://api.github.com/repos/rolanddenis/DGtal/languages","stargazers_url":"https://api.github.com/repos/rolanddenis/DGtal/stargazers","contributors_url":"https://api.github.com/repos/rolanddenis/DGtal/contributors","subscribers_url":"https://api.github.com/repos/rolanddenis/DGtal/subscribers","subscription_url":"https://api.github.com/repos/rolanddenis/DGtal/subscription","commits_url":"https://api.github.com/repos/rolanddenis/DGtal/commits{/sha}","git_commits_url":"https://api.github.com/repos/rolanddenis/DGtal/git/commits{/sha}","comments_url":"https://api.github.com/repos/rolanddenis/DGtal/comments{/number}","issue_comment_url":"https://api.github.com/repos/rolanddenis/DGtal/issues/comments{/number}","contents_url":"https://api.github.com/repos/rolanddenis/DGtal/contents/{+path}","compare_url":"https://api.github.com/repos/rolanddenis/DGtal/compare/{base}...{head}","merges_url":"https://api.github.com/repos/rolanddenis/DGtal/merges","archive_url":"https://api.github.com/repos/rolanddenis/DGtal/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/rolanddenis/DGtal/downloads","issues_url":"https://api.github.com/repos/rolanddenis/DGtal/issues{/number}","pulls_url":"https://api.github.com/repos/rolanddenis/DGtal/pulls{/number}","milestones_url":"https://api.github.com/repos/rolanddenis/DGtal/milestones{/number}","notifications_url":"https://api.github.com/repos/rolanddenis/DGtal/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/rolanddenis/DGtal/labels{/name}","releases_url":"https://api.github.com/repos/rolanddenis/DGtal/releases{/id}","created_at":"2015-01-29T09:51:01Z","updated_at":"2015-05-04T15:16:25Z","pushed_at":"2016-01-06T09:51:06Z","git_url":"git://github.com/rolanddenis/DGtal.git","ssh_url":"git@github.com:rolanddenis/DGtal.git","clone_url":"https://github.com/rolanddenis/DGtal.git","svn_url":"https://github.com/rolanddenis/DGtal","homepage":"http://dgtal.org","size":144179,"stargazers_count":0,"watchers_count":0,"language":"C++","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":"DGtal-team:master","ref":"master","sha":"355536b4e73ea9db0b73ba181347956ee5bcada8","user":{"login":"DGtal-team","id":1013900,"avatar_url":"https://avatars.githubusercontent.com/u/1013900?v=3","gravatar_id":"","url":"https://api.github.com/users/DGtal-team","html_url":"https://github.com/DGtal-team","followers_url":"https://api.github.com/users/DGtal-team/followers","following_url":"https://api.github.com/users/DGtal-team/following{/other_user}","gists_url":"https://api.github.com/users/DGtal-team/gists{/gist_id}","starred_url":"https://api.github.com/users/DGtal-team/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/DGtal-team/subscriptions","organizations_url":"https://api.github.com/users/DGtal-team/orgs","repos_url":"https://api.github.com/users/DGtal-team/repos","events_url":"https://api.github.com/users/DGtal-team/events{/privacy}","received_events_url":"https://api.github.com/users/DGtal-team/received_events","type":"Organization","site_admin":false},"repo":{"id":1709095,"name":"DGtal","full_name":"DGtal-team/DGtal","owner":{"login":"DGtal-team","id":1013900,"avatar_url":"https://avatars.githubusercontent.com/u/1013900?v=3","gravatar_id":"","url":"https://api.github.com/users/DGtal-team","html_url":"https://github.com/DGtal-team","followers_url":"https://api.github.com/users/DGtal-team/followers","following_url":"https://api.github.com/users/DGtal-team/following{/other_user}","gists_url":"https://api.github.com/users/DGtal-team/gists{/gist_id}","starred_url":"https://api.github.com/users/DGtal-team/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/DGtal-team/subscriptions","organizations_url":"https://api.github.com/users/DGtal-team/orgs","repos_url":"https://api.github.com/users/DGtal-team/repos","events_url":"https://api.github.com/users/DGtal-team/events{/privacy}","received_events_url":"https://api.github.com/users/DGtal-team/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/DGtal-team/DGtal","description":"Digital Geometry Tools and Algorithm Library","fork":false,"url":"https://api.github.com/repos/DGtal-team/DGtal","forks_url":"https://api.github.com/repos/DGtal-team/DGtal/forks","keys_url":"https://api.github.com/repos/DGtal-team/DGtal/keys{/key_id}","collaborators_url":"https://api.github.com/repos/DGtal-team/DGtal/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/DGtal-team/DGtal/teams","hooks_url":"https://api.github.com/repos/DGtal-team/DGtal/hooks","issue_events_url":"https://api.github.com/repos/DGtal-team/DGtal/issues/events{/number}","events_url":"https://api.github.com/repos/DGtal-team/DGtal/events","assignees_url":"https://api.github.com/repos/DGtal-team/DGtal/assignees{/user}","branches_url":"https://api.github.com/repos/DGtal-team/DGtal/branches{/branch}","tags_url":"https://api.github.com/repos/DGtal-team/DGtal/tags","blobs_url":"https://api.github.com/repos/DGtal-team/DGtal/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/DGtal-team/DGtal/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/DGtal-team/DGtal/git/refs{/sha}","trees_url":"https://api.github.com/repos/DGtal-team/DGtal/git/trees{/sha}","statuses_url":"https://api.github.com/repos/DGtal-team/DGtal/statuses/{sha}","languages_url":"https://api.github.com/repos/DGtal-team/DGtal/languages","stargazers_url":"https://api.github.com/repos/DGtal-team/DGtal/stargazers","contributors_url":"https://api.github.com/repos/DGtal-team/DGtal/contributors","subscribers_url":"https://api.github.com/repos/DGtal-team/DGtal/subscribers","subscription_url":"https://api.github.com/repos/DGtal-team/DGtal/subscription","commits_url":"https://api.github.com/repos/DGtal-team/DGtal/commits{/sha}","git_commits_url":"https://api.github.com/repos/DGtal-team/DGtal/git/commits{/sha}","comments_url":"https://api.github.com/repos/DGtal-team/DGtal/comments{/number}","issue_comment_url":"https://api.github.com/repos/DGtal-team/DGtal/issues/comments{/number}","contents_url":"https://api.github.com/repos/DGtal-team/DGtal/contents/{+path}","compare_url":"https://api.github.com/repos/DGtal-team/DGtal/compare/{base}...{head}","merges_url":"https://api.github.com/repos/DGtal-team/DGtal/merges","archive_url":"https://api.github.com/repos/DGtal-team/DGtal/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/DGtal-team/DGtal/downloads","issues_url":"https://api.github.com/repos/DGtal-team/DGtal/issues{/number}","pulls_url":"https://api.github.com/repos/DGtal-team/DGtal/pulls{/number}","milestones_url":"https://api.github.com/repos/DGtal-team/DGtal/milestones{/number}","notifications_url":"https://api.github.com/repos/DGtal-team/DGtal/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/DGtal-team/DGtal/labels{/name}","releases_url":"https://api.github.com/repos/DGtal-team/DGtal/releases{/id}","created_at":"2011-05-06T00:20:52Z","updated_at":"2016-01-02T06:04:59Z","pushed_at":"2016-01-06T09:51:07Z","git_url":"git://github.com/DGtal-team/DGtal.git","ssh_url":"git@github.com:DGtal-team/DGtal.git","clone_url":"https://github.com/DGtal-team/DGtal.git","svn_url":"https://github.com/DGtal-team/DGtal","homepage":"http://dgtal.org","size":197002,"stargazers_count":34,"watchers_count":34,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":44,"mirror_url":null,"open_issues_count":44,"forks":44,"open_issues":44,"watchers":34,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/DGtal-team/DGtal/pulls/1086"},"html":{"href":"https://github.com/DGtal-team/DGtal/pull/1086"},"issue":{"href":"https://api.github.com/repos/DGtal-team/DGtal/issues/1086"},"comments":{"href":"https://api.github.com/repos/DGtal-team/DGtal/issues/1086/comments"},"review_comments":{"href":"https://api.github.com/repos/DGtal-team/DGtal/pulls/1086/comments"},"review_comment":{"href":"https://api.github.com/repos/DGtal-team/DGtal/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/DGtal-team/DGtal/pulls/1086/commits"},"statuses":{"href":"https://api.github.com/repos/DGtal-team/DGtal/statuses/e2381b590e5b2e28f1309fe36587e25ab03633b1"}}}}