Positioning method and device, computer equipment and readable storage medium
By extracting blood vessel and sulcus features in brain images and performing image registration, the problem of low image matching accuracy caused by brain drift is solved, the accuracy of target positioning is improved, and the accuracy of brain surgery is enhanced.
Patent Information
- Application Number
- CN202310890508.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-07-19
- Publication Date
- 2025-01-21
AI Technical Summary
In brain surgery, brain drift results in low matching accuracy of preoperative and intraoperative brain images, which in turn affects the target positioning accuracy.
By acquiring the first brain image and the second brain image, extracting the blood vessel features and sulcus features in the first brain image, obtaining a matching image template, and registering the matching image template with the second brain image, we obtain Target registration relationship, and then locate the target position in the second brain image.
It improves the positioning accuracy of the target position, reduces positioning errors caused by brain drift, and enhances the accuracy in brain surgery.
Smart Images

Figure CN119338867A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of image processing technology, and in particular to a positioning method, apparatus, computer equipment and readable storage medium. Background Art
[0002] When performing brain surgery, it is necessary to first obtain preoperative brain images and plan the surgery based on the preoperative brain images; then obtain intraoperative brain images and modify the planned surgery plan by registering the preoperative brain images and intraoperative brain images. However, in actual application scenarios, due to the influence of brain drift, the matching accuracy of preoperative brain images and intraoperative brain images is low, resulting in inaccurate positioning of the target. Summary of the invention
[0003] Based on this, it is necessary to provide a positioning method, device, computer equipment and readable storage medium that can improve the positioning accuracy of the target in response to the above technical problems.
[0004] In a first aspect, the present application provides a positioning method, the method comprising:
[0005] Acquire a first brain image and a second brain image, and extract vascular features and sulcus and gyrus features from the first brain image to obtain a matching image template;
[0006] Registering the matching image template and the second brain image to obtain a target registration relationship;
[0007] The target position in the second brain image is located according to the target registration relationship and the target position in the matching image template.
[0008] In one embodiment, registering the matching image template and the second brain image to obtain a target registration relationship includes:
[0009] Registering each first registration point in the matching image template and each second registration point in the second brain image to obtain an initial registration relationship between the first registration point set and the second registration point set; the first registration point set includes the first registration point, and the second registration point set includes the second registration point;
[0010] The initial registration relationship is corrected to obtain a target registration relationship; the target registration relationship is used to characterize the correspondence between each first registration point in the first registration point set and each second registration point in the second registration point set; wherein the first registration point set includes first registration points that correspond one-to-one to each second registration point.
[0011] In one embodiment, the initial registration relationship is modified to obtain a target registration relationship, including:
[0012] According to the initial registration relationship, a group of points to be registered in the second registration point set is determined; the group of points to be registered includes two registered second registration points and at least one unregistered second registration point;
[0013] When the type of the to-be-registered point group meets the preset registration condition, re-register each second registration point in the to-be-registered point group according to the position of each first registration point;
[0014] Determine the next group of to-be-registered points that meet the preset registration condition from the second registration point set for re-registration, and return to perform the operation of re-registering each second registration point in the to-be-registered point set according to the position of each first registration point, until all the second registration points in the second registration point set are registered one by one;
[0015] The corresponding relationship between each re-registered second registration point and each first registration point is determined as the target registration relationship.
[0016] In one embodiment, re-registering each second registration point in the group of registration points according to the position of each first registration point includes:
[0017] Determine a target registration point according to the number and position of the first registration points corresponding to each registered second registration point;
[0018] Each second registration point in the group of to-be-registered points is re-registered according to the target registration point.
[0019] In one embodiment, determining a target registration point according to the number and position of the first registration points corresponding to each registered second registration point includes:
[0020] If the number of corresponding first registration points meets a preset standard, selecting a first number of first registration points from the plurality of corresponding first registration points as candidate registration points;
[0021] If the number of corresponding first registration points does not meet the preset standard, selecting a second number of first registration points from the plurality of corresponding first registration points as candidate registration points;
[0022] The target registration point is determined according to the position of the candidate registration point and the position of the registered second registration point.
[0023] In one embodiment, re-registering each second registration point in the group of to-be-registered points according to the target registration point includes:
[0024] Release the registration relationship between the target registration point and the registered second registration point;
[0025] If the number of unregistered second registration points is not less than the number of target registration points, determining second registration points corresponding to the target registration points from the unregistered second registration points for re-registration;
[0026] If the number of the unregistered second registration points is less than the number of the target registration points, first registration points corresponding to the unregistered second registration points are determined from the target registration points for re-registration.
[0027] In one of the embodiments, the preset registration condition includes that at least one unregistered second registration point is arranged between two registered second registration points; and the number of first registration points corresponding to any one of the registered second registration points is greater than one.
[0028] In one embodiment, registering each first registration point in the matching image template with each second registration point in the second brain image to obtain an initial registration relationship between the first registration point set and the second registration point set includes:
[0029] Performing binarization processing and distance transformation processing on the matching image template and the second brain image respectively to obtain a first distance map and a second distance map;
[0030] Each first registration point in the first distance map and each second registration point in the second distance map are registered to obtain an initial registration relationship.
[0031] In a second aspect, the present application further provides a positioning device, the device comprising:
[0032] An acquisition module, used for acquiring a first brain image and a second brain image, and extracting blood vessel features and sulcus features from the first brain image to obtain a matching image template;
[0033] A registration module, used to register the matching image template and the second brain image to obtain a target registration relationship;
[0034] The positioning module is used to locate the target position in the second brain image according to the target registration relationship and the target position in the matching image template.
[0035] In a third aspect, the present application further provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the steps of the method provided in the first aspect are implemented.
[0036] In a fourth aspect, the present application further provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the method provided in the first aspect above.
[0037] The present application provides a positioning method, apparatus, computer equipment and readable storage medium. In this embodiment, a matching image template obtained by extracting vascular features and sulcus features in a first brain image is used to align with a second brain image. In this way, the matching image template includes not only vascular features but also sulcus features, which can improve the accuracy of the target registration relationship obtained after aligning the matching image template and the second brain image. Thereby, the accuracy of the target position in the second brain image located according to the target registration relationship and the target position in the matching image template can be improved. BRIEF DESCRIPTION OF THE DRAWINGS
[0038] Figure 1 A schematic diagram of an image of brain drift relative to a target position in an embodiment;
[0039] Figure 2 A schematic diagram of a step flow of a positioning method in an embodiment;
[0040] Figure 3 is a schematic diagram of a structured light imaging device in one embodiment;
[0041] Figure 4 A schematic diagram of a matching image template acquisition process in an embodiment;
[0042] Figure 5 A schematic diagram of a step flow chart of a positioning method in another embodiment;
[0043] Figure 6 A schematic diagram of a step flow chart of a positioning method in another embodiment;
[0044] Figure 7 A schematic diagram of a step flow chart of a positioning method in another embodiment;
[0045] Figure 8 A schematic diagram of a step flow chart of a positioning method in another embodiment;
[0046] Fig. 9 A schematic diagram of a step flow chart of a positioning method in another embodiment;
[0047] Fig.10 is a schematic diagram of correcting an initial registration relationship in one embodiment;
[0048] Fig.11 A schematic diagram of a step flow chart of a positioning method in another embodiment;
[0049] Fig.12 A schematic diagram of binarization processing and distance transformation processing in one embodiment;
[0050] Fig.13 A schematic diagram of a step flow chart of a positioning method in another embodiment;
[0051] Fig.14 is a schematic structural diagram of a positioning device in one embodiment;
[0052] Fig.15 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION
[0053] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0054] The serial numbers assigned to the components in this article, such as "first", "second", etc., are only used to distinguish the objects described and do not have any order or technical meaning.
[0055] Before specifically introducing the technical solution of the embodiment of the present application, the technical background and technical evolution context on which the embodiment of the present application is based are first introduced. When performing brain surgery, it is necessary to first obtain preoperative brain images and plan the surgical plan based on the preoperative brain images; then obtain intraoperative brain images and align the preoperative brain images with the intraoperative brain images to modify the planned surgical plan.
[0056] However, in actual application scenarios, due to the influence of brain drift, the intraoperative brain image may not match the preoperative brain image, resulting in low accuracy in matching the preoperative brain image with the intraoperative brain image, which in turn may lead to inaccurate positioning of the target in the intraoperative brain image.
[0057] Effects of brain drift on intraoperative brain imaging Figure 1 As shown. Figure 1 It can be seen that compared with the target points in the preoperative brain image and the intraoperative brain image, the target point position in the intraoperative brain image has shifted due to brain drift. In the related art, the brain drift situation is imaged by intraoperative imaging equipment, and the positioning of the target point is readjusted based on the intraoperative imaging data. However, the methods in traditional technology are not accurate in positioning the target point. In this regard, the present application provides a positioning method.
[0058] The following is an introduction to the technical solutions involved in the embodiments of the present application in combination with the scenarios in which the embodiments of the present application are applied.
[0059] The positioning method provided in the present application can be applied to computer devices, and the computer devices can be but are not limited to industrial computers, laptops, smart phones, tablet computers, etc.
[0060] In one embodiment, Figure 2As shown, a positioning method is provided. This embodiment is described by applying the method to a computer device. In this embodiment, the method may include the following steps:
[0061] Step 200: Acquire a first brain image and a second brain image, and extract vascular features and sulcus features from the first brain image to obtain a matching image template; wherein the second brain image is acquired by structured light imaging technology.
[0062] The first brain image may be a computed tomography (CT) image, a magnetic resonance (MR) image, an X-ray image or an ultrasound image of the target object. The computer device may obtain the first brain image from an image device post-processing workstation, or may obtain the first brain image from a PACS (Picture Archiving and Communication Systems) server.
[0063] The second brain image is an image acquired by the structured light imaging device through the structured light imaging technology and transmitted to the computer device. The second brain image can be acquired by the structured light imaging device in real time and transmitted to the computer device.
[0064] In an optional embodiment, the structured light imaging device is a structured light camera, such as Figure 3 As shown, by aiming the structured light camera at the brain area of the target object, a second brain image can be obtained. The second brain image includes information of color and depth values, which is three-dimensional point cloud data. Figure 3 Where O1 represents the coordinate origin corresponding to the structured light camera, and the X-axis and Y-axis represent the X-axis and Y-axis in the coordinate system corresponding to the structured light camera.
[0065] The computer device can obtain a first brain image and a second brain image of the target object. After obtaining the first brain image, the computer device will perform feature extraction processing on the first brain image, extract blood vessel features and sulcus features in the first brain image, and obtain a matching image template.
[0066] In an optional embodiment, the computer device may directly input the first brain image into a pre-trained feature extraction model to obtain a matching image template.
[0067] In another optional embodiment, Figure 4As shown, the computer device can perform blood vessel segmentation and reconstruction on the first brain image to obtain a blood vessel map, perform feature extraction on the blood vessel map to obtain a blood vessel characteristic map; perform brain parenchyma segmentation and sulcus and gyrus reconstruction on the first brain image to obtain a sulcus and gyrus map, perform feature extraction on the sulcus and gyrus map to obtain a sulcus and gyrus characteristic map; perform fusion processing on the blood vessel characteristic map and the sulcus and gyrus characteristic map to obtain a matching image template.
[0068] Step 210: register the matching image template and the second brain image to obtain a target registration relationship.
[0069] After acquiring the matching image template, the computer device registers the matching image template and the acquired second brain image to determine the target registration relationship, that is, the transformation relationship between the matching image template and the second brain image. The target registration relationship is used to characterize the transformation relationship between each registration point of the second brain image and each corresponding registration point in the matching image template. In other words, each registration point in the matching image template can be converted to each corresponding registration point in the second brain image through the target registration relationship.
[0070] Step 220: locate the target position in the second brain image according to the target registration relationship and the target position in the matching image template.
[0071] The matching image template includes a target point, which may be predetermined by a staff member. After obtaining the target registration relationship, the computer device can determine the position of the target point in the second brain image through the target registration relationship and the position of the target point in the matching image template. In other words, the computer device can map the target point in the matching image template to the second brain image by calculating the product between the target registration relationship and the position of the target point in the matching image template, thereby obtaining the position of the target point in the second brain image.
[0072] In this embodiment, the matching image template obtained by extracting the vascular features and sulcus features in the first brain image is used to align with the second brain image. In this way, the matching image template includes not only the vascular features but also the sulcus features, which can improve the accuracy of the target alignment relationship obtained after aligning the matching image template and the second brain image, thereby improving the accuracy of the target position in the second brain image located according to the target alignment relationship and the target position in the matching image template. In addition, the second brain image in this embodiment can be acquired by structured light imaging technology, which can achieve real-time acquisition of the second brain image, thereby improving the accuracy of locating the target position in the second brain image. And the second brain image can be acquired using a structured light imaging device without the need to use expensive imaging equipment, which can reduce costs and improve the practicality of the positioning method.
[0073] In an optional embodiment, the embodiment of the present application can be applied to the scene of brain surgery, in which case the first brain image is a preoperative brain image, and the second brain image is an intraoperative brain image. In the embodiment of the present application, the real-time and accurate positioning of the target position during brain surgery can be achieved, so that when medical staff perform brain surgery based on the real-time and accurate target position, the accuracy of the target position operation during brain surgery can be greatly improved. Thereby, the occurrence of incomplete lesion resection, damage to excess healthy tissue, and damage to vascular structure leading to bleeding can be effectively reduced.
[0074] It should be understood that the embodiments of the present application are used to assist doctors in locating brain targets during actual applications (such as during brain surgery), and the results are only used as a reference for doctors during actual applications. In addition, each process of the embodiments of the present application is executed by a computer device.
[0075] In one embodiment, Figure 5 As shown, it involves registering the matching image template and the second brain image to obtain an implementation method of a target registration relationship, and the steps of the implementation method include:
[0076] Step 500: align each first registration point in the matching image template and each second registration point in the second brain image to obtain an initial registration relationship between the first registration point set and the second registration point set; the first registration point set includes the first registration point, and the second registration point set includes the second registration point.
[0077] After acquiring the matching image template and the second brain image, the computer device acquires each first registration point in the matching image template to obtain a first registration point set; and acquires each second registration point in the second brain image to obtain a second registration point set. The first registration point can be a pixel point in the matching image template or a mark point set by the staff. The second registration point can be a pixel point in the second brain image or a mark point set by the staff.
[0078] In an optional embodiment, the first registration point set can be obtained by the computer device using seed filling and boundary tracking to store the inner and outer boundary points in the matching image template using a linked list structure. Similarly, the second registration point set can be obtained by the computer device using seed filling and boundary tracking to store the inner and outer boundary points in the second brain image using a linked list structure.
[0079] After obtaining each first registration point and each second registration point, the computer device registers each first registration point and each second registration point to obtain an initial registration relationship between the first registration point set and the second registration point set. The initial registration relationship refers to a conversion relationship between the first registration point set and the second registration point set. This embodiment does not limit the specific process of registration, as long as its function can be achieved.
[0080] In an optional embodiment, the computer device may use an iterative closest point algorithm to align each first registration point and each second registration point.
[0081] Step 510: modify the initial registration relationship to obtain a target registration relationship; the target registration relationship is used to characterize the correspondence between each first registration point in the first registration point set and each second registration point in the second registration point set, wherein the first registration point set contains first registration points that correspond one-to-one to each second registration point.
[0082] After obtaining the initial registration relationship between the first registration point set corresponding to the matching image template and the second registration point set corresponding to the second brain image, the computer device corrects the initial registration relationship to obtain the target registration relationship. This embodiment does not limit the specific correction process, as long as it can be ensured that the obtained target registration relationship can represent that the first registration point set includes the first registration point that corresponds one-to-one to each second registration point in the second registration point set. In other words, each second registration point in the second registration point set can find the first registration point that corresponds one-to-one to it in the first registration point set.
[0083] In this embodiment, after the first registration points in the matching image template and the second registration points in the second brain image are registered to obtain an initial registration relationship, the initial registration relationship is also corrected to obtain a target registration relationship. The target registration relationship obtained in this way is more accurate, thereby improving the accuracy of locating the position of the target point in the second brain image according to the target registration relationship.
[0084] In one embodiment, Figure 6 As shown, it involves modifying the initial registration relationship to obtain an implementation method of the target second registration relationship, and the steps of the implementation method include:
[0085] Step 600: Determine a group of points to be registered in the second registration point set according to the initial registration relationship; the group of points to be registered includes two registered second registration points and at least one unregistered second registration point.
[0086] After obtaining the initial registration relationship between the first registration point set and the second registration point set, the computer device determines the group of points to be registered in the second registration point set according to the initial registration relationship. In the initial registration relationship, there may be a correspondence between multiple second registration points and one first registration point, or there may be no first registration point in the first registration point set that is registered with each second registration point. According to the initial registration relationship, two registered second registration points and at least one unregistered second registration point in the second registration point set are selected as the group of points to be registered in the second registration point set. A registered second registration point refers to a first registration point that corresponds to it in the first registration point set, and an unregistered second registration point refers to a first registration point that does not correspond to it in the first registration point set. In other words, the computer device searches for second registration points that correspond to each first registration point and second registration points that do not correspond to each first registration point in the second registration point set based on the initial registration relationship, and takes two second registration points that have corresponding first registration points and at least one second registration point that does not have corresponding first registration point in the second registration point set as the point group to be registered.
[0087] Step 610: When the type of the to-be-registered point group meets the preset registration condition, re-register each second registration point in the to-be-registered point group according to the position of each first registration point.
[0088] The preset registration condition is a condition set by the staff that the registration point group needs to meet when the initial registration relationship needs to be corrected. The preset registration condition can be determined by the staff according to the required target registration relationship. This embodiment does not limit the specific preset registration condition as long as its function can be guaranteed.
[0089] In one embodiment, the preset registration condition includes that at least one unregistered second registration point is arranged between two registered second registration points, and the number of first registration points corresponding to any one of the registered second registration points is greater than one.
[0090] In other words, the arrangement order of the second registration points in the group of points to be registered is: the first registered second registration point, the unregistered second registration point, the second registered second registration point, and the number of first registration points corresponding to the first registered second registration point and / or the second registered second registration point is greater than 1. In other words, the first registered second registration point corresponds to multiple first registration points, or the second registered second registration point corresponds to multiple first registration points; or both registered second registration points correspond to multiple first registration points.
[0091] After obtaining the set of points to be registered in the second set of registration points, the computer device determines whether the type of the set of points to be registered meets the preset registration condition. If it is determined that the set of points to be registered does not meet the preset registration condition, the computer device returns to step 600 to select a new set of points to be registered.
[0092] When it is determined that the group of points to be registered meets the preset registration conditions, the computer device will re-register the second registration points in the group of points to be registered according to the positions of the first registration points, that is, re-determine the registration relationship between the second registration points in the group of points to be registered and the first registration points.
[0093] Step 620: determine the next group of points to be registered that meets the preset registration conditions from the second registration point set, and return to execute the operation of re-registering each second registration point in the group of registration points according to the position of each first registration point, until all the second registration points in the second registration point set are registered one by one.
[0094] After the computer device has realigned each second registration point in the group of points to be registered, it will continue to search for a new group of points to be registered that meets the preset registration conditions from the second registration point set, and return to execute step 610 to realign each second registration point in the group of points to be registered according to the position of each second registration point, that is, realign the new group of points to be registered according to the above method, and repeat the above re-registration steps until all the second registration points in the second registration point set are registered one by one, that is, until no group of points to be registered that meets the preset registration conditions is found in the second registration point set.
[0095] Step 630: Determine the correspondence between each re-registered second registration point and each first registration point as the target registration relationship.
[0096] After the computer device realigns each second registration point according to the above steps, the correspondence between each realigned second registration point and each first registration point is determined as the target registration relationship, that is, the correspondence between the realigned second registration point set and the first registration point set is used as the target registration relationship.
[0097] In this embodiment, by determining the group of points to be registered in the second registration point set according to the initial registration relationship, and when the type of the group of points to be registered meets the preset registration condition, the second registration points in the group of points to be registered are re-registered according to the position of the first registration point; then a new group of points to be registered that meets the preset registration condition is re-determined for re-registration until all the second registration points in the second registration point set are registered one by one, so that the target registration relationship after the initial registration relationship is corrected can be obtained. In this way, the second registration points in the second registration point set are re-registered, so that it can be guaranteed that the first registration points corresponding to them one by one are found in the first registration point set, so that an accurate target registration relationship can be obtained, and then the accuracy of locating the target point in the second brain image can be improved.
[0098] In an optional embodiment, the computer device may determine the target registration relationship based on a B-spline interpolation method. k ,Q k}, find the transformation function f1 in the x direction and the transformation function f2 in the y direction, so that: Among them, P k represents the first registration points in the first registration point set, Q k represents each second registration point in the second registration point set, and n represents the number of each first registration point and each second registration point. Assuming that the transformation functions f1 and f2 are smooth enough, the target registration relationship f(x, y) can be expressed as: Among them, N i (x) and N j (y) represents the basis functions of the i-th and j-th B-spline in the x- and y-directions, respectively, and b i,j is the value of the control vertex; w and h represent the width and height of the second brain image, respectively; r and s are the grid sizes, r is the number of grids in the X direction, and s is the number of grids in the Y direction. In this embodiment, a cubic uniform B-spline basis function is selected, and the generated surface is controlled by r+3 and s+3 nodes on x and y, respectively. Using the least squares method to solve f(x,y), the target point in the second brain image can be expressed as:
[0099] In one embodiment, Figure 7 As shown, it is related to an implementation method of re-registering each second registration point in the registration point group according to the position of each first registration point, and the steps of the implementation method include:
[0100] Step 700: Determine a target registration point according to the number and position of the first registration points corresponding to each registered second registration point.
[0101] When the computer device determines that the group of points to be registered meets the preset registration conditions, it will search for the target registration point, that is, the first registration point that needs to be re-registered, among the corresponding first registration points based on the number and position of the first registration points corresponding to the registered second registration points in the group of points to be registered.
[0102] Step 710: Re-register each second registration point according to the target registration point.
[0103] After determining the target registration point, the computer device re-registers the target registration point with each second registration point, that is, re-determines the corresponding relationship between the target registration point and each second registration point.
[0104] In this embodiment, the target registration point to be registered can be determined according to the number and position of the first registration points corresponding to each registered second registration point in the group of points to be registered, and then the second registration point is re-registered according to the target registration point. This method of determining the target registration point is simple and fast, and can improve the efficiency of repeated registration of each second registration point.
[0105] In one embodiment, Figure 8 As shown, it is related to an implementation method of determining a target registration point according to the number and position of the first registration points corresponding to each registered second registration point, and the steps of the implementation method include:
[0106] Step 800: If the number of corresponding first registration points meets a preset standard, a first number of first registration points are selected from a plurality of corresponding first registration points as candidate registration points.
[0107] When the computer device determines the target registration point according to the number and position of the first registration points corresponding to each registered second registration point, it will judge the number of the first registration points corresponding to each registered second registration point to determine whether the number meets the preset standard. The preset standard can be that the number of the corresponding first registration points is an even number; the preset standard can also be that the number of the corresponding first registration points is an odd number. This embodiment does not limit the specific content of the preset standard, as long as its function can be achieved.
[0108] When determining that the number of first registration points corresponding to each registered second registration point meets the preset standard, the computer device selects a first number of first registration points from the corresponding first registration points as candidate registration points. The first number is related to the determination of the preset standard.
[0109] Step 810: If the number of corresponding first registration points does not meet the preset standard, select a second number of first registration points from the plurality of corresponding first registration points as candidate registration points;
[0110] When the computer device determines that the number of first registration points corresponding to each registered second registration point does not meet the preset standard, it selects a second number of first registration points from the corresponding first registration points as candidate registration points. The second number is related to the determination of the preset standard.
[0111] In an optional embodiment, if the preset standard is that the number of corresponding first registration points is an even number, the first number is half of the number of corresponding first registration points, the second number is half of the number of corresponding first registration points, and the number is rounded down. That is, when the number of corresponding first registration points meets the preset standard, that is, the number of corresponding first registration points is an even number, the first number is half of the number of corresponding first registration points, and the computer device selects the first number of first registration points from a plurality of corresponding first registration points as candidate registration points; when the number of corresponding first registration points does not meet the preset standard, that is, the number of corresponding first registration points is an odd number, the second number is half of the number of multiple first registration points, and the number is rounded down, and the computer device selects the second number of first registration points from a plurality of corresponding first registration points as candidate registration points. Assuming that the number of corresponding first registration points is 2 and the number of corresponding first registration points meets the preset standard, the first number is 1, that is, 1 first registration point is selected from 2 corresponding first registration points as a candidate registration point. Assume that the number of corresponding first registration points is 3, and the number of corresponding first registration points does not meet the preset standard, then the second number is half of 3, 1.5, and 1.5 is rounded down, that is, the second number is 1, and 1 first registration point is selected from the 3 corresponding first registration points as the candidate registration point.
[0112] Step 820: Determine a target registration point according to the position of the candidate registration point and the position of the registered second registration point.
[0113] After selecting a candidate registration point from a plurality of corresponding first registration points, the computer device determines a target registration point according to the position of the candidate registration point and the position of the registered second registration point in the group of points to be registered. In other words, the computer device selects a first registration point to be re-registered with each registered second registration point from the candidate registration points as the target registration point according to the positional relationship between the candidate registration point and the registered second registration point.
[0114] In this embodiment, by checking whether the number of first registration points corresponding to each registered second registration point in the registration point group meets the preset standard, a corresponding number of first registration points are selected from multiple first registration points as candidate registration points, and the target registration point is determined according to the position of the candidate registration point and the position of the registered second registration point. This method for determining the target registration point is fast, simple, and easy to implement, and can improve the efficiency of locating the target point position in the second brain image.
[0115] In one embodiment, Fig. 9 As shown, it is related to an implementation method of re-registering each second registration point according to the target registration point, and the steps of the implementation method include:
[0116] Step 910: If the number of unregistered second registration points is not less than the number of target registration points, second registration points corresponding to the target registration points are determined from the unregistered second registration points for re-registration.
[0117] The computer device compares the number of unregistered second registration points in the to-be-registered point group with the number of target registration points. If the computer device determines that the number of unregistered second registration points is greater than or equal to the number of target registration points, the computer device searches for second registration points corresponding to the target registration points from the unregistered second registration points to obtain a new registration relationship between the target registration points and the unregistered second registration points.
[0118] In an optional embodiment, when the computer device re-registers each second registration point according to the target registration point, it can release the registration relationship between the target registration point in the initial registration relationship and the registered second registration point in the group of points to be registered, that is, cut off the initial registration relationship between the target registration point in the initial registration relationship and the registered second registration point in the group of points to be registered; based on the determined new registration relationship between the target registration point and the unregistered second registration point, re-establish the relationship between the target registration point and the registered second registration point in the group of points to be registered.
[0119] In another optional embodiment, the computer device may replace the initial registration relationship with a new registration relationship between the determined target registration point and the unregistered second registration point.
[0120] In an optional embodiment, the computer device may search for a second registration point that is closest to the target registration point from among the unregistered second registration points as the second registration point corresponding to the target registration point.
[0121] Step 920: If the number of the unregistered second registration points is less than the number of the target registration points, first registration points corresponding to the unregistered second registration points are determined from the target registration points for re-registration.
[0122] If the computer device determines that the number of unregistered second registration points is less than the number of target registration points, the first registration points corresponding to the unregistered second registration points are searched from the target registration points to obtain a new registration relationship between the target registration points and the unregistered registration points.
[0123] In this embodiment, the second registration points are re-registered according to the number of unregistered second registration points and the number of target registration points, which can improve the accuracy of the re-registration relationship. In addition, the re-registration method is simple, fast and easy to implement.
[0124] In an optional embodiment, if Fig.10 As shown in FIG. 1 , the square blocks represent the first set of registration points, and the circles represent the second set of registration points. Fig.10 It can be seen from the initial registration relationship in that there are multiple first registration points corresponding to one second registration point, and there is no first registration point corresponding to the second registration point. Determine a group of points to be registered that meet the preset registration conditions from the second registration point set, such as Fig.10 In the case where the number of unregistered second registration points is not less than the number of target registration points (first registration points corresponding to the registered second registration points in the group of registration points to be registered), the registration relationship after re-registration of the second registration points is as follows: Fig.10 In the case where the number of unregistered second registration points is less than the number of target registration points, the registration relationship after re-registration of the second registration points is as follows: Fig.10 The registration relationship after the second registration in the second registration point set. After traversing all the second registration points in the second registration point set and re-registering them, the structure is as follows Fig.10 The registration relationship of the registration result is shown in . Fig.10 It can be seen that after this registration, there are still multiple first registration points corresponding to one second registration point, and there is no first registration point corresponding to the second registration point. In this case, the second registration point set after registration is re-taken as the new second registration point set, and repeat the above registration steps until each second registration point in the second registration point set can be found in the first registration point set until it corresponds to the first registration point one by one.
[0125] In one embodiment, Fig.11 As shown, it involves registering each first registration point in the matching image template with each second registration point in the second brain image to obtain an implementation method of an initial registration relationship between the first registration point set and the second registration point set, and the steps of the implementation method include:
[0126] Step 111 : performing binarization processing and distance transformation processing on the matching image template and the second brain image respectively to obtain a first distance map and a second distance map.
[0127] After obtaining the matching image template, the computer device performs binarization processing and distance transformation processing on the matching image template to obtain a first distance map. In other words, the computer device performs binarization processing on the matching image template to obtain a first binarized image; and performs distance transformation on the first binarized image to obtain a first distance map.
[0128] Similarly, after obtaining the second brain image, the computer device performs binarization processing and distance transformation processing on the second brain image to obtain a second distance map; that is, the computer performs binarization processing on the second brain image to obtain a second binarized image; and performs distance transformation on the second binarized image to obtain a second distance map.
[0129] This embodiment does not limit the specific process of the binarization processing and the distance transformation processing, as long as the functions can be achieved.
[0130] In an optional embodiment, the matching image template and the second brain image are subjected to binarization processing and distance transformation processing respectively to obtain the first distance map and the second distance map. Fig.12 shown.
[0131] Step 112: align each first registration point in the first distance map with each second registration point in the second distance map to obtain an initial registration relationship.
[0132] After obtaining the first distance map corresponding to the matching image template and the second distance map corresponding to the second brain image, the computer device obtains all first registration points in the first distance map and all second registration points in the second distance map, and registers each first registration point with each second registration point to obtain a first registration relationship. This embodiment does not limit the specific method of registering each first registration point with each second registration point, as long as its function can be achieved.
[0133] In an optional embodiment, the computer device may register the first registration points and the second registration points using the principle of closest distance, and search the second registration points that are closest to the first registration points from the second registration points to determine the initial registration relationship.
[0134] In this embodiment, the initial registration is performed by binarizing and distance transforming the matching image template and the second brain image to obtain the first distance map and the second distance map, respectively, to obtain the initial registration relationship. This method for determining the initial registration relationship is simple and quick, and by binarizing and distance transforming the matching image template and the second brain image, the accuracy of determining the initial registration relationship can be improved.
[0135] See also Fig.13 An embodiment of the present application provides a positioning method, the steps of which include:
[0136] Step 131, obtaining a first brain image and a second brain image, and extracting blood vessel features and sulcus features from the first brain image to obtain a matching image template;
[0137] Step 132, performing binarization and distance transformation processing on the matching image template and the second brain image respectively to obtain a first distance map and a second distance map;
[0138] Step 133, aligning each first registration point in the first distance image and each second registration point in the second distance image to obtain an initial registration relationship between the first registration point set and the second registration point set; wherein the first registration point set includes each first registration point, and the second registration point set includes each second registration point;
[0139] Step 134: determining a group of points to be registered in the second registration point set according to the initial registration relationship; the group of points to be registered includes two registered second registration points and at least one unregistered second registration point;
[0140] Step 135: when the type of the to-be-registered point group satisfies a preset registration condition, determining whether the number of first registration points corresponding to each registered second registration point meets a preset standard; the preset registration condition includes that at least one unregistered second registration point is arranged between two registered second registration points; and the number of first registration points corresponding to any registered second registration point is greater than 1;
[0141] Step 136: If the conditions are met, a first number of first registration points are selected from the plurality of first registration points corresponding to the registered second registration points as candidate registration points;
[0142] Step 137: If not, selecting a second number of first registration points from the plurality of first registration points corresponding to the registered second registration points as candidate registration points;
[0143] Step 138, determining a target registration point according to the position of the candidate registration point and the position of the registered second registration point;
[0144] Step 139, canceling the registration relationship between the target registration point and the registered second registration point;
[0145] Step 140: if the number of unregistered second registration points is not less than the number of target registration points, determine second registration points corresponding to the target registration points from the unregistered second registration points for re-registration;
[0146] Step 141: if the number of the unregistered second registration points is less than the number of the target registration points, determining the first registration points corresponding to the unregistered second registration points from the target registration points for re-registration;
[0147] Step 142: Determine the next group of to-be-registered points that meets the preset registration condition from the second registration point set and re-register until all the second registration points in the second registration point set are registered one by one;
[0148] Step 143: determining the correspondence between each second registration point and each first registration point after re-registration as a target registration relationship;
[0149] Step 144: locate the target position in the second protection image according to the target registration relationship and the target position in the matching image template.
[0150] It should be understood that, although the various steps in the flowcharts involved in the above-mentioned embodiments are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps does not have a strict order restriction, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above-mentioned embodiments can include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the steps or stages in other steps.
[0151] Based on the same inventive concept, the embodiment of the present application also provides a positioning device for implementing the positioning method involved above. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme recorded in the above method, so the specific limitations in one or more positioning device embodiments provided below can refer to the limitations of the positioning method above, and will not be repeated here.
[0152] In one embodiment, Fig.14 As shown, a positioning device 10 is provided, comprising: an acquisition module 11, a registration module 12 and a positioning module, wherein:
[0153] The acquisition module 11 is used to acquire the first brain image and the second brain image, and extract the blood vessel features and sulcus features of the first brain image to obtain a matching image template.
[0154] The registration module 12 is used to register the matching image template and the second brain image to obtain a target registration relationship.
[0155] The positioning module 13 is used to locate the target position in the second brain image according to the target registration relationship and the target position in the matching image template.
[0156] Each module in the above positioning device can be implemented in whole or in part by software, hardware or a combination thereof. Each module can be embedded in or independent of a processor in a computer device in the form of hardware, or can be stored in a memory in a computer device in the form of software, so that the processor can call and execute the operations corresponding to each module.
[0157] In one embodiment, a computer device is provided. The computer device may be a terminal, and its internal structure diagram may be as follows: Fig.15 As shown. The computer device includes a processor, a memory, a communication interface, a display screen and an input device connected to a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The communication interface of the computer device is used to communicate with an external terminal in a wired or wireless manner, and the wireless manner can be achieved through WIFI, a mobile cellular network, NFC (near field communication) or other technologies. When the computer program is executed by the processor, a positioning method is implemented. The display screen of the computer device can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer device can be a touch layer covered on the display screen, or a button, a trackball or a touch pad set on the computer device housing, or an external keyboard, touch pad or mouse, etc.
[0158] Those skilled in the art will understand that Fig.15 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0159] In one embodiment, a computer device is provided, including a memory and a processor, wherein a computer program is stored in the memory, and when the processor executes the computer program, the following steps are implemented:
[0160] Acquire a first brain image and a second brain image, and extract vascular features and sulcus and gyrus features from the first brain image to obtain a matching image template;
[0161] Registering the matching image template and the second brain image to obtain a target registration relationship;
[0162] The target position in the second brain image is located according to the target registration relationship and the target position in the matching image template.
[0163] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored, and when the computer program is executed by a processor, the following steps are implemented:
[0164] Acquire a first brain image and a second brain image, and extract vascular features and sulcus and gyrus features from the first brain image to obtain a matching image template;
[0165] Registering the matching image template and the second brain image to obtain a target registration relationship;
[0166] The target position in the second brain image is located according to the target registration relationship and the target position in the matching image template.
[0167] In one embodiment, a computer program product is provided, comprising a computer program, which, when executed by a processor, implements the following steps:
[0168] Acquire a first brain image and a second brain image, and extract vascular features and sulcus and gyrus features from the first brain image to obtain a matching image template;
[0169] Registering the matching image template and the second brain image to obtain a target registration relationship;
[0170] The target position in the second brain image is located according to the target registration relationship and the target position in the matching image template.
[0171] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in the present 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), magnetoresistive 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. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. Non-relational databases may include distributed databases based on blockchains, etc., but are not limited to this. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., but are not limited to this.
[0172] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, 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.
[0173] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.
Claims
1. A positioning method, characterized in that: The method comprises: Acquire a first brain image and a second brain image, and extract blood vessel features and sulcus features from the first brain image to obtain a matching image template; Registering the matching image template and the second brain image to obtain a target registration relationship; The target position in the second brain image is located according to the target registration relationship and the target position in the matching image template.
2. The method according to claim 1, characterized in that The registering the matching image template and the second brain image to obtain a target registration relationship includes: Registering each first registration point in the matching image template and each second registration point in the second brain image to obtain an initial registration relationship between a first registration point set and a second registration point set; the first registration point set includes the first registration point, and the second registration point set includes the second registration point; The initial registration relationship is corrected to obtain the target registration relationship; the target registration relationship is used to characterize the correspondence between each first registration point in the first registration point set and each second registration point in the second registration point set; wherein the first registration point set includes first registration points that correspond one-to-one to each second registration point.
3. The method according to claim 2, characterized in that The correcting the initial registration relationship to obtain the target registration relationship includes: Determine a group of points to be registered in the second registration point set according to the initial registration relationship; the group of points to be registered includes two registered second registration points and at least one unregistered second registration point; When the type of the to-be-registered point group meets a preset registration condition, re-registering each of the second registration points in the to-be-registered point group according to the position of each of the first registration points; Determine the next group of points to be registered that meets the preset registration condition from the second registration point set, and return to perform the operation of re-registering each of the second registration points in the group of points to be registered according to the position of each of the first registration points, until all the second registration points in the second registration point set are registered one by one; The corresponding relationship between each of the re-registered second registration points and each of the first registration points is determined as the target registration relationship.
4. The method according to claim 3, characterized in that The re-registering each second registration point in the group of points to be registered according to the position of each first registration point comprises: Determine a target registration point according to the number and position of the first registration points corresponding to each registered second registration point; Each of the second registration points in the group of points to be registered is re-registered according to the target registration point.
5. The method according to claim 4, characterized in that The determining the target registration point according to the number and position of the first registration points corresponding to each registered second registration point includes: If the number of the corresponding first registration points meets a preset standard, selecting a first number of the first registration points from a plurality of corresponding first registration points as candidate registration points; If the number of the corresponding first registration points does not meet the preset standard, selecting a second number of the first registration points from a plurality of corresponding first registration points as the candidate registration points; The target registration point is determined according to the position of the candidate registration point and the position of the registered second registration point.
6. The method according to claim 4, characterized in that The re-registering each of the second registration points in the group of points to be registered according to the target registration point comprises: If the number of the unregistered second registration points is not less than the number of the target registration points, determining the second registration points corresponding to the target registration points from the unregistered second registration points for re-registration; If the number of the unregistered second registration points is less than the number of the target registration points, the first registration points corresponding to the unregistered second registration points are determined from the target registration points for re-registration.
7. The method according to any one of claims 3 to 6, characterized in that: The preset registration condition includes that at least one unregistered second registration point is arranged between two registered second registration points; and the number of the first registration points corresponding to any one of the registered second registration points is greater than one.
8. The method according to any one of claims 2 to 6, characterized in that: The registering each first registration point in the matching image template and each second registration point in the second brain image to obtain an initial registration relationship between the first registration point set and the second registration point set includes: Performing binarization processing and distance transformation processing on the matching image template and the second brain image respectively to obtain a first distance map and a second distance map; The first registration points in the first distance map and the second registration points in the second distance map are registered to obtain the initial registration relationship.
9. A positioning device, characterized in that: The device comprises: An acquisition module, used for acquiring a first brain image and a second brain image, and extracting blood vessel features and sulcus features from the first brain image to obtain a matching image template; A registration module, used for registering the matching image template and the second brain image to obtain a target registration relationship; A positioning module is used to locate the target position in the second brain image according to the target registration relationship and the target position in the matching image template.
10. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 8 are implemented.
11. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 8 are implemented.