{"action":"created","issue":{"url":"https://api.github.com/repos/astropy/astropy/issues/3597","labels_url":"https://api.github.com/repos/astropy/astropy/issues/3597/labels{/name}","comments_url":"https://api.github.com/repos/astropy/astropy/issues/3597/comments","events_url":"https://api.github.com/repos/astropy/astropy/issues/3597/events","html_url":"https://github.com/astropy/astropy/issues/3597","id":61577321,"number":3597,"title":"Masked tables lose mask when written to HDF5 files.","user":{"login":"matteobachetti","id":7190189,"avatar_url":"https://avatars.githubusercontent.com/u/7190189?v=3","gravatar_id":"","url":"https://api.github.com/users/matteobachetti","html_url":"https://github.com/matteobachetti","followers_url":"https://api.github.com/users/matteobachetti/followers","following_url":"https://api.github.com/users/matteobachetti/following{/other_user}","gists_url":"https://api.github.com/users/matteobachetti/gists{/gist_id}","starred_url":"https://api.github.com/users/matteobachetti/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/matteobachetti/subscriptions","organizations_url":"https://api.github.com/users/matteobachetti/orgs","repos_url":"https://api.github.com/users/matteobachetti/repos","events_url":"https://api.github.com/users/matteobachetti/events{/privacy}","received_events_url":"https://api.github.com/users/matteobachetti/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/astropy/astropy/labels/Affects-release","name":"Affects-release","color":"0052cc"},{"url":"https://api.github.com/repos/astropy/astropy/labels/Bug","name":"Bug","color":"eb6420"},{"url":"https://api.github.com/repos/astropy/astropy/labels/io.misc","name":"io.misc","color":"c7def8"},{"url":"https://api.github.com/repos/astropy/astropy/labels/table","name":"table","color":"c7def8"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-03-14T12:03:15Z","updated_at":"2015-09-21T16:12:14Z","closed_at":null,"body":"Very quick example:\r\n```\r\nIn [1]: from astropy.table import Table\r\n\r\nIn [2]: import numpy as np\r\n\r\nIn [3]: a = Table(masked=True)\r\n\r\nIn [6]: a['x'] = np.arange(10)\r\n\r\nIn [7]: a\r\nOut[7]: \r\n<Table masked=True length=10>\r\n  x  \r\nint64\r\n-----\r\n    0\r\n    1\r\n    2\r\n    3\r\n    4\r\n    5\r\n    6\r\n    7\r\n    8\r\n    9\r\n\r\nIn [9]: a.write('bu.hdf5', path='bu')\r\n\r\nIn [10]: b = Table.read('bu.hdf5', path='bu')\r\n\r\nIn [11]: b\r\nOut[11]: \r\n<Table masked=False length=10>\r\n  x  \r\nint64\r\n-----\r\n    0\r\n    1\r\n    2\r\n    3\r\n    4\r\n    5\r\n    6\r\n    7\r\n    8\r\n    9\r\n```"},"comment":{"url":"https://api.github.com/repos/astropy/astropy/issues/comments/142030652","html_url":"https://github.com/astropy/astropy/issues/3597#issuecomment-142030652","issue_url":"https://api.github.com/repos/astropy/astropy/issues/3597","id":142030652,"user":{"login":"embray","id":676149,"avatar_url":"https://avatars.githubusercontent.com/u/676149?v=3","gravatar_id":"","url":"https://api.github.com/users/embray","html_url":"https://github.com/embray","followers_url":"https://api.github.com/users/embray/followers","following_url":"https://api.github.com/users/embray/following{/other_user}","gists_url":"https://api.github.com/users/embray/gists{/gist_id}","starred_url":"https://api.github.com/users/embray/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/embray/subscriptions","organizations_url":"https://api.github.com/users/embray/orgs","repos_url":"https://api.github.com/users/embray/repos","events_url":"https://api.github.com/users/embray/events{/privacy}","received_events_url":"https://api.github.com/users/embray/received_events","type":"User","site_admin":false},"created_at":"2015-09-21T16:12:14Z","updated_at":"2015-09-21T16:12:14Z","body":"I'm not really the one to ask. I don't deal with masked tables.  It's certainly not something that's simply natively supported in HDF5.  There's no sense in which HDF5 knows anything about \"masked data\"--one has to invent some kind of convention for storing data along with a mask in and HDF5 format (along with code that knows how to reconstruct the masked Table object from reading that convention).  Since it's a special convention built on top of HDF5 users would have to opt into it.  That's what the issues I referenced above are about."}}