Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SBX utils: ensure correct photometric setting for TIFs and allow extracting single plane #1316

Merged
merged 2 commits into from
Apr 1, 2024

Conversation

ethanbb
Copy link
Contributor

@ethanbb ethanbb commented Apr 1, 2024

Description

This PR includes two changes:

  • A bugfix for the condition when a 3D SBX with 3 or 4 planes is converted to TIF. By default, tifffile assumes the 4th dimension is the color channel, so it is necessary to set photometric to MINISBLACK to avoid each plane being 3-dimensional.
  • An added feature, the plane argument to SBX loading/conversion functions, which allows extraction of a single plane without keeping the singleton dimension. This is useful when opting to process each plane of a volumetric dataset individually.

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)

Has your PR been tested?

If you're fixing a bug or introducing a new feature it is recommended you run the tests by typing

Yes, caimanmanager test passes and new tests have been added for both of these changes.

@pgunn pgunn merged commit f8a8102 into flatironinstitute:dev Apr 1, 2024
3 checks passed
@pgunn
Copy link
Member

pgunn commented Apr 1, 2024

Looks good. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants