Method for controlling an x-ray inspection device mounted on a drone

CN122983104APending Publication Date: 2026-10-27WUHAN UNIV OF SCI & TECH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611468373.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-09-21
Publication Date
2026-10-27

AI Technical Summary

Technical Problem

[0003]然而,现有无人机挂载X光探伤方案仍面临诸多控制层面的挑战,一方面,无人机在悬停过程中受气流、电机振动等影响,机体姿态波动明显,导致X光发射方向难以持续垂直于待测表面,进而影响射线穿透路径与成像质量;另一方面,未将结构振动特征与碰撞风险关联分析,当无人机因外力或控制失稳而产生大幅抖动时,不仅导致数据重复采集,还可能因误判悬停位置而撞击被测结构表面,造成设备损坏以及产生安全隐患

Benefits of technology

本发明采集无人机机体振动幅值,借助PID控制器实时调控飞行姿态,抑制气流扰动、电机振动带来的姿态波动,保障X光探伤装置的空间位置稳定;通过获取无人机实时空间坐标与姿态角数据,计算缓冲套外壁与待测目标表面的相对夹角,并以此调节X光发射方向,使射线中心垂直入射待测表面,校正悬停偏移、姿态倾斜引发的射线方向偏差,保证X光最优入射穿透效果,提升探测数据的有效性、一致性以及成像质量,本发明比对实时探伤信号强度与预设标准信号强度,信号偏差超出允许误差时动态调整探伤调控参数,适配现场复杂工况,将调控参数与无人机空间坐标关联生成初步缺陷区域,为缺陷识别提供空间先验信息,缩减无效探测范围,提升数据采集的针对性与作业效率。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122983104A_ABST
    Figure CN122983104A_ABST
Patent Text Reader

Abstract

The application provides a kind of unmanned plane mounted X-ray flaw detection device control optimization method, it is related to unmanned plane control technical field, the application is by PID controller real-time adjustment unmanned plane attitude to restrain body vibration;Real-time positioning unmanned plane coordinates and collect attitude angle, calculate the relative angle of X-ray device buffer sleeve outer wall and the surface to be measured, adjust the emission direction according to the standard value deviation of flaw detection signal intensity and make it perpendicular to target surface;According to the standard value deviation of flaw detection signal intensity and tube voltage and tube current are adjusted, and combined with space coordinates generate preliminary defect area;Collect target surface image and preliminary defect area fusion determine final defect area, while judging collision risk based on vibration amplitude change rate;When there is collision risk and not complete flaw detection, adjust PID parameters and drive buffer sleeve folding deformation, until unmanned plane restores to safe state.The application effectively improves the defect positioning accuracy in X-ray flaw detection process, and reduces the collision risk of unmanned plane and measured structure.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of unmanned aerial vehicle (UAV) control technology, specifically to a control optimization method for an X-ray flaw detection device mounted on a UAV. Background Technology

[0002] In recent years, drone technology has received widespread attention in the field of infrastructure flaw detection, especially in structural health monitoring in high-altitude or hazardous environments, where drones equipped with non-destructive testing equipment have become an important development direction. X-ray flaw detection, due to its high sensitivity to internal defects, is gradually being integrated into drone platforms to achieve remote, efficient, and non-contact defect identification. Currently, some technologies attempt to fix X-ray emitters to the drone fuselage, enabling pinpoint detection via ground remote control or preset flight paths, and achieving a degree of automation in data acquisition.

[0003] However, existing UAV-mounted X-ray flaw detection solutions still face many challenges at the control level. On the one hand, the UAV's attitude fluctuates significantly during hovering due to airflow and motor vibration, making it difficult for the X-ray emission direction to remain perpendicular to the surface being tested, thus affecting the X-ray penetration path and imaging quality. On the other hand, the structural vibration characteristics are not correlated with collision risks. When the UAV shakes significantly due to external forces or control instability, it not only leads to repeated data collection but may also cause collisions with the surface of the tested structure due to misjudgment of the hovering position, resulting in equipment damage and safety hazards.

[0004] The information disclosed in the background section is only intended to enhance the understanding of the background of this disclosure, and therefore may include information that does not constitute prior art known to those skilled in the art. Summary of the Invention

[0005] The purpose of this invention is to provide a control optimization method for an X-ray flaw detection device mounted on an unmanned aerial vehicle (UAV) to solve the problems mentioned in the background art.

[0006] To achieve the above objectives, the present invention provides the following technical solution: A method for controlling and optimizing an X-ray flaw detection device mounted on a drone, comprising the following steps: Step 1: Real-time acquisition of the vibration amplitude of the UAV equipped with the X-ray flaw detection device during flight, and real-time adjustment of the UAV's flight attitude through a PID controller; Step 2: After the UAV flies to the flaw detection area, it remains hovering. At the same time, the UAV's spatial coordinates are located in real time, and the UAV's attitude angle data is collected. The relative angle between the outer wall of the buffer sleeve of the X-ray flaw detection device and the surface of the target to be tested is calculated. Based on the relative angle, the emission direction of the X-ray flaw detection device is adjusted so that its ray center is perpendicular to the surface of the target to be tested. Step 3: Acquire the signal strength returned by the X-ray flaw detection device in real time, compare it with the preset standard signal strength, and if the difference between the two exceeds the allowable error value, adjust the control parameters of the X-ray flaw detection device in real time, and generate a preliminary defect area based on the real-time spatial coordinates of the UAV and the control parameters. Step 4: Collect surface image data of the target to be tested, fuse it with the data of the preliminary defect area, determine the final defect area, calculate the vibration amplitude change rate based on the vibration amplitude change rate of the current acquisition time and the previous acquisition time, and determine whether the UAV has a collision risk based on the vibration amplitude change rate. Step 5: When there is a collision risk to the drone, determine the location of the collision risk. Based on the defect area and the location of the collision risk, determine whether the flaw detection data acquisition has been completed. If it has been completed, the drone is instructed to return to base. If it has not been completed, the control parameters of the PID controller are adjusted, and the matching buffer sleeve is folded and deformed until the rate of change of the vibration amplitude of the drone body recovers to below the safe rate of change threshold. Then, the drone is re-hovered on the surface of the target to be tested to continue the flaw detection task.

[0007] Furthermore, the principle of real-time adjustment of the UAV's flight attitude using a PID controller is as follows: The vibration deviation value is obtained by taking the absolute value of the difference between the body vibration amplitude and the preset hovering stability amplitude. The vibration deviation value is input to the proportional unit, integral unit and derivative unit of the PID controller respectively, which generate the real-time proportional control component, the historical cumulative integral control component and the derivative control component of the vibration change trend respectively. The proportional control component, integral control component and derivative control component are added together to generate the motor speed regulation. The motor speed adjustment is converted into a speed drive signal for each fan blade motor. The speed of each fan blade is adjusted by the speed drive signal so that the vibration amplitude of the machine body is less than or equal to the preset hovering stability amplitude.

[0008] Furthermore, the principle for calculating the relative angle between the outer wall of the buffer sleeve of the X-ray flaw detection device and the surface of the target object by real-time positioning of the UAV's spatial coordinates and collecting the UAV's attitude angle data is as follows: A global coordinate system is established with a preset ground reference point as the origin. The X-axis and Y-axis of the global coordinate system are located in the horizontal plane and are perpendicular to each other. The positive direction of the Z-axis is upward along the direction of gravity and is perpendicular to the horizontal plane where the X-axis and Y-axis are located. A local coordinate system is established with the center of mass of the UAV as the origin. The X-axis, Y-axis and Z-axis are set with the horizontal axis, vertical axis and vertical axis of the UAV body, respectively. When the UAV hovers over the flaw detection area, the coordinates of the UAV in the global coordinate system are obtained, and the attitude angle data of the UAV is obtained through the local coordinate system. The attitude angle data includes pitch angle, roll angle and yaw angle. At the hovering position, multi-point ranging is performed on the surface of the target to be measured. Based on the ranging results, a local surface point cloud is generated in real time. Based on the local surface point cloud, the normal direction vector of the target surface in the global coordinate system is determined. Based on attitude angle data, the directions of each coordinate axis in the local coordinate system are transformed to the global coordinate system to obtain the real-time outward normal direction vector of the UAV in the global coordinate system; The spatial dot product of the normal direction vector of the target surface in the global coordinate system and the real-time outward normal direction vector of the UAV in the global coordinate system is performed to obtain the spatial angle between the two vectors, which is the relative angle.

