Align development and master histories by rebasing development onto master - #192
Merged
Conversation
* Move ReadData etc to separate classes * Add ReadData.writeTo(OutputStream) * Add EncodedReadData that wraps a ReadData and an OutputStreamEncoder * Compression (BytesCodec) can encode ReadData. (This might happen immediately or later when the ReadData is written to OutputStream).
We still need a custom interface "OutputStreamOperator" because we want to throw IOException and UnaryOperator::apply doesn't.
When data is requested from the LazyReadData, the LazyReadData will ask its OutputStreamWriter to write the data to a ByteArrayOutputStream. When the LazyReadData itself is written to an OutputStream, it will pass that OutputStream to its OutputStreamWriter (without loading the data into a byte[] array first).
* getDatasetCodecInfos from DatasetAttributes
* add TransposeCodec implementation * DefaultDatasetAccess applies DatasetCodec chain
* implementation layer needs a different permutation due to c- f-order
Signed-off-by: Caleb Hulbert <cmhulbert@gmail.com>
* extract sub-codecs from serialized codecs
* use correct codec implementation * add commons-codec dependency * add test
* encodes / decodes string valued hex representations
* to avoid clash of corresponding padded codec in n5-zarr
* TransposeCodecInfo applies its permutation directly * special case processing for serialization moved to zarr
This gives the maximum pixel position covered by a shard/block at a given nesting level. Used for DatasetAccess.writeRegion().
NestedPosition should be ordered such that positions from a (sub-)shard
are grouped together:
For nested = {X,Y,Z} compare by Z, then Y, then X.
For X = [x,y,z] compare by z, then y, then x. (flattening order)
The List<DataBlock> returned by readBlocks is now in the same order as List<long[]> of positions requested. writeBlocks now doesn't read and decode existing shards that are completely overwritten.
Signed-off-by: Caleb Hulbert <cmhulbert@gmail.com>
Signed-off-by: Caleb Hulbert <cmhulbert@gmail.com>
Signed-off-by: Caleb Hulbert <cmhulbert@gmail.com>
Signed-off-by: Caleb Hulbert <cmhulbert@gmail.com>
* refactor ShardedN5Writer to TrackingN5Writer * a special N5Writer class is not needed to * rather, particular DatasetAttribute instances can be used to test sharding
* necessary for saveNonEmptyBlocks in n5-imglib2
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
We wanted to keep the git history that was previously squashed into master in #177. This proved more difficult of a workflow than we wanted, so we will archive that branch with a tag (shard-dev-archive) so the history is still available if ever it is useful.
Otherwise, we rebased current development off master, and will merge this PR into master. Then,
develomentbranch will be recreated off of master.any feature branches off of
developmentbefore this will need to rebase/cherry-pick onto the new development branch, ensuring that the commits we removed are not re-introduced.