Pollen slide scanning method based on pollen detection device

By dividing the slide into scanning blocks and adjusting the shooting position, combined with the pollen detection device, the depth coverage and impurity interference problems of pollen detection in the prior art were solved, and a high-definition pollen scanning map was generated, which improved the accuracy of the detection and integrity, providing an important reference for the prevention of pollen allergy.

CN119000676APending Publication Date: 2024-11-22HANGZHOU YIPAI INTELLIGENT TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411143461.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-20
Publication Date
2024-11-22

AI Technical Summary

Technical Problem

The prior art is difficult to capture and focus pollen within a large depth range, and conventional scanning methods cannot fully cover the pollen distribution, and are disturbed by impurities such as dust, affecting detection accuracy.

Method used

By dividing the slide into scanning blocks in M ​​rows and N columns, the adjacent blocks have partial overlap, the camera is moved to adjust to the optimal shooting position, combined with the pollen detection device to detect clarity, gradually adjust the Z-axis position, and splice the scanning blocks. To form a complete image, eliminate impurities, and improve the clarity of pollen detection.

Benefits of technology

It has achieved clear capture of pollen within a large depth range, eliminated impurities, and generated high-definition pollen scanning maps, which has improved the accuracy and completeness of pollen detection, reduced manpower investment, and provided an important reference for preventing pollen allergy.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119000676A_ABST
    Figure CN119000676A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of pathological section analysis, and provides a pollen slide scanning method based on a pollen detection device, which comprises the following steps: shooting a slide global image and delimiting a scanning area frame; moving the camera to align the camera with the target scanning small block in the scanning area; the camera is moved to a reference position z0, and a picture of a target scanning small block is shot at the reference position; calculating the definition of each pollen in the image, and storing the (circumscribed frame, definition score) = (rect, score) of each pollen in a set X; by adjusting the positions of the Z axis in the positive direction and the negative direction respectively, photographing each adjusted position and calculating the definition, and determining an optimal photographing position; synthesizing the photos shot at each adjusted position and the pollen set X into a graph I; and splicing the pictures I of all the scanned small blocks into a complete picture I. The pollen scanning picture obtained by the method can be used for constructing a pollen data set, and plays an important role in pollen teaching and knowledge spreading.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of pathological section analysis, and in particular to a pollen slide scanning method based on a pollen detection device. Background Art

[0002] Pollen pollution can cause pollen allergy, which is the most common and important of allergic reactions and can induce seasonal allergic rhinitis, asthma and dermatitis. The severity of symptoms of pollen allergy patients is correlated with the type and concentration of pollen. Therefore, accurate detection of pollen concentration in the air plays a positive role in the prevention of pollen allergy.

[0003] At present, the pollen in the air is collected by sedimentation or inhalation. After the pollen is collected on the glass slide, it can be scanned into a digital image by a pathology slice scanner, and then the pollen in it can be detected by the popular deep learning method this year. However, for this type of pollen slide, the depth range of the pollen distribution on the slide is large, and conventional single-layer or multi-layer scanning cannot fully cover it. In addition, the pollen is small, and the number varies greatly due to seasonal changes. There are also a lot of impurities such as dust on the slide, which interferes with the scanner's focus.

[0004] Therefore, there is an urgent need to design a scanning method that can eliminate interference such as impurities, capture and focus on pollen within a larger depth range, and merge the clear pollen within the scanning range into one image. Summary of the invention

[0005] In order to achieve the above object, the present invention provides the following technical solutions:

[0006] The present invention provides a pollen slide scanning method based on a pollen detection device, comprising:

[0007] (1) Take a global image of the slide and define a scanning area frame, and divide the defined scanning area into M rows and N columns of scanning blocks, with some overlap between adjacent blocks to ensure normal splicing;

[0008] (2) moving the camera so that it is aimed at the target within the scanning area and scanning a small area;

[0009] (3) Move the camera to the reference position z0.

[0010] (4) Take a picture of a small target scanned area at the reference position, then detect the pollen in the picture through the pollen detection device, and record the z0 position in the list Z;

[0011] (5) Calculate the clarity of each pollen in the image, and save the (bounding box, clarity score) = (rect, score) of each pollen into the set X;

[0012] (6) By adjusting the positive and negative positions of the Z axis respectively, taking photos of each adjusted position and calculating the clarity, the best shooting position is determined;

[0013] (7) Combining the photos taken at each adjusted position and the pollen set X into an image I;

[0014] (8) Repeat steps (2)-(7) to stitch all scanned small blocks of image I into a completed image I 总 .

[0015] The pollen detection device can detect clear and blurred pollen, and can exclude most impurities such as dust. The pollen detection device is provided with a device for driving the camera to move along the X-axis, Y-axis and Z-axis.

[0016] Furthermore, the scanned blocks within the scan area are scanned in an S-shaped order, and the specific scanning order is (1, 1)>(2, 1)>...>(M, 1)>(M, 2)>(M-1, 2)>...(1, 2)>(1, 3)>(2, 3).

[0017] Furthermore, in step (3), the method for determining the reference position z0 is:

[0018] Assuming that the scan block row and column are (m, n), take the scan blocks adjacent to it, and determine whether the adjacent scan blocks have set the best shooting position. If none of them have set the best shooting position, take the global reference position as the reference position, where the global reference position is determined in advance according to the thickness of the glass slide, controller parameters, etc. Under the global reference position, all objects on the glass slide can be roughly photographed, but they cannot be completely focused. If at least one adjacent scan block has set the best shooting position, take the average position of the best shooting position as the reference position.

[0019] Furthermore, in step (5), the calculation steps of the pollen clarity score are:

[0020] The pollen area is cropped out from the image according to the pollen's bounding box, and then the pollen area is converted into a grayscale image to calculate the gradient. The gradients are sorted from small to large, and the 98% gradient value is taken as the clarity of the pollen.

[0021] Furthermore, in step (6), before adjusting the reference position in a positive or negative direction, it is necessary to determine whether adjustment is required, and the determination is based on:

[0022] If the number of pollen in set X is 0, it is directly determined that no adjustment is required;

[0023] If there is pollen in set X, and there is only one z value in the Z list, it is directly determined that adjustment is needed, that is, it is also necessary to determine whether there is clearer pollen above or below;

[0024] Assume that the pollen parameters in X are (rect, score), where rect is the bounding box of the pollen, and score is the clarity score list corresponding to the Z list. If the pollen is not detected at a certain z-axis position, the score is 0;

[0025] Check the sequence number with the largest score and set it as i. When a positive adjustment is made, and i is the last digit and score[i]-score[i-1]>5, it is determined that an adjustment is required. When a negative adjustment is made, and i is the first digit and score[0]-score[1]>5, it is determined that an adjustment is required. In other cases, it is determined that no adjustment is required.

[0026] Furthermore, in step (6), the step of adjusting the reference position in a positive or negative direction is as follows:

[0027] First set the positive or negative adjustment step z step , where the positive adjustment step z step For positive and negative adjustment step z step is negative;

[0028] Then move the base position z to z0+z step At , take a picture, calculate the clarity of each pollen in the picture, and save each pollen's (bounding box, clarity score) = (rect, score) to set Y, then update the pollen parameters in X with the pollen in set Y, and add z to list Z, such as step z step If positive, add it to the right of z0; if step z step If it is negative, add it to the left of z0; repeat the above steps until it is determined that no position adjustment is needed;

[0029] Furthermore, the specific steps of updating the pollen parameters in X with the pollen in set Y are:

[0030] Take pollen from set X and set Y and match them in pairs. Suppose a pollen x in set X = (rect x , score x ), a pollen in Y y=(rect y , score y ), calculate rect x and rect y The IOU between pollen x and all pollens in set Y is calculated. If the maximum IOU is greater than 0.5, pollen x is considered to match pollen y corresponding to the maximum IOU.

[0031] According to whether they match, they are divided into sets X1, X2, Y1, and Y2, where set X1 is the set of pollens that do not match in set X, set X2 is the set of pollens that do match in set X, set Y1 is the set of pollens that do not match in set Y, and set Y2 is the set of pollens that do match in set Y;

[0032] For set X1, suppose that the original pollen x=(rect x , score x ), updated to: x'=(rect x , score x’ ), where rect x unchanged; if step z step is positive, score x’ =[score x , 0], if the step z step is negative, score x’ =[0, score x ];

[0033] For the set X2 and the set Y2, suppose that the original x=(rect x , score x ), y in set Y2 = (rect y , score y ) and pollen x, updated to: x'=(rect x’ , score x’ ), if score y >max(score x ), then rect x’ =rect y , otherwise rect x’ =rect x ; If step z step is positive, score x’ =[score x , score y ], if step z step is negative, score x’ =[score y , score x ];

