Last active
May 24, 2016 09:15
-
-
Save themperek/6c0067782fffe5c6ced8e47e08375ba3 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
filter_tables = tables.Filters(complib='blosc', complevel=0) | |
def hser(data): | |
h5file = tables.open_file("in-memory", "w", driver="H5FD_CORE", driver_core_backing_store=0) | |
h5file.create_table(h5file.root, "array", data, filters=filter_tables) | |
fi = h5file.get_file_image() | |
h5file.close() | |
return fi | |
def hdes(sdata): | |
h5_file = tables.open_file("in-memory", mode="r", driver="H5FD_CORE", driver_core_image=sdata, driver_core_backing_store=0) | |
sdatax = h5_file.root.array[:] | |
h5_file.close() | |
return sdatax |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment