Fiber core point cloud positioning method based on Bayesian theory and related equipment

Through Bayesian theory of core point cloud positioning method, the problem of inaccurate core point cloud positioning in microscopes is solved, and higher image quality and diagnostic value are achieved.

CN118941634AActive Publication Date: 2024-11-12BIOPSEE (SUZHOU) MEDICAL TECH CO LTD
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
CN202410981060.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-07-22
Publication Date
2024-11-12
Estimated Expiration
2044-07-22

Smart Images

  • Figure CN118941634A_ABST
    Figure CN118941634A_ABST
Patent Text Reader

Abstract

The invention discloses a fiber core point cloud positioning method based on the Bayesian theory and related equipment, and relates to the field of image processing, and the method comprises the steps: traversing each fiber core in an initial point cloud image, determining the fiber core and a point of a first preset neighborhood as an initial point cloud, so as to generate N initial point clouds, all points in the same initial point cloud have the same non-zero pixel value, the pixel values of the N initial point clouds are different, and the pixel values of the initial point clouds are fixed; determining a pixel value in the initial point cloud adjacent to a to-be-defined point as the pixel value of the to-be-defined point cloud, the to-be-defined point being any point outside the initial point cloud; calculating the posterior probability of each pixel value of the to-be-defined point in a data set formed by the to-be-defined point and a second preset field; and classifying the to-be-defined points into point clouds with the same pixel values according to the pixel values of the to-be-defined points so as to obtain a final point cloud picture.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of image processing, and more specifically, to a fiber core point cloud positioning method and related equipment based on Bayesian theory. Background Art

[0002] A microendoscope is a medical device that can be inserted into the human body through channels such as gastroscopes and colonoscopes to obtain local histological images to achieve accurate diagnosis of tiny lesions, gastrointestinal lesions, and early gastrointestinal cancer. There are two important components in the scanning control module of a microendoscope: a resonant mirror and a galvanometer galvanometer. The function of the resonant mirror is to make the light scan rapidly in the horizontal direction, so it is also called an X-galvanometer. The function of the galvanometer galvanometer is to make the light scan vertically, so it is also called a Y-galvanometer. The two work together to obtain a two-dimensional image.

[0003] The resonant mirror and galvanometer galvanometer mirror contain precise electronic components, and the characteristics of these electronic components will change with the change of the working environment temperature. During the imaging process, each image is based on the predetermined core position and generates a core point cloud. Due to the change of the galvanometer characteristics, the core position changes during the imaging process, which leads to inaccurate core point cloud positioning, resulting in image quality degradation. Therefore, it is necessary to propose a more accurate core point cloud positioning method. Summary of the invention

[0004] A series of simplified concepts are introduced in the Summary of the Invention section, which will be further described in detail in the Detailed Description of the Invention section. The Summary of the Invention section of this application does not mean to attempt to define the key features and essential technical features of the claimed technical solution, nor does it mean to attempt to determine the scope of protection of the claimed technical solution.

[0005] In the first aspect, the present application proposes a fiber core point cloud positioning method based on Bayesian theory, the method comprising:

[0006] Traversing each fiber core in the initial point cloud map, determining the points of the fiber core and its first preset neighborhood as the initial point cloud, so as to generate N initial point clouds, wherein the first preset neighborhood is an S pixel neighborhood adjacent to the fiber core, each point in the same initial point cloud has the same non-zero pixel value, the pixel values ​​of the N initial point clouds are all different, and the pixel value of the initial point cloud remains fixed;

[0007] Determine the pixel value in the initial point cloud adjacent to the point to be defined as the pixel value of the point cloud to be defined, wherein the point to be defined is any point outside the initial point cloud;

[0008] Calculate the posterior probability of each pixel value of the point to be defined in the data set composed of the point and the second preset neighborhood, wherein the second preset neighborhood is the Q pixel neighborhood adjacent to the point to be defined;

[0009] According to the pixel value of the above-mentioned point to be defined, it is classified into the point cloud with the same pixel value to obtain the final point cloud map.

[0010] In a feasible implementation manner, traversing each fiber core in the initial point cloud image includes:

[0011] Performing a fusion operation based on multiple frames of original image data sets to obtain the above fused image;

[0012] Performing an optical fiber positioning operation on the fused image to obtain a fiber core coordinate set, wherein the fiber core coordinate set includes a fiber core coordinate value of each fiber core;

