Microscope image splicing method and device

By using a coding structure-based method in microscope image stitching, image features are extracted and stage displacement coding information is added, the problems of large calculation amount and low accuracy in the prior art are solved, and efficient and accurate image stitching effect is achieved.

CN119831833AActive Publication Date: 2025-04-15SUZHOU INST OF BIOMEDICAL ENG & TECH CHINESE ACADEMY OF SCI

Patent Information

Application Number
CN202411902821.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-23
Publication Date
2025-04-15
Estimated Expiration
2044-12-23

AI Technical Summary

Technical Problem

The existing microscope image stitching method has a large amount of calculation and low accuracy. Especially when processing large-size images and images with similar features, there is a problem of risk of misidentification and poor accuracy.

Method used

Using a microscope image stitching method based on the encoding structure, image features are extracted through the encoder and accelerated using GPU, reducing the calculation amount and improving processing speed and stitching accuracy. At the same time, add stage displacement encoding information to the encoder or generator to further improve the splicing effect.

Benefits of technology

It realizes the rapid completion of image stitching and high accuracy, effectively avoiding the problems of long calculation time and poor accuracy, and improving the quality and efficiency of image stitching.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119831833A_ABST
    Figure CN119831833A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of image processing, and discloses a microscope image stitching method and device, and the method comprises the steps: obtaining a to-be-stitched image, the to-be-stitched image being an image obtained when a target sample is shot through a microscope, and the to-be-stitched image carrying corresponding objective table position information when the image is shot; inputting the to-be-spliced images into a pre-constructed encoder for encoding to obtain encoding results corresponding to the to-be-spliced images one by one; and inputting the coding results in one-to-one correspondence with the to-be-spliced images and the position information of the objective table into a pre-constructed generator to generate an image splicing result. According to the microscope image splicing method adopted by the invention, image splicing can be quickly completed for images with large microscope image sizes and high feature similarity, the precision is high, and the problems of long calculation time and poor precision are effectively avoided.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of image processing, and in particular to a microscope image stitching method and device. Background Art

[0002] A microscope is an optical instrument used to magnify tiny objects, cell structures, microorganisms, and other objects that cannot be directly observed by the naked eye. It is widely used in biology, medicine, materials science, chemistry, and other fields. However, when analyzing the entire tissue at a microscopic scale, it is necessary to meet both clarity requirements and field of view requirements. Although the microscope can meet the accuracy requirements, the field of view will be reduced accordingly, so it is necessary to use a microscope to scan and photograph the tissue to be analyzed, and then use a stitching method to obtain a high-precision, large-scale tissue image.

[0003] At present, there are two main methods for microscopy image stitching: one is feature-based stitching, and the other is phase-based stitching. Among them, feature-based stitching is to extract the corner features of the two images, then match the features, calculate the affine transformation matrix based on the feature matching results, project the image to be stitched into the reference image coordinate system according to the transformation matrix, and finally complete the image stitching through the fusion algorithm. However, this feature calculation method is time-consuming, especially for large-size images taken by microscopes, calculating features will consume a lot of memory and time, and the cell morphology in tissue images is highly similar. The feature-based method has the risk of misidentification for images with similar features, resulting in incorrect stitching results. Phase-based stitching uses fast Fourier transform to process and superimpose the images to be stitched, and then obtains the stitched image through inverse Fourier transform. However, the accuracy of this stitching method is poor. Summary of the invention

[0004] In view of this, the present invention provides a microscope image stitching method and device to solve the problem of large amount of calculation and low precision in the microscope image stitching method in the prior art.

[0005] In a first aspect, the present invention provides a microscope image stitching method, the method comprising:

[0006] Acquire an image to be stitched, where the image to be stitched is an image obtained when a target sample is photographed through a microscope, and the image to be stitched carries the corresponding stage position information when the image is photographed;

[0007] Input the images to be spliced ​​into a pre-built encoder for encoding, and obtain encoding results corresponding to the images to be spliced ​​one by one;

[0008] The one-to-one corresponding encoding results of the images to be stitched and the stage position information are input into a pre-built generator to generate the image stitching result.