[0009] Furthermore, the principle of adjusting the emission direction of the X-ray flaw detection device based on the relative angle is as follows: The relative angle is decomposed into pitch deviation angle and yaw deviation angle around the horizontal axis of the local coordinate system. PID control calculations are performed on the pitch deviation angle and yaw deviation angle to generate pitch adjustment component and yaw adjustment component. The pitch adjustment component and yaw adjustment component are used as adjustment signals to drive the X-ray flaw detection device to rotate around the horizontal axis and vertical axis of the local coordinate system by the corresponding angles, so that the center of the X-ray emission ray is perpendicular to the surface of the target to be measured.

[0010] Furthermore, the principle of adjusting the control parameters of the X-ray flaw detection device in real time and generating a preliminary defect area based on the real-time spatial coordinates of the UAV and the control parameters is as follows: The control parameters include tube voltage and tube current; The real-time intensity deviation is obtained by subtracting the real-time flaw detection signal intensity value of the X-ray flaw detection device from the standard signal intensity value preset for the material and thickness of the target. If the absolute value of the real-time strength deviation is greater than the preset allowable error value, then the real-time strength deviation is used as the input variable of the PID controller, and the transistor voltage regulation signal and transistor current regulation signal are generated in sequence through proportional amplification, integral accumulation and derivative prediction. After the control parameters stabilize, the real-time three-dimensional coordinates of the UAV in the global coordinate system are collected, and the real-time three-dimensional coordinates at the same collection time are bound with the control parameters to form working point data with spatial location labels. The real-time three-dimensional coordinates corresponding to the working point data are projected along the normal direction of the surface of the target to be tested. The projection point is taken as the initial screening suspicious point. The initial screening detection area is defined with the initial screening suspicious point as the center and the X-ray coverage radius of the X-ray flaw detection device under the current control parameters. All the initial screening suspicious points and their corresponding initial screening detection areas are summarized to form the preliminary defect area.

[0011] Furthermore, the principle of acquiring surface image data of the target to be tested, fusing it with the data of the preliminary defect area, and determining the final defect area is as follows: The visible light image and infrared thermal image of the target surface are acquired in real time while the drone is hovering. The visible light image and infrared thermal image are then registered at the pixel level to generate fused surface image data. Surface anomalous regions are extracted from the fused surface image data. These anomalous regions include crack textures and peeling areas in visible light images, as well as temperature anomalous regions in infrared thermal imaging images. The surface anomalous regions are spatially located in a global coordinate system to generate a set of surface defect regions. The spatial overlap between the set of surface defect regions and each initial screening detection region in the preliminary defect region is calculated, and the preliminary defect regions with spatial overlap exceeding the preset overlap threshold are determined as the final defect regions. Specifically, the image detection area is defined based on the real-time ray coverage radius of the X-ray flaw detection device, the intersection area of ​​the initial screening detection area and each image detection area in the global coordinate system is solved, and the spatial overlap is obtained by dividing the area of ​​the intersection area by the area of ​​the initial screening detection area.

[0012] Furthermore, the principle for determining whether a drone poses a collision risk based on the rate of change of vibration amplitude is as follows: At each acquisition time, the vibration amplitude of the machine body at the current acquisition time and the vibration amplitude of the machine body at the previous acquisition time are obtained. The absolute value of the difference between the two is calculated and then divided by the vibration amplitude of the machine body at the previous acquisition time to obtain the rate of change of vibration amplitude at the current acquisition time. The vibration amplitude change rate is compared with a preset safe change rate threshold. When the vibration amplitude change rate is less than the preset safe change rate threshold, the drone is judged to have no collision risk. When the vibration amplitude change rate is greater than or equal to the preset safe change rate threshold, the drone is judged to have a collision risk.

[0013] Furthermore, the principle for determining whether flaw detection data acquisition has been completed based on the defect area and the location of collision risk is as follows: When it is determined that the drone has a collision risk, the real-time three-dimensional coordinates of the drone at the current acquisition time and the previous acquisition time are obtained, the real-time trajectory vector of the drone is generated, the spatial intersection of the real-time trajectory vector and the surface of the target to be measured is judged, and the intersection point of the real-time trajectory vector and the surface of the target to be measured is taken as the collision risk location. The defect regions from multiple consecutive acquisition times prior to the current acquisition time are acquired. The defect regions are arranged in chronological order of acquisition times to form a defect region detection sequence. The area overlap of the last defect region in the defect region detection sequence with the defect region at the current acquisition time is calculated. The collision risk location is compared with the defect region at the current acquisition time in terms of spatial location to determine whether the collision risk location is located inside the boundary of the defect region or whether the distance from the boundary of the defect region is less than a preset influence distance threshold. If the area overlap is greater than the preset area overlap threshold, and the collision risk location is outside the defect area at the current acquisition time, or the distance from the defect area boundary is greater than or equal to the preset influence distance threshold, then the data acquisition is considered complete; otherwise, the data acquisition is considered incomplete.

[0014] Furthermore, the principle of adjusting the control parameters of the PID controller and causing the matching buffer sleeve to fold and deform until the rate of change of the vibration amplitude of the machine body recovers to below the safe rate of change threshold is as follows: When data acquisition is deemed incomplete, the vibration amplitude of the machine body at the current acquisition moment is compared with that at the previous acquisition moment. The difference in vibration amplitude is calculated and compared with a preset difference threshold. If the difference in vibration amplitude is greater than the preset difference threshold, the proportional coefficient of the PID controller is increased while the integral coefficient of the PID controller is decreased to generate adjusted PID control parameters. If the difference in vibration amplitude is less than or equal to the preset difference threshold, the derivative coefficient of the PID controller is increased to generate adjusted PID control parameters. The adjusted PID control parameters replace the current PID control parameters, and the adjusted PID control parameters are used to generate speed drive signals to adjust the speed of each fan blade. At the same time, a folding command is sent to the folding drive component of the matching buffer sleeve. During the folding process of the matching buffer sleeve, the vibration amplitude of the machine body is continuously collected in real time and the rate of change of the vibration amplitude of the machine body is calculated until the rate of change of the vibration amplitude of the machine body recovers to less than the preset safe rate of change threshold, and the matching buffer sleeve stops folding.

[0015] Compared with the prior art, the beneficial effects of the present invention are: This invention collects the vibration amplitude of a UAV body and uses a PID controller to adjust the flight attitude in real time, suppressing attitude fluctuations caused by airflow disturbances and motor vibrations, thus ensuring the spatial stability of the X-ray flaw detection device. By acquiring the UAV's real-time spatial coordinates and attitude angle data, the relative angle between the outer wall of the buffer sleeve and the surface of the target under test is calculated, and the X-ray emission direction is adjusted accordingly to ensure that the center of the ray is perpendicular to the surface under test. This corrects for ray direction deviations caused by hovering offset and attitude tilt, ensuring optimal X-ray incident penetration effect and improving the effectiveness, consistency, and imaging quality of the detection data. This invention compares the real-time flaw detection signal strength with the preset standard signal strength. When the signal deviation exceeds the allowable error, the flaw detection control parameters are dynamically adjusted to adapt to complex on-site conditions. The control parameters are correlated with the UAV's spatial coordinates to generate a preliminary defect area, providing spatial prior information for defect identification, reducing the invalid detection range, and improving the targeting and efficiency of data acquisition.

