Skip to content

Conversation

@schilling40
Copy link
Contributor

Adapt post-processing for the segmentation of inner hair cells (IHCs).
The current adaptation splits the functions into SGN and IHC. They can probably be more generalized, but this circumvents the adaptation of the prior erosion before using the connected graph components.

WIP

Copy link
Contributor

@constantinpape constantinpape left a comment

Choose a reason for hiding this comment

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

The current adaptation splits the functions into SGN and IHC. They can probably be more generalized, but this circumvents the adaptation of the prior erosion before using the connected graph components.

Splitting this makes sense. We can discuss more adaptations next week.

def run_unet_segmentation_slurm(
output_folder: str,
min_size: int,
boundary_distance_threshold: float = 0.5,
Copy link
Contributor

Choose a reason for hiding this comment

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

We should also expose the center_distance_threshold here.

with zarr.open(s3_path, mode="r") as f:
raw = f[input_key][roi]

elif ".tif" in input_path:
Copy link
Contributor

Choose a reason for hiding this comment

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

I would change this to if input_key is None. That's more consistent to how we handle this otherwise in the codebase.


# create edges between points whose distance is less than threshold min_edge_distance
for i in coords:
for j in coords:
Copy link
Contributor

Choose a reason for hiding this comment

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

This looks wrong. Shouldn't i, j be indices into the respective array or list?
So
for i in range(len(coords))
etc. ?

@schilling40 schilling40 merged commit 3cdefa4 into master Jun 6, 2025
6 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.

3 participants