[0034] For the set Y1, suppose that the original y=(rect y , score y ), update to the set X x'=(rect x , score x ), where rect x =rect y, if step z step is positive, score x =[0, score y ]; if step z step is negative, score x =[score y , 0].

[0035] Furthermore, the step of determining the best shooting position in step (6) is as follows:

[0036] Assume that I1~I n There are n pictures in total, and the corresponding z-axis is z1~z n ;

[0037] Assume that the initial z-axis position is z0, z1~z n z0 should be included in z1~z n The position in is i, that is, z i = z0;

[0038] Suppose pollen x in set X = (rect, score), the pollen in z i The clarity score on z is score[i], and the score of all pollens on z is calculated. i The sum of the clarity scores on i ,

[0039] Calculate all pollen between z1 and z n The sum of the clarity scores on (i-1) ,s (i+1) In addition, to ensure that the background clarity does not jump, the maximum difference between the optimal z-axis and the reference position z0 is limited to ±1 position;

[0040] The z-axis position corresponding to the maximum score is taken as the optimal z-axis.

[0041] Furthermore, the specific steps of synthesizing step (7) into a graph I are as follows:

[0042] Assume that I1~I n There are n pictures in total, and the corresponding Z axis is z1~z n ;

[0043] If n=1, the picture is picture I;

[0044] If n>1, for each pollen x=(rect, score) in the set X, calculate the sequence number with the largest clarity score, set to m, m∈(1,n), and take z m Corresponding picture I m , according to rect, from picture I m The corresponding area of ​​the pollen is intercepted;

[0045] Calculate the best z-axis number j, take z j Corresponding picture I j , as a reference image, paste the small image of each pollen cut out into the I j A clear picture I is spliced ​​at the corresponding position.

[0046] The present invention has the following beneficial effects:

[0047] (1) The present invention divides the global image of the photographed glass slide into scanning blocks of M rows and N columns, adjusts the shooting position for each scanning block multiple times, determines the best shooting position with the highest definition, takes the photo at the best shooting position as the reference picture, then splices all the pollen pictures with the highest definition in the scanning block to the corresponding position of the reference picture, splices a clear picture I, and finally splices all the scanning blocks into a picture I to obtain a pollen scanning picture with high definition and comprehensive data.

[0048] (2) The pollen scan images obtained by the present invention can be used to construct a pollen data set, which plays an important role in the teaching of pollen and the dissemination of knowledge.

[0049] (3) The complete pollen scan image obtained by the present invention can be used to construct a machine learning method, and a fully automatic pollen detection device can be used to automatically and accurately count the types and quantities of pollen, which can reduce the manpower input for pollen counting and provide an important reference for the prevention of pollen allergies. BRIEF DESCRIPTION OF THE DRAWINGS

[0050] Figure 1 It is a flow chart of the scanning method in the present invention.

[0051] Figure 2 This is a picture (a cutout portion) taken by adjusting the positive and negative positions of the Z axis in the present invention.

[0052] Figure 3 It is a picture synthesized by combining the photos taken at each adjustment position and the pollen set X in the present invention. DETAILED DESCRIPTION

[0053] The specific implementation methods of the present invention are described in detail below in conjunction with the accompanying drawings. It should be pointed out that the embodiments are only specific explanations of the invention and should not be regarded as limitations of the invention. The purpose of the embodiments is to enable those skilled in the art to better understand and reproduce the technical solutions of the present invention. The protection scope of the present invention shall still be based on the scope defined by the claims.

[0054] like Figure 1 As shown, the present invention provides a pollen slide scanning method based on a pollen detection device, comprising:

[0055] S1, take a global picture of the glass slide and delineate a scanning area frame, and divide the delineated scanning area into M rows and N columns of scanning blocks. There is partial overlap between adjacent blocks to ensure normal splicing; the scanning blocks in the scanning area are scanned in an S-shaped order, and the specific scanning order is (1, 1)>(2, 1)>...>(M, 1)>(M, 2)>(M-1, 2)>...(1, 2)>(1, 3)>(2, 3).

[0056] S2, move the camera to aim at the target in the scanning area to scan a small block;

[0057] S3, moving the camera to a reference position z0, wherein the reference position z0 is determined as follows:

