Method and device for predicting female age by using cervical cell image, storage medium and program

By detecting the superficial, middle and bottom squamous epithelial cells in cervical cell images, combined with deep learning technology, the problem of failure to use cervical squamous epithelial cell distribution information to predict women's age in the existing technology is solved, and efficient age prediction and health evaluation assistance is achieved.

CN120451969APending Publication Date: 2025-08-08WUHAN LANTINGYUN MEDICAL LAB CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510463679.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-14
Publication Date
2025-08-08

AI Technical Summary

Technical Problem

The prior art has failed to effectively use the distribution information of cervical squamous epithelial cells to predict female age, which limits the mining of multiple information and health association analysis of cervical cell screening results.

Method used

By analyzing cervical cell images, the surface, middle and bottom squamous epithelial cells were detected using the target detection model, and the deep features were extracted in combination with the pre-trained general basic model of pathology, and the regression prediction model was used to simulate age relationships and predict female age.

Benefits of technology

Accurate age prediction based on cervical cell images is achieved, providing cofactors for health evaluation, and improving the information richness and prediction accuracy of cervical cell screening.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120451969A_ABST
    Figure CN120451969A_ABST
Patent Text Reader

Abstract

The invention provides a method for predicting female age by using cervical cell images, and relates to the technical field of medical image processing, and the method comprises the following steps: S10, image collection: obtaining cervical cell images which are screened as NILM through liquid-based cytology at different age stages and are excluded from HPV infection; s20, squamous epithelial cell detection: using a target detection model to perform squamous epithelial cell detection on a surface layer, a middle layer and a bottom layer of the cervical cell image; and S30, squamous epithelial cell feature extraction and fusion: using the pre-trained pathology general basic model to extract deep features of squamous epithelial cells. Compared with the prior art, the method has the following beneficial effects: firstly, a prediction target is optimized: the morphological characteristics and quantity distribution of the cervical squamous epithelial cells can reflect the real age of a woman to a certain extent; 2, efficient feature expression: extracting cervical squamous epithelial cell features by using a computational pathology general large model UNI pre-trained in a large-scale medical image; and 3, taking as a health evaluation auxiliary factor.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of medical image processing, and in particular to a method for predicting female age using cervical cell images. Background Art

[0002] Cervical cancer is a common disease. 90% of cervical cancer cases originate from squamous cell carcinoma, which is formed by squamous metaplasia of the transformation zone, while the remaining 10% originate from adenocarcinoma, which originates from the glandular cells in the lining of the cervix. The stratified squamous epithelium covering the surface of the cervix helps prevent the invasion of toxins and infection. When this epithelium undergoes abnormal changes, it may indicate a potential disease risk, such as precancerous lesions or cancer formation. Therefore, during cervical cytology screening, squamous epithelial cells are usually the focus of examination.

[0003] In addition to detecting the presence of precancerous lesions, the morphology and distribution characteristics of squamous epithelial cells may also contain important information. The cervical squamous epithelium is a stratified structure composed of multiple layers of cells with varying morphologies. It extends from the endocervical canal and is continuous with the vaginal epithelium. Depending on the stage of maturation, these cell layers can be divided into basal, intermediate, and surface layers. Basal cells are roughly cuboidal and have the highest nuclear-to-cytoplasmic ratio among normal squamous cells. As cells migrate from the basal layer to the epithelial surface, morphological and functional changes occur during maturation. The cells gradually become flattened, the nuclear volume decreases, and the cell volume increases. Liquid-based cytology (LBC) samples are used and preserved as digital images with the help of imaging and digital processing technology for research and observation. The development of deep learning technology has also promoted its use in cervical image analysis to assist doctors in identifying cells, detecting abnormalities, and segmenting cells.

[0004] Based on this, in the field of cervical cytology screening, existing technologies have significant difficulties. Although it is known that cervical squamous epithelial cells have a layered structure (basal layer, middle layer, surface layer) and the cell morphology of each layer changes with the maturity stage, it has not yet been realized that there is a potential correlation between the distribution information of cervical squamous epithelial cells (such as the proportion of cells in different layers) and female age, and there has been no attempt to use this correlation to accurately predict female age through deep learning technology. This technical gap makes it impossible to provide more comprehensive health-related information for cervical cell screening results from the dimension of cell distribution, including age-related physiological characteristics to assist in judgment, which limits the depth of digital medicine in the field of cervical screening for multi-information mining and comprehensive application. Therefore, in response to this unresolved difficulty in existing technology, through analysis, it was found that the proportion of surface squamous epithelial cells was negatively correlated with the average age of women, and the proportion of basal squamous epithelial cells was positively correlated with the average age of women. Then, a method of using deep learning technology to process cervical cell images to predict female age was proposed, which opened up a new perspective for the analysis of cervical cell screening results. Summary of the Invention

[0005] In view of the shortcomings of the above-mentioned existing technologies, the technical problem to be solved by the present invention is to provide a method, device, storage medium and program for predicting female age using cervical cell images, which can analyze and find that the proportion of surface squamous epithelial cells is negatively correlated with the average age of women, and the proportion of bottom squamous epithelial cells is positively correlated with the average age of women.

[0006] To solve the above technical problems, the technical solution adopted by the present invention is as follows: the present invention provides a method for predicting female age using cervical cell images, which includes the following steps: S10. Image acquisition: Acquire images of cervical cells at different age groups that have been screened as NILM by liquid-based cytology and have excluded HPV infection; S20, Squamous epithelial cell detection: Use the target detection model to detect the surface, middle, and bottom squamous epithelial cells in cervical cell images; S30, Squamous epithelial cell feature extraction and fusion: Use the pre-trained general pathology basic model to extract the deep features of squamous epithelial cells, fuse the extracted features, and output the overall sample features; S40, Age Prediction: Input the total characteristics of the sample into the regression prediction model, simulate the correspondence between the sample characteristics and the actual age of the examinee, and perform age prediction.

