Skeleton extraction method based on particle swarm optimization and applied to micro-fluidic chip

Through the method based on particle swarm algorithm, preprocessing and edge detection of rock cast sheet images is realized, precise extraction of rock skeletons is solved, and the problem of extracting matrix regions in the existing technology is solved, providing a foundation for the production of microfluidic chips.

CN119963557AActive Publication Date: 2025-05-09SANYA MARINE OIL & GAS RESEARCH INSTITUTE NORTHEAST PETROLEUM UNIVERSITY
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
CN202510449904.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-11
Publication Date
2025-05-09
Estimated Expiration
2045-04-11

AI Technical Summary

Technical Problem

The prior art is difficult to extract the matrix area in the cast sheet easily, affecting the production of microfluidic chips and the effective use of residual oil.

Method used

The particle swarm algorithm is used to pre-process the two-dimensional rock cast sheet image. The threshold segmentation of the particle swarm algorithm and Canny edge detection are combined with morphological processing to achieve accurate extraction of the rock skeleton.

Benefits of technology

The precise extraction of the skeleton part in the cast sheet is achieved, providing a basis for the subsequent production of microfluidic chips, and helping to study the storage and mobilization status of residual oil.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119963557A_ABST
    Figure CN119963557A_ABST
Patent Text Reader

Abstract

The invention discloses a skeleton extraction method applied to a micro-fluidic chip based on a particle swarm algorithm, and the method comprises the following steps: S1, inputting a two-dimensional rock casting body slice image, and carrying out the preprocessing of the two-dimensional rock casting body slice image; s2, performing preliminary extraction on a rock skeleton region through threshold segmentation of a particle swarm algorithm; s3, correcting a skeleton edge through Canny edge detection of a particle swarm algorithm; and S4, performing morphological processing on smooth and continuous edges to complete skeleton extraction of the rock casting body slice. The method has the beneficial effects that the two-dimensional rock casting body slice image is preprocessed, parameters in threshold segmentation-Canny edge detection are optimized by using the particle swarm algorithm, and a result is subjected to weighted output, so that accurate extraction of a skeleton part in a casting body slice is realized, and a basis is provided for subsequent manufacturing of a micro-fluidic chip.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to the technical field of oil and gas field development, in particular to a skeleton extraction method applied to a microfluidic chip based on a particle swarm algorithm. Background Art

[0002] At present, the problem of the storage state and effective utilization of residual oil has become the focus of the current petroleum field. Experimental research has gradually shifted from the study of macroscopic model laws to the study of microscopic model mechanisms. It has become a conventional method to study the storage and utilization state of residual oil through microfluidic oil recovery experiments. Among them, how to easily extract the matrix area in the cast thin slice and make a microfluidic chip is one of the hot issues.

[0003] At present, most of the onshore oil fields have entered the late stage of high water content. It is the current primary task to clarify the occurrence state of the remaining oil in the reservoir rock skeleton and determine the new development plan for effective utilization. The changing law of the remaining oil should be further studied from a microscopic perspective. Microfluidic oil displacement experiment is an effective means of research. Therefore, it is particularly important to be able to easily and accurately extract the rock matrix area in the cast thin section. The extraction results will provide a basis for the subsequent production of microfluidic chips. Summary of the invention

[0004] The purpose of the present invention is to overcome the shortcomings of the prior art and provide a skeleton extraction method for a microfluidic chip based on a particle swarm algorithm.

[0005] The purpose of the present invention is achieved by the following technical solution: A skeleton extraction method based on particle swarm algorithm applied to microfluidic chip, comprising the following steps:

[0006] S1: Input 2D rock casting thin section image and preprocess it;

[0007] S2: Preliminary extraction of rock skeleton area through threshold segmentation of particle swarm algorithm;

[0008] S3: Modify the skeleton edge through Canny edge detection of particle swarm algorithm;

[0009] S4: Perform morphological processing to smooth and continuous edges and complete the skeleton extraction of rock cast thin sections.

[0010] Preferably, step S1 further includes the following steps:

[0011] S11: Perform empirical correction on the R, G, and B coefficients in the gray value formula;

[0012] S12: The color rock casting thin slice composed of the existing R, G, B three-channel information is converted into single gray channel information through weighted average grayscale processing.

[0013] .

[0014] Preferably, step S2 further includes the following steps:

[0015] S21: Randomly generate a large particle group in the entire image area, which contains Particles,

[0016] In the initial state, the current position of each particle is the individual optimal position ,in For the Particles in The current optimal position in the dimensional space, For the Particles in The position in the dimensional space;

[0017] In the initial state, the position of the first particle is the global optimal position ,in For the entire particle group The optimal position to find in dimensional space;

[0018] S22: Calculate the fitness of each particle based on its position ,

[0019] ;

[0020] in, is the average gray value of the target pixel, is the average gray value of background pixels, is the average gray value of the image to be processed, is the ratio of target pixels to total pixels, is the ratio of background pixels to total pixels, is the between-class standard deviation;

[0021] S23: Compare the fitness value of the current position with the individual's historical optimal fitness value. If the fitness value of the current position is higher than the individual's historical optimal fitness value, update the individual's optimal fitness value.

[0022] ;

[0023] If the current position fitness value is lower than the individual's historical optimal fitness value, continue searching;

[0024] S24: Compare the individual optimal fitness values ​​of each particle in the particle group to obtain the optimal position fitness value. If it is higher than the historical optimal fitness value of the group, update , otherwise continue searching;

[0025] S25: Update the speed and position of individual particles. The speed update formula is:

[0026] ;

[0027] in, For the Particles in The speed in the dimensional space, , is the inertia weight, is the number of iterations, The self-perception factor, is the social impact factor, is the individual random factor, is the population random factor, and For A random number between

[0028] The position update formula is:

[0029] ;

[0030] Location throughout In which is the total magnitude of gray levels of the input image;

[0031] S26: If the maximum number of iterations is reached Or if the global optimal position fitness value is less than the set threshold, the termination condition is met, the iteration is stopped and the result is output, otherwise, the process returns to step S22 to continue searching for the optimal solution;

[0032] S27: Using the output optimal threshold as the threshold segmentation setting value to complete the preliminary separation of the skeleton area of ​​the casting thin slice.

[0033] Preferably, step S3 further includes the following steps:

[0034] S31: Randomly generate a large particle group in the entire image area, which contains Particles,

[0035] In the initial state, the current position of each particle is the individual optimal position ,in For the Particles in The current optimal position in the dimensional space, For the Particles in The position in the dimensional space;

[0036] In the initial state, the position of the first particle is the global optimal position ,in For the entire particle group The optimal position to find in dimensional space;

[0037] S32: Calculate edge density, continuity and edge strength according to the position of each particle to obtain fitness;

[0038] S33: Compare the fitness value of the current position with the individual's historical optimal fitness value. If the fitness value of the current position is higher than the individual's historical optimal fitness value, update the individual's optimal fitness value.

[0039] ;

[0040] If the current position fitness value is lower than the individual's historical optimal fitness value, continue searching;

[0041] S34: Compare the individual optimal fitness values ​​of each particle in the particle group to obtain the optimal position fitness value. If it is higher than the historical optimal fitness value of the group, update , otherwise continue searching;

[0042] S35: Update the speed and position of individual particles. The speed update formula is:

[0043] ;

[0044] in, For the Particles in The speed in the dimensional space, , is the inertia weight, is the number of iterations, The self-perception factor, is the social impact factor, is the individual random factor, is the population random factor, and For A random number between

[0045] The position update formula is:

[0046] ;

[0047] Location throughout In which is the total magnitude of gray levels of the input image;

[0048] S36: If the maximum number of iterations is reached Or if the global optimal position fitness value is less than the set threshold, the termination condition is met, the iteration is stopped and the result is output, otherwise, the process returns to step S22 to continue searching for the optimal solution;

[0049] S37: Using the output optimal parameter combination as a setting value for Canny edge detection to complete edge detection of the casting thin slice skeleton region;

[0050] S38: Image result after threshold segmentation Results after Canny edge detection Perform weighted fusion.

[0051] ;

[0052] in, is the fused image, is the weight coefficient, .

[0053] Preferably, in step S32, the formula for calculating edge density is:

[0054] ;

[0055] The formula for calculating continuity is:

[0056] ;

[0057] The formula for calculating edge strength is:

[0058] ;

[0059] The fitness calculation formula is:

[0060] .

[0061] Preferably, in step S4, the image result after threshold segmentation and edge detection is combined with the output to perform an opening operation in morphology, and the input image is first eroded and then expanded.

[0062] Preferably, in step S4,

[0063] Open operation processing:

[0064] ;

[0065] Corrosion treatment:

[0066] ;

[0067] Expansion treatment:

