A cross-modality cell image registration method based on cell morphology mask
By converting multimodal cell images into geometric masks and using spatial moment features and frequency domain cross-correlation algorithms for cross-modal image registration, the problems of high computational complexity and low accuracy in existing technologies are solved, and efficient registration at the subcellular level is achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- UNIV OF SCI & TECH OF CHINA
- Filing Date
- 2026-04-29
- Publication Date
- 2026-07-31
AI Technical Summary
Existing multimodal cell image registration methods suffer from high computational complexity, low computational efficiency, and difficulty in achieving accurate registration at the subcellular level when dealing with visual differences between cross-modal images. In particular, they are prone to getting trapped in local optima when dealing with large-scale data.
Multimodal cell images are converted into geometric masks, and coarse registration is performed using spatial moment features. Fine registration is performed by combining frequency domain cross-correlation and random sampling consistency algorithms. Subcellular-level accurate registration is achieved through cascaded parameter search strategy and centroid matching.
It significantly improves the computational efficiency and accuracy of cross-modal image registration, enabling rapid processing of ultra-large cell images on ordinary computing power, and achieving precise registration at the subcellular level.
Smart Images

Figure CN122492770A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of digital pathological image processing, and specifically to a cross-modal cell image registration method based on cell morphology masks. Background Technology
[0002] In single-cell spatial transcriptomics research and modern digital pathology analysis, researchers often need to accurately map the spatial location of images of the same tissue section under different staining modalities or different omics. For example, aligning a hematoxylin-eosin (HE) stained bright-field image containing histopathological features with a DAPI fluorescence image containing spatial gene expression coordinates in spatial multi-omics data is a key prerequisite for achieving multimodal integrated analysis of morphology and spatial genomics.
[0003] Currently, existing technologies have proposed several solutions for cross-modal cell image registration: 1. Registration methods based on manual or automated feature point extraction. This approach typically involves: manually selecting or using algorithms to extract key feature points (such as tissue edges, morphological markers, etc.) from different omics images; establishing spatial mapping relationships through feature point matching; and registering multiple modal images to the same coordinate system for analysis. However, manual feature point extraction relies on visual observation, which is tedious and time-consuming. Algorithm-based feature point selection methods, such as Scale Invariant Feature Transform (SIFT) and Accelerated Robust Feature Transform (SURF), have limited robustness. Because HE staining (multi-color, high-texture) and fluorescence staining (dark field, discrete highlights) differ fundamentally in their imaging principles, pixel-level feature descriptors (such as SIFT and SURF) are prone to redundancy or spurious matching in complex biological tissue textures.
[0004] 2. Registration methods based on cell point clouds. This approach typically involves: identifying cell contours in multimodal cell images, extracting the geometric centers of each cell to construct a two-dimensional point cloud, and then using a point cloud registration algorithm to solve for transformation parameters, thereby achieving image alignment. However, this type of method faces computational efficiency and global constraint issues when dealing with extremely large datasets. Full-view digital slices (WSI) typically have extremely high spatial resolution (GB-level pixels) and contain hundreds of thousands of cell entities. Without effective global pose prior alignment, directly performing global matching on massive point clouds not only results in high computational complexity but also tends to converge to local optima in areas with highly repetitive tissue structures. Furthermore, the algorithm has limited ability to correct for nonlinear or shear deformations generated during slice preparation.
[0005] Therefore, there are still some limitations in the existing field of multimodal ultra-large cell image registration: the dramatic visual differences between cross-modal images make it challenging to directly use pixel features for robust matching; while ensuring the computational efficiency of ultra-large resolution images, how to establish a multi-scale constraint mechanism from global to local to avoid getting trapped in local optima and achieve sub-cellular level registration accuracy is an urgent problem to be solved in the current field. Summary of the Invention
[0006] To address the registration requirements of multimodal ultra-large cell images, this invention proposes a cross-modal cell image registration method based on cell morphology masks. The main inventive concepts are reflected in the following aspects: Transforming multimodal cell images into geometric masks eliminates modal differences, thereby eliminating the huge contrast differences and texture interference between multimodal images at the source. This simplifies the complex cross-modal pixel matching task into robust geometric topology distribution matching, significantly improving the convergence probability of the algorithm under heterogeneous data.
[0007] The initial offset parameters are directly analyzed using spatial moments, and global large-scale offset is solved using frequency domain cross-correlation. This greatly reduces the computational complexity of GB-level image registration while ensuring cell-level computational accuracy, achieving a balance between performance and accuracy.
[0008] By establishing point-to-point constraints on the centroid of single cells at the subcellular level and combining this with a random sampling consensus algorithm to remove outliers, a fully affine correction matrix that can correct subtle distortions in the image is calculated, further improving registration accuracy and achieving perfect overlay of multimodal cell images at subcellular resolution.
[0009] To solve the above-mentioned technical problems, the present invention adopts the following technical solution: A cross-modal cell image registration method based on cell morphology masks includes: Obtain cell images of different modalities from the same tissue slice, namely the reference image and the floating image, segment the cell nucleus boundaries, and generate corresponding binary mask images; The spatial moment features of the two binary mask images are extracted respectively. The centroid, principal axis deflection angle and scaling factor based on quantile span of the binary mask images are calculated to construct a coarse registration matrix and complete the global coarse registration. The coarsely registered binary mask image is downsampled, and the rotation and scaling parameters are traversed through the cascaded parameter search strategy. The translation vector is calculated by combining the frequency domain phase cross-correlation algorithm. The fine registration matrix is optimized using the Dice coefficient as the criterion to complete the global fine registration. Extract the centroid coordinates of single cells from the binary mask images of the reference image and the floating image. After initially projecting the centroid of the binary mask image of the floating image, perform nearest neighbor matching using a KD tree and fit the affine transformation matrix for fine-tuning using a random sampling consensus algorithm. The affine transformation matrix, fine registration matrix, and coarse registration matrix are concatenated to generate the final transformation matrix, which is then applied to the floating image to achieve subcellular precision registration with the reference image.
[0010] In one embodiment, the step of acquiring different modal cell images of the same tissue slice, namely a reference image and a floating image, segmenting the cell nucleus boundaries, and generating corresponding binary mask images specifically includes: Using a pre-trained deep learning segmentation network, reference images and floating images of the same tissue slice are processed separately, and finally two binary mask images reflecting the spatial distribution of cell nuclei are output.
[0011] In one embodiment, the step of extracting the spatial moment features of the two binary mask images, calculating the centroid, principal axis deflection angle, and scaling factor based on the quantile span of the binary mask images, constructing a coarse registration matrix, and completing global coarse registration specifically includes: Calculating the centroid of a binary mask image using second-order central moments and spindle deflection angle ; where the principal spindle deflection angle The calculation formula is: ; in, For binary mask images The first central moment; The moment of inertia in the horizontal direction. The moment of inertia represents the vertical direction. Indicates the central moment of the mixture; Extract the 1st and 99th quantile spans of the non-zero pixel coordinates from the two binary mask images, and calculate the scaling factor. ; This represents the effective distribution span of the coordinates of non-zero pixels in the reference image. This represents the effective distribution span of non-zero pixel coordinates in a floating image; A coarse registration matrix is constructed using the image centroid, principal axis deflection angle, and scaling factor. This completes the global coarse registration of the binary mask image of the floating image and the binary mask image of the reference image.
[0012] In one embodiment, the process of downsampling the coarsely registered binary mask image, traversing rotation and scaling parameters through a cascaded parameter search strategy, calculating the translation vector using a frequency domain phase cross-correlation algorithm, and optimizing the fine registration matrix using the Dice coefficient as a criterion specifically includes: The binary mask image is scaled proportionally so that the long side of the binary mask image is scaled to the scale of a set number of pixels. Coarse search phase: within the angle range Scaling range in 0.5° increments. Inner Traverse the system by step size; Fine search phase: In the vicinity of the coarse search results, the step size is reduced by a factor of 4 and local fine-tuning is performed using the corresponding registration parameters; Displacement compensation: Under each set of rotation and scaling parameters, a sub-pixel level translation vector is calculated in the frequency domain using a phase cross-correlation operator. ; Using the Dice coefficient to assess overlap: ; in, The binary mask image is obtained by applying the registration parameters of the fine search stage to the binary mask image corresponding to the coarsely registered floating image. The fine registration matrix is obtained by maximizing the Dice coefficient and combining it with the continuous space optimization algorithm to eliminate the residual error under the step size constraint.
[0013] In one embodiment, the extraction of single-cell centroid coordinates from the binary mask images of the reference image and the floating image, the initial projection of the centroid of the binary mask image of the floating image, the use of a KD tree for nearest neighbor matching, and the use of a random sampling consensus algorithm to fit an affine transformation matrix for fine-tuning specifically include: Extract the centroid set of all single cells in the binary mask image of the reference image at the original resolution. The set of centroids of all single cells in the binary mask image of the floating image. ; Will via After transformation, the KD-Tree algorithm is used in... Search for the nearest neighbor of each centroid point and calculate the distance. ; For fine registration matrix, This is the initial transformation matrix; Fully Affine Fitting: Filtering Distance For point pairs smaller than a threshold, mismatched points are removed using a random sampling consensus algorithm, and a 6-DOF affine transformation matrix including shear parameters is fitted. .
[0014] In one embodiment, the concatenation of the affine transformation matrix, the fine registration matrix, and the coarse registration matrix to generate the final transformation matrix and apply it to the floating image to achieve subcellular precision registration with the reference image specifically includes: Final transformation matrix ; These are the affine transformation matrix, the fine registration matrix, and the coarse registration matrix, respectively. The final transformation matrix transforms the coordinates of each pixel in the floating image. Mapping to the reference image space enables registration between the floating image and the reference image.
[0015] Compared with the prior art, the beneficial technical effects of the present invention are: 1. Strong cross-modal adaptability: This invention first transforms heterogeneous original images into a unified binary cell nucleus mask, and transforms the contrasting pixel brightness into the geometric topological relationship of the contrasting cell nucleus distribution, completely eliminating the interference of color and texture. It can also achieve accurate registration for images with great differences between modalities, such as HE-stained bright-field images and DAPI-stained fluorescent images.
[0016] 2. Fast registration speed: This invention breaks down the arduous task of high-resolution registration. Coarse registration quickly obtains the initial registration parameters by calculating spatial moments, which greatly reduces the parameter space that needs to be traversed in subsequent fine registration, and significantly reduces the amount of computation. Fine registration speeds up the process by downsampling the original large image and further speeds it up by using frequency domain operations, which greatly reduces the computation time and enables it to process ultra-large cell images quickly on ordinary computing power.
[0017] 3. Achieving subcellular-level registration accuracy: In the fine-tuning registration stage, blurred pixel areas are discarded. Instead, paired single-cell physical centroids are used in the roughly aligned space, and the RANSAC algorithm is used to robustly remove interference from damaged or missing cells. Finally, the registration matrix used for fine-tuning is calculated, and subcellular-precision registration effect is achieved. Attached Figure Description
[0018] Figure 1 This is a flowchart of the method of the present invention.
[0019] Figure 2 The process of registering DAPI-stained images of mouse kidney tissue sections to HE-stained images. Figure 2 The green area represents the outline of cell nuclei stained with HE, and the red area represents the outline of cell nuclei stained with DAPI. When the two overlap, they appear yellow.
[0020] Figure 3 This is a histogram showing the distribution of registration errors before and after fine-tuning the registration. Detailed Implementation
[0021] A preferred embodiment of the present invention will now be described in detail with reference to the accompanying drawings.
[0022] like Figure 1 As shown, a cross-modal cell image registration method based on cell morphology masks in this invention includes the following steps: S1. Obtain cell images of different modalities from the same tissue slice, namely the reference image and the floating image, segment the cell nucleus boundary, and generate the corresponding binary mask image. S2, extract the spatial moment features of the two binary mask images respectively, calculate the centroid, principal axis deflection angle and scaling factor based on quantile span of the binary mask images, construct the coarse registration matrix, and complete the global coarse registration; S3. The coarsely registered binary mask image is downsampled. The rotation and scaling parameters are traversed through the cascaded parameter search strategy. The translation vector is calculated by combining the frequency domain phase cross-correlation algorithm. The fine registration matrix is optimized using the Dice coefficient as the criterion to complete the global fine registration. S4. Extract the centroid coordinates of single cells from the binary mask images of the reference image and the floating image. After initially projecting the centroid of the binary mask image of the floating image, perform nearest neighbor matching using a KD tree and fit the affine transformation matrix for fine-tuning using a random sampling consensus algorithm. S5 concatenates the affine transformation matrix, fine registration matrix, and coarse registration matrix to generate the final transformation matrix, which is then applied to the floating image to achieve subcellular precision registration with the reference image.
[0023] The present invention will be described in detail below in several parts.
[0024] 1. Cell mask generation.
[0025] Different modal cell images of the same tissue slice are obtained, namely the reference image and the floating image. The cell nuclear boundaries in the images are identified by the cell segmentation model, and corresponding binary mask images are generated to eliminate the texture and color differences of the original image.
[0026] 2. Coarse registration based on space moments.
[0027] Spatial moment features are extracted from two binary mask images, and their respective centroids and principal axis deflection angles are calculated. After rotating and aligning all non-zero pixel coordinates of the images towards the principal axis, the pixel span on the principal and vertical axes is calculated using the coordinate quantiles (to remove outliers). Based on the centroid deviation, angle difference, and span ratio between the two images, an initial affine transformation matrix (coarse registration matrix) is constructed, which includes translation (displacement between the centroids of the two images), rotation angle (principal axis deflection angle), and initial scaling parameters (scaling factors). Based on this matrix, the binary mask image of the floating image is mapped to the coordinate space of the reference image, completing the global coarse registration of images of different modalities.
[0028] 3. Cascaded fine registration based on frequency domain cross-correlation.
[0029] The coarsely registered floating mask (a binary mask image of the floating image) and the reference mask (a binary mask image of the reference image) are downsampled proportionally to below the preset maximum long side size. A cascaded parameter search strategy is constructed, traversing the search for rotation angle and scaling parameters. Initially, a large step size is used for fast scanning. For each attempted state, the optimal translation position in that state is calculated using a frequency domain phase cross-correlation algorithm. Simultaneously, the Dice coefficient is used as a scoring standard to evaluate the degree of mask overlap. After finding the optimal parameters, a smaller step size is used to traverse and search again around these parameters to obtain more accurate rotation and scaling parameters. Finally, a continuous space optimization algorithm is introduced to eliminate residual errors under the step size constraint, thereby solving for the fine registration matrix that enables cell-level alignment of the cell nucleus distributions of the two modalities. The obtained fine registration matrix is applied to the coarsely registered floating mask to complete the global fine registration of images of different modalities.
[0030] 4. Fine-tuned registration based on centroid matching of sampled cells.
[0031] Extract the centroid coordinates of all single cells in the undownsampled original image. Using coarse and fine registration matrices, initially project the centroid set of the floating mask into the reference image space. Employ the KD-Tree algorithm for nearest neighbor matching of the bipoint set, randomly selecting a specified number of matching pairs from the pairing pool. Then, use the Random Sample Consensus (RANSAC) algorithm with a reprojection error threshold to solve for the final affine transformation matrix used for fine-tuning.
[0032] 5. Transformation cascade.
[0033] The finely tuned affine transformation matrix, the fine registration matrix, and the coarse registration matrix are concatenated by matrix multiplication in the order of the mathematical transformations to generate the final transformation matrix mapped to the original image coordinate system. This final transformation matrix is then applied to the original floating image to achieve subcellular precision registration with the reference image.
[0034] In this invention, after obtaining the mask image, all calculations and registrations (coarse registration, fine registration, and fine adjustment) are performed on the mask. Only the final transformation matrix generated at the end is applied to the initial floating image to complete the registration.
[0035] Example: This embodiment uses HE-stained images (reference images) and DAPI-fluorescent stained images (floating images) of mouse kidney tissue sections as experimental objects to explain in detail the specific implementation process of a cross-modal cell image registration method based on cell morphology masks proposed in this invention.
[0036] (1) Cell segmentation: Using the pre-trained deep learning segmentation network Cellpose, HE-stained bright-field images (HE-stained bright-field images have their hematoxylin channel information extracted beforehand) and DAPI fluorescence-stained images were processed respectively. The final output consisted of two binary mask images reflecting the spatial distribution of cell nuclei: a reference mask and a reference mask. With floating masks .like Figure 2 As shown, the HE mask image (reference mask) is green, and the DAPI mask image (floating mask) is red. The two have significant differences in spatial orientation and size.
[0037] (2) Global coarse registration based on space moments: To eliminate differences in scanner placement angle and starting coordinates, this invention achieves rapid alignment through analytical geometric features. Calculation of the geometric center and principal axis: The centroid of the mask is calculated using the second-order central moment. and spindle deflection angle The principal axis angle The calculation formula is: ; in, For image The central moment of the order. The moment of inertia (or second-order horizontal central moment) represents the horizontal direction and measures the degree of dispersion of image pixels relative to the centroid in the x-axis direction. The moment of inertia (or second-order vertical central moment) represents the vertical direction and measures the degree of dispersion of image pixels relative to the centroid in the y-axis direction. The mixed central moment (or orthometric moment) measures the correlation of image pixel distribution in the x and y directions. It is the core parameter for calculating the principal axis deflection angle and reflects the direction of shape distortion or tilt.
[0038] Scale estimation: Extract the 1st and 99th quantile spans of the non-zero pixel coordinates of the two images and calculate the scaling factor. .
[0039] It represents the effective distribution span of the coordinates of non-zero pixels in the reference image, and is calculated as the difference between the 99th quantile and the 1st quantile of the horizontal or vertical coordinates of non-zero pixels in the reference image; It represents the effective distribution span of the coordinates of non-zero pixels in the image to be registered (floating image), and is calculated as the difference between the 99th quantile and the 1st quantile of the horizontal or vertical coordinates of the non-zero pixels in the image to be registered.
[0040] Construct the initial matrix: Construct the initial affine transformation matrix (coarse registration matrix) using the parameters described above. This achieves initial image reset. For example... Figure 2 As shown, the overlapping area of the two images is yellow. The higher the proportion of yellow, the better the registration effect between the two. The HE-stained bright field image and the DAPI mask image after coarse matching are close to overlapping, but there is still a slight deviation.
[0041] (3) Cascaded fine registration based on frequency domain phase cross-correlation: Based on the coarse registration, this embodiment employs a cascaded search strategy to further refine the parameters: Downsampling: The mask image is scaled proportionally to a scale with a long side of 3000 pixels to balance computational accuracy and speed.
[0042] Coarse search phase: within the angle range Step size, scaling range Inner Traverse the system by step size.
[0043] Fine search phase: Near the results of the coarse search, the step size is reduced by a factor of 4 for local fine-tuning.
[0044] Displacement compensation: For each set of rotation and scaling parameters, the phase cross-correlation operator is used to calculate the sub-pixel level translation vector in the frequency domain. .
[0045] Performance evaluation: The overlap ratio is evaluated using the Dice coefficient. The Dice calculation formula is as follows: ; in The transformed floating mask is used. The fine registration matrix is obtained by maximizing the Dice coefficients combined with the Powell optimization algorithm. .like Figure 2 As shown, the HE staining bright-field image and the finely matched DAPI fluorescence staining image completely overlap, turning yellow overall, indicating that the registration accuracy between the two is high.
[0046] (4) Centroid fine-tuning based on RANSAC robust fitting: like Figure 2 As shown in the magnified partial image, there are still slight discrepancies between the HE-stained bright-field image and the DAPI fluorescence-stained image after fine-tuning. In this embodiment, subcellular fine-tuning is performed.
[0047] Centroid Extraction: Extract the reference mask centroid point set at the original resolution. and floating mask centroid set .
[0048] Establish a connection: via After transformation, the KD-Tree algorithm is used in... Search for the nearest neighbor of each point and calculate the distance. .
[0049] Fully Affine Fitting: Filtering Distance For point pairs smaller than a threshold (set to the 90th quantile of all distances d in this embodiment), mismatched points are removed using the RANSAC algorithm, and a 6-DOF affine transformation matrix including shearing parameters is fitted. .
[0050] (5) Results output and verification The final transformation matrix is defined as a concatenated product: .
[0051] This matrix is used to represent the coordinates of each pixel in the DAPI fluorescent staining image. Mapped to the HE staining bright-field image space.
[0052] like Figure 2 As shown, the magnified local images reveal that the cell nuclei are almost completely shifted in both the HE-stained bright-field image and the finely adjusted DAPI fluorescence-stained image. (Control) Figure 3 (Calculate the distance between the centroids of the corresponding cell nuclei in the HE-stained bright-field images and DAPI-stained fluorescent images before and after fine-tuning registration, and draw their histogram distribution.) It can be seen that the peak of the histogram after fine-tuning shifts significantly to the left of zero (the horizontal coordinate of the peak decreases from 5.85 pixels to 1.95 pixels), indicating that the registration accuracy is significantly improved, and the registration accuracy of the two reaches the subcellular level.
[0053] The terminology used herein is for the purpose of describing particular embodiments only and is not intended to limit the invention. The terms “comprising,” “including,” etc., as used herein indicate the presence of the stated features, steps, operations, and / or components, but do not exclude the presence or addition of one or more other features, steps, operations, or components.
[0054] It should be understood that although the steps in the flowcharts of the accompanying drawings are shown sequentially as indicated by the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some of the steps in the flowcharts of the accompanying drawings may include multiple steps or stages, which are not necessarily completed at the same time, but may be executed at different times, and the execution order of these steps or stages is not necessarily sequential, but may be performed alternately or in turn with other steps or at least some of the steps or stages of other steps.
[0055] 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.
[0056] It will be apparent to those skilled in the art that the present invention is not limited to the details of the exemplary embodiments described above, and that the invention can be implemented in other specific forms without departing from its spirit or essential characteristics. Therefore, the embodiments should be considered in all respects as exemplary and non-limiting, and the scope of the invention is defined by the appended claims rather than the foregoing description. Thus, all variations falling within the meaning and scope of equivalents of the claims are intended to be included within the present invention, and no reference numerals in the claims should be construed as limiting the scope of the claims.
[0057] Furthermore, it should be understood that although this specification describes embodiments, not every embodiment contains only one independent technical solution. This narrative style is merely for clarity. Those skilled in the art should consider the specification as a whole, and the technical solutions in each embodiment can also be appropriately combined to form other embodiments that can be understood by those skilled in the art.
Claims
1. A cell morphology mask based cross-modality cell image registration method, characterized in that, include: Obtain cell images of different modalities from the same tissue slice, namely the reference image and the floating image, segment the cell nucleus boundaries, and generate corresponding binary mask images; The spatial moment features of the two binary mask images are extracted respectively. The centroid, principal axis deflection angle and scaling factor based on quantile span of the binary mask images are calculated to construct a coarse registration matrix and complete the global coarse registration. The coarsely registered binary mask image is downsampled, and the rotation and scaling parameters are traversed through the cascaded parameter search strategy. The translation vector is calculated by combining the frequency domain phase cross-correlation algorithm. The fine registration matrix is optimized using the Dice coefficient as the criterion to complete the global fine registration. Extract the centroid coordinates of single cells from the binary mask images of the reference image and the floating image. After initially projecting the centroid of the binary mask image of the floating image, perform nearest neighbor matching using a KD tree and fit the affine transformation matrix for fine-tuning using a random sampling consensus algorithm. The affine transformation matrix, fine registration matrix, and coarse registration matrix are concatenated to generate the final transformation matrix, which is then applied to the floating image to achieve subcellular precision registration with the reference image.
2. The cell morphology mask based cross-modality cell image registration method according to claim 1, wherein, The process of acquiring different modal cell images of the same tissue slice, namely the reference image and the floating image, segmenting the cell nuclear boundaries, and generating corresponding binary mask images specifically includes: Using a pre-trained deep learning segmentation network, reference images and floating images of the same tissue slice are processed separately, and finally two binary mask images reflecting the spatial distribution of cell nuclei are output.
3. The cell morphology mask based cross-modality cell image registration method of claim 1, wherein, The process involves extracting the spatial moment features of the two binary mask images, calculating the centroid, principal axis deflection angle, and scaling factor based on the quantile span of the binary mask images, constructing a coarse registration matrix, and completing global coarse registration. Specifically, this includes: Calculating the centroid of a binary mask image using second order central moments and a spindle deflection angle ; wherein the spindle deflection angle is calculated according to the formula: ; in, For binary mask images The central moment of the first order; The moment of inertia in the horizontal direction. The moment of inertia represents the vertical direction. Indicates the central moment of the mixture; Extract the 1st and 99th quantile spans of the non-zero pixel coordinates from the two binary mask images, and calculate the scaling factor. ; This represents the effective distribution span of the coordinates of non-zero pixels in the reference image. This represents the effective distribution span of non-zero pixel coordinates in a floating image; A coarse registration matrix is constructed using the image centroid, principal axis deflection angle, and scaling factor. This completes the global coarse registration of the binary mask image of the floating image and the binary mask image of the reference image.
4. The method for cross-modal cell image registration based on cell morphology masks according to claim 1, characterized in that, The process involves downsampling the coarsely registered binary mask image, traversing rotation and scaling parameters using a cascaded parameter search strategy, calculating the translation vector using a frequency domain phase cross-correlation algorithm, and optimizing the fine registration matrix using the Dice coefficient as a criterion. Specifically, this includes: The binary mask image is scaled proportionally so that the long side of the binary mask image is scaled to the scale of a set number of pixels. Coarse search phase: within the angle range Scaling range in 0.5° increments. Inner Traverse the system by step size; Fine search phase: In the vicinity of the coarse search results, the step size is reduced by a factor of 4 and local fine-tuning is performed using the corresponding registration parameters; Displacement compensation: For each set of rotation and scaling parameters, a sub-pixel level translation vector is calculated in the frequency domain using a phase cross-correlation operator. ; Using the Dice coefficient to assess overlap: ; in, The binary mask image is obtained by applying the registration parameters of the fine search stage to the binary mask image corresponding to the coarsely registered floating image. The fine registration matrix is obtained by maximizing the Dice coefficient and combining it with the continuous space optimization algorithm to eliminate the residual error under the step size constraint.
5. The method for cross-modal cell image registration based on cell morphology masks according to claim 1, characterized in that, The process involves extracting the centroid coordinates of single cells from the binary mask images of the reference image and the floating image, initially projecting the centroid of the binary mask image of the floating image, performing nearest neighbor matching using a KD tree, and fitting an affine transformation matrix for fine-tuning using a random sampling consensus algorithm. Specifically, this includes: Extract the centroid set of all single cells in the binary mask image of the reference image at the original resolution. The set of centroids of all single cells in the binary mask image of the floating image. ; Will via After transformation, the KD-Tree algorithm is used in... Search for the nearest neighbor of each centroid point and calculate the distance. ; For fine registration matrix, This is the initial transformation matrix; Fully Affine Fitting: Filtering Distance For point pairs smaller than a threshold, mismatched points are removed using a random sampling consensus algorithm, and a 6-DOF affine transformation matrix including shear parameters is fitted. .
6. The method for cross-modal cell image registration based on cell morphology masks according to claim 1, characterized in that, The process of concatenating the affine transformation matrix, fine registration matrix, and coarse registration matrix to generate the final transformation matrix and applying it to the floating image to achieve subcellular precision registration with the reference image specifically includes: Final transformation matrix ; These are the affine transformation matrix, the fine registration matrix, and the coarse registration matrix, respectively. The final transformation matrix transforms the coordinates of each pixel in the floating image. Mapping to the reference image space enables registration between the floating image and the reference image.