[0007] In the preferred embodiment, step S10 further includes segmenting each full-field cervical cell image to obtain cervical cell sub-images, performing preprocessing on the cervical cell sub-images to obtain preprocessed cervical cell sub-images. ; The specific steps of step S10 are as follows: S11. Image segmentation and data cleaning: Each full-field cervical cell image is segmented using the overlapping sliding window method to generate 12 cervical cell sub-images with n×n pixels. Blurred cervical cell sub-images are removed based on SSIM. Among them, the SSIM value range is [-1,1]; S12. Image preprocessing: using a median filter algorithm to dynamically adjust the median filter kernel size to perform denoising on the cervical cell sub-image, thereby obtaining a denoised cervical cell sub-image; CLAHE is used to enhance the contrast of the cervical cell sub-image after denoising; S13. Dataset division: The enhanced cervical cell sub-images are divided into training set and test set by stratified sampling in a ratio of 4:1; Stratified sampling division includes age stratification and sample allocation.

[0008] In a preferred solution, in step S13, the calculation formula for age stratification is as follows: ; in, is the age group number of the cervical cell sub-image. is the age of the sample, For the floor rounding function, the calculated result is taken as the largest integer not greater than the value; The number of stratification layers is determined to be 6 according to the age of the cervical cell sub-image; The sample distribution is calculated as follows: ; in, is the number of cervical cell sub-images in the training set, is the number of cervical cell sub-images in the test set, is the total number of cervical cell sub-images in a certain age group.

[0009] In a preferred solution, in step S20, the target detection model is attention-enhanced YOLOv7; Detect and predict the bounding box coordinates of each squamous epithelial cell based on the attention-enhanced YOLOv7 model and confidence ; According to the bounding box coordinates and confidence Squamous epithelial cells of different differentiation levels were labeled and classified into superficial, middle, and basal squamous epithelial cells; The specific steps of step S20 are as follows: S21, input the cervical cell sub-image pre-processed in step S10 , extract features through YOLOv7 Backbone and get the initial features ; S22. Input initial features Multi-scale feature fusion is performed through the ELAN module to output enhanced features ; S23, according to the output of ELAN module Using SE attention mechanism to enhance features, we get ; S24, features after SE enhancement Input to YOLOv7 prediction head, output bounding box coordinates , confidence and class probabilities ; S25, according to the confidence level Perform DIoU-NMS, retain The bounding box of according to 、 and confidence Output test results ; S26. According to the bounding box coordinates from Cut out the fine-grained features of the corresponding cell area to obtain the original cell image block ; Scaling the original cell image patch to 224×224 pixels to generate fine-grained feature image blocks ; S27, according to category probability Statistical distribution vector: ; in, is the number of surface cells, is the number of middle layer cells, is the number of bottom cells, is the total number of cells detected.

[0010] In a preferred solution, the universal basic model of pathology pre-trained in step S30 is a UNI model, which is based on the Vision Transformer architecture; The specific steps of step S30 are as follows: S31. Feature extraction: Input fine-grained feature image blocks The UNI model of the pre-trained ViT architecture divides each cell image block into sub-blocks of specific pixels, extracts global features through a multi-head self-attention mechanism, and generates a deep feature vector with a dimension of 1024. ; S32. Feature dimensionality reduction: Take the features of a fixed number B squamous epithelial cells, where the feature dimension of B squamous epithelial cells is B×1024; The principal component analysis method is used to reduce the dimension of the extracted B cell features, compressing the B×1024-dimensional features to 2048 dimensions. The morphological feature vector after dimension reduction is ; S33, Feature Fusion: After dimensionality reduction and distribution vector Splicing on the feature dimension to generate the total features of the fused samples , the formula is as follows: .

[0011] In a preferred solution, the regression prediction model in step S40 is a random forest regression model, and the specific steps are as follows: S41. Total features of input samples and real age label to the random forest regression model; S42, generate 42 unpruned regression decision trees through Bootstrap sampling, and randomly select 45 features for node splitting in each tree; S43, recursively split nodes based on the maximum variance reduction criterion, and optimize hyperparameters through 5-fold cross validation; S44, integrate the prediction results of 42 trees and take the average value to output the predicted age and 95% confidence intervals.

[0012] In the preferred embodiment, the predicted age in step S44 is The formula is: ; in, is the predicted value of the t-th tree; The confidence interval is calculated as follows: .

[0013] In a preferred embodiment, a computer device / equipment / system is also provided, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the above-mentioned method for predicting female age using cervical cell images.

[0014] In a preferred embodiment, another computer non-transitory readable storage medium is provided, on which a computer program / instruction is stored, wherein when the computer program / instruction is executed by a processor, the steps of the above-mentioned method of predicting female age using cervical cell images are implemented.

[0015] In a preferred embodiment, another computer program product is also provided, comprising a computer program / instruction, wherein when the computer program / instruction is executed by one or more processors, the steps of the above-mentioned method for predicting female age using cervical cell images are implemented.