[0058] Assuming that the scan block row and column are (m, n), take the scan blocks adjacent to it, and determine whether the adjacent scan blocks have set the best shooting position. If none of them have set the best shooting position, take the global reference position as the reference position, where the global reference position is determined in advance according to the thickness of the glass slide, controller parameters, etc. Under the global reference position, all objects on the glass slide can be roughly photographed, but they cannot be completely focused. If at least one adjacent scan block has set the best shooting position, take the average position of the best shooting position as the reference position.

[0059] S4, taking a picture of a small target scan block at the reference position, then detecting the pollen in the picture through a pollen detection device, and recording the z0 position in a list Z;

[0060] S5, calculate the clarity of each pollen in the image, and save the (bounding box, clarity score) = (rect, score) of each pollen into the set X; the calculation steps of the pollen clarity score are:

[0061] The pollen area is cropped out from the image according to the pollen's bounding box, and then the pollen area is converted into a grayscale image to calculate the gradient. The gradients are sorted from small to large, and the 98% gradient value is taken as the clarity of the pollen.

[0062] S6, by adjusting the positive and negative positions of the Z axis respectively, taking photos at each adjusted position and calculating the clarity, and determining the best shooting position; the photos (part) taken at different Z axes are as follows Figure 2 As shown, before adjusting the reference position in a positive or negative direction, it is necessary to determine whether adjustment is required. The judgment basis is:

[0063] If the number of pollen in set X is 0, it is directly determined that no adjustment is required;

[0064] If there is pollen in set X, and there is only one z value in the Z list, it is directly determined that adjustment is needed, that is, it is also necessary to determine whether there is clearer pollen above or below;

[0065] Assume that the pollen parameters in X are (rect, score), where rect is the bounding box of the pollen, and score is the clarity score list corresponding to the Z list. If the pollen is not detected at a certain z-axis position, the score is 0;

[0066] Check the sequence number with the largest score and set it as i. When a positive adjustment is made, and i is the last digit and score[i]-score[i-1]>5, it is determined that an adjustment is required. When a negative adjustment is made, and i is the first digit and score[0]-score[1]>5, it is determined that an adjustment is required. In other cases, it is determined that no adjustment is required.

[0067] The steps for adjusting the reference position in a positive or negative direction are:

[0068] First set the positive or negative adjustment step z step , where the positive adjustment step z step For positive and negative adjustment step z step is negative;

[0069] Then move the base position z to z0+z step At , take a picture, calculate the clarity of each pollen in the picture, and save each pollen's (bounding box, clarity score) = (rect, score) to set Y, then update the pollen parameters in X with the pollen in set Y, and add z to list Z, such as step z step If positive, add it to the right of z0; if step z step If it is negative, add it to the left of z0; repeat the above steps until it is determined that no position adjustment is needed;

[0070] The specific steps to update the pollen parameters in X with the pollen of set Y are:

[0071] Take pollen from set X and set Y and match them in pairs. Suppose a pollen x in set X = (rect x , score x ), a pollen in Y y=(rect y , score y ), calculate rect x and rect yThe IOU between pollen x and all pollens in set Y is calculated. If the maximum IOU is greater than 0.5, pollen x is considered to match pollen y corresponding to the maximum IOU. Based on whether they match, they are divided into sets X1, X2, Y1, and Y2, where set X1 is the set of pollens that have no match in set X, set X2 is the set of pollens that have a match in set X, set Y1 is the set of pollens that have no match in set Y, and set Y2 is the set of pollens that have a match in set Y.

[0072] For set X1, suppose that the original pollen x=(rect x , score x ), updated to: x'=(rect x , score x’ ), where rect x unchanged; if step z step is positive, score x’ =[score x , 0], if the step z step is negative, score x’ =[0, score x ];

[0073] For the set X2 and the set Y2, suppose that the original x=(rect x , score x ), y in set Y2 = (rect y , score y ) and pollen x, updated to: x'=(rect x’ , score x’ ), if score y >max(score x ), then rect x’ =rect y , otherwise rect x’ =rect x ; If step z step is positive, score x’ =[score x , score y ], if step z step is negative, score x’ =[score y , score x ];

[0074] For the set Y1, suppose that the original y=(rect y , score y ), update to the set X x'=(rect x, score x ), where rect x =rect y , if step z step is positive, score x =[0, score y ]; if step z step is negative, score x =[score y , 0].

[0075] The steps to determine the best shooting position are:

