A method, apparatus, medium, and product for retinal vessel grading and diameter measurement
By segmenting blood vessels and extracting the centerline from retinal images, the system automatically identifies the origin of blood vessels and traverses the bifurcation points along the centerline. Based on the diameter relationship, it classifies and segments the vessels, solving the problems of strong human subjectivity and inaccurate measurement in existing retinal vessel measurement methods. This achieves automated and structured blood vessel diameter measurement.
Patent Information
- Application Number
- CN202611344269.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-09-01
- Publication Date
- 2026-11-24
AI Technical Summary
Existing methods for measuring retinal vessel diameter rely on manual operation, which is highly subjective, inefficient, difficult to automate grading and segmentation, and inaccurate in cases of vessel rupture or cavitation.
By segmenting blood vessels and extracting the centerline from retinal images, the origin of blood vessels is identified, and the bifurcation points are automatically traversed along the centerline of the blood vessels. The vessels are then graded and segmented according to their diameters, and a structured recording method is used.
It enables automated grading and segmented measurement of retinal vessels, reducing manual intervention and improving the accuracy and consistency of measurements, making it suitable for large-scale fundus screening and clinical research.
Smart Images

Figure CN123160602A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of image segmentation, and in particular to a method, device, medium, and product for retinal vessel grading and diameter measurement. Background Technology
[0002] The fundus is one of the few parts of the human body where the microvascular structure can be directly observed non-invasively. The morphological characteristics of retinal arteries and veins can reflect local eye diseases and the state of the systemic vascular system. Parameters such as retinal vessel diameter, bifurcation structure, vessel course, and vessel grade distribution are closely related to hypertension, diabetes, arteriosclerosis, cardiovascular and cerebrovascular diseases, and other fundus lesions. Therefore, accurate, stable, and automated measurement of retinal vessel diameter, and further recording of diameter information for different quadrants, vessel types, and graded vessels, is of great value for quantitative analysis of fundus images, disease screening, disease follow-up, and clinical research.
[0003] Currently, retinal vessel diameter measurement typically relies on manual or semi-automatic methods. For example, the operator needs to manually select the target vessel segment, mark the vessel boundary or centerline in the fundus image, and then the software calculates the vessel diameter at the specified location or within a specified area. This type of method has the following shortcomings: First, manual selection of vessel segments and measurement locations is highly subjective, resulting in poor consistency among different operators; second, manual measurement is inefficient and difficult to apply to large-scale fundus screening or large-sample clinical studies; third, existing methods usually only measure local vessel segments, making it difficult to systematically record the hierarchical relationship of vessel branches starting from the optic disc edge; fourth, although some methods can obtain vessel segmentation maps or centerline maps, they lack a mechanism to automatically determine the extension and branching levels of the main trunk based on vessel bifurcation points, making it difficult to generate structured primary, secondary, and tertiary vessel diameter measurement results; fifth, for cases such as vessel rupture, cavitation, noise, intersections, and pseudo-branches, existing methods are prone to causing discontinuities in the centerline, misjudgment of bifurcation points, or incorrect segmentation of vessel segments, thus affecting the accuracy and repeatability of diameter measurement.
[0004] Existing retinal vessel image processing solutions typically involve segmenting the retinal image into vessels, obtaining the vessel image, extracting the vessel centerline, and further identifying the target vessel or calculating vessel morphological parameters. However, current technology cannot fully address the technical challenge of "automatically traversing the bifurcation structure along the vessel centerline from the optic disc edge, determining the main trunk extension and branch levels based on vessel diameter relationships, and ultimately generating structured vessel diameter measurement results organized by quadrant, arterial / venous type, vessel level, origin coordinates, and vessel segment number."
[0005] Therefore, there is an urgent need to propose a new method for retinal vessel grading and diameter measurement to achieve automated grading, segmentation, diameter measurement, and structured recording of retinal arteries and veins. Summary of the Invention
[0006] The purpose of this application is to provide a method, device, medium, and product for retinal vessel grading and diameter measurement, which can solve the problems of excessive manual intervention, strong subjectivity, low efficiency, difficulty in automatically determining the branch level of vessels, lack of structured recording of measurement results, and inaccurate measurement of center line and diameter due to vessel rupture or cavities in the existing retinal vessel diameter measurement process.
[0007] To achieve the above objectives, this application provides the following solution: In a first aspect, this application provides a method for retinal vessel grading and diameter measurement, including: A retinal image to be processed is acquired, and blood vessel segmentation and blood vessel centerline extraction are performed on the retinal image to obtain a binary image of blood vessels and a binary image of blood vessels; the binary image of blood vessels includes a binary image of retinal arteries and a binary image of retinal veins; the binary image of blood vessels includes a binary image of arterial blood vessels and a binary image of venous blood vessels. The starting point of the main blood vessel is determined based on the edge of the optic disc. Starting from the starting point, the image of the blood vessel centerline is traversed to identify the bifurcation points of all blood vessels along the blood vessel path in sequence. At each bifurcation point, the diameter of the main vessel before bifurcation and the diameters of the two branch vessels after bifurcation are calculated respectively. Based on the diameter relationship between the two branch vessels after the bifurcation, the branch vessel with the larger diameter is regarded as an extension of the main trunk vessel, and the branch vessel with the smaller diameter is regarded as a bifurcation branch, and the vessels are classified and segmented. The diameter of each blood vessel segment is calculated based on the binary image of the blood vessel and the image of the blood vessel centerline; and the blood vessel classification and diameter measurement results are recorded in a structured manner.
[0008] Secondly, this application provides a device for retinal vessel grading and diameter measurement, comprising: The image acquisition and processing module is used to acquire a retinal image to be processed, perform vessel segmentation and vessel centerline extraction on the retinal image to be processed, and obtain a vessel binary map and a vessel centerline image; the vessel binary map includes a retinal artery binary map and a retinal vein binary map; the vessel centerline image includes an arterial vessel centerline image and a venous vessel centerline image; The optic disc positioning module is used to determine the starting point of the main blood vessel based on the edge of the optic disc, and traverse the image of the blood vessel centerline from the starting point to identify the bifurcation points of all blood vessels on the blood vessel path in sequence. The vessel diameter calculation module is used to calculate the diameter of the main vessel before the bifurcation and the diameter of the two branch vessels after the bifurcation at each bifurcation point. The vascular grading module is used to classify and segment the blood vessels based on the diameter relationship between the two branch vessels after bifurcation, treating the branch vessel with the larger diameter as an extension of the main trunk and the branch vessel with the smaller diameter as a bifurcation branch. The results recording module is used to calculate the diameter of each segment of blood vessel based on the binary image of blood vessels and the image of the blood vessel centerline; and to record the blood vessel grading and diameter measurement results in a structured manner.
[0009] Thirdly, this application provides a computer device, including: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the retinal vessel grading and diameter measurement method.
[0010] Fourthly, this application provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the aforementioned retinal vessel grading and diameter measurement method.
[0011] Fifthly, this application provides a computer program product, including a computer program that, when executed by a processor, implements the aforementioned retinal vessel grading and diameter measurement method.
[0012] According to the specific embodiments provided in this application, this application has the following technical effects: This application provides a method, device, medium, and product for retinal vessel grading and diameter measurement. By segmenting vessels and extracting vessel centerlines from the retinal image to be processed, binary images of arteries and veins can be obtained, avoiding errors in vessel type identification caused by mixed arteries and veins, and enabling subsequent diameter measurement results to distinguish between arteries and veins. By representing the vascular topology through the vessel centerline image, complex vascular regions can be converted into traversable linear structures, thereby facilitating the automatic identification of vessel origins, endpoints, common points, and bifurcation points. Traversing the centerline image starting from the vessel origin at the optic disc edge, bifurcation points can be identified step by step according to the natural course of the vessels, forming an anatomically... This invention provides vascular grading results with both scientific and topological significance. At each bifurcation point, the diameters of the main trunk and two branches are calculated, with the thicker vessels considered as extensions of the main trunk and the thinner vessels as bifurcation vessels. This automatically determines the main trunk continuity and branch levels of the vascular tree, reducing the subjectivity of manual judgment of vessel levels. The calculation of the diameter of each vessel segment yields the average diameter of that segment. The calculation method is simple, stable, and suitable for automated batch processing. This application addresses the problems of excessive manual intervention, high subjectivity, low efficiency, difficulty in automatically determining vessel branch levels, lack of structured recording of measurement results, and inaccurate centerline and diameter measurements due to vessel rupture or cavities in existing retinal vessel diameter measurements. Attached Figure Description
[0013] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0014] Figure 1 This is a flowchart illustrating a method for retinal vessel grading and diameter measurement in one embodiment of this application. Figure 2 A schematic diagram of effective field of view cropping for retinal images; Figure 3 A schematic diagram showing the segmentation results of the retinal arteries and retinal veins; Figure 4 This is a schematic diagram of the repair of fractures and cavities in the binary images of retinal arteries and retinal veins. Figure 5 A schematic diagram of the process for extracting the central line of retinal vessels; Figure 6 A schematic diagram illustrating the classification of ordinary points, endpoints, and bifurcation points in a blood vessel centerline image; Figure 7 This is a schematic diagram showing the starting point of the vascular centerline at the edge of the optic disc; Figure 8A schematic diagram showing the division of the superior temporal, inferior temporal, superior nasal, and inferior nasal regions; Figure 9 This is a schematic diagram illustrating the determination of main trunk extensions and bifurcation vessels based on diameter relationships. Figure 10 This is a schematic diagram for calculating the diameter of a blood vessel segment; Figure 11 This is a schematic diagram of the data structure for retinal vessel grading and diameter measurement results. Detailed Implementation
[0015] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0016] To make the above-mentioned objectives, features and advantages of this application more apparent and understandable, the application will be further described in detail below with reference to the accompanying drawings and specific embodiments.
[0017] In one exemplary embodiment, such as Figure 1 As shown, a method for retinal vessel grading and diameter measurement is provided. This method is executed by a computer device, specifically by a terminal or server alone, or by both a terminal and a server. In this embodiment, the method is described using a server as an example, including the following steps S101 to S105. Wherein: S101, acquire the retinal image to be processed, perform blood vessel segmentation and blood vessel centerline extraction on the retinal image to be processed, and obtain a binary image of blood vessels and a binary image of blood vessels; the binary image of blood vessels includes a binary image of retinal arteries and a binary image of retinal veins; the binary image of blood vessels includes a binary image of arterial blood vessels and a binary image of venous blood vessels. S101 specifically includes: S11, perform effective field-of-view cropping on the retinal image to be processed, retaining the effective field-of-view area; thereby removing black background, image edges and irrelevant areas, reducing the impact of invalid pixels on blood vessel segmentation, centerline extraction and blood vessel diameter measurement, and improving the stability of subsequent image processing.
[0018] like Figure 2 As shown, the effective field of view is first detected in the original retinal image to be processed. Since fundus images usually include a circular or nearly circular effective fundus area, and the image edges may have black backgrounds, occlusions, invalid edges or device imaging borders, the effective field of view area needs to be cropped before vascular analysis.
[0019] In one implementation, the effective visual field region of the retina can be determined through threshold segmentation, connected component analysis, circular region detection, boundary fitting, or a deep learning segmentation model. Subsequently, the original image is cropped based on the bounding rectangle or minimum enclosing region of the effective visual field region to obtain a retinal image containing only the effective visual field; this reduces the interference of background regions on the blood vessel segmentation model and subsequent morphological processing. S12, perform vessel segmentation on the cropped retinal image to obtain binary images of retinal arteries and retinal veins. And as shown... Figure 3 As shown; In one implementation, a semantic segmentation model can be used to perform pixel-level classification of retinal images, categorizing pixels in the image into background, arteries, veins, or other categories. The semantic segmentation model can be a series of models such as U-Net (U-shaped network), SwinUNet (U-shaped network based on a shifted window Transformer), TransUNet (U-shaped network based on Transformer), GCtxUNet (U-shaped network based on global context), DeepLab (deeply dilated convolutional segmentation network), or other neural network models capable of retinal vessel segmentation. After segmentation, arterial regions are set as foreground pixels, and non-arterial regions are set as background pixels to obtain a binary image of retinal arteries; similarly, vein regions are set as foreground pixels, and non-vein regions are set as background pixels to obtain a binary image of retinal veins.
[0020] S13, perform break repair and cavity repair on the binary image of retinal artery and the binary image of retinal vein respectively to obtain a continuous arterial blood vessel image and a continuous venous blood vessel image; thereby improving the problems of local discontinuity, holes and boundary defects in the blood vessel segmentation image, and improving the continuity and accuracy of blood vessel centerline extraction. like Figure 4 As shown, since the blood vessel segmentation results may contain local breaks, edge defects, holes or noise, this application repairs the breaks and holes in the binary images of retinal arteries and retinal veins respectively.
[0021] In one implementation, morphological closing operations, dilation-erosion combinations, connected component completion, hole filling, small break connections, or breakpoint connection algorithms based on vessel orientation consistency can be used for repair. For example, an m×m pixel structuring element can be created to perform morphological closing operations on the binary vessel image to connect closely spaced broken vessels and fill local holes. After repair, a coherent arterial vessel image and a coherent venous vessel image are obtained.
[0022] S14, extract the center lines of the arterial and venous vessels respectively to obtain arterial center line images and venous center line images, and as shown in... Figure 5 As shown.
[0023] In one implementation, an iterative thinning algorithm is used for centerline extraction. Specifically, foreground pixels of the blood vessel are set to 1, and background pixels are set to 0. The blood vessel image is iteratively traversed, and while maintaining the overall connectivity of the blood vessels, boundary foreground pixels that meet preset topological constraints are gradually deleted. After each round of traversal, the marked pixels are deleted uniformly, and the next round of thinning operation is performed until there are no deletable pixels in a complete iteration, thereby obtaining a blood vessel centerline image with a single pixel width. The skeleton satisfies the following structural characteristics: endpoint pixels have one and only one adjacent pixel, bifurcation point pixels have three adjacent pixels, and the remaining centerline pixels have two adjacent pixels. Subsequently, the centerline image is pruned to remove blood vessel segments that do not meet the length or connectivity requirements, thereby obtaining a blood vessel centerline that is more suitable for blood vessel topology traversal and structural analysis.
[0024] like Figure 6 As shown, after S101, the process further includes converting the vascular centerline image into a graph structure. The graph structure can be represented as G=(V,E), where V represents the set of nodes and E represents the set of edges; the specific process is as follows: S1, the centerline pixel with two neighboring pixels in the blood vessel centerline image is taken as a normal point; S2, take the centerline pixel with a neighboring pixel in the blood vessel centerline image as the endpoint; S3, the centerline pixel in the blood vessel centerline image that has three or more neighboring pixels is taken as the bifurcation point; S1-S3 represent the classification of the centerline image based on the number of neighborhood connections for each centerline pixel. S4, using the endpoints and the bifurcation points as vertices, and forming edges between adjacent vertices with continuous centerline pixel paths, construct the graph structure corresponding to the blood vessel centerline image; S5, Based on the graph structure, the vascular centerline image is converted from a pixel-level image into a traversable, segmentable, and recordable vascular tree structure.
[0025] S102, based on the edge of the optic disc, determine the starting point of the main blood vessel, and starting from the starting point, traverse the image of the blood vessel centerline, sequentially identifying the bifurcation points of all blood vessels along the blood vessel path, and as follows... Figure 7 As shown; S102 specifically includes: S21, Detect the visual disk area to obtain the coordinates of the visual disk center and the visual disk boundary; Among them, the detection of the visual disc region can be provided by target detection models, segmentation models, circular fitting methods or manual annotation results; S22, construct a circle with the center coordinates of the optic disc as the center and the average width and height of the optic disc as the radius; take the intersection of the blood vessel centerline and the circle as the starting point of the main blood vessel; That is, in the arterial centerline image and the venous centerline image, search for the centerline point that intersects with the edge of the optic disc or is closest to the edge of the optic disc, and take it as the starting point of the corresponding blood vessel.
[0026] Furthermore, based on the quadrant where the blood vessel originates and the type of blood vessel, they can be classified as: superior temporal artery, inferior temporal artery, superior nasal artery, inferior nasal artery, superior temporal vein, inferior temporal vein, superior nasal vein, and inferior nasal vein.
[0027] like Figure 8 As shown, the retinal image is divided into regions using the line connecting the center of the optic disc and the center of the macula as a reference direction. Based on the information of the left and right eyes in the image or the positional relationship between the optic disc and the macula, the temporal and nasal directions are determined, and the image is further divided into four quadrants: superior temporal, inferior temporal, superior nasal, and inferior nasal.
[0028] Based on the artery / vein segmentation results, the corresponding vascular tree can be divided into eight categories: superior temporal artery, inferior temporal artery, superior nasal artery, inferior nasal artery, superior temporal vein, inferior temporal vein, superior nasal vein, and inferior nasal vein. These categories serve as the first field of the measurement results.
[0029] S23, Traverse along the centerline diagram structure from the starting point; S24. During the traversal, if the current path does not encounter a bifurcation point of the blood vessel, continue to move along the center line and include the center line pixels and the corresponding blood vessel region pixels into the current blood vessel segment. S25, when traversing to the bifurcation point of a blood vessel, record the segment of the blood vessel before the bifurcation as a segment of the current level blood vessel, and track the two candidate branches after the bifurcation. For each candidate branch, determine its corresponding blood vessel region within a certain distance range far from the bifurcation point, and calculate its diameter.
[0030] S103, at each bifurcation point, calculate the diameter of the main vessel before bifurcation and the diameter of the two branch vessels after bifurcation. S103 specifically includes: S31, Select blood vessel segments of preset lengths at the proximal and distal ends of the bifurcation point respectively; S32, calculate the average diameter of the main trunk segment near the bifurcation point, the first branch segment near the bifurcation point, and the second branch segment near the bifurcation point based on the preset length of the vascular segments near the bifurcation point. S33, take the average diameter of the main trunk segment near the bifurcation point as the diameter of the main trunk before the bifurcation; S34, the average diameter of the first branch vessel segment distal to the bifurcation point and the second branch vessel segment distal to the bifurcation point are taken as the diameter of the two branch vessels after the bifurcation.
[0031] like Figure 9 As shown, at each bifurcation point, this application calculates the diameter of three parts of the blood vessel: (1) the diameter of the main trunk blood vessel near the bifurcation point (D0); (2) the diameter of the first branch blood vessel far from the bifurcation point (D1); and (3) the diameter of the second branch blood vessel far from the bifurcation point (D2).
[0032] In one implementation, a certain length of vascular segment proximal and distal to the bifurcation point can be selected, and the average diameter of each segment can be calculated. Subsequently, the vessel with the larger diameter in the two distal branches is defined as an extension of the main trunk vessel, and the vessel with the smaller diameter is defined as a newly generated bifurcation vessel.
[0033] For example, a primary vessel extends from its origin at the edge of the optic disc. After encountering the first bifurcation point, if the diameter of branch A is greater than that of branch B, then branch A is defined as an extension of the primary vessel, and branch B is defined as a secondary vessel. If the primary vessel continues to advance and encounters a second bifurcation point, the extension of the main trunk and new branches are determined according to the diameter. Thus, records such as the first segment, second segment, and third segment of a primary vessel can be generated.
[0034] For newly generated secondary vessels, the same rules can be applied to continue the traversal. When a secondary vessel encounters a bifurcation point, the thicker branch is defined as an extension of the secondary vessel, and the thinner branch is defined as a tertiary vessel. Thus, we can obtain hierarchical segmentation results such as the first segment of a secondary vessel, the second segment of a secondary vessel, and the first segment of a tertiary vessel.
[0035] S104, Based on the diameter relationship between the two branch vessels after the bifurcation, the branch vessel with the larger diameter is regarded as an extension of the main vessel, and the branch vessel with the smaller diameter is regarded as a bifurcation branch, and the vessels are classified and segmented; the first-level vessels, second-level vessels, third-level vessels and their corresponding first segment, second segment, third segment, etc. are recorded; This application can calculate the diameter of the main trunk and two branches at each bifurcation point, and use the thicker blood vessels as the extension of the main trunk and the thinner blood vessels as the bifurcation vessels. This can automatically determine the main trunk continuity relationship and branch level of the vascular tree, reducing the subjectivity of manual judgment of blood vessel level. In one implementation, the vascular grading rules are as follows: (1) The main blood vessel that originates directly from the edge of the optic disc is defined as a first-order blood vessel; (2) The finer branches that branch off from the bifurcation point of a primary vessel are defined as secondary vessels; (3) The finer branches that branch off from the bifurcation point of a secondary vessel are defined as tertiary vessels; (4) When a third-level vessel continues to bifurcate, it can be defined as a fourth-level vessel or a higher-level vessel as needed.
[0036] In one implementation, the blood vessel segmentation rules are as follows: (1) Within the same vascular level, the vascular path between two adjacent bifurcation points is defined as a vascular segment; (2) The path from the origin of the blood vessel to the first bifurcation point is defined as the first segment; (3) The path between the first branch point and the second branch point is defined as the second segment; (4) The path between the second and third bifurcation points is defined as the third segment; And so on.
[0037] For example, it can be recorded as: Primary blood vessel - first segment; Primary blood vessel - Second segment; Primary blood vessel - third segment; Secondary blood vessel - first segment; Secondary vessel - second segment; Grade III blood vessels - Segment 1; Tertiary vessels - second segment.
[0038] Furthermore, this application can automatically record various segments of blood vessels at different levels, such as primary, secondary, and tertiary vessels, thereby achieving a refined and hierarchical description of the retinal vascular tree. S105 calculates the diameter of each blood vessel segment based on the binary image of the blood vessel and the image of the blood vessel centerline; and records the blood vessel classification and diameter measurement results in a structured manner.
[0039] S105 specifically includes: S51, the diameter of the current blood vessel segment is obtained by dividing the total number of blood vessel pixels in the binary blood vessel image by the total number of centerline pixels in the blood vessel centerline image. Figure 10 As shown; Let A be the total number of pixels corresponding to a certain blood vessel segment in the binary image of the blood vessel, and L be the total number of pixels along the centerline of the same blood vessel segment in the centerline image. Then the diameter D of the blood vessel segment can be expressed as: D = A / L; Where A represents the total number of foreground pixels within the blood vessel segment, L represents the total number of pixels on the center line of the blood vessel segment, and D represents the average pixel diameter of the blood vessel segment.
[0040] If the pixel size or image scale conversion relationship of the fundus camera is known, the pixel diameter can be further converted into the actual physical diameter, such as micrometers or millimeters.
[0041] This application does not require point-by-point perpendicular measurement of each centerline point, nor does it require complex boundary fitting; the average width of the vessel segment can be obtained by the ratio of the area to the length of the centerline, making it suitable for large-scale, automated, and structured measurements.
[0042] S52, record the measurement results for each blood vessel segment according to the structured fields, and as follows: Figure 11 As shown, the results can be classified and recorded according to fields such as superior temporal artery, inferior temporal artery, superior nasal artery, inferior nasal artery, superior temporal vein, inferior temporal vein, superior nasal vein, and inferior nasal vein. The vessel level, origin coordinates, and segment number are further recorded to facilitate the formation of a standardized database and subsequent statistical analysis. The structured fields include: a first field of vessel location and type, a second field of vessel level, a third field of origin coordinates, and a fourth field of vessel segment number.
[0043] For example: Each record must include at least the following fields: The first field: the location and type of blood vessels, including the superior temporal artery, inferior temporal artery, superior nasal artery, inferior nasal artery, superior temporal vein, inferior temporal vein, superior nasal vein, and inferior nasal vein.
[0044] The second field is the vascular level, which includes primary vascular, secondary vascular, tertiary vascular, etc.
[0045] The third field: starting point coordinates, used to record the position of the starting point of the blood vessel segment in the image coordinate system, for example (x, y).
[0046] The fourth field is the vessel segment number, including the first segment, the second segment, the third segment, etc.
[0047] Furthermore, it can also record extended fields such as endpoint coordinates, bifurcation point coordinates, vessel segment length, total number of vessel pixels, total number of centerline pixels, average diameter, maximum diameter, minimum diameter, eye to which the vessel belongs, image number, patient number, and measurement time. An example record is shown below: Superior temporal artery, primary vessel, origin coordinates (x1, y1), first segment, average diameter D1; Superior temporal artery, primary vessel, origin coordinates (x2, y2), second segment, average diameter D2; Superior temporal artery, secondary vessel, origin coordinates (x3, y3), first segment, average diameter D3; Superior temporal artery, a third-order vessel, origin coordinates (x4, y4), first segment, average diameter D4; The infratemporal vein is a primary blood vessel with origin coordinates (x5, y5), the first segment, and an average diameter of D5.
[0048] The difference between this application and the prior art is at least in the following aspects: First, this application not only performs vessel segmentation and centerline extraction, but also automatically traverses the vessel tree structure along the vessel centerline starting from the edge of the optic disc.
[0049] Second, this application calculates the diameter of the trunk and the two branches at each bifurcation point, and automatically determines the trunk extension and bifurcation vessels based on the diameter relationship.
[0050] Third, this application can automatically establish hierarchical relationships such as primary blood vessels, secondary blood vessels, and tertiary blood vessels, and further record each segment of each level of blood vessel.
[0051] Fourth, this application calculates the average diameter of a blood vessel by dividing the total number of pixels in each segment by the total number of pixels along the center line of that segment, thus forming a blood vessel segment diameter measurement method suitable for automated processing.
[0052] Fifth, this application records the measurement results in a structured manner according to the location and type of blood vessels, the level of blood vessels, the coordinates of the starting point, and the sequence number of the blood vessel segment, which facilitates subsequent database storage, clinical report generation, and statistical analysis.
[0053] Sixth, this application can be deployed in computer equipment, servers, fundus image analysis systems or screening platforms, which can improve the efficiency of retinal vessel diameter measurement, reduce manual operation, and improve the consistency of results. It is suitable for large-scale fundus screening, clinical research and auxiliary diagnosis scenarios.
[0054] Based on the same inventive concept, this application also provides a retinal vessel grading and diameter measurement device for implementing the aforementioned retinal vessel grading and diameter measurement method. The solution provided by this device is similar to the solution described in the above method; therefore, the specific limitations of one or more embodiments of the retinal vessel grading and diameter measurement device provided below can be found in the limitations of the retinal vessel grading and diameter measurement method described above, and will not be repeated here.
[0055] In one exemplary embodiment, a device for retinal vessel grading and diameter measurement is provided, comprising: The image acquisition and processing module is used to acquire a retinal image to be processed, perform vessel segmentation and vessel centerline extraction on the retinal image to be processed, and obtain a vessel binary map and a vessel centerline image; the vessel binary map includes a retinal artery binary map and a retinal vein binary map; the vessel centerline image includes an arterial vessel centerline image and a venous vessel centerline image; The optic disc positioning module is used to determine the starting point of the main blood vessel based on the edge of the optic disc, and traverse the image of the blood vessel centerline from the starting point to identify the bifurcation points of all blood vessels on the blood vessel path in sequence. The vessel diameter calculation module is used to calculate the diameter of the main vessel before the bifurcation and the diameter of the two branch vessels after the bifurcation at each bifurcation point. The vascular grading module is used to classify and segment the blood vessels based on the diameter relationship between the two branch vessels after bifurcation, treating the branch vessel with the larger diameter as an extension of the main trunk and the branch vessel with the smaller diameter as a bifurcation branch. The results recording module is used to calculate the diameter of each segment of blood vessel based on the binary image of blood vessels and the image of the blood vessel centerline; and to record the blood vessel grading and diameter measurement results in a structured manner.
[0056] In an exemplary embodiment, a computer device is provided, which may be a server or a terminal. The computer device includes a processor, memory, input / output (I / O) interfaces, and a communication interface. The processor, memory, and I / O interfaces are connected via a system bus, and the communication interface is connected to the system bus via the I / O interfaces. The processor of the computer device provides computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and internal memory. The non-volatile storage medium stores an operating system, computer programs, and a database. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage medium. The I / O interfaces of the computer device are used for exchanging information between the processor and external devices. The communication interface of the computer device is used for communication with external terminals via a network connection. When the computer program is executed by the processor, it implements a method for retinal vessel grading and diameter measurement.
[0057] In one exemplary embodiment, a computer device is provided, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps in the above-described method embodiments.
[0058] In one exemplary embodiment, a computer-readable storage medium is provided storing a computer program that, when executed by a processor, implements the steps in the above-described method embodiments.
[0059] In one exemplary embodiment, a computer program product is provided, including a computer program that, when executed by a processor, implements the steps in the above-described method embodiments.
[0060] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, data stored, data displayed, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of the relevant data must comply with relevant regulations.
[0061] Those skilled in the art will understand that all or part of the processes in the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium. When executed, the computer program can include the processes of the embodiments described above. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM).
[0062] The databases involved in the embodiments provided in this application may include at least one type of relational database and non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the embodiments provided in this application may be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logic devices, quantum computing-based data processing logic devices, etc., and are not limited to these.
[0063] In this application, all actions to acquire signals, information, or data are carried out in compliance with the relevant data protection laws and policies of the country where the location is situated, and with the authorization granted by the owner of the relevant device.
[0064] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0065] This document uses specific examples to illustrate the principles and implementation methods of this application. The descriptions of the above embodiments are only for the purpose of helping to understand the methods and core ideas of this application. Furthermore, those skilled in the art will recognize that, based on the ideas of this application, there will be changes in the specific implementation methods and application scope. Therefore, the content of this specification should not be construed as a limitation of this application.
Claims
1. A method for grading and measuring the diameter of retinal vessels, characterized in that, include: A retinal image to be processed is acquired, and blood vessel segmentation and blood vessel centerline extraction are performed on the retinal image to obtain a binary image of blood vessels and a binary image of blood vessels; the binary image of blood vessels includes a binary image of retinal arteries and a binary image of retinal veins; the binary image of blood vessels includes a binary image of arterial blood vessels and a binary image of venous blood vessels. The starting point of the main blood vessel is determined based on the edge of the optic disc. Starting from the starting point, the image of the blood vessel centerline is traversed to identify the bifurcation points of all blood vessels along the blood vessel path in sequence. At each bifurcation point, the diameter of the main vessel before bifurcation and the diameters of the two branch vessels after bifurcation are calculated respectively. Based on the diameter relationship between the two branch vessels after the bifurcation, the branch vessel with the larger diameter is regarded as an extension of the main trunk vessel, and the branch vessel with the smaller diameter is regarded as a bifurcation branch, and the vessels are classified and segmented. The diameter of each blood vessel segment is calculated based on the binary image of the blood vessel and the image of the blood vessel centerline; and the blood vessel classification and diameter measurement results are recorded in a structured manner.
2. The method for retinal vessel grading and diameter measurement according to claim 1, characterized in that, The process of acquiring the retinal image to be processed, performing vessel segmentation and vessel centerline extraction on the retinal image to obtain a binary vessel map and a vessel centerline image, specifically includes: The retinal image to be processed is cropped to retain the effective visual field area; The cropped retinal image was segmented into blood vessels to obtain binary images of retinal arteries and retinal veins. The binary images of retinal arteries and retinal veins are respectively subjected to break repair and cavity repair to obtain continuous arterial and continuous venous images. The center lines of the arterial and venous vessels are extracted from the continuous arterial and venous vessel images, respectively, to obtain arterial vessel center line images and venous vessel center line images.
3. The method for retinal vessel grading and diameter measurement according to claim 1, characterized in that, The process of acquiring the retinal image to be processed, performing vessel segmentation and vessel centerline extraction on the retinal image to obtain a binary vessel map and a vessel centerline image, further includes: The centerline pixel in the blood vessel centerline image that has two neighboring pixels is taken as a normal point; The centerline pixel in the blood vessel centerline image that has one neighboring pixel is used as the endpoint; The centerline pixel in the blood vessel centerline image that has three or more neighboring pixels is used as the bifurcation point; Using the endpoints and the bifurcation points as vertices, and with edges formed by continuous centerline pixel paths between adjacent vertices, a graph structure corresponding to the blood vessel centerline image is constructed. The blood vessel centerline image is converted into a blood vessel tree structure based on the graph structure.
4. The method for retinal vessel grading and diameter measurement according to claim 1, characterized in that, The method of determining the starting point of the main blood vessel based on the optic disc edge, and traversing the blood vessel centerline image from the starting point to sequentially identify all bifurcation points of the blood vessel along the blood vessel path, specifically includes: The visual disk area is detected to obtain the coordinates of the visual disk center and the visual disk boundary; A circle is constructed with the center coordinates of the optic disc as the center and the average width and height of the optic disc as the radius; the intersection of the blood vessel centerline and the circle is taken as the starting point of the main blood vessel. Traverse along the centerline diagram structure from the starting point; During the traversal, if the current path does not encounter a bifurcation point of the blood vessel, it continues to move along the center line and includes the center line pixels and the corresponding blood vessel region pixels that have passed into the current blood vessel segment. When traversing to the bifurcation point of a blood vessel, the segment of the blood vessel before the bifurcation is recorded as a segment of the blood vessel at the current level, and the two candidate branches after the bifurcation are tracked respectively.
5. The method for retinal vessel grading and diameter measurement according to claim 1, characterized in that, At each bifurcation point, the diameter of the main vessel before the bifurcation and the diameters of the two branch vessels after the bifurcation are calculated, specifically including: Select blood vessel segments of preset lengths proximal to the bifurcation point and distal to the bifurcation point respectively; The average diameters of the main trunk segment near the bifurcation point, the first branch segment near the bifurcation point, and the second branch segment near the bifurcation point are calculated based on the pre-set lengths of the vessel segments near the bifurcation point and the distal segment near the bifurcation point. The average diameter of the main trunk segment near the bifurcation point is taken as the diameter of the main trunk before the bifurcation. The average diameter of the first branch vessel segment distal to the bifurcation point and the second branch vessel segment distal to the bifurcation point are taken as the diameter of the two branch vessels after the bifurcation.
6. The method for retinal vessel grading and diameter measurement according to claim 1, characterized in that, The process involves calculating the diameter of each blood vessel segment based on the binary blood vessel map and the blood vessel centerline image; and then recording the blood vessel grading and diameter measurement results in a structured manner, specifically including: The diameter of the current blood vessel segment is calculated by dividing the total number of blood vessel pixels in the binary image of the current blood vessel segment by the total number of centerline pixels in the centerline image of the blood vessel segment. The measurement results for each vessel segment are recorded according to the structured fields; the structured fields include: a first field of vessel location and type, a second field of vessel level, a third field of starting point coordinates, and a fourth field of vessel segment number.
7. A device for retinal vessel grading and diameter measurement, characterized in that, include: The image acquisition and processing module is used to acquire a retinal image to be processed, perform vessel segmentation and vessel centerline extraction on the retinal image to be processed, and obtain a vessel binary map and a vessel centerline image; the vessel binary map includes a retinal artery binary map and a retinal vein binary map; the vessel centerline image includes an arterial vessel centerline image and a venous vessel centerline image; The optic disc positioning module is used to determine the starting point of the main blood vessel based on the edge of the optic disc, and traverse the image of the blood vessel centerline from the starting point to identify the bifurcation points of all blood vessels on the blood vessel path in sequence. The vessel diameter calculation module is used to calculate the diameter of the main vessel before the bifurcation and the diameter of the two branch vessels after the bifurcation at each bifurcation point. The vascular grading module is used to classify and segment the blood vessels based on the diameter relationship between the two branch vessels after bifurcation, treating the branch vessel with the larger diameter as an extension of the main trunk and the branch vessel with the smaller diameter as a bifurcation branch. The results recording module is used to calculate the diameter of each segment of blood vessel based on the binary image of blood vessels and the image of the blood vessel centerline; and to record the blood vessel grading and diameter measurement results in a structured manner.
8. A computer device, comprising: A memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that the processor executes the computer program to implement the retinal vessel grading and diameter measurement method according to any one of claims 1-6.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When executed by a processor, the computer program implements the retinal vessel grading and diameter measurement method as described in any one of claims 1-6.
10. A computer program product, comprising a computer program, characterized in that, When executed by a processor, the computer program implements the retinal vessel grading and diameter measurement method as described in any one of claims 1-6.