[0068] ;

[0069] in, is the image to be processed, is the structural element, Translated for structural elements After the position, for After reflection, the two positions are symmetrical about the origin.

[0070] The present invention has the following advantages: the present invention pre-processes the two-dimensional rock casting thin section image, then uses the particle swarm algorithm to optimize the parameters in the threshold segmentation-Canny edge detection, and outputs the result in a weighted manner, thereby realizing the accurate extraction of the skeleton part in the casting thin section, and providing a basis for the subsequent production of a microfluidic chip. BRIEF DESCRIPTION OF THE DRAWINGS

[0071] Figure 1 This is a schematic diagram of the rock skeleton extraction process;

[0072] Figure 2 It is a schematic diagram of the iterative process of particle swarm No. 1 in the threshold segmentation part;

[0073] Figure 3 It is a schematic diagram of the iterative process of particle swarm No. 10 in the threshold segmentation part;

[0074] Figure 4 It is a schematic diagram of the iterative process of particle swarm No. 20 in the threshold segmentation part;

[0075] Figure 5 It is a schematic diagram of the iterative process of particle swarm No. 30 in the threshold segmentation part;

[0076] Figure 6 It is a schematic diagram of the iterative process of particle swarm No. 45 in the threshold segmentation part;

[0077] Figure 7 It is a schematic diagram of the extracted image after threshold segmentation based on the particle swarm algorithm;

[0078] Figure 8 A schematic diagram of an extracted image after edge detection based on a particle swarm algorithm;

[0079] Fig. 9 It is a schematic diagram of the fusion of the threshold segmentation image and the edge detection image;

[0080] Fig.10 Schematic diagram of the final image after morphological processing. DETAILED DESCRIPTION

[0081] In order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions 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. Generally, the components of the embodiments of the present invention described and shown in the drawings here can be arranged and designed in various different configurations.

[0082] Therefore, the following detailed description of the embodiments of the present invention provided in the accompanying drawings is not intended to limit the scope of the invention claimed for protection, but merely represents selected embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0083] It should be noted that, in the absence of conflict, the embodiments of the present invention and the features of the embodiments may be combined with each other.

[0084] 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, further definition and explanation thereof is not required in subsequent drawings.

[0085] In the description of the present invention, it should be noted that the terms "center", "upper", "lower", "left", "right", "vertical", "horizontal", "inside", "outside", etc. indicate positions or positional relationships based on the positions or positional relationships shown in the accompanying drawings, or the positions or positional relationships in which the product of the invention is usually placed when in use, or the positions or positional relationships commonly understood by those skilled in the art, which are only for the convenience of describing the present invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore cannot be understood as limiting the present invention. In addition, the terms "first", "second", etc. are only used to distinguish the description, and cannot be understood as indicating or implying relative importance.

[0086] In the description of the present invention, it is also necessary to explain that, unless otherwise clearly specified and limited, the terms "set", "install", "connect", and "connect" should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection, or it can be indirectly connected through an intermediate medium, or it can be the internal communication of two elements. For ordinary technicians in this field, the specific meanings of the above terms in the present invention can be understood according to specific circumstances.

[0087] like Figure 1 As shown, a skeleton extraction method based on particle swarm algorithm applied to microfluidic chip includes the following steps:

[0088] S1: Input 2D rock casting thin section image and preprocess it;

[0089] S2: Preliminary extraction of rock skeleton area through threshold segmentation of particle swarm algorithm; specifically, taking threshold variable as potential solution, the direction and position of threshold particles are updated iteratively to seek the optimal solution in the whole space and find the best segmentation threshold;

[0090] S3: Modify the skeleton edge through Canny edge detection of particle swarm algorithm;

[0091] S4: Perform morphological processing to smooth and continuous edges, and complete the skeleton extraction of rock casting thin sections. By preprocessing the two-dimensional rock casting thin section image, the particle swarm algorithm is used to optimize the parameters in the threshold segmentation-Canny edge detection, and the results are weighted and output, so as to achieve accurate extraction of the skeleton part in the casting thin section, providing a basis for the subsequent production of microfluidic chips.

[0092] Furthermore, step S1 further includes the following steps:

[0093] S11: Perform empirical correction on the R, G, and B coefficients in the gray value formula;

[0094] S12: The color rock casting thin slice composed of the existing R, G, B three-channel information is converted into single gray channel information through weighted average grayscale processing.

[0095] .

[0096] Specifically, since the production of cast thin slices usually requires injecting blue liquid glue into the pores and then grinding, the pore space is mostly blue, so the weight of B in the gray value formula is appropriately reduced.

[0097] Further, if Figure 2~Figure 6 As shown, the iterative particles randomly selected from the particle swarm are particles No. 1, 10, 20, 30, and 45. Step S2 also includes the following steps:

[0098] S21: Randomly generate a large particle group in the entire image area, which contains Particles,

[0099] In the initial state, the current position of each particle is the individual optimal position ,in For the Particles in The current optimal position in the dimensional space, For the Particles in The position in the dimensional space;

[0100] In the initial state, the position of the first particle is the global optimal position ,in For the entire particle group The optimal position found in the dimensional space is absolute and unique. Specifically, since the uncertainty required in threshold segmentation is the threshold variable, , where the particle position , is the total magnitude of the grayscale levels of the input image.

[0101] S22: Calculate the fitness of each particle based on its position , the larger the fitness function value is, the better the image segmentation effect is.

[0102] ;

[0103] in, is the average gray value of the target pixel, is the average gray value of background pixels, is the average gray value of the image to be processed, is the ratio of target pixels to total pixels, is the ratio of background pixels to total pixels, is the between-class standard deviation;

[0104] S23: Compare the fitness value of the current position with the individual's historical optimal fitness value. If the fitness value of the current position is higher than the individual's historical optimal fitness value, update the individual's optimal fitness value.

[0105] ;

[0106] If the current position fitness value is lower than the individual's historical optimal fitness value, continue searching;

[0107] S24: Compare the individual optimal fitness values ​​of each particle in the particle group to obtain the optimal position fitness value. If it is higher than the historical optimal fitness value of the group, update , otherwise continue searching;

[0108] S25: Update the speed and position of individual particles. The speed update formula is:

[0109] ;

[0110] in, For the Particles in The speed in the dimensional space is between the given maximum and minimum particle speeds, that is, , is the inertia weight, is the number of iterations, The self-perception factor, is the social impact factor, is the individual random factor, is the population random factor, and For A random number between

[0111] The position update formula is:

[0112] ;

[0113] Location throughout In which is the total magnitude of the grayscale level of the input image; specifically, the particle velocity value is expanded at the beginning of the iteration to ensure the rapidity of particle browsing in the entire space. As the iteration proceeds, the closer to the optimal solution area, the smaller the velocity span is, thereby ensuring the accuracy of the search result. This process applies an exponential function To prevent particles from stagnating, set a minimum threshold ,when near When the particle is in the optimal state, the current speed is maintained and the search continues, thereby increasing the search speed and accuracy of each particle and reducing the situation where the particle falls into the local optimum.

[0114] S26: If the maximum number of iterations is reached Or if the global optimal position fitness value is less than the set threshold, the termination condition is met, the iteration is stopped and the result is output, otherwise, the process returns to step S22 to continue searching for the optimal solution;

[0115] S27: Using the output optimal threshold as the threshold segmentation setting value to complete the preliminary separation of the skeleton area of ​​the casting thin slice, such as Figure 7 As shown in the figure, the optimal threshold iteration result is 0.54. Specifically, a large particle group is randomly generated in the entire image area, containing 50 particles, and the speed of each particle is Restricted to , set the maximum number of iterations is 100, is 1.6, is 1.6, the inertia weight coefficient , the iteration threshold range is between.

[0116] In this embodiment, step S3 further includes the following steps:

[0117] S31: Randomly generate a large particle group in the entire image area, which contains Particles,

[0118] In the initial state, the current position of each particle is the individual optimal position ,in For the Particles in The current optimal position in the dimensional space, For the Particles in The position in the dimensional space;

[0119] In the initial state, the position of the first particle is the global optimal position ,in For the entire particle group dimensional space; specifically, two particle types are selected for iteration for Canny edge detection: high threshold With low threshold , so =2.

[0120] S32: Calculate edge density, continuity and edge strength according to the position of each particle to obtain fitness; specifically, a larger fitness value produces a higher edge contrast.

[0121] S33: Compare the fitness value of the current position with the individual's historical optimal fitness value. If the fitness value of the current position is higher than the individual's historical optimal fitness value, update the individual's optimal fitness value.

[0122] ;

[0123] If the current position fitness value is lower than the individual's historical optimal fitness value, continue searching;

