Pre-processing of OCT B-scans for OCT angiography
A computer-implemented method of processing repeat B-scans of an imaged region of a body part, the imaged region including an anatomical feature in a first subregion and vasculature of interest in a second subregion of the imaged region, to generate cropped B-scans for use in generating OCT angiography data which provides a representation of the vasculature of interest, the method comprising processing each B-scan of the repeat B-scans by: selecting a subset of the data elements of the B-scan such that the selected data elements are distributed along a representation of the anatomical feature in the B-scan; using the selected data elements to define a respective subregion of interest in the B-scan, which includes OCT data acquired from the second subregion containing the vasculature of interest; and cropping the B-scan to leave the subregion of interest in the B-scan.
1 . A non-transitory computer-readable storage medium storing instructions which, when executed by a computer processor, cause the computer processor to perform a method of processing repeat B-scans of an imaged region of a body part acquired by an optical coherence tomography (OCT) imaging apparatus, the imaged region including an anatomical feature confined to a first subregion of the imaged region and vasculature of interest that is confined to a second subregion of the imaged region, to generate cropped B-scans for use in generating OCT angiography (OCTA) data which provides a representation of the vasculature of interest, the method comprising processing each B-scan of the repeat B-scans to generate a respective cropped B-scan by:
selecting, from data elements of the B-scan, a subset of the data elements such that the selected data elements are distributed along a representation of the anatomical feature in the B-scan;
using the selected data elements to define a respective subregion of interest in the B-scan, the respective subregion of interest including OCT data acquired from the second subregion which contains the vasculature of interest; and
generating the respective cropped B-scan by cropping the B-scan to leave the subregion of interest in the B-scan.
2 . The non-transitory computer-readable storage medium according to claim 1 , wherein
the body part comprises an eye,
the imaged region of the body part comprises a retina of the eye, and
the anatomical feature comprises an anatomical layer of the retina.
3 . The non-transitory computer-readable storage medium according to claim 2 , wherein
the anatomical layer of the retina is a retinal pigment epithelium, RPE, of the retina, and
the selecting of the subset of data elements comprises determining whether respective values of data elements in the B-scan have a predefined relationship to a threshold value, and selecting, for the subset, data elements whose values have the predefined relationship to the threshold value, the threshold value being set such that at least some of the selected data elements are distributed along a representation of the RPE in the B-scan.
4 . The non-transitory computer-readable storage medium according to claim 3 , wherein the threshold value is calculated from data element values in the B-scan such that there is only a predetermined number of the data elements above a number, k, of standard deviations from a mean, u, of the data element values in the B-scan, wherein k is set such that at least some of the selected data elements are distributed along the representation of the RPE in the B-scan, the threshold value being calculated by modelling the data element values in the B-scan to be distributed in accordance with a predetermined type of statistical distribution.
5 . The non-transitory computer-readable storage medium according to claim 3 , wherein
each B-scan comprises an array of A-scans that are arrayed along a first axis of the B-scan, each of the A-scans comprising data elements arrayed along a second axis of the B-scan,
the selected data elements are used to define a respective subregion of interest in the B-scan relative to the selected data elements by:
fitting a function to a distribution within the B-scan of the selected data elements;
calculating, for each A-scan in the B-scan, a respective value of an error measure for the selected data elements in the A-scan that is indicative of a distribution of the selected data elements along the A-scan, the respective value of the error measure being calculated for each A-scan in the B-scan with reference to a respective data element in the A-scan corresponding to a value of the fitted function at a coordinate of the A-scan along the first axis;
comparing, for each A-scan of the B-scan, the value of the error measure, which has been calculated for the selected data elements in the A-scan, with a threshold error value;
generating a modified selection of data elements in the B-scan by selecting, for each A-scan in the B-scan having a calculated value of the error measure that is greater than the threshold error value, data elements from the selected data elements in the A-scan that are below the respective data element in the A-scan;
fitting the function to a distribution within the B-scan of the modified selection of data elements;
using the function fitted to the distribution within the B-scan of the modified selection of data elements to calculate a respective reference coordinate along the second axis of the B-scan; and
defining the respective subregion of interest in the B-scan as a subregion of the B-scan having a predetermined size and a predetermined offset along the second axis of the B-scan relative to the calculated respective reference coordinate.
6 . The non-transitory computer-readable storage medium according to claim 5 , wherein the error measure comprises one of:
a normalized mean squared error of respective deviations of locations of the selected data elements in the A-scan from a location of a data element in the A-scan corresponding to the value of the fitted function at the coordinate of the A-scan along the first axis;
a sum of absolute deviations of locations of the selected data elements in the A-scan from a location of a data element in the A-scan corresponding to the value of the fitted function at the coordinate of the A-scan along the first axis; or
a sum of squared deviations of respective locations of the selected data elements in the A-scan from a location of a data element in the A-scan corresponding to the value of the fitted function at the coordinate of the A-scan along the first axis.
7 . The non-transitory computer-readable storage medium according to claim 5 , wherein the function is a quadratic function.
8 . The non-transitory computer-readable storage medium according to claim 1 , wherein
each B-scan comprises an array of A-scans that are arrayed along a first axis of the B-scan, each of the A-scans comprising data elements arrayed along a second axis of the B-scan,
the anatomical feature comprises an anatomical layer of the body part which is confined to the first subregion of the imaged region,
the selected data elements are used to define a respective subregion of interest in the B-scan relative to the selected data elements by:
fitting a function to a distribution within the B-scan of the selected data elements;
using the fitted function to calculate a respective reference coordinate along the second axis of the B-scan; and
defining the respective subregion of interest in the B-scan as a subregion of the B-scan having a predetermined size and a predetermined offset along the second axis of the B-scan relative to the calculated respective reference coordinate.
9 . The non-transitory computer-readable storage medium according to claim 8 , wherein
the body part comprises an eye,
the imaged region of the body part comprises a retina of the eye,
the anatomical layer comprises a retinal pigment epithelium, RPE, of the retina, and the function is a quadratic function.
10 . The non-transitory computer-readable storage medium according to claim 8 , wherein using the fitted function to calculate the respective reference coordinate along the second axis of the B-scan comprises:
determining a maximum value of the fitted function in an interval along the first axis spanned by the A-scans of the B-scan;
determining a minimum value of the fitted function in the interval along the first axis; and
calculating, as the reference coordinate, a mean of the maximum value and the minimum value.
11 . The non-transitory computer-readable storage medium according to claim 1 , wherein
each B-scan comprises an array of A-scans that are arrayed along a first axis of the B-scan, each of the A-scans comprising data elements arrayed along a second axis of the B-scan, and
the method further comprises:
determining whether the defined subregion of interest extends along one of the first axis and the second axis to an edge of the B-scan;
determining whether a size of the cropped B-scan along the one of the first axis and the second axis is smaller than a predetermined size; and
in a case where the subregion of interest has been determined to extend along the one of the first axis and the second axis to the edge of the B-scan, and the size of the cropped B-scan along the one of the first axis and the second axis has been determined to be smaller than the predetermined size, increasing the size of the cropped B-scan to the predetermined size by expanding the cropped B-scan along the one of the first axis and the second axis to have additional data elements whose data element values are based on a noise profile calculated from the B-scan.