CentralRetinalAnalysis
89 |-
90 |
- 91 | class PVBM.CentralRetinalAnalysis.CREVBMs[source] 92 |
A class that can perform geometrical biomarker computation for a fundus image.
93 |-
94 |
- 95 | compute_central_retinal_equivalents(blood_vessel, skeleton, xc, yc, radius, artery=True, Toplot=False)[source] 96 |
Compute the CRAE or CRVE equivalent for a given blood vessel graph.
97 |-
98 |
- Parameters: 99 |
-
100 |
blood_vessel (np.array) – blood_vessel segmentation containing binary values within {0,1}
101 | skeleton (np.array) – blood_vessel segmentation skeleton containing binary values within {0,1}
102 | xc (int) – x axis of the optic disc center
103 | yc (int) – y axis of the optic disc center
104 | radius (int) – radius in pixel of the optic disc
105 | artery (Bool) – Flag to decide if to use CRAE or CRVE formulas (artery to True means CRAE, and to False means CRVE)
106 | Toplot (Bool) – Flag to decide if to store the visualisation element. (Setting it to true use more RAM)
107 |
109 | - Returns: 110 |
A tuple containing: 111 | - A result dictionnary (Dict): Dictionnary containing the computer CRE (-1 if it has failed) 112 | - plotable_list (List): A summary that contains the topology information required to plot the visualisation (really useful when Toplot is True). Return None if the computation has failed.
113 |
114 | - Return type: 115 |
Tuple[Dict, List]
116 |
117 |
-
121 |
- 122 | apply_roi(segmentation, skeleton, zones_ABC)[source] 123 |
Apply a region of interest (ROI) mask to the segmentation and skeleton images.
124 |-
125 |
- Parameters: 126 |
-
127 |
segmentation (np.array) – The segmentation image containing binary values within {0, 1}.
128 | skeleton (np.array) – The skeleton image containing binary values within {0, 1}.
129 | zones_ABC (np.array) – A mask image used to exclude specific zones, where the second channel defines the exclusion areas.
130 |
132 | - Returns: 133 |
A tuple containing: 134 | - The modified segmentation image with the ROI applied. 135 | - The modified skeleton image with the ROI applied.
136 |
137 | - Return type: 138 |
Tuple[np.array, np.array]
139 |
140 |