[0016] The present invention provides a method, device, storage medium, and program for predicting female age using cervical cell images. Compared with the prior art, the present invention has the following advantages: First, optimize the prediction target: The morphological characteristics and quantitative distribution of cervical squamous epithelial cells can reflect a woman's true age to a certain extent. Therefore, using the target detection model to detect cervical squamous epithelial cells from cervical cell images for subsequent age prediction can effectively remove irrelevant noise in cervical cell images, allowing the prediction model to focus more on the key information in the cervical images. Second, efficient feature expression: Using the universal large-scale computational pathology model UNI, pre-trained on large-scale medical images, to extract cervical squamous epithelial cell features can obtain more representative deep features. The fusion of a large number of squamous epithelial cell features with cell distribution information can obtain refined features, thereby improving the accuracy of age prediction. Third, as an auxiliary factor for health evaluation: Predicting a woman's age directly from cervical cell images can be used as an auxiliary factor for health evaluation, for example, to assist doctors in detecting gynecological problems such as premature ovarian failure in advance. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] The present invention will be further described below with reference to the accompanying drawings and examples: Figure 1 This is an analysis chart of the relationship between the average age of the female subjects and the proportion of squamous epithelial cells with different degrees of differentiation in the data collected by the present invention; Figure 2 is the cervical cell image used in the present invention; Figure 3 It is a workflow diagram of the present invention; Figure 4 is a flow chart of the method steps of the present invention; Figure 5 This is a result diagram of the cervical squamous epithelial cell detection method of the present invention; Figure 6 This is a result diagram of the age prediction method using cervical cell images according to the present invention; Figure 7 It is a schematic structural diagram of the computer device of the present invention; Figure 8 is a flow chart of the steps of sample screening of the present invention; Figure 9 is a schematic flow chart of step S20 of the present invention; Figure 10 is a flow chart of step S30 of the present invention; Figure 11 This is a histogram of cervical cells of 3000 women of the present invention. DETAILED DESCRIPTION

[0018] In order to better understand the purpose, structure and function of the present invention, the embodiments and features in the embodiments of the present invention can be combined with each other without conflict. The present invention will be described in detail below with reference to the accompanying drawings and in combination with the embodiments.

[0019] In this embodiment, the ratio of cervical squamous epithelial cells with different degrees of differentiation is closely related to the age of women, such as Figure 1 This is an analysis chart of the relationship between the average age of the female subjects and the proportion of squamous epithelial cells with different degrees of differentiation in the data collected by the present invention.

[0020] To further explore this association, this embodiment develops a method for predicting female age using cervical cell images. Predicting female age using cervical cell images can provide a new perspective for cervical cytology screening results and assist in medical decision-making.

[0021] Example 1 like Figures 2-4 As shown, a method for predicting female age using cervical cell images includes the following steps: S10, image acquisition: Figure 11 As shown in the figure, 3,000 cervical cell images of women aged 36 to 65 years were collected from multiple medical institutions.

[0022] Among them, all cervical cell images were NILM (negative) after liquid-based cytology screening, and HPV infection-positive samples were excluded by PCR testing (HPV-DNA negative); In this embodiment, Figure 8 As shown, step S1 specifically involves obtaining an acquisition device. After acquiring images of cervical cells that have undergone cervical cytology examination and are determined to be normal, each full-field cervical cell image is divided into 12 cervical cell sub-images with a pixel size of 4096×4096 and an RGB color space. An overlapping sliding window method is used to ensure complete coverage of the squamous epithelial cell area.

[0023] Furthermore, the cervical cell sub-image is cleaned and pre-processed in sequence to obtain the pre-processed cervical cell sub-image. , the preprocessed cervical cell sub-image The dataset is divided into training set and test set in a ratio of 4:1.

[0024] Specifically, the data cleaning standard for cervical cell sub-images is to delete severely blurred or noisy cervical cell images and filter blurred images in the following manner: Based on the image clarity assessment, the structural similarity index (SSIM) is used to quantify the degree of blur. The image is removed when the threshold is set to SSIM < 0.85. The SSIM is calculated as follows: ; in, is the local mean, is the standard deviation, is the covariance, is a stability constant.

[0025] It should be noted that the structural similarity index (SSIM) is used to measure the similarity between two images x and y. It comprehensively considers the brightness, contrast, and structural information of the image. By combining and weighting these factors, a similarity index with a value range of -1 to 1 is obtained. The closer the value is to 1, the more similar the two images are.

[0026] Specifically, the preprocessing of the cervical cell sub-image includes denoising the image using a median filter algorithm with a filter kernel size of 11, and improving the image contrast using the contrast-limited adaptive histogram equalization (CLAHE) method with a window size of (8, 8) and a contrast limit threshold of 5.0, as follows: De-noising uses adaptive median filtering, dynamically adjusts the filter kernel size, filters out salt and pepper noise, and retains cell boundary information.

[0027] In an implementable manner, the initial kernel size may be: 11×11.

[0028] The update formula for the median filter kernel size is: ; in, is the current median filter kernel size, the initial value is 11×11, is the noise standard deviation, estimated by wavelet transform.

[0029] Contrast enhancement was performed using contrast-limited adaptive histogram equalization (CLAHE) with a window size of 8×8 and a contrast-limited threshold. , then the histogram clipping formula is: ; in, is the frequency of gray level (i) in the original histogram, is the total number of pixels in the image, The grayscale level is usually 256, which indicates the number of possible grayscale values in the image.

[0030] Specifically, in contrast-limited adaptive histogram equalization (CLAHE), excessive enhancement of local contrast is prevented. By clipping the histogram, the frequency of certain gray levels can be avoided from being too high, thereby ensuring that the image does not suffer from local distortion while enhancing the contrast.

[0031] The data set is divided by stratified sampling as follows: After data cleaning and preprocessing, the cervical cell sub-images were stratified and sampled, and divided into a training set (2400 cases) and a test set (600 cases) at a ratio of 4:1. The stratified sampling method ensured that the proportions of samples of different age groups in the training set and the test set were consistent, avoiding model bias caused by uneven age distribution. The calculation formula for age stratification is: ; in, The age group number of the cervical cell sub-image is counted starting from 1. is the age of the cervical cell sub-image (years), This is a floor function that rounds the result to the maximum integer not greater than this value.

