A method and system for rapid identification of pathogenic bacteria
By combining a large visual-language model with multi-scale structural perception and spatiotemporal growth discrimination, the spatiotemporal modeling and multi-scale problems of pathogen identification are solved, and the colony growth judgment and species identification are automated, thereby improving detection efficiency and accuracy.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- SICHUAN UNIV
- Filing Date
- 2025-06-13
- Publication Date
- 2026-07-07
AI Technical Summary
Existing pathogen identification methods lack the ability to model the spatiotemporal growth process of colonies, have insufficient multi-scale structural perception capabilities, and have weak ability to distinguish microscopic features, resulting in low detection efficiency, slow speed, and difficulty in achieving high-throughput screening.
By employing a large-scale vision-language model combined with multi-scale structural perception and spatiotemporal growth discrimination operations, the spatiotemporal and multi-scale features of bacterial colonies are modeled. Multi-scale dilated convolution and the large-scale vision-language model are used to interpret and identify bacterial growth. Combined with microscopic focusing classification operations, the entire process is automated.
It improves the efficiency and accuracy of pathogen detection, automates the entire process from colony growth assessment to species identification, reduces manual intervention, and is suitable for rapid clinical diagnosis.
Smart Images

Figure CN120689871B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of medical information processing technology, and more specifically to a method and system for rapid identification of pathogens. Background Technology
[0002] Rapid identification of pathogens is crucial in clinical diagnosis, public health, and biosafety. Its core objective is to achieve accurate interpretation of colony growth status and species identification based on microscopic image sequences. Traditional methods such as microbial culture, biochemical tests, and PCR detection, while accurate, generally suffer from long testing cycles, complex procedures, high reliance on personnel, and difficulty in achieving high-throughput screening. In recent years, deep learning methods have been widely introduced into pathogen image recognition tasks. Common approaches include extracting colony color, edge, and texture features based on convolutional neural networks, and using deep neural networks for full-image modeling. Some studies have also attempted to introduce the Transformer architecture, using attention mechanisms to enhance the perception of local colony structure and growth trends.
[0003] Although the above methods have excellent pathogen detection capabilities, they still have the following three problems: (1) Lack of spatiotemporal modeling ability for colony growth: Bacterial growth has significant spatiotemporal continuity. Existing methods are mostly based on single-frame image feature analysis, lacking effective modeling of the colony's emergence process, diffusion speed, and spatiotemporal distribution. (2) Insufficient multi-scale structure perception ability: The size difference of colonies at different growth stages is huge (from micron-level initial spots to millimeter-level mature colonies). Existing single-scale feature extraction models are difficult to take into account the feature differences at different stages, and there is a problem of insufficient representation of the low-contrast texture of the initial small colonies and the complex structure of mature colonies. (3) Weak ability to distinguish microscopic features: Early classification of bacterial species depends on accurate modeling of microscopic structures such as blurred edges, diffusion patterns, and texture changes. However, traditional classification models are difficult to make full use of these detailed features, resulting in insufficient classification accuracy.
[0004] Therefore, how to propose a rapid identification method and system for pathogens and improve the efficiency, speed and automation level of pathogen detection is a problem that urgently needs to be solved by those skilled in the art. Summary of the Invention
[0005] In view of this, the present invention provides a method and system for rapid identification of pathogens, providing a high-precision, low-manual-dependence solution for automated microbial monitoring and analysis.
[0006] To achieve the above objectives, the present invention adopts the following technical solution:
[0007] On the one hand, this invention proposes a rapid identification method for pathogens, comprising the following steps:
[0008] Acquire a colony time-series image sequence, perform spatiotemporal growth discrimination operation on the colony time-series image sequence, and obtain spatiotemporal features by modeling the growth dynamics of colonies in the time dimension and the morphological distribution in the spatial dimension;
[0009] Multi-scale structure perception operation is performed on the spatiotemporal features to obtain multi-scale response features, and a colony saliency region feature map is obtained based on the multi-scale response features.
[0010] A visual-language model is constructed. The feature map of the salient region of the colony is input into the visual-language model to determine whether there are growing colonies and output the corresponding growth judgment result. If the growth judgment result is growth, the species is identified. If the growth judgment result is no growth, the subsequent analysis is terminated.
[0011] Input training data and optimize model parameters in the bacterial species identification process based on the loss function;
[0012] The trained model parameters are persisted and deployed to the actual system to achieve rapid identification of pathogens.
[0013] Preferably, a spatiotemporal growth discrimination operation is performed on the colony time-series image sequence. By modeling the growth dynamics of colonies in the time dimension and the morphological distribution in the spatial dimension, spatiotemporal features are obtained, including:
[0014] The colony time sequence As input, where , Indicates the number of image frames. , , These represent the image height, width, and number of channels, respectively; the colony time-series image sequence is composed of colony images at different times during the culture process;
[0015] By modeling the variation trend between adjacent frames and the spatial structure distribution of the colony time-series images, the spatial features of each frame are obtained. Characteristics of growth and change ;
[0016] splicing the spatial features Characteristics of growth and change To obtain spatiotemporal characteristics .
[0017] Preferably, a multi-scale structure-aware operation is performed on the spatiotemporal features to obtain multi-scale response features, and a colony saliency region feature map is obtained based on the multi-scale response features, including:
[0018] Parallel multi-scale dilated convolution operations are introduced to process the spatiotemporal features, by setting different dilation rates. Dilated convolutions are used to obtain response features at multiple scales. :
[0019] ;
[0020] in, Indicates a splicing operation; Indicates the kernel size as void ratio The dilated convolution operation; ; The set number of scales;
[0021] Response characteristics at multiple scales Pixel-by-pixel saliency scoring is performed to obtain a feature map of saliency regions of the colony. :
[0022] ;
[0023] in, For convolution operations, for Activation function , These are learnable parameters.
[0024] Preferably, the feature map of the salient region of the colony is input into the visual-language large model to determine whether there are growing colonies, and the corresponding growth judgment result is output, including:
[0025] The colony saliency region feature map is input into the visual-language large model, which outputs the colony growth probability. ;
[0026] Set growth judgment threshold If satisfied If the result is positive, it indicates the presence of growing colonies, and the growth result is output as "growing"; otherwise, it indicates the absence of growing colonies, and the growth result is output as "not growing".
[0027] Preferably, if the growth interpretation result is growth, then species identification is performed, including:
[0028] The microscopic focusing classification operation is performed on the feature map of the salient region to output the bacterial species identification result. The process is as follows:
[0029] By introducing a local perception mechanism, fine-grained modeling of edge morphology, texture, blurred boundaries, and micro-diffusion structures within the salient region feature map is performed, outputting micro-features. , means as follows:
[0030]
[0031] in, This indicates a micro-focused classification operation; This indicates element-wise multiplication;
[0032] The micro-features The data is input into the target detection head to locate different bacterial colonies, predict the probability distribution of each colony belonging to different bacterial species, and output the identification results.
[0033]
[0034]
[0035] in, It is a bounding box regression function, which outputs the center point of multiple colonies. and width and height Predicted bounding box parameters , , These are the trainable parameters for the fully connected layer. The normalized probability function outputs the bacterial species identification result. The bacterial species category corresponding to the highest probability in each bounding box.
[0036] Preferably, the loss function includes a vision-language large model loss function. Bounding box regression loss function and micro-focused classification loss function ;
[0037] The loss function of the vision-language large model The cross-entropy loss function is used to constrain the consistency between the colony growth judgment results output by the vision-language large model and the true label;
[0038] The bounding box regression loss function Used to constrain the regression accuracy between the coordinates of the detection box and the true bounding box;
[0039] The micro-focusing classification loss function The cross-entropy loss function is used to constrain the matching relationship between the predicted species category output by the micro-focus classification operation and the actual species label;
[0040] The loss function of the vision-language large model The bounding box regression loss function and the micro-focusing classification loss function The average value will be used as the final loss value to optimize the model parameters in the bacterial species identification process.
[0041] On the other hand, the present invention also discloses a rapid pathogen identification system for implementing the above-mentioned rapid pathogen identification method, comprising:
[0042] The spatiotemporal growth discrimination module acquires a colony time-series image sequence, performs a spatiotemporal growth discrimination operation on the colony time-series image sequence, and obtains spatiotemporal features by modeling the growth dynamics of colonies in the time dimension and the morphological distribution in the spatial dimension.
[0043] The multi-scale structure perception module performs multi-scale structure perception operations on the spatiotemporal features to obtain response features at multiple scales, and obtains a colony saliency region feature map based on the response features at multiple scales.
[0044] The growth interpretation module constructs a visual-linguistic large model, inputs the feature map of the salient region of the colony into the visual-linguistic large model, determines whether there are growing colonies, and outputs the corresponding growth interpretation result; if the growth interpretation result is growth, then the species is identified; if the growth interpretation result is no growth, then the subsequent analysis is terminated.
[0045] The parameter training module takes training data as input and optimizes the model parameters in the bacterial species identification process based on the loss function.
[0046] The model deployment module persists the trained model parameters and deploys them to the actual system to achieve rapid identification of pathogens.
[0047] Preferably, the growth interpretation module includes a microscopic focusing classification unit, which performs microscopic focusing classification on the salient region feature map and outputs the bacterial species identification result.
[0048] As can be seen from the above technical solution, compared with the prior art, the present invention discloses a method and system for rapid identification of pathogens, which has the following beneficial effects:
[0049] (1) By adapting the spatiotemporal growth discrimination operation and multi-scale structure perception operation of the visual-language large model, the colony growth trend can be identified from the continuous image sequence, solving the problems of small size, low contrast and multi-scale missed detection in the early stage, and realizing rapid and accurate growth interpretation.
[0050] (2) Microscopic focusing classification operation enhances the perception of weak features (texture, edge, microstructure) in the early stage, improves the accuracy of colony classification, overcomes the problem of early feature recognition, and ensures the efficiency and accuracy of colony species identification.
[0051] (3) The growth judgment agent (which takes the continuously collected colony time sequence image as input, introduces the visual-language large model as the basic perception unit, and integrates spatiotemporal growth discrimination operation and multi-scale structure perception operation) and the colony recognition agent (which introduces micro-focus classification operation) work together to realize full-process automation from growth judgment to species recognition, reduce manual intervention, improve efficiency and consistency, and adapt to clinical rapid diagnosis scenarios. Attached Figure Description
[0052] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on the provided drawings without creative effort.
[0053] Figure 1 A flowchart of the method provided by the present invention;
[0054] Figure 2 The system architecture diagram provided for this invention. Detailed Implementation
[0055] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0056] On the one hand, such as Figure 1 As shown, this invention proposes a rapid identification method for pathogens, comprising the following steps:
[0057] S1. Obtain the colony time-series image sequence, perform spatiotemporal growth discrimination operation on the colony time-series image sequence, and obtain spatiotemporal features by modeling the growth dynamics of colonies in the time dimension and the morphological distribution in the spatial dimension, including:
[0058] S1.1: Using colony time sequence images As input, where , Indicates the number of image frames. , , These represent the image height, width, and number of channels, respectively; the colony time-series image sequence consists of colony images at different times during the culture process.
[0059] S1.2: Perform spatiotemporal growth discrimination operation on the colony time-series image sequence. By modeling the change trend between adjacent frames and the spatial structure distribution of the image, the spatial features of each frame image are obtained. Characteristics of growth and change :
[0060]
[0061] in, For spatial structure feature extractor, For the time series modeling module, This represents the length of the time window.
[0062] S1.2: Features of splicing space Characteristics of growth and change To obtain spatiotemporal characteristics :
[0063]
[0064] in, This indicates a splicing operation.
[0065] S2. Perform multi-scale structure sensing operations on spatiotemporal features to obtain multi-scale response features, and obtain a colony saliency region feature map based on the multi-scale response features, including:
[0066] S2.1: Spatiotemporal characteristics Multi-scale structure perception operations are performed, and multi-scale dilated convolution operations are introduced in parallel to model the structure of the colony region in detail at multiple receptive field scales.
[0067] By setting different void ratios Dilated convolutions are used to obtain response features at multiple scales. :
[0068] ;
[0069] in, Indicates the kernel size as void ratio The dilated convolution operation; ; The set number of scales.
[0070] S2.2: For Pixel-by-pixel saliency scoring is performed to obtain a feature map of saliency regions of the colony. :
[0071]
[0072] in, For convolution operations, for Activation function , These are learnable parameters.
[0073] S3. Construct a visual-language large model, input the feature map of the salient region of the colony into the visual-language large model, determine whether there are growing colonies, and output the corresponding growth interpretation result; if the growth interpretation result is growth, then perform species identification; if the growth interpretation result is no growth, then terminate the subsequent analysis.
[0074] Specifically, the process for this step is as follows:
[0075] S3.1: Constructing a semantic prompt template "Determine whether there is colony growth in this area," and generate a colony salience feature map. As input, it is embedded into the Visual-Language Large Model (VLM) to perform the growth and interpretation task, as shown below:
[0076]
[0077] in, This indicates that the input is stored in the Visual-Language Large Model (VLM). The normalized probability function outputs the predicted probability (i.e., colony growth probability) for the two semantic categories of "no growth" and "growth". ).
[0078] S3.2: Set growth judgment threshold If satisfied If the condition is met, then the presence of colony growth signs in the current time series image is determined, and the growth interpretation result is output as "growing," and the bacterial species is identified; otherwise, it is considered that no colony growth exists, and the growth interpretation result is output as "no growth," terminating the subsequent analysis.
[0079] Furthermore, if the growth interpretation result is growth, then species identification is performed, including:
[0080] The microscopic focusing classification operation is performed on the salient region feature map to output the bacterial species identification results. The process is as follows:
[0081] By introducing a local perception mechanism, fine-grained modeling of edge morphology, texture, blurred boundaries, and micro-diffusion structures within the salient region feature map is performed, outputting micro-features. , means as follows:
[0082]
[0083] in, This indicates a micro-focused classification operation; This indicates element-wise multiplication;
[0084] micro features The data is input into the target detection head to locate different bacterial colonies, predict the probability distribution of each colony belonging to different bacterial species, and output the identification results.
[0085]
[0086]
[0087] in, It is a bounding box regression function, which outputs the center point of multiple colonies. and width and height Predicted bounding box parameters , , These are the trainable parameters for the fully connected layer. The normalized probability function outputs the bacterial species identification result. The bacterial species category corresponding to the highest probability in each bounding box.
[0088] S4. Input training data and optimize model parameters in the bacterial species identification process based on the loss function.
[0089] Loss functions include the visual-language large model loss function. Bounding box regression loss function and micro-focused classification loss function ;
[0090] Visual-Language Large Model Loss Function The cross-entropy loss function is used to constrain the consistency between the colony growth judgment results output by the vision-language large model and the real labels, thereby improving the system's ability to discriminate the early growth state of colonies.
[0091] Bounding box regression loss function This is used to constrain the regression accuracy of the detection box coordinates and the true bounding box, thereby improving the accuracy of colony spatial localization.
[0092] Micro-focused classification loss function A cross-entropy loss function is used to constrain the matching relationship between the predicted bacterial species output by the microscopic focusing classification operation and the actual bacterial species label, thereby ensuring the accuracy of colony species identification.
[0093] The loss function of the large vision-language model Bounding box regression loss function and micro-focused classification loss function The average value will be used as the final loss value to optimize the model parameters in the bacterial species identification process.
[0094] In practice, the colony time-series image sequences are automatically acquired by an embedded camera module in a standardized incubator and transmitted to a central server via the intranet. More than 50 bacterial species are included, with each colony containing more than 200 time-series image sequences. The training process is performed on a server equipped with four NVIDIA H100 GPUs. The method proposed in this embodiment is trained using the AdamW optimizer with a learning rate set to 6e. -4 The batch size is set to 4. The window length in the spatiotemporal growth discrimination operation. Set to 3; number of scales Setting it to 3 sets the void ratio for multi-scale dilated convolution operations. Growth judgment threshold The value was set to 0.7. After 120,000 iterations, the model was finally trained.
[0095] S5. Persist the trained model parameters and deploy them to the actual system to achieve rapid identification of pathogens.
[0096] On the other hand, reference Figure 2 The present invention also discloses a rapid pathogen identification system for implementing the above-mentioned rapid pathogen identification method, comprising:
[0097] The spatiotemporal growth discrimination module acquires colony time-series image sequences, models the growth dynamics of colonies in the time dimension and the morphological distribution in the spatial dimension based on the colony time-series image sequences, and obtains spatiotemporal features;
[0098] The multi-scale structure perception module performs multi-scale dilated convolution operations on spatiotemporal features to obtain response features at multiple scales, and obtains a colony saliency region feature map based on the response features at multiple scales.
[0099] The growth interpretation module constructs a visual-linguistic large model, inputs the feature map of the salient region of the colony into the visual-linguistic large model, determines whether there are growing colonies, and outputs the corresponding growth interpretation result; if the growth interpretation result is growth, then the species is identified; if the growth interpretation result is no growth, then the subsequent analysis is terminated.
[0100] The parameter training module takes training data as input and optimizes the model parameters in the bacterial species identification process based on the loss function.
[0101] The model deployment module persists the trained model parameters and deploys them to the actual system to achieve rapid identification of pathogens.
[0102] Preferably, the growth interpretation module includes a microscopic focusing classification unit, which performs microscopic focusing classification on the feature map of salient regions and outputs the bacterial species identification result.
[0103] The various embodiments in this specification are described in a progressive manner, with each embodiment focusing on its differences from other embodiments. Similar or identical parts between embodiments can be referred to interchangeably. For the apparatus disclosed in the embodiments, since it corresponds to the method disclosed in the embodiments, the description is relatively simple; relevant parts can be referred to the method section.
[0104] The above description of the disclosed embodiments enables those skilled in the art to make or use the invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the invention. Therefore, the invention is not to be limited to the embodiments shown herein, but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A rapid identification method for pathogenic bacteria, characterized in that, Includes the following steps: Acquire a time-series image sequence of bacterial colonies, perform spatiotemporal growth discrimination operations on the sequence, and obtain spatiotemporal features by modeling the growth dynamics of colonies in the time dimension and their morphological distribution in the spatial dimension, including: The colony time sequence As input, where , Indicates the number of image frames. , , These represent the image height, width, and number of channels, respectively; the colony time-series image sequence is composed of colony images at different times during the culture process; By modeling the variation trend between adjacent frames and the spatial structure distribution of the colony time-series images, the spatial features of each frame are obtained. Characteristics of growth and change ; splicing the spatial features Characteristics of growth and change To obtain spatiotemporal characteristics ; Perform multi-scale structure-aware operations on the spatiotemporal features to obtain multi-scale response features, and obtain a colony saliency region feature map based on the multi-scale response features, including: Parallel multi-scale dilated convolution operations are introduced to process the spatiotemporal features, by setting different dilation rates. Dilated convolutions are used to obtain response features at multiple scales. : ; in, Indicates a splicing operation; Indicates the kernel size as void ratio The dilated convolution operation; ; The set number of scales; Response characteristics at multiple scales Pixel-by-pixel saliency scoring is performed to obtain a feature map of saliency regions of the colony. : ; in, For convolution operations, for Activation function , These are learnable parameters; A visual-language model is constructed. The feature map of the salient region of the colony is input into the visual-language model to determine whether there are growing colonies and output the corresponding growth judgment result. If the growth judgment result is growth, the species is identified. If the growth judgment result is no growth, the subsequent analysis is terminated. If the growth interpretation result is growth, then species identification is performed, including: The microscopic focusing classification operation is performed on the feature map of the salient region to output the bacterial species identification result. The process is as follows: By introducing a local perception mechanism, fine-grained modeling of edge morphology, texture, blurred boundaries, and micro-diffusion structures within the salient region feature map is performed, outputting micro-features. , means as follows: in, This indicates a micro-focused classification operation; This indicates element-wise multiplication; The micro-features The data is input into the target detection head to locate different bacterial colonies, predict the probability distribution of each colony belonging to different bacterial species, and output the identification results. in, It is a bounding box regression function, which outputs the center point of multiple colonies. and width and height Predicted bounding box parameters , , These are the trainable parameters for the fully connected layer. The normalized probability function outputs the bacterial species identification result. The bacterial species category with the highest probability in each bounding box; Input training data and optimize model parameters in the bacterial species identification process based on the loss function; The trained model parameters are persisted and deployed to the actual system to achieve rapid identification of pathogens.
2. The rapid identification method for pathogens according to claim 1, characterized in that, The colony saliency region feature map is input into the visual-language large model to determine whether there are growing colonies, and the corresponding growth judgment result is output, including: The colony saliency region feature map is input into the visual-language large model, which outputs the colony growth probability. ; Set growth judgment threshold If satisfied If the result is positive, it indicates the presence of growing colonies, and the growth result is output as "growing"; otherwise, it indicates the absence of growing colonies, and the growth result is output as "not growing".
3. The rapid identification method for pathogens according to claim 1, characterized in that, The loss function includes the vision-language large model loss function. Bounding box regression loss function and micro-focused classification loss function ; The loss function of the vision-language large model The cross-entropy loss function is used to constrain the consistency between the colony growth judgment results output by the vision-language large model and the true label; The bounding box regression loss function Used to constrain the regression accuracy between the coordinates of the detection box and the true bounding box; The micro-focusing classification loss function The cross-entropy loss function is used to constrain the matching relationship between the predicted species category output by the micro-focus classification operation and the actual species label; The loss function of the vision-language large model The bounding box regression loss function and the micro-focusing classification loss function The average value will be used as the final loss value to optimize the model parameters in the bacterial species identification process.
4. A rapid pathogen identification system, used to implement the rapid pathogen identification method as described in any one of claims 1-3, characterized in that, include: The spatiotemporal growth discrimination module acquires a colony time-series image sequence, performs a spatiotemporal growth discrimination operation on the colony time-series image sequence, and obtains spatiotemporal features by modeling the growth dynamics of colonies in the time dimension and the morphological distribution in the spatial dimension. The multi-scale structure perception module performs multi-scale structure perception operations on the spatiotemporal features to obtain response features at multiple scales, and obtains a colony saliency region feature map based on the response features at multiple scales. The growth interpretation module constructs a visual-linguistic large model, inputs the feature map of the salient region of the colony into the visual-linguistic large model, determines whether there are growing colonies, and outputs the corresponding growth interpretation result; if the growth interpretation result is growth, then the species is identified; if the growth interpretation result is no growth, then the subsequent analysis is terminated. The parameter training module takes training data as input and optimizes the model parameters in the bacterial species identification process based on the loss function. The model deployment module persists the trained model parameters and deploys them to the actual system to achieve rapid identification of pathogens.
5. The rapid identification system for pathogens according to claim 4, characterized in that, The growth interpretation module includes a microscopic focusing classification unit, which performs microscopic focusing classification on the salient region feature map and outputs the bacterial species identification result.