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

Add FormatTools methods for creating well names #3347

Merged
merged 6 commits into from
Feb 10, 2022

Conversation

melissalinkert
Copy link
Member

9631911 is backported from a private PR.

This adds String getWellName(int row, int col) and String getWellRowName(int row) to FormatTools, to unify the logic for creating a well name from the row and column indexes. This was prompted by a plate with more than 26 rows, which caused weird Image names when using the standard 'A' + rowIndex logic. I'm open to other ideas on how to name rows beyond the 26th; what is here just seemed like the most obvious strategy.

I wouldn't expect any test failures, as existing Image names should not change and I don't think we have any plates larger than 384 wells at the moment. This is just low priority cleanup and future-proofing, so feel free to exclude as needed.

This handles row counts greater than 26, and should make it easier to
get meaningful well names across all HCS readers.
This is a step towards supporting plates with more than 26 rows, in
particular 1536-well plates.
@melissalinkert
Copy link
Member Author

Excluding for now, since this conflicts with #3350 (which has new datasets and config changes).

@sbesson
Copy link
Member

sbesson commented Jan 14, 2022

The new API additions make sense to me and are directly used in various HCS readers with the non-regression tests staying successful. ONly consideration is whether unit tests should also be added to formats-api directly. Otherwise LGTM from my side.

@sbesson sbesson requested a review from dgault January 14, 2022 13:15
@melissalinkert
Copy link
Member Author

A few tests added in 969f1c1. I think I convinced myself that it's better to explicitly forbid a negative/row column, but if anyone disagrees can revert that change.

Copy link
Member

@sbesson sbesson left a comment

Choose a reason for hiding this comment

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

I agree with the proposed behavior of throwing an exception for negative indexes.

@dgault
Copy link
Member

dgault commented Feb 10, 2022

Builds and tests have remained green with this PR included.

The new API additions look good and the behaviour matches the expected results. Testing manually with sample files from each of the impacted readers and the well names remained consistent with no regressions detected. The size limit seems fine for now and can be extended in the future if ever required. PR looks good to merge for 6.9.0

@dgault dgault merged commit d8526f2 into ome:develop Feb 10, 2022
@melissalinkert melissalinkert deleted the well-names-big-plates branch September 6, 2024 19:02
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.

3 participants