You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The difference is that in the first case fill_hyperspace returns contiguous slabs of chunks to read directly from the underlying HDF5 layer, so a whole row of chunks is loaded up with a single call to hdf5.Dataset.__getitem__, whereas in the second case fill_hyperspace fails to notice that an optimization is possible and as a result you end up calling hdf5.Dataset.__getitem__ again and again for every individual chunk.
in the above diagram, Xs are the chunks that are already in memory because of the previous call to dset[:, ::2 * chunk_size] = a, whereas each lowercase letter represents a separate call to hdf5.Dataset.__getitem__ when the user invokes b = dset[:].
The text was updated successfully, but these errors were encountered:
This is a follow-up to #370 and more specifically #371.
Downstream of #370, this is very fast:
While this is much slower:
The difference is that in the first case
fill_hyperspace
returns contiguous slabs of chunks to read directly from the underlying HDF5 layer, so a whole row of chunks is loaded up with a single call tohdf5.Dataset.__getitem__
, whereas in the second casefill_hyperspace
fails to notice that an optimization is possible and as a result you end up callinghdf5.Dataset.__getitem__
again and again for every individual chunk.In other words,
in the above diagram, Xs are the chunks that are already in memory because of the previous call to
dset[:, ::2 * chunk_size] = a
, whereas each lowercase letter represents a separate call tohdf5.Dataset.__getitem__
when the user invokesb = dset[:]
.The text was updated successfully, but these errors were encountered: