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

[Requirement] [File-Handling] Support various image formats. #34

Open
8 tasks
YooSunYoung opened this issue Jul 17, 2024 · 2 comments
Open
8 tasks

[Requirement] [File-Handling] Support various image formats. #34

YooSunYoung opened this issue Jul 17, 2024 · 2 comments

Comments

@YooSunYoung
Copy link
Member

Executive summary

Imaging workflows should be able to load/save various image formats.

Context and background knowledge

There are various existing imaging analysis tools that support complicated features and we can't support all of them with essimaging so we are expecting to use those existing tools.
However, they might only accept certain image formats, so we need to be flexible about exporting images.

Loading various images should be also supported since we will need to verify our methods with other existing tools with existing images, that are not in nexus format.

Inputs

See fabio for more examples.
Common neutron image formats are

  • tiff
  • png
  • mpeg
  • nexus
  • binary (i.e. binary files from timepix detector)

Methodology

  • Write/wrap loader/exporters of each image format using reliable third party APIs.
  • Define a data structure that is useful for neutron imaging and load images into the data structure or save the data structure into the target format.
  • Write clear documentation about how to write such wrapper/loader/exporter to be inserted in workflows.

Outputs

Same as Inputs

Which interfaces are required?

Integrated into reduction workflow, Python module / function, Jupyter notebook

Test cases

We have some images from timepix detector we can use for testings.
We can use background image or iron sample measurement.

Comments

No response

@nvaytet
Copy link
Member

nvaytet commented Jul 30, 2024

Not sure why the supported input formats need to be the same as the supported output formats.
As the description at the top says, we shouldn't have to support all inputs.
I am hoping we can get away with just Nexus and one other image format as input.
Basically, I think we should get an actual list of required outputs, instead of guessing what we might need?

Regarding fabio I remember having some issues with it in the past (I can't remember what the issues were specifically), but that was a while ago, maybe that is no longer relevant.
I think we also talked about usingPillow for saving images, which should work well I think?

@YooSunYoung
Copy link
Member Author

Not sure why the supported input formats need to be the same as the supported output formats.

It doesn't have to be.
I just didn't want to repeat them because they are the same in this specific cases.

These formats were mentioned in the last meeting about imaging.
It's more than just guessing because there are typical imaging tools that users need (at least the instrument scientists).

Nexus should be the first priority among all though.

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

No branches or pull requests

2 participants