metadata - auto-fill scales from N5 attributes#45
Open
martinschorb wants to merge 1 commit intoconstantinpape:masterfrom
Open
metadata - auto-fill scales from N5 attributes#45martinschorb wants to merge 1 commit intoconstantinpape:masterfrom
martinschorb wants to merge 1 commit intoconstantinpape:masterfrom
Conversation
auto-fill scales from N5 attributes
Owner
|
I would rather not merge this here, because storing the scale factors in In the meantime, you can simply read the with open(os.path.join(path, "setup0", "timepoint0", "attributes.json")) as f:
scale_factors = json.load(f)["scales"]
# first need to reverse the axis order of the scale factors due to XYZ convention in java vs. ZYX convention in python
scale_factors = [sf[::-1] for sf in scale_factors]
# then need to translate from absolute to relative scale factors, which are expected by pybdv
scale_factors = pybdv.util.absolute_to_relative_scale_factors(scale_factors)
write_n5_metadata(path, scale_factors, ...) |
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.
auto-fill scales from N5 attributes