[0016] Furthermore, this invention fuses the surface image data of the target under test with the preliminary defect area to obtain the final defect area, improving the anti-interference capability and spatial positioning accuracy of defect judgment; using the change rate of body vibration amplitude as a quantitative criterion to identify collision risks, it can detect the trend of the UAV abnormally approaching the structure under test in advance, realizing real-time risk warning. When a collision risk is detected and the flaw detection task has not been completed, this invention adjusts the control parameters of the PID controller, and with the buffer sleeve folding deformation buffer protection, the flaw detection operation can continue after the vibration recovers to the safe threshold. This not only ensures the integrity and continuity of the flaw detection data, but also avoids the risk of impact damage under close-range operation, significantly improving the safety of flaw detection operations and the success rate of task completion under complex working conditions. Attached Figure Description

[0017] Figure 1 This is a flowchart illustrating the control optimization method for the X-ray flaw detection device mounted on an unmanned aerial vehicle (UAV) according to the present invention. Figure 2 This is a schematic diagram showing the changes in the vibration amplitude and motor speed adjustment of the present invention as a function of the data collection time. Detailed Implementation

[0018] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to specific embodiments.

[0019] It should be noted that, unless otherwise defined, the technical or scientific terms used in this invention should have the ordinary meaning understood by one of ordinary skill in the art to which this invention pertains. The terms "first," "second," and similar terms used in this invention do not indicate any order, quantity, or importance, but are merely used to distinguish different components. Terms such as "comprising" or "including" mean that the element or object preceding the word encompasses the elements or objects listed following the word and their equivalents, without excluding other elements or objects. Terms such as "connected" or "linked" are not limited to physical or mechanical connections, but can include electrical connections, whether direct or indirect. Terms such as "upper," "lower," "left," and "right" are used only to indicate relative positional relationships; when the absolute position of the described object changes, the relative positional relationship may also change accordingly.

[0020] Example: Please see Figures 1 to 2 The present invention provides a technical solution: A method for controlling and optimizing an X-ray flaw detection device mounted on a drone, comprising the following steps: Step 1: Real-time acquisition of the vibration amplitude of the UAV equipped with the X-ray flaw detection device during flight, and real-time adjustment of the UAV's flight attitude through a PID controller; In this embodiment, the principle of real-time adjustment of the UAV's flight attitude using a PID controller is as follows: The vibration deviation value is obtained by taking the absolute value of the difference between the body vibration amplitude and the preset hovering stability amplitude. A triaxial accelerometer is installed at the center of mass of the UAV to measure the acceleration of the UAV in the X, Y, and Z directions. The acceleration is integrated to obtain the displacement amplitude of the UAV in the X, Y, and Z directions. The composite vector magnitude of the displacement amplitude in the three directions is taken as the vibration amplitude of the UAV. The vibration deviation value is obtained by subtracting the vibration amplitude from the preset hovering stability amplitude and taking the absolute value. The preset hovering stability amplitude is the vibration amplitude of the UAV when it maintains stable hovering under windless and undisturbed conditions, representing the target value of the UAV's vibration amplitude. The vibration deviation value reflects the degree of deviation of the current vibration of the UAV from the ideal stable state. The larger the vibration deviation value, the farther the current vibration amplitude deviates from the ideal state, the more unstable the UAV attitude, affecting the X-ray emission direction and increasing the risk of collision. The smaller the vibration deviation value, the closer the UAV is to a stable hovering state, and the more stable the UAV attitude.

[0021] The vibration deviation value is input to the proportional unit, integral unit and derivative unit of the PID controller respectively, which generate the real-time proportional control component, the historical cumulative integral control component and the derivative control component of the vibration change trend respectively. The proportional control component, integral control component and derivative control component are added together to generate the motor speed regulation. It should be noted that the vibration deviation value is fed into three independent units of the PID controller, each generating a control component. Specifically, in the proportional unit, the vibration deviation value is multiplied by a proportional coefficient to generate a real-time proportional control component. This component is proportional to the vibration deviation value and is used for rapid response to instantaneous vibration conditions; the larger the vibration deviation value, the larger the adjustment amplitude. In the integral unit, the vibration deviation value is accumulated over time and multiplied by an integral coefficient to generate a historically accumulated integral control component, used to eliminate long-term static deviations during long-term UAV flights. In the derivative unit, the rate of change of the current vibration deviation value relative to the previous moment is calculated and multiplied by a derivative coefficient to generate a derivative control component reflecting the vibration change trend, used to predict the deviation change trend.

[0022] The motor speed adjustment is a percentage of the base motor speed, where the base motor speed is the average value of each motor speed after the UAV enters the flaw detection area and first reaches a stable hovering state.

[0023] The motor speed adjustment is converted into a speed drive signal for each fan blade motor. The speed of each fan blade is adjusted by the speed drive signal so that the vibration amplitude of the machine body is less than or equal to the preset hovering stability amplitude.

[0024] The preset hovering stability amplitude is used to determine whether the real-time body vibration amplitude has been adjusted to an acceptable stable range. When the body vibration amplitude is less than or equal to the preset hovering stability amplitude, it is considered that the real-time body vibration amplitude can meet the requirements for stable hovering. The PID control maintains the current output and no further adjustment is needed. The principle is to allow the real-time body vibration amplitude to fluctuate slightly around the body vibration amplitude in the stable hovering state. The preset hovering stability amplitude is set to 10% to 20% of the absolute value of the difference between the real-time body vibration amplitude and the body vibration amplitude in the stable hovering state. The higher the preset hovering stability amplitude, the less sensitive it is to vibration. PID control is only applied when the deviation is large, resulting in decreased hovering stability. The lower the preset hovering stability amplitude, the more PID control is applied when there is a small deviation. The adjustment frequency is high, and the UAV is strictly constrained to a range close to the ideal amplitude. The attitude fluctuation is minimal, and the hovering accuracy is high, but this will lead to increased power consumption and misadjustment. Table 1 is constructed to characterize the changes in body vibration amplitude and motor speed adjustment at each acquisition time, as follows: Table 1. Changes in body vibration amplitude and motor speed adjustment Table 1 reflects the process and dynamic characteristics of the PID controller's attitude adjustment for the UAV. The preset hovering stability amplitude is 2.0 mm. At the initial acquisition time, the body vibration amplitude is 5.80 mm, far exceeding the preset hovering stability amplitude. At this time, the motor speed adjustment increases rapidly, indicating that the proportional control of the PID controller responds strongly to large deviations and outputs a large adjustment amount to quickly offset the vibration. As the adjustment process continues, the vibration amplitude steadily decreases, while the motor speed adjustment decreases, reflecting that as the deviation decreases, the proportional control component weakens, but the integral component continues to accumulate to maintain the adjustment strength. When the acquisition time is 12 seconds, the body vibration amplitude further decreases. At this time, the derivative component intervenes to prevent the amplitude from decreasing excessively, and the rate of decrease in the adjustment amount slows down. Later, the body vibration amplitude stabilizes at around 2.0 mm, indicating that the PID controller has successfully adjusted the attitude to a stable hovering state. Subsequently, only a very small continuous adjustment amount is needed to overcome environmental disturbances and keep the amplitude fluctuating within the allowable range.

[0025] Figure 2 The curves showing the changes in body vibration amplitude and motor speed adjustment as of the time of data acquisition are plotted based on Table 1. Figure 2 As can be seen, the curve's variation pattern corresponds perfectly with the data in Table 1.