[0032] Specifically, the above formula is used to stratify the cervical cell sub-images according to age, and the age of the cervical cell sub-images is Subtract 36, divide by 5, round down, and add 1 to get the age group number of the cervical cell sub-image.

[0033] Stratified by age, with every 5 years as one layer, the number of stratification layers is 6 [36-40, 41-45, 46-50, 50-55, 56-60, 60-65 years old]; Using K-Fold cross validation (K=5), the calculation formula for the number of cervical cell sub-images per layer is: ; in, is the number of cervical cell sub-images in the training set, is the number of cervical cell sub-images in the test set, is the total number of cervical cell sub-images in a certain age group, This is a floor function that rounds the result to the maximum integer not greater than this value.

[0034] Specifically, the formula is used to assign cervical cell sub-images of each age group into training and test sets. is the total number of cervical cell sub-images in this age group 4 / 5 is rounded down; Equal to the total number of cervical cell sub-images minus The number of cervical cell sub-images is increased, and 5-Fold cross-validation is used to make full use of the cervical cell sub-image data, thereby improving the generalization ability of the model and the accuracy of the evaluation.

[0035] In this embodiment, Figure 9As shown, step S20, squamous epithelial cell detection and classification: use the attention-enhanced YOLOv7 target detection model to detect the surface, middle and bottom squamous epithelial cells of the cervical cell image, perform SE attention enhancement on each ELAN module in YOLOv7 through a specific formula to obtain the ELANSE module, improve the accuracy of YOLOv7 in detecting the bottom squamous epithelial cell target, use the attention-enhanced YOLOv7 target detection model to detect multiple squamous epithelial cells and predict the bounding box and confidence of each squamous epithelial cell, and mark the squamous epithelial cells of different differentiation degrees with borders and classify them into surface, middle and bottom squamous epithelial cells. This method detects the position and quantity distribution of the surface, middle and bottom squamous epithelial cells in the cervical cell image.

[0036] In this embodiment, the target detection model architecture is as follows: The YOLOv7 detection framework is used, and its core modules include: Backbone: CSPDarknet53 is used as the feature extraction backbone network, responsible for extracting multi-scale features. Features at different scales can capture different levels of cellular information. For example, large-scale features can detect the overall morphology of the cell, while small-scale features can focus on detailed features of the cell, such as the texture of the cell nucleus.

[0037] Neck: The ELAN (Enhanced Lightweight Aggregation Net) module is used for feature fusion. The model can comprehensively utilize information at all scales, while the SE attention mechanism can highlight the features of key channels and improve the model's sensitivity to important information.

[0038] Head: Outputs bounding box coordinates, confidence, and category probability. The bounding box coordinates are used to locate the position of the cell, the category probability is used to distinguish whether the cell is in the surface, middle, or bottom layer, and the confidence indicates the model's degree of trust in the detection result.

[0039] The specific steps of step S20 in this embodiment are as follows: S21, Backbone feature extraction: the cervical cell sub-image pre-processed in step S10 Input into the pre-trained YOLOv7 model and extract the initial features through the CSPDarknet53 backbone network of the YOLOv7 model. The formula is as follows: ; Get initial features ; in, is the basic feature map, extracted by CSPDarknet53 from the preprocessed image in step S1, containing the preliminary texture and edge information of the cell area, with a dimension of , is the spatial resolution of the basic feature map, which is the size of the input cervical cell sub-image (4096×4096) after downsampling. is the number of channels, indicating the channel dimension of the feature map, and each channel corresponds to different types of cell features.

[0040] S22, ELAN module multi-scale fusion: the initial features Input to the ELAN module for multi-scale feature fusion, and output to generate enhanced feature map , the specific formula is as follows: ; in, Features of different scales are fused through the ELAN module to enhance the multi-scale representation capability of features.

[0041] Specifically, features of different receptive fields are fused through multi-branch convolution (3×3, 5×5 kernels), the dimensions are adjusted after splicing the output channels, and the contextual perception ability of features is improved through cross-layer connection and multi-scale path fusion to capture the morphological differences of surface, middle and bottom cells.

[0042] S23, SE attention enhancement: According to the output of the ELAN module The SE attention mechanism is used to enhance the features of key cell regions, and we get ; The specific formula calculation steps are as follows: S231, the output of the ELAN module is pooled by global average pooling The spatial information of is compressed into a scalar value of the channel weight to extract channel-level statistical features. The formula is as follows: ; S232. Dynamically calculate the weight vector of each channel through MLP to amplify the underlying cell features. The calculation formula is as follows: ; in, is a multi-layer perceptron, which contains two fully connected layers, namely and , and is the learnable weight matrix of the ELANSE module, which is used to dynamically adjust the channel weights. is the first layer fully connected weight matrix, is the second layer fully connected weight matrix, For the ReLU activation function, nonlinearity is introduced. is the Sigmoid function, which maps the weights to the [0,1] interval.

[0043] S233, channel-by-channel multiplication operation, weight vector s and feature map Multiply the corresponding channels to suppress the interference of the noise channel and obtain the enhanced feature map , the formula is as follows: ; in, Through channel weight The weighted feature matrix enhances the response of important features.

[0044] S24, detection head prediction: features enhanced by SE Input to the prediction head of YOLOv7, output bounding box coordinates, confidence and category probability, as follows: ; ; in, The bounding box coordinates (x, y are the center point coordinates, w, h are the width and height) obtained by decoding the prediction head of YOLOv7 are used to locate the cell area. is the class probability vector normalized by Softmax, indicating the probability that the cell belongs to the surface, middle or bottom squamous epithelial cells.

