Speckle displacement detection precision improvement method based on image distortion intelligent identification

By establishing a four-dimensional vector model using the particle swarm optimization algorithm and optimizing the speckle image distortion parameters, the problem of insufficient speckle displacement detection accuracy was solved, and high-precision speckle displacement detection was achieved.

CN120953498APending Publication Date: 2025-11-14UNIV OF ELECTRONICS SCI & TECH OF CHINA
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511066143.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-07-31
Publication Date
2025-11-14

AI Technical Summary

Technical Problem

Existing speckle displacement detection methods lack accuracy under pattern distortion conditions, resulting in large calculation errors and making it difficult to meet high-precision requirements.

Method used

The particle swarm optimization algorithm is used for optimization calculation. By identifying speckle image distortion, a four-dimensional vector model is established to optimize displacement calculation parameters and improve detection accuracy.

Benefits of technology

It significantly improves the accuracy of speckle displacement detection, accurately identifies the displacement and distortion parameters of speckle patterns, and enhances the positioning accuracy of robot motion trajectories.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120953498A_ABST
    Figure CN120953498A_ABST
Patent Text Reader

Abstract

The invention discloses a speckle displacement detection precision improvement method based on image distortion intelligent identification, and the method comprises the following steps: S1, data collection: firstly, carrying out the installation of a mechanical arm speckle projection device, and then carrying out the data collection; s2, error analysis, namely distortion reason analysis; s3, parameter modeling: modeling factors influencing the distortion degree based on the reason analysis in the step S2; s4, optimizing by using a particle swarm algorithm, and identifying an optimal parameter of the distorted picture; and S5, obtaining optimal parameters of picture translation and deformation. According to the speckle displacement detection precision improvement method based on image distortion intelligent identification, particle modeling is carried out on the displacement amount and the distortion amount of the projected speckles, optimization operation is carried out through a particle swarm algorithm, the precision of displacement calculation is improved, and information of the distortion amount of the speckles is obtained.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of robotics technology, specifically relating to a method for improving the accuracy of speckle displacement detection based on intelligent image distortion recognition. Background Technology

[0002] Currently, robots are widely used in industrial production, medical surgery, precision assembly, and other fields, and their precision is of great significance in measuring performance and task completion quality. Therefore, controlling the robot's motion trajectory and positioning accuracy is key to ensuring production quality and driving the industry towards high-end development.

[0003] GB / T 12642-2013, "Performance Specifications and Test Methods for Industrial Robots," specifies a series of important performance indicators for manipulator robots and their corresponding test methods. Accurate testing of these indicators is a prerequisite for achieving high-precision robot control. Precise quantification of key parameters such as positioning error and repeatability provides data support for subsequent error compensation and motion control algorithm optimization, thereby improving robot performance.

[0004] Currently, mainstream robot accuracy inspection methods mainly include laser tracker-based inspection, vision inspection, and joint sensor compensation methods. However, these methods generally face some problems in practical applications: in terms of cost, equipment such as laser trackers and high-precision coordinate measuring machines are expensive, and the system setup, debugging, and maintenance costs are also high; in terms of inspection efficiency, some methods have cumbersome inspection processes, making it difficult to meet the needs of real-time monitoring on production lines, making it difficult to continuously guarantee high-precision inspection requirements under complex working conditions or during long-term use.

[0005] In the field of robot error calibration, an economical detection method based on collimated laser projection speckle patterns and digital image correlation can be used for error calibration. This method boasts high accuracy, extremely low cost, real-time performance, and strong applicability. The main process involves fixing a speckle pattern projector at the end effector of a robotic arm. During the arm's movement, the projected speckle pattern is photographed and its displacement is calculated, thus converting the error into the robotic arm's error. However, this method's calculation process relies on the identification and matching of sub-regions of two speckle patterns. Therefore, its accuracy is significantly affected by the layout and features of the speckle patterns. If the speckle pattern deforms in the two captured images, altering its features, the matching accuracy of the sub-regions may decrease, leading to a significant error in the calculation method.