[0026] Step 2: After the UAV flies to the flaw detection area, it remains hovering. At the same time, the UAV's spatial coordinates are located in real time, and the UAV's attitude angle data is collected. The relative angle between the outer wall of the buffer sleeve of the X-ray flaw detection device and the surface of the target to be tested is calculated. Based on the relative angle, the emission direction of the X-ray flaw detection device is adjusted so that its ray center is perpendicular to the surface of the target to be tested. In this embodiment, the principle of calculating the relative angle between the outer wall of the buffer sleeve of the X-ray flaw detection device and the surface of the target being tested by real-time positioning of the UAV's spatial coordinates and collecting the UAV's attitude angle data is as follows: A global coordinate system is established with a preset ground reference point as the origin. The X-axis and Y-axis of the global coordinate system are located in the horizontal plane and are perpendicular to each other. The positive direction of the Z-axis is upward along the direction of gravity and is perpendicular to the horizontal plane where the X-axis and Y-axis are located. A local coordinate system is established with the center of mass of the UAV as the origin. The X-axis, Y-axis and Z-axis are set with the horizontal axis, vertical axis and vertical axis of the UAV body, respectively. The global coordinate system is used to describe the absolute position of the UAV in the air and the absolute orientation of the target surface. The local coordinate system rotates as the UAV's attitude changes and is used to describe the UAV's tilt and yaw states.

[0027] As one implementation method, the X-ray flaw detection device is equipped with a Kresling origami buffer sleeve. The substrate is processed into a ring-shaped sleeve according to the Kresling folding pattern and wrapped around the outside of each UAV blade. It rotates synchronously with the blade. When it is hit by a collision, its folded structure deforms to absorb the impact force, thereby achieving buffer protection for the blade.

[0028] When the UAV hovers over the flaw detection area, the coordinates of the UAV in the global coordinate system are obtained, and the attitude angle data of the UAV is obtained through the local coordinate system. The attitude angle data includes pitch angle, roll angle and yaw angle. The attitude angles of the UAV are measured by an airborne inertial measurement unit. The pitch angle represents the tilt angle of the fuselage longitudinal axis relative to the horizontal plane, the roll angle represents the rotation angle of the fuselage transverse axis around the fuselage longitudinal axis, and the yaw angle represents the angle between the projection of the fuselage longitudinal axis onto the horizontal plane and the X-axis of the global coordinate system.

[0029] At the hovering position, multi-point ranging is performed on the surface of the target to be measured. Based on the ranging results, a local surface point cloud is generated in real time. Based on the local surface point cloud, the normal direction vector of the target surface in the global coordinate system is determined. Multiple non-collinear scattered points are selected on the surface of the target to be measured. After the UAV hovers, the distance to each scattered point on the surface of the target to be measured is measured at the hovering position using an airborne laser rangefinder, and the coordinates of each scattered point in the global coordinate system are recorded. Based on the coordinates of each scattered point, a local surface point cloud is obtained by least squares plane fitting. The specific steps are as follows: Suppose that the local surface point cloud contains There are points, and the coordinates of each point in the local coordinate system are . ,in, Represents the index of the point, and , Indicates the number of points. They represent the first The x-coordinate, y-coordinate, and y-coordinate of each point; the formula used to calculate the centroid coordinates of the local surface point cloud is: in, These represent the x-coordinate, y-coordinate, and y-coordinate of the centroid of the local surface point cloud, respectively. The covariance matrix is ​​constructed based on the centroid coordinates, specifically as follows: in, Represent the covariance matrix; The covariance matrix is ​​decomposed into eigenvalues ​​to obtain three eigenvalues ​​from largest to smallest and their corresponding eigenvectors. The eigenvector corresponding to the smallest eigenvalue is selected as the normal direction vector.

[0030] Based on attitude angle data, the directions of each coordinate axis in the local coordinate system are transformed to the global coordinate system to obtain the real-time outward normal direction vector of the UAV in the global coordinate system; Based on the attitude angle of the UAV, a rotation matrix is ​​constructed as follows: in, Represents the rotation matrix. This indicates a rotation angle about the Z-axis of the local coordinate system. The rotation matrix at time, Indicates the yaw angle. This indicates a rotation angle about the Y-axis of the local coordinate system. The rotation matrix at time, Indicates pitch angle, This indicates a rotation angle about the X-axis of the local coordinate system. The rotation matrix at time, Indicates the roll angle; Multiplying the direction vector in the local coordinate system by the rotation matrix yields the outward normal direction vector in the global coordinate system.

[0031] The spatial dot product of the normal direction vector of the target surface in the global coordinate system and the real-time outward normal direction vector of the UAV in the global coordinate system is performed to obtain the spatial angle between the two vectors, which is the relative angle.

[0032] It should be noted that the relative angle reflects the spatial deviation between the central ray direction of the UAV's X-ray emitting device and the normal direction of the target surface under real-time UAV attitude. The normal direction of the target surface represents the ideal incident direction of the X-ray, i.e., perpendicular incident, while the external normal direction of the UAV represents the actual direction of the X-ray. The larger the relative angle, the more the X-ray emission direction deviates from the perpendicular incident, resulting in a longer X-ray penetration path and a decrease in imaging quality.

[0033] The principle of adjusting the emission direction of an X-ray flaw detector based on the relative angle is as follows: The relative angle is decomposed into pitch deviation angle and yaw deviation angle around the horizontal axis of the local coordinate system. PID control calculations are performed on the pitch deviation angle and yaw deviation angle to generate pitch adjustment components and yaw adjustment components. These components are used as adjustment signals to drive the X-ray flaw detector to rotate around the horizontal axis of the local coordinate system by the corresponding angle, and to drive the X-ray flaw detector to rotate around the vertical axis of the local coordinate system by the corresponding angle, so that the center of the X-ray emission ray is perpendicular to the surface of the target to be measured.

[0034] The relative angle is the vector angle in three-dimensional space. Since the X-ray emitter of a UAV only has two degrees of freedom—the X-axis and Y-axis—around the local coordinate system, the relative angle is decomposed into two mutually orthogonal deviation angles. Based on the rotation matrix, the normal direction vector in the global coordinate system is transformed to the local coordinate system. The calculation formula is as follows: in, This represents the normal direction vector in the local coordinate system. This represents the normal direction vector in the global coordinate system. The matrix representing the inverse of the rotation matrix; and ,in, These represent the projection components of the normal direction vector in the local coordinate system onto the X, Y, and Z axes of the local coordinate system, respectively. Pitch deviation angle is The angle between the projection onto the local coordinate system YOZ plane and the Z-axis is determined by the following formula: in, Indicates the pitch deviation angle; Yaw deviation angle is The angle between the projection onto the local coordinate system XOZ plane and the Z-axis is determined by the following formula: in, Indicates the yaw deviation angle; The pitch and yaw angles are used as input signals for two independent PID controllers, and the control objective is to bring the pitch angles close to 0, outputting pitch and yaw adjustment components respectively.

[0035] Step 3: Acquire the signal strength returned by the X-ray flaw detection device in real time, compare it with the preset standard signal strength, and if the difference between the two exceeds the allowable error value, adjust the control parameters of the X-ray flaw detection device in real time, and generate a preliminary defect area based on the real-time spatial coordinates of the UAV and the control parameters. In this embodiment, the principle of adjusting the control parameters of the X-ray flaw detection device in real time and generating a preliminary defect area based on the real-time spatial coordinates of the UAV and the control parameters is as follows: The control parameters include tube voltage and tube current; It should be noted that the tube voltage determines the maximum energy of X-ray photons, affecting the attenuation of X-rays in materials and the penetration depth. When the UAV detects targets of different thicknesses and materials, the tube voltage needs to be adjusted in real time to ensure sufficient penetration and avoid overexposure and insufficient penetration. The tube current determines the X-ray photon flux. When the hovering distance of the UAV fluctuates or the surface reflection conditions change, the tube current is adjusted to compensate for signal attenuation and ensure that the flaw detection data has sufficient contrast and resolution. Therefore, the control parameters are set as tube voltage and tube current, forming a two-dimensional control of intensity and energy.

[0036] The real-time intensity deviation is obtained by subtracting the real-time flaw detection signal intensity value of the X-ray flaw detection device from the standard signal intensity value preset for the material and thickness of the target. The principle of preset standard signal intensity values ​​is as follows: In a laboratory environment, a standard test block with the same material and thickness as the target to be tested is selected. Several typical working conditions are divided according to the tube voltage and tube current values ​​of the X-ray flaw detection device. Under each typical working condition, multiple radiographic tests are performed through the X-ray flaw detection device in a direction perpendicular to the surface of the standard test block. The X-ray signal intensity, as well as the corresponding tube current and tube voltage, are recorded during each radiographic test. The average value of the X-ray signal intensity of all radiographic tests under the same material and thickness is taken to obtain the standard signal intensity value for the corresponding material and thickness. The radiographic tests and standard signal intensity value calculations are repeated under different thicknesses and different materials to obtain the correspondence between thickness, material and standard signal intensity value. During actual flaw detection operations, the standard signal intensity value is retrieved from the correspondence based on the known material and thickness information of the target to be tested.

[0037] If the absolute value of the real-time strength deviation is greater than the preset allowable error value, then the real-time strength deviation is used as the input variable of the PID controller, and the transistor voltage regulation signal and transistor current regulation signal are generated in sequence through proportional amplification, integral accumulation and derivative prediction. Under a given material and thickness, multiple repeated tests are performed, recording the deviation of the signal intensity from the standard signal intensity value for each test. The mean and standard deviation of these deviations are calculated. A preset allowable error value is set to k times the mean plus the standard deviation, where k represents the confidence coefficient. The probability that the deviation falls within the range of k times the mean plus the standard deviation and k times the mean minus the standard deviation is determined by k. k represents the probability that normal fluctuations will not be misjudged as events requiring adjustment. The smaller the value of k, the more sensitive it is to deviations, allowing for more frequent adjustments, but it is also more susceptible to noise interference. The larger the value, the more stable the control, but the more delayed the response to actual defects. As an implementation method, the value range is 2 to 3. When k=2, it corresponds to a 95% confidence level, and the probability of one-sided out-of-range error is 2.5%, which means there is a 2.5% probability of exceeding the allowable error range. This is suitable for scenarios where false alarms are not sensitive. When k=3, it corresponds to a 99.7% confidence level, and the probability of one-sided out-of-range error is 0.15%, which means there is a 0.15% probability of exceeding the allowable error range. This is suitable for precision flaw detection scenarios where high data stability is required.

[0038] Real-time intensity deviation is a direct indicator of X-ray penetration effect. Both tube voltage and tube current affect this indicator. Therefore, the real-time intensity deviation value is used as the output variable of the PID controller to ensure coordinated adjustment of tube voltage and tube current. Tube voltage mainly affects X-ray energy, while tube current mainly affects photon flux. Since their physical effects are different, PID parameters are set separately to match dynamic response characteristics. Specifically, the proportional coefficient in the tube voltage control process is larger to emphasize the lack of rapid response penetration, the integral coefficient is smaller to eliminate static deviation, and the derivative coefficient is smaller to reduce noise interference. In the tube current control process, the proportional coefficient is smaller to prevent overshoot, the integral coefficient is larger to smooth and compensate for signal attenuation, and the derivative coefficient is smaller to avoid high-frequency jitter.

[0039] Output the tube voltage adjustment signal and the tube current adjustment signal respectively. Add the tube voltage adjustment signal and the tube current adjustment signal to the original tube voltage and tube current respectively to obtain the new tube voltage and tube current.

[0040] After the control parameters stabilize, the real-time three-dimensional coordinates of the UAV in the global coordinate system are collected, and the real-time three-dimensional coordinates at the same collection time are bound with the control parameters to form working point data with spatial location labels. The real-time three-dimensional coordinates corresponding to the working point data are projected along the normal direction of the surface of the target to be tested. The projection point is taken as the initial screening suspicious point. The initial screening detection area is defined with the initial screening suspicious point as the center and the X-ray coverage radius of the X-ray flaw detection device under the current control parameters. All the initial screening suspicious points and their corresponding initial screening detection areas are summarized to form the preliminary defect area.

[0041] It should be noted that "stable control parameters" means that after the tube voltage and tube current of the X-ray flaw detection device are adjusted by PID, the absolute value of the deviation between the real-time flaw detection signal intensity and the preset standard signal brightness is maintained within the preset allowable error value. At this time, it is considered that the detection condition has adapted to the surface condition of the target. The real-time three-dimensional coordinates of the UAV in the global coordinate system are collected and orthogonally projected along the normal direction of the surface to be tested. The position of the projection point in the global coordinate system is calculated. This point is used as the initial suspicious point, representing the theoretical irradiation center of the X-ray on the target surface. A circular initial screening detection area is delineated. The X-ray signal in the initial screening detection area may have abnormal attenuation or enhancement. All the initial suspicious points and their corresponding initial screening detection areas are summarized to form a preliminary defect area composed of multiple spatially discrete areas. This provides a priority spatial candidate area for subsequent image fusion judgment, so as to narrow down the fine recognition range.

[0042] Step 4: Collect surface image data of the target to be tested, fuse it with the data of the preliminary defect area, determine the final defect area, calculate the vibration amplitude change rate based on the vibration amplitude change rate of the current acquisition time and the previous acquisition time, and determine whether the UAV has a collision risk based on the vibration amplitude change rate. In this embodiment, the principle of acquiring surface image data of the target to be tested, fusing it with data from the preliminary defect area, and determining the final defect area is as follows: The visible light image and infrared thermal image of the target surface are acquired in real time while the drone is hovering. The visible light image and infrared thermal image are then registered at the pixel level to generate fused surface image data. A visible light camera and an infrared thermal imager are mounted on a drone to acquire visible light images and infrared thermal images respectively. The intrinsic parameters of the visible light camera and the infrared thermal imager, as well as the rotation and translation extrinsic parameters between them, are obtained in advance. Then, at each acquisition moment, the rotation and translation extrinsic parameters are used to project the coordinates of each pixel of the infrared image onto the coordinate system of the visible light image. The mutual information maximization criterion is used to perform small translation and rotation fine-tuning on the projected infrared image to make the visible light image and the infrared thermal image spatially aligned.

[0043] Extract surface anomaly regions from fused surface image data, including crack and peeling regions in visible light images and temperature anomaly regions in infrared thermal imaging images. Spatially locate the surface anomaly regions in the global coordinate system to generate a set of surface defect regions. The spatial overlap between the set of surface defect regions and each initial screening detection region in the preliminary defect region is calculated, and the preliminary defect regions with spatial overlap exceeding the preset overlap threshold are determined as the final defect regions. Specifically, the image detection area is defined based on the real-time ray coverage radius of the X-ray flaw detection device, the intersection area of ​​the initial screening detection area and each image detection area in the global coordinate system is solved, and the spatial overlap is obtained by dividing the area of ​​the intersection area by the area of ​​the initial screening detection area.

[0044] Spatial overlap reflects the degree of physical overlap in three-dimensional space between anomaly regions caused by X-ray signals and those caused by images. It serves as a measure of the consistency between two independent detection methods for the same defect region. X-ray inspection can penetrate materials to detect internal defects, but it is susceptible to attitude shifts and distance fluctuations, potentially generating false signals. Visible light and infrared images can identify surface cracks and temperature anomalies, but they cannot reflect internal structures. When the anomaly regions identified by these two detection methods highly overlap, it indicates a very high probability that a real defect exists in that region. The preset overlap threshold range is... , which represents the minimum acceptable spatial confidence level. The larger the threshold, the more stringent the defect detection confirmation, but the more likely it is to miss real defects. The smaller the threshold, the higher the detection rate, but the higher the false alarm rate.