[0009] The present invention proposes a microscope image stitching method based on a coding structure, wherein an encoder is used to extract image features, and this step is accelerated by a GPU, which can effectively improve the processing speed, and the stage displacement coding information is added to the encoder or generator, which can further reduce the amount of calculation and improve the processing speed and stitching accuracy, and finally a stitched image is generated by a generator. The microscope image stitching method adopted by the present invention can effectively target images with large microscope image size and high feature similarity, and can quickly complete image stitching with high accuracy, effectively avoiding the problem of long calculation time and poor accuracy.

[0010] In an optional implementation, after acquiring the images to be stitched, the method further includes:

[0011] A light source correction algorithm is used to perform light source correction on the image to be stitched, and the image to be stitched after light source correction is used as input to the encoder.

[0012] In this embodiment, before encoding the image to be stitched, the image is also corrected for light source non-uniformity through the gamma light source correction algorithm. The corrected image can effectively eliminate the non-uniformity of the light source, improve the consistency of image brightness and contrast, and thus reduce the error caused by lighting differences. This not only helps to enhance the overall quality of the image, but also significantly improves the accuracy of image matching during the stitching process, ensuring the clarity and accuracy of the final synthesized image.

[0013] In an optional implementation, a light source correction algorithm is used to perform light source correction on the image to be stitched, including:

[0014] Convert the image to be stitched into an HSV format image;

[0015] Extract brightness component based on HSV format image;

[0016] Perform multi-scale Gaussian convolution based on the brightness component to obtain the illumination component;

[0017] The preset function is used to correct the illumination component to obtain the corrected image to be stitched.

[0018] In this embodiment, the brightness difference in the image caused by the non-uniformity of the light source is effectively eliminated through the gamma light source correction algorithm, making the brightness distribution of the image more uniform, thereby improving the visual effect of the overall image and effectively improving the quality of image stitching.

[0019] In an optional implementation, the preset function is:

[0020]

[0021] Among them, O(x, y) is the corrected pixel brightness value, F(x, y) is the pixel brightness value of the image to be stitched, x and y are both pixel coordinates, Wherein, I(x, y) is the illumination component of the image to be stitched, and m is the mean brightness of the illumination component.

[0022] In this implementation, the gamma function is used to correct the illumination component, and the image is resynthesized using the corrected brightness to obtain the image after light source correction. This correction method can nonlinearly adjust the image brightness, accurately correct the brightness deviation caused by the unevenness of the light source, and while improving the visual balance of the image, it also retains the image detail information, thereby effectively improving the overall quality of the spliced ​​image.

[0023] In an optional embodiment, the pre-built encoder includes:

[0024] The self-attention layer, the first residual connection and normalization layer, the feedforward network layer, the second residual connection and normalization layer are connected in sequence.

[0025] In this implementation, the encoder structure can effectively extract deep features of the image and improve the stitching accuracy and quality.

[0026] In an optional embodiment, the pre-built generator includes:

[0027] The masked self-attention layer, the third residual connection and normalization layer, the decoding self-attention layer, the fourth residual connection and normalization layer, the feedforward network layer, and the fifth residual connection and normalization layer are connected in sequence.

[0028] In this implementation, the generator structure can effectively enhance image detail restoration and improve stitching accuracy.

[0029] In a second aspect, the present invention provides a microscope image stitching device, the device comprising:

[0030] An acquisition module is used to acquire the image to be stitched, where the image to be stitched is an image obtained when a target sample is photographed through a microscope, and the image to be stitched carries the corresponding stage position information when the image is photographed;

[0031] The encoding module is used to input the images to be spliced ​​into a pre-built encoder for encoding, and obtain encoding results corresponding to the images to be spliced ​​one by one;

[0032] The generation module is used to input the one-to-one corresponding encoding results of the images to be stitched and the position information of the stage into a pre-built generator to generate an image stitching result.

[0033] In a third aspect, the present invention provides a computer device, comprising: a memory and a processor, the memory and the processor being communicatively connected to each other, the memory storing computer instructions, and the processor executing the microscope image stitching method of the first aspect or any corresponding embodiment thereof by executing the computer instructions.