[0006] After detailed analysis, it was found that during the data acquisition phase of this method, the speckle projection device needs to move continuously according to the programmed trajectory. The angle between the projected beam and the normal of the imaging plate is constantly changing, which will cause the pattern to be deformed by an approximate stretching. At the same time, due to the continuous change of the projection direction, the speckle pattern will rotate, which may cause the speckle in each picture to be distorted to varying degrees, changing the pattern characteristics, affecting sub-region matching, and ultimately causing a loss of accuracy in error calculation. Summary of the Invention

[0007] The purpose of this invention is to solve the above-mentioned problems and provide a method for improving the accuracy of speckle displacement detection based on intelligent image distortion recognition by using particle swarm optimization to perform optimization calculations, improve the accuracy of displacement calculation, and obtain speckle distortion information.

[0008] To solve the above-mentioned technical problems, the technical solution of the present invention is: a method for improving the accuracy of speckle displacement detection based on intelligent image distortion recognition, comprising the following steps:

[0009] S1. Data acquisition: First, install the speckle projection device of the robotic arm, and then acquire data.

[0010] S2, Error Analysis, i.e., Analysis of the Causes of Distortion;

[0011] S3. Parametric modeling: Based on the cause analysis in step S2, model the factors that affect the degree of distortion.

[0012] S4. Particle swarm optimization algorithm to identify the optimal parameters of distorted images;

[0013] S5. Obtain the optimal parameters for image translation and deformation.

[0014] Furthermore, the data acquisition in S1 includes the following steps:

[0015] S11. Install the robotic arm, imaging panel, and camera, and connect the camera to the computer;

[0016] S12. Project the prepared speckle pattern onto the target position on the imaging plate. Move the robotic arm and set the end of the robotic arm as the end of the robotic arm. Control the end of the robotic arm to always point to the target position on the imaging plate.

[0017] S13. During the movement of the robotic arm, the camera takes pictures and obtains multiple sets of images.

[0018] Furthermore, the distortion cause analysis process in S2 is as follows: due to the different projection directions of the two projections at the end of the robotic arm, the resulting speckle pattern is distorted from a circle to an ellipse with different eccentricities and different major axis directions; at this time, the speckle pattern exhibits distortion in two directions, which changes the pattern information contained in the sub-region and will affect the calculation accuracy of the digital image correlation method for displacement calculation through sub-region search.

[0019] Furthermore, the modeling process in S3 is as follows:

[0020] S31. Based on the way the robotic arm moves, model the projection of the robotic arm to obtain a three-dimensional image;

[0021] S32. In the XZ plane, the angle between the robotic arm and the normal of the imaging plate is β; the angle between the projection of the speckle beam in the XY plane and the positive direction of the Y axis is α; when the robotic arm moves according to the programmed path, the angles α and β will change accordingly. The angle α determines the direction of the major axis of the elliptic speckle, and the angle β determines the eccentricity of the elliptic speckle.

[0022] S33. In images obtained from different groups of images, the differences between speckle patterns can be divided into four dimensions: the amount of movement along the X-axis, the amount of movement along the Y-axis, the rotation angle α, and the projection angle β; these four-dimensional vectors are used as four optimization parameters for the particle swarm optimization algorithm.

[0023] Furthermore, the particle swarm optimization algorithm in S4, the method for identifying the optimal parameters of the distorted image based on this algorithm, includes the following steps:

[0024] S41. Calculate the correlation coefficient between the two images and use 1 - correlation coefficient as the fitness function of the particle swarm optimization algorithm.

[0025] The formula for calculating the correlation coefficient of the images is as follows:

[0026]

[0027] The grayscale value of the first image is a. ij Where i = 1, 2, ..., m, j = 1, 2, ..., n (m and n are the row and column numbers of the image, respectively); the grayscale value of the second image is b. ij ;

[0028] Since the fitness function is continuously reduced through iteration during the particle swarm optimization (PSO) calculation process, CC = 1 - C is chosen as the fitness function for this PSO algorithm.

[0029] S42. Initialize the particle swarm algorithm by inputting the initial vector into the deformation function for processing;