[0045] The principle of determining whether a drone poses a collision risk based on the rate of change of vibration amplitude is as follows: At each acquisition time, the vibration amplitude of the machine body at the current acquisition time and the vibration amplitude of the machine body at the previous acquisition time are obtained. The absolute value of the difference between the two is calculated and then divided by the vibration amplitude of the machine body at the previous acquisition time to obtain the rate of change of vibration amplitude at the current acquisition time. Specifically, the vibration amplitude change rate reflects the trend of the intensity of the drone's vibration over time. When the drone is hovering stably, the vibration amplitude is relatively stable and the vibration amplitude change rate is very small. When the drone drifts or goes out of control and quickly approaches the surface of the target, the airflow between the drone and the surface is compressed, which will generate an air cushion effect or turbulence. This sudden change in aerodynamic force will instantly change the motor load, causing the vibration amplitude to increase sharply. The essence of the vibration amplitude change rate is to evaluate the trend of the distance between the drone and the surface of the target being measured to shorten.

[0046] The vibration amplitude change rate is compared with a preset safe change rate threshold. When the vibration amplitude change rate is less than the preset safe change rate threshold, the drone is judged to have no collision risk. When the vibration amplitude change rate is greater than or equal to the preset safe change rate threshold, the drone is judged to have a collision risk.

[0047] Specifically, the preset safe rate of change threshold is the decomposition line that distinguishes normal hovering vibration fluctuations from abnormal vibration abrupt changes before a collision. This threshold is higher than the maximum fluctuation range of the vibration amplitude change rate during normal hovering to avoid false triggers, and lower than the actual measured vibration amplitude abrupt change rate before a collision to ensure early warning. In a windless, interference-free environment, far from the surface being measured, the drone is allowed to hover stably. Several consecutive data collection times are set, and the vibration amplitude at each adjacent collection time is acquired. The rate of change of vibration amplitude at each collection time is calculated, and the mean and standard deviation of these rates of change are statistically analyzed. The mean is then added to... The product of the safety factor and the standard deviation yields the preset safety change rate threshold. The safety factor controls the conservatism of the collision warning. The smaller the safety factor, the lower the warning threshold, and the more sensitive the system is to sudden vibration changes, enabling it to detect approach trends earlier, but the false alarm rate increases. The larger the safety factor, the higher the warning threshold and the lower the false alarm rate, but delayed warnings may occur. The value ranges from 3 to 5 to cover 99.7% to 99.99% of normal fluctuations. The smaller the safety factor, the higher the false alarm rate, which is suitable for scenarios that are not sensitive to collisions. The larger the safety factor, the lower the false alarm rate, which is suitable for high-precision flaw detection tasks.

[0048] Step 5: When there is a collision risk to the drone, determine the location of the collision risk. Based on the defect area and the location of the collision risk, determine whether the flaw detection data acquisition has been completed. If it has been completed, the drone is instructed to return to base. If it has not been completed, the control parameters of the PID controller are adjusted, and the matching buffer sleeve is folded and deformed until the rate of change of the vibration amplitude of the drone body recovers to below the safe rate of change threshold. Then, the drone is re-hovered on the surface of the target to be tested to continue the flaw detection task.

[0049] In this embodiment, the principle for determining whether flaw detection data acquisition has been completed based on the defect area and the location of collision risk is as follows: When it is determined that the drone has a collision risk, the real-time three-dimensional coordinates of the drone at the current acquisition time and the previous acquisition time are obtained, the real-time trajectory vector of the drone is generated, the spatial intersection of the real-time trajectory vector and the surface of the target to be measured is judged, and the intersection point of the real-time trajectory vector and the surface of the target to be measured is taken as the collision risk location. The defect regions from multiple consecutive acquisition times prior to the current acquisition time are acquired. The defect regions are arranged in chronological order of acquisition times to form a defect region detection sequence. The area overlap of the last defect region in the defect region detection sequence with the defect region at the current acquisition time is calculated. The collision risk location is compared with the defect region at the current acquisition time in terms of spatial location to determine whether the collision risk location is located inside the boundary of the defect region or whether the distance from the boundary of the defect region is less than a preset influence distance threshold. Area overlap is used to quantify the degree of spatial overlap between the defect region at the current acquisition moment and the defect region at the previous acquisition moment. The defect region at the current acquisition moment and the last defect region in the defect region detection sequence (i.e., the defect region at the previous acquisition moment) are selected, and their intersection and union areas in the global coordinate system are collected. The area overlap is obtained by dividing the intersection area by the union area. The value range of area overlap is... The closer the value is to 1, the more the defect areas detected at adjacent acquisition times overlap, indicating that the defect areas are stable, the detection results are consistent, the data has converged, and repeated detection will not add any new effective information.

[0050] If the area overlap is greater than the preset area overlap threshold, and the collision risk location is outside the defect area at the current acquisition time, or the distance from the defect area boundary is greater than or equal to the preset influence distance threshold, then the data acquisition is considered complete; otherwise, the data acquisition is considered incomplete.

[0051] It should be noted that if the area overlap is greater than the preset area overlap threshold, it indicates that the defect area has been detected stably multiple times, the data tends to converge, and repeated collection will not add any new valid information. On this basis, the collision risk location is further compared with the defect area at the current collection time to determine whether the collision risk location is located inside the boundary of the defect area or the distance from the boundary of the defect area is less than the preset influence distance threshold. If the collision risk location falls inside the defect area or is close to its boundary, it means that the area is the target area of ​​the current flaw detection task, and its data has been collected in the previous detection. There is no need to risk collecting in this area. At this time, combined with the two conditions of high area overlap and collision risk location being concentrated in the already detected area, it is judged that the data collection has been completed. Conversely, if the area overlap is lower than the threshold, it means that the current defect area has not yet converged stably, or the collision risk location is outside the defect area and far away. It means that the data in this area is incomplete or the current risk location is not an existing defect area. Flaw detection still needs to continue. In this case, it is judged that the data collection has not been completed, and the subsequent PID parameter adjustment and buffer sleeve folding protection action are triggered.

[0052] Among them, a preset impact distance threshold is established based on the drone's safe distance and buffering capacity. This threshold should be less than the shortest distance that the drone can safely brake or avoid at its current hovering speed, ensuring that the drone has sufficient time to respond after triggering a collision risk assessment. Simultaneously, this threshold is greater than the maximum deformation stroke of the buffer sleeve during folding deformation, which can effectively absorb impact and protect the fuselage, thus ensuring that the buffer sleeve has sufficient deformation buffering capacity when the risk location is close to the defect area but before an actual collision occurs. The area overlap threshold determines the strictness of the judgment that the defect area data has stabilized and converged, and the flaw detection task can be terminated. The range of the area overlap threshold is... A value of 1 indicates the strictest judgment, while a value of 0 indicates the most lenient judgment. A larger value means that the defect areas at the preceding and following acquisition times must almost completely overlap spatially to determine data convergence. Detection is only allowed to stop when the defect area has been repeatedly confirmed with almost no spatial drift. This is suitable for critical structural component flaw detection tasks with low tolerance for missed detections, but it can easily lead to longer detection times and more invalid duplicate acquisitions. A smaller area overlap threshold means that a larger spatial offset or shape change in the defect area at the preceding and following acquisition times is allowed, and data convergence can still be determined. This indicates that the system focuses more on task efficiency and risk avoidance, and tends to allow detection to end once the defect area is roughly stable. This is suitable for scenarios with high flaw detection speed requirements, relatively flat surfaces, and large defect sizes.

