A corneal injury detection system based on anterior segment OCT
The center coordinates of the B-scan image are determined through edge detection and arc fitting algorithms, and the position is adjusted using the alignment degree value, which solves the problem of inaccurate B-scan image alignment in corneal damage detection and achieves the accurate construction of the corneal three-dimensional model.
Patent Information
- Application Number
- CN202511101932.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-08-07
- Publication Date
- 2025-09-30
- Estimated Expiration
- 2045-08-07
AI Technical Summary
In OCT three-dimensional modeling of corneal damage, it is difficult to accurately match and align each B-scan image, resulting in inaccurate construction of the three-dimensional model.
By acquiring the OCT scan data of the cornea, the edge detection algorithm and arc fitting algorithm are used to determine the coordinates of the arc center of each B-scan image, and preliminary alignment is performed based on these coordinates. The image position is then adjusted using the alignment degree value to ensure that each B-scan image is accurately aligned, and ultimately the three-dimensional data of the cornea is constructed.
It achieves precise alignment of each B-scan image in corneal damage detection, eliminates the influence of light refraction and patient eye jitter alignment, and ensures the accuracy of the three-dimensional model.
Smart Images

Figure CN120585263B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of image data processing technology, and specifically to a corneal damage detection system based on anterior segment OCT. Background Art
[0002] Optical coherence tomography (OCT) technology uses infrared or white light to illuminate biological samples and detect backscattered photons from different depths within the sample using the coherence principle. This technology can produce depth profiles (also referred to as B-scan images) or three-dimensional structural images of the sample with millimeter-level penetration depths and micrometer-level spatial resolution. Fundus retinal imaging is the most widely used and technologically mature field of OCT. Ophthalmic OCT devices, represented by spectral-domain OCT and swept-band OCT, have a significant installed base and are increasingly becoming the gold standard for imaging diagnosis of fundus diseases.
[0003] Detecting corneal injuries using anterior segment OCT requires 3D reconstruction of the acquired 2D images. This 3D model helps doctors analyze the damage and assist in surgical decisions. During the OCT imaging process, light refracts as it passes through various media (e.g., the sclera lens, tears, and cornea), causing geometric distortion during image reconstruction. Furthermore, slight eye movements or breathing can cause scan line misalignment, resulting in jagged edges or interlaminar fractures. These phenomena can affect the alignment of the individual B-scan images during 3D reconstruction. If the B-scan images cannot be precisely aligned, an accurate 3D model of the cornea cannot be constructed. Summary of the Invention
[0004] The purpose of this application is to provide a corneal injury detection system based on anterior segment OCT to solve the technical problem of difficulty in accurately matching and aligning each B-scan image in OCT three-dimensional modeling of corneal injuries.
[0005] To achieve the above objectives, this application provides the following technical solutions:
[0006] A corneal injury detection system based on anterior segment OCT, comprising:
[0007] An OCT device is used to obtain OCT scanning data of the cornea; the OCT scanning data at least includes a plurality of B-scan images of the anterior segment OCT of the cornea at different angles;
[0008] The server is configured to obtain first alignment data based on each B-scan image; the first alignment data is three-dimensional data formed by directly aligning and splicing each B-scan image;
[0009] and, based on the first alignment data, obtaining a plurality of alignment values; the alignment values corresponding to the B-scan images one-to-one; the alignment values being used to at least represent the degree of alignment between the corresponding B-scan image and the remaining B-scan images;
[0010] and, based on the respective alignment degree values, adjusting the spatial position of each B-scan image in the first alignment data to obtain second alignment data; wherein the alignment degree value corresponding to any B-scan image in the second alignment data is greater than or equal to a preset value;
[0011] and, constructing voxel information based on the second alignment data;
[0012] And, based on the voxel information, three-dimensional data of the cornea is acquired.
[0013] As a specific solution in the technical solution of the present application, the OCT scanning data at least includes rotation scanning data; the rotation scanning data is a plurality of B-scan images at different angles obtained with the center point of the eyeball as the rotation center.
[0014] As a specific solution in the technical solution of the present application, the server is further configured to traverse each B-scan image to obtain a first B-scan image; the first B-scan image is any B-scan image for which the coordinates of the arc center are not obtained among the B-scan images;
[0015] and, obtaining an edge detection image from the first B-scan image based on an edge detection algorithm;
[0016] and obtaining a plurality of fitting arcs from the edge detection image based on an arc fitting algorithm;
[0017] and, based on each fitted arc, obtaining a plurality of arc center coordinates corresponding one-to-one to the fitted arc;
[0018] and, based on the coordinates of the centers of the respective arcs, obtaining the coordinates of the center of the aligned circle;
[0019] And, based on the alignment circle center coordinates, align the first B-scan image with the remaining B-scan images to obtain the first alignment data.
[0020] As a specific solution in the technical solution of the present application, the server obtains the alignment center coordinates based on the center coordinates of each arc, including: the alignment center coordinates are the average value of the center coordinates of each arc.
[0021] As a specific solution in the technical solution of the present application, the server is further used to obtain a weight corresponding to each arc center coordinate based on each arc center coordinate; the weight is used to at least represent the distance between the corresponding arc center coordinate and the remaining arc center coordinates;
[0022] And, based on each weight and each arc center coordinate, the alignment center coordinate is obtained.
[0023] As a specific solution in the technical solution of the present application, the server is further configured to: if the weight corresponding to the arc center coordinate is proportional to the sum of the corresponding distance values, then the aligned center coordinate is the arc center coordinate with the smallest corresponding weight among the arc center coordinates; the sum of the distance values is the sum of the distances between the arc center coordinate and the remaining arc center coordinates;
[0024] If the weight corresponding to the arc center coordinate is inversely proportional to the sum of the corresponding distance values, the aligned center coordinate is the arc center coordinate with the largest corresponding weight among all the arc center coordinates.
[0025] As a specific solution of the technical solution of the present application, the server is further configured to traverse each B-scan image in the first alignment data to obtain a second B-scan image; the second B-scan image is any B-scan image for which the alignment degree value has not been obtained among the B-scan images;
[0026] and, based on the second B-scan image, acquiring a third B-scan image; the third B-scan image being any B-scan image intersecting with the second B-scan image among the B-scan images;
[0027] and, based on the second B-scan image and the third B-scan image, obtaining a first intersection line and a second intersection line; the first intersection line is an intersection line formed by the second B-scan image and the third B-scan image; and the second intersection line is an intersection line formed by the third B-scan image and the second B-scan image;
[0028] and, obtaining a first similarity based on the first intersection line and the second intersection line;
[0029] And, based on the first similarity, obtaining an alignment degree value corresponding to the second B-scan image.
[0030] As a specific solution in the technical solution of the present application, the server is further used to obtain a plurality of one-to-one corresponding first pixel points and second pixel points based on the first intersection line and the second intersection line; the first pixel point is a pixel point in the first intersection line; the second pixel point is a pixel point in the second intersection line;
[0031] And, based on each first pixel point and each second pixel point, obtaining a plurality of first grayscale values and a plurality of second grayscale values; the first grayscale value is the grayscale value of the corresponding first pixel point; the second grayscale value is the grayscale value of the corresponding second pixel point;
[0032] And, based on each first grayscale value and each second grayscale value, a first similarity is obtained.
[0033] As a specific solution of the technical solution of the present application, the server is further configured to obtain a fourth B-scan image based on the second B-scan image; the fourth B-scan image is any B-scan image that is adjacent to and does not intersect with the second B-scan image among the B-scan images;
[0034] and, based on the second B-scan image and the fourth B-scan image, acquiring a plurality of first distances and a plurality of second distances; the first distance being the distance from the alignment circle center coordinate to the corresponding fitted arc in the second B-scan image; and the second distance being the distance from the alignment circle center coordinate to the corresponding fitted arc in the fourth B-scan image;
[0035] and, obtaining a second similarity based on each first distance and each second distance;
[0036] And, based on the first similarity and the second similarity, an alignment degree value corresponding to the second B-scan image is obtained.
[0037] As a specific solution in the technical solution of the present application, the server is further configured to obtain a plurality of difference values based on each first distance and each second distance; the difference value is the difference between the first distance and the corresponding second distance;
[0038] And, based on each difference, the second similarity is obtained.
[0039] Compared with the prior art, the present invention has the following advantages:
[0040] This application utilizes the circular structure of the eye to perform a preliminary alignment of each B-scan image, obtaining first alignment data. Using this first alignment data, an alignment degree value is then obtained to characterize whether each B-scan image is aligned. The alignment degree value is then used to fine-tune the spatial position of each B-scan image, allowing each B-scan image to be precisely aligned, thereby obtaining second alignment data. In other words, this application uses the alignment degree value to eliminate the effects of light refraction caused by passing through different media, or jitter caused by the patient's eye movements or breathing, on the alignment of each B-scan image. In other words, this application enables precise alignment of each B-scan image. BRIEF DESCRIPTION OF THE DRAWINGS
[0041] Figure 1A schematic diagram of a process for detecting corneal damage based on anterior segment OCT proposed in an embodiment of the present application;
[0042] Figure 2 This is a schematic diagram of the structure of a corneal damage detection system based on anterior segment OCT proposed in an embodiment of the present application;
[0043] Figure 3 A schematic diagram of the spatial structure of the alignment data proposed in an embodiment of the present application;
[0044] Figure 4 This is a schematic diagram of the structure of the cornea proposed in an embodiment of the present application.
[0045] In the figure: 1. B-scan image; 3. Cornea; 31. Tear film layer; 32. Epithelial layer; 33. Descemet's membrane; 34. Stroma layer; 35. Endothelial layer; 4. Center of the eyeball. DETAILED DESCRIPTION
[0046] The following will be combined with the drawings in the embodiments of this application to clearly and completely describe the technical solutions in the embodiments of this application. Obviously, the embodiments described are only part of the embodiments of this application, not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of this application.
[0047] In the description of the embodiments of the present application and the accompanying drawings, the terms "first," "second," and the like are used to distinguish similar objects and are not necessarily used to describe a specific order or precedence. For example, the first B-scan image and the second B-scan image described below are different B-scan images. It should be understood that the terms used in this manner are interchangeable where appropriate, so that the embodiments described herein can be implemented in an order other than that illustrated or described herein. In addition, the terms "including," "having," and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, system, product, or apparatus comprising a series of steps or modules is not necessarily limited to those steps or modules explicitly listed, but may include other steps or modules not explicitly listed or inherent to such process, method, product, or apparatus. The division of modules in the embodiments of the present application is merely a logical division, and other divisions may be used in actual implementations. For example, multiple modules may be combined or integrated into another system, or some features may be omitted or not implemented. In addition, the coupling or direct coupling or communication connection between modules shown or discussed may be through some interface, and the indirect coupling or communication connection between modules may be electrical or other similar forms, which are not limited in the embodiments of the present application. Moreover, the modules or sub-modules described as separate components may or may not be physically separated, may or may not be physical modules, or may be distributed into multiple circuit modules, and some or all of the modules may be selected according to actual needs to achieve the purpose of the embodiment of the present application.
[0048] In order to solve the technical problem of difficulty in accurately matching and aligning each B-scan image in OCT three-dimensional modeling of corneal damage, this application proposes an embodiment of a corneal damage detection method based on anterior segment OCT. Figure 1 As shown, the corneal damage detection method based on anterior segment OCT includes steps S100 to S600.
[0049] Step S100: Acquire OCT scanning data of the cornea.
[0050] In this embodiment, the OCT scan data includes at least a plurality of B-scan images of the anterior segment of the cornea at different angles. The OCT scan data includes at least rotational scan data. The rotational scan data is a plurality of B-scan images acquired at different angles with the center of the eyeball as the rotation center.
[0051] Generally, OCT scans include A-scan, B-scan, and C-scan. A-scan stands for amplitude, meaning the horizontal axis of the display represents the propagation time or distance of the ultrasonic wave in the material being tested, while the vertical axis represents the amplitude of the ultrasonic reflection wave. The scanned image is displayed in two dimensions. For a B-scan, the screen displays a cross-section parallel to the direction of sound propagation and perpendicular to the workpiece's measured surface. A C-scan scans a cross-section at a specific depth. This involves moving within a two-dimensional plane and selecting signal imaging at a point at a specific depth within the A-scan, displaying defect information on the horizontal cross-section.
[0052] Obtaining OCT scan data of the cornea is a complex process involving multiple steps and equipment settings. Below I will describe in detail how to obtain OCT scan data through an OCT device, especially how to obtain B-scan images at different angles. The OCT device includes a scanning head, a probe, a display, and a computer. The scanning head is the core part of the OCT device, which is used to emit light and receive reflected light. The angle and position of the probe need to be adjusted according to the position of the eye. The OCT device displays the scan results in real time through a computer, and the doctor views the structure of the cornea through the image on the display. In a specific embodiment of the present application, step S100, obtaining OCT scan data of the cornea, includes steps S110 to S130.
[0053] Step S110: Determine the patient's position; the patient usually needs to sit in front of the OCT device with the head placed on a bracket to ensure that the head is stable to prevent movement from affecting image quality.
[0054] Step S120: Patient eye preparation: For the eye being examined, anesthetic eye drops (e.g., benzocaine) are usually used to reduce discomfort during corneal scanning, and mydriatic agents (e.g., tropicamide) may be used to dilate the pupil so that the scanning device can better acquire an image of the cornea.
[0055] Step S130: Obtain corneal OCT scanning data.
[0056] Specifically, step S130, obtaining OCT scanning data of the cornea, includes steps S131 to S133.
[0057] Step S131: Anterior surface scanning: The anterior surface of the cornea (i.e., the outermost layer of the cornea) is scanned using the OCT device. This scan is typically performed through the center of the eye, with the beam irradiating the eye perpendicularly to obtain an image of the anterior surface.
[0058] Step S132: Posterior surface scanning: The OCT device's probe can scan the posterior surface of the cornea (located between the corneal stroma and the aqueous humor). This scan is crucial for assessing the thickness and structure of the cornea's various layers.
[0059] Step S133: Rotational scanning at different angles. Rotational scanning is used to obtain corneal cross-sectional images around the center of the eyeball. The device rotates the probe horizontally or vertically to provide images of different sections of the cornea.
[0060] Step S200: Acquire first alignment data based on each B-scan image.
[0061] In this embodiment, the first alignment data is three-dimensional data formed by directly aligning and splicing the B-scan images.
[0062] It should be understood that, when the prior art obtains three-dimensional corneal data (i.e., a three-dimensional model of the cornea) through OCT scanning data of the cornea, it is necessary to align the various B-scan images obtained at different angles to obtain alignment data (i.e., first alignment data); further, by fitting the grayscale changes of the alignment data, a densely distributed three-dimensional point cloud or data array can be obtained, and voxel modeling of the obtained three-dimensional point cloud or data array can be performed to obtain three-dimensional corneal data. This is a mature technology and will not be elaborated here.
[0063] In the embodiment of the present application, any reasonable method can be used to obtain the first alignment data based on each B-scan image. For example, step S200, obtaining the first alignment data based on each B-scan image, includes steps S210 to S260.
[0064] Step S210: traverse each B-scan image to obtain a first B-scan image.
[0065] In this embodiment, the first B-scan image is any B-scan image for which the arc center coordinates have not been obtained. That is, in this embodiment, the method for obtaining the arc center coordinates of any B-scan image is the same as the method for obtaining the arc center coordinates of the first B-scan image.
[0066] Step S220: Obtain an edge detection image from the first B-scan image based on an edge detection algorithm.
[0067] It should be understood that obtaining an edge detection image of an image (i.e., the first B-scan image) based on an edge detection algorithm is a mature technology and will not be elaborated on here. An edge detection algorithm is a computational method for identifying the boundaries (edges) of objects in digital images. Its core goal is to locate locations in an image where significant mutations occur in pixel grayscale, color, or texture. These locations typically correspond to areas where object contours, surface orientation changes, or scene depth discontinuities. In an embodiment of the present application, the edge detection algorithm may be any algorithm that can obtain an edge detection image from the first B-scan image. For example, the edge detection algorithm may be a Prewitt algorithm, a Sobel algorithm, a Laplacian algorithm, and a Canny algorithm.
[0068] Step S230: obtaining a plurality of fitting arcs from the edge detection image based on an arc fitting algorithm.
[0069] It should be understood that obtaining multiple fitted arcs from an edge detection image based on an arc fitting algorithm is a mature technology and will not be elaborated here. The arc fitting algorithm is a numerical calculation method for identifying and reconstructing the optimal arc geometric model from a discrete point set (e.g., an edge detection image). Its core goal is to find the arc parameters (center, radius) that best match the scattered point distribution through mathematical optimization. It is often used to recover smooth circular structures from noisy data. In an embodiment of the present application, the arc fitting algorithm can be any algorithm that can obtain multiple fitted arcs from the edge detection image. For example, the arc fitting algorithm can be a least squares algorithm or an average value algorithm.
[0070] It should be noted that the human eyeball is similar to a sphere. Generally, the structure of the cornea is as follows Figure 4 As shown, the cornea 3 sequentially comprises a tear film layer 31, an epithelial layer 32, a Bowman's membrane 33, a stroma 34, and an endothelial layer 35. Because the human eyeball is spherical, the centers of the arcs formed between the layers of the cornea 3 are all close to the center point 4 of the eyeball. As previously mentioned, each B-scan image is acquired around the center of the patient's eyeball. Therefore, in this embodiment, the B-scan images can be aligned using the centers of the circles formed by the layers of the cornea 3 (also referred to as alignment center coordinates below), thereby obtaining first alignment data.
[0071] Step S240: Based on each fitted arc, obtain a plurality of arc center coordinates corresponding one-to-one to the fitted arc.
[0072] It should be clear that obtaining the coordinates of the center of any fitted arc based on the arc fitting algorithm is a mature technology and will not be described in detail here.
[0073] Step S250: Based on the coordinates of the centers of the arcs, the coordinates of the alignment centers are obtained.
[0074] In the embodiments of the present application, any reasonable method can be used to obtain the alignment center coordinates based on the center coordinates of each arc. For example, the alignment center coordinates can be obtained as shown in the first and second embodiments.
[0075] Example 1 of obtaining the coordinates of the center of the alignment circle
[0076] In this embodiment, step S250, based on the coordinates of the centers of the arcs, obtains the coordinates of the center of the alignment circle, including step S251.
[0077] Step S251: the center coordinates of the aligned circles are the average values of the center coordinates of the arcs.
[0078] Specifically, in step S251, the calculation formula for the alignment center coordinates to be the average value of the center coordinates of each arc is as follows:
[0079]
[0080]
[0081] in, Indicates the horizontal coordinate value corresponding to the center of the aligned circle; Indicates the vertical coordinate value corresponding to the center of the aligned circle; n indicates the number of centers of each arc; Indicates the horizontal coordinate value corresponding to the center of the i-th arc; Indicates the vertical coordinate value corresponding to the center of the i-th arc.
[0082] In this embodiment, if a layer of the cornea 3 is diseased or deformed, that is, if the coordinates of the center of a corresponding arc are inaccurate, then the alignment center coordinates obtained based on the above calculation formula will be inaccurate. If the alignment center coordinates are inaccurate, then the first alignment data obtained in step S260 will also be inaccurate, that is, the B-scan images in the first alignment data will not be accurately aligned. Based on this, the acquisition of the alignment center coordinates can refer to Example 2.
[0083] Example 2 of Obtaining Alignment Circle Center Coordinates
[0084] In this embodiment, step S250, based on the coordinates of the centers of the arcs, obtains the coordinates of the center of the alignment circle, including step S252 and step S253.
[0085] Step S252: Based on the coordinates of the centers of the arcs, obtain the weights corresponding to the coordinates of the centers of the arcs.
[0086] In this embodiment, the weight is used to at least characterize the distance between the corresponding arc center coordinate and the coordinates of the centers of the remaining arcs. It is easy to understand that under normal circumstances, the centers (i.e., the arc center coordinates) corresponding to the arcs formed by the various layers of the cornea 3 in the B-scan image are always close to each other. If the center coordinate of a particular arc is far away from the center coordinates of the remaining arcs, then the arc center coordinate is either not the center coordinate corresponding to the layers of the cornea 3, or the layer corresponding to the arc center coordinate is deformed or has a disease. In other words, when obtaining the aligned center coordinates, arc center coordinates that differ significantly from the center coordinates of the individual arcs can be ignored or given less consideration.
[0087] In an embodiment of the present application, step S252: based on the coordinates of the centers of the arcs, a calculation formula (hereinafter referred to as the first formula) for obtaining the weight corresponding to the coordinates of the centers of the arcs can be as follows:
[0088]
[0089] Where n represents the number of centers of each arc; Represents the weight corresponding to the center of the t-th arc, t is greater than or equal to 1 and less than or equal to n; Indicates the horizontal coordinate corresponding to the center of the t-th arc; Indicates the vertical coordinate corresponding to the center of the t-th arc; Indicates the horizontal coordinate corresponding to the center of the i-th arc; represents the ordinate corresponding to the center of the i-th arc; a represents a first constant, which is any positive number greater than 0 and can be set as needed. In this embodiment, the closer the center of the t-th arc is to the centers of the remaining arcs, the greater its corresponding weight; the farther the center of the t-th arc is from the centers of the remaining arcs, the smaller its corresponding weight.
[0090] Of course, in other embodiments of the present application, the closer the distance between the center of the t-th arc and the centers of the other arcs, the smaller the corresponding weight; and the farther the distance between the center of the t-th arc and the centers of the other arcs, the larger the corresponding weight. This is not listed here. In the subsequent embodiments of the present application, the weights corresponding to the first formula are used to illustrate the various embodiments of the present application. This does not mean that the calculation method of the weights of the present application can only be the first formula.
[0091] Step S253: Based on each weight and each arc center coordinate, the alignment center coordinate is obtained.
[0092] In an embodiment of the present application, any reasonable method can be used to obtain the alignment center coordinates based on the weights and the center coordinates of each arc. For example, the center coordinates of several arcs with larger weights can be selected, and then the alignment center coordinates can be obtained by calculating the average of these arc center coordinates. In another embodiment of the present application, step S253, obtaining the alignment center coordinates based on the weights and the center coordinates of each arc, includes steps S254 and S255.
[0093] Step S254: If the weight corresponding to the arc center coordinate is proportional to the sum of the corresponding distance values, the aligned center coordinate is the arc center coordinate with the smallest corresponding weight among all the arc center coordinates.
[0094] In this embodiment, the sum of the distance values is the sum of the distances between the coordinates of the center of the arc and the coordinates of the centers of the other arcs.
[0095] Step S255: If the weight corresponding to the arc center coordinate is inversely proportional to the sum of the corresponding distance values, the aligned center coordinate is the arc center coordinate with the largest corresponding weight among all the arc center coordinates.
[0096] It can be seen from step S254 and step S255 that in this embodiment, the arc center coordinates that are closest to the arc center coordinates can be selected as the alignment center coordinates.
[0097] Step S260: Based on the alignment circle center coordinates, align the first B-scan image with the remaining B-scan images to obtain the first alignment data.
[0098] As mentioned above, each B-scan image is a B-scan image formed at various angles around the center of the eyeball. In this embodiment, the alignment circle center coordinates corresponding to each B-scan image (i.e., the first B-scan image) are close to the eyeball center point 4 in three-dimensional space. Based on this, each B-scan image 1 is aligned by aligning the circle center coordinates (i.e., the default is the eyeball center point 4), and the first alignment data obtained is as follows: Figure 3 shown.
[0099] As can be seen from the background art, the first alignment data obtained through the above steps is not completely accurate. For example, light refraction when passing through different media, or vibrations caused by the patient's eye movements or breathing can cause scan line misalignment, resulting in alignment errors in the B-scan images. This means that the B-scan images are not accurately aligned. If the B-scan images are not accurately aligned, it is impossible to subsequently obtain an accurate three-dimensional model of the cornea. In this embodiment, step S300 must be performed to subsequently obtain an accurate three-dimensional model of the cornea.
[0100] Step S300: Acquire multiple alignment degree values based on the first alignment data.
[0101] In this embodiment, the alignment degree values correspond to the B-scan images in a one-to-one manner, and are used to at least represent the degree of alignment between the corresponding B-scan image and the remaining B-scan images.
[0102] In an embodiment of the present application, any reasonable method can be used to obtain multiple alignment values based on the first alignment data. For example, step S300, obtaining multiple alignment values based on the first alignment data, includes steps S310 to S350.
[0103] Step S310: traverse each B-scan image in the first alignment data to obtain a second B-scan image.
[0104] In this embodiment, the second B-scan image is any B-scan image for which no alignment value has been obtained. That is, in this embodiment, the alignment value corresponding to any B-scan image is obtained in the same manner as the alignment value corresponding to the second B-scan image.
[0105] Step S320: Acquire a third B-scan image based on the second B-scan image.
[0106] In this embodiment, the third B-scan image is any B-scan image among the B-scan images that intersects with the second B-scan image.
[0107] It is easy to understand that since the second B-scan image and the third B-scan image intersect, if the second B-scan image and the third B-scan image are aligned, then the intersection lines formed between the second B-scan image and the third B-scan image are very similar. In other words, whether the second B-scan image and the third B-scan image are aligned can be determined based on the similarity between the intersection lines.
[0108] Step S330: Acquire a first intersection line and a second intersection line based on the second B-scan image and the third B-scan image.
[0109] In this embodiment, the first intersection line is an intersection line formed by the second B-scan image and the third B-scan image, and the second intersection line is an intersection line formed by the third B-scan image and the second B-scan image.
[0110] Step S340: Obtain a first similarity based on the first intersection line and the second intersection line.
[0111] It should be understood that obtaining the similarity (ie, the first similarity) between two images or two lines (ie, the first intersection line and the second intersection line) is a mature technology in the technical field of image processing and will not be elaborated here.
[0112] In a specific embodiment of the present application, step S340, obtaining a first similarity based on the first intersection line and the second intersection line, includes steps S341 to S343.
[0113] Step S341: Based on the first intersection line and the second intersection line, obtain a plurality of one-to-one corresponding first pixel points and second pixel points.
[0114] In this embodiment, the first pixel point is a pixel point on the first intersection line, and the second pixel point is a pixel point on the second intersection line.
[0115] Step S342: Based on each first pixel point and each second pixel point, obtain a plurality of first grayscale values and a plurality of second grayscale values.
[0116] In this embodiment, the first grayscale value is the grayscale value of the corresponding first pixel, and the second grayscale value is the grayscale value of the corresponding second pixel.
[0117] Step S343: Obtain a first similarity based on each first grayscale value and each second grayscale value.
[0118] Specifically, in step S343, based on each first grayscale value and each second grayscale value, a calculation formula for obtaining a first similarity is as follows:
[0119]
[0120] in, represents the first similarity; represents the number of first grayscale values (that is, the number of second grayscale values); represents the kth first grayscale value, where k is greater than or equal to 1 and less than or equal to m; represents the kth second grayscale value; Indicates the absolute value; represents a second constant, which is any positive number greater than 0 and can be set as required. In this embodiment, the smaller the difference in grayscale values corresponding to the pixels in the first intersection line and the second intersection line, the greater the first similarity.
[0121] Step S350: Based on the first similarity, obtaining an alignment degree value corresponding to the second B-scan image.
[0122] In an embodiment of the present application, the alignment value corresponding to the second B-scan image can be obtained based on the first similarity in any reasonable manner. For example, the alignment value corresponding to the second B-scan image can be obtained by taking the average of multiple first similarities corresponding to the second B-scan image.
[0123] In order to further obtain the precise alignment value corresponding to the second B-scan image, in one embodiment of the present application, step S350 obtains the alignment value corresponding to the second B-scan image based on the first similarity, including steps S351 to S354.
[0124] Step S351: Acquire a fourth B-scan image based on the second B-scan image.
[0125] In this embodiment, the fourth B-scan image is any B-scan image among the B-scan images that is adjacent to and does not intersect with the second B-scan image.
[0126] Step S352: Acquire a plurality of first distances and a plurality of second distances based on the second B-scan image and the fourth B-scan image.
[0127] In this embodiment, the first distance is the distance from the alignment circle center coordinate to the corresponding fitted arc in the second B-scan image. The second distance is the distance from the alignment circle center coordinate to the corresponding fitted arc in the fourth B-scan image. As previously mentioned, the cornea has a layered sandwich structure. If the second B-scan image has been aligned, the distances between the alignment circle center coordinates in each layer of the second B-scan image and the fourth B-scan image should be similar.
[0128] Step S353: Obtain a second similarity based on each first distance and each second distance.
[0129] In the embodiment of the present application, any reasonable method can be used to obtain the second similarity based on each first distance and each second distance. For example, step S353, obtaining the second similarity based on each first distance and each second distance, includes steps S353a and S353b.
[0130] Step S353a: Acquire multiple difference values based on each first distance and each second distance.
[0131] In this embodiment, the difference is the difference between the first distance and the corresponding second distance.
[0132] Step S353b: Based on each difference, obtain the second similarity.
[0133] Specifically, in step S353b, based on each difference, a calculation formula for obtaining the second similarity may be as follows:
[0134]
[0135] in, represents the second similarity; d represents the number of first distances (that is, the number of second distances); represents the fth first distance, where f is greater than or equal to 1 and less than or equal to d; represents the fth second distance; Indicates the absolute value; represents a third constant, which is any positive number greater than 0 and can be set as needed. In this embodiment, the smaller the difference between each first distance and each second distance, the higher the degree of alignment between the second B-scan image and the fourth B-scan image.
[0136] Step S354: Based on the first similarity and the second similarity, obtaining an alignment degree value corresponding to the second B-scan image.
[0137] In an embodiment of the present application, the alignment value corresponding to the second B-scan image can be obtained based on the first similarity and the second similarity in any reasonable manner. For example, the alignment value corresponding to the second B-scan image can be the product or sum of the first similarity and the second similarity.
[0138] In a specific embodiment of the present application, in step S354, a calculation formula for obtaining an alignment value corresponding to the second B-scan image based on the first similarity and the second similarity is as follows:
[0139]
[0140] in, represents the alignment value corresponding to the second B-scan image; represents an average value of each first similarity corresponding to the second B-scan image; represents an average value of each second similarity corresponding to the second B-scan image; Represents a normalization function, which is used to normalize the values in the brackets to the range of [0, 1].
[0141] Step S400: Based on the respective alignment degree values, the spatial position of each B-scan image in the first alignment data is adjusted to obtain second alignment data.
[0142] In this embodiment, the alignment values corresponding to any B-scan image in the second alignment data are all greater than or equal to a preset value. The preset value can be set as needed, for example, 0.5 or 0.6. It should be understood that finding the optimal solution for stitching and aligning individual B-scan images (i.e., ensuring that the alignment value of each B-scan image is greater than or equal to the preset value) is a mature technology in the computer field and will not be elaborated on here.
[0143] Step S500: constructing voxel information based on the second alignment data.
[0144] It should be understood that in the technical field of constructing a three-dimensional corneal model, constructing voxel information based on alignment data (ie, second alignment data) is a mature technology and will not be elaborated here.
[0145] Step S600: Acquire three-dimensional data of the cornea based on the voxel information.
[0146] It should be understood that in the technical field of constructing a three-dimensional corneal model, obtaining three-dimensional corneal data based on voxel information is also a mature technology and will not be elaborated here.
[0147] The embodiment of a corneal damage detection method based on anterior segment OCT proposed in the present application utilizes the circular structure of the eye to preliminarily align each B-scan image to obtain the first alignment data. Then, through the first alignment data, an alignment degree value that can characterize whether each B-scan image is aligned is obtained, and the spatial position of each B-scan image is fine-tuned by the alignment degree value, so that each B-scan image can be accurately aligned, and then the second alignment data is obtained. In other words, the present application can eliminate the influence of refraction of light passing through different media, or the influence of jitter caused by slight movement of the patient's eyeball or breathing on the alignment of each B-scan image through the alignment degree value. In other words, the corneal damage detection method based on anterior segment OCT proposed in the present application can accurately align each B-scan image.
[0148] After introducing a corneal injury detection method based on anterior segment OCT proposed in an embodiment of the present application, the following introduces a corneal injury detection system based on anterior segment OCT proposed in an embodiment of the present application. Figure 2 As shown, the corneal damage detection system 10 based on anterior segment OCT includes:
[0149] An OCT device 11 is configured to acquire OCT scan data of the cornea; the OCT scan data at least includes a plurality of B-scan images of the anterior segment OCT of the cornea at different angles;
[0150] The server 12 is configured to obtain first alignment data based on each B-scan image; the first alignment data is three-dimensional data formed by directly aligning and splicing each B-scan image;
[0151] and, based on the first alignment data, obtaining a plurality of alignment values; the alignment values corresponding to the B-scan images one-to-one; the alignment values being used to at least represent the degree of alignment between the corresponding B-scan image and the remaining B-scan images;
[0152] and, based on the respective alignment degree values, adjusting the spatial position of each B-scan image in the first alignment data to obtain second alignment data; wherein the alignment degree value corresponding to any B-scan image in the second alignment data is greater than or equal to a preset value;
[0153] and, constructing voxel information based on the second alignment data;
[0154] And, based on the voxel information, three-dimensional data of the cornea is acquired.
[0155] As a specific embodiment of the present application, the OCT scanning data at least includes rotation scanning data; the rotation scanning data is a plurality of B-scan images at different angles obtained with the center point of the eyeball as the rotation center.
[0156] As a specific embodiment of the present application, the server 12 is further configured to traverse each B-scan image to obtain a first B-scan image; the first B-scan image is any B-scan image for which the coordinates of the arc center are not obtained among the B-scan images;
[0157] and, obtaining an edge detection image from the first B-scan image based on an edge detection algorithm;
[0158] and obtaining a plurality of fitting arcs from the edge detection image based on an arc fitting algorithm;
[0159] and, based on each fitted arc, obtaining a plurality of arc center coordinates corresponding one-to-one to the fitted arc;
[0160] and, based on the coordinates of the centers of the respective arcs, obtaining the coordinates of the center of the aligned circle;
[0161] And, based on the alignment circle center coordinates, align the first B-scan image with the remaining B-scan images to obtain the first alignment data.
[0162] As a specific embodiment of the present application, the server 12 obtains the alignment center coordinates based on the center coordinates of each arc, including: the alignment center coordinates are the average value of the center coordinates of each arc.
[0163] As a specific embodiment of the present application, the server 12 is further configured to obtain a weight corresponding to each arc center coordinate based on each arc center coordinate; the weight is at least used to represent the distance between the corresponding arc center coordinate and the remaining arc center coordinates;
[0164] And, based on each weight and each arc center coordinate, the alignment center coordinate is obtained.
[0165] As a specific embodiment of the present application, the server 12 is further configured to: if the weight corresponding to the arc center coordinate is proportional to the sum of the corresponding distance values, then the aligned center coordinate is the arc center coordinate with the smallest corresponding weight among the arc center coordinates; and the sum of the distance values is the sum of the distances between the arc center coordinate and the remaining arc center coordinates;
[0166] If the weight corresponding to the arc center coordinate is inversely proportional to the sum of the corresponding distance values, the aligned center coordinate is the arc center coordinate with the largest corresponding weight among all the arc center coordinates.
[0167] As a specific embodiment of the present application, the server 12 is further configured to traverse each B-scan image in the first alignment data to obtain a second B-scan image; the second B-scan image is any B-scan image for which the alignment degree value has not been obtained among the B-scan images;
[0168] and, based on the second B-scan image, acquiring a third B-scan image; the third B-scan image being any B-scan image intersecting with the second B-scan image among the B-scan images;
[0169] and, based on the second B-scan image and the third B-scan image, obtaining a first intersection line and a second intersection line; the first intersection line is an intersection line formed by the second B-scan image and the third B-scan image; and the second intersection line is an intersection line formed by the third B-scan image and the second B-scan image;
[0170] and, obtaining a first similarity based on the first intersection line and the second intersection line;
[0171] And, based on the first similarity, obtaining an alignment degree value corresponding to the second B-scan image.
[0172] As a specific embodiment of the present application, the server 12 is further configured to obtain a plurality of one-to-one corresponding first pixel points and second pixel points based on the first intersection line and the second intersection line; the first pixel point is a pixel point in the first intersection line; the second pixel point is a pixel point in the second intersection line;
[0173] And, based on each first pixel point and each second pixel point, obtaining a plurality of first grayscale values and a plurality of second grayscale values; the first grayscale value is the grayscale value of the corresponding first pixel point; the second grayscale value is the grayscale value of the corresponding second pixel point;
[0174] And, based on each first grayscale value and each second grayscale value, a first similarity is obtained.
[0175] As a specific embodiment of the present application, the server 12 is further configured to obtain a fourth B-scan image based on the second B-scan image; the fourth B-scan image is any B-scan image that is adjacent to and does not intersect with the second B-scan image among the B-scan images;
[0176] and, based on the second B-scan image and the fourth B-scan image, acquiring a plurality of first distances and a plurality of second distances; the first distance being the distance from the alignment circle center coordinate to the corresponding fitted arc in the second B-scan image; and the second distance being the distance from the alignment circle center coordinate to the corresponding fitted arc in the fourth B-scan image;
[0177] and, obtaining a second similarity based on each first distance and each second distance;
[0178] And, based on the first similarity and the second similarity, an alignment degree value corresponding to the second B-scan image is obtained.
[0179] As a specific embodiment of the present application, the server 12 is further configured to obtain a plurality of difference values based on each first distance and each second distance; the difference value is a difference between a first distance and a corresponding second distance;
[0180] And, based on each difference, the second similarity is obtained.
[0181] The embodiment of a corneal damage detection system based on anterior segment OCT proposed in the present application utilizes the circular structure of the eye to preliminarily align each B-scan image to obtain the first alignment data. Then, through the first alignment data, an alignment degree value is obtained that can characterize whether each B-scan image is aligned, and the spatial position of each B-scan image is fine-tuned by the alignment degree value, so that each B-scan image can be accurately aligned, and then the second alignment data is obtained. In other words, the present application can eliminate the influence of refraction of light passing through different media, or the influence of jitter caused by slight movement of the patient's eyeball or breathing on the alignment of each B-scan image through the alignment degree value. In other words, the corneal damage detection system based on anterior segment OCT proposed in the present application can accurately align each B-scan image.
[0182] It should be understood that computer-readable storage media in this application include permanent and non-permanent, removable and non-removable media that can be used to store information by any method or technology. The information can be computer-readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory, static random access memory, dynamic random access memory, other types of random access memory, read-only memory, electrically erasable programmable read-only memory, flash memory or other memory technology, read-only compact disc read-only memory, digital versatile disc or other optical storage, magnetic cassettes, disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined herein, computer-readable media does not include temporary computer-readable media such as modulated data signals and carrier waves.
[0183] In the above embodiments, the description of each embodiment has its own focus. For parts that are not described in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0184] Those skilled in the art will clearly understand that, for the convenience and brevity of description, the specific working processes of the methods, devices and equipment described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0185] In the several embodiments provided in the embodiments of the present application, it should be understood that the disclosed devices, apparatuses and methods can be implemented in other ways. For example, the device embodiments described above are merely schematic. For example, the division of the modules is merely a logical function division. In actual implementation, there may be other division methods, such as multiple modules or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or modules, which can be electrical, mechanical or other forms.
[0186] The modules described as separate components may or may not be physically separate, and the components shown as modules may or may not be physical modules, that is, they may be located in one place or distributed across multiple network modules. Some or all of the modules may be selected to achieve the purpose of the present embodiment according to actual needs.
[0187] In addition, the functional modules in each embodiment of the present application can be integrated into a processing module, or each module can exist physically separately, or two or more modules can be integrated into a module. The above-mentioned integrated modules can be implemented in the form of hardware or in the form of software functional modules. If the integrated modules are implemented in the form of software functional modules and sold or used as independent products, they can be stored in a computer-readable storage medium.
[0188] In the above embodiments, all or part of the embodiments may be implemented by software, hardware, firmware, or any combination thereof. When implemented by software, all or part of the embodiments may be implemented in the form of a computer program product.
[0189] The computer program product includes one or more computer instructions. When the computer program is loaded and executed on a computer, the processes or functions described in accordance with the embodiments of the present application are fully or partially generated. The computer may be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions may be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another. For example, the computer instructions may be transmitted from one website, computer, server, or data center to another website, computer, server, or data center via a wired (e.g., coaxial cable, optical fiber, digital subscriber line) or wireless (e.g., infrared, wireless, microwave, etc.) method. The computer-readable storage medium may be any available medium that can be stored on a computer or a data storage device such as a server or data center that integrates one or more available media. The available medium may be a magnetic medium (e.g., a floppy disk, hard disk, or magnetic tape), an optical medium (e.g., a digital versatile disk), or a semiconductor medium (e.g., a solid-state drive (SSD)).
[0190] Although the embodiments of the present application have been shown and described, it will be appreciated by those skilled in the art that many changes, modifications, substitutions, and alterations may be made to these embodiments without departing from the principles of the present application.
Claims
1. A corneal damage detection system based on anterior segment OCT, characterized in that: include: An OCT device is used to obtain OCT scanning data of the cornea; the OCT scanning data at least includes a plurality of B-scan images of the anterior segment OCT of the cornea at different angles; The server is configured to obtain first alignment data based on each B-scan image; the first alignment data is three-dimensional data formed by directly aligning and splicing each B-scan image; and, based on the first alignment data, obtaining a plurality of alignment degree values; The alignment degree values correspond one-to-one to the B-scan images; The alignment degree value is at least used to represent the degree of alignment between the corresponding B-scan image and the remaining B-scan images; and, based on the respective alignment degree values, adjusting the spatial position of each B-scan image in the first alignment data to obtain second alignment data; The alignment degree value corresponding to any B-scan image in the second alignment data is greater than or equal to a preset value; and, constructing voxel information based on the second alignment data; And, based on the voxel information, three-dimensional data of the cornea is acquired.
2. The corneal damage detection system based on anterior segment OCT according to claim 1, characterized in that: The OCT scanning data at least includes rotation scanning data; the rotation scanning data is a plurality of B-scan images at different angles acquired with the center point of the eyeball as the rotation center.
3. The corneal damage detection system based on anterior segment OCT according to claim 1, characterized in that: The server is further configured to traverse each B-scan image to obtain a first B-scan image; the first B-scan image is any B-scan image for which the coordinates of the arc center are not obtained among the B-scan images; and, obtaining an edge detection image from the first B-scan image based on an edge detection algorithm; and obtaining a plurality of fitting arcs from the edge detection image based on an arc fitting algorithm; and, based on each fitted arc, obtaining a plurality of arc center coordinates corresponding one-to-one to the fitted arc; and, based on the coordinates of the centers of the respective arcs, obtaining the coordinates of the center of the aligned circle; And, based on the alignment circle center coordinates, align the first B-scan image with the remaining B-scan images to obtain the first alignment data.
4. The corneal damage detection system based on anterior segment OCT according to claim 3, characterized in that: The server obtains the alignment center coordinates based on the center coordinates of each arc, including: the alignment center coordinates are the average value of the center coordinates of each arc.
5. The corneal damage detection system based on anterior segment OCT according to claim 3, characterized in that: The server is further configured to obtain a weight corresponding to each arc center coordinate based on each arc center coordinate; the weight is at least used to represent the distance between the corresponding arc center coordinate and the remaining arc center coordinates; And, based on each weight and each arc center coordinate, the alignment center coordinate is obtained.
6. The corneal damage detection system based on anterior segment OCT according to claim 5, characterized in that: The server is further configured to, if the weight corresponding to the arc center coordinate is proportional to the sum of the corresponding distance values, then the aligned center coordinate is the arc center coordinate with the smallest corresponding weight among the arc center coordinates; and the sum of the distance values is the sum of the distances between the arc center coordinate and the remaining arc center coordinates; If the weight corresponding to the arc center coordinate is inversely proportional to the sum of the corresponding distance values, the aligned center coordinate is the arc center coordinate with the largest corresponding weight among all the arc center coordinates.
7. The corneal damage detection system based on anterior segment OCT according to claim 6, characterized in that: The server is further configured to traverse each B-scan image in the first alignment data to obtain a second B-scan image; the second B-scan image is any B-scan image for which no alignment value has been obtained among the B-scan images; and, based on the second B-scan image, acquiring a third B-scan image; the third B-scan image being any B-scan image intersecting with the second B-scan image among the B-scan images; and, acquiring a first intersection line and a second intersection line based on the second B-scan image and the third B-scan image; The first intersection line is an intersection line formed by the second B-scan image and the third B-scan image; The second intersection line is an intersection line formed in the third B-scan image and the second B-scan image; and, obtaining a first similarity based on the first intersection line and the second intersection line; And, based on the first similarity, obtaining an alignment degree value corresponding to the second B-scan image.
8. The corneal damage detection system based on anterior segment OCT according to claim 7, characterized in that: The server is further configured to obtain a plurality of one-to-one corresponding first pixel points and second pixel points based on the first intersection line and the second intersection line; the first pixel points are pixel points in the first intersection line; and the second pixel points are pixel points in the second intersection line; And, based on each first pixel point and each second pixel point, obtaining a plurality of first grayscale values and a plurality of second grayscale values; the first grayscale value is the grayscale value of the corresponding first pixel point; the second grayscale value is the grayscale value of the corresponding second pixel point; And, based on each first grayscale value and each second grayscale value, a first similarity is obtained.
9. The corneal damage detection system based on anterior segment OCT according to claim 7, characterized in that: The server is further configured to obtain a fourth B-scan image based on the second B-scan image; the fourth B-scan image being any B-scan image that is adjacent to and does not intersect with the second B-scan image among the B-scan images; and, based on the second B-scan image and the fourth B-scan image, acquiring a plurality of first distances and a plurality of second distances; the first distance being the distance from the alignment circle center coordinate to the corresponding fitted arc in the second B-scan image; and the second distance being the distance from the alignment circle center coordinate to the corresponding fitted arc in the fourth B-scan image; and, obtaining a second similarity based on each first distance and each second distance; And, based on the first similarity and the second similarity, obtaining an alignment degree value corresponding to the second B-scan image.
10. The corneal damage detection system based on anterior segment OCT according to claim 9, characterized in that: The server is further configured to obtain a plurality of difference values based on each first distance and each second distance; the difference value is a difference between a first distance and a corresponding second distance; And, based on each difference, the second similarity is obtained.