{"action":"created","comment":{"url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/pulls/comments/243347380","pull_request_review_id":187085721,"id":243347380,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDI0MzM0NzM4MA==","diff_hunk":"@@ -0,0 +1,329 @@\n+# -*- coding: utf-8 -*-\n+\"\"\"\n+Created on Mon Dec  3 16:22:42 2018\n+\n+@author: thinh\n+\"\"\"\n+\n+from datetime import datetime\n+import os\n+import re\n+import uuid\n+\n+import h5py as h5\n+import matplotlib.pyplot as plt\n+import numpy as np\n+\n+import datajoint as dj\n+from pipeline import reference, subject, acquisition #, behavior, ephys, action, stimulation\n+from pipeline.helper_functions import parse_prefix\n+\n+\n+# Merge all schema and generate the overall ERD (then save in \"/images\")\n+#all_erd = dj.ERD(reference) + dj.ERD(subject) + dj.ERD(action) + dj.ERD(acquisition) + dj.ERD(behavior) + dj.ERD(ephys) + dj.ERD(stimulation)\n+#all_erd.save('./images/all_erd.png')\n+\n+# Merge all schema and generate the overall ERD (then save in \"/images\")\n+core_erd = dj.ERD(reference) + dj.ERD(subject) + dj.ERD(acquisition)\n+core_erd.save('./images/core_erd.png')\n+\n+############## Dataset #################\n+path = os.path.join('..','data','whole_cell_nwb2.0')\n+fnames = os.listdir(path)\n+\n+for fname in fnames:\n+    try:\n+        nwb = h5.File(os.path.join(path,fname), 'r')\n+        print(f'File loaded: {fname}')\n+    except:\n+        print('=================================')\n+        print(f'!!! ERROR LOADING FILE: {fname}')   \n+        print('=================================')\n+        continue\n+    \n+    ############################ METADATA ############################\n+    \n+    # ==================== subject ====================\n+    list(nwb['general']['subject'])","path":"scripts/ingest_nwb_wholecell.py","position":47,"original_position":47,"commit_id":"a40ad3d23e5ee80231380df4d44cd268a5b49935","original_commit_id":"a40ad3d23e5ee80231380df4d44cd268a5b49935","user":{"login":"dimitri-yatsenko","id":1096169,"node_id":"MDQ6VXNlcjEwOTYxNjk=","avatar_url":"https://avatars3.githubusercontent.com/u/1096169?v=4","gravatar_id":"","url":"https://api.github.com/users/dimitri-yatsenko","html_url":"https://github.com/dimitri-yatsenko","followers_url":"https://api.github.com/users/dimitri-yatsenko/followers","following_url":"https://api.github.com/users/dimitri-yatsenko/following{/other_user}","gists_url":"https://api.github.com/users/dimitri-yatsenko/gists{/gist_id}","starred_url":"https://api.github.com/users/dimitri-yatsenko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dimitri-yatsenko/subscriptions","organizations_url":"https://api.github.com/users/dimitri-yatsenko/orgs","repos_url":"https://api.github.com/users/dimitri-yatsenko/repos","events_url":"https://api.github.com/users/dimitri-yatsenko/events{/privacy}","received_events_url":"https://api.github.com/users/dimitri-yatsenko/received_events","type":"User","site_admin":false},"body":"remove ","created_at":"2018-12-20T17:02:44Z","updated_at":"2018-12-20T17:12:46Z","html_url":"https://github.com/vathes/Guo-Inagaki-2017/pull/1#discussion_r243347380","pull_request_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/pulls/1","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/pulls/comments/243347380"},"html":{"href":"https://github.com/vathes/Guo-Inagaki-2017/pull/1#discussion_r243347380"},"pull_request":{"href":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/pulls/1"}}},"pull_request":{"url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/pulls/1","id":238823225,"node_id":"MDExOlB1bGxSZXF1ZXN0MjM4ODIzMjI1","html_url":"https://github.com/vathes/Guo-Inagaki-2017/pull/1","diff_url":"https://github.com/vathes/Guo-Inagaki-2017/pull/1.diff","patch_url":"https://github.com/vathes/Guo-Inagaki-2017/pull/1.patch","issue_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/issues/1","number":1,"state":"open","locked":false,"title":"[WIP] Schema design and ingestion of metadata and trial information for whole cell recording ","user":{"login":"ttngu207","id":37779736,"node_id":"MDQ6VXNlcjM3Nzc5NzM2","avatar_url":"https://avatars0.githubusercontent.com/u/37779736?v=4","gravatar_id":"","url":"https://api.github.com/users/ttngu207","html_url":"https://github.com/ttngu207","followers_url":"https://api.github.com/users/ttngu207/followers","following_url":"https://api.github.com/users/ttngu207/following{/other_user}","gists_url":"https://api.github.com/users/ttngu207/gists{/gist_id}","starred_url":"https://api.github.com/users/ttngu207/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ttngu207/subscriptions","organizations_url":"https://api.github.com/users/ttngu207/orgs","repos_url":"https://api.github.com/users/ttngu207/repos","events_url":"https://api.github.com/users/ttngu207/events{/privacy}","received_events_url":"https://api.github.com/users/ttngu207/received_events","type":"User","site_admin":false},"body":"Pipeline should be general enough to incorporate extracellular recording, as well as to used as base template for other paper. ","created_at":"2018-12-14T19:44:05Z","updated_at":"2018-12-20T17:12:45Z","closed_at":null,"merged_at":null,"merge_commit_sha":"0e285a8b5d9fed428e5286489eba05add7c48e76","assignee":null,"assignees":[],"requested_reviewers":[{"login":"shenshan","id":2539832,"node_id":"MDQ6VXNlcjI1Mzk4MzI=","avatar_url":"https://avatars1.githubusercontent.com/u/2539832?v=4","gravatar_id":"","url":"https://api.github.com/users/shenshan","html_url":"https://github.com/shenshan","followers_url":"https://api.github.com/users/shenshan/followers","following_url":"https://api.github.com/users/shenshan/following{/other_user}","gists_url":"https://api.github.com/users/shenshan/gists{/gist_id}","starred_url":"https://api.github.com/users/shenshan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shenshan/subscriptions","organizations_url":"https://api.github.com/users/shenshan/orgs","repos_url":"https://api.github.com/users/shenshan/repos","events_url":"https://api.github.com/users/shenshan/events{/privacy}","received_events_url":"https://api.github.com/users/shenshan/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/pulls/1/commits","review_comments_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/pulls/1/comments","review_comment_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/pulls/comments{/number}","comments_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/issues/1/comments","statuses_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/statuses/a40ad3d23e5ee80231380df4d44cd268a5b49935","head":{"label":"ttngu207:master","ref":"master","sha":"a40ad3d23e5ee80231380df4d44cd268a5b49935","user":{"login":"ttngu207","id":37779736,"node_id":"MDQ6VXNlcjM3Nzc5NzM2","avatar_url":"https://avatars0.githubusercontent.com/u/37779736?v=4","gravatar_id":"","url":"https://api.github.com/users/ttngu207","html_url":"https://github.com/ttngu207","followers_url":"https://api.github.com/users/ttngu207/followers","following_url":"https://api.github.com/users/ttngu207/following{/other_user}","gists_url":"https://api.github.com/users/ttngu207/gists{/gist_id}","starred_url":"https://api.github.com/users/ttngu207/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ttngu207/subscriptions","organizations_url":"https://api.github.com/users/ttngu207/orgs","repos_url":"https://api.github.com/users/ttngu207/repos","events_url":"https://api.github.com/users/ttngu207/events{/privacy}","received_events_url":"https://api.github.com/users/ttngu207/received_events","type":"User","site_admin":false},"repo":{"id":161347593,"node_id":"MDEwOlJlcG9zaXRvcnkxNjEzNDc1OTM=","name":"Guo-Inagaki-2017","full_name":"ttngu207/Guo-Inagaki-2017","private":false,"owner":{"login":"ttngu207","id":37779736,"node_id":"MDQ6VXNlcjM3Nzc5NzM2","avatar_url":"https://avatars0.githubusercontent.com/u/37779736?v=4","gravatar_id":"","url":"https://api.github.com/users/ttngu207","html_url":"https://github.com/ttngu207","followers_url":"https://api.github.com/users/ttngu207/followers","following_url":"https://api.github.com/users/ttngu207/following{/other_user}","gists_url":"https://api.github.com/users/ttngu207/gists{/gist_id}","starred_url":"https://api.github.com/users/ttngu207/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ttngu207/subscriptions","organizations_url":"https://api.github.com/users/ttngu207/orgs","repos_url":"https://api.github.com/users/ttngu207/repos","events_url":"https://api.github.com/users/ttngu207/events{/privacy}","received_events_url":"https://api.github.com/users/ttngu207/received_events","type":"User","site_admin":false},"html_url":"https://github.com/ttngu207/Guo-Inagaki-2017","description":null,"fork":true,"url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017","forks_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/forks","keys_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/teams","hooks_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/hooks","issue_events_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/issues/events{/number}","events_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/events","assignees_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/assignees{/user}","branches_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/branches{/branch}","tags_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/tags","blobs_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/git/refs{/sha}","trees_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/statuses/{sha}","languages_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/languages","stargazers_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/stargazers","contributors_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/contributors","subscribers_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/subscribers","subscription_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/subscription","commits_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/commits{/sha}","git_commits_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/git/commits{/sha}","comments_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/comments{/number}","issue_comment_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/issues/comments{/number}","contents_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/contents/{+path}","compare_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/merges","archive_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/downloads","issues_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/issues{/number}","pulls_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/pulls{/number}","milestones_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/milestones{/number}","notifications_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/labels{/name}","releases_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/releases{/id}","deployments_url":"https://api.github.com/repos/ttngu207/Guo-Inagaki-2017/deployments","created_at":"2018-12-11T14:38:35Z","updated_at":"2018-12-20T16:39:33Z","pushed_at":"2018-12-20T16:39:31Z","git_url":"git://github.com/ttngu207/Guo-Inagaki-2017.git","ssh_url":"git@github.com:ttngu207/Guo-Inagaki-2017.git","clone_url":"https://github.com/ttngu207/Guo-Inagaki-2017.git","svn_url":"https://github.com/ttngu207/Guo-Inagaki-2017","homepage":null,"size":484,"stargazers_count":0,"watchers_count":0,"language":"Python","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":null,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"vathes:master","ref":"master","sha":"467fd5d468471b1e243b022f82ca7cc29a4830fe","user":{"login":"vathes","id":22978966,"node_id":"MDEyOk9yZ2FuaXphdGlvbjIyOTc4OTY2","avatar_url":"https://avatars2.githubusercontent.com/u/22978966?v=4","gravatar_id":"","url":"https://api.github.com/users/vathes","html_url":"https://github.com/vathes","followers_url":"https://api.github.com/users/vathes/followers","following_url":"https://api.github.com/users/vathes/following{/other_user}","gists_url":"https://api.github.com/users/vathes/gists{/gist_id}","starred_url":"https://api.github.com/users/vathes/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vathes/subscriptions","organizations_url":"https://api.github.com/users/vathes/orgs","repos_url":"https://api.github.com/users/vathes/repos","events_url":"https://api.github.com/users/vathes/events{/privacy}","received_events_url":"https://api.github.com/users/vathes/received_events","type":"Organization","site_admin":false},"repo":{"id":161227479,"node_id":"MDEwOlJlcG9zaXRvcnkxNjEyMjc0Nzk=","name":"Guo-Inagaki-2017","full_name":"vathes/Guo-Inagaki-2017","private":false,"owner":{"login":"vathes","id":22978966,"node_id":"MDEyOk9yZ2FuaXphdGlvbjIyOTc4OTY2","avatar_url":"https://avatars2.githubusercontent.com/u/22978966?v=4","gravatar_id":"","url":"https://api.github.com/users/vathes","html_url":"https://github.com/vathes","followers_url":"https://api.github.com/users/vathes/followers","following_url":"https://api.github.com/users/vathes/following{/other_user}","gists_url":"https://api.github.com/users/vathes/gists{/gist_id}","starred_url":"https://api.github.com/users/vathes/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vathes/subscriptions","organizations_url":"https://api.github.com/users/vathes/orgs","repos_url":"https://api.github.com/users/vathes/repos","events_url":"https://api.github.com/users/vathes/events{/privacy}","received_events_url":"https://api.github.com/users/vathes/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/vathes/Guo-Inagaki-2017","description":null,"fork":false,"url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017","forks_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/forks","keys_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/keys{/key_id}","collaborators_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/teams","hooks_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/hooks","issue_events_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/issues/events{/number}","events_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/events","assignees_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/assignees{/user}","branches_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/branches{/branch}","tags_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/tags","blobs_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/git/refs{/sha}","trees_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/git/trees{/sha}","statuses_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/statuses/{sha}","languages_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/languages","stargazers_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/stargazers","contributors_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/contributors","subscribers_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/subscribers","subscription_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/subscription","commits_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/commits{/sha}","git_commits_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/git/commits{/sha}","comments_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/comments{/number}","issue_comment_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/issues/comments{/number}","contents_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/contents/{+path}","compare_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/compare/{base}...{head}","merges_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/merges","archive_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/downloads","issues_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/issues{/number}","pulls_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/pulls{/number}","milestones_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/milestones{/number}","notifications_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/labels{/name}","releases_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/releases{/id}","deployments_url":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/deployments","created_at":"2018-12-10T19:41:27Z","updated_at":"2018-12-10T20:36:41Z","pushed_at":"2018-12-20T16:39:33Z","git_url":"git://github.com/vathes/Guo-Inagaki-2017.git","ssh_url":"git@github.com:vathes/Guo-Inagaki-2017.git","clone_url":"https://github.com/vathes/Guo-Inagaki-2017.git","svn_url":"https://github.com/vathes/Guo-Inagaki-2017","homepage":null,"size":2,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"archived":false,"open_issues_count":1,"license":null,"forks":2,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/pulls/1"},"html":{"href":"https://github.com/vathes/Guo-Inagaki-2017/pull/1"},"issue":{"href":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/issues/1"},"comments":{"href":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/issues/1/comments"},"review_comments":{"href":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/pulls/1/comments"},"review_comment":{"href":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/pulls/1/commits"},"statuses":{"href":"https://api.github.com/repos/vathes/Guo-Inagaki-2017/statuses/a40ad3d23e5ee80231380df4d44cd268a5b49935"}},"author_association":"COLLABORATOR"}}
{"actor":{"display_login":"dimitri-yatsenko"}}