{"action":"created","comment":{"url":"https://api.github.com/repos/dask/distributed/pulls/comments/86448829","pull_request_review_id":7109232,"id":86448829,"diff_hunk":"@@ -0,0 +1,64 @@\n+from __future__ import print_function, division, absolute_import\n+\n+import sys\n+\n+import numpy as np\n+\n+try:\n+    import blosc\n+    n = blosc.set_nthreads(2)","path":"distributed/protocol/numpy.py","position":9,"original_position":9,"commit_id":"a33ecc802ffb52bcfceec7665847fa441c81680d","original_commit_id":"a33ecc802ffb52bcfceec7665847fa441c81680d","user":{"login":"mrocklin","id":306380,"avatar_url":"https://avatars.githubusercontent.com/u/306380?v=3","gravatar_id":"","url":"https://api.github.com/users/mrocklin","html_url":"https://github.com/mrocklin","followers_url":"https://api.github.com/users/mrocklin/followers","following_url":"https://api.github.com/users/mrocklin/following{/other_user}","gists_url":"https://api.github.com/users/mrocklin/gists{/gist_id}","starred_url":"https://api.github.com/users/mrocklin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mrocklin/subscriptions","organizations_url":"https://api.github.com/users/mrocklin/orgs","repos_url":"https://api.github.com/users/mrocklin/repos","events_url":"https://api.github.com/users/mrocklin/events{/privacy}","received_events_url":"https://api.github.com/users/mrocklin/received_events","type":"User","site_admin":false},"body":"We want some benefit from threads, but don't want to take them all (dask itself does parallelism)  Two seemed like a decent default (more decent than \"all\").  Do you have other thoughts on what this should be?","created_at":"2016-11-03T21:37:23Z","updated_at":"2016-11-03T21:37:23Z","html_url":"https://github.com/dask/distributed/pull/606#discussion_r86448829","pull_request_url":"https://api.github.com/repos/dask/distributed/pulls/606","_links":{"self":{"href":"https://api.github.com/repos/dask/distributed/pulls/comments/86448829"},"html":{"href":"https://github.com/dask/distributed/pull/606#discussion_r86448829"},"pull_request":{"href":"https://api.github.com/repos/dask/distributed/pulls/606"}}},"pull_request":{"url":"https://api.github.com/repos/dask/distributed/pulls/606","id":90883456,"html_url":"https://github.com/dask/distributed/pull/606","diff_url":"https://github.com/dask/distributed/pull/606.diff","patch_url":"https://github.com/dask/distributed/pull/606.patch","issue_url":"https://api.github.com/repos/dask/distributed/issues/606","number":606,"state":"closed","locked":false,"title":"Support custom serialization","user":{"login":"mrocklin","id":306380,"avatar_url":"https://avatars.githubusercontent.com/u/306380?v=3","gravatar_id":"","url":"https://api.github.com/users/mrocklin","html_url":"https://github.com/mrocklin","followers_url":"https://api.github.com/users/mrocklin/followers","following_url":"https://api.github.com/users/mrocklin/following{/other_user}","gists_url":"https://api.github.com/users/mrocklin/gists{/gist_id}","starred_url":"https://api.github.com/users/mrocklin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mrocklin/subscriptions","organizations_url":"https://api.github.com/users/mrocklin/orgs","repos_url":"https://api.github.com/users/mrocklin/repos","events_url":"https://api.github.com/users/mrocklin/events{/privacy}","received_events_url":"https://api.github.com/users/mrocklin/received_events","type":"User","site_admin":false},"body":"This changes the protocol to support custom serialization methods on a per-type basis.\n\nFixes https://github.com/dask/distributed/issues/604 which also includes an explanation of the approach taken here.\n\nAs a proof of concept I implemented a custom serialization for numpy ndarrays that both uses blosc (if available) and avoids the two memory copies in pickle.dumps.\n","created_at":"2016-10-25T20:18:30Z","updated_at":"2016-11-03T21:37:23Z","closed_at":"2016-11-02T12:46:30Z","merged_at":"2016-11-02T12:46:30Z","merge_commit_sha":"a9bb18aa1843777f684076ccb1f0b29c64f0d7e2","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/dask/distributed/pulls/606/commits","review_comments_url":"https://api.github.com/repos/dask/distributed/pulls/606/comments","review_comment_url":"https://api.github.com/repos/dask/distributed/pulls/comments{/number}","comments_url":"https://api.github.com/repos/dask/distributed/issues/606/comments","statuses_url":"https://api.github.com/repos/dask/distributed/statuses/a33ecc802ffb52bcfceec7665847fa441c81680d","head":{"label":"mrocklin:protocol-serialize","ref":"protocol-serialize","sha":"a33ecc802ffb52bcfceec7665847fa441c81680d","user":{"login":"mrocklin","id":306380,"avatar_url":"https://avatars.githubusercontent.com/u/306380?v=3","gravatar_id":"","url":"https://api.github.com/users/mrocklin","html_url":"https://github.com/mrocklin","followers_url":"https://api.github.com/users/mrocklin/followers","following_url":"https://api.github.com/users/mrocklin/following{/other_user}","gists_url":"https://api.github.com/users/mrocklin/gists{/gist_id}","starred_url":"https://api.github.com/users/mrocklin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mrocklin/subscriptions","organizations_url":"https://api.github.com/users/mrocklin/orgs","repos_url":"https://api.github.com/users/mrocklin/repos","events_url":"https://api.github.com/users/mrocklin/events{/privacy}","received_events_url":"https://api.github.com/users/mrocklin/received_events","type":"User","site_admin":false},"repo":{"id":46569619,"name":"distributed","full_name":"mrocklin/distributed","owner":{"login":"mrocklin","id":306380,"avatar_url":"https://avatars.githubusercontent.com/u/306380?v=3","gravatar_id":"","url":"https://api.github.com/users/mrocklin","html_url":"https://github.com/mrocklin","followers_url":"https://api.github.com/users/mrocklin/followers","following_url":"https://api.github.com/users/mrocklin/following{/other_user}","gists_url":"https://api.github.com/users/mrocklin/gists{/gist_id}","starred_url":"https://api.github.com/users/mrocklin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mrocklin/subscriptions","organizations_url":"https://api.github.com/users/mrocklin/orgs","repos_url":"https://api.github.com/users/mrocklin/repos","events_url":"https://api.github.com/users/mrocklin/events{/privacy}","received_events_url":"https://api.github.com/users/mrocklin/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/mrocklin/distributed","description":null,"fork":true,"url":"https://api.github.com/repos/mrocklin/distributed","forks_url":"https://api.github.com/repos/mrocklin/distributed/forks","keys_url":"https://api.github.com/repos/mrocklin/distributed/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mrocklin/distributed/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mrocklin/distributed/teams","hooks_url":"https://api.github.com/repos/mrocklin/distributed/hooks","issue_events_url":"https://api.github.com/repos/mrocklin/distributed/issues/events{/number}","events_url":"https://api.github.com/repos/mrocklin/distributed/events","assignees_url":"https://api.github.com/repos/mrocklin/distributed/assignees{/user}","branches_url":"https://api.github.com/repos/mrocklin/distributed/branches{/branch}","tags_url":"https://api.github.com/repos/mrocklin/distributed/tags","blobs_url":"https://api.github.com/repos/mrocklin/distributed/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mrocklin/distributed/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mrocklin/distributed/git/refs{/sha}","trees_url":"https://api.github.com/repos/mrocklin/distributed/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mrocklin/distributed/statuses/{sha}","languages_url":"https://api.github.com/repos/mrocklin/distributed/languages","stargazers_url":"https://api.github.com/repos/mrocklin/distributed/stargazers","contributors_url":"https://api.github.com/repos/mrocklin/distributed/contributors","subscribers_url":"https://api.github.com/repos/mrocklin/distributed/subscribers","subscription_url":"https://api.github.com/repos/mrocklin/distributed/subscription","commits_url":"https://api.github.com/repos/mrocklin/distributed/commits{/sha}","git_commits_url":"https://api.github.com/repos/mrocklin/distributed/git/commits{/sha}","comments_url":"https://api.github.com/repos/mrocklin/distributed/comments{/number}","issue_comment_url":"https://api.github.com/repos/mrocklin/distributed/issues/comments{/number}","contents_url":"https://api.github.com/repos/mrocklin/distributed/contents/{+path}","compare_url":"https://api.github.com/repos/mrocklin/distributed/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mrocklin/distributed/merges","archive_url":"https://api.github.com/repos/mrocklin/distributed/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mrocklin/distributed/downloads","issues_url":"https://api.github.com/repos/mrocklin/distributed/issues{/number}","pulls_url":"https://api.github.com/repos/mrocklin/distributed/pulls{/number}","milestones_url":"https://api.github.com/repos/mrocklin/distributed/milestones{/number}","notifications_url":"https://api.github.com/repos/mrocklin/distributed/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mrocklin/distributed/labels{/name}","releases_url":"https://api.github.com/repos/mrocklin/distributed/releases{/id}","deployments_url":"https://api.github.com/repos/mrocklin/distributed/deployments","created_at":"2015-11-20T15:20:38Z","updated_at":"2016-11-01T06:34:08Z","pushed_at":"2016-11-03T20:06:55Z","git_url":"git://github.com/mrocklin/distributed.git","ssh_url":"git@github.com:mrocklin/distributed.git","clone_url":"https://github.com/mrocklin/distributed.git","svn_url":"https://github.com/mrocklin/distributed","homepage":null,"size":3644,"stargazers_count":5,"watchers_count":5,"language":"Python","has_issues":false,"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":5,"default_branch":"master"}},"base":{"label":"dask:master","ref":"master","sha":"a5db145489560e5cdc06b8cece768ad62d4ae12c","user":{"login":"dask","id":17131925,"avatar_url":"https://avatars.githubusercontent.com/u/17131925?v=3","gravatar_id":"","url":"https://api.github.com/users/dask","html_url":"https://github.com/dask","followers_url":"https://api.github.com/users/dask/followers","following_url":"https://api.github.com/users/dask/following{/other_user}","gists_url":"https://api.github.com/users/dask/gists{/gist_id}","starred_url":"https://api.github.com/users/dask/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dask/subscriptions","organizations_url":"https://api.github.com/users/dask/orgs","repos_url":"https://api.github.com/users/dask/repos","events_url":"https://api.github.com/users/dask/events{/privacy}","received_events_url":"https://api.github.com/users/dask/received_events","type":"Organization","site_admin":false},"repo":{"id":42408083,"name":"distributed","full_name":"dask/distributed","owner":{"login":"dask","id":17131925,"avatar_url":"https://avatars.githubusercontent.com/u/17131925?v=3","gravatar_id":"","url":"https://api.github.com/users/dask","html_url":"https://github.com/dask","followers_url":"https://api.github.com/users/dask/followers","following_url":"https://api.github.com/users/dask/following{/other_user}","gists_url":"https://api.github.com/users/dask/gists{/gist_id}","starred_url":"https://api.github.com/users/dask/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dask/subscriptions","organizations_url":"https://api.github.com/users/dask/orgs","repos_url":"https://api.github.com/users/dask/repos","events_url":"https://api.github.com/users/dask/events{/privacy}","received_events_url":"https://api.github.com/users/dask/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/dask/distributed","description":"Distributed computation in Python","fork":false,"url":"https://api.github.com/repos/dask/distributed","forks_url":"https://api.github.com/repos/dask/distributed/forks","keys_url":"https://api.github.com/repos/dask/distributed/keys{/key_id}","collaborators_url":"https://api.github.com/repos/dask/distributed/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/dask/distributed/teams","hooks_url":"https://api.github.com/repos/dask/distributed/hooks","issue_events_url":"https://api.github.com/repos/dask/distributed/issues/events{/number}","events_url":"https://api.github.com/repos/dask/distributed/events","assignees_url":"https://api.github.com/repos/dask/distributed/assignees{/user}","branches_url":"https://api.github.com/repos/dask/distributed/branches{/branch}","tags_url":"https://api.github.com/repos/dask/distributed/tags","blobs_url":"https://api.github.com/repos/dask/distributed/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/dask/distributed/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/dask/distributed/git/refs{/sha}","trees_url":"https://api.github.com/repos/dask/distributed/git/trees{/sha}","statuses_url":"https://api.github.com/repos/dask/distributed/statuses/{sha}","languages_url":"https://api.github.com/repos/dask/distributed/languages","stargazers_url":"https://api.github.com/repos/dask/distributed/stargazers","contributors_url":"https://api.github.com/repos/dask/distributed/contributors","subscribers_url":"https://api.github.com/repos/dask/distributed/subscribers","subscription_url":"https://api.github.com/repos/dask/distributed/subscription","commits_url":"https://api.github.com/repos/dask/distributed/commits{/sha}","git_commits_url":"https://api.github.com/repos/dask/distributed/git/commits{/sha}","comments_url":"https://api.github.com/repos/dask/distributed/comments{/number}","issue_comment_url":"https://api.github.com/repos/dask/distributed/issues/comments{/number}","contents_url":"https://api.github.com/repos/dask/distributed/contents/{+path}","compare_url":"https://api.github.com/repos/dask/distributed/compare/{base}...{head}","merges_url":"https://api.github.com/repos/dask/distributed/merges","archive_url":"https://api.github.com/repos/dask/distributed/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/dask/distributed/downloads","issues_url":"https://api.github.com/repos/dask/distributed/issues{/number}","pulls_url":"https://api.github.com/repos/dask/distributed/pulls{/number}","milestones_url":"https://api.github.com/repos/dask/distributed/milestones{/number}","notifications_url":"https://api.github.com/repos/dask/distributed/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/dask/distributed/labels{/name}","releases_url":"https://api.github.com/repos/dask/distributed/releases{/id}","deployments_url":"https://api.github.com/repos/dask/distributed/deployments","created_at":"2015-09-13T18:42:29Z","updated_at":"2016-11-02T21:56:59Z","pushed_at":"2016-11-03T20:06:55Z","git_url":"git://github.com/dask/distributed.git","ssh_url":"git@github.com:dask/distributed.git","clone_url":"https://github.com/dask/distributed.git","svn_url":"https://github.com/dask/distributed","homepage":"http://distributed.readthedocs.io/en/latest/","size":4030,"stargazers_count":171,"watchers_count":171,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":72,"mirror_url":null,"open_issues_count":53,"forks":72,"open_issues":53,"watchers":171,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/dask/distributed/pulls/606"},"html":{"href":"https://github.com/dask/distributed/pull/606"},"issue":{"href":"https://api.github.com/repos/dask/distributed/issues/606"},"comments":{"href":"https://api.github.com/repos/dask/distributed/issues/606/comments"},"review_comments":{"href":"https://api.github.com/repos/dask/distributed/pulls/606/comments"},"review_comment":{"href":"https://api.github.com/repos/dask/distributed/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/dask/distributed/pulls/606/commits"},"statuses":{"href":"https://api.github.com/repos/dask/distributed/statuses/a33ecc802ffb52bcfceec7665847fa441c81680d"}}}}
{"actor":{"display_login":"mrocklin"}}