[0034] In a fourth aspect, the present invention provides a computer-readable storage medium storing computer instructions for causing a computer to execute the microscope image stitching method of the first aspect or any corresponding embodiment thereof.

[0035] In a fifth aspect, the present invention provides a computer program product, comprising computer instructions for causing a computer to execute the microscope image stitching method of the first aspect or any corresponding embodiment thereof.

[0036] It should be noted that the microscope image stitching device, computer device, computer readable storage medium and computer program product provided by the present invention correspond to the above-mentioned microscope image stitching method. Therefore, for the beneficial effects of the microscope image stitching device, computer device, computer readable storage medium and computer program product, please refer to the description of the corresponding beneficial effects of the microscope image stitching method above, which will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS

[0037] In order to more clearly illustrate the specific implementation methods of the present invention or the technical solutions in the prior art, the drawings required for use in the specific implementation methods or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some implementation methods of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0038] Figure 1 is a schematic flow chart of a microscope image stitching method according to an embodiment of the present invention;

[0039] Figure 2 is a schematic diagram of a scanned original image according to an embodiment of the present invention;

[0040] Figure 3 is a schematic diagram of stitching images according to an embodiment of the present invention;

[0041] Figure 4 is a flow chart of another microscope image stitching method according to an embodiment of the present invention;

[0042] Figure 5 is a schematic diagram of a stitched image after correction according to an embodiment of the present invention;

[0043] Figure 6 is a schematic diagram of stitching image details according to an embodiment of the present invention;

[0044] Figure 7 is a schematic diagram of an encoder structure according to an embodiment of the present invention;

[0045] Figure 8 is a schematic diagram of a generator structure according to an embodiment of the present invention;

[0046] Fig. 9 is a structural block diagram of a microscope image stitching device according to an embodiment of the present invention;

[0047] Fig.10 It is a schematic diagram of the hardware structure of a computer device according to an embodiment of the present invention. DETAILED DESCRIPTION

[0048] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present invention.

[0049] According to an embodiment of the present invention, an embodiment of a microscope image stitching method is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.

[0050] In this embodiment, a microscope image stitching method is provided, which can be executed by a server, a terminal, a mobile terminal and other devices. Figure 1 is a flow chart of a microscope image stitching method according to an embodiment of the present invention. Figure 1 As shown, the process includes the following steps:

[0051] Step S101 , obtaining an image to be stitched, where the image to be stitched is an image obtained when a target sample is photographed through a microscope, and the image to be stitched carries the corresponding stage position information when the image is photographed.

[0052] In this embodiment, the target sample can be photographed by controlling the microscope to perform an S-shaped scanning, and the position of the stage during each photographing can be recorded, that is, the stage position information.

[0053] The stage position information may include two-dimensional coordinate information. Usually, the stage of a microscope moves on a two-dimensional plane, so the stage position information may be an (X, Y) coordinate pair, indicating the specific position of each shooting position during the scanning process. In addition, the stage position information also includes sequence coding, that is, the microscope scans in an S-shaped or other scanning manner, so sequence coding can be used to indicate the order of each shooting point. For example, in an S-shaped scan, the code may be a serial number, indicating the number of positions in the scanning path at which the current shooting point is taken. In this way, it is convenient for the encoder or generator to further understand the shooting order and position of the image and improve the image stitching quality.

[0054] This embodiment also provides a shooting example, which is an original image obtained by scanning a resolution plate under bright field. Figure 2 shown.

[0055] Step S102, input the images to be spliced ​​into a pre-built encoder for encoding, and obtain encoding results corresponding to the images to be spliced ​​one by one. The encoding results refer to feature representations obtained after the encoder processes the images to be spliced, that is, image features extracted by the encoder.

[0056] The image to be stitched is input into the pre-built encoder, which can convert the image data into feature vectors or feature maps, which contain key information in the image, such as edges, shapes, textures, colors, etc. These encoding results help the encoder model understand the content of the image and provide feature information for subsequent stitching tasks.