[0013] Generate an initial point cloud image with the same size as the above fused image, wherein all pixel values ​​in the initial point cloud image are initialized to 0;

[0014] Based on the above fiber core coordinate set, each fiber core is traversed in the above initial point cloud image, and the pixel value of each initial point cloud is generated randomly or according to a preset rule.

[0015] In a feasible implementation manner, the step of determining the pixel value of the initial point cloud adjacent to the point to be defined as the pixel value of the point cloud to be defined includes:

[0016] Determine the pixel values ​​of the P initial point clouds adjacent to the above-mentioned point to be defined as candidate categories;

[0017] A pixel value is randomly selected from the candidate categories to be determined as the pixel value of the point cloud to be defined.

[0018] In a feasible implementation manner, the above calculation of the posterior probability of each pixel value of the point to be defined in the data set composed of the point and the second preset area includes:

[0019] Calculate the prior probability based on the pixel values ​​in the above-mentioned category point cloud images;

[0020] Calculate the mean and variance value of pixels at each category position of the fused image, and calculate the conditional probability in the category point cloud image based on the mean and variance value;

[0021] The posterior probability is calculated based on the prior probability and the conditional probability.

[0022] In a feasible implementation, the calculation is repeated M times according to the calculation method of the above-mentioned prior probability, the above-mentioned conditional probability and the above-mentioned posterior probability, so as to take the larger value of the posterior probability as the pixel label value of the above-mentioned point to be defined, and the pixel value of the point on the point cloud map is updated to the above-mentioned pixel label value.

[0023] In a feasible implementation manner, the above-mentioned calculation of the conditional probability based on the above-mentioned mean and the above-mentioned variance value includes:

[0024] The above conditional probability P(X|Y) is calculated based on the following formula:

[0025]

[0026] Among them, X represents the value of the random variable, μ represents the above mean, and e represents the above variance.

[0027] In a feasible implementation manner, the calculation of the posterior probability according to the prior probability and the conditional probability includes:

[0028] The above posterior probability P(Y|X) is calculated based on the following formula:

[0029] P(Y|X)=P(Y)*P(X|Y)

[0030] Among them, P(X|Y) is the above conditional probability, and P(Y) is the above prior probability.

[0031] In a feasible implementation, it also includes:

[0032] When the above-mentioned posterior probability is less than the threshold, the pixel value of the point is set to 0, making it a background image.

[0033] In one possible implementation, S is less than Q.

[0034] In a second aspect, the present application embodiment proposes a fiber core point cloud positioning device based on Bayesian theory, including:

[0035] A first determining unit is used to traverse each fiber core in the initial point cloud map, and determine the points of the fiber core and its first preset neighborhood as the initial point cloud to generate N initial point clouds, wherein the first preset neighborhood is an S pixel neighborhood adjacent to the fiber core, each point in the same initial point cloud has the same non-zero pixel value, the pixel values ​​of the N initial point clouds are different, and the pixel value of the initial point cloud remains fixed;

[0036] A second determining unit is used to determine the pixel value in the initial point cloud adjacent to the point to be defined as the pixel value of the point cloud to be defined, wherein the point to be defined is any point outside the initial point cloud;

[0037] A calculation unit, used to calculate the posterior probability of each pixel value of the point to be defined in the data set composed of the point and a second preset neighborhood, wherein the second preset neighborhood is a Q pixel neighborhood adjacent to the point to be defined;

[0038] The acquisition unit is used to classify the above-mentioned point to be defined into a point cloud with the same pixel value according to the pixel value of the point to be defined, so as to obtain a final point cloud image.

[0039] In a third aspect, an electronic device comprises: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor is used to implement the steps of the Bayesian-based fiber core point cloud positioning method of any one of the first aspects described above when executing the computer program stored in the memory.

[0040] In a fourth aspect, the present application further proposes a computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the steps of the Bayesian-based fiber core point cloud positioning method of any one of the first aspects are implemented.

