Implemented 3D connected components as wrapper class for scipy.ndimage.label
All threads resolved!
All threads resolved!
Compare changes
- Christian Kento Rasmussen authored
+ 19
− 11
@@ -2,6 +2,8 @@ import numpy as np
@@ -2,6 +2,8 @@ import numpy as np
@@ -12,27 +14,31 @@ class CC:
@@ -12,27 +14,31 @@ class CC:
# As we index get_bounding_box element 0 will be the bounding box for the connected component at index
@@ -52,10 +58,10 @@ class CC:
@@ -52,10 +58,10 @@ class CC:
@@ -69,4 +75,6 @@ def get_3d_cc(image: np.ndarray | torch.Tensor):
@@ -69,4 +75,6 @@ def get_3d_cc(image: np.ndarray | torch.Tensor):