[0057] The encoder structure used in this embodiment includes but is not limited to a convolutional neural network encoder, a variational autoencoder, a Transformer encoder, etc. When training the encoder, the stage displacement encoding information is also loaded, which can be used as part of the feature representation.

[0058] Step S103, inputting the one-to-one corresponding encoding results of the images to be stitched and the stage position information into a pre-built generator to generate an image stitching result.

[0059] The encoding result and the stage position information are fed into the pre-trained generator, which may include a multi-layer network, such as a mask self-attention layer, a decoding self-attention layer, etc., to process the image. The mask self-attention layer can selectively focus on the image splicing area, while the decoding self-attention layer helps restore the details of the image. Finally, a complete spliced ​​image can be obtained. The complete spliced ​​resolution plate image is referenced. Figure 3 shown.

[0060] The generator structure used in this embodiment includes but is not limited to an inverse convolutional neural network, an attention mechanism decoder, a variational autoencoder decoder, a Transformer decoder, etc.

[0061] The present invention proposes a microscope image stitching method based on a coding structure, wherein an encoder is used to extract image features, and this step is accelerated by a GPU, which can effectively improve the processing speed, and the stage displacement coding information is added to the encoder or generator, which can further reduce the amount of calculation and improve the processing speed and stitching accuracy, and finally a stitched image is generated by a generator. The microscope image stitching method adopted by the present invention can effectively target images with large microscope image size and high feature similarity, and can quickly complete image stitching with high accuracy, effectively avoiding the problem of long calculation time and poor accuracy.

[0062] In some optional implementations, after acquiring the images to be stitched, the method further includes:

[0063] A light source correction algorithm is used to perform light source correction on the image to be stitched, and the image to be stitched after light source correction is used as input to the encoder.

[0064] Reference Figure 4 As shown, after obtaining the image to be stitched, the Figure 2 After the samples 1, 2, ..., n in the image are obtained, the gamma light source correction algorithm can be used to correct the light source of the image, and then the image after light source correction is input into the pre-trained encoder, and the encoder is used to encode the image to be spliced ​​respectively, and then the encoding result and the sample position encoding are input into the generator together, and finally the complete image of the target sample after splicing is obtained. The complete image obtained after light source correction is referenced Figure 5 shown.

[0065] In this embodiment, before encoding the image to be stitched, the image is also corrected for light source non-uniformity through the gamma light source correction algorithm. The corrected image can effectively eliminate the non-uniformity of the light source, improve the consistency of image brightness and contrast, and thus reduce the error caused by illumination differences. This not only helps to enhance the overall quality of the image, but also significantly improves the accuracy of image matching during the stitching process, ensuring the clarity and accuracy of the final synthesized image.

[0066] In some optional implementations, a light source correction algorithm is used to perform light source correction on the image to be stitched, including:

[0067] Convert the images to be stitched into HSV format images.

[0068] Extract the brightness component based on the HSV format image.

[0069] Multi-scale Gaussian convolution is performed based on the brightness component to obtain the illumination component.

[0070] The preset function is used to correct the illumination component to obtain the corrected image to be stitched.

[0071] Specifically, the image to be spliced ​​is first converted from RGB format to HSV (hue, saturation, brightness) format. The brightness component in the HSV format can be more easily processed independently of the color information, which is convenient for brightness and light source correction. Furthermore, in order to extract the illumination information of the image to be spliced, that is, the illumination change information that is irrelevant to the image content, the brightness component can be processed using multi-scale Gaussian convolution. Gaussian convolution can effectively remove the detail information in the image by smoothing the image, retaining only the illumination component. After multi-scale Gaussian convolution processing, the illumination component can be obtained, which represents the illumination intensity of each pixel in the image and reflects the global illumination non-uniformity of the image. Finally, the illumination component is corrected by a two-dimensional gamma function to correct the brightness deviation caused by illumination non-uniformity.

[0072] In this embodiment, the gamma light source correction algorithm effectively eliminates the brightness difference caused by the unevenness of the light source in the image, making the brightness distribution of the image more uniform, thereby improving the visual effect of the overall image and effectively improving the quality of image stitching. Figure 6 As shown, from the edge of the spliced ​​4 images, it can be seen that there is no pixel misalignment and deformation.