[0041] In summary, the method proposed in the embodiment of the present application includes: traversing each fiber core in the initial point cloud map, determining the points of the above-mentioned fiber core and its first preset neighborhood as the initial point cloud to generate N of the above-mentioned initial point clouds, wherein the above-mentioned first preset neighborhood is the S pixel neighborhood adjacent to the above-mentioned fiber core, and each point in the same initial point cloud has the same non-zero pixel value, the pixel values ​​of the N initial point clouds are all different, and the pixel value of the above-mentioned initial point cloud remains fixed; determining the pixel value in the initial point cloud adjacent to the point to be defined as the pixel value of the above-mentioned point cloud to be defined, wherein the above-mentioned point to be defined is any point outside the above-mentioned initial point cloud; calculating the posterior probability of each pixel value of the data set composed of the point to be defined at this point and the second preset area, wherein the above-mentioned second preset neighborhood is the Q pixel neighborhood adjacent to the above-mentioned point to be defined; according to the pixel value of the above-mentioned point to be defined, it is classified into the point cloud with the same pixel value to obtain the final point cloud map. The method proposed in the embodiment of the present application can accurately identify the position of the fiber core in the initial point cloud map by accurately positioning and fixing the pixel value of each fiber core and its neighborhood, thereby improving the accuracy and stability of the point cloud map in subsequent steps. Through hierarchical processing from the initial point cloud to the point cloud to be defined, the point cloud data can be effectively managed and classified. By calculating the posterior probability multiple times and selecting the value with a higher probability as the pixel label value in the point cloud map, the attributes of each point cloud can be more accurately reflected. The present method provides an automated point cloud processing flow, which can adjust the neighborhood size and the number of posterior probability calculations as needed to adapt to different application scenarios and needs, thereby enhancing the versatility and scalability of the method. Through more accurate point cloud positioning, the imaging errors caused by changes in equipment characteristics can be reduced, thereby improving the overall quality and diagnostic value of the image.

[0042] The fiber core point cloud positioning method based on Bayesian theory proposed in this application, and other advantages, objectives and features of this application will be partially reflected through the following description, and will also be partially understood by technical personnel in this field through research and practice of this application. BRIEF DESCRIPTION OF THE DRAWINGS

[0043] Various other advantages and benefits will become apparent to those of ordinary skill in the art by reading the detailed description of the preferred embodiments below. The accompanying drawings are only for the purpose of illustrating the preferred embodiments and are not to be considered as limiting the present specification. Also, the same reference symbols are used throughout the accompanying drawings to represent the same components. In the accompanying drawings:

[0044] Figure 1 A schematic diagram of the process of a fiber core point cloud positioning method based on Bayesian theory provided in an embodiment of the present application;

[0045] Figure 2 A schematic diagram of a first preset neighborhood provided in an embodiment of the present application;

[0046] Figure 3 A schematic diagram of a second preset neighborhood provided in an embodiment of the present application;

[0047] Figure 4 A schematic diagram of a conditional probability calculation principle provided in an embodiment of the present application;

[0048] Figure 5 A schematic structural diagram of a fiber core point cloud positioning device based on Bayesian theory provided in an embodiment of the present application;

[0049] Figure 6 A schematic diagram of the structure of a fiber core point cloud positioning electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0050] The terms "first", "second", "third", "fourth", etc. (if any) in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments described herein can be implemented in an order other than that illustrated or described herein. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices. The technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, rather than all of the embodiments.

[0051] See also Figure 1 , which is a schematic diagram of the process of a fiber core point cloud positioning method based on Bayesian theory provided in an embodiment of the present application, which may specifically include:

[0052] S110, traversing each fiber core in the initial point cloud map, determining the points of the fiber core and its first preset neighborhood as the initial point cloud, so as to generate N initial point clouds, wherein the first preset neighborhood is an S pixel neighborhood adjacent to the fiber core, each point in the same initial point cloud has the same non-zero pixel value, the pixel values ​​of the N initial point clouds are all different, and the pixel values ​​of the initial point cloud are fixed;

[0053] Exemplary. Before performing point cloud positioning, it is first necessary to traverse each fiber core in the initial point cloud map. Determine the points of each fiber core and its first preset neighborhood. The "first preset neighborhood" here refers to the area of ​​S pixels adjacent to the fiber core, and S can be 4. Each point in each fiber core and its neighborhood is defined as an initial point cloud, so a total of N initial point clouds will be generated. Each point in the same initial point cloud has the same non-zero pixel value, while the pixel values ​​between different initial point clouds are different. The pixel values ​​of these initial point clouds remain fixed during subsequent processing. The first preset area is such as Figure 2 shown.

[0054] S120, determining the pixel value in the initial point cloud adjacent to the point to be defined as the pixel value of the point cloud to be defined, wherein the point to be defined is any point outside the initial point cloud;