[0076] Assume that I1~I n There are n pictures in total, and the corresponding z-axis is z1~z n ;

[0077] Assume that the initial z-axis position is z0, z1~z n z0 should be included in z1~z n The position in is i, that is, z i = z0;

[0078] Suppose pollen x in set X = (rect, score), the pollen in z i The clarity score on z is score[i], and the score of all pollens on z is calculated. i The sum of the clarity scores on i ,

[0079] Calculate all pollen between z1 and z n The sum of the clarity scores on (i-1) ,s (i+1) In addition, to ensure that the background clarity does not jump, the maximum difference between the optimal z-axis and the reference position z0 is limited to ±1 position;

[0080] The z-axis position corresponding to the maximum score is taken as the optimal z-axis.

[0081] S7, combining the photos taken at each adjusted position and the pollen set X into an image I, such as Figure 3 As shown;

[0082] The specific steps of synthesizing into a picture I are:

[0083] Assume that I1~I n There are n pictures in total, and the corresponding Z axis is z1~z n ;

[0084] If n=1, the picture is picture I;

[0085] If n>1, for each pollen x=(rect, score) in the set X, calculate the sequence number with the largest clarity score, set to m, m∈(1,n), and take z m Corresponding picture I m , according to rect, from picture I m The corresponding area of ​​the pollen is intercepted;

[0086] Calculate the best z-axis number j, take z j Corresponding picture I j , as a reference image, paste the small image of each pollen cut out into the I j A clear picture I is spliced ​​at the corresponding position.

[0087] S8, repeat steps S2-S7 to stitch all scanned small blocks of image I into a completed image I 总 , which is the final pollen scan.

[0088] The pollen detection device can automatically detect clear and blurred pollen, and can exclude most impurities such as dust. The pollen detection device is provided with a device for driving the camera to move along the X-axis, Y-axis and Z-axis. The pollen detection device can be purchased from the market.

[0089] Although the preferred embodiments of the present application have been described, those skilled in the art may make additional changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications falling within the scope of the present application.

[0090] It should be noted that the technical features not described in detail in the present invention can be implemented by any existing technology.

Claims

1. A pollen slide scanning method based on a pollen detection device, characterized in that: include: (1) Taking a global image of the slide and demarcating a scanning area frame, and dividing the demarcated scanning area into scanning blocks of M rows and N columns, with some overlap between adjacent blocks; (2) moving the camera so that it is aimed at the target within the scanning area and scanning a small area; (3) Move the camera to the reference position z0. (4) Take a picture of a small target scanned area at the reference position, then detect the pollen in the picture through the pollen detection device, and record the z0 position in the list Z; (5) Calculate the clarity of each pollen in the image, and save each pollen's (bounding box, clarity score = (rect, score) into the set X; (6) By adjusting the positive and negative positions of the Z axis respectively, taking photos of each adjusted position and calculating the clarity, the best shooting position is determined; (7) Combining the photos taken at each adjusted position and the pollen set X into an image I; (8) Repeat steps (2)-(7) to stitch all scanned small blocks of image I into a completed image I 总 .

2. A pollen slide scanning method based on a pollen detection device according to claim 1, characterized in that: The scan blocks within the scan area are scanned in an S-shaped sequence.

3. A pollen slide scanning method based on a pollen detection device according to claim 1, characterized in that: In step (3), the method for determining the reference position z0 is: Assume that the rows and columns of the scan blocks are (m, n), take the scan blocks adjacent to each other above, below, left and right, and determine whether the adjacent scan blocks have set the best shooting position. If none of them have set the best shooting position, take the global reference position as the reference position. If at least one adjacent scan block has set the best shooting position, take the average position of the set best shooting position as the reference position.

4. A pollen slide scanning method based on a pollen detection device according to claim 1, characterized in that: In step (5), the calculation steps of the pollen clarity score are as follows: The pollen area is cropped out from the image according to the pollen's bounding box, and then the pollen area is converted into a grayscale image to calculate the gradient. The gradients are sorted from small to large, and the 98% gradient value is taken as the clarity of the pollen.

