Segmentation method for fluorescent spots in fluorescent images, and computer device and computer-readable storage medium
By performing base sequence alignment and region growing on fluorescence images in high-throughput sequencing and combining similarity judgment, the problems of irregular spot shape and blurred boundaries in fluorescence images are solved, and high-precision segmentation of the spot position is achieved.
Patent Information
- Application Number
- PCT/CN2024/115053
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2024-03-25
- Filing Date
- 2024-08-28
- Publication Date
- 2025-10-02
AI Technical Summary
In existing technologies for high-throughput sequencing, the light spots in fluorescent images have irregular shapes and blurred boundaries, which results in decreased base recognition accuracy. Existing methods make it difficult to accurately segment the light spot positions.
By performing base recognition on the pixel positions of multiple fluorescence images and determining the error degree by base sequence alignment, pixel positions with low error degree are selected as candidate points for region growing. Region segmentation is performed in combination with base sequence similarity, and priority traversal and multi-layer similarity judgment are used to segment the light spot.
Without the need for prior knowledge, the light spot edge is segmented more accurately, improving the accuracy and confidence of light spot recognition.
Smart Images

Figure CN2024115053_02102025_PF_FP_ABST
Abstract
Description
Method for segmenting fluorescent spots in fluorescent images, computer equipment, and computer-readable storage medium
[0001] This disclosure claims priority to a Chinese patent application filed with the Patent Office of China on March 25, 2024, with application number 2024103464266 and application name “Method for segmenting fluorescent spots in fluorescent images, computer device and computer-readable storage medium”, the entire contents of which are incorporated by reference into this disclosure. Technical Field
[0002] The present disclosure relates to the technical field of computer image processing, and in particular to a method for segmenting fluorescent spots in a fluorescent image, a computer device, and a computer-readable storage medium. Background Art
[0003] At present, high-throughput sequencing technology is the main means of identifying the base sequence of nucleic acids. High-throughput sequencing technology uses image acquisition equipment to collect the fluorescent reflection of the bases of the nucleic acid to be tested to obtain fluorescent images of the bases. In multiple rounds of sequencing cycles, multiple fluorescent images are generated, and then the light spots in the multiple fluorescent images are used to identify the bases to obtain the base sequence of the nucleic acid to be tested.
[0004] Summary of the Invention
[0005] The embodiments of the present disclosure at least provide a method for segmenting fluorescent spots in a fluorescent image, a computer device, and a computer-readable storage medium.
[0006] In a first aspect, an embodiment of the present disclosure provides a computer device, comprising: a processor and a memory, wherein the memory stores machine-readable instructions executable by the processor, the processor is configured to execute the machine-readable instructions stored in the memory, and when the machine-readable instructions are executed by the processor, the processor performs a process for segmenting fluorescent spots in a fluorescent image, wherein the process for segmenting fluorescent spots in a fluorescent image includes:
[0007] performing base recognition on at least a portion of pixel positions in a plurality of fluorescent images to obtain base sequences of the at least a portion of pixel positions, wherein the plurality of fluorescent images are obtained through a plurality of consecutive sequencing cycles;
[0008] Comparing the base sequence of at least part of the pixel positions with the base sequence in a reference genome to determine the degree of error of the base sequence of at least part of the pixel positions;
[0009] The pixel positions where the error level of the base sequence is lower than a preset error level threshold are used as candidate pixel positions for region growing;
[0010] In the candidate pixel positions for region growing, a seed point for base sequence region growing is determined, and region growing is performed based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel positions in the neighborhood of the seed point, and the multiple regions obtained after growth are used as multiple fluorescent spots in the fluorescent image.
[0011] In a possible implementation, the processor is further configured to perform image space correction on the multiple fluorescent images before performing base calling on at least part of pixel positions in the multiple fluorescent images.
[0012] In one possible implementation, during the segmentation of the fluorescent spot in the fluorescent image, the processor determines a seed point for base sequence region growing in the candidate pixel positions for region growing, and performs region growing based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel positions in the neighborhood of the seed point, including:
[0013] Based on the error degree of the base sequence corresponding to the candidate pixel position, the candidate pixel position is divided into multiple categories, and the priority of region growing is determined for each category;
[0014] In order of priority from high to low, multiple categories are traversed, and the seed point corresponding to the current category is determined from the candidate pixel positions corresponding to the current category traversed, and region growing is performed based on the similarity between the base sequence of the seed point corresponding to the current category and the base sequence of the candidate pixel positions in the neighborhood of the seed point.
[0015] In one possible implementation, during the segmentation of the fluorescent spot in the fluorescent image performed by the processor, performing region growing based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel position in the neighborhood of the seed point includes:
[0016] executing the following multiple region growing cycles until the similarity between the base sequence of the seed point determined in any region growing cycle and the base sequence of the candidate pixel position in the corresponding neighborhood fails to meet the region growing condition, or there is no candidate pixel position with an undetermined belonging region;
[0017] Determining whether the candidate pixel position meets a region growing condition based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel position in the corresponding neighborhood;
[0018] In response to the similarity corresponding to any candidate pixel position satisfying the region growing condition, determining the candidate pixel position as being located in the same region as the seed point, and determining the candidate pixel position as a new seed point;
[0019] The pixel position of the new seed point is used to determine the candidate pixel positions in the neighborhood of the new seed point, and enter the next region growth cycle.
[0020] In one possible implementation, during the segmentation of the fluorescent spot in the fluorescent image performed by the processor, determining whether the candidate pixel position satisfies the region growing condition based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel position in the corresponding neighborhood includes:
[0021] determining a first comparison result between the first base sequence of the seed point and the second base sequence of the candidate pixel position in the corresponding neighborhood when the error degree of the first base sequence of the seed point indicates that the first base sequence of the seed point does not have errors;
[0022] If the first comparison result indicates that the number of different bases between the first base sequence and the second base sequence is less than a target threshold, determining that the candidate pixel position in the corresponding neighborhood meets the region growing condition;
[0023] If the first comparison result indicates that the number of different bases between the first base sequence and the second base sequence is greater than or equal to the target threshold, it is determined that the candidate pixel position in the corresponding neighborhood does not meet the region growing condition.
[0024] In one possible embodiment, during the segmentation of the fluorescent spot in the fluorescent image performed by the processor, determining whether the candidate pixel position in the corresponding neighborhood satisfies the region growing condition based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel position in the corresponding neighborhood further includes:
[0025] When the error degree of the first base sequence of the seed point indicates that the first base sequence of the seed point has an error, determining a first comparison result between the first base sequence of the seed point and the second base sequence of the candidate pixel position of the corresponding neighborhood;
[0026] If the first comparison result indicates that the number of different bases between the first base sequence and the second base sequence is less than a target threshold, determining that the candidate pixel position in the corresponding neighborhood meets the region growing condition;
[0027] If the first comparison result indicates that the number of different bases between the first base sequence and the second base sequence is greater than or equal to the target threshold, determining the number of different bases between the second base sequence and the reference genome based on the error level corresponding to the second base sequence;
[0028] If the number of different bases between the second base sequence and the reference genome is less than the target threshold, determining that the candidate pixel position in the corresponding neighborhood meets the region growing condition;
[0029] If the number of different bases between the second base sequence and the reference genome is greater than or equal to the target threshold, it is determined that the candidate pixel position in the corresponding neighborhood does not meet the region growing condition.
[0030] In one possible implementation, during the segmentation of the fluorescent spot in the fluorescent image by the processor, determining the number of base differences between the second base sequence and the reference genome based on the error level corresponding to the second base sequence includes:
[0031] Determine a first matching position of the first base sequence of the seed point in the reference genome, and a second matching position of the second base sequence of the candidate pixel position in the corresponding neighborhood in the reference genome;
[0032] When the first matching position and the second matching position are different, determining that the candidate pixel position in the corresponding neighborhood does not satisfy the region growing condition;
[0033] When the first matching position and the second matching position are the same, the number of different bases between the second base sequence and the reference genome is determined based on the error level corresponding to the second base sequence.
[0034] In an optional embodiment, during the segmentation of the fluorescent spot in the fluorescent image performed by the processor, the seed point corresponding to the current classification is determined from the candidate pixel positions corresponding to the current classification that have been traversed, and region growing is performed based on the similarity between the base sequence of the seed point corresponding to the current classification and the base sequence of the candidate pixel positions in the neighborhood of the seed point, including:
[0035] Perform at least one determination cycle until there are no candidate pixel positions for which the belonging area has not been determined among the pixel positions corresponding to the current classification traversed:
[0036] Determine a target candidate pixel position from the candidate pixel positions corresponding to the current classification that have been traversed; wherein the target candidate pixel position includes a candidate pixel position of an undetermined belonging area;
[0037] Determine a seed point corresponding to the current classification at the target candidate pixel position, and perform region growing based on the similarity between the base sequence of the seed point corresponding to the current classification and the base sequence of the candidate pixel position within the neighborhood of the seed point;
[0038] Determine whether there are any candidate pixel positions whose belonging areas have not been determined under the current classification; if so, enter the next determination cycle.
[0039] In one possible embodiment, the computer device is a computer device in a gene sequencing system, or a computer device that wirelessly communicates with a gene sequencing system. In a second aspect, an embodiment of the present disclosure provides a method for segmenting fluorescent spots in a fluorescent image, the method comprising:
[0040] performing base recognition on at least a portion of pixel positions in a plurality of fluorescent images to obtain base sequences of the at least a portion of pixel positions, wherein the plurality of fluorescent images are obtained through a plurality of consecutive sequencing cycles;
[0041] Comparing the base sequence of at least part of the pixel positions with the base sequence in a reference genome to determine the degree of error of the base sequence of at least part of the pixel positions;
[0042] The pixel positions where the error level of the base sequence is lower than a preset error level threshold are used as candidate pixel positions for region growing;
[0043] In the candidate pixel positions for region growing, a seed point for base sequence region growing is determined, and region growing is performed based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel positions in the neighborhood of the seed point, and the multiple regions obtained after growth are used as multiple fluorescent spots in the fluorescent image.
[0044] In an optional embodiment, the method further includes: performing image space correction on the multiple fluorescence images before performing base identification on at least part of the pixel positions in the multiple fluorescence images.
[0045] In an optional embodiment, determining a seed point for base sequence region growing in a candidate pixel position for region growing, and performing region growing based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel position in the neighborhood of the seed point, includes:
[0046] Based on the error degree of the base sequence corresponding to the candidate pixel position, the candidate pixel position is divided into multiple categories, and the priority of region growing is determined for each category;
[0047] In order of priority from high to low, multiple categories are traversed, and the seed point corresponding to the current category is determined from the candidate pixel positions corresponding to the current category traversed, and region growing is performed based on the similarity between the base sequence of the seed point corresponding to the current category and the base sequence of the candidate pixel positions in the neighborhood of the seed point.
[0048] In an optional embodiment, performing region growing based on the similarity between the base sequence of the seed point and the base sequences of the candidate pixel positions in the neighborhood of the seed point includes:
[0049] executing the following multiple region growing cycles until the similarity between the base sequence of the seed point determined in any region growing cycle and the base sequence of the candidate pixel position in the corresponding neighborhood fails to meet the region growing condition, or there is no candidate pixel position with an undetermined belonging region;
[0050] Determining whether the candidate pixel position meets a region growing condition based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel position in the corresponding neighborhood;
[0051] In response to the similarity corresponding to any candidate pixel position satisfying the region growing condition, determining the candidate pixel position as being located in the same region as the seed point, and determining the candidate pixel position as a new seed point;
[0052] The pixel position of the new seed point is used to determine the candidate pixel positions in the neighborhood of the new seed point, and enter the next region growth cycle.
[0053] In an optional embodiment, determining whether the candidate pixel position meets the region growing condition based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel position in the corresponding neighborhood includes:
[0054] determining a first comparison result between the first base sequence of the seed point and the second base sequence of the candidate pixel position in the corresponding neighborhood when the error degree of the first base sequence of the seed point indicates that the first base sequence of the seed point does not have errors;
[0055] If the first comparison result indicates that the number of different bases between the first base sequence and the second base sequence is less than a target threshold, determining that the candidate pixel position in the corresponding neighborhood meets the region growing condition;
[0056] If the first comparison result indicates that the number of different bases between the first base sequence and the second base sequence is greater than or equal to the target threshold, it is determined that the candidate pixel position in the corresponding neighborhood does not meet the region growing condition.
[0057] In an optional embodiment, the determining whether the candidate pixel position in the corresponding neighborhood satisfies the region growing condition based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel position in the corresponding neighborhood further includes:
[0058] When the error degree of the first base sequence of the seed point indicates that the first base sequence of the seed point has an error, determining a first comparison result between the first base sequence of the seed point and the second base sequence of the candidate pixel position of the corresponding neighborhood;
[0059] If the first comparison result indicates that the number of different bases between the first base sequence and the second base sequence is less than a target threshold, determining that the candidate pixel position in the corresponding neighborhood meets the region growing condition;
[0060] If the first comparison result indicates that the number of different bases between the first base sequence and the second base sequence is greater than or equal to the target threshold, determining the number of different bases between the second base sequence and the reference genome based on the error level corresponding to the second base sequence;
[0061] If the number of different bases between the second base sequence and the reference genome is less than the target threshold, determining that the candidate pixel position in the corresponding neighborhood meets the region growing condition;
[0062] If the number of different bases between the second base sequence and the reference genome is greater than or equal to the target threshold, it is determined that the candidate pixel position in the corresponding neighborhood does not meet the region growing condition.
[0063] In an optional embodiment, determining the number of base differences between the second base sequence and the reference genome based on the error level corresponding to the second base sequence includes:
[0064] Determine a first matching position of the first base sequence of the seed point in the reference genome, and a second matching position of the second base sequence of the candidate pixel position in the corresponding neighborhood in the reference genome;
[0065] When the first matching position and the second matching position are different, determining that the candidate pixel position in the corresponding neighborhood does not satisfy the region growing condition;
[0066] When the first matching position and the second matching position are the same, the number of different bases between the second base sequence and the reference genome is determined based on the error level corresponding to the second base sequence.
[0067] In an optional embodiment, determining a seed point corresponding to the current classification from the traversed candidate pixel positions corresponding to the current classification, and performing region growing based on the similarity between the base sequence of the seed point corresponding to the current classification and the base sequence of the candidate pixel positions in the neighborhood of the seed point, includes:
[0068] Perform at least one determination cycle until there are no candidate pixel positions for which the belonging area has not been determined among the pixel positions corresponding to the current classification traversed:
[0069] Determine a target candidate pixel position from the candidate pixel positions corresponding to the current classification that have been traversed; wherein the target candidate pixel position includes a candidate pixel position of an undetermined belonging area;
[0070] Determine a seed point corresponding to the current classification at the target candidate pixel position, and perform region growing based on the similarity between the base sequence of the seed point corresponding to the current classification and the base sequence of the candidate pixel position within the neighborhood of the seed point;
[0071] Determine whether there are any candidate pixel positions whose belonging areas have not been determined under the current classification; if so, enter the next determination cycle.
[0072] In a third aspect, embodiments of the present disclosure further provide a gene sequencing system, comprising: a chip, a chip platform, a reagent storage container, a flow guidance system, an optical detection system, and a computer device;
[0073] Wherein, one or more sequencing objects are attached to the chip;
[0074] The chip platform is configured to fix and support the chip;
[0075] The reagent storage container is configured to store one or more reagents;
[0076] The fluid guiding system is configured to controllably transport the one or more reagents from the reagent storage container to the chip so as to contact with the sequencing object and generate a chemical reaction;
[0077] The optical detection system is configured to excite fluorescent markers in sequencing reagents, detect fluorescent signals generated by the excitation of the fluorescent markers, and generate fluorescent images based on the fluorescent signals;
[0078] The computer device is configured to obtain a plurality of the fluorescence images from the optical detection system, and identify the base sequence of the sequencing object using the method for segmenting the fluorescent spot in the fluorescence image described in the second aspect or any optional embodiment of the second aspect.
[0079] In a fourth aspect, an embodiment of the present disclosure further provides a computer-readable storage medium having a computer program stored thereon. When the computer program is executed by a processor, the steps of the above-mentioned second aspect or any possible implementation of the second aspect are executed.
[0080] In order to make the above-mentioned objectives, features and advantages of the present disclosure more obvious and easy to understand, preferred embodiments are given below and described in detail with reference to the accompanying drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0081] In order to more clearly illustrate the technical solutions of the embodiments of the present disclosure, the following briefly introduces the drawings required for use in the embodiments. The drawings herein are incorporated into and constitute a part of the specification. These drawings illustrate embodiments consistent with the present disclosure and, together with the specification, are used to illustrate the technical solutions of the present disclosure. It should be understood that the following drawings only illustrate certain embodiments of the present disclosure and should not be regarded as limiting the scope. For those of ordinary skill in the art, other relevant drawings can be obtained based on these drawings without inventive effort.
[0082] FIG1 shows a schematic diagram of a gene sequencing system provided by some embodiments of the present disclosure;
[0083] FIG2 shows a schematic structural diagram of an optical detection system provided by some embodiments of the present disclosure;
[0084] FIG3 shows a flow chart of a method for segmenting fluorescent spots in a fluorescent image provided by some embodiments of the present disclosure;
[0085] FIG4 shows an example diagram of a fluorescence image sequence provided by some embodiments of the present disclosure;
[0086] FIG5 shows a flowchart of a specific method for performing region growing provided by some embodiments of the present disclosure;
[0087] FIG6 shows a schematic diagram of a computer device provided by some embodiments of the present disclosure. DETAILED DESCRIPTION
[0088] In order to make the purpose, technical solutions and advantages of the embodiments of the present disclosure clearer, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the drawings in the embodiments of the present disclosure. Obviously, the described embodiments are only part of the embodiments of the present disclosure, rather than all of the embodiments. The components of the embodiments of the present disclosure generally described and shown here can be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of the present disclosure is not intended to limit the scope of the present disclosure for protection, but merely represents the selected embodiments of the present disclosure. Based on the embodiments of the present disclosure, all other embodiments obtained by those skilled in the art without making creative work are within the scope of protection of the present disclosure.
[0089] High-throughput sequencing (HTS) is also known as next-generation sequencing (NGS) because it can simultaneously sequence hundreds of thousands to millions of nucleic acid molecules in a single run, significantly increasing sequencing efficiency compared to traditional first-generation sequencing technologies. During the sequencing process, excitation light excites fluorescent substances to produce fluorescence that reflects the characteristics of bases. An image acquisition device captures the resulting fluorescence signal, creating a fluorescence image. Specific base recognition software identifies the base type corresponding to the light spot in the fluorescence image and assigns a quality score for the base recognition accuracy.
[0090] Base recognition is determined based on the region of interest (i.e., light spot) and corresponding pixel values of the fluorescent image obtained by processing the collected fluorescent image. The fluorescent signal released by the chemical reaction is captured in real time by the instrument's highly sensitive camera, which records and analyzes the acquired fluorescent image. However, during the base recognition process, due to the limitations of the image acquisition equipment, the light spots in the collected fluorescent images often exhibit irregular shapes and blurred boundaries, resulting in reduced base recognition accuracy. Therefore, how to identify the location and clear range of the light spot in the fluorescent image is a technical problem that urgently needs to be solved.
[0091] At present, common methods for identifying the position of light spots in images mainly include methods for calculating the coordinates of the center point of the light spot, such as: grayscale centroid weighted method, Gaussian surface fitting method, parabola fitting method, etc.; and traditional segmentation algorithms for segmenting the shape of the light spot from the image, such as: region growing method, edge detection, watershed segmentation; and image segmentation networks based on deep learning.
[0092] However, the method of extracting light spots based on the coordinates of the center point of the light spot requires that the grayscale of the light spot is approximately distributed in a two-dimensional Gaussian distribution. The shapes and sizes of the light spots in the fluorescence images in high-throughput sequencing vary, and the grayscale distribution of most light spots does not conform to the two-dimensional Gaussian distribution; the light spot target required by the image segmentation algorithm is large, while the light spots in the fluorescence images in high-throughput sequencing are generally small, which cannot meet the requirements; the image segmentation network based on deep learning requires manual construction of light spot labels, which are difficult to mark with the naked eye during the construction process, and the process is relatively cumbersome.
[0093] Based on the above research, the present disclosure provides a method for segmenting fluorescent spots in a fluorescent image, which performs base recognition on at least some pixel positions in multiple fluorescent images to obtain base sequences of the at least some pixel positions, compares the base sequences of the at least some pixel positions with the base sequences in the reference genome, determines the error level of the base sequences of the at least some pixel positions, and then uses the pixel positions where the error level of the base sequences is lower than a preset error level threshold as candidate pixel positions for region growing; among the candidate pixel positions for region growing, determines a seed point for base sequence region growing, and performs region growing based on the similarity between the base sequence of the seed point and the base sequences of the candidate pixel positions in the neighborhood of the seed point, and uses the multiple regions obtained after the growth as multiple fluorescent spots in the fluorescent image. Therefore, when the spot shape of the fluorescent image is irregular or the spot boundary is blurred, the image segmentation algorithm of region growing is combined with the sequencing process, and the base sequence alignment algorithm in sequencing is used. Based on the similarity judgment of the base sequences, the spot edge can be more accurately segmented and the exact position of the spot can be determined without the need for prior knowledge.
[0094] In addition, in the embodiment of the present disclosure, a specific method is provided for dividing the candidate pixel positions into multiple categories by utilizing the error degree of the base sequence corresponding to each candidate pixel position, and determining the priority of regional growth for different categories. Then, multiple categories are traversed in order from high to low priority, and the seed point corresponding to the current category is determined from the candidate pixel positions corresponding to the traversed current category, and regional growth is performed based on the similarity between the base sequence of the seed point corresponding to the current category and the base sequence of the candidate pixel position in the neighborhood of the seed point, thereby realizing a method of prioritizing the selection of high-quality seed points for regional growth, performing regional growth on the spot area, and making the determined spot position have a higher confidence level.
[0095] In addition, the embodiment of the present disclosure also uses multi-layer similarity judgment to determine whether the pixel positions at adjacent positions belong to the same light spot area, which more effectively segments the light spot edge and improves the accuracy of light spot recognition.
[0096] The defects in the above solutions are the results obtained by the inventors after practice and careful research. Therefore, the process of discovering the above problems and the solutions proposed by the present disclosure for the above problems below should be the contributions made by the inventors to the present disclosure during the disclosure process.
[0097] It should be noted that similar reference numerals and letters denote similar items in the following drawings, and therefore, once an item is defined in one drawing, it does not require further definition or explanation in subsequent drawings.
[0098] The term "and / or" herein simply describes an association relationship, indicating that three relationships can exist. For example, A and / or B can represent the existence of A alone, the simultaneous existence of A and B, and the existence of B alone. In addition, the term "at least one" herein refers to any combination of at least two of any one or more of a plurality of items. For example, "at least one of A, B, and C" can represent any one or more elements selected from the set consisting of A, B, and C.
[0099] It is understandable that before using the technical solutions disclosed in the embodiments of the present disclosure, the personal information involved in the present disclosure (including but not limited to attribute information, facial images, etc.) is obtained with the authorization of the user. Specifically, it can be through a pop-up window on the page, information push, etc., sending a prompt message requesting authorization to the user, and obtaining the above personal information after the user agrees to the authorization.
[0100] To facilitate understanding of this embodiment, a method for segmenting fluorescent spots in a fluorescent image disclosed in an embodiment of the present disclosure is first introduced in detail. The executor of the method for segmenting fluorescent spots in a fluorescent image provided in the embodiment of the present disclosure is generally a computer device with certain computing capabilities. The computer device includes, for example: a computer device in a gene sequencing system, or a computer device capable of processing fluorescent images obtained by gene sequencing.
[0101] Please refer to Figure 1, which illustrates the overall architecture of a gene sequencing system according to an embodiment of the present disclosure. As shown in Figure 1, the gene sequencing system 100 according to an embodiment of the present disclosure includes: a chip 10, a chip platform 20, a reagent storage container 30, a fluidics system 40, an optical detection system 50, and a computer 60.
[0102] Wherein, one or more sequencing objects are attached to the chip 10;
[0103] The sequencing object here can be a gene fragment, which includes a base sequence of a certain length, for example, 150 bp in length; the sequencing object can also be a gene molecule.
[0104] a chip platform 20 configured to fix and support the chip 10;
[0105] The reagent storage container 30 is configured to store one or more reagents for sequencing; here, the reagents may exemplarily include polymerase chain reaction (PCR) fluorescent reagents.
[0106] The flow guide system 40 is configured to controllably transport the one or more sequencing reagents from the reagent storage container 30 to the chip 10 so as to contact the sequencing target and generate a chemical reaction;
[0107] an optical detection system 50 configured to excite fluorescent markers in sequencing reagents and detect fluorescent signals generated by the excitation of the fluorescent markers to generate a fluorescent image;
[0108] The computer device 60 is configured to obtain a fluorescent image from the optical detection system 50 and identify the base sequence of the sequencing object according to the fluorescent image.
[0109] Referring to FIG. 2 , FIG. 2 is a schematic structural diagram of an optical detection system provided in an embodiment of the present disclosure. The optical detection system 50 at least includes a light source component 501 and an imaging component 502 .
[0110] The imaging assembly 502 includes at least an aperture plate 5021, a dichroic mirror 5022-1, a microscope 5023, and an image sensor 5024. The aperture plate 5021 is provided with a plurality of light holes. Here, the image sensor 5024 can be exemplarily an industrial camera.
[0111] The light source component 501 emits scattered excitation light, which passes through at least some of the multiple light holes on the aperture plate 5021 to form multiple laser beams and irradiate the dichroic mirror 5022-1; the dichroic mirror 5022-1 reflects the excitation light beams passing through the light holes onto the chip 10 to assist the microscope 5023 in focusing; the microscope 5023 collects the fluorescence signals generated by the sequencing objects on the chip 10 after a chemical reaction; the image sensor 5024 senses the fluorescence signals and generates a fluorescence image.
[0112] In one implementation, the light source component 501 may be, for example, a light emitting diode, or a semiconductor laser (LD), or both. When the light source component 501 is a semiconductor laser, it can well assist the microscope 5023 in focusing.
[0113] In one implementation, the dichroic mirror 5022 - 1 may be fixed at a certain angle, for example, by glue dispensing.
[0114] In one implementation, the aperture piece 5021 can be made of an opaque material, for example, a metal sheet. The scattered excitation light emitted by the light source component 501 can only pass through the light-through hole portion, and the non-light-through hole portion of the aperture piece 5021 will block the excitation light.
[0115] In one possible embodiment, the imaging assembly 502 further includes an attenuation plate 5026, which is disposed parallel to the aperture plate 5021 and configured to attenuate the intensity of the excitation light beam. Referring to FIG. 2 , the attenuation plate 5026 can be disposed behind the aperture plate 5021. After passing through the light aperture, the excitation light beam can directly impinge on the attenuation plate 5026.
[0116] In one possible implementation, the imaging assembly 502 further includes a convex lens 5027 , which is disposed parallel to the attenuation plate 5026 and located between the attenuation plate 5026 and the dichroic mirror 5022 - 1 , and is configured to collimate the excitation light beam into a parallel beam.
[0117] In one possible implementation, the microscope 5023 may include an objective lens 50231 and a tube lens 50232 , wherein the objective lens 50231 is located below the dichroic mirror 5022 - 1 , the tube lens 50232 is located above the dichroic mirror 5022 - 1 , and the image sensor 5024 is located above the tube lens 50232 .
[0118] A motor is configured on one side of the objective lens 50231, for example, a voice coil motor. The motor on the objective lens 50231 can be used to control the objective lens 50231 to move up and down to achieve focusing of the objective lens 50231.
[0119] The following describes a method for segmenting fluorescent spots in a fluorescent image provided by an embodiment of the present disclosure.
[0120] 3 , which is a flow chart of a method for segmenting fluorescent spots in a fluorescent image according to an embodiment of the present disclosure, includes steps S301 to S304 , wherein:
[0121] S301 , performing base recognition on at least some pixel positions in a plurality of fluorescent images to obtain base sequences of the at least some pixel positions, wherein the plurality of fluorescent images are obtained through a plurality of consecutive sequencing cycles.
[0122] In a specific implementation, the fluorescence image is obtained by taking multiple shots of the same test area on the gene chip.
[0123] Before performing base identification on each pixel position in the multiple fluorescent images, the method further includes: performing image space correction on the multiple fluorescent images.
[0124] Here, image space correction is performed on multiple fluorescence images, for example, alignment processing is performed on multiple fluorescence images, and the pixel positions of the pixel positions are in a unified coordinate system, and the pixel positions of each fluorescence image correspond one-to-one with the pixel positions of other fluorescence images.
[0125] Exemplarily, multiple fluorescence images are acquired in the following manner:
[0126] An image acquisition device is used to photograph the test area of the gene chip to obtain multiple fluorescence images of the test area of the gene chip under multiple sequencing cycles; image alignment processing is performed on the multiple original fluorescence images to obtain multiple fluorescence images after image alignment processing.
[0127] Among multiple original fluorescence images, an image with a higher signal-to-noise ratio can be selected as a reference image, or an image can be randomly selected as a reference image, and the remaining images are aligned with the reference image.
[0128] The registration method may be a grayscale correlation method, a phase correlation method, or the like.
[0129] After obtaining multiple fluorescence images, base recognition can be performed on the multiple fluorescence images to determine the base sequence of the pixel positions.
[0130] Here, the fluorescent image includes multiple light spots, and the multiple light spots are obtained when the camera captures the area to be tested on the base chip during one sequencing cycle.
[0131] After obtaining the fluorescent image sequence, base recognition is performed using the method disclosed in patent publication number "CN115910217A".
[0132] Following the above S301, the method for segmenting fluorescent spots in a fluorescent image provided by the embodiment of the present disclosure further includes:
[0133] S302: Compare the base sequence of at least part of the pixel positions with the base sequence in the reference genome to determine the error level of the base sequence of at least part of the pixel positions.
[0134] Here, generally, the base sequence of the reference genome usually includes more bases; and the base sequence at each pixel position can usually only match a certain gene fragment in the base sequence of the reference genome. Then, when the base sequence at each pixel position is compared with the base sequence in the reference genome, for example, it includes:
[0135] The base sequence at each pixel position is matched with the base sequence in the reference genome to determine the position Pos of the gene fragment corresponding to the base sequence at each pixel position in the reference genome, as well as the difference information between the base sequence and the corresponding gene fragment, and the degree of error corresponding to the base sequence at the pixel position is determined based on the difference information.
[0136] The error level includes, for example, the number of incorrect base errors, the error rate, or other parameters that can represent the error level.
[0137] Among them, the position Pos of the gene fragment corresponding to the base sequence of each pixel position in the reference genome is used in the region growing process. The specific application method can be found in the following embodiment and will not be repeated here.
[0138] FIG4 shows an example of a fluorescence image sequence. In FIG4 , the fluorescence image sequence is composed of fluorescence images z1 through z10, each of which has a size of 512×512 pixels. Each pixel position can include one or multiple pixels, and the same pixel position in different fluorescence images has a corresponding relationship. For example, pixel position s1 corresponds to the pixel position at coordinates (100, 100) in all fluorescence images z1 through z10. The base sequence corresponding to pixel position s1 is composed of the base types at the pixel position at coordinates (100, 100) in all fluorescence images z1 through z10.
[0139] The base sequence obtained by base calling at each pixel position is compared with the reference genome to obtain the base sequence error level corresponding to that pixel position. The base sequence error level can include the number of incorrect bases or the error rate. The open source alignment software BWA can be used for this alignment.
[0140] Following the above S302, after obtaining the error degree of the base sequence of at least some pixel positions, the present application further includes the following steps.
[0141] S303: Pixel positions whose base sequence error levels are lower than a preset error level threshold are used as candidate pixel positions for region growing.
[0142] Here, for example, each pixel position can be traversed, and for the currently traversed pixel position, the error degree of the base sequence corresponding to the currently traversed pixel position is compared with a preset error degree threshold; if the error degree of the base sequence corresponding to the currently traversed pixel position is less than the preset error degree threshold, the currently traversed pixel position is used as a candidate pixel position, and an identifier is added to the candidate pixel position to indicate that the pixel position is a candidate pixel position.
[0143] For example, based on the comparison result, the identifier of the candidate pixel position is determined to be 1, and the identifier of the non-candidate pixel position is determined to be 0. In this way, the identifiers used to represent whether all pixel positions are candidate pixel positions constitute a binary image.
[0144] S304: Determine a seed point for base sequence region growth in the candidate pixel positions for region growing, and perform region growing based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel positions in the neighborhood of the seed point, and use the multiple regions obtained after growth as multiple fluorescent spots in the fluorescent image.
[0145] In a specific implementation, a seed point for base sequence region growing is determined at a candidate pixel position, and region growing is performed based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel position in the neighborhood of the seed point. For example, the following method can be used:
[0146] Based on the error degree of the base sequence corresponding to the candidate pixel position, the candidate pixel position is divided into multiple categories, and the priority of region growing is determined for each category;
[0147] In order of priority from high to low, multiple categories are traversed, and the seed point corresponding to the current category is determined from the candidate pixel positions corresponding to the current category traversed, and region growing is performed based on the similarity between the base sequence of the seed point corresponding to the current category and the base sequence of the candidate pixel positions in the neighborhood of the seed point.
[0148] In a specific implementation, when classifying candidate pixel positions, for example, each pixel position with a value of 1, that is, a candidate pixel position, can be read in sequence from the binary image generated in the above-mentioned step S302; then the error degree of the base sequence corresponding to the read candidate pixel position is determined, and based on the sequence error degree of the base corresponding to the candidate pixel position, the classification identifier corresponding to the candidate pixel position is determined to achieve classification of the candidate pixel position.
[0149] For example, assuming that the preset error level threshold is (m+1), all pixel positions with an error level less than the error level threshold are considered candidate pixel positions. The candidate pixel positions are divided into 0 to m categories according to the error level of the base sequence corresponding to each candidate pixel position, and each category corresponds to a category identifier.
[0150] Category 0: indicates alignment with the reference genome. There are no erroneous bases in the corresponding base fragments, and the position Pos of the gene fragment that matches the reference genome is recorded.
[0151] Category 1: indicates alignment with the reference genome. In the corresponding base sequence, there is an incorrect base, and the position Pos of the gene fragment that matches the reference genome is recorded;
[0152] …
[0153] Class m: indicates alignment with the reference genome. In the corresponding base sequence, there are m erroneous bases, and the position Pos of the gene fragment that matches the reference genome is recorded;
[0154] Since the classification corresponding to the 0-class point (that is, the candidate pixel position of class 0) indicates that the number of incorrect bases in the base sequence relative to the reference genome is 0, and the 0-class point has the highest degree of match with the reference genome, the 0-class point may be located in the center area of the base spot. According to the principle of center-outward expansion, the 0-class point can be set to the highest priority; the m-class point has the lowest degree of match with the reference genome, so the probability of it belonging to the spot is lower, and a lower priority can be determined for it, so that the pixel positions corresponding to each classification can be processed in descending order of priority, so that the spot in the fluorescence image can be segmented more accurately.
[0155] Then, multiple categories are traversed in descending order of priority of each category, and a seed point corresponding to the current category is determined among the candidate pixel positions corresponding to the current category that have been traversed.
[0156] When determining the seed point, the seed point can be determined according to the coordinate value of the candidate pixel position corresponding to the current classification. For example, among the multiple candidate pixel positions corresponding to the current classification, the candidate pixel position located in the center area is selected as the seed point corresponding to the current classification. In addition, one or more seed points can be determined for each classification. When using the seed point for region growing, if there are multiple seed points, the multiple seed points are used in turn for region growing.
[0157] Specifically, the embodiment of the present disclosure further provides a specific method for determining a seed point corresponding to the current classification from the candidate pixel positions corresponding to the current classification that have been traversed, and performing region growing based on the similarity between the base sequence of the seed point corresponding to the current classification and the base sequence of the candidate pixel positions in the neighborhood of the seed point, including:
[0158] At least one determination cycle is performed until no candidate pixel position of an undetermined belonging area exists among the pixel positions corresponding to the current classification that have been traversed.
[0159] In each determination cycle, the following process is performed:
[0160] Determine a target candidate pixel position from the candidate pixel positions corresponding to the current classification that have been traversed; wherein the target candidate pixel position includes a candidate pixel position of an undetermined belonging area;
[0161] Determine a seed point corresponding to the current classification at the target candidate pixel position, and perform region growing based on the similarity between the base sequence of the seed point corresponding to the current classification and the base sequence of the candidate pixel position within the neighborhood of the seed point;
[0162] Determine whether there are any candidate pixel positions whose belonging areas have not been determined under the current classification; if so, enter the next determination cycle.
[0163] For example, starting from traversing the class 0 points, there are N candidate pixel positions corresponding to the class 0 points. The set consisting of N candidate pixel positions is expressed as:
[0164] In the first cycle of traversing to the 0-type point, At least one seed point is determined in the algorithm, and region growing is performed based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel position in the corresponding neighborhood. In the above region growing process, At least some of the candidate pixel positions in the region are determined to belong to the region. In addition, the regions of candidate pixel positions of other classes are also determined, such as class 1 points, class 2 points, etc. Assume that after the region growing stops, there are still M class 0 points whose belonging regions are not determined. These class 0 points whose belonging regions are not determined constitute the set Among them, P 0_2 ∈P 0_1 . Enter the second confirmation cycle.
[0165] In the second cycle of traversing to the 0-type point, At least one seed point is determined in the algorithm, and region growing is performed based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel positions in the corresponding neighborhood. In addition, it is also possible to determine the belonging region for candidate pixel positions of other classes, such as Class 1 points, Class 2 points, etc. Assuming that there are no Class 0 points with undetermined belonging regions after the region growing stops, the traversal of Class 1 points will continue.
[0166] In the first determination cycle of Class 1 points, since some Class 1 points may have already been assigned to regions when traversing Class 0 points, in this case, all Class 1 points whose assigned regions have not been determined are first found from all Class 1 points, and these are used as the target candidate pixel positions for the first determination cycle. Assuming that there are K Class 1 points whose assigned regions have not been determined at this time, then the K Class 1 points whose assigned regions have been determined constitute the set: Then from At least one seed point is determined in the algorithm, and region growing is performed based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel position in the corresponding neighborhood. In the above region growing process, At least some of the candidate pixel positions in the region are determined to belong to the region. In addition, the regions of candidate pixel positions of other classes are also determined, such as class 2 points, class 3 points, etc. Assume that after the region growing stops, there are still L class 1 points whose belonging regions are not determined. These class 1 points whose belonging regions are not determined constitute the set Among them, P 1_2 ∈P 1_1 . Enter the second confirmation cycle.
[0167] In the second determination cycle when traversing to the point of type 1, At least one seed point is determined in the algorithm, and region growing is performed based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel positions in the corresponding neighborhood. In addition, it is also possible to determine the belonging region for candidate pixel positions of other classes, such as Class 2 points, Class 3 points, etc. Assuming that there are no Class 1 points with undetermined belonging regions after the region growing stops, the traversal of Class 2 points will continue.
[0168] …
[0169] Until m points are traversed, in the first determination cycle of traversing to m points, all m points in the undetermined region are first found from the m points, and used as the target candidate pixel positions for the first determination cycle. Then, seed points are determined from the target candidate pixel positions, and region growing is performed based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel positions in the corresponding neighborhood.
[0170] The traversal is terminated until there are no more m-type points whose belonging areas are not determined, and the spot area is obtained.
[0171] As shown in FIG5 , the embodiment of the present disclosure further provides a specific method for performing region growing based on the similarity between the base sequence of a seed point and the base sequences of candidate pixel positions in the neighborhood of the seed point, including:
[0172] Perform multiple region growing cycles as follows:
[0173] S501: Determine whether the candidate pixel position meets a region growing condition based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel position in the corresponding neighborhood.
[0174] Here, in the first round of region growing, except for the seed point pixel, all other candidate pixel positions are candidate pixel positions with undetermined belonging regions. Candidate pixel positions adjacent to the seed point can be determined as neighboring candidate pixel positions. In the Nth round of region growing, some candidate pixel positions have been determined to belong to the region where a fluorescent spot is located through the first to the N-1th rounds of region growing. Therefore, when determining the neighboring candidate pixel positions of the seed point, if the neighboring candidate pixel positions have already been determined to belong, these neighboring candidate pixel positions with already determined belongings are not considered when determining whether the region growing conditions are met.
[0175] The similarity between the base sequence of the seed point and the base sequence of the candidate pixel position in the corresponding neighborhood is used to describe the possibility of whether the base sequence of the seed point and the base sequence of the candidate pixel position in the corresponding neighborhood belong to the same light spot. The higher the similarity, the higher the possibility of belonging to the same light spot; the lower the similarity, the lower the possibility of belonging to the same light spot.
[0176] For example, for "class 0 points", when the selected seed point is a class 0 point, since the seed point and the reference genome can be completely matched, the higher the similarity between the base sequence of the seed point and the base sequence of the candidate pixel position in the corresponding neighborhood, the base sequence representing the candidate pixel position in the neighborhood belongs to the area where the light spot is located.
[0177] Furthermore, in this case, when determining whether a candidate pixel position meets the region growing condition, for example, the following method can be used:
[0178] determining a first comparison result between the first base sequence of the seed point and the second base sequence of the candidate pixel position in the corresponding neighborhood when the error degree of the first base sequence of the seed point indicates that the first base sequence of the seed point does not have errors;
[0179] If the first comparison result indicates that the number of different bases between the first base sequence and the second base sequence is less than a target threshold, determining that the candidate pixel position in the corresponding neighborhood meets the region growing condition;
[0180] If the first comparison result indicates that the number of different bases between the first base sequence and the second base sequence is greater than or equal to the target threshold, it is determined that the candidate pixel position in the corresponding neighborhood does not meet the region growing condition.
[0181] Here, the candidate pixel position whose belonging region is not determined means that it has not been determined whether the candidate pixel position belongs to the fluorescent spot in the previous region growing process.
[0182] For example, the target threshold t is 4. Assuming that the first comparison result indicates that the number of different bases between the first base sequence and the second base sequence is less than 4, the candidate pixel position in the corresponding neighborhood meets the region growing condition. If the number is greater than or equal to 4, it is determined that the candidate pixel position in the corresponding neighborhood does not meet the region growing condition.
[0183] For a candidate pixel position p1 within the neighborhood of the seed point, assuming that the candidate pixel position p1 is a Class 2 point, the number of base errors between the candidate pixel position p1 and the reference genome is 2, that is, the number of different bases between the first base sequence and the second base sequence is 2, which is less than the threshold value 4, then the candidate pixel position p1 meets the region growing condition. For a candidate pixel position p2 within the neighborhood of the seed point, assuming that the candidate pixel position p2 is a Class 4 point, the number of base errors between the candidate pixel position p2 and the reference genome is 4, that is, the number of different bases between the first base sequence and the second base sequence is 4, which is equal to the threshold value 4, then the candidate pixel position p2 does not meet the region growing condition.
[0184] At the same time, since the base sequence corresponding to each pixel position is not 100% accurate, but may contain certain errors due to various factors, this may result in that in some cases, even if the similarity between the base sequence of the seed point and the base sequence of the candidate pixel position in the corresponding neighborhood is low, there is a possibility that the candidate pixel point in the neighborhood belongs to the light spot area.
[0185] In this case, in order to utilize the similarity between the base sequence of the seed point and the base sequence of the candidate pixel position in the corresponding neighborhood to determine whether the candidate pixel position meets the region growing condition, the following method can be specifically used:
[0186] When the error degree of the first base sequence of the seed point indicates that the first base sequence of the seed point has an error, determining a first comparison result between the first base sequence of the seed point and the second base sequence of the candidate pixel position of the corresponding neighborhood;
[0187] If the first comparison result indicates that the number of different bases between the first base sequence and the second base sequence is less than a target threshold, determining that the candidate pixel position in the corresponding neighborhood meets the region growing condition;
[0188] If the first comparison result indicates that the number of different bases between the first base sequence and the second base sequence is greater than or equal to the target threshold, determining the number of different bases between the second base sequence and the reference genome based on the error level corresponding to the second base sequence;
[0189] If the number of different bases between the second base sequence and the reference genome is less than the target threshold, determining that the candidate pixel position in the corresponding neighborhood meets the region growing condition;
[0190] If the number of different bases between the second base sequence and the reference genome is greater than or equal to the target threshold, it is determined that the candidate pixel position in the corresponding neighborhood does not meet the region growing condition.
[0191] Specifically, when determining the number of different bases between the second base sequence and the reference genome based on the error degree corresponding to the second base sequence, the following method can be used:
[0192] Determine a first matching position of the first base sequence of the seed point in the reference genome, and a second matching position of the second base sequence of the candidate pixel position in the corresponding neighborhood in the reference genome;
[0193] When the first matching position and the second matching position are different, determining that the candidate pixel position in the corresponding neighborhood does not satisfy the region growing condition;
[0194] When the first matching position and the second matching position are the same, the number of different bases between the second base sequence and the reference genome is determined based on the error level corresponding to the second base sequence.
[0195] Assume that the threshold value t for the number of incorrect bases is 4, the seed point is marked as "type 3 point", the corresponding base sequence length of the seed point is 20, and when compared with the reference genome, the positions where the misalignment occurs are 2, 7, and 10, respectively. The position compared with the reference genome is TempPos;
[0196] The neighboring point p3 of the seed point is also marked as "type 3 point". When compared with the reference genome, the positions where the misalignment occurs are 5, 8, and 15, and the position compared with the reference genome is TempPos;
[0197] The neighborhood point is compared with the seed point p3. The number of incorrect bases is 6. According to the threshold t=4, it is determined that the neighborhood point and the seed point do not belong to the same region.
[0198] However, since the positions of the seed point and the neighborhood point compared to the reference genome are both TempPos, that is, the seed point and the neighborhood point correspond to the same gene fragment in the reference genome, the base sequence of the neighborhood point must also be compared with the base sequence of the reference genome.
[0199] Since the number of different bases between the base sequence of the neighborhood point and the base sequence of the reference gene is 3, which is less than the threshold value 4, it can also be considered that the neighborhood point p3 and the seed point belong to the same spot area.
[0200] S502: In response to the similarity corresponding to any candidate pixel position satisfying the region growing condition, determining the candidate pixel position as being located in the same region as the seed point;
[0201] S503: Determine whether the stop condition is met; if so, jump to S506; if not, jump to S504.
[0202] The stopping conditions include: the similarity between the base sequence of the determined seed point and the base sequence of the candidate pixel position in the corresponding neighborhood does not meet the region growing condition, or there is no candidate pixel position with an undetermined belonging region;
[0203] S504: determining the candidate pixel position determined to be located in the same area as the seed point as a new seed point;
[0204] S505: using the pixel position of the new seed point, determining the candidate pixel positions in the neighborhood of the new seed point, and jumping to S501;
[0205] S506: Stop region growing.
[0206] By using the above steps S501 to S503 , the pixel position belonging to the fluorescent spot can be determined from all candidate pixel positions.
[0207] After multiple rounds of region growing processing, multiple sub-growing regions corresponding to the respective classifications are obtained, and these sub-growing regions are combined to obtain a target growing region, which is the region where the fluorescent spot is located.
[0208] In one possible example, after obtaining the target growth region, the target growth region can be filtered. For example, the target growth region is filtered based on its area. If the target growth region is smaller than a preset area, the target growth region is filtered out. The preset area can be, for example, 5×5 or 7×7 pixel locations, which is set according to the actual application.
[0209] The preset area represents the possible minimum area of the light spot. When region growing is performed, due to interference from some noise, smaller regions may be grown. These regions are usually smaller than the minimum area of the light spot.
[0210] In addition, the present disclosure also provides a specific example of a region growing process, including the following steps:
[0211] 1. Set the classification threshold m when comparing the base sequence with the reference genome;
[0212] 2. Use bioinformatics alignment software (not limited to bwa) to align the base sequences. Mark the candidate pixel positions corresponding to the base sequences, where candidate pixel positions less than or equal to the classification threshold m are marked as 1; candidate pixel positions greater than the classification threshold m are marked as 0;
[0213] 3. Classify the candidate pixel positions marked as 1 into 0 to m types of points:
[0214] Class 0 points: base sequences that completely match the reference genome.
[0215] Category 1 point: When compared with the reference genome, if there is an incorrect base in the base sequence, the incorrect position of the incorrect base in the reference genome is recorded; and the alignment position Pos of the base sequence in the reference genome is recorded;
[0216] …
[0217] Class m points: compared with the reference genome, there are m erroneous bases in the base sequence, and the erroneous positions of the m erroneous bases in the reference genome are recorded; and the alignment position Pos of the base sequence in the reference genome is recorded;
[0218] 4. Select seed points from the order of "class 0 points" to "class m points" and put them into the queue.
[0219] 5. Take the pixel position marked as 1 from the queue, and classify the points that meet the region growing judgment conditions in the neighborhood candidate pixel position of the seed point (4 neighborhood or 8 neighborhood) as the same class as the seed point, put them into the queue, and mark the neighborhood candidate pixel position as 0 in the binary image;
[0220] Here, the specific process can be:
[0221] (51) The neighborhood point is determined to be a candidate pixel position, and its mark on the binary image is 1;
[0222] (52) Determine whether the position (Pos) of the neighboring point is consistent with the seed point on the reference genome alignment. If (Pos) is consistent and the seed point is marked as a "class 0 point", then proceed to step 52; otherwise, proceed to step 53:
[0223] (53) Determine the number of different bases in the base sequence between the neighborhood point and the seed point. If the number of different bases is less than the threshold t, the point is classified as the same region as the seed point, and the neighborhood point is marked as 0 in the binary image.
[0224] (54) If the seed point belongs to "type 1 point" to "type m point", the number of different bases between the neighborhood point and the seed point is determined. If the number of different bases is less than the threshold t, the point is classified as the same region as the seed point; if it is greater than the threshold t, the neighborhood point is directly compared with the reference genome based on its position Pos on the reference genome. If the number of different bases is less than the threshold t, the point is classified as the same region as the seed point and the neighborhood point is marked as 0 in the binary image.
[0225] 6. Repeat steps 4 to 5 to complete the region growth of all seed points and obtain the target growth area;
[0226] 7. Filter the target growth area in step 6, filtering out target growth areas smaller than a certain size (e.g., s*s pixels, where the value of s is not limited to 3, 5, 7, etc.). Obtain the filtered target growth area, and obtain the pixel position information of the target pixel position corresponding to the target growth area, that is, the area where the fluorescent spot is located.
[0227] The order in which the steps are written does not imply a strict order of execution and does not constitute any limitation on the implementation process. The specific order of execution of the steps should be determined by their functions and possible internal logic.
[0228] The present disclosure also provides a computer device, as shown in FIG6 , which is a schematic diagram of the structure of the computer device provided by the present disclosure, including:
[0229] Processor 61 and memory 62; the memory 62 stores machine-readable instructions executable by the processor 61, and the processor 61 is configured to execute the machine-readable instructions stored in the memory 62. When the machine-readable instructions are executed by the processor 61, the processor 61 performs the following steps:
[0230] performing base recognition on each pixel position in a plurality of fluorescent images to obtain a base sequence at each pixel position, wherein the plurality of fluorescent images are obtained through a plurality of gene sequencing cycles;
[0231] Compare the base sequence at each pixel position with the base sequence in the reference genome to determine the degree of base sequence error at each pixel position;
[0232] Pixel positions where the base sequence error level is lower than a preset error level threshold are used as candidate pixel positions for region growing, and seed points for region growing are determined among the candidate pixel positions for region growing;
[0233] Region growing is performed based on the similarity between the base sequence of the seed point and the base sequence of the corresponding neighboring candidate pixel position, and each region obtained after growing is used as each fluorescent spot in the fluorescent image.
[0234] The above-mentioned memory 62 includes internal memory 621 and external memory 622; the memory 621 here is also called internal memory, which is used to temporarily store the calculation data in the processor 61 and the data exchanged with the external memory 622 such as the hard disk. The processor 61 exchanges data with the external memory 622 through the internal memory 621.
[0235] The specific execution process of the above instructions can refer to the steps of the method for segmenting fluorescent spots in a fluorescent image described in the embodiment of the present disclosure, and will not be repeated here.
[0236] The present disclosure also provides a computer-readable storage medium storing a computer program that, when executed by a processor, executes the steps of the method for segmenting fluorescent spots in a fluorescent image described in the above method embodiment. The storage medium can be either volatile or non-volatile, computer-readable.
[0237] The present disclosure also provides a computer program product that carries program code. The program code includes instructions that can be used to execute the steps of the method for segmenting fluorescent spots in fluorescent images described in the above method embodiment. For details, please refer to the above method embodiment and will not be repeated here.
[0238] The computer program product may be implemented in hardware, software, or a combination thereof. In one embodiment, the computer program product is implemented as a computer storage medium. In another embodiment, the computer program product is implemented as a software product, such as a software development kit (SDK).
[0239] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems and devices described above can refer to the corresponding processes in the aforementioned method embodiments, and will not be repeated here. In the several embodiments provided in the present disclosure, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. The device embodiments described above are merely schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some communication interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0240] The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of these units may be selected to achieve the purpose of this embodiment according to actual needs.
[0241] In addition, each functional unit in each embodiment of the present disclosure may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
[0242] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a non-volatile computer-readable storage medium that is executable by a processor. Based on this understanding, the technical solution of the present disclosure, or the part that contributes to the prior art, or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes several instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the method described in each embodiment of the present disclosure. The aforementioned storage medium includes various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.
[0243] Finally, it should be noted that the above-described embodiments are only specific implementation methods of the present disclosure, which are used to illustrate the technical solutions of the present disclosure, rather than to limit them. The scope of protection of the present disclosure is not limited thereto. Although the present disclosure has been described in detail with reference to the above-described embodiments, those skilled in the art should understand that any person skilled in the art can modify or easily conceive of changes to the technical solutions described in the above-described embodiments within the technical scope disclosed in the present disclosure, or replace some of the technical features therein with equivalents. Such modifications, changes, or replacements do not deviate from the spirit and scope of the technical solutions of the embodiments of the present disclosure, and should be included in the scope of protection of the present disclosure. Therefore, the scope of protection of the present disclosure shall be subject to the scope of protection of the claims.
Claims
1. A computer device, characterized in that: include: A processor and a memory, wherein the memory stores machine-readable instructions executable by the processor, and the processor is configured to execute the machine-readable instructions stored in the memory. When the machine-readable instructions are executed by the processor, the processor performs a process of segmenting fluorescent spots in a fluorescent image, and the process of segmenting fluorescent spots in a fluorescent image includes: performing base recognition on at least a portion of pixel positions in a plurality of fluorescent images to obtain base sequences of the at least a portion of pixel positions, wherein the plurality of fluorescent images are obtained through a plurality of consecutive sequencing cycles; Comparing the base sequence of at least part of the pixel positions with the base sequence in a reference genome to determine the degree of error of the base sequence of at least part of the pixel positions; The pixel positions where the error level of the base sequence is lower than a preset error level threshold are used as candidate pixel positions for region growing; In the candidate pixel positions for region growing, a seed point for base sequence region growing is determined, and region growing is performed based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel positions in the neighborhood of the seed point, and the multiple regions obtained after growth are used as multiple fluorescent spots in the fluorescent image.
2. The computer device according to claim 1, wherein: The processor is further configured to perform image space correction on the multiple fluorescent images before performing base calling on at least part of pixel positions in the multiple fluorescent images.
3. The computer device according to claim 1, wherein: The processor performs the segmentation of the fluorescent spot in the fluorescent image, determining a seed point for base sequence region growing in the candidate pixel position for region growing, and performing region growing based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel position in the neighborhood of the seed point, including: Based on the error degree of the base sequence corresponding to the candidate pixel position, the candidate pixel position is divided into multiple categories, and the priority of region growing is determined for each category; In order of priority from high to low, multiple categories are traversed, and the seed point corresponding to the current category is determined from the candidate pixel positions corresponding to the current category traversed, and region growing is performed based on the similarity between the base sequence of the seed point corresponding to the current category and the base sequence of the candidate pixel positions in the neighborhood of the seed point.
4. The computer device according to any one of claims 1 to 3, characterized in that: In the process of executing the segmentation of the fluorescent spot in the fluorescent image by the processor, performing region growing according to the similarity between the base sequence of the seed point and the base sequence of the candidate pixel position in the neighborhood of the seed point includes: executing the following multiple region growing cycles until the similarity between the base sequence of the seed point determined in any region growing cycle and the base sequence of the candidate pixel position in the corresponding neighborhood fails to meet the region growing condition, or there is no candidate pixel position with an undetermined belonging region; Determining whether the candidate pixel position meets a region growing condition based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel position in the corresponding neighborhood; In response to the similarity corresponding to any candidate pixel position satisfying the region growing condition, determining the candidate pixel position as being located in the same region as the seed point, and determining the candidate pixel position as a new seed point; The pixel position of the new seed point is used to determine the candidate pixel positions in the neighborhood of the new seed point, and enter the next region growth cycle.
5. The computer device according to claim 4, wherein: In the process of executing the segmentation of the fluorescent spot in the fluorescent image by the processor, determining whether the candidate pixel position satisfies the region growing condition based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel position in the corresponding neighborhood includes: When the error degree of the first base sequence of the seed point indicates that there is no error in the first base sequence of the seed point, determining the first base sequence of the seed point and the first base sequence of the candidate pixel position in the corresponding neighborhood. The first alignment result of the two-base sequence; If the first comparison result indicates that the number of different bases between the first base sequence and the second base sequence is less than a target threshold, determining that the candidate pixel position in the corresponding neighborhood meets the region growing condition; If the first comparison result indicates that the number of different bases between the first base sequence and the second base sequence is greater than or equal to the target threshold, it is determined that the candidate pixel position in the corresponding neighborhood does not meet the region growing condition.
6. The computer device according to claim 4 or 5, characterized in that During the process of performing the segmentation of the fluorescent spot in the fluorescent image by the processor, determining whether the candidate pixel position in the corresponding neighborhood satisfies the region growing condition based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel position in the corresponding neighborhood, further comprising: When the error degree of the first base sequence of the seed point indicates that the first base sequence of the seed point has an error, determining a first comparison result between the first base sequence of the seed point and the second base sequence of the candidate pixel position of the corresponding neighborhood; If the first comparison result indicates that the number of different bases between the first base sequence and the second base sequence is less than a target threshold, determining that the candidate pixel position in the corresponding neighborhood meets the region growing condition; If the first comparison result indicates that the number of different bases between the first base sequence and the second base sequence is greater than or equal to the target threshold, determining the number of different bases between the second base sequence and the reference genome based on the error level corresponding to the second base sequence; If the number of different bases between the second base sequence and the reference genome is less than the target threshold, determining that the candidate pixel position in the corresponding neighborhood meets the region growing condition; If the number of different bases between the second base sequence and the reference genome is greater than or equal to the target threshold, it is determined that the candidate pixel position in the corresponding neighborhood does not meet the region growing condition.
7. The computer device according to claim 6, wherein: During the process of segmenting the fluorescent spot in the fluorescent image performed by the processor, determining the number of different bases between the second base sequence and the reference genome according to the error degree corresponding to the second base sequence includes: Determine a first matching position of the first base sequence of the seed point in the reference genome, and a second matching position of the second base sequence of the candidate pixel position in the corresponding neighborhood in the reference genome; When the first matching position and the second matching position are different, determining that the candidate pixel position in the corresponding neighborhood does not satisfy the region growing condition; When the first matching position and the second matching position are the same, the number of different bases between the second base sequence and the reference genome is determined based on the error level corresponding to the second base sequence.
8. The computer device according to claim 3, wherein: The processor performs, during the segmentation of the fluorescent spot in the fluorescent image, determining a seed point corresponding to the current classification from the traversed candidate pixel positions corresponding to the current classification, and performing region growing based on the similarity between the base sequence of the seed point corresponding to the current classification and the base sequence of the candidate pixel positions in the neighborhood of the seed point, including: Perform at least one determination cycle until there are no candidate pixel positions for which the belonging area has not been determined among the pixel positions corresponding to the current classification traversed: Determine a target candidate pixel position from the candidate pixel positions corresponding to the current classification that have been traversed; wherein the target candidate pixel position includes a candidate pixel position of an undetermined belonging area; Determine a seed point corresponding to the current classification at the target candidate pixel position, and perform region growing based on the similarity between the base sequence of the seed point corresponding to the current classification and the base sequence of the candidate pixel position within the neighborhood of the seed point; Determine whether there are any candidate pixel positions whose belonging areas have not been determined under the current classification; if so, enter the next determination cycle.
9. The computer device according to claim 1, wherein: The computer device is a computer device in a gene sequencing system, or a computer device that wirelessly communicates with a gene sequencing system.
10. A method for segmenting fluorescent spots in a fluorescent image, characterized in that: The method comprises: performing base recognition on at least a portion of pixel positions in a plurality of fluorescent images to obtain base sequences of the at least a portion of pixel positions, wherein the plurality of fluorescent images are obtained through a plurality of consecutive sequencing cycles; Comparing the base sequence of at least part of the pixel positions with the base sequence in a reference genome to determine the degree of error of the base sequence of at least part of the pixel positions; The pixel positions where the error level of the base sequence is lower than a preset error level threshold are used as candidate pixel positions for region growing; In the candidate pixel positions for region growing, a seed point for base sequence region growing is determined, and region growing is performed based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel positions in the neighborhood of the seed point, and the multiple regions obtained after growth are used as multiple fluorescent spots in the fluorescent image.
11. The method according to claim 10, characterized in that Also includes: Before performing base calling on at least part of the pixel positions in the plurality of fluorescence images, image space correction is performed on the plurality of fluorescence images.
12. The method according to claim 10, characterized in that The step of determining a seed point for base sequence region growing in a candidate pixel position for region growing, and performing region growing based on similarity between a base sequence of the seed point and a base sequence of a candidate pixel position in a neighborhood of the seed point, comprises: Based on the error degree of the base sequence corresponding to the candidate pixel position, the candidate pixel position is divided into multiple categories, and the priority of region growing is determined for each category; In order of priority from high to low, multiple categories are traversed, and the seed point corresponding to the current category is determined from the candidate pixel positions corresponding to the current category traversed, and region growing is performed based on the similarity between the base sequence of the seed point corresponding to the current category and the base sequence of the candidate pixel positions in the neighborhood of the seed point.
13. The method according to any one of claims 10 to 12, characterized in that: The performing region growing based on the similarity between the base sequence of the seed point and the base sequences of the candidate pixel positions in the neighborhood of the seed point includes: executing the following multiple region growing cycles until the similarity between the base sequence of the seed point determined in any region growing cycle and the base sequence of the candidate pixel position in the corresponding neighborhood fails to meet the region growing condition, or there is no candidate pixel position with an undetermined belonging region; Determining whether the candidate pixel position meets a region growing condition based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel position in the corresponding neighborhood; In response to the similarity corresponding to any candidate pixel position satisfying the region growing condition, determining the candidate pixel position as being located in the same region as the seed point, and determining the candidate pixel position as a new seed point; The pixel position of the new seed point is used to determine the candidate pixel positions in the neighborhood of the new seed point, and enter the next region growth cycle.
14. The method according to claim 13, characterized in that The determining whether the candidate pixel position satisfies the region growing condition based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel position in the corresponding neighborhood includes: determining a first comparison result between the first base sequence of the seed point and the second base sequence of the candidate pixel position in the corresponding neighborhood when the error degree of the first base sequence of the seed point indicates that the first base sequence of the seed point does not have errors; If the first comparison result indicates that the number of different bases between the first base sequence and the second base sequence is less than a target threshold, determining that the candidate pixel position in the corresponding neighborhood meets the region growing condition; If the first comparison result indicates the number of different bases between the first base sequence and the second base sequence If the value is greater than or equal to the target threshold, it is determined that the candidate pixel position in the corresponding neighborhood does not meet the region growing condition.
15. The method according to claim 13 or 14, characterized in that The determining whether the candidate pixel positions in the corresponding neighborhood meet the region growing condition based on the similarity between the base sequence of the seed point and the base sequence of the candidate pixel positions in the corresponding neighborhood further includes: When the error degree of the first base sequence of the seed point indicates that the first base sequence of the seed point has an error, determining a first comparison result between the first base sequence of the seed point and the second base sequence of the candidate pixel position of the corresponding neighborhood; If the first comparison result indicates that the number of different bases between the first base sequence and the second base sequence is less than a target threshold, determining that the candidate pixel position in the corresponding neighborhood meets the region growing condition; If the first comparison result indicates that the number of different bases between the first base sequence and the second base sequence is greater than or equal to the target threshold, determining the number of different bases between the second base sequence and the reference genome based on the error level corresponding to the second base sequence; If the number of different bases between the second base sequence and the reference genome is less than the target threshold, determining that the candidate pixel position in the corresponding neighborhood meets the region growing condition; If the number of different bases between the second base sequence and the reference genome is greater than or equal to the target threshold, it is determined that the candidate pixel position in the corresponding neighborhood does not meet the region growing condition.
16. The method according to claim 15, characterized in that The determining, based on the error level corresponding to the second base sequence, the number of base differences between the second base sequence and the reference genome, includes: Determine a first matching position of the first base sequence of the seed point in the reference genome, and a second matching position of the second base sequence of the candidate pixel position in the corresponding neighborhood in the reference genome; When the first matching position and the second matching position are different, determining that the candidate pixel position in the corresponding neighborhood does not satisfy the region growing condition; When the first matching position and the second matching position are the same, the number of different bases between the second base sequence and the reference genome is determined based on the error level corresponding to the second base sequence.
17. The method according to claim 12, wherein: The step of determining a seed point corresponding to the current classification from the candidate pixel positions corresponding to the current classification that have been traversed, and performing region growing based on the similarity between the base sequence of the seed point corresponding to the current classification and the base sequence of the candidate pixel positions in the neighborhood of the seed point, includes: Perform at least one determination cycle until there are no candidate pixel positions for which the belonging area has not been determined among the pixel positions corresponding to the current classification traversed: Determine a target candidate pixel position from the candidate pixel positions corresponding to the current classification that have been traversed; wherein the target candidate pixel position includes a candidate pixel position of an undetermined belonging area; Determine a seed point corresponding to the current classification at the target candidate pixel position, and perform region growing based on the similarity between the base sequence of the seed point corresponding to the current classification and the base sequence of the candidate pixel position within the neighborhood of the seed point; Determine whether there are any candidate pixel positions whose belonging areas have not been determined under the current classification; if so, enter the next determination cycle.
18. A gene sequencing system, characterized in that: The gene sequencing system includes: a chip, a chip platform, a reagent storage container, a flow guidance system, an optical detection system and a computer device; Wherein, one or more sequencing objects are attached to the chip; The chip platform is configured to fix and support the chip; The reagent storage container is configured to store one or more reagents; The flow guide system is configured to controllably transport the one or more reagents from the reagent storage container to the The chip is placed in the chip so as to contact with the sequencing object and undergo a chemical reaction; The optical detection system is configured to excite fluorescent markers in sequencing reagents, detect fluorescent signals generated by the excitation of the fluorescent markers, and generate fluorescent images based on the fluorescent signals; The computer device is configured to acquire a plurality of the fluorescent images from the optical detection system, and identify the base sequence of the sequencing object using the method for segmenting fluorescent spots in a fluorescent image according to any one of claims 10 to 17.
19. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a computer program. When the computer program is executed by a computer device, the computer device performs the steps of the method for segmenting fluorescent spots in a fluorescent image according to any one of claims 10 to 17.
Citation Information
Patent Citations
Base cluster detection method and device, gene sequencer and storage medium
CN116596933A
Fluorescent cluster center positioning method and device, terminal equipment and storage medium
CN116597005A
Method for segmenting fluorescent light spots in fluorescent image, computer equipment and computer readable storage medium
CN118154876A
Nucleic acid analysis device and nucleic acid analysis method
JP2019012082A
System for predicting microsatellite instability and construction method thereof, terminal device and medium
US20240062881A1