[0055] Exemplarily, for any point outside the initial point cloud (referred to as a point to be defined), the point to be defined refers to any point outside the initial point cloud. The pixel value of the point to be defined is determined by the pixel value of any point cloud in the adjacent P initial point clouds, where P can be 3. Its pixel value will be determined as the pixel value in the adjacent initial point cloud. This step involves starting from the position of the point to be defined, looking for whether there is an initial point cloud around it. If so, the pixel value of the point to be defined will be set to the pixel value of the adjacent initial point cloud.

[0056] S130, calculating the posterior probability of each pixel value of the point to be defined in the data set composed of the point and the second preset neighborhood, wherein the second preset neighborhood is a Q pixel neighborhood adjacent to the point to be defined;

[0057] For example, next, the posterior probability of each pixel value in the data set within the second preset neighborhood of the point to be defined needs to be calculated. The "second preset neighborhood" here refers to the Q pixel neighborhood adjacent to the point to be defined, Q can be 8, and the second preset neighborhood is as follows Figure 3 As shown in Figure 2, Bayesian theory is used to estimate the probability of each possible pixel value of the point to be defined given the surrounding pixel values.

[0058] S140, classifying the to-be-defined point into a point cloud with the same pixel value according to the pixel value of the to-be-defined point, so as to obtain a final point cloud image;

[0059] For example, according to the above calculated pixel value probability, the point to be defined will be classified into the point cloud with the same pixel value. In this way, the final point cloud map can be gradually expanded and improved to ensure that each point is correctly classified into the corresponding point cloud.

[0060] In summary, the method proposed in the embodiment of the present application can accurately identify the position of the fiber core in the initial point cloud map by accurately positioning and fixing the pixel value of each fiber core and its neighborhood, thereby improving the accuracy and stability of the point cloud map in subsequent steps. Through hierarchical processing from the initial point cloud to the point cloud to be defined, the point cloud data can be effectively managed and classified. By calculating the posterior probability multiple times and selecting the value with a higher probability as the pixel label value in the point cloud map, the attributes of each point cloud can be more accurately reflected. The present method provides an automated point cloud processing flow, which can adjust the neighborhood size and the number of posterior probability calculations as needed, so as to adapt to different application scenarios and needs, thereby enhancing the versatility and scalability of the method. Through more accurate point cloud positioning, the imaging errors caused by changes in equipment characteristics can be reduced, thereby improving the overall quality and diagnostic value of the image.

[0061] In some examples, traversing each fiber core in the initial point cloud image includes:

[0062] Performing a fusion operation based on multiple frames of original image data sets to obtain the above fused image;

[0063] Performing an optical fiber positioning operation on the fused image to obtain a fiber core coordinate set, wherein the fiber core coordinate set includes a fiber core coordinate value of each fiber core;

[0064] Generate an initial point cloud image with the same size as the above fused image, wherein all pixel values ​​in the initial point cloud image are initialized to 0;

[0065] Based on the above fiber core coordinate set, each fiber core is traversed in the above initial point cloud image, and the pixel value of each initial point cloud is generated randomly or according to a preset rule.

[0066] Exemplarily, N frames of images are selected from multiple frames of original images for fusion. These images can come from different time points or different angles. By fusing these images, the quality of the image and the integrity of the information can be improved. The fusion operation can use various image processing techniques, such as multi-image overlay, HDR (high dynamic range imaging) technology, or more advanced deep learning methods to improve the clarity and detail of the final image.

[0067] Perform fiber positioning operations on the acquired fused image. This usually involves image recognition techniques such as edge detection, pattern recognition, or deep learning algorithms to accurately identify the location of the fiber core. The coordinate values ​​of each fiber core are obtained from the positioning process. These coordinate values ​​identify the exact location of the fiber core in the image and provide basic data for subsequent processing steps such as point cloud map generation.

[0068] Based on the size of the fused image, a point cloud image is generated with all pixel values ​​initially set to 0. This blank point cloud image will be used in subsequent processing steps. By setting the pixel values ​​of the corresponding point cloud positions to specific values ​​based on the core coordinates identified in the fused image, the method of setting the pixels of the point cloud to specific values ​​can be randomly generated or incrementally generated in the traversal order to mark the position of the core. These marked points and their neighborhoods (such as 4-pixel neighborhoods) will be used in subsequent steps to define and classify the surrounding point clouds.