[0053] In this embodiment, the principle of adjusting the control parameters of the PID controller and causing the matching buffer sleeve to fold and deform until the rate of change of the vibration amplitude of the machine body recovers to below the safe rate of change threshold is as follows: The vibration amplitude of the machine body at the current acquisition time is obtained and compared with the vibration amplitude at the previous acquisition time. The difference in vibration amplitude is calculated and compared with a preset difference threshold. If the difference in vibration amplitude is greater than the preset difference threshold, the proportional coefficient of the PID controller is increased while the integral coefficient of the PID controller is decreased to generate adjusted PID control parameters. If the difference in vibration amplitude is less than or equal to the preset difference threshold, the derivative coefficient of the PID controller is increased to generate adjusted PID control parameters. Specifically, the vibration amplitude difference reflects the magnitude and direction of the vibration amplitude change per unit time. If it is positive and large, it indicates that the vibration increases sharply in a short period of time, usually due to strong transient disturbances caused by sudden external force impact. If it is negative or a small positive value, it indicates that the vibration changes slowly or decreases, usually caused by cumulative attitude drift or continuous low-frequency oscillation. The PID control parameters are adjusted based on the relationship between the vibration amplitude difference and the preset difference threshold. When the vibration amplitude difference is greater than the preset difference threshold, it indicates that the vibration has deteriorated rapidly in a short period of time, which is a strong impact disturbance. The primary goal at this time is rapid braking. Therefore, it is necessary to increase the proportional coefficient to amplify the correction force for large real-time deviations, generate a larger motor speed adjustment, and quickly offset the sudden displacement. At the same time, the integral coefficient is reduced to reduce the weight of historical cumulative error, prevent the integral term from lag and overcompensation during sudden changes, and avoid reverse overshoot and secondary oscillation. When the vibration amplitude difference is less than or equal to the preset difference threshold, it indicates that the vibration change amplitude is not large or the area is stable, which is a continuous low-frequency oscillation or cumulative drift. There is no risk of emergency impact. The adjustment goal at this time is to ensure smooth convergence, no overshoot, and smooth elimination of continuous fluctuations. Therefore, the derivative coefficient is increased to enhance the ability to sense and suppress the vibration change rate, predict the vibration trend in advance, and adjust in the opposite direction to allow the UAV to smoothly return to a safe hovering state.

[0054] The preset difference threshold is used to determine whether the current vibration amplitude change is a sudden strong impact or a steady drift. In an environment without interference and far from the surface of the target, the drone hovers several times to obtain the body vibration amplitude at each acquisition time, and calculates the vibration amplitude difference between adjacent acquisition times. The maximum value of all vibration amplitude differences is taken as the preset difference threshold.

[0055] The adjusted PID control parameters replace the current PID control parameters, and the adjusted PID control parameters are used to generate speed drive signals to adjust the speed of each fan blade. At the same time, a folding command is sent to the folding drive component of the matching buffer sleeve. During the folding process of the matching buffer sleeve, the vibration amplitude of the machine body is continuously collected in real time and the rate of change of the vibration amplitude of the machine body is calculated until the rate of change of the vibration amplitude of the machine body recovers to less than the preset safe rate of change threshold, and the matching buffer sleeve stops folding.

[0056] The accompanying buffer sleeve changes the external contour and stiffness of the UAV during folding. On the one hand, it absorbs collision energy, and on the other hand, it changes the aerodynamic interaction characteristics between the body and the surface to be tested. Moreover, the folding action itself is a mechanical disturbance. If folding is stopped before the vibration has stabilized, the UAV may be in a critical unstable state, which may easily trigger the risk of collision again. The premise for stopping folding is to return to a safe state. However, it will not stop immediately when it returns to a safe state. Instead, the UAV will be allowed to re-stable hover on the surface to be tested. Therefore, the stopping condition is that the vibration amplitude change rate returns to less than the preset safe change rate threshold. At this time, it is determined that the system has entered the stable convergence stage. This avoids forcibly performing fine detection before the risk has been completely eliminated, and also prevents excessive conservatism. It achieves a balance between flight safety and data acquisition efficiency during flaw detection.

[0057] The above formulas are all dimensionless calculations. The formulas are derived from software simulations based on a large amount of collected data to obtain the most recent real-world results. The preset parameters in the formulas are set by those skilled in the art according to the actual situation.

[0058] The above embodiments can be implemented, in whole or in part, by software, hardware, firmware, or any other combination thereof. When implemented in software, the above embodiments can be implemented, in whole or in part, as a computer program product. Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented by electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution.

[0059] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment, depending on actual needs.

[0060] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any changes or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application.

Claims

1. A control optimization method for an X-ray flaw detection device mounted on an unmanned aerial vehicle (UAV), characterized in that, The specific steps include: Step 1: Real-time acquisition of the vibration amplitude of the UAV equipped with the X-ray flaw detection device during flight, and real-time adjustment of the UAV's flight attitude through a PID controller; Step 2: After the UAV flies to the flaw detection area, it remains hovering. At the same time, the UAV's spatial coordinates are located in real time, and the UAV's attitude angle data is collected. The relative angle between the outer wall of the buffer sleeve of the X-ray flaw detection device and the surface of the target to be tested is calculated. Based on the relative angle, the emission direction of the X-ray flaw detection device is adjusted so that its ray center is perpendicular to the surface of the target to be tested. Step 3: Acquire the signal strength returned by the X-ray flaw detection device in real time, compare it with the preset standard signal strength, and if the difference between the two exceeds the allowable error value, adjust the control parameters of the X-ray flaw detection device in real time, and generate a preliminary defect area based on the real-time spatial coordinates of the UAV and the control parameters. Step 4: Collect surface image data of the target to be tested, fuse it with the data of the preliminary defect area, determine the final defect area, calculate the vibration amplitude change rate based on the vibration amplitude change rate of the current acquisition time and the previous acquisition time, and determine whether the UAV has a collision risk based on the vibration amplitude change rate. Step 5: When there is a collision risk to the drone, determine the location of the collision risk. Based on the defect area and the location of the collision risk, determine whether the flaw detection data acquisition has been completed. If it has been completed, the drone is instructed to return to base. If it has not been completed, the control parameters of the PID controller are adjusted, and the matching buffer sleeve is folded and deformed until the rate of change of the vibration amplitude of the drone body recovers to below the safe rate of change threshold. Then, the drone is re-hovered on the surface of the target to be tested to continue the flaw detection task.

2. The control optimization method for an X-ray flaw detection device mounted on a UAV according to claim 1, characterized in that: The principle of using a PID controller to adjust the flight attitude of a drone in real time is as follows: The vibration deviation value is obtained by taking the absolute value of the difference between the body vibration amplitude and the preset hovering stability amplitude. The vibration deviation value is input to the proportional unit, integral unit and derivative unit of the PID controller respectively, which generate the real-time proportional control component, the historical cumulative integral control component and the derivative control component of the vibration change trend respectively. The proportional control component, integral control component and derivative control component are added together to generate the motor speed regulation. The motor speed adjustment is converted into a speed drive signal for each fan blade motor. The speed of each fan blade is adjusted by the speed drive signal so that the vibration amplitude of the machine body is less than or equal to the preset hovering stability amplitude.