[0124] S34: Compare the individual optimal fitness values ​​of each particle in the particle group to obtain the optimal position fitness value. If it is higher than the historical optimal fitness value of the group, update , otherwise continue searching;

[0125] S35: Update the speed and position of individual particles. The speed update formula is:

[0126] ;

[0127] in, For the Particles in The speed in the dimensional space is between the given maximum and minimum particle speeds, that is, , is the inertia weight, is the number of iterations, The self-perception factor, is the social impact factor, is the individual random factor, is the population random factor, and For A random number between

[0128] The position update formula is:

[0129] ;

[0130] Location throughout In which is the total magnitude of gray levels of the input image;

[0131] S36: If the maximum number of iterations is reached Or if the global optimal position fitness value is less than the set threshold, the termination condition is met, the iteration is stopped and the result is output, otherwise, the process returns to step S22 to continue searching for the optimal solution;

[0132] S37: The output optimal parameter combination is used as the setting value of Canny edge detection to complete the edge detection of the casting thin slice skeleton area, such as Figure 8 As shown;

[0133] S38: Image result after threshold segmentation Results after Canny edge detection Perform weighted fusion.

[0134] ;

[0135] in, is the fused image, is the weight coefficient, ,like Fig. 9 As shown, Specifically, a large particle group containing 50 particles is randomly generated in the entire image area, and the speed of each particle is Restricted to , set the maximum number of iterations is 100, is 1.6, is 1.6, the inertia weight coefficient , high threshold , low threshold .

[0136] Furthermore, in step S32, the formula for calculating edge density is:

[0137] ;

[0138] The formula for calculating continuity is:

[0139] ;

[0140] The formula for calculating edge strength is:

[0141] ;

[0142] The fitness calculation formula is:

[0143] .

[0144] In this embodiment, if Fig.10 As shown, in step S4, the image result after threshold segmentation and edge detection is combined with the output to perform morphological opening operation processing, and the input image is first corroded and then expanded. Specifically, the input image is first corroded to remove protruding pixels, and then expanded to enhance the continuity and smoothness of the image. While keeping the large skeleton in the image basically unchanged, the isolated small pixels in the output image are removed, further improving the quality and coherence of the output image. Further, in step S4,

[0145] Open operation processing:

[0146] ;

[0147] Corrosion treatment:

[0148] ;

[0149] Expansion treatment:

[0150] ;

[0151] in is the image to be processed, is the structural element, Translated for structural elements After the position, for After reflection, the two positions are symmetrical about the origin.

[0152] Although the present invention has been described in detail with reference to the aforementioned embodiments, it is still possible for those skilled in the art to modify the technical solutions described in the aforementioned embodiments, or to make equivalent substitutions for some of the technical features therein. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the protection scope of the present invention.

Claims

1. A skeleton extraction method based on particle swarm algorithm applied to microfluidic chip, characterized in that: The following steps are involved: S1: Input 2D rock casting thin section image and preprocess it; S2: Preliminary extraction of rock skeleton area through threshold segmentation of particle swarm algorithm; S3: Modify the skeleton edge through Canny edge detection of particle swarm algorithm; S4: Perform morphological processing to smooth and continuous edges and complete skeleton extraction of rock cast thin sections; The step S2 further includes the following steps: S21: Randomly generate a large particle group in the entire image area, which contains Particles; S22: Calculate the fitness of each particle based on its position , is the evaluation function; S23: Compare the fitness value of the current position with the individual's historical optimal fitness value. If the fitness value of the current position is higher than the individual's historical optimal fitness value, update the individual's optimal fitness value. ; in, For the Particles in The current optimal position in the dimensional space, For the Particles in The position in the dimensional space; If the current position fitness value is lower than the individual's historical optimal fitness value, continue searching; S24: Compare the individual optimal fitness values ​​of each particle in the particle group to obtain the optimal position fitness value. If it is higher than the historical optimal fitness value of the group, update , For the entire particle group The optimal position to find in the dimensional space, otherwise continue searching; S25: Update the speed and position of individual particles; S26: If the maximum number of iterations is reached Or if the global optimal position fitness value is less than the set threshold, the termination condition is met, the iteration is stopped and the result is output, otherwise, the process returns to step S22 to continue searching for the optimal solution; S27: Using the output optimal threshold as the threshold segmentation setting value to complete the preliminary separation of the skeleton area of ​​the casting thin slice.