[0030] S43. Calculate the global optimal position based on the individual optimal position and the formula.

[0031] S44. Calculate whether the fitness function is small enough. If it has not reached the minimum value, continue iterating.

[0032] Furthermore, the processing in S42 is as follows:

[0033] S421. Define each four-dimensional particle in a particle swarm as (x... i ,y i ,β i ,α i The velocity is V = (V1, V2, ... V). N ); where x i The distance the image moves along the x-axis is represented by the y-axis. i β represents the distance the image moves along the y-axis. i α represents the projection angle of the image. i The rotation angle of the image is represented by i = 1, 2, ..., N, where N represents the total number of particles;

[0034] S422. Initialize the particle's velocity to V0 = 0; initialize the particle's position P0; set upper and lower limits for the four variables so that the four vectors take random values ​​within different ranges.

[0035] S423. For each particle, process the first image according to the initialized four-dimensional vector P0; translate the first image along the X and Y axes according to the information of the four-dimensional vector P0, rotate the pattern by an angle α, and stretch it in that direction to simulate the projection distortion caused by the angle β, and obtain the processed deformed image.

[0036] S424. Calculate the correlation coefficient between the deformed image and the second image to obtain the fitness function CC corresponding to the particle.

[0037] Furthermore, step S43 includes the following sub-steps:

[0038] S431. Perform step S42 on all N particles. The position corresponding to the minimum fitness function in the history of each particle is regarded as the individual optimal position of that particle. After each iteration, the best position among the individual optimal positions of all particles is regarded as the global optimal position.

[0039] S432. Let P be the optimal position of the currently searched individual. i The currently found global optimum position is denoted as W. i Update the velocity and position of the particle swarm according to the following equations:

[0040] V i (t+1)=c0Vi (t)+c1*r1(t)*[P i (t)-X i (t)]+c2*r2(t)*[W i (t)-X i (t)]

[0041] X i (t+1)=X i (T)+V i (t+1)

[0042] Where c0 is the inertia weight, c1 and c2 are learning factors, r1(t) and r2(t) are random numbers between [0,1], and V i The velocity of the particle;

[0043] S433. After the new particle swarm velocity and position are generated, the new four-dimensional vector is used as the input to the deformation function to obtain the new output image and fitness function, thus completing the next iteration.

[0044] Furthermore, the specific content of S44 is as follows: a cutoff threshold is set for the fitness function. If the fitness function is less than the cutoff threshold at the current iteration number, the iteration is stopped, and the four vectors corresponding to the current global optimal position of the particle are obtained. When the fitness function is greater than the cutoff threshold, the iteration continues until the set maximum iteration number is reached, and the iteration ends, and the four vectors corresponding to the current global optimal position of the particle are obtained.

[0045] The beneficial effects of this invention are:

[0046] 1. The present invention provides a method for improving the accuracy of speckle displacement detection based on intelligent image distortion recognition. The method performs particle modeling on the displacement and distortion of the projected speckle, performs optimization calculation through particle swarm optimization algorithm, improves the accuracy of displacement calculation, and obtains information on speckle distortion.

[0047] 2. This invention models the translation and deformation information of an image as a four-dimensional vector, which is used as the input of the particle swarm optimization algorithm. A function related to the correlation coefficient is used as the fitness function of the algorithm. By optimizing the four-dimensional vector through the particle swarm optimization algorithm, the specific parameters of speckle pattern displacement and distortion can be identified, which greatly improves the calculation accuracy of speckle displacement. Attached Figure Description

[0048] Figure 1 This is a flowchart of the steps of a method for improving the accuracy of speckle displacement detection based on intelligent image distortion recognition according to the present invention;

[0049] Figure 2 This is a schematic diagram of the structure of the robotic arm speckle projection device of the present invention;

[0050] Figure 3 This is a diagram showing the speckle projection imaging effect of the robotic arm of this invention;

[0051] Figure 4 This is a schematic diagram of the robotic arm projection method of the present invention;

[0052] Explanation of reference numerals in the attached figures: 1. Speckle pattern projector; 2. End of robotic arm; 3. Robotic arm; 4. Imaging plate; 5. Speckle pattern; 6. Camera. Detailed Implementation

[0053] The present invention will be further described below with reference to the accompanying drawings and specific embodiments:

[0054] like Figures 1 to 4 As shown, this invention provides a method for improving the accuracy of speckle displacement detection based on intelligent image distortion recognition. The basic principle is as follows: For two distorted images, one image is continuously translated and deformed, and its correlation with the second image is calculated until the maximum correlation coefficient is obtained. At this point, the optimal displacement and deformation information between the two images can be obtained. Therefore, this invention models the translation and deformation information of the images as a four-dimensional vector, which is used as the input to a particle swarm optimization algorithm. A function related to the correlation coefficient is used as the fitness function of the algorithm. By optimizing the four-dimensional vector using the particle swarm optimization algorithm, the specific parameters of speckle pattern displacement and distortion can be identified, greatly improving the calculation accuracy of speckle displacement.

[0055] This invention includes the following steps:

[0056] S1. Data Acquisition: First, install the speckle projection device on the robotic arm, and then collect data.

[0057] The data acquisition in step S1 includes the following steps:

[0058] S11. Install the robotic arm 3, imaging plate 4, and camera 6. Connect camera 6 to the computer.

[0059] S12. Project the prepared speckle pattern 5 onto the target position on the imaging plate 4. The robotic arm 3 moves, and the end of the robotic arm 3 is set as the robotic arm end 2. Control the robotic arm end 2 to always point to the target position on the imaging plate 4.

[0060] A speckle pattern projector 1 is installed on the end effector 2 of the robotic arm for projecting speckle patterns. In this embodiment, the speckle pattern 5 is the speckle pattern itself.

[0061] S13. During the movement of the robotic arm 3, the camera 6 takes pictures and obtains multiple sets of images.

[0062] S2, Error Analysis, i.e., Analysis of the Causes of Distortion.

[0063] The distortion analysis process in step S2 is as follows: Due to the different projection directions of the two projections at the end of the robotic arm 2, the resulting speckle pattern is distorted from a circle to an ellipse with different eccentricities and different major axis directions. At this time, the speckle pattern exhibits distortion in two directions, which changes the pattern information contained in the sub-region and affects the accuracy of the digital image correlation method for displacement calculation through sub-region search.

[0064] In this embodiment, the two directions specifically refer to: the speckle pattern is a planar pattern containing two-dimensional X and Y information. When the eccentricity and major axis direction change, the information contained in both the X and Y dimensions differs from the original pattern. A sub-region means dividing the entire speckle pattern into several square regions of size (2n+1)*(2n+1), where n is an arbitrary value, but the size of 2n+1 must not exceed the side length of the image. Each square region is a sub-region of the pattern. The impact on calculation accuracy refers to the reduction in precision. Specifically, sub-region displacement calculation depends on the correlation, or similarity, between sub-regions of two images. If one image is distorted, the correlation between the sub-regions of the two images will decrease, and the matching accuracy will decline.

[0065] S3. Parametric modeling: Based on the cause analysis in step S2, model the factors that affect the degree of distortion.

[0066] The modeling process in step S3 is as follows:

[0067] S31. Based on the movement pattern of the robotic arm, model the projection of the robotic arm to obtain a three-dimensional image.

[0068] S32. In the XZ plane, the angle between the robotic arm and the normal of the imaging plate is β, and the angle between the projection of the speckle beam in the XY plane and the positive Y-axis is α. When the robotic arm moves according to the programmed path, the angles α and β will change accordingly. The angle α determines the direction of the major axis of the elliptic speckle, and the angle β determines the eccentricity of the elliptic speckle.

[0069] In this embodiment, the XZ plane and XY plane are based on the projection target position selected in S12 as the origin. Within the imaging plate plane, the X-axis and Y-axis are parallel to the boundary of the imaging plate, and the Z-axis is perpendicular to the imaging plate plane. This coordinate system can be defined as a projection coordinate system.