[0045] S25, non-maximum suppression (DIoU-NMS): according to the confidence Perform DIoU-NMS and retain high confidence bounding boxes as follows: In the formula In the example, the center point distance between the bounding boxes is introduced and the diagonal length of the minimum bounding box As a penalty term, redundant bounding boxes in overlapping areas are reduced.

[0046] reserve The bounding box of ,ensures that the overlap between the final output detection boxes is small.

[0047] according to 、 and confidence Output test results ; in, are the bounding box coordinates, is the category label, is the confidence level.

[0048] S26. Cell image block cropping: based on the detection results Extract bounding box coordinates for each cell ; According to the bounding box coordinates from The fine-grained features of the corresponding cell area are cropped, the local details of the cell area are retained, and the original cell image block is obtained ; Scaling the original cell image patch to 224×224 pixels to generate fine-grained feature image blocks ; Fine-grained feature image patches As the input data of step S3, these cropped cell image blocks can more specifically extract cell features, and the formula is as follows: ; in, For the region alignment pooling operation, according to the bounding box coordinates From the feature map Accurately crop and pool the feature vectors of the cell area, In order to retain the fine-grained feature images of the cell region (such as cell nuclear shape and cytoplasmic texture), they are used as input data of the UNI model in step S3 to extract fine-grained pathological features of the cell region, including cell nuclear morphology and cytoplasmic texture.

[0049] S27, cell distribution vector: from Extract the number of cells in each layer detected , passed to step S30, the specific steps are as follows: S271, cell type statistics: Count the number of cells in each category: ; ; ; in, is the number of surface cells, is the number of middle layer cells, is the number of bottom cells, is the total number of cells detected, reflecting the density of cells in the image. For the The class labels of the cells (0 = surface, 1 = middle, 2 = bottom).

[0050] S272, normalized distribution vector: ; in, Indicates the proportion of surface, middle and bottom cells, satisfying ,Right now , is the normalized proportion vector of the global cell distribution, which is used by the UNI model in step S30 to understand the relationship between cell distribution and age. For example, the proportion of underlying cells increases with age. is the total number of cells detected.

[0051] S30. Squamous epithelial cell feature extraction and fusion: Squamous epithelial cell feature extraction is performed using the general basic model of computational pathology. After feature extraction, the features and distribution information of a fixed number of squamous epithelial cells from the same subject are fused to obtain the overall sample characteristics of the subject.

[0052] The specific steps are as follows: S31. Squamous epithelial cell feature extraction: The pre-trained pathology universal basic model UNI is used to extract the deep features of squamous epithelial cells, and the final output feature dimension is 1024 key features. The features of a fixed number B squamous epithelial cells are subsequently fused, and the feature dimension is (B, 1024). The specific method is based on the Vision Transformer (ViT) architecture to transform the fine-grained features into The image is divided into fixed-size blocks and global features are extracted through a multi-head self-attention mechanism; After analyzing the number of squamous epithelial cells that can be detected from the cervical image, B is set to 128 in this embodiment; Fixed size of 7×7, 14×14, or 28×28 pixels; In this embodiment, a fixed size of 14×14 pixels is selected, and for a fine-grained feature image block with an input size of 224×224 pixels, , divided into 14×14 pixels, we can get blocks; Specifically, UNI is a general-purpose task-based model for computational pathology based on self-supervised training of the ViT architecture. It has been pre-trained on more than 100 million images from more than 100,000 diagnostic H&E-stained whole-field digital slides (WSIs), covering 20 major tissue types, and has been evaluated on 34 clinical tasks of varying diagnostic difficulty, including tumor detection, grading, and subtype classification, demonstrating its wide applicability.

[0053] This embodiment uses the pre-trained basic model to extract key features of cervical squamous epithelial cells and stores them as a feature matrix with a dimension of (128, 1024).

[0054] S311, image preprocessing: for each fine-grained feature image block Normalize it and get , the formula is: ; in, and are the mean and standard deviation of the global training images.

[0055] S312, block embedding: Divide into 16×16 blocks of 14×14 pixels, and get .

[0056] Each block is flattened into a 588-dimensional vector (14×14×3) and converted to a 1024-dimensional embedding vector through linear projection. The formula is: ; is the linear projection weight matrix, For bias.

[0057] S313, Positional Encoding Integration: Block Embedding Features and Positional Encoding Matrix Add together and get , the formula is as follows: ; in, For learnable position encoding, each fine-grained feature image block Corresponds to a 1024-dimensional vector; S314, Self-Attention Computation: Generating Queries via Linear Transformations ,key ,value Matrix, calculate multi-head self-attention, the formula is: ; in, , , , For query ,key ,value The linear transformation matrix of The result is processed by multi-layer perceptron (MLP) and layer normalization to obtain the feature vector .

[0058] in, is the input for subsequent block embedding, As the input of the self-attention mechanism, generate .

[0059] It is a 1024-dimensional feature vector that represents the morphology, texture and pathological properties of cells S32. Feature Dimensionality Reduction (PCA): PCA principal component analysis was used to reduce the dimensionality of the flattened squamous epithelial cell features as follows: S321, Feature Matrix Construction: The feature vectors of 128 cells Stack by rows to form a feature matrix , the formula is: ; S322, Feature Flattening: Flatten the feature matrix Flattened to a one-dimensional vector , the formula is: ; S323, PCA Dimensionality Reduction: Calculating Feature Means Using the Training Set and the principal component matrix The covariance matrix of For dimensionality reduction, the formula is: ; in, is the mean vector of training set features, used to center the data, The principal component matrix is composed of the first 2048 eigenvectors of the covariance matrix of the training set, that is, the 131072-dimensional features are compressed to 2048 dimensions to remove redundant information.

[0060] Retain the first 2048 principal components to obtain the morphological feature vector after dimension reduction .

[0061] S33, feature fusion (morphological features + distribution information): after dimensionality reduction and distribution vector Splicing on the feature dimension to generate the total features of the fused samples , the formula is: ; Specifically, it is to transform the microscopic (cell features: morphological feature vector after dimensionality reduction ) and macroscopic (distribution law: distribution vector ) information to enhance the representation of biological changes in age prediction.

[0062] Will and the corresponding real age label Stored as HDF5 file, the format is as follows: Stored in HDF5 file, containing fields feature (2051-dimensional vector) and age (actual age label); To further illustrate this embodiment, the following table is used for illustration:

[0063] S40, age prediction: based on the total sample features obtained in step S30 , a regression prediction model is used to simulate the correspondence between sample features and the actual age of the subject to perform age prediction. In the embodiment, in order to verify the effect of the age prediction model on the actual prediction task, two experiments are designed to perform verification.

[0064] The first task is to detect cervical squamous epithelial cells. Since the subsequent age prediction requires the extraction of squamous epithelial cell characteristics, it is necessary to ensure that squamous epithelial cells of different degrees of differentiation can be detected normally by the model.

[0065] In specific experiments, confusion matrix is used to represent the prediction of squamous epithelial cells with different degrees of differentiation, such as Figure 5 As shown in the figure, the detection rates of the present invention for superficial squamous epithelial cells, intermediate squamous epithelial cells, and basal squamous epithelial cells are 81%, 83%, and 64%, respectively, and most squamous epithelial cells in cervical cell images can be detected.

[0066] The specific method is as follows: S41, in this embodiment, the regression prediction model is a random forest regression prediction model, the HDF5 file generated in step S3 is input to the random forest regression prediction model, and the random forest regression prediction model reads the total sample features in the HDF5 file and the corresponding real age label ; S42. Dataset division: Divide the data into training set and test set in a 4:1 ratio to ensure balanced distribution among all age groups.

[0067] Among them, the training set is used for model training and parameter tuning, and the test set is used for final model performance evaluation.

[0068] Random forest model parameter initialization: the number of trees is set to 42 unpruned regression trees by default; Number of randomly selected features: 45 features are randomly selected when each tree splits (m=√2051≈45); Other parameters: minimum number of node samples (default is 2), maximum depth is unlimited.

[0069] S43. Model training and optimization: Bootstrap sampling is used to perform random sampling with replacement on the training set to generate a training subset for each tree. Furthermore, the first tree may be trained using repeated samples, and the second tree may use another set of samples.

[0070] The decision tree construction process is as follows: S431, node splitting criterion: select the features and thresholds that maximize the variance reduction, the formula is:

[0071] Function: Select the optimal split point by reducing the uncertainty of age prediction.

[0072] S432, recursive splitting: Repeat the above process at each node until the termination condition is met (such as the number of node samples ≤ 2).

[0073] S433, Hyperparameter Tuning: Use grid search to optimize key parameters and select the best combination through 5-fold cross validation.

[0074] Specifically, in this example, the number of trees tested on the validation set was 30 / 42 / 50, and 42 trees were finally selected (the lowest mean square error on the validation set was 8.6).

[0075] S44. Model prediction and result generation Single tree prediction: Total features of input samples , each decision tree independently predicts the age value , further, the first tree predicts 50 years old, and the second tree predicts 53 years old.

[0076] Ensemble prediction: take the average of the prediction results of 42 trees to predict age The formula is: ; in, is the predicted value of the t-th tree; Confidence interval calculation: Generate a 95% confidence interval based on the standard deviation σ of the predicted values of all trees; The calculation formula for the standard deviation σ of the predicted value is as follows: ; Then, the confidence interval calculation formula is as follows: ; In this embodiment, the predicted values of the 42 trees of the input sample are [50, 53, 49, ..., 52], with an average of 51.3 years, a standard deviation σ = 0.8, and a confidence interval of [49.8, 52.8].

[0077] S45. Model evaluation and output S451, Pearson correlation coefficient (R): Measures the linear correlation between predicted age and actual age. The formula is: ; The closer the value is to 1, the stronger the correlation is.

[0078] S452, Root Mean Square Error (RMSE): Quantifies the prediction deviation, the formula is: ; Secondly, for the age prediction task, the Pearson correlation coefficient R is used to express the correlation between the predicted cervical age and the actual age, R=0.73, and the prediction results are as follows Figure 6 shown.

[0079] Figure 6 The gray bar chart at the top of the middle represents the number of samples in each age group, ensuring the balance of samples in each age group.

[0080] Figure 6 The orange dots represent the model-predicted ages, while the blue dots represent the actual ages. We can see that there is a stronger correlation at older ages, and a moderate correlation overall.

[0081] Result output: In the test set of 600 samples, Figure 6 The scatter plot of predicted age and actual age in the data shows a strong correlation (R = 0.73) with an RMSE of 3.2 years.

[0082] Predicted age value: such as 51.3 years old; Confidence interval: such as [49.8,52.8] years; Key metrics: R=0.73, RMSE=3.2.

[0083] The above steps can be used to predict female age using cervical cell images.

[0084] Example 2 Further illustrate with reference to Example 1, Figure 7 The structure shown, Figure 7 This is a schematic diagram of the structure of a computer device / equipment / system provided in an embodiment of the present application. The computer device / equipment / system includes: A processor, memory, a communication bus, and a computer program stored in the memory and executable on the processor.

