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

fix mask_flows_to_seg to work for multiple inputs #932

Merged
merged 1 commit into from
May 7, 2024

Conversation

mrariden
Copy link
Collaborator

@mrariden mrariden commented May 3, 2024

When using io.masks_flows_to_seg() the iteration over the arguments when the input is a list of images did not succeed and fails quietly. I adjusted the iteration to correctly iterate through the arguments.

Resolves:
#904
#894

Remaining issue: in CP2 the arguments for diams and file_names are switched in order compared to CP3. It shouldn't matter if the keywords are used but order-based calls to io.masks_flows_to_seg() will be wrong between the versions. The order cannot be switched without removing the default argument for diams, since there isn't a default for file_names.

Possible solution: set the default diams = None since it is used in the .npy est_diam key. Currently it is set to a default of 30, which may not be correct either.

Copy link

codecov bot commented May 3, 2024

Codecov Report

Attention: Patch coverage is 66.66667% with 1 lines in your changes are missing coverage. Please review.

Project coverage is 56.03%. Comparing base (cc4e62c) to head (21789ec).
Report is 33 commits behind head on main.

Files Patch % Lines
cellpose/io.py 66.66% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #932      +/-   ##
==========================================
- Coverage   56.26%   56.03%   -0.23%     
==========================================
  Files          16       17       +1     
  Lines        3784     3876      +92     
==========================================
+ Hits         2129     2172      +43     
- Misses       1655     1704      +49     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@carsen-stringer carsen-stringer merged commit 9cc49ef into MouseLand:main May 7, 2024
12 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.

None yet

2 participants