High-quality sperm acquisition method based on testis tissue sample of azoospermia patient
By using a combination of YOLOX and Kalman filter in testicular tissue samples, and a dynamic threshold multi-target tracking algorithm, high-quality sperm can be identified and screened, solving the problem of difficulty in sperm identification in testicular tissue samples and improving the fertilization success rate.
Patent Information
- Application Number
- CN202510725879.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-03
- Publication Date
- 2025-09-12
AI Technical Summary
In existing technologies, it is difficult to identify sperm in testicular tissue samples, and high-quality sperm cannot be preferentially selected, which affects the success rate of fertilization.
The target detection model of the YOLOX structure based on the attention mechanism and the prediction model of the Kalman filter are combined with the multi-target tracking algorithm with dynamic threshold to identify and track the movement trajectory of sperm in testicular tissue samples, and select high-quality sperm through morphological analysis.
It improves the accuracy and efficiency of sperm identification, reduces the missed detection rate, ensures the quality of sperm in the subsequent fertilization process, and improves the fertilization success rate.
Smart Images

Figure CN120635894A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of reproductive medicine, and in particular to a method for obtaining high-quality sperm based on testicular tissue samples of azoospermia patients. Background Art
[0002] For assisted reproductive treatment of azoospermia, intracytoplasmic sperm injection (ICSI) is one of the most commonly used technical routes. This technology requires micromanipulation to select sperm with normal morphology and good motility, and inject them into the egg with an extremely fine glass needle to force the fertilization process. However, because the semen samples of azoospermia patients usually do not contain sperm that can be used for fertilization, it is necessary to obtain testicular tissue samples through testicular puncture (TESA) and microscopic sperm extraction (TESE), and screen and evaluate the possible live sperm in the testicular tissue samples under a microscope.
[0003] In actual clinical operation, the screening and evaluation of the presence of live sperm in testicular tissue samples mostly rely on the doctor's visual experience and judgment. However, the background of testicular tissue samples is complex, such as Figure 1 As shown in (b), it contains a large number of non-target cells (such as red blood cells, interstitial cells and immature spermatogonia, etc.), which will interfere with image recognition. Figure 1 Unlike the sperm in ordinary semen samples with active motility and clear morphology shown in (a), the number of sperm in testicular tissue is extremely small and sparsely distributed, with weak motility and fuzzy morphology, and it is easy to be confused with the surrounding tissue structure, resulting in long manual retrieval time, low efficiency, high missed detection rate, and easy to be affected by fatigue, which increases the risk of misjudgment; secondly, based on the existing sperm morphology evaluation standards, doctors can select high-quality sperm from ordinary semen samples, but this evaluation standard is not applicable to primary or incompletely developed sperm in testicular tissue samples; secondly, due to the scarcity of live sperm in the samples, doctors tend to "first come, first served", ignoring the structural judgment and systematic evaluation of candidate sperm, which can easily affect the subsequent fertilization success rate.
[0004] In addition, existing deep learning methods are mostly based on scenes with simple backgrounds and a large number of sperm. They have poor adaptability to testicular tissue sample images with complex backgrounds, small sperm counts and low signal-to-noise ratios. They also lack the ability to continuously track sperm, making it impossible to identify sperm behavior and extract kinematic features, resulting in the inability to perform morphological analysis, resulting in poor quality of the obtained sperm and affecting the success rate of fertilization. Summary of the Invention
[0005] To this end, the technical problem to be solved by the present invention is to overcome the problem in the prior art that sperm identification in testicular tissue is difficult and high-quality sperm cannot be preferentially selected, which affects the final fertilization success rate.
[0006] To solve the above technical problems, the present invention provides a method for obtaining high-quality sperm based on testicular tissue samples from patients with azoospermia, comprising: S1: Obtain a microscopic video sequence of a testicular tissue sample, extract the first frame image and input it into the target detection model, output multiple detection frames containing sperm position information and their confidence scores, and use the sperm position information of each detection frame as the starting position of the corresponding sperm motion trajectory; S2: The motion trajectory of each sperm is obtained by the frame, input into the prediction model, and the first Each sperm in the frame is The corresponding prediction box in the frame; ; S3: The detection frame with a confidence level greater than or equal to the high confidence threshold obtained after the frame image is processed by the target detection model is used as the first High confidence detection boxes for frames; The first The high confidence detection box of the frame and the Each sperm in the frame is The corresponding prediction box in the frame is matched to obtain the The movement trajectory of all sperms obtained in the frame: For a successfully matched high-confidence detection frame, the position information of the high-confidence detection frame is used as the next position of the corresponding sperm trajectory; For the high-confidence detection frame that is not successfully matched, the position information of the high-confidence detection frame is used as the starting position of the motion trajectory of the corresponding new sperm; For the prediction frame that is not matched successfully, the sperm trajectory corresponding to the prediction frame is marked as lost at the position of the current frame; S4: Order , return to execute S2 until the microscopic video sequence processing is completed, and the movement trajectories of all sperm in the microscopic video sequence are obtained; S5: From the multiple frames of images corresponding to the motion trajectory of each sperm, select the multiple frames of images corresponding to the preset number of confidence levels of each sperm sorted from high to low to construct a candidate morphological analysis sample set for each sperm; S6: Input the candidate morphological analysis samples of each sperm into the classification model, and output the head morphology classification results and mid-piece morphology classification results of each sperm; sperm with normal head morphology classification results and normal mid-piece morphology classification results are regarded as high-quality sperm.
[0007] Preferably, the processing of the unmatched high-confidence detection frame and the unmatched prediction frame further includes: The first The detection frame whose confidence is greater than the low confidence threshold and less than the high confidence threshold after the frame image is processed by the target detection model is used as the low confidence detection frame and is combined with the first The high-confidence detection frame of the frame that is not successfully matched is used as the second-screen detection frame; the prediction frame that is not successfully matched is used as the second-screen prediction frame; The first The second-screen detection frame of the frame is matched with the second-screen prediction frame to obtain the The motion trajectories of all sperm obtained by frame secondary matching: For the successfully matched second-screen detection frame, the position information of the second-screen detection frame is used as the next position of the corresponding sperm trajectory; For the unmatched second-screen detection frame, the position information of the second-screen detection frame is used as the starting position of the motion trajectory of the corresponding new sperm; For the unmatched second-screen prediction frame, the sperm trajectory corresponding to the second-screen prediction frame is marked as lost at the position of the current frame.
[0008] Preferably, the Matching the frame two-screen detection frame with the two-screen prediction frame includes: Calculate the Frame The second screening frame and the The second matching cost value of the two-screen prediction box , whose expression is: ; in, represents the second intersection-over-union weight coefficient; represents the intersection-over-union loss function; represents the second distance weight coefficient; represents the L1 norm distance; Indicates the Detection frames to be matched twice; Indicates the Remaining prediction boxes; Indicates confidence; Based on the The matching cost value of each second-screen detection frame and each second-screen prediction frame in the frame is used to construct a second cost matrix, and the matching algorithm is used for matching to obtain all successfully matched second-screen detection frames, unmatched second-screen detection frames, and unmatched second-screen prediction frames.
[0009] Preferably, the The high confidence detection box of the frame and the Each sperm in the frame is Matching the corresponding prediction boxes in the frame includes: Calculate the Frame A high confidence detection box and the Each sperm in the frame is The corresponding prediction box in the frame The first matching cost between the predicted boxes The expression is: ; in, represents the first intersection-over-union weight coefficient; represents the intersection-over-union loss function; represents the first distance weight coefficient; represents the L1 norm distance; Indicates the High confidence detection boxes; Indicates the prediction boxes; Based on the Each high confidence detection box in the frame is Each sperm in the frame is The first matching cost value of each prediction box in the corresponding prediction box in the frame is used to construct the first cost matrix, and the matching algorithm is used to match the frames to obtain all the high-confidence detection frames that are successfully matched, the high-confidence detection frames that are not successfully matched, and the prediction frames.
[0010] Preferably, the matching algorithm is the Hungarian algorithm.
[0011] Preferably, after constructing the candidate morphological analysis sample set for each sperm, the method further includes: Calculate the various kinematic parameters of each sperm based on the candidate morphological analysis sample set of each sperm; If all the kinematic parameters of the sperm are within their corresponding preset ranges, the sperm is regarded as the target sperm.
[0012] Preferably, the kinematic parameters include sperm motion curve velocity, sperm motion linear velocity, sperm average path velocity, sperm head lateral swing amplitude and sperm motion average angular displacement.
[0013] Preferably, when the sperm trajectory is continuous If the position of the frame is marked as lost, the sperm trajectory tracking is terminated early.
[0014] Preferably, the target detection model is a sperm detection model fine-tuned on a testicular tissue sample, and its structure is a YOLOX structure based on an attention mechanism.
[0015] Preferably, the prediction model is a Kalman filter.
[0016] The above technical solution of the present invention has the following beneficial effects compared with the prior art: The present invention discloses a method for obtaining high-quality sperm based on testicular tissue samples from patients with azoospermia. The method uses a target detection model to identify the position of sperm within each frame of a microscopic video sequence. To avoid the introduction of a large amount of background impurities or falsely detected targets (such as cell debris, motion artifacts, etc.) in low signal-to-noise ratio scenarios, which would result in a large number of low-confidence detection frames participating in the matching and causing frequent trajectory interruptions or incorrect associations, thereby affecting the stability of the trajectory, the method considers analyzing high-confidence detection frames. By matching the high-confidence detection frames in each frame with each acquired prediction frame and updating the motion trajectory, the continuity of each sperm trajectory is ensured, the computational complexity is reduced, and a reliable data foundation is provided for subsequent morphological analysis to accurately obtain high-quality sperm. Morphological analysis is performed on a preset number of frames of images before confidence in all acquired sperm motion trajectories, ensuring the input quality of the morphological analysis, improving the efficiency of identifying high-quality sperm, and thereby improving the fertilization success rate.
[0017] The method for obtaining high-quality sperm based on testicular tissue samples of patients with azoospermia described in the present invention is to avoid the possibility that some sperm may be missed due to low confidence in a certain frame due to sparse sperm targets and complex background in the testicular tissue image. After matching the high-confidence sperm, the sperm in the low-confidence range are also matched twice, thereby avoiding missing important sperm and improving the accuracy of sperm to be analyzed in the subsequent process. In the secondary matching process, on the basis of the first matching cost function, the confidence is introduced to reduce the matching weight of the detection frame in the secondary matching process, further avoiding misdetection. The impact of trajectory breakage or incorrect association caused by morphological analysis is considered. Based on the consideration of whether the morphology of the sperm in each frame of the image is normal, the static screening process is completed. In order to further improve the acquisition process of high-quality sperm, the kinematic parameters of the sperm are calculated based on the sperm candidate morphological sample set, and each sperm is dynamically analyzed. Sperm with kinematic parameters that meet the preset conditions are selected. These sperm are all sperm with high motility. These sperm are used as the target of morphological analysis, which improves the recognition efficiency of high-quality sperm, helps to obtain better quality sperm, and further improves the subsequent fertilization success rate. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] In order to make the content of the present invention more clearly understood, the present invention is further described in detail below based on specific embodiments of the present invention in conjunction with the accompanying drawings, wherein: Figure 1 is a schematic diagram of a semen sample and a testicular tissue sample; Figure 1 (a) shows a schematic diagram of a diluted semen sample under a 20x bright field microscope; Figure 1(b) shows a schematic diagram of a testicular tissue sample under a 20x bright field microscope; Figure 2 This is a flow chart of a method for obtaining high-quality sperm based on a testicular tissue sample from an azoospermia patient provided by the present invention; Figure 3 This is a schematic diagram of the sperm tracking process in testicular tissue under a microscope; Figure 4 This is the flow chart of the sperm tracking algorithm based on dynamic confidence matching. DETAILED DESCRIPTION
[0019] The present invention will be further described below with reference to the accompanying drawings and specific embodiments so that those skilled in the art can better understand the present invention and implement it. However, the embodiments are not intended to limit the present invention.
[0020] Reference Figure 2 As shown in FIG, a flow chart of a method for obtaining high-quality sperm based on a testicular tissue sample from an azoospermia patient provided by the present invention; specifically comprising: S1: Obtain a microscopic video sequence of a testicular tissue sample, extract the first frame image and input it into the target detection model, output multiple detection frames containing sperm position information and their confidence levels, and use the sperm position information in each detection frame as the starting position of the corresponding sperm's motion trajectory.
[0021] The microscopic video sequence of obtaining a testicular tissue sample comprises: The standardized testicular tissue sample is imaged in real time using an ordinary bright field microscope or a phase contrast microscope to collect a microscopic video sequence; wherein, in a specific embodiment of the present invention, the microscopic image is collected using a medically certified camera with a resolution of 1200×900 under an ordinary bright field inverted microscope; the image format is a three-channel 8-bit deep color image with a resolution of not less than 720p, a frame rate of not less than 25fps, a pixel bit depth of not less than 8-bit, and the image can be grayscale or color; in order to reduce the influence of illumination changes and sample differences and enhance image quality, the collected image is subjected to standardized preprocessing operations such as denoising, enhancement, and normalization, and then used as the input of the sperm detection model to ensure that target recognition has a sufficient image quality foundation; wherein, the standardized image The expression is: ; in, represents the original image; and represent the mean and standard deviation of the image respectively.
[0022] In a specific embodiment of the present invention, the target detection model is a sperm detection model fine-tuned on a testicular tissue sample, and its structure is a YOLOX structure based on an attention mechanism, which is used to perform frame-by-frame detection on the preprocessed video; the introduction of the attention mechanism module (SA Block) enables the model to automatically focus on the sperm target when processing the testicular tissue image, enhance the focusing ability on the tiny sperm head, ignore irrelevant background information, and further improve the detection accuracy and speed of rare weakly motile sperm; the model outputs the detection frame of each sperm head target and its center coordinates, confidence score and other information, that is, the YOLOX model fine-tuned on the testicular tissue sperm image dataset is used to detect the sperm head in the image and output its detection frame coordinates. and confidence score conf. To adapt to different scenarios, such as different microscope magnifications and imaging modes (brightfield and phase contrast microscopy), the training data uses images of different magnifications and incorporates data augmentation strategies such as rotation, scaling, and mirroring. The detection results are used to generate the initial target trajectory for subsequent association processing by the tracking module.
[0023] S2: The motion trajectory of each sperm is obtained by the frame, input into the prediction model, and the first Each sperm in the frame is The corresponding prediction box in the frame; ; In a specific embodiment of the present invention, the prediction model is a Kalman filter.
[0024] S3: The detection frame with a confidence level greater than or equal to the high confidence threshold obtained after the frame image is processed by the target detection model is used as the first High confidence detection boxes for frames; The first The high confidence detection box of the frame and the Each sperm in the frame is The corresponding prediction box in the frame is matched to obtain the The movement trajectory of all sperms obtained in the frame: Calculate the Frame A high confidence detection box and the Each sperm in the frame is The corresponding prediction box in the frame The first matching cost between the predicted boxes The expression is: ; in, represents the first intersection-over-union weight coefficient; represents the intersection-over-union loss function; represents the first distance weight coefficient; represents the L1 norm distance; Indicates the High confidence detection boxes; Indicates the prediction boxes; Based on the Each high confidence detection box in the frame is Each sperm in the frame is The first matching cost value of each prediction box in the corresponding prediction box in the frame is used to construct a first cost matrix, and the matching algorithm is used to match the prediction boxes to obtain all the high-confidence detection boxes that are successfully matched, the high-confidence detection boxes that are not successfully matched, and the prediction boxes; For the high-confidence detection frame that is successfully matched, it is determined that the sperm corresponding to the high-confidence detection frame is in the first If it exists in the frame, the position information of the high-confidence detection frame is used as the next position of the corresponding sperm trajectory; For the high confidence detection frame that is not matched successfully, it is determined that the sperm corresponding to the high confidence detection frame is in the first If it does not exist in the frame, the position information of the high-confidence detection frame is used as the starting position of the motion trajectory of the corresponding new sperm; For the prediction frame that is not matched successfully, it is determined that the sperm corresponding to the prediction frame is in the The predicted box does not exist in the frame, and the sperm trajectory corresponding to the predicted box is marked as lost at the position of the current frame.
[0025] In a specific embodiment of the present invention, in order to avoid missed sperm detection, the processing of unmatched high-confidence detection frames and unmatched prediction frames further includes: The first The detection frame whose confidence is greater than the low confidence threshold and less than the high confidence threshold after the frame image is processed by the target detection model is used as the low confidence detection frame and is combined with the first The high-confidence detection frame of the frame that is not successfully matched is used as the second-screen detection frame; the prediction frame that is not successfully matched is used as the second-screen prediction frame; The first The second-screen detection frame of the frame is matched with the second-screen prediction frame to obtain the The motion trajectories of all sperm obtained by frame secondary matching: Calculate the Frame The second screening frame and the The second matching cost value of the two-screen prediction box , whose expression is: ; in, represents the second intersection-over-union weight coefficient; represents the intersection-over-union loss function; represents the second distance weight coefficient; represents the L1 norm distance; Indicates the Detection frames to be matched twice; Indicates the Remaining prediction boxes; Indicates confidence; Based on the The matching cost value of each second-screen detection frame and each second-screen prediction frame in the frame is used to construct a second cost matrix, and the matching algorithm is used to match them to obtain all the successfully matched second-screen detection frames, unmatched second-screen detection frames, and unmatched second-screen prediction frames; For the second screening test frame that matches successfully, it is determined that the sperm corresponding to the second screening test frame is in the If it exists in the frame, the position information of the second screening detection frame is used as the next position of the corresponding sperm trajectory; For the second screening test frame that is not matched successfully, it is determined that the sperm corresponding to the second screening test frame is in the If it does not exist in the frame, the position information of the second screening detection frame is used as the starting position of the motion trajectory of the corresponding new sperm; For the unmatched second screening prediction frame, the sperm corresponding to the second screening prediction frame is determined to be in the first If the predicted box does not exist in the frame, the sperm trajectory corresponding to the predicted box is marked as lost at the position of the current frame; Finally, the The sperm motion trajectory obtained by successfully matching the high confidence detection frame in the frame and the sperm motion trajectory obtained in the secondary matching process are used as the first The movement trajectory of all sperms obtained in the frame; Among them, when the sperm's trajectory is continuous If the position mark of the frame is lost, the sperm trajectory tracking is terminated in advance; in a specific embodiment of the present invention, ; The matching algorithm is the Hungarian algorithm.
[0026] In summary, due to the complex background of testicular tissue and weak sperm motility, e.g. Figure 3 As shown in the figure, YOLOX detection has low confidence or missed detection in some frames. Figure 3In three consecutive frames of the video, the same sperm can be detected in the first and third frames with high confidence, but the sperm is not detected in the second frame with low confidence, indicating missed detection. To achieve stable tracking, the present invention innovatively provides a multi-target tracking algorithm based on dynamic thresholds to match and associate detection results in consecutive frames. The algorithm uses a Kalman filter to predict the position of the sperm in the next frame, and combines the Euclidean distance of the center point with the Hungarian matching strategy to complete trajectory management. At the same time, the present invention innovatively introduces a low-confidence target retention mechanism, that is, for detection targets that are greater than the low confidence threshold and less than the high confidence threshold but meet the motion consistency condition, they are still included in the trajectory update range, thereby improving the robustness of tracking in a sparse target environment. Finally, several stable sperm trajectory sequences are output.
[0027] In a specific embodiment of the present invention, a dynamic threshold multi-target tracking algorithm is used to perform cross-frame matching and trajectory management on sperm targets detected by YOLOX; the target state vector of the sperm during the tracking process is expressed as: ; in, is the center coordinate of the detection frame, 、 The dotted symbols are their temporal derivatives, which are used for velocity prediction. The trajectory state of the detection box is predicted by the Kalman filter algorithm. The prediction result is optimally matched with the current detection result using the Hungarian algorithm. The matching algorithm is as follows: ; in, Represents the sperm detection frame set of the current frame, represents the set of trajectories in the previous frame, Represents the matching cost matrix traces; Indicates the matching result.
[0028] like Figure 3 As shown in Figure 2, due to the large difference in the confidence of sperm target detection output in testicular tissue samples, a two-stage dynamic threshold matching method is adopted: the high-confidence detection result will first be matched with the current predicted trajectory. After the first matching, the low-confidence detection result will be matched with the remaining unmatched trajectory to avoid missed detections. That is, in the first stage, high-confidence detection results are matched with the predicted trajectory first. In the second stage, low-confidence detection targets are introduced to complete the real targets that may be missed, realizing multi-stage Hungarian matching guided by confidence. The specific process is as follows: Figure 4 As shown in the figure, the dynamic threshold algorithm can ensure that real sperm with weak movement or low confidence are not filtered out, thus avoiding missed detection.
[0029] S4: Order , return to execute S2 until the microscopic video sequence processing is completed, and the movement trajectories of all sperm in the microscopic video sequence are obtained.
[0030] S5: From the multi-frame images corresponding to the motion trajectory of each sperm, select the multi-frame images corresponding to the top M confidence levels of each sperm ranked from high to low to construct a candidate morphological analysis sample set for each sperm.
[0031] S6: Input the candidate morphological analysis samples of each sperm into the classification model, and output the head morphology classification results and mid-piece morphology classification results of each sperm; sperm with normal head morphology classification results and normal mid-piece morphology classification results are regarded as high-quality sperm; among them, the head morphology classification results include normal, amorphous, large, pear-shaped, round and small; the mid-piece morphology classification results include normal, asymmetric, thick and thin; morphological analysis can exclude deformed sperm, give priority to sperm with normal morphology, and assist doctors in selecting the sperm most suitable for ICSI operation.
[0032] In a specific embodiment of the present invention, to further select higher-quality sperm, all detection segments contained in each successfully associated sperm trajectory are extracted and sorted according to the confidence score within each trajectory. The top five image regions of interest (ROIs) with the highest confidence scores are selected as candidate morphological analysis samples. This method ensures analysis quality, reduces background noise interference, and avoids misjudgments caused by low-quality frames. The following key parameters are then calculated for each trajectory to comprehensively reflect the sperm's behavioral characteristics, such as movement speed, path morphology, and direction changes, namely: Based on the candidate morphological analysis sample set of each sperm, various kinematic parameters of each sperm are calculated; wherein the kinematic parameters include sperm motion curve velocity, sperm motion linear velocity, sperm average path velocity, sperm head lateral swing amplitude and sperm motion average angular displacement.
[0033] The sperm motion curve velocity (curvilinear velocity, curve velocity, μm / s) represents the average speed per unit time of the sperm head moving along the actual trajectory in a two-dimensional plane, reflecting its overall motility; Calculate the sperm motion curve velocity The expression is: ; in, represents the total observation time; Indicates the total number of image frames; Indicates that sperm The position vector of the frame; Indicates that sperm The position vector of the frame; It represents the straight-line distance between adjacent frames, and the sum is the total length of the actual trajectory.
[0034] The linear velocity of sperm movement (μm / s) represents the ratio of the linear distance between the starting point and the end point of the sperm trajectory to the time taken, reflecting its directional consistency and effective forward movement ability; the linear velocity of sperm movement is calculated The expression is: ; in, Indicates that sperm The position vector of the frame; The vector representing the position of the sperm in frame 1.
[0035] The average sperm path velocity (Average Path Velocity, μm / s) is the unit time moving speed of the smooth average path obtained by algorithm fitting. Due to slight differences in algorithms of different systems, this parameter is only applicable to relative comparison within the same system. The expression is: ; in, Indicates the first The position vector of a point; Indicates the first The position vector of a point; It represents the distance between adjacent points on the smooth path, and the sum is the average path length.
[0036] The lateral head displacement amplitude (μm) of the sperm head indicates the maximum or average lateral displacement of the sperm head relative to the average path, reflecting its swing amplitude or path stability. The expression is: ; in, It indicates the deviation between the actual position and the smooth path position. The average of the absolute value reflects the swing intensity.
[0037] The mean angular displacement (M Angular Displacement) of sperm represents the average absolute value of the change in direction of the sperm per unit time along the motion path. It is used to measure the turning frequency and amplitude of the path, but does not directly reflect the change in the head pointing angle. The expression is: ; in, Indicates that three consecutive position points The resulting steering angle; Indicates the absolute value of the steering angle to avoid positive and negative offsets, and the sum reflects the magnitude of the overall direction change.
[0038] High sperm curve velocity indicates active sperm but may take detours; high linear velocity indicates efficient straight-line movement; mean sperm path velocity is used to compare actual trajectories with ideal paths; high lateral head sway amplitude may affect linearity (e.g., associated with low VSL); high mean angular displacement indicates frequent turns and an unstable trajectory, while low mean angular displacement indicates consistent movement. If all the kinematic parameters of the sperm are within their corresponding preset ranges, the sperm will be used as the target sperm. These sperm are all sperm with high motility. Subsequently, the candidate morphological analysis samples of each target sperm are classified and processed, and finally high-quality target sperm are obtained, realizing high-quality sperm screening combining static and dynamic methods, improving the recognition efficiency of high-quality sperm, helping to obtain better quality sperm, and further improving the subsequent fertilization success rate.
[0039] In summary, the present invention provides a method for obtaining high-quality sperm from testicular tissue samples of patients with azoospermia, which combines a deep learning detection model, an instance tracking algorithm, and morphological segmentation, and has the following significant technical advantages and beneficial effects: (1) Improve the accuracy and efficiency of sperm identification: With the help of a trained deep neural network model, the present invention can automatically identify rare and morphologically atypical live sperm in complex testicular tissue images, significantly reducing missed detections and misjudgments caused by background interference. Compared with manual visual inspection, it is more stable and reliable, and the recognition speed is greatly improved.
[0040] (2) Possessing instance tracking capability: The present invention adopts a sperm instance tracking algorithm, which can stably capture the sperm movement trajectory in continuous video frames, which helps to continuously and stably move sperm and provides a basis for subsequent morphological analysis of single target sperm.
[0041] (3) Realize standardized morphological analysis of sperm: The present invention automatically segments the identified sperm into the head, middle section, and tail, and extracts key parameters such as the head aspect ratio, tail length, and bending angle, thereby constructing a data-based and objective evaluation mechanism, providing doctors with a more valuable reference basis for screening, and making up for the problem of traditional reliance on subjective experience and lack of evaluation standards.
[0042] (4) Reduce dependence on operator experience and physical strength: The present invention replaces the doctor's continuous inspection and visual judgment of the microscopic field of view through the automatic image processing and analysis system, which reduces the operating burden, reduces the recognition errors caused by fatigue and subjective differences, and helps to improve the standardization and standardization of operations.
[0043] The present invention can automatically detect, track, and analyze individual sperm in a microscope image sequence, extracting their motion characteristics and morphological parameters, thereby providing a reliable and quantitative basis for subsequent sperm selection and assisted reproductive treatment. The entire implementation process consists of image acquisition, target detection and tracking, trajectory analysis, and morphological assessment. These modules can be integrated into the diagnosis and treatment platform of assisted reproductive institutions to improve the efficiency and accuracy of sperm screening in assisted reproductive treatment for azoospermia. Furthermore, the sperm classification and assessment results can be used to assist doctors in target screening and quality assessment, possessing considerable clinical value and interpretability. The recognition results can be displayed superimposed on the original image, supporting structural visualization.
[0044] Obviously, the above embodiments are merely examples for clarity of explanation and are not intended to limit the implementation methods. Those skilled in the art will appreciate that other variations or modifications can be made based on the above description. It is not necessary and impossible to enumerate all implementation methods here. Obvious variations or modifications arising therefrom remain within the scope of protection of the present invention.
Claims
1. A method for obtaining high-quality sperm based on testicular tissue samples from patients with azoospermia, characterized in that: include: S1: Obtain a microscopic video sequence of a testicular tissue sample, extract the first frame image and input it into the target detection model, output multiple detection frames containing sperm position information and their confidence scores, and use the sperm position information of each detection frame as the starting position of the corresponding sperm motion trajectory; S2: The motion trajectory of each sperm is obtained by the frame, input into the prediction model, and the first Each sperm in the frame is The corresponding prediction box in the frame; ; S3: The detection frame with a confidence level greater than or equal to the high confidence threshold obtained after the frame image is processed by the target detection model is used as the first High confidence detection boxes for frames; The first The high confidence detection box of the frame and the Each sperm in the frame is The corresponding prediction box in the frame is matched to obtain the The movement trajectory of all sperms obtained in the frame: For a successfully matched high-confidence detection frame, the position information of the high-confidence detection frame is used as the next position of the corresponding sperm trajectory; For the high-confidence detection frame that is not successfully matched, the position information of the high-confidence detection frame is used as the starting position of the motion trajectory of the corresponding new sperm; For the prediction frame that is not matched successfully, the sperm trajectory corresponding to the prediction frame is marked as lost at the position of the current frame; S4: Order , return to execute S2 until the microscopic video sequence processing is completed, and the movement trajectories of all sperm in the microscopic video sequence are obtained; S5: From the multiple frames of images corresponding to the motion trajectory of each sperm, select the multiple frames of images corresponding to the preset number of confidence levels of each sperm sorted from high to low to construct a candidate morphological analysis sample set for each sperm; S6: Input the candidate morphological analysis samples of each sperm into the classification model, and output the classification results of the head morphology and mid-segment morphology of each sperm; Sperm with normal head morphology and normal midpiece morphology were considered high-quality sperm.
2. The method for obtaining high-quality sperm based on a testicular tissue sample from an azoospermia patient according to claim 1, wherein: The processing of unmatched high-confidence detection frames and unmatched prediction frames also includes: The first The detection frame whose confidence is greater than the low confidence threshold and less than the high confidence threshold after the frame image is processed by the target detection model is used as the low confidence detection frame and is combined with the first The high-confidence detection frame of the frame that is not successfully matched is used as the second-screen detection frame; the prediction frame that is not successfully matched is used as the second-screen prediction frame; The first The second-screen detection frame of the frame is matched with the second-screen prediction frame to obtain the The motion trajectories of all sperm obtained by frame secondary matching: For the successfully matched second-screen detection frame, the position information of the second-screen detection frame is used as the next position of the corresponding sperm trajectory; For the unmatched second-screen detection frame, the position information of the second-screen detection frame is used as the starting position of the motion trajectory of the corresponding new sperm; For the unmatched second-screen prediction frame, the sperm trajectory corresponding to the second-screen prediction frame is marked as lost at the position of the current frame.
3. The method for obtaining high-quality sperm based on a testicular tissue sample from an azoospermia patient according to claim 2, wherein: The first Matching the frame two-screen detection frame with the two-screen prediction frame includes: Calculate the Frame The second screening frame and the The second matching cost value of the two-screen prediction box , whose expression is: ; in, represents the second intersection-over-union weight coefficient; represents the intersection-over-union loss function; represents the second distance weight coefficient; represents the L1 norm distance; Indicates the Detection frames to be matched twice; Indicates the Remaining prediction boxes; Indicates confidence; Based on the The matching cost value of each second-screen detection frame and each second-screen prediction frame in the frame is used to construct a second cost matrix, and the matching algorithm is used for matching to obtain all successfully matched second-screen detection frames, unmatched second-screen detection frames, and unmatched second-screen prediction frames.
4. The method for obtaining high-quality sperm based on a testicular tissue sample from an azoospermia patient according to claim 1, wherein: The first The high confidence detection box of the frame and the Each sperm in the frame is Matching the corresponding prediction boxes in the frame includes: Calculate the Frame A high confidence detection box and the Each sperm in the frame is The corresponding prediction box in the frame The first matching cost between the predicted boxes The expression is: ; in, represents the first intersection-over-union weight coefficient; represents the intersection-over-union loss function; represents the first distance weight coefficient; represents the L1 norm distance; Indicates the High confidence detection boxes; Indicates the prediction boxes; Based on the Each high confidence detection box in the frame is Each sperm in the frame is The first matching cost value of each prediction box in the corresponding prediction box in the frame is used to construct the first cost matrix, and the matching algorithm is used to match the frames to obtain all the high-confidence detection frames that are successfully matched, the high-confidence detection frames that are not successfully matched, and the prediction frames.
5. A method for obtaining high-quality sperm based on a testicular tissue sample from an azoospermia patient according to any one of claims 3-4, characterized in that: The matching algorithm is the Hungarian algorithm.
6. The method for obtaining high-quality sperm based on a testicular tissue sample from an azoospermia patient according to claim 1, wherein: After constructing the candidate morphological analysis sample set for each sperm, it also includes: Calculate the various kinematic parameters of each sperm based on the candidate morphological analysis sample set of each sperm; If all the kinematic parameters of the sperm are within their corresponding preset ranges, the sperm is regarded as the target sperm.
7. The method for obtaining high-quality sperm based on a testicular tissue sample from an azoospermia patient according to claim 5, characterized in that: The kinematic parameters include the sperm motion curve velocity, the sperm motion linear velocity, the sperm average path velocity, the sperm head lateral swing amplitude and the sperm motion average angular displacement.
8. The method for obtaining high-quality sperm based on a testicular tissue sample from an azoospermia patient according to claim 1, wherein: When the sperm's trajectory is continuous If the position of the frame is marked as lost, the sperm trajectory tracking is terminated early.
9. The method for obtaining high-quality sperm based on a testicular tissue sample from an azoospermia patient according to claim 1, characterized in that: The target detection model is a sperm detection model fine-tuned on testicular tissue samples, and its structure is the YOLOX structure based on the attention mechanism.
10. The method for obtaining high-quality sperm based on a testicular tissue sample from an azoospermia patient according to claim 1, characterized in that: The prediction model is a Kalman filter.
Citation Information
Patent Citations
Sperm morphology analysis method and device
CN112801967A
Semen automatic detection method and system
CN115184243A
Method of tracking multi-obstacle objects in field environment, system thereof, device and medium
US20250157226A1
Cited By
Sperm movement tracking and quality analysis method based on deep learning and optical flow fusion
CN121904402A