[0085] The processor can call a computer program in the memory, and when executing the program, implement the method for predicting female age using cervical cell images provided in the above embodiment, the method including: S10, image acquisition: obtaining cervical cell images of different age stages that are screened as NILM by liquid-based cytology and exclude HPV infection; S20, squamous epithelial cell detection: using the target detection model to detect surface, middle and bottom squamous epithelial cells in the cervical cell images; S30, squamous epithelial cell feature extraction and fusion: using a pre-trained pathology general basic model to extract deep features of squamous epithelial cells, fusing the extracted features, and outputting the total sample features; S40, age prediction: inputting the total sample features into the regression prediction model, simulating the correspondence between the sample features and the actual age of the examinee, and performing age prediction.

[0086] Furthermore, the computer device / equipment / system also includes: Communications Interface: used for communication between memory and processor.

[0087] The memory may include a high-speed RAM memory and may also include a non-volatile memory (non-volatile memory), such as at least one disk memory.

[0088] If the memory, processor, and communication interface are implemented independently, the communication interface, memory, and processor can be connected to each other through a bus and communicate with each other. The bus can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Architecture (EISA) bus. The bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 7 Only one thick line is used in the diagram, but this does not mean that there is only one bus or one type of bus.

[0089] In addition, the logical instructions in the above-mentioned memory can be implemented in the form of a software functional unit and can be stored in a computer-readable storage medium when sold or used as an independent product. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes several instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods of each embodiment of the present invention. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.

[0090] A processor may include one or more processing units. For example, a processor may include an application processor (AP), an application-specific integrated circuit (ASIC), a modem processor, a central processing unit (CPU), an image signal processor (ISP), a controller, memory, a video codec, a digital signal processor (DSP), a baseband processor, and / or a neural-network processing unit (NPU). The different processing units may be independent devices or integrated into one or more processors. The controller may be a neural network center or command center. The controller may generate operation control signals based on instruction opcodes and timing signals to control instruction fetching and execution. The processor may also include memory for storing instructions and data. In some embodiments, the memory in the processor is a high-speed cache memory. This memory can store instructions or data that have just been used or are being recycled by the processor. If the processor needs to use the instruction or data again, it can directly call it from the memory. This avoids repeated accesses, reduces processor latency, and thus improves system efficiency.

[0091] Optionally, in a specific implementation, if the memory, processor, and communication interface are integrated on a chip, the memory, processor, and communication interface can communicate with each other through an internal interface.

[0092] On the other hand, an embodiment of the present application also provides a computer non-transitory readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the above-mentioned method for predicting female age using cervical cell images, the method comprising: S10, image acquisition: obtaining cervical cell images of different age stages that have been screened as NILM by liquid-based cytology and have excluded HPV infection; S20, squamous epithelial cell detection: using a target detection model to perform surface, middle, and bottom squamous epithelial cell detection on cervical cell images; S30, squamous epithelial cell feature extraction and fusion: using a pre-trained general pathology basic model to extract deep features of squamous epithelial cells, fusing the extracted features, and outputting the total sample features; S40, age prediction: inputting the total sample features into the regression prediction model, simulating the correspondence between the sample features and the actual age of the examinee, and performing age prediction.

[0093] On the other hand, an embodiment of the present application also provides a computer program product, which includes a computer program. The computer program can be stored on a non-transitory computer-readable storage medium. The computer program can run computer instructions. When the computer program is executed by a processor, the computer can execute the method provided by the above-mentioned methods for predicting female age using cervical cell images, the method including: S10, image acquisition: obtaining cervical cell images of different age stages that are screened as NILM by liquid-based cytology and exclude HPV infection; S20, squamous epithelial cell detection: using a target detection model to detect surface, middle and bottom squamous epithelial cells in cervical cell images; S30, squamous epithelial cell feature extraction and fusion: using a pre-trained pathology general basic model to extract deep features of squamous epithelial cells, fusing the extracted features, and outputting the total sample features; S40, age prediction: inputting the total sample features into the regression prediction model, simulating the correspondence between the sample features and the actual age of the examinee, and performing age prediction.

[0094] The logic and / or steps represented in the flowcharts or otherwise described herein, for example, can be considered as a sequenced list of executable instructions for implementing the logical functions, and can be embodied in any computer-readable medium for use by, or in conjunction with, an instruction execution system, apparatus, or device (e.g., a computer-based system, a system including a processor, or other system that can fetch and execute instructions from an instruction execution system, apparatus, or device). For purposes of this specification, a "computer-readable medium" can be any device that can contain, store, communicate, propagate, or transport a program for use by, or in conjunction with, an instruction execution system, apparatus, or device. More specific examples (a non-exhaustive list) of computer-readable media include the following: an electrical connection with one or N wires (electronic devices), a portable computer disk cartridge (magnetic device), random access memory (RAM), read-only memory (ROM), erasable and programmable read-only memory (EPROM or flash memory), fiber optic devices, and a portable compact disc read-only memory (CDROM). In addition, the computer-readable medium may even be paper or other suitable medium on which the program is printed, since the program can be obtained electronically by optically scanning the paper or other medium and then editing, interpreting or processing it in other suitable ways as necessary, and then storing it in a computer memory.

[0095] The storage medium mentioned above may be a read-only memory, a magnetic disk, or an optical disk, etc. Although the embodiments of the present application have been shown and described above, it is understood that the above embodiments are exemplary and should not be construed as limiting the present application. Persons skilled in the art may make changes, modifications, substitutions, and variations to the above embodiments within the scope of the present application.

Claims