[0070] S33. In images captured from different groups, the differences between speckle patterns can be categorized into four dimensions: the amount of movement along the X-axis, the amount of movement along the Y-axis, the rotation angle α, and the projection angle β. These four vector dimensions are used as four optimization parameters for the particle swarm optimization algorithm.

[0071] S4 uses the particle swarm optimization algorithm to identify the optimal parameters for distorted images.

[0072] The particle swarm optimization algorithm in step S4, which identifies the optimal parameters for distorted images, includes the following steps:

[0073] S41. Calculate the correlation coefficient between the two images, and use 1 - correlation coefficient as the objective function of the particle swarm optimization algorithm.

[0074] The formula for calculating the correlation coefficient of the images is as follows:

[0075]

[0076] The grayscale value of the first image is a. ij Where i = 1, 2, ..., m, j = 1, 2, ..., n (m and n are the total number of rows and columns of the image, respectively); the grayscale value of the second image is b. ij , where i and j represent the number of rows and columns, respectively.

[0077] Since the objective function is continuously reduced through iteration during the particle swarm optimization (PSO) calculation process, CC = 1 - C is chosen as the objective function of this PSO algorithm.

[0078] In this embodiment, 1 - the correlation coefficient is equivalent to CC, which is the objective function of the particle swarm optimization algorithm. During the iteration process, the correlation coefficient C between two images is maximized to achieve higher accuracy in finding the displacement and distortion variables through optimization. However, in particle swarm optimization, it's generally better to minimize the objective function; the goal of optimization is to reduce the objective function as much as possible. Therefore, the correlation coefficient C cannot be directly chosen as the objective function. Instead, a function f(x) related to the correlation coefficient is constructed as the objective function. There are many ways to construct the objective function; choosing f(x) = 1 - C is one method. Any construction method that satisfies the condition of a larger correlation coefficient and a smaller f(x) is acceptable. The correlation coefficient of images describes the similarity between images; a larger correlation coefficient indicates a higher degree of similarity. Since image grayscale information can be viewed as a two-dimensional matrix, the correlation coefficient of images can be represented by the normalized cross-correlation function of the matrix, i.e., formula C, where C ranges from -1 to 1. CC is equivalent to f(x).

[0079] S42. Initialize the particle swarm algorithm by inputting the initial vector into the deformation function for processing.

[0080] The processing procedure in step S42 is as follows:

[0081] S421. Define each four-dimensional particle in a particle swarm as (x... i ,y i ,β i ,α i The velocity is V = (V1, V2, ... V).N ); where x i The distance the image moves along the x-axis is represented by the y-axis. i β represents the distance the image moves along the y-axis. i α represents the projection angle of the image. i The rotation angle of the image is represented by i = 1, 2, ..., N, where N represents the total number of particles.

[0082] S422. Initialize the particle's velocity to V0 = 0; initialize the particle's position P0; set upper and lower limits for the four variables so that the four vectors take random values ​​within different ranges.

[0083] S423. For each particle, process the first image according to the initialized four-dimensional vector P0; translate the first image along the X and Y axes according to the information of the four-dimensional vector P0, rotate the pattern by an angle α, and stretch it in that direction to simulate the projection distortion caused by the angle β, thus obtaining the processed deformed image.

[0084] S424. Calculate the correlation coefficient between the deformed image and the second image to obtain the objective function CC corresponding to the particle.

[0085] S43. Based on the individual optimal position, calculate the global optimal position according to the formula.

[0086] S43 includes the following sub-steps:

[0087] S431. Perform step S42 on all N particles. The position corresponding to the minimum objective function in the history of each particle is regarded as the individual optimal position of that particle. After each iteration, the best position among the individual optimal positions of all particles is regarded as the global optimal position.

[0088] S432. Let P be the optimal position of the currently searched individual. i The currently found global optimum position is denoted as W. i Update the velocity and position of the particle swarm according to the following equations:

[0089] V i (t+1)=c0V i (t)+c1*r1(t)*[P i (t)-X i (t)]+c2*r2(t)*[W i (t)-X i (t)]

