{"action":"created","issue":{"url":"https://api.github.com/repos/joblib/joblib/issues/260","labels_url":"https://api.github.com/repos/joblib/joblib/issues/260/labels{/name}","comments_url":"https://api.github.com/repos/joblib/joblib/issues/260/comments","events_url":"https://api.github.com/repos/joblib/joblib/issues/260/events","html_url":"https://github.com/joblib/joblib/pull/260","id":113053476,"number":260,"title":"[MRG] Numpy pickle to single file","user":{"login":"aabadie","id":1375137,"avatar_url":"https://avatars.githubusercontent.com/u/1375137?v=3","gravatar_id":"","url":"https://api.github.com/users/aabadie","html_url":"https://github.com/aabadie","followers_url":"https://api.github.com/users/aabadie/followers","following_url":"https://api.github.com/users/aabadie/following{/other_user}","gists_url":"https://api.github.com/users/aabadie/gists{/gist_id}","starred_url":"https://api.github.com/users/aabadie/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aabadie/subscriptions","organizations_url":"https://api.github.com/users/aabadie/orgs","repos_url":"https://api.github.com/users/aabadie/repos","events_url":"https://api.github.com/users/aabadie/events{/privacy}","received_events_url":"https://api.github.com/users/aabadie/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":85,"created_at":"2015-10-23T16:22:17Z","updated_at":"2015-12-13T12:37:59Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/joblib/joblib/pulls/260","html_url":"https://github.com/joblib/joblib/pull/260","diff_url":"https://github.com/joblib/joblib/pull/260.diff","patch_url":"https://github.com/joblib/joblib/pull/260.patch"},"body":"I gave a try to gzip.GzipFile to dump numpy object. This PR is a POC of such usage and also contains a fairly large refactoring of numpy_pickle.\r\n\r\nIn terms of performance, I reused the bench script from #255. With Numpy 1.10, there's no memory copy but the read/write is slightly slower (31s dump, 5.5s read). It also makes the code more 'readable'.\r\nI had to comment out the test regarding the compatibility between pickles.\r\n\r\nWaiting for the CI's"},"comment":{"url":"https://api.github.com/repos/joblib/joblib/issues/comments/164254642","html_url":"https://github.com/joblib/joblib/pull/260#issuecomment-164254642","issue_url":"https://api.github.com/repos/joblib/joblib/issues/260","id":164254642,"user":{"login":"aabadie","id":1375137,"avatar_url":"https://avatars.githubusercontent.com/u/1375137?v=3","gravatar_id":"","url":"https://api.github.com/users/aabadie","html_url":"https://github.com/aabadie","followers_url":"https://api.github.com/users/aabadie/followers","following_url":"https://api.github.com/users/aabadie/following{/other_user}","gists_url":"https://api.github.com/users/aabadie/gists{/gist_id}","starred_url":"https://api.github.com/users/aabadie/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aabadie/subscriptions","organizations_url":"https://api.github.com/users/aabadie/orgs","repos_url":"https://api.github.com/users/aabadie/repos","events_url":"https://api.github.com/users/aabadie/events{/privacy}","received_events_url":"https://api.github.com/users/aabadie/received_events","type":"User","site_admin":false},"created_at":"2015-12-13T12:37:59Z","updated_at":"2015-12-13T12:37:59Z","body":"> Can you add a few specific unit tests to get it back up?\r\n\r\nI could fix the coveralls issue:\r\n* It appears that numpy arrays subclasses reconstruction is not covered by the tests because of a misuse of `ndarray.__array_prepare__()` function : the subclass type is correctly set but the content is not filled... and the tests only checks that the type of subclass is correct (e.g numpy.matrix for example) but never its content. I fixed this here but note that this problem is already present in master.\r\n* I also generated pickled numpy array and matrix objects with the old format in `joblib/test/data` just to cover all use cases of the compatibility code and added a dedicated test function.\r\n* The other coverage issues were due to code depending on the versions of python or numpy. I just changed that: always use our own `asbytes` or `_read_bytes` functions instead of the numpy one."}}