Skip to main content
. 2023 Jun 20;28(6):066002. doi: 10.1117/1.JBO.28.6.066002

Algorithm 1.

Blood vasculature under the skin layer

Input: breast mask without skin, Nx, Ny, Nz, σ1, σ2, σ3
Output: artery mask, vein mask
1: Obtain a Ny×Nz random sample matrix from a uniform distribution
2: Obtain two blurred matrices via Gaussian filtering with σ1 and σ2 to the result of step (1)
3: Calculate the difference between the results of step (2)
4: Binarize the result of step (3) by Otsu’s thresholding
5: Skeletonize the result of step (4)
6: Obtain a Nx×Ny×Nz matrix that contains Nx copies of the result of step (5) in the first dimension of 3D
7: Perform bit-wise exclusive or operation (XOR) between breast mask without skin and that after erosion for 0.375 mm
8: Perform XOR of the results of steps (6) and (7)
9: Skeletonize the result of step (8)
10: Blur the result of step (9) by Gaussian filtering with σ3
11: Binarize the result of step (10) by Otsu’s thresholding
12: Obtain artery mask and vein mask by labeling the segments in the result of step (11) with either arteries or veins, respectively
13: return artery mask, vein mask