-
Notifications
You must be signed in to change notification settings - Fork 54
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 support for passing wells as List[dict] in write_plate_metadata #157
Conversation
Codecov Report
@@ Coverage Diff @@
## master #157 +/- ##
==========================================
+ Coverage 80.49% 81.12% +0.63%
==========================================
Files 11 11
Lines 1174 1192 +18
==========================================
+ Hits 945 967 +22
+ Misses 229 225 -4
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Barring the same discussion around possible prefixes for unparsed keys, 👍
Looks good. |
Re list of strings, my consideration was to limit the scope of supporting conventions and only consider the single standard scenario where row == letter, column == 1-based index i.e. support But I am okay with leaving it the caller responsibility to generate the row/column indices first if we believe this is unnecessary. We can always add convenience APIs later |
I guess that is kinda convenient. And we will also have the
and raise |
Very good point about
Either way, I don't think there is any breaking change involved as the HCS API has not been released yet. |
@sbesson do you want to add support for calculating rowIndex and columnIndex like in #157 (comment) in this PR? |
Yes, as per the discussion above, my intention is to support the following APIs
I would add support in a follow-up PR as I'd need the |
Follow-up of #153, this adds support for wells specified as lists of dictionaries rather than lists of string. The primary use case are:
1- support additional custom metadata e.g.
2- support the upcoming breaking changes proposed in ome/ngff#24 i.e.
Unit tests are updated accordingly to cover all variants. While working on the tests, I found that the usage of the list mutability by the
_validate*
API was creating unnecessary confusion when the input argument is re-used. 347da42 updates the logic to create a copy of the input list when the content might be modified by the validation function.Since this API will likely be released with 0.4 support and given the changes proposed in ome/ngff#24, it is likely the former support for wells as
List[str]
will:1- either need to be removed as a list of paths will not be sufficient to generate valid
wells
2- or be updated to include the assumptions that the wells are following the standard letter/number convention and auto-generate the underlying
rowIndex
/columnIndex
indices.I left this discussion outside the scope of this PR which only focuses on supporting the
List[dict]
form.