[0073] In some optional implementations, the preset function is:

[0074]

[0075] Among them, O(x, y) is the corrected pixel brightness value, F(x, y) is the pixel brightness value of the image to be stitched, x and y are both pixel coordinates, Wherein, I(x, y) is the illumination component of the image to be stitched, and m is the mean brightness of the illumination component.

[0076] In this embodiment, the gamma function is used to correct the illumination component, and the image is resynthesized using the corrected brightness to obtain the image after light source correction. This correction method can nonlinearly adjust the image brightness, accurately correct the brightness deviation caused by the unevenness of the light source, and while improving the visual balance of the image, it also retains the image detail information, thereby effectively improving the overall quality of the spliced ​​image.

[0077] In some optional embodiments, the pre-built encoder includes:

[0078] The self-attention layer, the first residual connection and normalization layer, the feedforward network layer, the second residual connection and normalization layer are connected in sequence.

[0079] This embodiment provides a specific structure of an encoder, referring to Figure 7 As shown in the figure, the self-attention layer can capture the long-distance dependencies in the image, ensure the visual consistency of the splicing area, and reduce the incoordination of the boundary; the residual connection and normalization layer can help the model better transfer the gradient, avoid the gradient vanishing problem in training, and thus improve the stability of the splicing effect and the ability to restore details. This encoder structure can effectively extract the deep features of the image and improve the splicing accuracy and quality.

[0080] In some optional implementations, the pre-built generator includes:

[0081] The masked self-attention layer, the third residual connection and normalization layer, the decoding self-attention layer, the fourth residual connection and normalization layer, the feedforward network layer, and the fifth residual connection and normalization layer are connected in sequence.

[0082] The pre-training data sets of the encoder and generator can select microscopic images of several different samples as data sets, including resolution plates under bright field, encoding chips under fluorescence field, tissue sections under fluorescence field, etc. Different scanning steps are set for each type of sample according to the size.

[0083] In this embodiment, a specific generator structure is provided, referring to Figure 8 As shown in the figure, the masked self-attention layer can effectively focus on the contextual information of the spliced ​​area, ensure the seamless fusion of the image content, and avoid defects or unnatural seams at the splicing. Through multiple residual connections and normalization layers, the generator can optimize the gradient transfer and improve the detail loss problem that may occur during the training process, thereby ensuring the detail fidelity and global consistency of the spliced ​​image. This generator structure can effectively enhance the image detail restoration and improve the splicing accuracy.

[0084] In this embodiment, a microscope image stitching device is also provided, which is used to implement the above-mentioned embodiments and preferred embodiments, and the descriptions that have been made will not be repeated. As used below, the term "module" can implement a combination of software and / or hardware of a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, the implementation of hardware, or a combination of software and hardware, is also possible and conceivable.

[0085] This embodiment provides a microscope image stitching device, such as Fig. 9 As shown, the device comprises:

[0086] The acquisition module 201 is used to acquire the image to be stitched, where the image to be stitched is an image obtained when a target sample is photographed through a microscope, and the image to be stitched carries the corresponding stage position information when the image is photographed.

[0087] The encoding module 202 is used to input the images to be spliced ​​into a pre-constructed encoder for encoding to obtain a one-to-one encoding result of the images to be spliced; wherein the pre-constructed encoder includes: a self-attention layer, a first residual connection and a normalization layer, a feedforward network layer, and a second residual connection and a normalization layer connected in sequence.

[0088] The generation module 203 is used to input the encoding results of the images to be stitched and the stage position information into a pre-built generator in one-to-one correspondence to generate an image stitching result. The pre-built generator includes: a mask self-attention layer, a third residual connection and normalization layer, a decoding self-attention layer, a fourth residual connection and normalization layer, a feedforward network layer, and a fifth residual connection and normalization layer connected in sequence.

[0089] In some optional embodiments, the device comprises:

[0090] The correction module is used to correct the light source of the image to be spliced ​​by using the light source correction algorithm, and the image to be spliced ​​after the light source correction is used to input the encoder. It includes: converting the image to be spliced ​​into an HSV format image; extracting the brightness component based on the HSV format image; performing multi-scale Gaussian convolution based on the brightness component to obtain the illumination component; and correcting the illumination component using a preset function to obtain the corrected image to be spliced.

[0091] The microscope image stitching device in this embodiment is presented in the form of a functional unit, where the unit refers to an ASIC circuit, a processor and memory that executes one or more software or fixed programs, and / or other devices that can provide the above functions.

[0092] The further functional description of each of the above modules and units is the same as that of the above corresponding embodiments and will not be repeated here.

[0093] The embodiment of the present invention also provides a computer device having the above Fig. 9 The microscope image stitching device shown.

[0094] See also Fig.10 , Fig.10 is a schematic diagram of the structure of a computer device provided by an optional embodiment of the present invention, such as Fig.10As shown, the computer device includes: one or more processors 10, a memory 20, and interfaces for connecting various components, including high-speed interfaces and low-speed interfaces. Various components are connected to each other using different buses for communication, and can be installed on a common mainboard or installed in other ways as needed. The processor can process the instructions executed in the computer device, including instructions stored in or on the memory to display the graphical information of the GUI on an external input / output device (such as, a display device coupled to the interface). In some optional embodiments, if necessary, multiple processors and / or multiple buses can be used together with multiple memories and multiple memories. Similarly, multiple computer devices can be connected, and each device provides some necessary operations (for example, as a server array, a group of blade servers, or a multi-processor system). Fig.10 A processor 10 is taken as an example.

[0095] The processor 10 may be a central processing unit, a network processor or a combination thereof. The processor 10 may further include a hardware chip. The hardware chip may be a dedicated integrated circuit, a programmable logic device or a combination thereof. The programmable logic device may be a complex programmable logic device, a field programmable gate array, a general purpose array logic or any combination thereof.

[0096] The memory 20 stores instructions executable by at least one processor 10, so that the at least one processor 10 executes the method shown in the above embodiment.

[0097] The memory 20 may include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function; the data storage area may store data created according to the use of the computer device, etc. In addition, the memory 20 may include a high-speed random access memory, and may also include a non-transient memory, such as at least one disk storage device, a flash memory device, or other non-transient solid-state storage device. In some optional embodiments, the memory 20 may optionally include a memory remotely arranged relative to the processor 10, and these remote memories may be connected to the computer device via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0098] The memory 20 may include a volatile memory, such as a random access memory; the memory may also include a non-volatile memory, such as a flash memory, a hard disk or a solid state drive; the memory 20 may also include a combination of the above types of memory.

[0099] The computer device further comprises a communication interface 30 for the computer device to communicate with other devices or a communication network.

[0100] The embodiment of the present invention also provides a computer-readable storage medium. The method according to the embodiment of the present invention can be implemented in hardware, firmware, or can be implemented as a computer code that can be recorded in a storage medium, or can be implemented as a computer code that is originally stored in a remote storage medium or a non-temporary machine-readable storage medium and will be stored in a local storage medium through a network download, so that the method described herein can be stored in such software processing on a storage medium using a general-purpose computer, a dedicated processor, or programmable or dedicated hardware. Among them, the storage medium can be a magnetic disk, an optical disk, a read-only storage memory, a random access memory, a flash memory, a hard disk or a solid-state hard disk, etc.; further, the storage medium can also include a combination of the above types of memories. It can be understood that a computer, a processor, a microprocessor controller, or programmable hardware includes a storage component that can store or receive software or computer code. When the software or computer code is accessed and executed by a computer, a processor, or hardware, the method shown in the above embodiment is implemented.

[0101] A part of the present invention may be applied as a computer program product, such as a computer program instruction, which, when executed by a computer, can call or provide the method and / or technical solution according to the present invention through the operation of the computer. Those skilled in the art should understand that the existence of the computer program instruction in a computer-readable medium includes, but is not limited to, a source file, an executable file, an installation package file, etc., and accordingly, the way in which the computer program instruction is executed by the computer includes, but is not limited to: the computer directly executes the instruction, or the computer compiles the instruction and then executes the corresponding compiled program, or the computer reads and executes the instruction, or the computer reads and installs the instruction and then executes the corresponding installed program. Here, the computer-readable medium may be any available computer-readable storage medium or communication medium accessible to the computer.