[0090] X i (t+1)=X i (t)+V i (t+1)

[0091] Where c0 is the inertia weight, c1 and c2 are learning factors, r1(t) and r2(t) are random numbers between [0,1], and V i The velocity of the particle.

[0092] S433. After the new particle swarm velocity and position are generated, the new four-dimensional vector is used as the input to the deformation function to obtain the new output image and the target function, thus completing the next iteration.

[0093] S44. Calculate whether the objective function is small enough. If it has not reached the minimum value, continue iterating.

[0094] The specific content of step S44 is as follows: Set a cutoff threshold for the objective function. If the objective function is less than the cutoff threshold at the current iteration number, stop the iteration and obtain the four vectors corresponding to the current global optimal position of the particle. When the objective function is greater than the cutoff threshold, continue iterating until the set maximum number of iterations is reached, then end the iteration and obtain the four vectors corresponding to the current global optimal position of the particle.

[0095] In this embodiment, the cutoff threshold refers to the fact that the set objective function f(x) = 1 - C is a number between 0 and 2. Therefore, this cutoff threshold is a number that is near 0 and greater than 0. The specific data depends on the user's needs. The closer it is to 0, the higher the accuracy of the calculation. It is usually a decimal that is greater than 0 and less than 1.

[0096] S5. Obtain the optimal parameters for image translation and deformation.

[0097] Those skilled in the art will recognize that the embodiments described herein are intended to help the reader understand the principles of the invention, and should be understood that the scope of protection of the invention is not limited to such specific statements and embodiments. Those skilled in the art can make various other specific modifications and combinations based on the technical teachings disclosed in this invention without departing from the spirit of the invention, and these modifications and combinations are still within the scope of protection of this invention.

Claims

1. A method for improving the accuracy of speckle displacement detection based on intelligent image distortion recognition, characterized in that, Includes the following steps: S1. Data acquisition: First, install the speckle projection device of the robotic arm, and then acquire data. S2, Error Analysis, i.e., Analysis of the Causes of Distortion; S3. Parametric modeling: Based on the cause analysis in step S2, model the factors that affect the degree of distortion. S4. Particle swarm optimization algorithm to identify the optimal parameters of distorted images; S5. Obtain the optimal parameters for image translation and deformation.

2. The method for improving the accuracy of speckle displacement detection based on intelligent image distortion recognition according to claim 1, characterized in that, The data acquisition in S1 includes the following steps: S11. Install the robotic arm (3), imaging plate (4) and camera (6), and connect the camera (6) to the computer; S12. Project the prepared speckle pattern (5) onto the target position on the imaging plate (4), move the robotic arm (3), set the end of the robotic arm (3) as the robotic arm end (2), and control the robotic arm end (2) to always point to the target position on the imaging plate (4). S13. During the movement of the robotic arm (3), the camera (6) takes pictures and obtains multiple sets of images.

3. The method for improving the accuracy of speckle displacement detection based on intelligent image distortion recognition according to claim 1, characterized in that, The process of analyzing the distortion cause in S2 is as follows: Due to the different projection directions of the two projections of the end of the robotic arm (2), the resulting speckle pattern is distorted from a circle to an ellipse with different eccentricities and different major axis directions. At this time, the speckle pattern is distorted in two directions, which changes the pattern information contained in the sub-region and will affect the accuracy of the digital image correlation method for displacement calculation through sub-region search.

4. The method for improving the accuracy of speckle displacement detection based on intelligent image distortion recognition according to claim 1, characterized in that, The modeling process in S3 is as follows: S31. Based on the way the robotic arm moves, model the projection of the robotic arm to obtain a three-dimensional image; S32. In the XZ plane, the angle between the robotic arm and the normal of the imaging plate is β; the angle between the projection of the speckle beam in the XY plane and the positive direction of the Y axis is α; when the robotic arm moves according to the programmed path, the angles α and β will change accordingly. The angle α determines the direction of the major axis of the elliptic speckle, and the angle β determines the eccentricity of the elliptic speckle. S33. In images obtained from different groups of images, the differences between speckle patterns can be divided into four dimensions: the amount of movement along the X-axis, the amount of movement along the Y-axis, the rotation angle α, and the projection angle β; these four-dimensional vectors are used as four optimization parameters for the particle swarm optimization algorithm.