[0069] Through the method proposed in this embodiment, richer information can be extracted from multi-frame image data, and the high quality and accuracy of the fused image can be used to perform high-precision optical fiber positioning and point cloud map generation.

[0070] In some examples, determining the pixel value of the initial point cloud adjacent to the point to be defined as the pixel value of the point cloud to be defined includes:

[0071] Determine the pixel values ​​of the P initial point clouds adjacent to the above-mentioned point to be defined as candidate categories;

[0072] A pixel value is randomly selected from the candidate categories to be determined as the pixel value of the point cloud to be defined.

[0073] Exemplarily, for a given point to be defined (i.e., any point outside the initial point cloud), determine its adjacent P initial point clouds. "Adjacent" can be defined based on some geometric distance or connectivity, such as the nearest neighbor algorithm or other spatial distance calculation methods. From these adjacent P initial point clouds, the pixel values ​​of each point cloud are collected, and these values ​​constitute a "candidate category". This category contains all pixel value options that may be assigned to the point to be defined.

[0074] In the obtained candidate category, a pixel value is randomly selected. The selected pixel value will be determined as the pixel value of the above-mentioned point cloud to be defined. This step completes the setting of the pixel value of the point to be defined, so that the point in this point cloud data obtains a specific attribute value.

[0075] By introducing randomness, this embodiment can avoid the local extreme value problem that may be ignored by the deterministic algorithm, making the classification result more robust. The method of selecting P point clouds can be flexibly set according to the actual application requirements, so that this method can adapt to different environments and requirements. A relatively simple and effective method is provided to estimate and correct the pixel values ​​of unknown categories in the point cloud image, which is very useful in applications that require extremely high pixel classification accuracy.

[0076] In some examples, in a feasible implementation manner, the above calculation of the posterior probability of each pixel value of the point to be defined in the data set composed of the point and the second preset area includes:

[0077] Calculate the prior probability based on the pixel values ​​in the above-mentioned category point cloud images;

[0078] Calculate the mean and variance value of pixels at each category position of the fused image, and calculate the conditional probability in the category point cloud image based on the mean and variance value;

[0079] The posterior probability is calculated based on the prior probability and the conditional probability.

[0080] Exemplarily, the mean and variance of pixels at each category position in the fused image are calculated. The fused image is formed by merging multiple image layers, which contains rich background and target information. The mean provides the average brightness or color information of each category of pixels, while the variance reflects the dispersion or consistency of these pixel values.

[0081] The pixel values ​​in the category point cloud are set as prior probabilities, that is, the initial probability that each pixel belongs to a certain category without considering the fused image data.

[0082] The mean and variance in the fused image are used to calculate the conditional probability, that is, the probability that a pixel belongs to a specific category when a pixel value is given. This can be implemented based on the normal distribution or other statistical distribution models. The conditional probability can be calculated based on the degree of deviation of the pixel value from the category mean.

[0083] The posterior probability is the probability obtained by combining the prior probability and the conditional probability, calculated according to Bayes' theorem. After observing a specific pixel value, the updated probability that the pixel belongs to each category.

[0084] In some examples, the calculation is repeated M times according to the calculation method of the prior probability, the conditional probability and the posterior probability, so that the larger value of the posterior probability is used as the pixel label value of the point to be defined, and the pixel value of the point on the point cloud map is updated to the pixel label value.

[0085] Exemplarily, by repeating this series of calculations M times, the estimation of the posterior probability can be further optimized and adjusted. Ultimately, the category with the highest posterior probability is selected as the pixel label value in each point cloud image. This repeated calculation helps stabilize the estimation of the posterior probability, especially when the data is complex or noisy.

[0086] The method proposed in the embodiment of the present application calculates the posterior probability by combining prior knowledge and observed data, which can significantly improve the accuracy of classification, allow dynamic updating of prior probability and conditional probability, adapt to new data input, and have learning ability.

[0087] In some examples, calculating the conditional probability based on the mean and the variance value includes:

[0088] The above conditional probability P(X|Y) is calculated based on the following formula:

[0089]

[0090] Among them, x represents the value of the random variable, μ represents the above mean, and e represents the above variance.

[0091] In some examples, calculating the posterior probability according to the prior probability and the conditional probability includes:

