Skip to content

Does the LRUStoreCache store compressed or decompressed chunks? #1833

Answered by rabernat
cwognum asked this question in Q&A
Discussion options

You must be logged in to vote

The Store interface in Zarr Python returns compressed bytes from storage. LRUStoreCache wraps one (high latency) store with another store which caches those bytes in memory, exposing the same interface to the rest of the library.

So yes, the data are decompressed every time you read a chunk, even if that chunk is cached.

There are definitely scenarios where caching decompressed data would be preferable. That would be an interesting direction to explore.

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
1 reply
@cwognum
Comment options

Answer selected by cwognum
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants