Skip to content

Commit

Permalink
v0.0.5
Browse files Browse the repository at this point in the history
  • Loading branch information
MalloryWittwer committed Mar 14, 2024
1 parent 3da89fe commit eff8f3b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[metadata]
name = mousetumornet
version = 0.0.4
version = 0.0.5
description = nnU-Net model for the segmentation of lung tumor nodules in mice CT scans.
long_description = file: README.md
long_description_content_type = text/markdown
Expand Down
4 changes: 2 additions & 2 deletions src/mousetumornet/roi.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,9 +92,9 @@ def compute_roi(img: np.ndarray):
return df, lungs_bbox_data, body, roi


def compute_roi_bones(img: np.ndarray):
def compute_roi_bones(img: np.ndarray, q=0.99):
"""Computes a ROI encompassing the bones in the image - based on quantiles."""
bones = (img > np.quantile(img, 0.99)).astype(np.uint8)
bones = (img > np.quantile(img, q)).astype(np.uint8)
if bones.sum() == 0:
print("It looks like no bones were segmented.")
x0 = 0
Expand Down

0 comments on commit eff8f3b

Please sign in to comment.