GitHub PullRequestReviewCommentEvent at 2014-12-21 07:29:44
Repository: Press-Start-Button
Actor: ryaninhust
Payload: {"action":"created","comment":{"url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/pulls/comments/22146207","id":22146207,"diff_hunk":"@@ -0,0 +1,78 @@\n+#!/usr/bin/env python\n+#encoding: utf-8\n+\n+import numpy as np\n+from PIL import Image\n+\n+\n+def create_data(file):\n+    data_list = []\n+    with open(file,'r') as f:\n+        while True:\n+            line = f.readline()\n+            if not line:\n+                break\n+            line = line.rstrip('\\n').split(' ')\n+            feature_dict = {}\n+            for l in line[1:]:\n+                ls = l.split(':')\n+                feature_dict[ls[0]] = ls[1]\n+            data_list.append([line[0],feature_dict])\n+    return data_list\n+\n+def create_test_data(file):\n+    data_list = []\n+    i = 1\n+    with open(file,'r') as f:\n+        while True:\n+            line = f.readline()\n+            if not line:\n+                break\n+            line = line.rstrip('\\n').split(' ')\n+            feature_dict = {}\n+            for l in line[1:]:\n+                ls = l.split(':')\n+                feature_dict[ls[0]] = ls[1]\n+            data_list.append([i,feature_dict])\n+            i += 1\n+    return data_list\n+\n+def find_m_index(n):\n+    \"\"\"find matrix index giving feature index\"\"\"\n+    return (n-1)/105, (n-1)%105","path":"cut_edge.py","position":42,"original_position":42,"commit_id":"aacfdb1a7199942ad3d9775dc4f1584a5d9eba7d","original_commit_id":"aacfdb1a7199942ad3d9775dc4f1584a5d9eba7d","user":{"login":"ryaninhust","id":1479023,"avatar_url":"https://avatars.githubusercontent.com/u/1479023?v=3","gravatar_id":"","url":"https://api.github.com/users/ryaninhust","html_url":"https://github.com/ryaninhust","followers_url":"https://api.github.com/users/ryaninhust/followers","following_url":"https://api.github.com/users/ryaninhust/following{/other_user}","gists_url":"https://api.github.com/users/ryaninhust/gists{/gist_id}","starred_url":"https://api.github.com/users/ryaninhust/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ryaninhust/subscriptions","organizations_url":"https://api.github.com/users/ryaninhust/orgs","repos_url":"https://api.github.com/users/ryaninhust/repos","events_url":"https://api.github.com/users/ryaninhust/events{/privacy}","received_events_url":"https://api.github.com/users/ryaninhust/received_events","type":"User","site_admin":false},"body":"运算符号要 双空格  ","created_at":"2014-12-21T07:29:44Z","updated_at":"2014-12-21T07:29:44Z","html_url":"https://github.com/ryaninhust/Press-Start-Button/pull/1#discussion_r22146207","pull_request_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/pulls/1","_links":{"self":{"href":"https://api.github.com/repos/ryaninhust/Press-Start-Button/pulls/comments/22146207"},"html":{"href":"https://github.com/ryaninhust/Press-Start-Button/pull/1#discussion_r22146207"},"pull_request":{"href":"https://api.github.com/repos/ryaninhust/Press-Start-Button/pulls/1"}}},"pull_request":{"url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/pulls/1","id":26425241,"html_url":"https://github.com/ryaninhust/Press-Start-Button/pull/1","diff_url":"https://github.com/ryaninhust/Press-Start-Button/pull/1.diff","patch_url":"https://github.com/ryaninhust/Press-Start-Button/pull/1.patch","issue_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/issues/1","number":1,"state":"open","locked":false,"title":"Init","user":{"login":"Hyiiego","id":5633821,"avatar_url":"https://avatars.githubusercontent.com/u/5633821?v=3","gravatar_id":"","url":"https://api.github.com/users/Hyiiego","html_url":"https://github.com/Hyiiego","followers_url":"https://api.github.com/users/Hyiiego/followers","following_url":"https://api.github.com/users/Hyiiego/following{/other_user}","gists_url":"https://api.github.com/users/Hyiiego/gists{/gist_id}","starred_url":"https://api.github.com/users/Hyiiego/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Hyiiego/subscriptions","organizations_url":"https://api.github.com/users/Hyiiego/orgs","repos_url":"https://api.github.com/users/Hyiiego/repos","events_url":"https://api.github.com/users/Hyiiego/events{/privacy}","received_events_url":"https://api.github.com/users/Hyiiego/received_events","type":"User","site_admin":false},"body":"","created_at":"2014-12-21T07:27:16Z","updated_at":"2014-12-21T07:29:44Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d1e1fe4fcf469ae39ed68f190873e6e3dcd6d525","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/pulls/1/commits","review_comments_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/pulls/1/comments","review_comment_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/pulls/comments/{number}","comments_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/issues/1/comments","statuses_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/statuses/aacfdb1a7199942ad3d9775dc4f1584a5d9eba7d","head":{"label":"Hyiiego:master","ref":"master","sha":"aacfdb1a7199942ad3d9775dc4f1584a5d9eba7d","user":{"login":"Hyiiego","id":5633821,"avatar_url":"https://avatars.githubusercontent.com/u/5633821?v=3","gravatar_id":"","url":"https://api.github.com/users/Hyiiego","html_url":"https://github.com/Hyiiego","followers_url":"https://api.github.com/users/Hyiiego/followers","following_url":"https://api.github.com/users/Hyiiego/following{/other_user}","gists_url":"https://api.github.com/users/Hyiiego/gists{/gist_id}","starred_url":"https://api.github.com/users/Hyiiego/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Hyiiego/subscriptions","organizations_url":"https://api.github.com/users/Hyiiego/orgs","repos_url":"https://api.github.com/users/Hyiiego/repos","events_url":"https://api.github.com/users/Hyiiego/events{/privacy}","received_events_url":"https://api.github.com/users/Hyiiego/received_events","type":"User","site_admin":false},"repo":{"id":28229593,"name":"Press-Start-Button","full_name":"Hyiiego/Press-Start-Button","owner":{"login":"Hyiiego","id":5633821,"avatar_url":"https://avatars.githubusercontent.com/u/5633821?v=3","gravatar_id":"","url":"https://api.github.com/users/Hyiiego","html_url":"https://github.com/Hyiiego","followers_url":"https://api.github.com/users/Hyiiego/followers","following_url":"https://api.github.com/users/Hyiiego/following{/other_user}","gists_url":"https://api.github.com/users/Hyiiego/gists{/gist_id}","starred_url":"https://api.github.com/users/Hyiiego/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Hyiiego/subscriptions","organizations_url":"https://api.github.com/users/Hyiiego/orgs","repos_url":"https://api.github.com/users/Hyiiego/repos","events_url":"https://api.github.com/users/Hyiiego/events{/privacy}","received_events_url":"https://api.github.com/users/Hyiiego/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Hyiiego/Press-Start-Button","description":"ML 14f final project","fork":true,"url":"https://api.github.com/repos/Hyiiego/Press-Start-Button","forks_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/forks","keys_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/teams","hooks_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/hooks","issue_events_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/issues/events{/number}","events_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/events","assignees_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/assignees{/user}","branches_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/branches{/branch}","tags_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/tags","blobs_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/git/refs{/sha}","trees_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/statuses/{sha}","languages_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/languages","stargazers_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/stargazers","contributors_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/contributors","subscribers_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/subscribers","subscription_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/subscription","commits_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/commits{/sha}","git_commits_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/git/commits{/sha}","comments_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/comments{/number}","issue_comment_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/issues/comments/{number}","contents_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/contents/{+path}","compare_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/merges","archive_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/downloads","issues_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/issues{/number}","pulls_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/pulls{/number}","milestones_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/milestones{/number}","notifications_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/labels{/name}","releases_url":"https://api.github.com/repos/Hyiiego/Press-Start-Button/releases{/id}","created_at":"2014-12-19T13:02:20Z","updated_at":"2014-12-21T07:25:01Z","pushed_at":"2014-12-21T07:24:59Z","git_url":"git://github.com/Hyiiego/Press-Start-Button.git","ssh_url":"git@github.com:Hyiiego/Press-Start-Button.git","clone_url":"https://github.com/Hyiiego/Press-Start-Button.git","svn_url":"https://github.com/Hyiiego/Press-Start-Button","homepage":null,"size":0,"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":"ryaninhust:master","ref":"master","sha":"572e5eb232b0c3e57fa9007cd055147a7f9d9b8a","user":{"login":"ryaninhust","id":1479023,"avatar_url":"https://avatars.githubusercontent.com/u/1479023?v=3","gravatar_id":"","url":"https://api.github.com/users/ryaninhust","html_url":"https://github.com/ryaninhust","followers_url":"https://api.github.com/users/ryaninhust/followers","following_url":"https://api.github.com/users/ryaninhust/following{/other_user}","gists_url":"https://api.github.com/users/ryaninhust/gists{/gist_id}","starred_url":"https://api.github.com/users/ryaninhust/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ryaninhust/subscriptions","organizations_url":"https://api.github.com/users/ryaninhust/orgs","repos_url":"https://api.github.com/users/ryaninhust/repos","events_url":"https://api.github.com/users/ryaninhust/events{/privacy}","received_events_url":"https://api.github.com/users/ryaninhust/received_events","type":"User","site_admin":false},"repo":{"id":28227609,"name":"Press-Start-Button","full_name":"ryaninhust/Press-Start-Button","owner":{"login":"ryaninhust","id":1479023,"avatar_url":"https://avatars.githubusercontent.com/u/1479023?v=3","gravatar_id":"","url":"https://api.github.com/users/ryaninhust","html_url":"https://github.com/ryaninhust","followers_url":"https://api.github.com/users/ryaninhust/followers","following_url":"https://api.github.com/users/ryaninhust/following{/other_user}","gists_url":"https://api.github.com/users/ryaninhust/gists{/gist_id}","starred_url":"https://api.github.com/users/ryaninhust/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ryaninhust/subscriptions","organizations_url":"https://api.github.com/users/ryaninhust/orgs","repos_url":"https://api.github.com/users/ryaninhust/repos","events_url":"https://api.github.com/users/ryaninhust/events{/privacy}","received_events_url":"https://api.github.com/users/ryaninhust/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/ryaninhust/Press-Start-Button","description":"ML 14f final project","fork":false,"url":"https://api.github.com/repos/ryaninhust/Press-Start-Button","forks_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/forks","keys_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/teams","hooks_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/hooks","issue_events_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/issues/events{/number}","events_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/events","assignees_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/assignees{/user}","branches_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/branches{/branch}","tags_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/tags","blobs_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/git/refs{/sha}","trees_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/statuses/{sha}","languages_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/languages","stargazers_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/stargazers","contributors_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/contributors","subscribers_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/subscribers","subscription_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/subscription","commits_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/commits{/sha}","git_commits_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/git/commits{/sha}","comments_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/comments{/number}","issue_comment_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/issues/comments/{number}","contents_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/contents/{+path}","compare_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/merges","archive_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/downloads","issues_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/issues{/number}","pulls_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/pulls{/number}","milestones_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/milestones{/number}","notifications_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/labels{/name}","releases_url":"https://api.github.com/repos/ryaninhust/Press-Start-Button/releases{/id}","created_at":"2014-12-19T11:53:21Z","updated_at":"2014-12-19T12:02:27Z","pushed_at":"2014-12-19T12:02:21Z","git_url":"git://github.com/ryaninhust/Press-Start-Button.git","ssh_url":"git@github.com:ryaninhust/Press-Start-Button.git","clone_url":"https://github.com/ryaninhust/Press-Start-Button.git","svn_url":"https://github.com/ryaninhust/Press-Start-Button","homepage":null,"size":0,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":1,"forks":2,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ryaninhust/Press-Start-Button/pulls/1"},"html":{"href":"https://github.com/ryaninhust/Press-Start-Button/pull/1"},"issue":{"href":"https://api.github.com/repos/ryaninhust/Press-Start-Button/issues/1"},"comments":{"href":"https://api.github.com/repos/ryaninhust/Press-Start-Button/issues/1/comments"},"review_comments":{"href":"https://api.github.com/repos/ryaninhust/Press-Start-Button/pulls/1/comments"},"review_comment":{"href":"https://api.github.com/repos/ryaninhust/Press-Start-Button/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/ryaninhust/Press-Start-Button/pulls/1/commits"},"statuses":{"href":"https://api.github.com/repos/ryaninhust/Press-Start-Button/statuses/aacfdb1a7199942ad3d9775dc4f1584a5d9eba7d"}}}}