[0092] The above posterior probability P(Y|X) is calculated based on the following formula:

[0093] P(Y|X)=P(Y)*P(X|Y)

[0094] Among them, P(X|Y) is the above conditional probability, and P(Y) is the above prior probability.

[0095] In some examples, the above method also includes: when the posterior probability is less than a threshold, setting the pixel value of the point to 0, so that it becomes the background image.

[0096] Exemplarily, by calculating the posterior probability multiple times, each pixel of the point cloud is assigned a label value that represents the most likely category. A preset threshold is set, which is determined based on experience or statistical analysis to distinguish between labels with high confidence and labels with low confidence. The setting of the threshold depends on the specific application requirements and the required image quality. The label values ​​of all point clouds are checked, and any label value below the preset threshold will be set to zero. These points will not be classified into any specific category, but will be regarded as background or uncertain areas.

[0097] After filtering, all point clouds with non-zero label values ​​are grouped into one point cloud to generate the final point cloud map. In this way, the final image only contains data with high confidence, thereby improving the overall quality and reliability of the image. By removing low-confidence labels, image noise can be significantly reduced.

[0098] In some examples, S is less than Q.

[0099] Exemplarily, by setting the value of Q to be larger than S, the posterior probability has enough samples, thereby increasing the accuracy of the calculation.

[0100] In some examples, the final point cloud image can be obtained by:

[0101] S210, adjusting the laser power to a suitable value to obtain an image with optimal brightness, and taking N frames of original images.

[0102] S220, taking the average value of N frames of images to obtain a fused image I mean .

[0103] S230, generating an initial point cloud image I cloud , I cloud Size and fusion image I mean The pixel values ​​of all points are initialized to 0.

[0104] S240, in I mean Locate the fiber core and obtain the fiber core coordinate set {C n}, n = 1, 2, ... N, N is the number of fiber cores.

[0105] S250, mark point cloud area:

[0106] S2501, traverse {C n};

[0107] S2502, in I cloud Admiral Cn The pixel values ​​of the points in its first preset neighborhood are marked as n, and N initial point clouds are generated. The pixel values ​​of the initial point clouds remain unchanged in the subsequent steps.

[0108] S260, generating candidate categories {Cls for the points to be defined outside the initial point cloud area n}, n = 1, 2…, TT is the number of points outside the initial point cloud area, the pixel values ​​of the three nearest point clouds of point pt are taken as candidate categories, Cls pt ={C1,C2,C3}.

[0109] S270. Randomly set the pixel value of the point outside the initial point cloud area to one of the candidate categories.

[0110] S280, calculate the posterior probability of each point outside the initial point cloud area within its 3X3 neighborhood:

[0111] S2801. Calculate the prior probability of each category:

[0112] Hypothesis I cloud The pixel value (category) of the 3X3 neighborhood of a point pt is as follows Figure 4 As shown:

[0113] Calculating the prior probability, we get:

[0114] P(Y=101)=3 / 9

[0115] P(Y=102)=2 / 9

[0116] P(Y=103)=2 / 9

[0117] P(Y=104)=2 / 9

[0118] S2802, in I mean Calculate the mean and variance of the pixels at the corresponding position of each category

[0119] S2803, according to the formula Calculate the conditional probability P(X|Y) and get

[0120] P(X|Y=101)

[0121] P(X|Y=102)

[0122] P(X|Y=103)

[0123] P(X|Y=104)

[0124] S2804, calculate the post-verification probability P(Y|X) according to the formula P(Y|X)=P(Y)*P(X|Y), and obtain

[0125] P(Y=101|X)

[0126] P(Y=102|X)

[0127] P(Y=103|X)

[0128] P(Y=104|X)

[0129] S2805. Take the label value v corresponding to the maximum value of the result calculated in S2804, and update the pixel value of point pt on the point cloud map to v.

[0130] S290, repeat step S280 multiple times until the set number of iterations is reached and then stop.

[0131] S300, minimum value suppression.

[0132] It is determined whether the posterior probability of each point in step S300 is less than the threshold Trd. If yes, the point is marked as 0 in the point cloud image.

[0133] S310, grouping points with the same pixel value on the point cloud image into one point cloud to obtain a final point cloud image.

[0134] See also Figure 5 , a structural schematic diagram of a fiber core point cloud positioning device based on Bayesian theory provided in an embodiment of the present application may include:

[0135] The first determining unit 21 is used to traverse each fiber core in the initial point cloud map, and determine the points of the fiber core and its first preset neighborhood as the initial point cloud to generate N initial point clouds, wherein the first preset neighborhood is an S pixel neighborhood adjacent to the fiber core, each point in the same initial point cloud has the same non-zero pixel value, the pixel values ​​of the N initial point clouds are different, and the pixel value of the initial point cloud is fixed;

[0136] A second determining unit 22 is used to determine the pixel value in the initial point cloud adjacent to the point to be defined as the pixel value of the point cloud to be defined, wherein the point to be defined is any point outside the initial point cloud;

[0137] A calculation unit 23 is used to calculate the posterior probability of each pixel value of the point to be defined in the data set composed of the point and a second preset neighborhood, wherein the second preset neighborhood is a Q pixel neighborhood adjacent to the point to be defined;

[0138] The acquisition unit 24 is used to classify the to-be-defined point into a point cloud with the same pixel value according to the pixel value of the to-be-defined point, so as to obtain a final point cloud image.

[0139] like Figure 6As shown, an embodiment of the present application also provides an electronic device 300, including a memory 310, a processor 320, and a computer program 311 stored in the memory 310 and executable on the processor, and when the processor 320 executes the computer program 311, the steps of any of the above-mentioned methods for core point cloud positioning are implemented.

[0140] Since the electronic device introduced in this embodiment is a device used to implement a fiber core point cloud positioning device based on Bayesian theory in the embodiment of the present application, based on the method introduced in the embodiment of the present application, the technical personnel in this field can understand the specific implementation mode of the electronic device of this embodiment and its various variations. Therefore, how the electronic device implements the method in the embodiment of the present application is not introduced in detail here. As long as the equipment used by the technical personnel in this field to implement the method in the embodiment of the present application is within the scope of protection of this application.

[0141] In the specific implementation process, when the computer program 311 is executed by the processor, it can achieve Figure 1 Any implementation manner in the corresponding embodiments.

[0142] It should be noted that in the above embodiments, the description of each embodiment has its own emphasis, and for parts that are not described in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.

[0143] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment in combination with software and hardware. Moreover, the present application may adopt the form of a computer program product implemented in one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) that include computer-usable program code.

[0144] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded computer, or other programmable data processing device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0145] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0146] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0147] The embodiment of the present application further provides a computer program product, which includes computer software instructions. When the computer software instructions are executed on a processing device, the processing device executes the process of core point cloud positioning in the corresponding embodiment.

[0148] The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on the computer, the process or function according to the embodiment of the present application is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices. The computer instructions can be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions can be transmitted from a website site, a computer, a server or a data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (digital subscriber line, DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) mode to another website site, computer, server or data center. The computer-readable storage medium can be any available medium that a computer can store or a data storage device such as a server or a data center that includes one or more available media integration. The available medium can be a magnetic medium, (e.g., a floppy disk, a hard disk, a tape), an optical medium (e.g., a DVD), or a semiconductor medium (e.g., a solid state drive (SSD)), etc.

[0149] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.

[0150] In the several embodiments provided in the present application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of units is only a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or units, which can be electrical, mechanical or other forms.

[0151] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0152] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.

[0153] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the various embodiments of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (Read-Only Memory, ROM), random access memory (Random Access Memory, RAM), disk or optical disk and other media that can store program codes.

[0154] The above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some of the technical features therein by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application.

Claims

1. A fiber core point cloud positioning method based on Bayesian theory, It is characterized in that include: Traversing each fiber core in the initial point cloud map, determining the points of the fiber core and its first preset neighborhood as the initial point cloud, so as to generate N initial point clouds, wherein the first preset neighborhood is an S pixel neighborhood adjacent to the fiber core, each point in the same initial point cloud has the same non-zero pixel value, the pixel values ​​of the N initial point clouds are all different, and the pixel value of the initial point cloud remains fixed; Determine the pixel value in the initial point cloud adjacent to the point to be defined as the pixel value of the point cloud to be defined, wherein the point to be defined is any point outside the initial point cloud; Calculate the posterior probability of each pixel value of the data set composed of the point to be defined at this point and a second preset neighborhood, wherein the second preset neighborhood is a Q pixel neighborhood adjacent to the point to be defined; According to the pixel value of the point to be defined, it is classified into the point cloud with the same pixel value as that of the point to be defined, so as to obtain the final point cloud image.