2. The skeleton extraction method based on particle swarm algorithm applied to microfluidic chip according to claim 1, characterized in that: The step S1 further includes the following steps: S11: Perform empirical correction on the R, G, and B coefficients in the gray value formula; S12: The color rock casting thin slice composed of the existing R, G, B three-channel information is converted into single gray channel information through weighted average grayscale processing. 。 3. The skeleton extraction method based on particle swarm algorithm applied to microfluidic chip according to claim 2, characterized in that: In step S21, the current position of each particle is the individual optimal position in the initial state. ,in For the Particles in The current optimal position in the dimensional space, For the Particles in The position in the dimensional space; In the initial state, the position of the first particle is the global optimal position ,in For the entire particle group The optimal position to find in dimensional space; In step S22, the fitness is calculated The formula is: ; in, is the average gray value of the target pixel, is the average gray value of background pixels, is the average gray value of the image to be processed, is the ratio of target pixels to total pixels, is the ratio of background pixels to total pixels, is the between-class standard deviation; In step S25, the speed update formula is: ; in, For the Particles in The speed in the dimensional space, , is the inertia weight, is the number of iterations, The self-perception factor, is the social impact factor, is the individual random factor, is the population random factor, and For A random number between The position update formula is: ; Location throughout In which is the total magnitude of the grayscale levels of the input image.

4. The skeleton extraction method based on particle swarm algorithm applied to microfluidic chip according to claim 3 is characterized in that: The step S3 further includes the following steps: S31: Randomly generate a large particle group in the entire image area, which contains Particles, In the initial state, the current position of each particle is the individual optimal position ,in For the Particles in The current optimal position in the dimensional space, For the Particles in The position in the dimensional space; In the initial state, the position of the first particle is the global optimal position ,in For the entire particle group The optimal position to find in dimensional space; S32: Calculate edge density, continuity and edge strength according to the position of each particle to obtain fitness; S33: Compare the fitness value of the current position with the individual's historical optimal fitness value. If the fitness value of the current position is higher than the individual's historical optimal fitness value, update the individual's optimal fitness value. ; If the current position fitness value is lower than the individual's historical optimal fitness value, continue searching; S34: Compare the individual optimal fitness values ​​of each particle in the particle group to obtain the optimal position fitness value. If it is higher than the historical optimal fitness value of the group, update , otherwise continue searching; S35: Update the speed and position of individual particles. The speed update formula is: ; in, For the Particles in The speed in the dimensional space, , is the inertia weight, is the number of iterations, The self-perception factor, is the social impact factor, is the individual random factor, is the population random factor, and For A random number between The position update formula is: ; Location throughout In which is the total magnitude of gray levels of the input image; S36: If the maximum number of iterations is reached Or if the global optimal position fitness value is less than the set threshold, the termination condition is met, the iteration is stopped and the result is output, otherwise, the process returns to step S22 to continue searching for the optimal solution; S37: Using the output optimal parameter combination as a setting value for Canny edge detection to complete edge detection of the casting thin slice skeleton region; S38: Image result after threshold segmentation Results after Canny edge detection Perform weighted fusion. ; in, is the fused image, is the weight coefficient, .

5. The skeleton extraction method based on particle swarm algorithm applied to microfluidic chip according to claim 4 is characterized in that: In step S32, the formula for calculating edge density is: ; The formula for calculating continuity is: ; The formula for calculating edge strength is: ; The fitness calculation formula is: 。 6. The skeleton extraction method based on particle swarm algorithm applied to microfluidic chip according to claim 5, characterized in that: In step S4, the image result after threshold segmentation and edge detection is combined with the output to perform an opening operation in morphology, and the input image is first eroded and then expanded.

7. The skeleton extraction method based on particle swarm algorithm applied to microfluidic chip according to claim 6, characterized in that: In the step S4, Open operation processing: ; Corrosion treatment: ; Expansion treatment: ; in, is the image to be processed, is the structural element, Translated for structural elements After the position, for After reflection, the two positions are symmetrical about the origin.

Citation Information

Patent Citations

  • Improved particle swarm optimization method for achieving inversion of engineering rockmass mechanical parameters

    CN107169558A

  • Adaptive particle swarm algorithm-based grayscale threshold obtaining method and image segmentation method

    CN107492103A

  • Particle swarm algorithm-based image edge detection method and system

    CN108053413A

  • Image border detecting method and system based on particle swarm algorithm

    CN108198197A

  • Method and device for determining intra-pore sweep conditions

    CN111507986A