A cooperative inspection method and device based on heterogeneous multi-machine combination, a terminal device, and a storage medium
By constructing an undirected connected graph and generating the optimal path using the ant colony algorithm, the problems of high computational complexity and insufficient robot endurance in power line inspection are solved, thus realizing efficient large-scale intelligent power line inspection.
Patent Information
- Application Number
- CN202411775864.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-05
- Publication Date
- 2026-02-10
- Estimated Expiration
- 2044-12-05
AI Technical Summary
Power line inspection suffers from problems such as high computational complexity, slow computation speed, weak ability to process high-dimensional spaces, and insufficient robot endurance, making it difficult to realize large-scale intelligent power line inspection.
By constructing an undirected connected graph of the inspection area, using the ant colony algorithm for population exploration, and generating the optimal path set, the robot's endurance problem is solved, and a concurrent approach is adopted to improve computational efficiency.
It improves the computing efficiency and robot endurance of intelligent power inspection, and solves the problems of insufficient computing power and endurance in large-scale power inspection.
Smart Images

Figure CN119645065B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of intelligent inspection technology, and in particular to a collaborative inspection method, device, terminal equipment, and storage medium based on heterogeneous multi-machine collaboration. Background Technology
[0002] In recent years, with the accelerated pace of power system infrastructure construction and the continuous expansion of the power system's scale, numerous problems and challenges have arisen for power system inspection. Power system inspection aims to ensure the safe and stable operation of the power system by regularly inspecting, testing, and evaluating power equipment (such as substations, transmission lines, and distribution lines).
[0003] There are basically two scenarios for intelligent power line inspection. The first scenario involves ground robots traversing or performing fixed-point inspections of the areas where power equipment needs to be inspected, such as in substation inspections, where obstacles are known. The second scenario involves using large drones or helicopters to inspect transmission lines or towers. In this scenario, one or more optimized paths need to be planned in advance for the inspection sequence of multiple tower targets, solving the problem of multi-drone, multi-target inspection while avoiding obstacles. Traditional search algorithms for power drone path planning are primarily used for obstacle avoidance path planning in substations. Intelligent optimization algorithms are widely applied to power line inspection path planning.
[0004] However, traditional search algorithms have always suffered from drawbacks such as high computational complexity, slow computation speed, and weak ability to handle high-dimensional spaces. Intelligent optimization algorithms may be a suitable choice to address these problems, but as the inspection coverage increases, the computational load of intelligent optimization algorithms also increases exponentially. Furthermore, due to energy consumption issues, robots cannot operate for extended periods, so the power supply problem also makes it difficult to implement large-scale robot inspections. Therefore, intelligent power inspection currently lacks the capability for large-scale application. Summary of the Invention
[0005] This invention provides a collaborative inspection method, device, terminal equipment, and storage medium based on heterogeneous multi-machine collaboration. By constructing an undirected connected graph together with the replenishment point and the collection point, the robot's endurance problem is solved. Secondly, a concurrent approach is adopted, which improves the computational efficiency of the algorithm by constructing several ant colonies to conduct population exploration operations together. This solves the defects of insufficient computing power and insufficient robot endurance in current power intelligent inspection when conducting large-scale inspections.
[0006] One embodiment of the present invention provides a collaborative inspection method based on heterogeneous multi-machine collaboration, comprising:
[0007] Acquire the following information: several data collection points to be inspected within the inspection area, several resupply points for resupplying and extending the power of the inspection robots, the initial positions and initial resources of the inspection robots to be inspected, and the number of robots.
[0008] Based on the collection points and the supply points, the connection paths between each collection point and each supply point are determined, and an undirected connected graph of the inspection area is constructed based on the connection paths; wherein, the collection points and the supply points are all nodes of the undirected connected graph.
[0009] Several ant colonies are constructed, and several male ants in the ant colonies are initialized according to the number of robots, the initial position, and the initial resources; wherein, each ant colony contains several male ants equal to the number of robots, and in each ant colony, the male ant corresponds one-to-one with the inspection robot;
[0010] An ant colony algorithm is used. Based on the undirected connected graph, the initial positions of several male ants in several ant colonies, and the initial resources, the ant colonies are repeatedly subjected to population exploration operations until a target path set is determined from the path sets generated by the ant colonies in several population exploration operations. The path set consists of several effective paths taken by several male ants in an ant colony to traverse all collection points in the undirected connected graph. The effective path is the path taken by each male ant in the ant colony to move from one node to another. The target path set is the path set with the shortest completion time and the highest task balance rate among the several path sets.
[0011] Based on the valid paths explored by each male ant in the target path set, the inspection task of the inspection robot corresponding to each male ant is determined.
[0012] Furthermore, the population exploration operation includes:
[0013] Obtain the global optimal solution, global path pheromone, and global expected reward table; wherein, the global optimal solution is initially empty, the global path pheromone is used to record the pheromone on each effective path in the path set generated by each ant colony, and is initially a preset constant value; the global expected reward table is used to record the reward value of each male ant in each ant colony exploring the corresponding effective path, and is initially empty.
[0014] The undirected connected graph, the global path pheromone, and the global expected reward table are input into the ant colony that has not performed node exploration operations, so that the ant colony, based on the undirected connected graph, the global path pheromone, the global expected reward table, the initial position of the male ant, and the initial resources, repeatedly performs node exploration operations until the ant colony has explored all the collection points and the male ant is at the resupply point.
[0015] When it is confirmed that a target ant colony has explored all the collection points and that all the male ants are at the resupply points, the path set of the target ant colony is obtained;
[0016] Calculate a first performance metric for the path set and compare it with a second performance metric for the global optimal solution. If the first performance metric of the path set is greater than the second performance metric of the current global optimal solution, then update the global optimal solution to the path set. The first performance metric and the second performance metric are composed of completion time and task balancing rate.
[0017] Update the global path pheromone and the global expected reward table based on the valid paths in the path set;
[0018] Determine whether the total number of times the ant colonies perform population exploration operations is not less than a preset threshold number;
[0019] If so, then based on the current global optimal solution, the current global path pheromone, and the current global expected reward table, the population exploration operation is re-executed on the target ant colony;
[0020] If not, then the global optimal solution will be used as the target path set.
[0021] Furthermore, the node exploration operation includes:
[0022] Obtain the current global path pheromone, the current global expected reward table, the current taboo table, the current position of each male ant, and the current resources; wherein, initially, the current position and current resources of each male ant are the initial position and initial resources corresponding to each male ant, and the taboo table is used to record the collection points that the ant colony has explored, and is initially empty;
[0023] Based on the current location and resources of each male ant, a target male ant is identified for exploring an effective path;
[0024] Based on the target male ant, the global path pheromone, and the global expected reward table, a target node to be explored is determined; wherein, the target node is a collection point or a resupply point;
[0025] When the target node is determined as a collection point, the remaining resources of the target male ant after it reaches the target node from its current position are calculated, and the target resupply point closest to the target node is determined.
[0026] When the target node is determined to be a resupply point, or when the target male ant is determined to be able to reach the target resupply point from its current position using the remaining resources, an effective path is generated based on the current position and the target node. The target node is then used as the new current position of the target male ant, the remaining resources are used as the new current resources of the target male ant, and the target node is added to the taboo list.
[0027] Determine whether the current taboo list contains all the collection points, and whether all the male ants are at the resupply points;
[0028] If so, then generate a path set based on several valid paths;
[0029] If not, proceed to the next round of node exploration.
[0030] Furthermore, after calculating the remaining resources after the target male ant reaches the target node from its current position and determining the nearest target supply point to the target node, the process further includes:
[0031] After determining that the target male ant has reached the target node from its current location, if it is unable to reach the target supply point using the remaining resources, the global path pheromone and the global expected reward table are updated according to the current number of valid paths, and the taboo table is cleared, and the node exploration operation is re-executed.
[0032] Furthermore, updating the global path pheromone and the global expected reward table includes:
[0033] Obtain the path pheromone of each valid path in the global path pheromone;
[0034] Traverse the male ants and calculate the pheromone left by each male ant on each valid path when it passes through each valid path;
[0035] Upon completion of the traversal, the total pheromone content along each of the valid paths is calculated;
[0036] Based on the sum of pheromones for each valid path and the corresponding path pheromone, update the path pheromone of each valid path in the global path pheromone.
[0037] The effective path is input into a preset reward prediction model so that the reward prediction model outputs the expected reward value on the effective path explored by each male ant, and the expected reward table is updated according to the expected reward value; wherein, the reward prediction model is a model constructed using the Q-learning algorithm.
[0038] Furthermore, based on the target male ant, the global path pheromone, and the global expected reward table, a target node to be explored is determined, including:
[0039] Several collection points not currently recorded in the taboo list, as well as idle supply points, are selected as initial candidate nodes.
[0040] Based on the current resources of the target male ant, determine several initial candidate nodes that the target male ant can reach as candidate nodes;
[0041] Calculate the probability that the target male ant will collide with other male ants when it reaches each of the candidate nodes from its current position;
[0042] A probability value is randomly generated. When the probability value is less than a preset probability, a target node is randomly selected from the candidate nodes using a roulette wheel method.
[0043] When the probability value is not less than the preset probability, a target node is determined from the candidate nodes based on the conflict probability, the global path pheromone, and the global expected reward table.
[0044] Furthermore, determining a target node from the candidate nodes based on the conflict probability, the global path pheromone, and the global expected reward table includes:
[0045] Based on the current location of the male ant and several candidate nodes, determine the working time for the male ant to travel from its current location to each candidate node and perform the inspection task;
[0046] Based on the working time and the conflict probability, calculate the heuristic information of each candidate node;
[0047] The transition probability of each candidate node is determined according to the following formula:
[0048]
[0049] in, Let τ be the transition probability of candidate node j. ij (t) represents the path pheromone between the current position of the male ant and candidate node j, η ij ζ is the heuristic information for candidate node j. ij Let α be the expected reward for the male ant to reach candidate node j from its current position, β be a preset pheromone heuristic factor, γ be a preset expectation heuristic factor, and γ be a preset reward heuristic factor. is the set of candidate nodes.
[0050] Another embodiment of the present invention provides a collaborative inspection device based on heterogeneous multi-machine collaboration, comprising:
[0051] The data acquisition module is used to acquire several collection points to be inspected within the inspection area, several supply points for refueling the inspection robots, the initial positions and initial resources of several inspection robots performing the inspection, and the number of robots.
[0052] The connected graph construction module is used to determine the connected paths between each collection point and each supply point based on the collection points and the supply points, and to construct an undirected connected graph of the inspection area based on the connected paths; wherein, the collection points and the supply points are all nodes of the undirected connected graph;
[0053] The ant colony building module is used to build several ant colonies and initialize several male ants in the ant colonies according to the number of robots, the initial position, and the initial resources; wherein, each ant colony contains several male ants equal to the number of robots, and in each ant colony, the male ant corresponds one-to-one with the inspection robot;
[0054] The population exploration module employs an ant colony algorithm to repeatedly perform population exploration operations on several ant colonies based on the undirected connected graph, the initial positions of several male ants in the ant colonies, and initial resources, until a target path set is determined from several path sets generated by the ant colonies in the several population exploration operations. The path set consists of several valid paths traversed by several male ants in an ant colony to complete all collection points in the undirected connected graph; each valid path is the path taken by each male ant in the ant colony from one node to another. The target path set is the path set with the shortest completion time and the highest task balance rate among the several path sets.
[0055] The task allocation module is used to determine the inspection task of the inspection robot corresponding to each male ant based on the effective paths explored by each male ant in the target path set.
[0056] Another embodiment of the present invention provides a terminal device, including a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor. When the processor executes the computer program, it implements a collaborative inspection method based on heterogeneous multi-machine collaboration as described in any of the embodiments.
[0057] Another embodiment of the present invention provides a storage medium including a stored computer program, wherein, when the computer program is executed, it controls the device where the storage medium is located to perform a collaborative inspection method based on heterogeneous multi-machine collaboration as described in any of the above embodiments.
[0058] The following benefits can be obtained by implementing the present invention:
[0059] This invention discloses a collaborative inspection method, device, terminal equipment, and storage medium based on heterogeneous multi-machine collaboration. The method constructs an undirected connected graph of the inspection area based on collection points and replenishment points. Several ant colonies are constructed based on the number of robots, their initial positions, and initial resources. Several population exploration operations are performed on the ant colonies according to the undirected connected graph, causing each ant colony to generate several path sets. From these path sets, a target path set is identified. Finally, based on the effective paths explored by each male ant in the target path set, the inspection task corresponding to each male ant is determined. Therefore, this invention constructs an undirected connected graph together with the collection points, allowing for consideration of robot endurance while addressing the inspection task allocation problem. Furthermore, it employs a concurrent approach, constructing several ant colonies to perform population exploration operations simultaneously, thereby improving the algorithm's computational efficiency and solving the problems of insufficient computing power and robot endurance in current large-scale power intelligent inspection systems. Attached Figure Description
[0060] Figure 1 This is a flowchart illustrating a collaborative inspection method based on heterogeneous multi-machine collaboration, provided by an embodiment of the present invention.
[0061] Figure 2 This is a schematic diagram of the structure of a collaborative inspection device based on heterogeneous multi-machine collaboration, provided in an embodiment of the present invention.
[0062] Figure 3 This is a schematic diagram of the structure of an octree voxel map provided in an embodiment of the present invention.
[0063] Figure 4 This is a schematic diagram of inspection task allocation provided in an embodiment of the present invention.
[0064] Figure 5 This is a schematic diagram of the population exploration operation provided in an embodiment of the present invention. Detailed Implementation
[0065] To make the objectives, technical solutions, and advantages of this application clearer, the technical solutions of this application will be clearly and completely described below with reference to the accompanying drawings of the embodiments. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0066] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application pertains; the terminology used herein is for the purpose of describing particular embodiments only and is not intended to limit the application; the terms “comprising” and “having”, and any variations thereof, in the specification, claims, and foregoing description of the drawings are intended to cover non-exclusive inclusion.
[0067] In the description of the embodiments of this application, technical terms such as "first" and "second" are used only to distinguish different objects and should not be construed as indicating or implying relative importance or implicitly specifying the number, specific order, or primary and secondary relationship of the indicated technical features. In the description of the embodiments of this application, "multiple" means two or more, unless otherwise explicitly defined.
[0068] In this document, the term "embodiment" means that a particular feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of this application. The appearance of this phrase in various places throughout the specification does not necessarily refer to the same embodiment, nor is it a separate or alternative embodiment mutually exclusive with other embodiments. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described herein can be combined with other embodiments.
[0069] In the description of the embodiments in this application, the term "and / or" is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, and B existing alone. Additionally, the character " / " in this document generally indicates that the preceding and following related objects have an "or" relationship.
[0070] In the description of the embodiments of this application, the term "multiple" refers to two or more (including two), similarly, "multiple sets" refers to two or more (including two sets), and "multiple pieces" refers to two or more (including two pieces).
[0071] In the description of the embodiments of this application, unless otherwise expressly specified and limited, technical terms such as "installation," "connection," "joining," and "fixing" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral part; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; they can refer to the internal communication of two components or the interaction between two components. For those skilled in the art, the specific meaning of the above terms in the embodiments of this application can be understood according to the specific circumstances.
[0072] See Figure 1 This is a flowchart illustrating a collaborative inspection method based on heterogeneous multi-machine collaboration according to an embodiment of the present invention, including:
[0073] S1. Obtain the initial position, initial resources, and number of robots of the several collection points to be inspected in the inspection area, several supply points for replenishing the inspection robots, and several inspection robots to be inspected.
[0074] In a preferred embodiment of the present invention, taking a large-scale joint inspection of power transmission, transformation, and distribution systems as an example, all locations requiring inspection and photography are designated as robot data collection points. This data collection point information includes, but is not limited to: the data collection point's ID, its latitude, longitude, and altitude coordinates, and the required shooting angles (including pitch, roll, and yaw angles). Supply points are devices such as robot airports or charging stations that can automatically charge the robots. Each supply point defines its latitude and longitude coordinates and a list of robots permitted to charge it. Simultaneously, it acquires all available robot IDs, robot models, and battery levels. Furthermore, it clarifies the list of data collection points where the robot can perform inspections and the list of supply points it can access.
[0075] S2. Based on the collection points and the supply points, determine the connection paths between each collection point and each supply point, and construct an undirected connected graph of the inspection area based on the connection paths; wherein, the collection points and the supply points are all nodes of the undirected connected graph;
[0076] In a preferred embodiment of the present invention, trajectory information between points is drawn based on the coordinate information of the collection points and replenishment points. The trajectory information includes trajectory length, speed limit, etc. Specifically, an octree voxel map is first constructed based on the inspection area. Especially in irregular terrains such as mountains and lakes, the octree voxel map enables efficient map data processing. It achieves multi-resolution representation and efficient storage, and supports persistent storage and fast loading. To solve the storage problem of large-area maps, a hierarchical distributed storage mechanism is selected. The octree is defined hierarchically according to different resolutions and distributed and stored on different servers. The octree voxel map is as follows: Figure 3 As shown, a large cube is continuously and evenly divided into eight pieces until it becomes the smallest cube. The entire large cube can be considered the root node, and the smallest cube can be considered a "leaf node." Thus, in an octree, the map volume can increase eightfold by moving up one level from the next level node. There is no need to expand a node if all its child nodes are occupied or none are occupied.
[0077] Based on the distribution of collection points and supply points, plan a connected graph that connects all collection points. This can be done manually by hand or automatically generated by an algorithm. Search-based path planning algorithms such as A* and fast random trees can be used to generate the trajectory between two points. Specifically, based on the collection points, supply points, and trajectory lines, an undirected connected graph is drawn, where all collection points are represented by... supply point This means that the nodes of the graph are V = V 1 ∪V 2 The trajectory lines are represented by the edges of the graph by E = {e1, e2, ...}. This undirected graph can be represented as...<V,E> .
[0078] S3. Construct several ant colonies, and initialize several male ants in the ant colonies according to the number of robots, the initial position, and the initial resources; wherein, each ant colony contains several male ants equal to the number of robots, and in each ant colony, the male ant corresponds one-to-one with the inspection robot.
[0079] In a preferred embodiment of the present invention, N populations are defined, each with a queen ant who governs M ants. The M ants correspond to M schedulable robots, and their initial positions correspond to the robot's location node. To address the large-scale computational problem, the ant colonies are distributed across various algorithm servers, with several algorithm servers sharing a central data server. The central data server stores global path pheromones, a global expected reward table, and the global optimal solution. Population exploration is then distributed across the algorithm servers, allowing for efficient parallel execution.
[0080] S4. Using an ant colony algorithm, based on the undirected connected graph, the initial positions of several male ants in several ant colonies, and the initial resources, the ant colonies are repeatedly subjected to population exploration operations until a target path set is determined from the path sets generated by the ant colonies in the several population exploration operations. The path set consists of several valid paths traversed by several male ants in an ant colony when traversing all collection points in the undirected connected graph. Each valid path is the path taken by each male ant in the ant colony from one node to another. The target path set is the path set with the shortest completion time and the highest task balance rate among the several path sets.
[0081] In a preferred embodiment of the present invention, according to Figure 5 Ant colony exploration can be simply understood as the collection point V 1 The robot needs to be traversed once, as its battery is running low and it needs to be moved to a support point V as soon as possible. 2 Charge it promptly.
[0082] The problem can be further described as follows:
[0083] 1) All data collection points must be visited at least once.
[0084] 2) Nodes in the supply point can be visited without being visited, or they can be visited multiple times.
[0085] 3) The robot has capability constraints and can only perform some of the data collection tasks.
[0086] 4) A supply point can only supply one robot at a time, and there are capacity constraints, meaning it can only supply a subset of robots. Assume the current supply point layout is sufficient to satisfy the task execution of all collection points.
[0087] 5) The robot needs to be recharged at supply points and completes all collection point tasks by leaping through the air. The robot's power consumption is related to the distance it travels and the number of tasks at each collection point. For example, one bar of power can allow it to travel 10 kilometers or complete 5 collection tasks.
[0088] 6) By default, robots start from the supply point and eventually return to the supply point when they finish.
[0089] Preferably, the population exploration operation includes:
[0090] S41. Obtain the global optimal solution, global path pheromone, and global expected reward table; wherein, the global optimal solution is initially empty; the global path pheromone is used to record the pheromone on each valid path in the path set generated by each ant colony, and is initially a preset constant value; the global expected reward table is used to record the reward value of each male ant in each ant colony exploring the corresponding valid path, and is initially empty; the taboo table is used to record the collection points that the ant colony has explored, and is initially empty.
[0091] In a preferred embodiment of the present invention, initially, the global path pheromone and the global expected reward table are initialized. Each queen ant is assigned M male ants, which are placed at the robot's initial node position, and the number of male ants is adjusted according to the robot's remaining power. Each queen ant initializes a taboo table, which records the collection points visited by the queen ant and the male ants, reflecting the ant's memory and preventing ants from retracing paths. The global path pheromone is initialized with a relatively large value. The global expected reward table is initialized and set to 0. An energy consumption matrix table is initialized, which records the minimum energy required for the robot to travel from collection point i to collection point j. This energy consumption is calculated as follows:
[0092] E(i,j)=e1(L(i,j)+e1min{L(j,l)|l∈V 2})+e2T(j);
[0093] Where L(i,j) represents the travel time required to travel from collection point i to collection point j, min{L(j,l)|l∈V 2Let {e1} represent the minimum travel time required for the robot to travel from collection point j to the nearest supply station l, and e1 be the energy consumption required per unit travel time. T(j) represents the robot's working time at collection point j, and e2 be the energy consumption required per unit working time. If e1 and e2 are different for each robot, then initialize the energy consumption matrix table {E1(i,j), E2(i,j), ..., E...} for each robot. M (i,j)}.
[0094] S42. Input the undirected connected graph, the global path pheromone, and the global expected reward table into the ant colony that has not performed node exploration operations, so that the ant colony, based on the undirected connected graph, the global path pheromone, the global expected reward table, the initial position of the male ant, and the initial resources, repeatedly perform node exploration operations until the ant colony has explored all the collection points and the male ants are all at the resupply points.
[0095] In a preferred embodiment of the present invention, the current global path information, global expected reward table, etc. are pushed to the algorithm server according to the deployment method of the algorithm server, and node exploration is performed in parallel.
[0096] Preferably, the node exploration operation includes:
[0097] S421. Obtain the current global path pheromone, the current global expected reward table, the current taboo table, the current position and current resources of each male ant; wherein, initially, the current position and current resources of each male ant are the initial position and initial resources corresponding to each male ant, and the taboo table is used to record the collection points that the ant colony has explored, and is initially empty.
[0098] S422. Based on the current location and current resources of each male ant, determine a target male ant for exploring an effective path;
[0099] In a preferred embodiment of the present invention, the moving ant is selected according to the Max-Min rule. First, a tabu list is used to identify whether all collection points have been explored. If there are still unexplored collection points, the male ant with the shortest end time of the currently assigned exploration node is selected for allocation according to the Max-Min rule. If all collection points have been explored, the male ant with the shortest remaining energy consumption and not currently docked at a supply point is selected for allocation according to the Max-Min rule.
[0100] S423. Based on the target male ant, the global path pheromone, and the global expected reward table, determine a target node to be explored; wherein, the target node is a collection point or a resupply point;
[0101] Preferably, a target node to be explored is determined based on the target male ant, the global path pheromone, and the global expected reward table, including:
[0102] S4231. Select several collection points not recorded in the current taboo table, as well as idle supply points, as initial candidate nodes;
[0103] S4232. Based on the current resources of the target male ant, determine several initial candidate nodes that the target male ant can reach as candidate nodes;
[0104] S4233. Calculate the probability that the target male ant will collide with other male ants when it arrives at each of the candidate nodes from its current position.
[0105] S4234. Randomly generate a probability value. When the probability value is less than a preset probability, use a roulette wheel to randomly determine a target node from the candidate nodes.
[0106] S4235. When the probability value is not less than the preset probability, a target node is determined from the candidate nodes based on the conflict probability, the global path pheromone, and the global expected reward table.
[0107] Preferably, determining a target node from the candidate nodes based on the conflict probability, the global path pheromone, and the global expected reward table includes:
[0108] S42351. Based on the current position of the male ant and several candidate nodes, determine the working time for the male ant to travel from its current position to each of the candidate nodes and perform the inspection task.
[0109] S42352. Calculate the heuristic information of each candidate node based on the working duration and the conflict probability;
[0110] S42353. Determine the transition probability of each candidate node according to the following formula:
[0111]
[0112] in, Let τ be the transition probability of candidate node j. ij (t) represents the path pheromone between the current position of the male ant and candidate node j, η ij ζ is the heuristic information for candidate node j. ij Let α be the expected reward for the male ant to reach candidate node j from its current position, β be a preset pheromone heuristic factor, γ be a preset expectation heuristic factor, and γ be a preset reward heuristic factor. is the set of candidate nodes.
[0113] In a preferred embodiment of the present invention, firstly, the next exploration point that the male ant can choose must be identified. This exploration point can only be a collection point that is not in the taboo list, and the remaining power of the robot corresponding to the male ant is sufficient to meet the minimum energy consumption requirements in the energy consumption matrix table.
[0114] Then, calculate the probability c that the male ant's chosen exploration point will conflict with the exploration path of other male ants. ij (t).
[0115] Finally, the optimal next exploration point is selected from the available exploration points. There are two specific selection methods. The p-value (p∈(0,1)) is a pre-set probability value.
[0116] Ants have a probability of 1-p that they randomly select an exploration node that meets the endurance constraint using a roulette wheel method;
[0117] Ants choose their next exploration point based on a probability p, using the global path pheromone and expected reward table. At time t, the queen ant sends out male ant k located at node i to explore the next node j based on the path pheromone τ. ij (t), heuristic information η ij and expected return ζ ij The transition probability is determined as follows:
[0118]
[0119] in, It is the set of nodes that the k-th node of the h-th male ant is allowed to explore; α is the pheromone heuristic factor; β is the expectation heuristic factor; γ is the reward heuristic factor; d ij It is the time required for the operation from node i to the target node j, including the travel time and the inspection operation time (i.e., the data collection time).
[0120] S424. When the target node is determined to be a collection point, calculate the remaining resources of the target male ant after it arrives at the target node from its current position, and determine the target supply point closest to the target node;
[0121] Preferably, after calculating the remaining resources after the target male ant reaches the target node from its current location and determining the nearest target supply point to the target node, the method further includes:
[0122] S4241. After determining that the target male ant has reached the target node from its current position, and it is unable to reach the target supply point using the remaining resources, update the global path pheromone and the global expected reward table according to the current number of valid paths, clear the taboo table, and re-execute the node exploration operation.
[0123] S425. When the target node is determined to be a resupply point, or when the target male ant reaches the target node from its current position and can reach the target resupply point using the remaining resources, an effective path is generated based on the current position and the target node. The target node is set as the new current position of the target male ant, the remaining resources are set as the new current resources of the target male ant, and the target node is added to the taboo list.
[0124] S426. Determine whether the current taboo table records all collection points and whether all the male ants are at resupply points;
[0125] S427. If so, then generate a path set based on several valid paths;
[0126] S428. If not, proceed to the next round of node exploration.
[0127] In a preferred embodiment of the present invention, if the selected target node is insufficient to reach the next supply point, the current queen ant's overall exploration fails and the exploration stops. Otherwise, the exploration continues, and the taboo list is modified to record the already explored collection points: if the current exploration node is a collection point, the collection point is added to the taboo list; if all collection points have been traversed and the last node of all male ants is a supply point, the exploration ends; otherwise, the node exploration operation continues.
[0128] It should be noted that during the confirmation process, it is necessary to identify whether there are any conflicts in the trajectories of all male ants under the current queen's jurisdiction. If there are conflicts, the trajectories are adjusted based on game theory strategies to resolve the conflicts.
[0129] S43. When it is confirmed that a target ant colony has explored all the collection points and all the male ants are at the resupply points, the path set of the target ant colony is obtained.
[0130] S44. Calculate the first performance index of the path set, and compare the performance index with the second performance index of the global optimal solution. If it is determined that the first performance index of the path set is greater than the second performance index of the current global optimal solution, then update the global optimal solution to the path set; wherein, the first performance index and the second performance index are composed of completion time and task balancing rate.
[0131] In a preferred embodiment of the present invention, it is determined whether the effective path explored by the queen ant under the command of the male ants is better than the global optimal solution, that is, whether the set of paths is better than the global optimal solution. If so, the global optimal solution is updated, and the effective paths explored by the queen ant are compared, and the path with the best indicators is selected and recorded, including path information and evaluation indicators. Using minimum and maximum completion time and task balance rate as indicators, it can be defined as:
[0132] minz = w1f1 + w2f2;
[0133] Where z represents the final evaluation metric, w1 and w2 are weights, f1 represents the normalized minimum and maximum completion times, and f2 represents the normalized task balance rate.
[0134] S45. Update the global path pheromone and the global expected return table based on the valid paths in the path set;
[0135] Preferably, updating the global path pheromone and the global expected reward table includes:
[0136] S451. Obtain the path pheromone of each valid path in the global path pheromone;
[0137] S452. Traverse the male ants and calculate the pheromone left by each male ant on each effective path when it passes through each effective path.
[0138] S453. When the traversal is completed, calculate the total pheromone content on each of the effective paths;
[0139] S454. Update the path pheromone of each valid path in the global path pheromone based on the sum of pheromones of each valid path and the corresponding path pheromone.
[0140] S455. Input the effective path into the preset reward prediction model so that the reward prediction model outputs the expected reward value on the effective path explored by each male ant, and updates the expected reward table according to the expected reward value; wherein, the reward prediction model is a model constructed using the Q-learning algorithm.
[0141] In a preferred embodiment of the present invention, the path pheromone τ ij (t) is updated according to the following formula:
[0142] τ ij (t+1)=(1-ρ)τ ij (t)+Δτ ij (t);
[0143]
[0144] Here, 1-ρ represents the volatile pheromone. When the queen ant finds a valid path, pheromones will be left behind along all the paths traversed by her male ants.
[0145] Expected return ζ hijThis represents the expected reward that the queen ant will receive when it issues a command to the h-th male ant to travel from node i to node j. Here, the Q-value Q(h,i,j) from Q-learning is used for calculation.
[0146] Q-learning is a reinforcement learning algorithm, belonging to the category of model-free prediction algorithms, used to solve Markov Decision Process (MDP) problems. The core idea of Q-learning is to learn an action-value function (Q-function) to evaluate the expected utility of taking an action in a given state. Q-learning can be used to train the decision-making ability of a queen ant.
[0147] The Q table is defined as follows:
[0148]
[0149]
[0150] The definition of state is as follows: the current male ant being commanded by the queen and the node being explored are defined as the state. The choice of action refers to the node being explored by the male ant. The update of the Q-value of the h-th male ant from its current exploration node i to its next exploration node j is as follows:
[0151] Q(h,i,j)=Q(h,i,j)+λ(r(h,i,j)+μ·max j′ Q(h,j,j ′ )-Q(h,i,j));
[0152] Where λ is the learning rate, μ is the discount rate, i is the current last exploration position of the h-th male ant, and j is the new exploration node currently selected by the h-th male ant. ′ This represents the next new exploration point that can be selected after the h-th male ant has explored j. r(h,i,j) is the immediate reward, and max... j′ Q(h,j,j ′ ) represents the maximum cumulative reward value that the h-th male ant can obtain after exploring j.
[0153]
[0154] Where r1 > r2 > 0 > r3. r3 is negative, indicating the current path is invalid and a certain reward needs to be deducted. r1 is the largest value, meaning the highest reward is obtained.
[0155] S46. Determine whether the total number of times the ant colonies perform population exploration operations is not less than a preset threshold number.
[0156] In a preferred embodiment of the present invention, when the total number of population exploration operations has exceeded the maximum number of iterations (number threshold), or the optimal solution has remained unchanged for a certain period of time, the population exploration can be terminated, the result can be output, and the algorithm can be ended; otherwise, the population exploration can continue.
[0157] S47. If so, then based on the current global optimal solution, the current global path pheromone, and the current global expected reward table, re-execute the population exploration operation on the target ant colony.
[0158] S48. If not, then the global optimal solution shall be taken as the target path set.
[0159] S5. Based on the valid paths explored by each male ant in the target path set, determine the inspection task of the inspection robot corresponding to each male ant.
[0160] In a preferred embodiment of the present invention, such as Figure 4 The diagram shown illustrates the allocation of heterogeneous multi-robot joint inspection tasks. The robots can be drones, wheeled robots, quadruped robots, or bipedal robots.
[0161] Robot 1 starts from supply point 1, follows the ABC sequence, returns to supply point 1 to recharge, then continues to collect DE, and finally returns to supply point 1 to recharge.
[0162] Robot 2 starts from supply point 2, collects photos in the order of FG, then goes to supply point 2 to recharge, then continues to collect HJ, and finally docks at supply point 3.
[0163] Robot 3 departs from supply point 3, collects photos in the JK sequence, and then proceeds to supply point 4 to recharge.
[0164] Robot 4 starts from supply point 4, visits the LM to collect photos, returns to supply point 4, then continues to collect OP photos and finally docks at supply point 2.
[0165] This embodiment provides a collaborative inspection method based on heterogeneous multi-machine collaboration. It constructs an undirected connected graph of the inspection area based on collection points and resupply points. Several ant colonies are built according to the number of robots, their initial positions, and initial resources. Based on the undirected connected graph, the ant colonies undergo several population exploration operations to generate several path sets. From these path sets, a target path set is identified. Finally, based on the effective paths explored by each male ant in the target path set, the inspection task corresponding to each male ant is determined. Therefore, this invention constructs an undirected connected graph together with the resupply points and collection points, allowing for consideration of robot endurance while addressing the inspection task allocation problem. Furthermore, it employs a concurrent approach, constructing several ant colonies to perform population exploration operations simultaneously, thereby improving the algorithm's computational efficiency and solving the problems of insufficient computing power and robot endurance in current large-scale power intelligent inspections.
[0166] See Figure 2 This is a schematic diagram of a collaborative inspection device based on heterogeneous multi-machine collaboration according to an embodiment of the present invention, comprising:
[0167] The data acquisition module is used to acquire several collection points to be inspected within the inspection area, several supply points for refueling the inspection robots, the initial positions and initial resources of several inspection robots performing the inspection, and the number of robots.
[0168] The connected graph construction module is used to determine the connected paths between each collection point and each supply point based on the collection points and the supply points, and to construct an undirected connected graph of the inspection area based on the connected paths; wherein, the collection points and the supply points are all nodes of the undirected connected graph;
[0169] The ant colony building module is used to build several ant colonies and initialize several male ants in the ant colonies according to the number of robots, the initial position, and the initial resources; wherein, each ant colony contains several male ants equal to the number of robots, and in each ant colony, the male ant corresponds one-to-one with the inspection robot;
[0170] The population exploration module employs an ant colony algorithm to repeatedly perform population exploration operations on several ant colonies based on the undirected connected graph, the initial positions of several male ants in the ant colonies, and initial resources, until a target path set is determined from several path sets generated by the ant colonies in the several population exploration operations. The path set consists of several valid paths traversed by several male ants in an ant colony to complete all collection points in the undirected connected graph; each valid path is the path taken by each male ant in the ant colony from one node to another. The target path set is the path set with the shortest completion time and the highest task balance rate among the several path sets.
[0171] The task allocation module is used to determine the inspection task of the inspection robot corresponding to each male ant based on the effective paths explored by each male ant in the target path set.
[0172] It should be noted that the device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Furthermore, in the accompanying drawings of the device embodiments provided by this invention, the connection relationships between modules indicate that they have communication connections, which can be specifically implemented as one or more communication buses or signal lines. Those skilled in the art can understand and implement this without any creative effort.
[0173] Those skilled in the art will clearly understand that, for convenience and brevity, the specific working process of the device described above can be referred to the corresponding process in the foregoing method embodiments, and will not be repeated here.
[0174] Another preferred embodiment of the present invention provides a terminal device, including a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor. When the processor executes the computer program, it implements a collaborative inspection method based on heterogeneous multi-machine collaboration as described in any of the above embodiments.
[0175] The terminal device can be a desktop computer, laptop, handheld computer, or cloud server, etc. The terminal device may include, but is not limited to, a processor and a memory.
[0176] The processor can be a Central Processing Unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor can be a microprocessor or any conventional processor. The processor is the control center of the terminal device, connecting all parts of the terminal device via various interfaces and lines.
[0177] The memory can be used to store the computer program. The processor implements various functions of the terminal device by running or executing the computer program stored in the memory and calling data stored in the memory. The memory may mainly include a program storage area and a data storage area. The program storage area may store the operating system, at least one application program required for a function, etc.; the data storage area may store data created based on the use of the mobile phone, etc. In addition, the memory may include high-speed random access memory, and may also include non-volatile memory, such as hard disk, RAM, plug-in hard disk, smart memory card (SMC), secure digital card (SD) card, flash memory card, at least one disk storage device, flash memory device, or other volatile solid-state storage device.
[0178] Another preferred embodiment of the present invention provides a storage medium, which is a computer-readable storage medium, in which a computer program is stored. When executed by a processor, the computer program can implement the steps of the various method embodiments described above. The computer program includes computer program code, which can be in the form of source code, object code, executable file, or some intermediate form. The computer-readable medium can include any entity or device capable of carrying the computer program code, a recording medium, a USB flash drive, a portable hard drive, a magnetic disk, an optical disk, a computer memory, a read-only memory (ROM), a random access memory (RAM), an electrical carrier signal, a telecommunication signal, and a software distribution medium, etc.
[0179] The above description represents the preferred embodiments of the present invention. It should be noted that those skilled in the art can make various improvements and modifications without departing from the principles of the present invention, and these improvements and modifications are also considered to be within the scope of protection of the present invention.
Claims
1. A collaborative inspection method based on heterogeneous multi-machine collaboration, characterized in that, include: Acquire the following information: several data collection points to be inspected within the inspection area, several resupply points for resupplying and extending the power of the inspection robots, the initial positions and initial resources of the inspection robots to be inspected, and the number of robots. Based on the collection points and the supply points, the connection paths between each collection point and each supply point are determined, and an undirected connected graph of the inspection area is constructed based on the connection paths; wherein, the collection points and the supply points are all nodes of the undirected connected graph. Several ant colonies are constructed, and several male ants in the ant colonies are initialized according to the number of robots, the initial position, and the initial resources; wherein, each ant colony contains several male ants equal to the number of robots, and in each ant colony, the male ant corresponds one-to-one with the inspection robot; An ant colony algorithm is used. Based on the undirected connected graph, the initial positions of several male ants in several ant colonies, and the initial resources, the ant colonies are repeatedly subjected to population exploration operations until a target path set is determined from the path sets generated by the ant colonies in several population exploration operations. The path set consists of several effective paths taken by several male ants in an ant colony to traverse all collection points in the undirected connected graph. The effective path is the path taken by each male ant in the ant colony to move from one node to another. The target path set is the path set with the shortest completion time and the highest task balance rate among the several path sets. Based on the valid paths explored by each male ant in the target path set, determine the inspection task of the inspection robot corresponding to each male ant; The population exploration operation includes: Obtain the global optimal solution, global path pheromone, and global expected reward table; wherein, the global optimal solution is initially empty; the global path pheromone is used to record the pheromone on each valid path in the path set generated by each ant colony, and is initially a preset constant value; the global expected reward table is used to record the reward value of each male ant in each ant colony for exploring the corresponding valid path, and is initially empty; input the undirected connected graph, the global path pheromone, and the global expected reward table into the ant colony that has not performed node exploration operations, so that the ant colony, based on the undirected connected graph, the global path pheromone, the global expected reward table, the initial position of the male ant, and the initial resources, repeatedly perform node exploration operations until the ant colony has explored all collection points and all male ants are at resupply points; after confirming that a target ant colony has explored all collection points and all male ants are at resupply points... When a point is given, the path set of the target ant colony is obtained; a first performance index of the path set is calculated, and the performance index is compared with a second performance index of the global optimal solution. If it is determined that the first performance index of the path set is greater than the second performance index of the current global optimal solution, then the global optimal solution is updated to the path set; wherein, the first performance index and the second performance index are composed of completion time and task balance rate; based on the valid paths in the path set, the global path pheromone and the global expected reward table are updated; it is determined whether the total number of times the ant colonies perform population exploration operations is not less than a preset number threshold; if so, the population exploration operation is re-executed on the target ant colony based on the current global optimal solution, the current global path pheromone, and the current global expected reward table; if not, the global optimal solution is used as the target path set.
2. The collaborative inspection method based on heterogeneous multi-machine collaboration as described in claim 1, characterized in that, The node exploration operation includes: Obtain the current global path pheromone, the current global expected reward table, the current taboo table, the current position of each male ant, and the current resources; wherein, initially, the current position and current resources of each male ant are the initial position and initial resources corresponding to each male ant, and the taboo table is used to record the collection points that the ant colony has explored, and is initially empty; Based on the current location and resources of each male ant, a target male ant is identified for exploring an effective path; Based on the target male ant, the global path pheromone, and the global expected reward table, a target node to be explored is determined; wherein, the target node is a collection point or a resupply point; When the target node is determined as a collection point, the remaining resources of the target male ant after it reaches the target node from its current position are calculated, and the target resupply point closest to the target node is determined. When the target node is determined to be a resupply point, or when the target male ant is determined to be able to reach the target resupply point from its current position using the remaining resources, an effective path is generated based on the current position and the target node. The target node is then used as the new current position of the target male ant, the remaining resources are used as the new current resources of the target male ant, and the target node is added to the taboo list. Determine whether the current taboo list contains all the collection points, and whether all the male ants are at the resupply points; If so, then generate a path set based on several valid paths; If not, proceed to the next round of node exploration.
3. The collaborative inspection method based on heterogeneous multi-machine collaboration as described in claim 2, characterized in that, After calculating the remaining resources after the target male ant reaches the target node from its current position, and determining the nearest target supply point to the target node, the method further includes: After determining that the target male ant has reached the target node from its current location, if it is unable to reach the target supply point using the remaining resources, the global path pheromone and the global expected reward table are updated according to the current number of valid paths, and the taboo table is cleared, and the node exploration operation is re-executed.
4. The collaborative inspection method based on heterogeneous multi-machine collaboration as described in claim 3, characterized in that, The updating of the global path pheromone and the global expected reward table includes: Obtain the path pheromone of each valid path in the global path pheromone; Traverse the male ants and calculate the pheromone left by each male ant on each valid path when it passes through each valid path; Upon completion of the traversal, the total pheromone content along each of the valid paths is calculated; Based on the sum of pheromones for each valid path and the corresponding path pheromone, update the path pheromone of each valid path in the global path pheromone. The effective path is input into a preset reward prediction model so that the reward prediction model outputs the expected reward value on the effective path explored by each male ant, and the expected reward table is updated according to the expected reward value; wherein, the reward prediction model is a model constructed using the Q-learning algorithm.
5. The collaborative inspection method based on heterogeneous multi-machine collaboration as described in claim 4, characterized in that, Based on the target ant, the global path pheromone, and the global expected reward table, a target node to be explored is determined, including: Several collection points not currently recorded in the taboo list, as well as idle supply points, are selected as initial candidate nodes. Based on the current resources of the target male ant, determine several initial candidate nodes that the target male ant can reach as candidate nodes; Calculate the probability that the target male ant will collide with other male ants when it reaches each of the candidate nodes from its current position; A probability value is randomly generated. When the probability value is less than a preset probability, a target node is randomly selected from the candidate nodes using a roulette wheel method. When the probability value is not less than the preset probability, a target node is determined from the candidate nodes based on the conflict probability, the global path pheromone, and the global expected reward table.
6. The collaborative inspection method based on heterogeneous multi-machine collaboration as described in claim 5, characterized in that, The step of determining a target node from the candidate nodes based on the conflict probability, the global path pheromone, and the global expected reward table includes: Based on the current location of the male ant and several candidate nodes, determine the working time for the male ant to travel from its current location to each candidate node and perform the inspection task; Based on the working time and the conflict probability, calculate the heuristic information of each candidate node; The transition probability of each candidate node is determined according to the following formula: ; in, Let be the transition probability of candidate node j. The path pheromone between the current position of the male ant and candidate node j is... This provides heuristic information for candidate node j. The expected reward for the male ant to reach candidate node j from its current position. As a preset pheromone heuristic factor, As a preset expected heuristic factor, As a preset reward heuristic factor, is the set of candidate nodes.
7. A collaborative inspection device based on heterogeneous multi-machine collaboration, characterized in that, include: The data acquisition module is used to acquire several collection points to be inspected within the inspection area, several supply points for refueling the inspection robots, the initial positions and initial resources of several inspection robots performing the inspection, and the number of robots. The connected graph construction module is used to determine the connected paths between each collection point and each supply point based on the collection points and the supply points, and to construct an undirected connected graph of the inspection area based on the connected paths; wherein, the collection points and the supply points are all nodes of the undirected connected graph; The ant colony building module is used to build several ant colonies and initialize several male ants in the ant colonies according to the number of robots, the initial position, and the initial resources; wherein, each ant colony contains several male ants equal to the number of robots, and in each ant colony, the male ant corresponds one-to-one with the inspection robot; The population exploration module employs an ant colony algorithm to repeatedly perform population exploration operations on several ant colonies based on the undirected connected graph, the initial positions of several male ants in the ant colonies, and initial resources, until a target path set is determined from several path sets generated by the ant colonies in the several population exploration operations. The path set consists of several valid paths traversed by several male ants in an ant colony to complete all collection points in the undirected connected graph; each valid path is the path taken by each male ant in the ant colony from one node to another. The target path set is the path set with the shortest completion time and the highest task balance rate among the several path sets. The task allocation module is used to determine the inspection task of the inspection robot corresponding to each male ant based on the effective paths explored by each male ant in the target path set. The population exploration operation includes: Obtain the global optimal solution, global path pheromone, and global expected reward table; wherein, the global optimal solution is initially empty; the global path pheromone is used to record the pheromone on each valid path in the path set generated by each ant colony, and is initially a preset constant value; the global expected reward table is used to record the reward value of each male ant in each ant colony for exploring the corresponding valid path, and is initially empty; input the undirected connected graph, the global path pheromone, and the global expected reward table into the ant colony that has not performed node exploration operations, so that the ant colony, based on the undirected connected graph, the global path pheromone, the global expected reward table, the initial position of the male ant, and the initial resources, repeatedly perform node exploration operations until the ant colony has explored all collection points and all male ants are at resupply points; after confirming that a target ant colony has explored all collection points and all male ants are at resupply points... When a point is given, the path set of the target ant colony is obtained; a first performance index of the path set is calculated, and the performance index is compared with a second performance index of the global optimal solution. If it is determined that the first performance index of the path set is greater than the second performance index of the current global optimal solution, then the global optimal solution is updated to the path set; wherein, the first performance index and the second performance index are composed of completion time and task balance rate; based on the valid paths in the path set, the global path pheromone and the global expected reward table are updated; it is determined whether the total number of times the ant colonies perform population exploration operations is not less than a preset number threshold; if so, the population exploration operation is re-executed on the target ant colony based on the current global optimal solution, the current global path pheromone, and the current global expected reward table; if not, the global optimal solution is used as the target path set.
8. A terminal device, characterized in that, The method includes a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor, wherein the processor executes the computer program to implement a collaborative inspection method based on heterogeneous multi-machine collaboration as described in any one of claims 1 to 6.
9. A storage medium, characterized in that, The storage medium includes a stored computer program, wherein, when the computer program is running, it controls the device where the storage medium is located to execute a collaborative inspection method based on heterogeneous multi-machine collaboration as described in any one of claims 1 to 6.
Citation Information
Patent Citations
Multi-UAV cooperation target searching method based on multi-group ant colony algorithm
CN108829140A
Multi-unmanned aerial vehicle four-dimensional flight path planning method based on improved Q-learning ant colony algorithm
CN117930884A