Skip to content

Conversation

@jacob720
Copy link

@jacob720 jacob720 commented Feb 10, 2026

@jacob720 jacob720 marked this pull request as draft February 10, 2026 10:15
@jacob720 jacob720 force-pushed the 85_add_vds_generation branch from d1684f5 to 371e9a0 Compare February 10, 2026 10:17
@jacob720 jacob720 changed the base branch from main to top-level-attributes February 10, 2026 13:06
bit_depth_image: AttrR[int]
compression: AttrRW[str]
trigger_mode: AttrR[str]
nimages: AttrR[int]
Copy link
Author

Choose a reason for hiding this comment

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

May be better to get this out of OD.FP.frames?

Copy link
Contributor

@GDYendell GDYendell left a comment

Choose a reason for hiding this comment

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

This looks pretty good! Something I should have mentioned is that we need to create multiple virtual datasets. This should be easy enough, it will just need a bit of re-ordering to avoid repeating the calculations.

I think there should be a for loop over dataset_names (now passed in) inside the with File block where all creation of v_source and v_layout is done, with pre-computation of frame layouts done before if possible.

create_interleave_vds(
path=Path(self.OD.file_path.get()),
prefix=self.OD.file_prefix.get(),
frame_count=self.detector.nimages.get(),
Copy link
Contributor

Choose a reason for hiding this comment

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

This should probably be OD.FP.frames

prefix=self.OD.file_prefix.get(),
frame_count=self.detector.nimages.get(),
frames_per_block=self.OD.block_size.get(),
blocks_per_file=self.OD.FP.process_blocks_per_file.get(),
Copy link
Contributor

Choose a reason for hiding this comment

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

process_blocks_per_file needs adding to the EigerFrameProcessorPlugin

frame_shape=(
self.detector.x_pixels_in_detector.get(),
self.detector.y_pixels_in_detector.get(),
),
Copy link
Contributor

Choose a reason for hiding this comment

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

This should be OD.FP.data_dims_0/1. These probably don't change if it is in ROI mode.

dtype=dtype,
)

for file_writer_idx, n_frames in enumerate(frame_count_per_file_writer):
Copy link
Contributor

Choose a reason for hiding this comment

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

I am not sure that you need to iterate over file writer index and then its local file
index. I think it should just iterate over the global file index and the number of writers
only affects the stride of the layout slice.

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.

Add VDS generation

2 participants