5. The method for improving the accuracy of speckle displacement detection based on intelligent image distortion recognition according to claim 1, characterized in that, The particle swarm optimization algorithm in S4, and the method for identifying the optimal parameters of distorted images based on this algorithm, includes the following steps: S41. Calculate the correlation coefficient between the two images and use 1 - correlation coefficient as the fitness function of the particle swarm optimization algorithm. The formula for calculating the correlation coefficient of the images is as follows: The grayscale value of the first image is a. ij Where i = 1, 2, ..., m, j = 1, 2, ..., n (m and n are the row and column numbers of the image, respectively); the grayscale value of the second image is b. ij ; Since the fitness function is continuously reduced through iteration during the particle swarm optimization (PSO) calculation process, CC = 1 - C is chosen as the fitness function for this PSO algorithm. S42. Initialize the particle swarm algorithm by inputting the initial vector into the deformation function for processing; S43. Calculate the global optimal position based on the individual optimal position and the formula. S44. Calculate whether the fitness function is small enough. If it has not reached the minimum value, continue iterating.

6. The method for improving the accuracy of speckle displacement detection based on intelligent image distortion recognition according to claim 1, characterized in that, The processing in S42 is as follows: S421. Define each four-dimensional particle in a particle swarm as (x... i ,y i ,β i ,α i The velocity is V = (V1, V2, ... V). N ); where x i The distance the image moves along the x-axis is represented by the y-axis. i β represents the distance the image moves along the y-axis. i α represents the projection angle of the image. i The rotation angle of the image is represented by i = 1, 2, ..., N, where N represents the total number of particles; S422. Initialize the particle's velocity to V0 = 0; initialize the particle's position P0; set upper and lower limits for the four variables so that the four vectors take random values ​​within different ranges. S423. For each particle, process the first image according to the initialized four-dimensional vector P0; translate the first image along the X and Y axes according to the information of the four-dimensional vector P0, rotate the pattern by an angle α, and stretch it in that direction to simulate the projection distortion caused by the angle β, and obtain the processed deformed image. S424. Calculate the correlation coefficient between the deformed image and the second image to obtain the fitness function CC corresponding to the particle.

7. The method for improving the accuracy of speckle displacement detection based on intelligent image distortion recognition according to claim 1, characterized in that, S43 includes the following sub-steps: S431. Perform step S42 on all N particles. The position corresponding to the minimum fitness function in the history of each particle is regarded as the individual optimal position of that particle. After each iteration, the best position among the individual optimal positions of all particles is regarded as the global optimal position. S432. Let P be the optimal position of the currently searched individual. i The currently found global optimum position is denoted as W. i ; Update the velocity and position of the particle swarm according to the following equation: V i (t+1)=c0V i (t)+c1*r1(t)*[P i (t)-X i (t)]+c2*r2(t)*[W i (t)-X i (t)] X i (t+1)=X i (T)+V i (t+1) Where c0 is the inertia weight, c1 and c2 are learning factors, r1(t) and r2(t) are random numbers between [0,1], and V i The velocity of the particle; S433. After the new particle swarm velocity and position are generated, the new four-dimensional vector is used as the input to the deformation function to obtain the new output image and fitness function, thus completing the next iteration.

8. The method for improving the accuracy of speckle displacement detection based on intelligent image distortion recognition according to claim 1, characterized in that, The specific content of S44 is as follows: a cutoff threshold is set for the fitness function. If the fitness function is less than the cutoff threshold at the current iteration number, the iteration stops and the four vectors corresponding to the current global optimal position of the particle are obtained. When the fitness function is greater than the cutoff threshold, the iteration continues until the set maximum iteration number is reached, the iteration ends, and the four vectors corresponding to the current global optimal position of the particle are obtained.