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

Split out common AD file plugin logic into core writer class, create ADTiffWriter #606

Merged
merged 45 commits into from
Jan 6, 2025

Conversation

jwlodek
Copy link
Member

@jwlodek jwlodek commented Oct 8, 2024

This now seems to mostly work, at least from the collection side. The data cannot be read back via tiled at the moment, however, so for now marking as draft, since I may need to edit the docs generated somewhat to account for this. PRs into bluesky and tiled have been merged to allow reading back collected TIFF data with this branch.

Addresses #595 .

TODO:

  • Add tests for tiff writer
  • Make sure we can read the data back through tiled
  • Make sure HDF writer still works as it did.

@jwlodek
Copy link
Member Author

jwlodek commented Oct 8, 2024

@genematx Here are the ophyd async changes that introduce tiff writer support, specifically you can look at collect_stream_docs in the ADWriter class to see what I am emitting

@jwlodek jwlodek marked this pull request as ready for review October 10, 2024 13:19
Copy link
Member

@mrakitin mrakitin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We reviewed the changes interactively with @jwlodek and @RobertSchaffer1, and they make sense to me.

@coretl, if you are happy with the changes, Jakub will rebase the PR branch to resolve the conflicts.

Copy link
Collaborator

@coretl coretl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had some ideas that will remove some of the cast statements, what do you reckon?

src/ophyd_async/epics/adcore/_hdf_writer.py Outdated Show resolved Hide resolved
src/ophyd_async/epics/adcore/_hdf_writer.py Outdated Show resolved Hide resolved
src/ophyd_async/epics/adaravis/_aravis.py Outdated Show resolved Hide resolved
@jwlodek
Copy link
Member Author

jwlodek commented Nov 22, 2024

Applied the changes, rebased, and tests are now passing, but for some reason I am having issues running with real hardware. I think I will start a fresh environment on Monday and confirm if I can collect both HDF and TIFF data and read it back via tiled.

@coretl
Copy link
Collaborator

coretl commented Nov 26, 2024

I can see why you've done it, but I would still prefer to pass in the writer instance rather than class into the AreaDetector base class. I've made some suggestions in jwlodek#3

@jwlodek
Copy link
Member Author

jwlodek commented Dec 16, 2024

This is I think ready for another review pass @coretl , but I need to figure out what is happening with the tests on 3.12...

@jwlodek
Copy link
Member Author

jwlodek commented Dec 18, 2024

@coretl applied your suggestions, I agree it is cleaner this way. Still have a unawaited coro error on 3.12 - need to track that down

Copy link
Collaborator

@coretl coretl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A few minor points now, looks almost done, thanks!

src/ophyd_async/epics/adaravis/_aravis_controller.py Outdated Show resolved Hide resolved
src/ophyd_async/epics/adaravis/_aravis_controller.py Outdated Show resolved Hide resolved
src/ophyd_async/epics/adcore/_core_writer.py Outdated Show resolved Hide resolved
src/ophyd_async/epics/adcore/_core_detector.py Outdated Show resolved Hide resolved
src/ophyd_async/epics/adcore/_core_logic.py Outdated Show resolved Hide resolved
src/ophyd_async/epics/adcore/_core_logic.py Outdated Show resolved Hide resolved
src/ophyd_async/epics/adcore/_core_detector.py Outdated Show resolved Hide resolved
src/ophyd_async/epics/adaravis/_aravis.py Outdated Show resolved Hide resolved
src/ophyd_async/epics/adcore/_core_writer.py Outdated Show resolved Hide resolved
src/ophyd_async/epics/adcore/_hdf_writer.py Outdated Show resolved Hide resolved
jwlodek and others added 9 commits December 20, 2024 11:38
Co-authored-by: Tom C (DLS) <101418278+coretl@users.noreply.github.com>
Co-authored-by: Tom C (DLS) <101418278+coretl@users.noreply.github.com>
Co-authored-by: Tom C (DLS) <101418278+coretl@users.noreply.github.com>
Co-authored-by: Tom C (DLS) <101418278+coretl@users.noreply.github.com>
Co-authored-by: Tom C (DLS) <101418278+coretl@users.noreply.github.com>
Co-authored-by: Tom C (DLS) <101418278+coretl@users.noreply.github.com>
Co-authored-by: Tom C (DLS) <101418278+coretl@users.noreply.github.com>
@jwlodek
Copy link
Member Author

jwlodek commented Dec 23, 2024

I think this is now ready for a final once over and then merge

Copy link
Collaborator

@coretl coretl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From a skim of this it looks fine. One possibly unused variable...

src/ophyd_async/epics/adaravis/_aravis_controller.py Outdated Show resolved Hide resolved
@tacaswell tacaswell merged commit 6c42a1f into bluesky:main Jan 6, 2025
15 checks passed
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.

6 participants