1. A method for predicting female age using cervical cell images, characterized in that: The following steps are involved: S10. Image acquisition: Acquire images of cervical cells at different age groups that have been screened as NILM by liquid-based cytology and have excluded HPV infection; S20, Squamous epithelial cell detection: Use the target detection model to detect the surface, middle, and bottom squamous epithelial cells in cervical cell images; S30, Squamous epithelial cell feature extraction and fusion: Use the pre-trained general pathology basic model to extract the deep features of squamous epithelial cells, fuse the extracted features, and output the overall sample features; S40, Age Prediction: Input the total characteristics of the sample into the regression prediction model, simulate the correspondence between the sample characteristics and the actual age of the examinee, and perform age prediction.

2. The method for predicting female age using cervical cell images according to claim 1, characterized in that: Step S10 also includes segmenting each full-field cervical cell image to obtain cervical cell sub-images, performing preprocessing on the cervical cell sub-images to obtain preprocessed cervical cell sub-images. ; The specific steps of step S10 are as follows: S11. Image segmentation and data cleaning: Each full-field cervical cell image is segmented using the overlapping sliding window method to generate 12 cervical cell sub-images with n×n pixels. Blurred cervical cell sub-images are removed based on SSIM. Among them, the SSIM value range is [-1,1]; S12. Image preprocessing: using a median filter algorithm to dynamically adjust the median filter kernel size to perform denoising on the cervical cell sub-image, thereby obtaining a denoised cervical cell sub-image; CLAHE is used to enhance the contrast of the cervical cell sub-image after denoising; S13. Dataset division: The enhanced cervical cell sub-images are divided into training set and test set by stratified sampling in a ratio of 4:1; Stratified sampling division includes age stratification and sample allocation.

3. The method for predicting female age using cervical cell images according to claim 2, characterized in that: In step S13, the calculation formula for age stratification is as follows: ; in, is the age group number of the cervical cell sub-image. is the age of the sample, For the floor rounding function, the calculated result is taken as the largest integer not greater than the value; The number of stratification layers is determined to be 6 according to the age of the cervical cell sub-image; The sample distribution is calculated as follows: ; in, is the number of cervical cell sub-images in the training set, is the number of cervical cell sub-images in the test set, is the total number of cervical cell sub-images in a certain age group.

4. The method for predicting female age using cervical cell images according to claim 2, characterized in that: In step S20, the target detection model is attention-enhanced YOLOv7; Detect and predict the bounding box coordinates of each squamous epithelial cell based on the attention-enhanced YOLOv7 model and confidence ; According to the bounding box coordinates and confidence Squamous epithelial cells of different differentiation levels were labeled and classified into superficial, middle, and basal squamous epithelial cells; The specific steps of step S20 are as follows: S21, input the cervical cell sub-image pre-processed in step S10 , extract features through YOLOv7 Backbone and get the initial features ; S22. Input initial features Multi-scale feature fusion is performed through the ELAN module to output enhanced features ; S23, according to the output of ELAN module Using SE attention mechanism to enhance features, we get ; S24, features after SE enhancement Input to YOLOv7 prediction head, output bounding box coordinates , confidence and class probabilities ; S25. According to the confidence level Perform DIoU-NMS, retain The bounding box of according to 、 and confidence Output test results ; S26. According to the bounding box coordinates from Cut out the fine-grained features of the corresponding cell area to obtain the original cell image block ; Scaling the original cell image patch to 224×224 pixels to generate fine-grained feature image blocks ; S27, according to category probability Statistical distribution vector: ; in, is the number of surface cells, is the number of middle layer cells, is the number of bottom cells, is the total number of cells detected.

5. The method for predicting female age using cervical cell images according to claim 4, characterized in that: The pre-trained universal basic model for pathology in step S30 is the UNI model, which is based on the Vision Transformer architecture; The specific steps of step S30 are as follows: S31. Feature extraction: Input fine-grained feature image blocks The UNI model of the pre-trained ViT architecture divides each cell image block into sub-blocks of specific pixels, extracts global features through a multi-head self-attention mechanism, and generates a deep feature vector with a dimension of 1024. ; S32. Feature dimensionality reduction: Take the features of a fixed number B squamous epithelial cells, where the feature dimension of B squamous epithelial cells is B×1024; The principal component analysis method is used to reduce the dimension of the extracted B cell features, compressing the B×1024-dimensional features to 2048 dimensions. The morphological feature vector after dimension reduction is ; S33, feature fusion: after dimensionality reduction and distribution vector Splicing on the feature dimension to generate the total features of the fused samples , the formula is as follows: 。 6. The method for predicting female age using cervical cell images according to claim 5, characterized in that: In step S40, the regression prediction model is a random forest regression model, and the specific steps are as follows: S41. Total features of input samples and real age label to the random forest regression model; S42, generate 42 unpruned regression decision trees through Bootstrap sampling, and randomly select 45 features for node splitting in each tree; S43, recursively split nodes based on the maximum variance reduction criterion, and optimize hyperparameters through 5-fold cross validation; S44, integrate the prediction results of 42 trees and take the average value to output the predicted age and 95% confidence intervals.

7. The method for predicting female age using cervical cell images according to claim 6, characterized in that: The predicted age in step S44 The formula is: ; in, is the predicted value of the t-th tree; The confidence interval is calculated as follows: 。 8. A computer device / apparatus / system comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: The processor executes the computer program to implement the steps of the method for predicting female age using cervical cell images as described in any one of claims 1 to 7.

9. A computer non-transitory readable storage medium having a computer program / instruction stored thereon, characterized in that: When the computer program / instruction is executed by a processor, the steps of the method for predicting female age using cervical cell images as described in any one of claims 1 to 7 are implemented.

10. A computer program product comprising a computer program / instructions, characterized in that When the computer program / instruction is executed by one or more processors, the steps of the method for predicting female age using cervical cell images as described in any one of claims 1 to 7 are implemented.