3. The control optimization method for an X-ray flaw detection device mounted on a UAV according to claim 1, characterized in that: The principle of real-time positioning of the UAV's spatial coordinates and collection of the UAV's attitude angle data, and calculation of the relative angle between the outer wall of the buffer sleeve of the X-ray flaw detection device and the surface of the target to be tested, is as follows: A global coordinate system is established with a preset ground reference point as the origin. The X-axis and Y-axis of the global coordinate system are located in the horizontal plane and are perpendicular to each other. The positive direction of the Z-axis is upward along the direction of gravity and is perpendicular to the horizontal plane where the X-axis and Y-axis are located. A local coordinate system is established with the center of mass of the UAV as the origin. The X-axis, Y-axis and Z-axis are set with the horizontal axis, vertical axis and vertical axis of the UAV body, respectively. When the UAV hovers over the flaw detection area, the coordinates of the UAV in the global coordinate system are obtained, and the attitude angle data of the UAV is obtained through the local coordinate system. The attitude angle data includes pitch angle, roll angle and yaw angle. At the hovering position, multi-point ranging is performed on the surface of the target to be measured. Based on the ranging results, a local surface point cloud is generated in real time. Based on the local surface point cloud, the normal direction vector of the target surface in the global coordinate system is determined. Based on attitude angle data, the directions of each coordinate axis in the local coordinate system are transformed to the global coordinate system to obtain the real-time outward normal direction vector of the UAV in the global coordinate system; The spatial dot product of the normal direction vector of the target surface in the global coordinate system and the real-time outward normal direction vector of the UAV in the global coordinate system is performed to obtain the spatial angle between the two vectors, which is the relative angle.

4. The control optimization method for an X-ray flaw detection device mounted on a UAV according to claim 3, characterized in that: The principle of adjusting the emission direction of an X-ray flaw detector based on the relative angle is as follows: The relative angle is decomposed into pitch deviation angle and yaw deviation angle around the horizontal axis of the local coordinate system. PID control calculations are performed on the pitch deviation angle and yaw deviation angle to generate pitch adjustment component and yaw adjustment component. The pitch adjustment component and yaw adjustment component are used as adjustment signals to drive the X-ray flaw detection device to rotate around the horizontal axis and vertical axis of the local coordinate system by the corresponding angles, so that the center of the X-ray emission ray is perpendicular to the surface of the target to be measured.

5. The control optimization method for an X-ray flaw detection device mounted on a UAV according to claim 1, characterized in that: The principle of real-time adjustment of the control parameters of the X-ray flaw detection device and generation of preliminary defect areas based on the real-time spatial coordinates of the UAV and the control parameters is as follows: The control parameters include tube voltage and tube current; The real-time intensity deviation is obtained by subtracting the real-time flaw detection signal intensity value of the X-ray flaw detection device from the standard signal intensity value preset for the material and thickness of the target. If the absolute value of the real-time strength deviation is greater than the preset allowable error value, then the real-time strength deviation is used as the input variable of the PID controller, and the transistor voltage regulation signal and transistor current regulation signal are generated in sequence through proportional amplification, integral accumulation and derivative prediction. After the control parameters stabilize, the real-time three-dimensional coordinates of the UAV in the global coordinate system are collected, and the real-time three-dimensional coordinates at the same collection time are bound with the control parameters to form working point data with spatial location labels. The real-time three-dimensional coordinates corresponding to the working point data are projected along the normal direction of the surface of the target to be tested. The projection point is taken as the initial screening suspicious point. The initial screening detection area is defined with the initial screening suspicious point as the center and the X-ray coverage radius of the X-ray flaw detection device under the current control parameters. All the initial screening suspicious points and their corresponding initial screening detection areas are summarized to form the preliminary defect area.

6. The control optimization method for an X-ray flaw detection device mounted on a UAV according to claim 5, characterized in that: The principle for acquiring surface image data of the target under test, fusing it with data from the preliminary defect area, and determining the final defect area is as follows: The visible light image and infrared thermal image of the target surface are acquired in real time while the drone is hovering. The visible light image and infrared thermal image are then registered at the pixel level to generate fused surface image data. Surface anomalous regions are extracted from the fused surface image data. These anomalous regions include crack textures and peeling areas in visible light images, as well as temperature anomalous regions in infrared thermal imaging images. The surface anomalous regions are spatially located in a global coordinate system to generate a set of surface defect regions. The spatial overlap between the set of surface defect regions and each initial screening detection region in the preliminary defect region is calculated, and the preliminary defect regions with spatial overlap exceeding the preset overlap threshold are determined as the final defect regions. The image detection area is defined based on the real-time ray coverage radius of the X-ray flaw detection device. The intersection area between the initial screening detection area and each image detection area in the global coordinate system is calculated. The spatial overlap is obtained by dividing the area of ​​the intersection area by the area of ​​the initial screening detection area.

7. The control optimization method for an X-ray flaw detection device mounted on a UAV according to claim 1, characterized in that: The principle of determining whether a drone poses a collision risk based on the rate of change of vibration amplitude is as follows: At each acquisition time, the vibration amplitude of the machine body at the current acquisition time and the vibration amplitude of the machine body at the previous acquisition time are obtained. The absolute value of the difference between the two is calculated and then divided by the vibration amplitude of the machine body at the previous acquisition time to obtain the rate of change of vibration amplitude at the current acquisition time. The vibration amplitude change rate is compared with a preset safe change rate threshold. When the vibration amplitude change rate is less than the preset safe change rate threshold, the drone is judged to have no collision risk. When the vibration amplitude change rate is greater than or equal to the preset safe change rate threshold, the drone is judged to have a collision risk.

8. The control optimization method for an X-ray flaw detection device mounted on a UAV according to claim 1, characterized in that: The principle for determining whether flaw detection data acquisition has been completed based on the defect area and the location of collision risk is as follows: When it is determined that the drone has a collision risk, the real-time three-dimensional coordinates of the drone at the current acquisition time and the previous acquisition time are obtained, the real-time trajectory vector of the drone is generated, the spatial intersection of the real-time trajectory vector and the surface of the target to be measured is judged, and the intersection point of the real-time trajectory vector and the surface of the target to be measured is taken as the collision risk location. The defect regions from multiple consecutive acquisition times prior to the current acquisition time are acquired. The defect regions are arranged in chronological order of acquisition times to form a defect region detection sequence. The area overlap of the last defect region in the defect region detection sequence with the defect region at the current acquisition time is calculated. The collision risk location is compared with the defect region at the current acquisition time in terms of spatial location to determine whether the collision risk location is located inside the boundary of the defect region or whether the distance from the boundary of the defect region is less than a preset influence distance threshold. If the area overlap is greater than the preset area overlap threshold, and the collision risk location is outside the defect area at the current acquisition time, or the distance from the defect area boundary is greater than or equal to the preset influence distance threshold, then the data acquisition is considered complete; otherwise, the data acquisition is considered incomplete.

9. The control optimization method for an X-ray flaw detection device mounted on a UAV according to claim 8, characterized in that: The principle behind adjusting the control parameters of the PID controller and causing the matching buffer sleeve to fold and deform until the rate of change of the machine body vibration amplitude returns to below the safe rate of change threshold is as follows: When data acquisition is deemed incomplete, the vibration amplitude of the machine body at the current acquisition moment is compared with that at the previous acquisition moment. The difference in vibration amplitude is calculated and compared with a preset difference threshold. If the difference in vibration amplitude is greater than the preset difference threshold, the proportional coefficient of the PID controller is increased while the integral coefficient of the PID controller is decreased to generate adjusted PID control parameters. If the difference in vibration amplitude is less than or equal to the preset difference threshold, the derivative coefficient of the PID controller is increased to generate adjusted PID control parameters. The adjusted PID control parameters replace the current PID control parameters, and the adjusted PID control parameters are used to generate speed drive signals to adjust the speed of each fan blade. At the same time, a folding command is sent to the folding drive component of the matching buffer sleeve. During the folding process of the matching buffer sleeve, the vibration amplitude of the machine body is continuously collected in real time and the rate of change of the vibration amplitude of the machine body is calculated until the rate of change of the vibration amplitude of the machine body recovers to less than the preset safe rate of change threshold, and the matching buffer sleeve stops folding.