2. According to the Bayesian theory-based fiber core point cloud positioning method of claim 1, It is characterized in that The traversing each fiber core in the initial point cloud image includes: Performing a fusion operation based on multiple frames of original image data sets to obtain the fused image; Performing an optical fiber positioning operation on the fused image to obtain a fiber core coordinate set, wherein the fiber core coordinate set includes a fiber core coordinate value of each fiber core; Generate an initial point cloud image with the same size as the fused image, wherein all pixel values ​​in the initial point cloud image are initialized to 0; Based on the fiber core coordinate set, each fiber core is traversed in the initial point cloud map, and the pixel value of each initial point cloud is generated randomly or according to a preset rule.

3. According to the Bayesian theory-based fiber core point cloud positioning method of claim 2, It is characterized in that The step of determining the pixel value of the initial point cloud adjacent to the point to be defined as the pixel value of the point cloud to be defined comprises: Determine the pixel values ​​of P initial point clouds adjacent to the point to be defined as candidate categories; A pixel value is randomly selected in the candidate category and determined as the pixel value of the point cloud to be defined.

4. The fiber core point cloud positioning method based on Bayesian theory according to claim 3, It is characterized in that The calculation of the posterior probability of each pixel value of the data set composed of the point to be defined at the point and the second preset area includes: Calculate the prior probability based on the pixel values ​​in the category point cloud image; Calculating the mean and variance value of pixels at each category position of the fused image, and calculating conditional probability in the category point cloud image based on the mean and the variance value; The posterior probability is calculated based on the prior probability and the conditional probability.

5. The fiber core point cloud positioning method based on Bayesian theory according to claim 4, It is characterized in that The calculation is repeated M times according to the calculation method of the prior probability, the conditional probability and the posterior probability, so as to take the larger value of the posterior probability as the pixel label value of the point to be defined, and the pixel value of the point on the point cloud map is updated to the pixel label value.

6. The fiber core point cloud positioning method based on Bayesian theory according to claim 4, It is characterized in that The calculating the conditional probability based on the mean and the variance value comprises: The conditional probability P(X|Y) is calculated based on the following formula: : Wherein, x represents the value of the random variable, μ represents the mean, and e represents the variance.

7. The fiber core point cloud positioning method based on Bayesian theory according to claim 6, It is characterized in that The calculating the posterior probability according to the prior probability and the conditional probability comprises: The posterior probability P(Y|X) is calculated based on the following formula: P(Y|X)=P(Y)*P(X|Y) Among them, P(X|Y) is the conditional probability, and P(Y) is the prior probability.

8. The fiber core point cloud positioning method based on Bayesian theory according to claim 1, It is characterized in that Also includes: When the posterior probability is less than the threshold, the pixel value of the point is set to 0, making it a background image.

9. The fiber core point cloud positioning method based on Bayesian theory according to claim 1, It is characterized in that S is smaller than Q.

10. A fiber core point cloud positioning device based on Bayesian theory, It is characterized in that include: A first determining unit is used to traverse each fiber core in the initial point cloud image, and determine the points of the fiber core and its first preset neighborhood as the initial point cloud, so as to generate N initial point clouds, wherein the first preset neighborhood is an S pixel neighborhood adjacent to the fiber core, each point in the same initial point cloud has the same non-zero pixel value, the pixel values ​​of the N initial point clouds are different, and the pixel value of the initial point cloud is fixed; A second determining unit is used to determine the pixel value in the initial point cloud adjacent to the point to be defined as the pixel value of the point cloud to be defined, wherein the point to be defined is any point outside the initial point cloud; A calculation unit, used to calculate the posterior probability of each pixel value of the point to be defined in the data set composed of the point and a second preset neighborhood, wherein the second preset neighborhood is a Q pixel neighborhood adjacent to the point to be defined; The acquisition unit is used to classify the point to be defined into a point cloud with the same pixel value according to the pixel value of the point to be defined, so as to obtain a final point cloud image.

Citation Information

Patent Citations

  • Point cloud noise reduction method and device, electronic equipment and computer readable storage medium

    CN111798398A

  • Pipeline BIM model reconstruction method and system based on depth image and point cloud

    CN115294294A

  • Radar point cloud densification method and related equipment

    CN117710782A

  • Point cloud data processing method and device

    WO2022142628A1