5. A pollen slide scanning method based on a pollen detection device according to claim 1, characterized in that: In step (6), before adjusting the reference position in a positive or negative direction, it is necessary to determine whether adjustment is required. The determination is based on: If the number of pollen in set X is 0, it is directly determined that no adjustment is required; If there is pollen in set X, and there is only one z value in the Z list, it is directly determined that adjustment is needed; Assume that the pollen parameters in X are (rect, score), where rect is the bounding box of the pollen, and score is the clarity score list corresponding to the Z list. If the pollen is not detected at a certain z-axis position, the score is 0; Check the sequence number with the largest score and set it as i. When a positive adjustment is made, and i is the last digit and score[i]-score[i-1]>5, it is determined that an adjustment is required. When a negative adjustment is made, and i is the first digit and score[0]-score[1]>5, it is determined that an adjustment is required. In other cases, it is determined that no adjustment is required.

6. A pollen slide scanning method based on a pollen detection device according to claim 1, characterized in that: In step (6), the steps of adjusting the reference position in a positive or negative direction are as follows: First set the positive or negative adjustment step z step , where the positive adjustment step z step For positive and negative adjustment step z step is negative; Then move the base position z0 to z0+z step At , take a picture, calculate the clarity of each pollen in the picture, and save each pollen's (bounding box, clarity score) = (rect, score) to set Y, then update the pollen parameters in X with the pollen in set Y, and add z to list Z, such as step z step is positive, then add it to the right of z0, such as stepping z step If it is negative, add it to the left of z0; repeat the above steps until it is determined that no position adjustment is needed.

7. A pollen slide scanning method based on a pollen detection device according to claim 6, characterized in that: The specific steps to update the pollen parameters in X with the pollen of set Y are: Take pollen from set X and set Y and match them in pairs. Suppose a pollen x in set X = (rect x , score x ), a pollen in Y y=(rect y , score y ), calculate rect x and rect y The IOU between pollen x and all pollens in set Y is calculated. If the maximum IOU is greater than 0.5, pollen x is considered to match pollen y corresponding to the maximum IOU. According to whether they match, they are divided into sets X1, X2, Y1, and Y2, where set X1 is the set of pollens that do not match in set X, set X2 is the set of pollens that do match in set X, set Y1 is the set of pollens that do not match in set Y, and set Y2 is the set of pollens that do match in set Y; For set X1, suppose that the original pollen x=(rect x , score x ), updated to: x'=(rect x , score x’ ), where rect x unchanged; if step z step is positive, score x’ =[score x , 0], if the step z step is negative, score x’ =[0, score x ]; For the set X2 and the set Y2, suppose that the original x=(rect x , score x ), y in set Y2 = (rect y , score y ) and pollen x, updated to: x'=(rect x’ , score x’ ), if score y >max(score x ), then rect x’ =rect y , otherwise rect x’ =rect x ; If step z step is positive, score x’ =[score x , score y ], if step z step is negative, score x’ =[score y , score x ]; For the set Y1, suppose that the original y=(rect y , score y ), update to the set X x' = (rect x , score x ), where rect x =rect y , if step z step is positive, score x =[0, score y ]; if step z step is negative, score x =[score y , 0].

8. The pollen slide scanning method based on the pollen detection device according to claim 1, characterized in that: The steps for determining the best shooting position in step (6) are: Assume that I1~I n There are n pictures in total, and the corresponding z-axis is z1~z n ; Assume that the initial z-axis position is z0, z1~z n z0 should be included in z1~z n The position in is i, that is, z i = z0; Suppose pollen x in set X = (rect, score), the pollen in z i The clarity score on z is score[i], and the score of all pollens on z is calculated. i The sum of the clarity scores on i , Calculate all pollen between z1 and z n The sum of the clarity scores on (i-1) ,s (i+1) In addition, to ensure that the background clarity does not jump, the maximum difference between the optimal z-axis and the reference position z0 is limited to ±1 position; The z-axis position corresponding to the maximum score is taken as the optimal z-axis.

9. The pollen slide scanning method based on the pollen detection device according to claim 1, characterized in that: The specific steps of synthesizing step (7) into a graph I are as follows: Assume that I1~I n There are n pictures in total, and the corresponding Z axis is z1~z n ; If n=1, the picture is picture I; If n>1, for each pollen x=(rect, score) in the set X, calculate the sequence number with the largest clarity score, set to m, m∈(1,n), and take z m Corresponding image I m , according to the external frame, from the picture I m The corresponding area of ​​the pollen is intercepted; Calculate the best z-axis number j, take z j Corresponding image I j , as the reference image, and then paste the small image of each pollen cutout into the I j A clear picture I is spliced ​​at the corresponding position.