Quantitative method and system for multiple staining of livestock and poultry muscle fibers based on double model fusion
By fusing the Cellpose-SAM and SegFormer models, the problems of low efficiency and poor accuracy in muscle fiber quantization in traditional methods are solved. This achieves pixel-level segmentation and classification of muscle fibers with high robustness and high generalization ability, and provides comprehensive phenotypic quantification data.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- JIANGXI AGRICULTURAL UNIVERSITY
- Filing Date
- 2025-12-10
- Publication Date
- 2026-04-17
AI Technical Summary
Traditional methods for measuring muscle fiber phenotypes are inefficient and have poor accuracy. Deep learning models have insufficient generalization ability in muscle fiber analysis and are unable to handle complex image degradation problems, resulting in inaccurate quantification of muscle fiber attributes.
We employ the Cellpose-SAM model for instance segmentation and the SegFormer model for semantic classification, combined with an automated post-processing algorithm, to achieve pixel-level accurate segmentation and multi-type classification of muscle fibers. The robustness and generalization ability are improved by fusing the two models.
It achieves efficient and accurate pixel-level segmentation and multi-type classification of muscle fibers, solves the problems of accurate counting and morphological parameter measurement of muscle fiber attribute quantification, and has robustness across staining modalities.
Smart Images

Figure CN121304668B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of image processing technology, and in particular to a method and system for quantifying multiple-stain animal muscle fibers based on dual-model fusion. Background Technology
[0002] Meat products, especially pork, account for nearly half of the world's protein sources. The continued focus on meat quality by consumers and the food processing industry has made muscle fiber histological characteristics a key indicator for measuring meat quality. Muscle fibers are the basic structural units that make up muscle tissue. Their number, size, type, and spatial distribution patterns determine the physiological and biochemical characteristics of meat products, directly affecting post-slaughter muscle color, pH value, water-holding capacity, and the texture of meat products. Therefore, accurately and efficiently quantifying these muscle fiber properties is of great significance for breeding high-quality meat breeds and for a deeper understanding of the mechanisms of meat formation.
[0003] Traditional methods for myofibril phenotyping suffer from significant drawbacks in efficiency and accuracy. These methods typically rely on manual operation, including the labeling, counting, and type differentiation of muscle slices. This highly repetitive and labor-intensive process not only consumes substantial human and time resources but is also highly susceptible to subjective errors. Furthermore, blurred boundaries, closely adjacent structures, or irregular shapes generated during the slicing process make accurate differentiation difficult for the human eye, leading to poor manual segmentation results. The inability to obtain accurate muscle fiber boundaries directly impacts subsequent area, quantity, and advanced index calculations, resulting in inaccurate results. Especially for cells with incomplete or fragmented image edges, traditional methods lack unified quantitative standards, and their inclusion in the analysis severely interferes with the final statistical accuracy and model training efficiency.
[0004] In recent years, although deep learning has made significant progress in image segmentation, technical challenges remain in myofibril analysis. Traditional instance segmentation models, such as the SOLOv2 model, are designed with generality in mind, but they have limitations in segmenting myofibril cell images. For example, they have low accuracy in boundary delineation, or may incorrectly classify two adjacent cells as a single instance. Further complicating matters, myofibril images often suffer from ice crystal artifacts, dye contamination, uneven staining, and a large number and size variation of myofibrils, placing extremely high demands on the robustness and generalization ability of the models. Moreover, existing models typically perform well only on images highly similar to the training data (in-distribution). Their performance drops sharply when faced with images stained using different methods (such as HE, ATPase, and immunofluorescence IF staining) or acquired using different devices (i.e., out-of-distribution data). These factors all necessitate the development of a high-generalization, high-precision deep learning model capable of overcoming complex image degradation problems and achieving pixel-level precise segmentation and multi-type classification of muscle fibers, thereby providing a reliable foundation for subsequent quantitative analysis of advanced indicators such as morphology and spatial topology. Summary of the Invention
[0005] The purpose of this invention is to overcome the shortcomings of the prior art and provide a highly generalizable and robust method and system for quantifying multi-stained animal muscle fibers based on dual-model fusion, which enables pixel-level instance segmentation, accurate classification of multiple types, and comprehensive phenotypic quantification of pig muscle fibers.
[0006] To achieve the above objectives, the technical solution provided by this invention is as follows:
[0007] A method for quantifying multiple staining animal muscle fibers based on dual-model fusion includes:
[0008] Obtain multimodal stained digital images of muscle fibers from morphologically intact livestock and poultry muscle tissue samples;
[0009] A raw dataset was established using multimodal staining digital images of muscle fibers, and the images in the raw dataset were manually and precisely labeled to establish a benchmark dataset.
[0010] The benchmark dataset was randomly split into training, validation, and test datasets. The instance segmentation model and the pixel-level semantic classification model were trained using the training dataset, respectively. The Cellpose-SAM model was used as the basic architecture for the instance segmentation model, and the SegFormer model was used as the basic architecture for the semantic classification model.
[0011] The trained instance segmentation model and semantic classification model are used to perform independent reasoning on the test dataset, and the muscle fiber information is quantified by combining an automated post-processing algorithm.
[0012] Furthermore, complete animal muscle tissue samples (such as pigs, cattle, sheep, chickens, etc.) are obtained, and frozen-fixed using a cryo-embedding agent to prepare frozen sections of muscle fiber cross sections. The frozen sections of muscle fiber cross sections are then co-stained with myosin adenosine triphosphatase and succinate dehydrogenase for multimodal staining. Digital images of the muscle fiber multimodal staining are obtained by imaging with a microscopic imaging module.
[0013] Furthermore, the precise manual annotation includes:
[0014] Based on the myofibroblast cell contours in the image, the image segmentation module is used to perform pixel-level instance segmentation annotation, excluding non-myofibroblast regions in the image, including ice crystal artifacts, dye contamination, gaps between myofibroblast bundles, blood vessels and fat cells, and generating instance segmentation mask files.
[0015] Based on the multimodal staining features of muscle fibers, the type of muscle fibers is determined, and a corresponding semantic classification mask file is generated. The types include type I, type IIA, and type IIB, which correspond to slow muscle / oxidative type, fast muscle / oxidative glycolysis type, and fast muscle / glycolysis type, respectively.
[0016] Furthermore, based on the multimodal staining characteristics of muscle fibers, a cascaded elimination strategy is used to determine the type of muscle fibers:
[0017] First, for each myofibril ROI in the instance segmentation mask file, its average optical density value in grayscale space is automatically measured. Based on the characteristic that oxidized myofibrils are deeply stained in mATPase and SDH co-staining, the regions with average optical density values lower than a first preset threshold are marked as preliminary type I myofibril candidate sets. The user's correction instructions are received through a visual interface to eliminate misjudged targets, generating a determined type I myofibril set. The type I myofibril set is subtracted from the full myofibril set to obtain the remaining type II myofibril candidate set.
[0018] Secondly, for each ROI in the type II myofiber candidate set, contour smoothing fitting and proportional contour shrinkage based on the geometric center are performed to construct an annular sampling band that fits the inner side of the cell membrane and calculate the average optical density value of the region. Based on the staining characteristics of intermediate myofiber presenting an edge halo, the regions whose values fall within the second preset threshold range are marked as the preliminary type IIA myofiber candidate set. After visualization and receiving user correction instructions, misjudged type IIB myofiber fibers are removed to generate a determined type IIA myofiber set.
[0019] Finally, a logical elimination operation is performed to subtract the determined set of type IIA muscle fibers from the candidate set of type II muscle fibers. All remaining ROIs are automatically identified as type IIB muscle fibers. The determined sets of type I, type IIA, and type IIB muscle fibers are uniformly mapped to the same single-channel image, and each type is assigned a unique pixel label value according to a preset encoding rule. This generates a final semantic classification mask file that contains complete classification information and is suitable for training a semantic classification model.
[0020] Furthermore, the instance segmentation model is trained using instance segmentation mask files as supervision signals, and the instance segmentation model introduces image enhancement strategies targeting noise, blur, channel displacement, and size changes during training to give the model high generalization and robustness.
[0021] The semantic classification model is trained using a semantic classification mask file as a supervision signal, and the semantic classification model adopts a pixel-level cross-entropy loss function to ensure the classification accuracy of each pixel.
[0022] Furthermore, the trained instance segmentation model and semantic classification model are used to perform independent reasoning on the test dataset, and automated post-processing code is used to quantify muscle fiber information, including:
[0023] The instance segmentation model is used to perform inference on the test dataset and output the ROI contour data of each muscle fiber, which is then saved as an ROI file compressed package.
[0024] The semantic classification model is used to infer the test dataset and output a pixel-level classification result mask for the image.
[0025] The ImageJ macro code processing module reads the ROI contour data and performs a class mode vote on the pixels inside each ROI on the corresponding pixel-level classification result mask, and uses the class with the highest percentage as the final class label of the ROI.
[0026] Based on the final category label, the morphological parameters and spatial location parameters of the ROI contour data of each type of muscle fiber were automatically measured and statistically analyzed.
[0027] Statistical analysis and derivation index calculations are performed based on the obtained morphological and spatial parameters to quantify the muscle fiber information of livestock and poultry.
[0028] Furthermore, the morphological parameters include: area, perimeter, width, height, major axis length, minor axis length, roundness, maximum Ferrette diameter, minimum Ferrette diameter, Ferrette angle, aspect ratio, roundness, and solidity;
[0029] The spatial location parameters include: cell edge point coordinates, geometric center point coordinates, and centroid coordinates.
[0030] Furthermore, statistical analysis and derivation index calculations are performed based on the obtained morphological and spatial location parameters, including:
[0031] Based on morphological parameters, common statistical derivatives such as mean, median, skewness, and coefficient of variation for each type of muscle fiber are calculated.
[0032] The number ratio, area ratio, and density of different types of muscle fibers in multimodal stained digital images of muscle fibers were statistically analyzed.
[0033] Based on spatial location parameters, the spatial distribution characteristics of muscle fibers are digitally represented using the R language.
[0034] Furthermore, based on spatial location parameters, the spatial distribution characteristics of muscle fibers are digitally represented using the R language, including:
[0035] First, the minimum Euclidean distance between ROIs of non-repetitive muscle fibers is calculated to construct a distance matrix;
[0036] Secondly, a single-connection hierarchical clustering algorithm is applied to automatically group spatially adjacent muscle fibers of the same type into independent topological clusters based on a preset distance threshold.
[0037] Finally, advanced spatial topological indicators, including the number of clusters of the same type of muscle fibers, the frequency of cluster size distribution, and spatial Shannon entropy, are automatically counted and quantified to achieve a digital representation of the spatial distribution characteristics of muscle fibers.
[0038] Furthermore, to achieve the above objectives, the present invention also provides a multi-staining livestock and poultry muscle fiber quantification system based on dual-model fusion, which is used to implement the above-mentioned multi-staining livestock and poultry muscle fiber quantification method based on dual-model fusion, including a microscopic imaging module, an image segmentation module, a type determination module, a training module, an ImageJ macro code processing module, an automated measurement and statistics module, and a statistical analysis and derived index calculation module.
[0039] The microscopic imaging module is used to acquire multimodal stained digital images of muscle fibers;
[0040] The image segmentation module is used to perform pixel-level instance segmentation and annotation of the myofiber cell contours in the multimodal stained digital image of myofibers;
[0041] The type determination module is used to determine the type of muscle fibers;
[0042] The training module is used to train an instance segmentation model and a pixel-level semantic classification model respectively using a training dataset;
[0043] The ImageJ macro code processing module is used to read ROI contour data and perform class mode voting statistics on the pixels inside each ROI on the corresponding pixel-level classification result mask, and take the class with the highest percentage as the final class label of the ROI.
[0044] The automated measurement and statistics module is used to automatically measure and statistically analyze the morphological parameters and spatial location parameters of the ROI contour data of each type of muscle fiber according to the final category label.
[0045] The statistical analysis and derived index calculation module is used to perform statistical analysis and derived index calculation based on the obtained morphological parameters and spatial location parameters, thereby quantifying the muscle fiber information of livestock and poultry.
[0046] Compared with existing technologies, the principles and advantages of this technical solution are as follows:
[0047] By leveraging the high generalization ability of the Cellpose-SAM model, complex image challenges such as ice crystal artifacts, dye contamination, and uneven staining can be addressed directly and effectively without additional image preprocessing steps. This greatly simplifies the analysis process and significantly saves time-consuming manual preprocessing and annotation resources, achieving a balance between high efficiency and high robustness.
[0048] By combining high-precision Cellpose-SAM instance segmentation results with SegFormer pixel-level semantic information and employing a post-processing logic based on majority voting, this approach overcomes the segmentation errors of traditional methods for fuzzy boundaries and complex shapes, ensuring the accuracy of muscle fiber type determination. Regarding quantitative indicators, this solution addresses the problem of accurately counting core basic indicators (e.g., the total number of muscle fibers and the absolute number of each type) and automating the measurement of morphological parameters (e.g., area, aspect ratio, and firmness), achieving high-precision classification and quantification.
[0049] The R language was used to quantify high-level spatial topological indicators such as the number of clusters of the same type of muscle fibers, providing richer and more comprehensive phenotypic data for in-depth research on the formation mechanism of meat.
[0050] Finally, this technical solution possesses strong scalability. The trained (Cellpose-SAM) instance segmentation model can serve as the foundational model for muscle fiber segmentation, proving effective for various staining schemes. The (Segformer) semantic classification model is a proprietary model trained specifically for this staining method, allowing for rapid application to other muscle fiber staining modalities through fine-tuning via human-computer interaction. Testing has verified that this technical solution achieves high-precision and high-efficiency automated phenotypic quantification on the test dataset and exhibits excellent segmentation robustness on out-of-distribution data (e.g., H&E slices, single-enzyme stained slices, or IF stained slices). Attached Figure Description
[0051] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the services required in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings in the following description are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0052] Figure 1 This is a flowchart illustrating the principle of the present invention: a multi-staining method for quantifying animal muscle fibers based on dual-model fusion.
[0053] Figure 2 This is a schematic diagram of the independent training architecture of the Cellpose-SAM model and the SegFormer model used in this invention.
[0054] Figure 3 This is a schematic diagram of the macro code majority voting logic in the process of type determination and classification of the present invention;
[0055] Figure 4 This image illustrates challenging scenarios in muscle fiber images, such as ice crystals, dye contamination, tight boundaries, and incomplete edges. The left side shows the original image, and the right side shows the segmentation result mask from the model's inference. This image visually demonstrates how the deep learning model of this invention successfully overcomes image degradation and morphological heterogeneity problems in practical applications.
[0056] Figure 5 This is a schematic diagram of a representative implementation in the test dataset, used to demonstrate the high-precision instance segmentation results of the (Cellpose-SAM) instance segmentation model, the pixel-level classification results of the (Segformer) semantic classification model, and the final category label classification effect of the ImageJ macro code;
[0057] Figure 6 To determine the correlation between the quantity and cross-sectional area (CSA) regression results of the automated model analysis and the manually labeled results on the test dataset. ) and the probability plot of area density distribution KS test (P value) and correlation coefficient (PPCC) verification plot;
[0058] Figure 7 For based on Figure 5 A schematic diagram illustrating the quantitative results of spatial topological indices such as the number of myofiber clusters of the same type calculated from sample data (sample_id is the sample number, n_roi is the size of the myofiber cluster, n_clusters is the number of myofiber clusters, and file is the ROI file compressed package).
[0059] Figure 8To demonstrate the out-of-distribution image test results used to verify the model's cross-modal generalization robustness, original images of HE-stained sections, ATPase-stained sections, and immunofluorescence (IF)-stained sections, along with the model's automatic segmentation and inference results, are shown. Here, cyto3 and cpsam are pre-weight files for the Cellpose and Cellpose-SAM models, respectively; MyoHLS is a weight file trained based on the Cellpose-SAM model architecture; and MyoV is a dedicated tool developed for HE-stained images.
[0060] Figure 9 This is a connection block diagram of the multi-staining livestock and poultry muscle fiber quantification system based on dual-model fusion according to the present invention. Detailed Implementation
[0061] The present invention will be further described below with reference to specific embodiments:
[0062] like Figure 1 As shown in this embodiment, the method and system for quantifying multiple staining animal muscle fibers based on dual-model fusion includes the following steps:
[0063] S1. Image Acquisition and Preparation:
[0064] Obtain multimodal stained digital images of muscle fibers from morphologically intact livestock and poultry muscle tissue samples;
[0065] In this step, the muscle tissue samples were derived from representative skeletal muscle regions of livestock species, specifically the longissimus dorsi muscle of pigs. After acquisition, the samples were cryo-fixed using a cryoemulation medium, and frozen sections of muscle fibers were prepared. These sections were then subjected to multimodal co-staining using myosin adenosine triphosphate (mATPase) and succinate dehydrogenase (SDH). Using a microscopic imaging module, high-power fields were randomly selected for imaging to acquire digital images of the muscle fibers with multimodal staining, ensuring the representativeness and robustness of the acquired images.
[0066] S2. Establish an original dataset using multimodal staining digital images of muscle fibers, and perform precise manual annotation on the images in the original dataset to establish a benchmark dataset;
[0067] In this step, based on the myofibril cell contours in the image, the image segmentation module (cellpose.v4.0.6) is used to perform pixel-level instance segmentation and annotation, actively excluding incomplete or fragmented myofibril instances at the image edges, and also excluding non-myofibril regions in the image, including ice crystal artifacts, dye contamination, gaps between myofibril bundles, blood vessels, and fat cells, to generate an instance segmentation mask file.
[0068] Based on the multimodal staining features of muscle fibers, the type of muscle fibers is determined, and a corresponding semantic classification mask file is generated. The types include type I, type IIA, and type IIB, which correspond to slow muscle / oxidative type, fast muscle / oxidative glycolysis type, and fast muscle / glycolysis type, respectively.
[0069] Specifically, when determining the type of muscle fibers based on their multimodal staining characteristics, a cascaded elimination strategy is used:
[0070] First, for each myofibril ROI in the instance segmentation mask file, its average optical density value in grayscale space is automatically measured. Based on the characteristic that oxidized myofibrils are deeply stained in mATPase and SDH co-staining, the regions with average optical density values lower than a first preset threshold are marked as preliminary type I myofibril candidate sets. The user's correction instructions are received through a visual interface to eliminate misjudged targets, generating a determined type I myofibril set. The type I myofibril set is subtracted from the full myofibril set to obtain the remaining type II myofibril candidate set.
[0071] Secondly, for each ROI in the type II myofiber candidate set, contour smoothing fitting and proportional contour shrinkage based on the geometric center are performed to construct an annular sampling band that fits the inner side of the cell membrane and calculate the average optical density value of the region. Based on the staining characteristics of intermediate myofiber presenting an edge halo, the regions whose values fall within the second preset threshold range are marked as the preliminary type IIA myofiber candidate set. After visualization and receiving user correction instructions, misjudged type IIB myofiber fibers are removed to generate a determined type IIA myofiber set.
[0072] Finally, a logical elimination operation is performed to subtract the determined set of type IIA muscle fibers from the candidate set of type II muscle fibers. All remaining ROIs are automatically identified as type IIB muscle fibers. The determined sets of type I, type IIA, and type IIB muscle fibers are uniformly mapped to the same single-channel image, and each type is assigned a unique pixel label value according to a preset encoding rule. This generates a final semantic classification mask file that contains complete classification information and is suitable for training a semantic classification model.
[0073] S3. Randomly split the benchmark dataset into training dataset, validation dataset, and test dataset, and train the instance segmentation model and pixel-level semantic classification model respectively using the training dataset: Cellpose-SAM model is used as the basic architecture of the instance segmentation model, and SegFormer model is used as the basic architecture of the semantic classification model.
[0074] The instance segmentation model is trained using instance segmentation mask files as supervision signals; the semantic classification model is trained using semantic classification mask files as supervision signals.
[0075] The instance segmentation model incorporates image enhancement strategies targeting noise, blur, channel displacement, and size changes during training to give the model high generalization and robustness; the semantic classification model employs a pixel-level cross-entropy loss function to ensure the classification accuracy of each pixel.
[0076] like Figure 2 As shown, the instance segmentation model and the semantic classification model are trained independently. The training process of these two models uses the AdamW optimizer, combined with dynamic learning rate scheduling, to ensure the stability and convergence efficiency of the training.
[0077] Although this embodiment uses data from the longissimus dorsi muscle of pigs as the main training set, the population used is a highly heterogeneous F6 chimeric family, and the Cellpose-SAM high generalization architecture is adopted. Its technical principles and application scope can cover other livestock and poultry species with similar muscle fiber tissue (such as cattle, sheep, chickens, etc.).
[0078] S4. Use the trained instance segmentation model and semantic classification model to perform independent reasoning on the test dataset, and combine with an automated post-processing algorithm to quantify muscle fiber information.
[0079] The specific process of this step includes:
[0080] The instance segmentation model is used to perform inference on the test dataset and output the ROI contour data of each muscle fiber, which is then saved as an ROI file compressed package.
[0081] The semantic classification model is used to infer the test dataset and output a pixel-level classification result mask for the image.
[0082] like Figure 3 The macro code logic shown reads the ROI contour data through the ImageJ macro code processing module, and performs a class mode voting statistics on the pixels inside each ROI on the corresponding pixel-level classification result mask. The class with the highest percentage is used as the final class label (Type I, Type IIA, Type IIB) of the ROI, as shown in Table 1, which facilitates the automatic classification of muscle fibers.
[0083] Table 1
[0084]
[0085] Based on the final category label, the morphological parameters and spatial location parameters of the ROI contour data of each type of muscle fiber were automatically measured and statistically analyzed.
[0086] In this embodiment, the morphological parameters include: area, perimeter, width, height, major axis length, minor axis length, roundness, maximum Ferrette diameter, minimum Ferrette diameter, Ferrette angle, aspect ratio, roundness, and firmness; the spatial position parameters include: cell edge point coordinates, geometric center point coordinates, and centroid coordinates.
[0087] Based on the obtained morphological and spatial parameters, statistical analysis and derivation index calculations were performed using R language to quantify the muscle fiber information of livestock and poultry.
[0088] Based on morphological parameters, common statistical derivative indicators such as mean, median, skewness, and coefficient of variation for each type of muscle fiber are calculated; the number ratio, area ratio, and density of different types of muscle fibers in multimodal stained digital images of muscle fibers are statistically analyzed; and based on spatial location parameters, the spatial distribution characteristics of muscle fibers are digitally represented using R language.
[0089] Specifically, the process of digitally representing the spatial distribution characteristics of muscle fibers using R language based on spatial location parameters is as follows:
[0090] First, the minimum Euclidean distance between ROIs of non-repetitive muscle fibers is calculated to construct a distance matrix;
[0091] Secondly, a single-connection hierarchical clustering algorithm is applied to automatically group spatially adjacent muscle fibers of the same type into independent topological clusters based on a preset distance threshold.
[0092] Finally, advanced spatial topological indicators, including the number of clusters of the same type of muscle fibers, the frequency of cluster size distribution, and spatial Shannon entropy, are automatically counted and quantified to achieve a digital representation of the spatial distribution characteristics of muscle fibers.
[0093] Figure 7 The results of the spatial topology index quantification calculated based on sample data are presented.
[0094] Performance verification and example demonstration. Figure 5 A representative example from the test dataset is shown. Figure 6 The model's performance was validated across the entire test dataset: the quantity and cross-sectional area (CSA) regression correlation between the model's automated analysis results and manually labeled results. The results of the probability plot KS test (P-value) and correlation coefficient (PPCC) of the area density distribution are all close to 1, which proves that the automated method and the manual analysis have a high degree of consistency and reliability in the distribution morphology of muscle fiber size.
[0095] OOD robustness verification. Figure 8The model is validated on out-of-distribution (OOD) data, including HE-stained sections, ATPase-stained sections, and immunofluorescence (IF)-stained sections. The model still outputs high-quality segmentation inference results on these modalities not seen in the training set, demonstrating its excellent cross-modal generalization ability. This allows the present invention to be rapidly applied as a base model to other myofibril studies. Figure 4 The images showcase complex and challenging scenarios such as ice crystals, dye contamination, tight boundaries, and incomplete edges, providing a visual demonstration that the model of this invention successfully overcomes image degradation and morphological heterogeneity problems in practical applications.
[0096] like Figure 9 As shown, this embodiment also provides a multi-staining livestock and poultry muscle fiber quantification system based on dual-model fusion, which is used to implement the above-mentioned multi-staining livestock and poultry muscle fiber quantification method based on dual-model fusion. It includes a microscopic imaging module, an image segmentation module, a type determination module, a training module, an ImageJ macro code processing module, an automated measurement and statistics module, and a statistical analysis and derived index calculation module.
[0097] Among them, the microscopic imaging module is used to acquire multimodal stained digital images of muscle fibers;
[0098] The image segmentation module is used to perform pixel-level instance segmentation and annotation of myofiber cell contours in multimodal stained digital images of myofibers;
[0099] The type determination module is used to determine the type of muscle fibers;
[0100] The training module is used to train the instance segmentation model and the pixel-level semantic classification model respectively using the training dataset;
[0101] The ImageJ macro code processing module is used to read ROI contour data and perform class mode voting statistics on the pixels inside each ROI on the corresponding pixel-level classification result mask, and use the class with the highest percentage as the final class label of the ROI.
[0102] The automated measurement and statistics module is used to automatically measure and statistically analyze the morphological and spatial location parameters of the ROI contour data of each type of muscle fiber according to the final category label.
[0103] The statistical analysis and derived index calculation module is used to perform statistical analysis and derived index calculation based on the obtained morphological parameters and spatial location parameters, thereby quantifying the muscle fiber information of livestock and poultry.
[0104] The above-described embodiments are merely preferred embodiments of the present invention and are not intended to limit the scope of the present invention. Therefore, any changes made in accordance with the shape and principle of the present invention should be covered within the protection scope of the present invention.
Claims
1. A method for quantifying multiple staining animal muscle fibers based on dual-model fusion, characterized in that, include: Obtain multimodal stained digital images of muscle fibers from morphologically intact livestock and poultry muscle tissue samples; A raw dataset was established using multimodal staining digital images of muscle fibers, and the images in the raw dataset were manually and precisely labeled to establish a benchmark dataset. The benchmark dataset was randomly split into training, validation, and test datasets. The instance segmentation model and the pixel-level semantic classification model were trained using the training dataset, respectively. The Cellpose-SAM model was used as the basic architecture for the instance segmentation model, and the SegFormer model was used as the basic architecture for the semantic classification model. The trained instance segmentation model and semantic classification model are used to perform independent reasoning on the test dataset, and the muscle fiber information is quantified by combining an automated post-processing algorithm. The precise manual annotation includes: Based on the myofibroblast cell contours in the image, the image segmentation module is used to perform pixel-level instance segmentation annotation, excluding non-myofibroblast regions in the image, including ice crystal artifacts, dye contamination, gaps between myofibroblast bundles, blood vessels and fat cells, and generating instance segmentation mask files. Based on the multimodal staining features of muscle fibers, the type of muscle fibers is determined and a corresponding semantic classification mask file is generated. The types include type I, type IIA, and type IIB, which correspond to slow muscle / oxidative type, fast muscle / oxidative glycolysis type, and fast muscle / glycolysis type, respectively. Based on the multimodal staining characteristics of muscle fibers, a cascaded elimination strategy is used to determine the type of muscle fibers: First, for each ROI (region of interest) in the instance segmentation mask file, the average optical density value in gray space is automatically measured. Based on the characteristic that oxidized myofibrils are deeply stained in mATPase and SDH co-staining, regions with average optical density values lower than a first preset threshold are marked as preliminary type I myofibril candidate sets. The user's correction instructions are received through a visual interface to eliminate misjudged targets, generating a determined type I myofibril set. The type I myofibril set is subtracted from the full myofibril set to obtain the remaining type II myofibril candidate set. Secondly, for each ROI in the type II myofiber candidate set, contour smoothing fitting and proportional contour shrinkage based on the geometric center are performed to construct an annular sampling band that fits the inner side of the cell membrane and calculate the average optical density value of the region. Based on the staining characteristics of intermediate myofiber presenting an edge halo, the regions whose values fall within the second preset threshold range are marked as the preliminary type IIA myofiber candidate set. After visualization and receiving user correction instructions, misjudged type IIB myofiber fibers are removed to generate a determined type IIA myofiber set. Finally, a logical elimination operation is performed to subtract the determined set of type IIA muscle fibers from the candidate set of type II muscle fibers. All remaining ROIs are automatically identified as type IIB muscle fibers. The determined sets of type I, type IIA, and type IIB muscle fibers are uniformly mapped to the same single-channel image, and each type is assigned a unique pixel label value according to a preset encoding rule. This generates a final semantic classification mask file that contains complete classification information and is suitable for training a semantic classification model.
2. The method for quantifying multiple staining animal muscle fibers based on dual-model fusion according to claim 1, characterized in that, Complete animal muscle tissue samples were obtained and frozen-fixed using a cryo-embedding agent to prepare frozen sections of muscle fibers. The frozen sections of muscle fibers were then co-stained with myosin triphosphate adenosine triphosphate and succinate dehydrogenase for multimodal staining. Digital images of the multimodal staining of muscle fibers were obtained by imaging with a microscopic imaging module.
3. The method for quantifying multiple staining animal muscle fibers based on dual-model fusion according to claim 1, characterized in that, The instance segmentation model is trained using instance segmentation mask files as supervision signals, and during training, the instance segmentation model introduces image enhancement strategies targeting noise, blur, channel displacement, and size changes to give the model high generalization and robustness. The semantic classification model is trained using a semantic classification mask file as a supervision signal, and the semantic classification model adopts a pixel-level cross-entropy loss function to ensure the classification accuracy of each pixel.
4. The method for quantifying multiple staining animal muscle fibers based on dual-model fusion according to claim 1, characterized in that, The trained instance segmentation and semantic classification models are used to perform independent reasoning on the test dataset, and automated post-processing code is used to quantify muscle fiber information, including: The instance segmentation model is used to perform inference on the test dataset and output the ROI contour data of each muscle fiber, which is then saved as an ROI file compressed package. The semantic classification model is used to infer the test dataset and output a pixel-level classification result mask for the image. The ImageJ macro code processing module reads the ROI contour data and performs a class mode vote on the pixels inside each ROI on the corresponding pixel-level classification result mask, and uses the class with the highest percentage as the final class label of the ROI. Based on the final category label, the morphological parameters and spatial location parameters of the ROI contour data of each type of muscle fiber were automatically measured and statistically analyzed. Statistical analysis and derivation index calculations are performed based on the obtained morphological and spatial parameters to quantify the muscle fiber information of livestock and poultry.
5. The method for quantifying multiple staining animal muscle fibers based on dual-model fusion according to claim 4, characterized in that, The morphological parameters include: area, perimeter, width, height, major axis length, minor axis length, roundness, maximum Ferrette diameter, minimum Ferrette diameter, Ferrette angle, aspect ratio, roundness, and solidity; The spatial location parameters include: cell edge point coordinates, geometric center point coordinates, and centroid coordinates.
6. The method for quantifying multiple staining animal muscle fibers based on dual-model fusion according to claim 4, characterized in that, Statistical analysis and derivation index calculations were performed based on the obtained morphological and spatial parameters, including: Based on morphological parameters, statistical derivatives, including the mean, median, skewness, and coefficient of variation for each type of muscle fiber, were calculated. The number ratio, area ratio, and density of different types of muscle fibers in multimodal stained digital images of muscle fibers were statistically analyzed. Based on spatial location parameters, the spatial distribution characteristics of muscle fibers are digitally represented using the R language.
7. The method for quantifying multiple staining animal muscle fibers based on dual-model fusion according to claim 6, characterized in that, Based on spatial location parameters, the spatial distribution characteristics of muscle fibers are digitally represented using the R language, including: First, the minimum Euclidean distance between ROIs of non-repetitive muscle fibers is calculated to construct a distance matrix; Secondly, a single-connection hierarchical clustering algorithm is applied to automatically group spatially adjacent muscle fibers of the same type into independent topological clusters based on a preset distance threshold. Finally, advanced spatial topological indicators, including the number of clusters of the same type of muscle fibers, the frequency of cluster size distribution, and spatial Shannon entropy, are automatically counted and quantified to achieve a digital representation of the spatial distribution characteristics of muscle fibers.
8. A system for quantifying multiple staining animal muscle fibers based on dual-model fusion, used to implement the method for quantifying multiple staining animal muscle fibers based on dual-model fusion as described in any one of claims 1-7, characterized in that, It includes a microscopic imaging module, an image segmentation module, a type determination module, a training module, an ImageJ macro code processing module, an automated measurement and statistics module, and a statistical analysis and derived index calculation module; The microscopic imaging module is used to acquire multimodal stained digital images of muscle fibers; The image segmentation module is used to perform pixel-level instance segmentation and annotation of myofiber cell contours in multimodal stained digital images of myofibers; The type determination module is used to determine the type of muscle fibers; The training module is used to train an instance segmentation model and a pixel-level semantic classification model respectively using a training dataset; The ImageJ macro code processing module is used to read ROI contour data and perform class mode voting statistics on the pixels inside each ROI on the corresponding pixel-level classification result mask, and take the class with the highest percentage as the final class label of the ROI. The automated measurement and statistics module is used to automatically measure and statistically analyze the morphological parameters and spatial location parameters of the ROI contour data of each type of muscle fiber according to the final category label. The statistical analysis and derived index calculation module is used to perform statistical analysis and derived index calculation based on the obtained morphological parameters and spatial location parameters, thereby quantifying the muscle fiber information of livestock and poultry.
Citation Information
Patent Citations
Railway ballast track bed surface dirt quantification method and device based on machine vision
CN120298338A