[0102] Although the embodiments of the present invention have been described in conjunction with the accompanying drawings, those skilled in the art may make various modifications and variations without departing from the spirit and scope of the present invention, and such modifications and variations are all within the scope defined by the appended claims.

Claims

1. A microscope image stitching method, characterized in that: The method comprises: Acquire an image to be stitched, where the image to be stitched is an image obtained when a target sample is photographed through a microscope, and the image to be stitched carries the corresponding stage position information when the image is photographed; Inputting the images to be spliced ​​into a pre-built encoder for encoding, and obtaining encoding results corresponding to the images to be spliced ​​one by one; The encoding results and the stage position information corresponding one by one to the images to be stitched are input into a pre-built generator to generate an image stitching result.

2. The method according to claim 1, characterized in that After acquiring the image to be stitched, the method further includes: A light source correction algorithm is used to perform light source correction on the image to be spliced, and the image to be spliced ​​after light source correction is used to input the encoder.

3. The method according to claim 2, characterized in that The adopting a light source correction algorithm to perform light source correction on the images to be stitched includes: Convert the image to be stitched into an HSV format image; Extracting a brightness component based on the HSV format image; Perform multi-scale Gaussian convolution based on the brightness component to obtain an illumination component; The illumination component is corrected using a preset function to obtain the corrected image to be stitched.

4. The method according to claim 3, characterized in that The preset function is: Wherein, O(x, y) is the corrected pixel brightness value, F(x, y) is the pixel brightness value of the image to be stitched, x and y are both pixel coordinates, Wherein, I(x, y) is the illumination component of the image to be stitched, and m is the brightness mean of the illumination component.

5. The method according to claim 1, characterized in that The pre-built encoders include: The self-attention layer, the first residual connection and normalization layer, the feedforward network layer, the second residual connection and normalization layer are connected in sequence.

6. The method according to claim 1, characterized in that The pre-built generators include: The masked self-attention layer, the third residual connection and normalization layer, the decoding self-attention layer, the fourth residual connection and normalization layer, the feedforward network layer, and the fifth residual connection and normalization layer are connected in sequence.

7. A microscope image stitching device, characterized in that: The device comprises: An acquisition module, used for acquiring an image to be stitched, wherein the image to be stitched is an image obtained when a target sample is photographed through a microscope, and the image to be stitched carries the corresponding stage position information when the image is photographed; An encoding module, used for inputting the images to be spliced ​​into a pre-built encoder for encoding, and obtaining encoding results corresponding to the images to be spliced ​​one by one; The generation module is used to input the encoding results and the stage position information of the images to be stitched in one-to-one correspondence into a pre-built generator to generate an image stitching result.

8. A computer device, characterized in that: include: A memory and a processor, wherein the memory and the processor are communicatively connected to each other, the memory stores computer instructions, and the processor executes the microscope image stitching method according to any one of claims 1 to 6 by executing the computer instructions.

9. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer instructions, and the computer instructions are used to enable the computer to execute the microscope image stitching method according to any one of claims 1 to 6.

10. A computer program product, characterized in that The method comprises computer instructions for causing a computer to execute the microscope image stitching method according to any one of claims 1 to 6.

Citation Information

Patent Citations

  • Neural network model based on attention mechanism

    CN114462567A

  • Microscope image intelligent splicing method and device, medium and equipment

    CN114463231A

  • Large-range microscopic imaging image acquisition method and device

    CN114897698A

  • Non-uniform illumination non-linear adaptive correction method based on OTSU

    CN115775212A

  • Microscopic image splicing method based on objective table motion information

    CN116402685A

Cited By

  • Deep learning-based microscopic image seamless splicing and enhanced reconstruction method

    CN121353070A

  • A Deep Learning-Based Seamless Stitching and Enhancement Reconstruction Method for Microscopic Images

    CN121353070B