Read compressed elements without loading into memory #34
Loading…
x
Reference in New Issue
Block a user
No description provided.
Delete Branch "substream"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
This change removes the load of compressed variables into a MemoryStream before reading them, instead reading out of the original stream.
In testing on some files of sizes up to 70MB the allocated memory when reading was reduced by 50-70%
I wrote the first commit as part of the change but it stands alone as a fix for reading unseekable streams (where stream.Position throws e.g. DeflateStream.Position) or streams where the mat file does not start at 0 (so stream.Position does not work for padding adjustments). It basically just runs all the tests using different factories for different cases
This is great! Thanks for your contribution!
Thanks!