{"action":"created","comment":{"url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls/comments/79158531","id":79158531,"diff_hunk":"@@ -0,0 +1,23 @@\n+\t/**\n+\t * Isolates overlapping objects from the background and each other.\n+\t * @param input The image used to create the watershed.\n+\t * @param contours The contours used to create the watershed.\n+\t * @param output The image where the output is stored.\n+\t */\n+\tprivate void $tMeth.name($step.name())(Mat input,List<MatOfPoint> contours, Mat output) {\n+\t\tfinal Mat markers = new Mat(input.size(), CvType.CV_32SC1, new Scalar(0.0));\n+\t\tMat temp = new Mat(input.size(), CvType.CV_8UC3, new Scalar(0.0,0.0,0.0));\n+\t\ttemp.convertTo(input,CvType.CV_8UC3);\n+\t\ttry {\n+\t\t\tfor (int i = 0; i < contours.size(); i++) {\n+\t\t\t\tImgproc.drawContours(markers, contours, i, Scalar.all((i + 1) * (255\n+\t\t\t\t\t/contours.size())),-1);\n+\t\t\t\t}\n+\t\t\tImgproc.circle(markers, new Point(5, 5), 3, Scalar.all(255), -1, Core.LINE_8, 0);\n+\t\t\tImgproc.watershed(input, markers);\n+\t\t\tmarkers.convertTo(output, CvType.CV_8UC1);\n+\t\t\tCore.bitwise_not(output, output);\n+\t\t} finally {\n+\t\t\tmarkers.release();\n+\t\t}","path":"ui/src/main/resources/edu/wpi/grip/ui/codegeneration/java/operations/Watershed.vm","position":22,"original_position":22,"commit_id":"8b17b7faad144e1299a89fe11f7db2cd6d0c6771","original_commit_id":"1c8e61a76f3fda3a610d1f4af2db0dde44a29242","user":{"login":"SamCarlberg","id":6320992,"avatar_url":"https://avatars.githubusercontent.com/u/6320992?v=3","gravatar_id":"","url":"https://api.github.com/users/SamCarlberg","html_url":"https://github.com/SamCarlberg","followers_url":"https://api.github.com/users/SamCarlberg/followers","following_url":"https://api.github.com/users/SamCarlberg/following{/other_user}","gists_url":"https://api.github.com/users/SamCarlberg/gists{/gist_id}","starred_url":"https://api.github.com/users/SamCarlberg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SamCarlberg/subscriptions","organizations_url":"https://api.github.com/users/SamCarlberg/orgs","repos_url":"https://api.github.com/users/SamCarlberg/repos","events_url":"https://api.github.com/users/SamCarlberg/events{/privacy}","received_events_url":"https://api.github.com/users/SamCarlberg/received_events","type":"User","site_admin":false},"body":"No, `Mat` doesn't implement `Closeable`","created_at":"2016-09-16T12:26:30Z","updated_at":"2016-09-16T12:26:30Z","html_url":"https://github.com/WPIRoboticsProjects/GRIP/pull/597#discussion_r79158531","pull_request_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls/597","_links":{"self":{"href":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls/comments/79158531"},"html":{"href":"https://github.com/WPIRoboticsProjects/GRIP/pull/597#discussion_r79158531"},"pull_request":{"href":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls/597"}}},"pull_request":{"url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls/597","id":72393890,"html_url":"https://github.com/WPIRoboticsProjects/GRIP/pull/597","diff_url":"https://github.com/WPIRoboticsProjects/GRIP/pull/597.diff","patch_url":"https://github.com/WPIRoboticsProjects/GRIP/pull/597.patch","issue_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/issues/597","number":597,"state":"open","locked":false,"title":"Code Generation","user":{"login":"PatrickPenguinTurtle","id":16124010,"avatar_url":"https://avatars.githubusercontent.com/u/16124010?v=3","gravatar_id":"","url":"https://api.github.com/users/PatrickPenguinTurtle","html_url":"https://github.com/PatrickPenguinTurtle","followers_url":"https://api.github.com/users/PatrickPenguinTurtle/followers","following_url":"https://api.github.com/users/PatrickPenguinTurtle/following{/other_user}","gists_url":"https://api.github.com/users/PatrickPenguinTurtle/gists{/gist_id}","starred_url":"https://api.github.com/users/PatrickPenguinTurtle/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/PatrickPenguinTurtle/subscriptions","organizations_url":"https://api.github.com/users/PatrickPenguinTurtle/orgs","repos_url":"https://api.github.com/users/PatrickPenguinTurtle/repos","events_url":"https://api.github.com/users/PatrickPenguinTurtle/events{/privacy}","received_events_url":"https://api.github.com/users/PatrickPenguinTurtle/received_events","type":"User","site_admin":false},"body":"@osulacam and myself are working on an extension to GRIP that generates code. Eventually it will generate code for the users choice of Java, C++ and Python. For now it only generates Java code. \r\n\r\nThe idea behind this is so that users do not have to run a jvm containing GRIP to get pipelines to run. Instead they would include this file in their code and call the processImage function to run the pipeline once. \r\n\r\nAs mentioned this is in progress and at this time is not finished enough to be merged into GRIP. \r\n\r\n\r\n\r\nThings to do:\r\n- [ ] Testing @PatrickPenguinTurtle \r\n- [x] Better warning for unsupported ops @osulacam \r\n- [ ] Try with resources blocks @osulacam \r\n- [ ] Pull socket hint descriptions into comments","created_at":"2016-06-02T18:23:46Z","updated_at":"2016-09-16T12:26:30Z","closed_at":null,"merged_at":null,"merge_commit_sha":"0b5d92428416eb163bc15437f98814bf1a9060d2","assignee":null,"assignees":[],"milestone":{"url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/milestones/10","html_url":"https://github.com/WPIRoboticsProjects/GRIP/milestones/1.6.0","labels_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/milestones/10/labels","id":1967347,"number":10,"title":"1.6.0","description":"Code Generation","creator":{"login":"AustinShalit","id":3799260,"avatar_url":"https://avatars.githubusercontent.com/u/3799260?v=3","gravatar_id":"","url":"https://api.github.com/users/AustinShalit","html_url":"https://github.com/AustinShalit","followers_url":"https://api.github.com/users/AustinShalit/followers","following_url":"https://api.github.com/users/AustinShalit/following{/other_user}","gists_url":"https://api.github.com/users/AustinShalit/gists{/gist_id}","starred_url":"https://api.github.com/users/AustinShalit/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AustinShalit/subscriptions","organizations_url":"https://api.github.com/users/AustinShalit/orgs","repos_url":"https://api.github.com/users/AustinShalit/repos","events_url":"https://api.github.com/users/AustinShalit/events{/privacy}","received_events_url":"https://api.github.com/users/AustinShalit/received_events","type":"User","site_admin":false},"open_issues":7,"closed_issues":0,"state":"open","created_at":"2016-08-27T17:34:13Z","updated_at":"2016-08-27T17:34:56Z","due_on":"2016-09-04T00:00:00Z","closed_at":null},"commits_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls/597/commits","review_comments_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls/597/comments","review_comment_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls/comments{/number}","comments_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/issues/597/comments","statuses_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/statuses/8b17b7faad144e1299a89fe11f7db2cd6d0c6771","head":{"label":"osulacam:DataModel","ref":"DataModel","sha":"8b17b7faad144e1299a89fe11f7db2cd6d0c6771","user":{"login":"osulacam","id":7980882,"avatar_url":"https://avatars.githubusercontent.com/u/7980882?v=3","gravatar_id":"","url":"https://api.github.com/users/osulacam","html_url":"https://github.com/osulacam","followers_url":"https://api.github.com/users/osulacam/followers","following_url":"https://api.github.com/users/osulacam/following{/other_user}","gists_url":"https://api.github.com/users/osulacam/gists{/gist_id}","starred_url":"https://api.github.com/users/osulacam/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/osulacam/subscriptions","organizations_url":"https://api.github.com/users/osulacam/orgs","repos_url":"https://api.github.com/users/osulacam/repos","events_url":"https://api.github.com/users/osulacam/events{/privacy}","received_events_url":"https://api.github.com/users/osulacam/received_events","type":"User","site_admin":false},"repo":{"id":58765533,"name":"GRIP","full_name":"osulacam/GRIP","owner":{"login":"osulacam","id":7980882,"avatar_url":"https://avatars.githubusercontent.com/u/7980882?v=3","gravatar_id":"","url":"https://api.github.com/users/osulacam","html_url":"https://github.com/osulacam","followers_url":"https://api.github.com/users/osulacam/followers","following_url":"https://api.github.com/users/osulacam/following{/other_user}","gists_url":"https://api.github.com/users/osulacam/gists{/gist_id}","starred_url":"https://api.github.com/users/osulacam/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/osulacam/subscriptions","organizations_url":"https://api.github.com/users/osulacam/orgs","repos_url":"https://api.github.com/users/osulacam/repos","events_url":"https://api.github.com/users/osulacam/events{/privacy}","received_events_url":"https://api.github.com/users/osulacam/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/osulacam/GRIP","description":"Program for rapidly developing computer vision applications","fork":true,"url":"https://api.github.com/repos/osulacam/GRIP","forks_url":"https://api.github.com/repos/osulacam/GRIP/forks","keys_url":"https://api.github.com/repos/osulacam/GRIP/keys{/key_id}","collaborators_url":"https://api.github.com/repos/osulacam/GRIP/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/osulacam/GRIP/teams","hooks_url":"https://api.github.com/repos/osulacam/GRIP/hooks","issue_events_url":"https://api.github.com/repos/osulacam/GRIP/issues/events{/number}","events_url":"https://api.github.com/repos/osulacam/GRIP/events","assignees_url":"https://api.github.com/repos/osulacam/GRIP/assignees{/user}","branches_url":"https://api.github.com/repos/osulacam/GRIP/branches{/branch}","tags_url":"https://api.github.com/repos/osulacam/GRIP/tags","blobs_url":"https://api.github.com/repos/osulacam/GRIP/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/osulacam/GRIP/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/osulacam/GRIP/git/refs{/sha}","trees_url":"https://api.github.com/repos/osulacam/GRIP/git/trees{/sha}","statuses_url":"https://api.github.com/repos/osulacam/GRIP/statuses/{sha}","languages_url":"https://api.github.com/repos/osulacam/GRIP/languages","stargazers_url":"https://api.github.com/repos/osulacam/GRIP/stargazers","contributors_url":"https://api.github.com/repos/osulacam/GRIP/contributors","subscribers_url":"https://api.github.com/repos/osulacam/GRIP/subscribers","subscription_url":"https://api.github.com/repos/osulacam/GRIP/subscription","commits_url":"https://api.github.com/repos/osulacam/GRIP/commits{/sha}","git_commits_url":"https://api.github.com/repos/osulacam/GRIP/git/commits{/sha}","comments_url":"https://api.github.com/repos/osulacam/GRIP/comments{/number}","issue_comment_url":"https://api.github.com/repos/osulacam/GRIP/issues/comments{/number}","contents_url":"https://api.github.com/repos/osulacam/GRIP/contents/{+path}","compare_url":"https://api.github.com/repos/osulacam/GRIP/compare/{base}...{head}","merges_url":"https://api.github.com/repos/osulacam/GRIP/merges","archive_url":"https://api.github.com/repos/osulacam/GRIP/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/osulacam/GRIP/downloads","issues_url":"https://api.github.com/repos/osulacam/GRIP/issues{/number}","pulls_url":"https://api.github.com/repos/osulacam/GRIP/pulls{/number}","milestones_url":"https://api.github.com/repos/osulacam/GRIP/milestones{/number}","notifications_url":"https://api.github.com/repos/osulacam/GRIP/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/osulacam/GRIP/labels{/name}","releases_url":"https://api.github.com/repos/osulacam/GRIP/releases{/id}","deployments_url":"https://api.github.com/repos/osulacam/GRIP/deployments","created_at":"2016-05-13T19:02:08Z","updated_at":"2016-05-13T19:02:10Z","pushed_at":"2016-09-14T16:53:21Z","git_url":"git://github.com/osulacam/GRIP.git","ssh_url":"git@github.com:osulacam/GRIP.git","clone_url":"https://github.com/osulacam/GRIP.git","svn_url":"https://github.com/osulacam/GRIP","homepage":"http://wpiroboticsprojects.github.io/GRIP","size":45845,"stargazers_count":0,"watchers_count":0,"language":"Java","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":"WPIRoboticsProjects:master","ref":"master","sha":"a7008925966fc8c296875a215b7dfdd14b805309","user":{"login":"WPIRoboticsProjects","id":14004340,"avatar_url":"https://avatars.githubusercontent.com/u/14004340?v=3","gravatar_id":"","url":"https://api.github.com/users/WPIRoboticsProjects","html_url":"https://github.com/WPIRoboticsProjects","followers_url":"https://api.github.com/users/WPIRoboticsProjects/followers","following_url":"https://api.github.com/users/WPIRoboticsProjects/following{/other_user}","gists_url":"https://api.github.com/users/WPIRoboticsProjects/gists{/gist_id}","starred_url":"https://api.github.com/users/WPIRoboticsProjects/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WPIRoboticsProjects/subscriptions","organizations_url":"https://api.github.com/users/WPIRoboticsProjects/orgs","repos_url":"https://api.github.com/users/WPIRoboticsProjects/repos","events_url":"https://api.github.com/users/WPIRoboticsProjects/events{/privacy}","received_events_url":"https://api.github.com/users/WPIRoboticsProjects/received_events","type":"Organization","site_admin":false},"repo":{"id":41505521,"name":"GRIP","full_name":"WPIRoboticsProjects/GRIP","owner":{"login":"WPIRoboticsProjects","id":14004340,"avatar_url":"https://avatars.githubusercontent.com/u/14004340?v=3","gravatar_id":"","url":"https://api.github.com/users/WPIRoboticsProjects","html_url":"https://github.com/WPIRoboticsProjects","followers_url":"https://api.github.com/users/WPIRoboticsProjects/followers","following_url":"https://api.github.com/users/WPIRoboticsProjects/following{/other_user}","gists_url":"https://api.github.com/users/WPIRoboticsProjects/gists{/gist_id}","starred_url":"https://api.github.com/users/WPIRoboticsProjects/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WPIRoboticsProjects/subscriptions","organizations_url":"https://api.github.com/users/WPIRoboticsProjects/orgs","repos_url":"https://api.github.com/users/WPIRoboticsProjects/repos","events_url":"https://api.github.com/users/WPIRoboticsProjects/events{/privacy}","received_events_url":"https://api.github.com/users/WPIRoboticsProjects/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/WPIRoboticsProjects/GRIP","description":"Program for rapidly developing computer vision applications","fork":false,"url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP","forks_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/forks","keys_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/keys{/key_id}","collaborators_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/teams","hooks_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/hooks","issue_events_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/issues/events{/number}","events_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/events","assignees_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/assignees{/user}","branches_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/branches{/branch}","tags_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/tags","blobs_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/git/refs{/sha}","trees_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/git/trees{/sha}","statuses_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/statuses/{sha}","languages_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/languages","stargazers_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/stargazers","contributors_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/contributors","subscribers_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/subscribers","subscription_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/subscription","commits_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/commits{/sha}","git_commits_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/git/commits{/sha}","comments_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/comments{/number}","issue_comment_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/issues/comments{/number}","contents_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/contents/{+path}","compare_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/compare/{base}...{head}","merges_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/merges","archive_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/downloads","issues_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/issues{/number}","pulls_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls{/number}","milestones_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/milestones{/number}","notifications_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/labels{/name}","releases_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/releases{/id}","deployments_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/deployments","created_at":"2015-08-27T18:59:07Z","updated_at":"2016-09-10T18:10:22Z","pushed_at":"2016-09-15T01:26:50Z","git_url":"git://github.com/WPIRoboticsProjects/GRIP.git","ssh_url":"git@github.com:WPIRoboticsProjects/GRIP.git","clone_url":"https://github.com/WPIRoboticsProjects/GRIP.git","svn_url":"https://github.com/WPIRoboticsProjects/GRIP","homepage":"http://wpiroboticsprojects.github.io/GRIP","size":58045,"stargazers_count":113,"watchers_count":113,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":51,"mirror_url":null,"open_issues_count":89,"forks":51,"open_issues":89,"watchers":113,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls/597"},"html":{"href":"https://github.com/WPIRoboticsProjects/GRIP/pull/597"},"issue":{"href":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/issues/597"},"comments":{"href":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/issues/597/comments"},"review_comments":{"href":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls/597/comments"},"review_comment":{"href":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls/597/commits"},"statuses":{"href":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/statuses/8b17b7faad144e1299a89fe11f7db2cd6d0c6771"}}}}
{"actor":{"display_login":"SamCarlberg"}}