Skip to content

Commit cd14c3d

Browse files
committed
Updated
1 parent 81ac1eb commit cd14c3d

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

src/AnalysisFunctions.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1337,13 +1337,15 @@ def threshold_cell_areas_3d(
13371337
pil_raw, _, _, _, _ = IA_F.calculate_region_properties(
13381338
cell_mask_new, dims=3, spacing=(1, 1, 1)
13391339
)
1340+
13401341
for i in np.arange(len(pil_raw)):
1341-
if not len(np.unique(pil_raw[i][:, 0])):
1342+
if len(np.unique(pil_raw[i][:, 0]) < n_planes):
13421343
cell_mask_new[pil_raw[i][:, 0], pil_raw[i][:, 1], pil_raw[i][:, 2]] = 0
13431344

13441345
pil, areas, centroids, _, _ = IA_F.calculate_region_properties(
13451346
cell_mask_new, dims=3, spacing=spacing
13461347
)
1348+
13471349
return cell_mask_new, pil, centroids, areas
13481350

13491351
def threshold_cell_areas_2d(

0 commit comments

Comments
 (0)