CN115079704B - Path planning method and device, storage medium and electronic equipment - Google Patents

Path planning method and device, storage medium and electronic equipment Download PDF

Info

Publication number
CN115079704B
CN115079704B CN202210918666.XA CN202210918666A CN115079704B CN 115079704 B CN115079704 B CN 115079704B CN 202210918666 A CN202210918666 A CN 202210918666A CN 115079704 B CN115079704 B CN 115079704B
Authority
CN
China
Prior art keywords
individuals
path
inspection
fitness
determining
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202210918666.XA
Other languages
Chinese (zh)
Other versions
CN115079704A (en
Inventor
邢东旭
亓晓青
许晓莹
刘倩
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China Telecom Corp Ltd
Original Assignee
China Telecom Corp Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by China Telecom Corp Ltd filed Critical China Telecom Corp Ltd
Priority to CN202210918666.XA priority Critical patent/CN115079704B/en
Publication of CN115079704A publication Critical patent/CN115079704A/en
Application granted granted Critical
Publication of CN115079704B publication Critical patent/CN115079704B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05DSYSTEMS FOR CONTROLLING OR REGULATING NON-ELECTRIC VARIABLES
    • G05D1/00Control of position, course or altitude of land, water, air, or space vehicles, e.g. automatic pilot
    • G05D1/02Control of position or course in two dimensions
    • G05D1/021Control of position or course in two dimensions specially adapted to land vehicles
    • G05D1/0231Control of position or course in two dimensions specially adapted to land vehicles using optical position detecting means
    • G05D1/0242Control of position or course in two dimensions specially adapted to land vehicles using optical position detecting means using non-visible light signals, e.g. IR or UV signals
    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05DSYSTEMS FOR CONTROLLING OR REGULATING NON-ELECTRIC VARIABLES
    • G05D1/00Control of position, course or altitude of land, water, air, or space vehicles, e.g. automatic pilot
    • G05D1/02Control of position or course in two dimensions
    • G05D1/021Control of position or course in two dimensions specially adapted to land vehicles
    • G05D1/0212Control of position or course in two dimensions specially adapted to land vehicles with means for defining a desired trajectory
    • G05D1/0221Control of position or course in two dimensions specially adapted to land vehicles with means for defining a desired trajectory involving a learning process
    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05DSYSTEMS FOR CONTROLLING OR REGULATING NON-ELECTRIC VARIABLES
    • G05D1/00Control of position, course or altitude of land, water, air, or space vehicles, e.g. automatic pilot
    • G05D1/02Control of position or course in two dimensions
    • G05D1/021Control of position or course in two dimensions specially adapted to land vehicles
    • G05D1/0212Control of position or course in two dimensions specially adapted to land vehicles with means for defining a desired trajectory
    • G05D1/0223Control of position or course in two dimensions specially adapted to land vehicles with means for defining a desired trajectory involving speed control of the vehicle
    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05DSYSTEMS FOR CONTROLLING OR REGULATING NON-ELECTRIC VARIABLES
    • G05D1/00Control of position, course or altitude of land, water, air, or space vehicles, e.g. automatic pilot
    • G05D1/02Control of position or course in two dimensions
    • G05D1/021Control of position or course in two dimensions specially adapted to land vehicles
    • G05D1/0259Control of position or course in two dimensions specially adapted to land vehicles using magnetic or electromagnetic means
    • G05D1/0263Control of position or course in two dimensions specially adapted to land vehicles using magnetic or electromagnetic means using magnetic strips
    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05DSYSTEMS FOR CONTROLLING OR REGULATING NON-ELECTRIC VARIABLES
    • G05D1/00Control of position, course or altitude of land, water, air, or space vehicles, e.g. automatic pilot
    • G05D1/02Control of position or course in two dimensions
    • G05D1/021Control of position or course in two dimensions specially adapted to land vehicles
    • G05D1/0276Control of position or course in two dimensions specially adapted to land vehicles using signals provided by a source external to the vehicle
    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05DSYSTEMS FOR CONTROLLING OR REGULATING NON-ELECTRIC VARIABLES
    • G05D1/00Control of position, course or altitude of land, water, air, or space vehicles, e.g. automatic pilot
    • G05D1/02Control of position or course in two dimensions
    • G05D1/021Control of position or course in two dimensions specially adapted to land vehicles
    • G05D1/0276Control of position or course in two dimensions specially adapted to land vehicles using signals provided by a source external to the vehicle
    • G05D1/028Control of position or course in two dimensions specially adapted to land vehicles using signals provided by a source external to the vehicle using a RF signal

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Aviation & Aerospace Engineering (AREA)
  • Radar, Positioning & Navigation (AREA)
  • Remote Sensing (AREA)
  • General Physics & Mathematics (AREA)
  • Automation & Control Theory (AREA)
  • Electromagnetism (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The disclosure relates to the technical field of artificial intelligence, in particular to a path planning method, a device storage medium and electronic equipment, wherein the path planning method comprises the following steps: acquiring a grid map of an environment to be inspected, and generating an inspection path according to the grid map, wherein the inspection path comprises inspection nodes; inputting the patrol path as individuals of a parent population in a genetic algorithm into the genetic algorithm, and acquiring an optimal solution of the genetic algorithm, wherein the optimal solution is a first patrol path determined by the genetic algorithm; determining the first connection times of any two routing inspection nodes from the first routing inspection path; inputting the first connection times into an ant colony algorithm, and performing iterative operation according to the first connection times by utilizing the ant colony algorithm to obtain an optimal inspection path. The method and the device can improve the path planning efficiency and improve the accuracy of the path planning result.

Description

Path planning method and device, storage medium and electronic equipment
Technical Field
The disclosure relates to the technical field of artificial intelligence, and in particular relates to a path planning method, a path planning device, a storage medium and electronic equipment.
Background
In many industries, it is necessary to manually inspect a working environment, such as power inspection, mine inspection, machine room inspection, and the like. The manual inspection is low in efficiency and high in labor cost, and in some extreme environments such as high temperature, high humidity, toxic or other dangerous environments, the manual inspection also has the problems of high safety risk and incapability of timely inspection. In order to avoid the above problems of manual inspection, an intelligent robot is generally adopted to inspect the working environment at present. In order to enable the intelligent robot to automatically patrol the patrol environment, the intelligent robot needs to conduct path planning in advance so that the intelligent robot can automatically patrol the working environment according to the planned path.
In the prior art, an ant colony algorithm or a genetic algorithm is generally adopted to plan a path of the intelligent robot. The ant colony algorithm was first proposed by Italian student Marco Dorigo in 1992 in his doctor paper as a probabilistic algorithm for finding optimized paths, and its inspiration is derived from the actions of ants to find paths in the course of finding food. The algorithm has the characteristics of distributed calculation, information positive feedback and heuristic search, and is essentially a heuristic global optimization algorithm in the evolutionary algorithm. However, the ant colony algorithm has low convergence speed, so that the efficiency is lower when the ant colony algorithm is adopted for path planning.
The genetic algorithm is a calculation model of the biological evolution process simulating the natural selection and genetic mechanism of the Darwin biological evolution theory, and is a method for searching the optimal solution by simulating the natural evolution process. The algorithm converts the solving process of the problem into processes like crossing, mutation and the like of chromosome genes in biological evolution by using a computer simulation operation in a mathematical mode. When solving more complex combinatorial optimization problems, better optimization results can generally be obtained faster. However, the genetic algorithm is easy to converge prematurely, so that a certain gap exists between a path planning result determined by the genetic algorithm and an actual optimal inspection path.
It should be noted that the information disclosed in the above background section is only for enhancing understanding of the background of the present disclosure and thus may include information that does not constitute prior art known to those of ordinary skill in the art.
Disclosure of Invention
The disclosure aims to provide a path planning method, a path planning device, a storage medium and an electronic device, so as to overcome the problems of low data acquisition efficiency and low operation efficiency caused by the limitations and defects of the related art at least to a certain extent.
Other features and advantages of the present disclosure will be apparent from the following detailed description, or may be learned in part by the practice of the disclosure.
According to a first aspect of the present disclosure, there is provided a path planning method, comprising:
acquiring a grid map of an environment to be inspected, and generating an inspection path according to the grid map, wherein the inspection path comprises inspection nodes;
inputting the patrol path as individuals of a parent population in a genetic algorithm into the genetic algorithm, and acquiring an optimal solution of the genetic algorithm, wherein the optimal solution is a first patrol path determined by the genetic algorithm;
determining the first connection times of any two routing inspection nodes from the first routing inspection path;
inputting the first connection times into an ant colony algorithm, and performing iterative operation according to the first connection times by utilizing the ant colony algorithm to obtain an optimal inspection path.
In an exemplary embodiment of the present disclosure, the obtaining the optimal solution of the genetic algorithm includes:
the method comprises the steps of circulating a first execution preset step until a preset condition is met, wherein the first preset step comprises the following steps:
acquiring the fitness of each individual in the parent population, and determining the average fitness of the parent population according to the fitness of each individual;
Performing elite preservation on the parent population according to the fitness of each individual and/or the average fitness to obtain an elite preservation result;
calculating the mutation rate and/or the crossover rate of each individual according to the average fitness, and carrying out mutation and/or crossover operation on the elite retention result according to the mutation rate and/or the crossover rate to obtain a offspring population;
if the preset condition is not met, the offspring population is taken as the parent population, and the first preset step is executed again;
and if the preset condition is determined to be met, determining the optimal solution from the child population, wherein the optimal solution is M first individuals with the largest fitness in the child population, and M is an integer greater than 1.
In an exemplary embodiment of the present disclosure, the determining that the preset condition is satisfied includes:
and determining that the preset condition is met when the first number of times of circularly executing the first preset step is larger than or equal to a first preset threshold value or the fitness of the individuals in the offspring population is consistent with the fitness of the individuals in the parent population.
In an exemplary embodiment of the disclosure, said performing elite preservation on said population according to said fitness of each of said individuals and/or said average fitness, obtaining elite preservation results comprises:
Sequencing the individuals according to the fitness of the individuals from big to small to generate an individual sequence;
copying individuals with preset proportions before the individual sequences to obtain copied individuals;
determining said elite retention result from each said individual and said replicated individual according to said fitness of each said individual and/or said average fitness.
In an exemplary embodiment of the present disclosure, said determining said elite retention result from each of said individuals and said replicated individuals according to said fitness of each of said individuals and/or said average fitness comprises:
n individuals with the largest fitness among the individuals and the copied individuals according to the fitness of the individuals, and taking the N individuals as elite retention results, wherein N is an integer greater than 1; or alternatively, the first and second heat exchangers may be,
and determining a target individual with a fitness greater than or equal to the average fitness from the individuals and the duplicate individuals according to the fitness of the individuals and the average fitness, and taking the target individual as the elite retention result.
In an exemplary embodiment of the present disclosure, the performing an iterative operation according to the first connection number using the ant colony algorithm includes:
And circularly executing a second preset step until the second times of circularly executing the second preset step is larger than or equal to a second preset threshold value, wherein the second preset step comprises the following steps:
determining a first transition probability of any two routing inspection nodes according to the first connection times;
placing ants at the initial node for inspection, and determining the next node to be inspected of the ants according to the first transfer probability, so that the ants inspect the next node to be inspected;
when ants reach the next node to be inspected, taking the next node to be inspected as a current inspection node and acquiring the position information of the ants at the current inspection node;
if the ants are determined to not reach the termination node according to the position information, determining the next node to be inspected of the ants according to the first transfer probability, so that the ants inspect the next node to be inspected;
and if the ants reach the termination node according to the position information, acquiring a second routing inspection path of the ants.
In an exemplary embodiment of the present disclosure, after the acquiring the second inspection path of the ant, the method further includes:
if the second times are smaller than the second preset threshold, determining second connection times of any two routing inspection nodes from the second routing inspection path;
Calculating the sum of the first connection times and the second connection times;
and taking the sum value as the first connection times, and executing the second preset step again.
In an exemplary embodiment of the present disclosure, the acquiring the optimal patrol path includes:
if the second time is greater than or equal to the second preset threshold value, determining a target routing inspection path with the shortest length from the second routing inspection paths;
and taking the target inspection path as the optimal inspection path.
In an exemplary embodiment of the disclosure, the determining the next node to be patrol for ants according to the first transition probability includes:
acquiring a tabu list of ants, wherein the tabu list comprises inspection nodes inspected by the ants;
determining nodes to be inspected according to the tabu list;
calculating a second transition probability of the current routing inspection node and the node to be routing inspection;
and taking the node to be patrolled and examined with the maximum second transition probability as the next patrolling and examining node.
In an exemplary embodiment of the present disclosure, the determining the transition probabilities of the arbitrary two routing nodes according to the first connection times includes:
calculating pheromones of the arbitrary two nodes according to the first connection times and pheromone volatilization factors, wherein the pheromone volatilization factors are inversely related to the second times;
And calculating the first transition probability according to the pheromone and the distance between any two nodes.
According to a second aspect of the present disclosure, there is provided a path planning apparatus comprising:
the system comprises a routing inspection path generation module, a routing inspection module and a routing inspection module, wherein the routing inspection path generation module is used for acquiring a grid map of an environment to be inspected and generating a routing inspection path according to the grid map, and the routing inspection path comprises routing inspection nodes;
the optimal solution acquisition module is used for inputting the routing inspection path as an individual of a parent population in a genetic algorithm into the genetic algorithm and acquiring an optimal solution of the genetic algorithm, wherein the optimal solution is a first routing inspection path determined by the genetic algorithm;
the connection frequency determining module is used for determining the first connection frequency of any two routing inspection nodes from the first routing inspection path;
and the optimal routing inspection path determining module is used for inputting the first connection times into an ant colony algorithm, and carrying out iterative operation according to the first connection times by utilizing the ant colony algorithm so as to obtain an optimal routing inspection path.
According to a third aspect of the present disclosure, there is provided a computer readable storage medium having stored thereon a computer program which when executed by a processor implements the steps of the method of any of the first aspects.
According to a fourth aspect of the present disclosure, there is provided an electronic device comprising:
a processor; and
a memory for storing executable instructions of the processor;
wherein the processor is configured to perform the steps of the method of any of the first aspects via execution of the executable instructions.
The technical scheme provided by the embodiment of the disclosure can comprise the following beneficial effects:
in summary, according to the method provided by the disclosure, a grid map of an environment to be inspected is obtained, and an inspection path is generated according to the grid map, wherein the inspection path comprises inspection nodes; inputting the patrol path as individuals of a parent population in a genetic algorithm into the genetic algorithm, and acquiring an optimal solution of the genetic algorithm, wherein the optimal solution is a first patrol path determined by the genetic algorithm; determining the first connection times of any two routing inspection nodes from the first routing inspection path; inputting the first connection times into an ant colony algorithm, carrying out iterative operation according to the first connection times by utilizing the ant colony algorithm to obtain an optimal routing inspection path, firstly accelerating convergence speed by adopting a genetic algorithm, improving path planning efficiency, then obtaining the optimal routing inspection path by utilizing the ant colony algorithm, and improving accuracy of path planning results.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the disclosure.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the disclosure and together with the description, serve to explain the principles of the disclosure. It will be apparent to those of ordinary skill in the art that the drawings in the following description are merely examples of the disclosure and that other drawings may be derived from them without undue effort.
FIG. 1 schematically illustrates a flow chart of a path planning method in an exemplary embodiment of the present disclosure;
FIG. 2 schematically illustrates an architecture diagram of a path planning system in an exemplary embodiment of the present disclosure;
FIG. 3 schematically illustrates a schematic diagram of a grid map of an environment to be inspected in an exemplary embodiment of the present disclosure;
FIG. 4 schematically illustrates a flowchart of a genetic algorithm optimal solution acquisition method in an exemplary embodiment of the present disclosure;
FIG. 5 schematically illustrates a flowchart of an iterative method of operation in an exemplary embodiment of the present disclosure;
FIG. 6 schematically illustrates a schematic diagram of an optimal inspection path in an exemplary embodiment of the present disclosure;
Fig. 7 schematically illustrates a block diagram of a path planning apparatus in an exemplary embodiment of the present disclosure;
FIG. 8 schematically illustrates a schematic diagram of a storage medium in an exemplary embodiment of the present disclosure;
fig. 9 schematically illustrates a block diagram of an electronic device in an exemplary embodiment of the present disclosure.
In the drawings, the same or corresponding reference numerals indicate the same or corresponding parts.
Detailed Description
The principles and spirit of the present invention will be described below with reference to several exemplary embodiments. It should be understood that these embodiments are presented merely to enable those skilled in the art to better understand and practice the invention and are not intended to limit the scope of the invention in any way. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the disclosure to those skilled in the art.
Those skilled in the art will appreciate that embodiments of the invention may be implemented as a system, apparatus, device, method, or computer program product. Accordingly, the present disclosure may be embodied in the following forms, namely: complete hardware, complete software (including firmware, resident software, micro-code, etc.), or a combination of hardware and software.
In one exemplary embodiment of the present disclosure, a path planning method is first provided. Referring to fig. 1, the path planning method may include the steps of:
s11, acquiring a grid map of an environment to be inspected, and generating an inspection path according to the grid map, wherein the inspection path comprises inspection nodes;
s12, inputting the patrol path as an individual of a parent population in a genetic algorithm into the genetic algorithm, and acquiring an optimal solution of the genetic algorithm, wherein the optimal solution is a first patrol path determined by the genetic algorithm;
s13, determining first connection times of any two routing inspection nodes from the first routing inspection path;
s14, inputting the first connection times into an ant colony algorithm, and performing iterative operation according to the first connection times by utilizing the ant colony algorithm to obtain an optimal inspection path.
In summary, according to the method provided by the disclosure, a grid map of an environment to be inspected is obtained, and an inspection path is generated according to the grid map, wherein the inspection path comprises inspection nodes; inputting the patrol path as individuals of a parent population in a genetic algorithm into the genetic algorithm, and acquiring an optimal solution of the genetic algorithm, wherein the optimal solution is a first patrol path determined by the genetic algorithm; determining the first connection times of any two routing inspection nodes from the first routing inspection path; inputting the first connection times into an ant colony algorithm, carrying out iterative operation according to the first connection times by utilizing the ant colony algorithm to obtain an optimal routing inspection path, firstly accelerating convergence speed by adopting a genetic algorithm, improving path planning efficiency, and then obtaining the optimal routing inspection path by utilizing the ant colony algorithm to improve path planning accuracy.
Each step in the path planning method in the present exemplary embodiment will be described in more detail with reference to the accompanying drawings and examples.
In S11, a grid map of an environment to be inspected is obtained, and an inspection path is generated according to the grid map, where the inspection path includes inspection nodes.
In one exemplary embodiment of the present disclosure, referring to the system architecture shown in fig. 2, may include: an intelligent terminal device 201, a server 203, etc., wherein the intelligent terminal device 201 may be provided on a path inspection device such as an intelligent robot. Data transmission between the intelligent terminal device 201 and the server 203 can be performed through the network 202. The network may include various connection types, such as wired communication links, wireless communication links, and the like. The path planning method can be executed at the server side, the intelligent terminal equipment or cooperatively executed by the intelligent terminal equipment and the server side. Taking the method as an example, the server can acquire a grid map of the environment to be patrolled and examined, and acquire the optimal patrolling path according to the grid map. Further, after the server obtains the optimal inspection path, an inspection instruction is sent to the intelligent robot according to the optimal inspection path, so that the intelligent robot inspects the environment to be inspected according to the optimal inspection path.
In an exemplary embodiment of the present disclosure, the environment to be inspected may be an inspection environment such as power inspection, mine inspection, machine room inspection, etc., and is not particularly limited herein. The grid map of the environment to be inspected is shown in fig. 2, wherein the grid map comprises a plurality of grids, and each grid represents one node of the environment to be inspected. Wherein the numbers within each grid represent the location information of the node. In one exemplary embodiment of the present disclosure, the location information of each node of the environment to be surveyed may be represented by each value in a continuous array. Further, the blank grid on the grid map represents the nodes which can pass through in the environment to be inspected, the grid with a dotted line on the grid map represents the nodes which need to be inspected in the environment to be inspected (hereinafter referred to as inspection nodes for short), and the grid with a solid line on the grid map represents the nodes which cannot pass through in the environment to be inspected, namely the obstacle nodes.
Further, after the grid map is obtained, a patrol path is generated according to the grid map. Each path consists of all routing inspection nodes and nodes which can pass through.
In step S12, the patrol path is input into the genetic algorithm as an individual of a parent population in the genetic algorithm, and an optimal solution of the genetic algorithm is obtained, where the optimal solution is a first patrol path determined by the genetic algorithm.
Based on the foregoing, in an exemplary embodiment of the present disclosure, as shown in fig. 4, the acquiring the optimal solution of the genetic algorithm includes:
the method comprises the steps of circulating a first execution preset step until a preset condition is met, wherein the first preset step comprises the following steps:
s121, acquiring the fitness of each individual in the parent population, and determining the average fitness of the parent population according to the fitness of each individual;
s122, elite preservation is carried out on the parent population according to the fitness of each individual and/or the average fitness, and an elite preservation result is obtained;
s123, calculating the mutation rate and/or the crossover rate of each individual according to the average fitness, and carrying out mutation and/or crossover operation on the elite retention result according to the mutation rate and/or the crossover rate to obtain a offspring population;
s124, if the preset condition is not met, taking the offspring population as the parent population, and executing the first preset step again;
and S125, if the preset condition is determined to be met, determining the optimal solution from the child population, wherein the optimal solution is M first individuals with the largest fitness in the child population, and M is an integer larger than 1.
In one exemplary embodiment of the present disclosure, the fitness of each of the individuals in the parent population may be calculated according to equation (1). Equation (1) is shown below:
wherein, fit represents the fitness,L(P i +P i+1 ) Representing the distance between every two adjacent nodes in each individual (i.e. each inspection path), P i And P i+1 Representing two adjacent nodes, T representing the number of nodes in the patrol path.
Further, after the fitness of each individual is determined, determining the average fitness of the parent population according to the fitness of each individual, and performing elite preservation on the parent population according to the fitness of each individual and/or the average fitness to obtain an elite preservation result.
In an exemplary embodiment of the present disclosure, performing elite preservation on the population according to the fitness of each individual and/or the average fitness, and obtaining an elite preservation result includes:
sequencing the individuals according to the fitness of the individuals from big to small to generate an individual sequence; copying individuals with preset proportions before the individual sequences to obtain copied individuals; determining said elite retention result from each said individual and said replicated individual according to said fitness of each said individual and/or said average fitness.
For example, each of the individuals has an individual sequence A, B, C, D, E, F, G, H generated by sorting the individuals in order of fitness from large to small. And (3) copying the individuals 1/4 of the sequence of the individuals in front of the sequence of the individuals into two parts, namely copying the individuals A and B into two parts respectively, and copying the individuals 1/2 of the sequence of the individuals into one part, namely copying the individuals C, D, E, F into one part, so as to obtain the copied individuals. And determining the elite retention result from each individual and the duplicate individual according to the fitness of each individual and/or the average fitness.
In one exemplary embodiment of the present disclosure, determining the elite retention result from each of the individuals and the replicated individuals according to the fitness of each of the individuals and/or the average fitness comprises:
n individuals with the largest fitness among the individuals and the copied individuals according to the fitness of the individuals, and taking the N individuals as elite retention results, wherein N is an integer greater than 1; or, determining a target individual having a fitness greater than or equal to the average fitness from among the individuals and the duplicated individuals based on the fitness of the individuals and the average fitness, and taking the target individual as the elite retention result.
For example, N has a value of 8, and each individual is A, B, C, D, E, F, G, H. The duplicate individual was A, A, B, B, C, D, E, F. The 8 individuals with the greatest fitness determined from each of the individuals and the duplicate individuals are A, B, C, A, A, B, B, C, respectively, and the 8 individuals A, B, C, A, A, B, B, C with the greatest fitness are taken as elite retention results.
For another example, if the average fitness is between fitness of the individual D and fitness of the individual E, the target individual determined from each of the individual and the duplicate individual is A, B, C, D, A, A, B, B, C, D, and the target individual A, B, C, D, A, A, B, B, C, D is used as an elite retention result.
Further, after the elite retention result is obtained, calculating the mutation rate and/or the crossover rate of each individual according to the average fitness, and carrying out mutation and/or crossover operation on the elite retention result according to the mutation rate and/or the crossover rate to obtain a offspring population.
In one exemplary embodiment of the present disclosure, the variability and/or crossover rate of each of the individuals may be according to equation (2). Equation (2) is shown below:
wherein P is c The cross-over rate is indicated as such, P m Represents the mutation rate, N 1 Indicating fitness of individuals having fitness greater than or equal to the average fitness among the individuals, N 2 Represents the average fitness value, N Indicating the maximum fitness in each of the individuals.
In an exemplary embodiment of the present disclosure, if the individual a in the parent population is 123456789, the individual B in the parent population is 142358679, and the cross operation is performed on A, B, the node after the node 5 in a may be replaced with the node after the node 5 in B, and the node before the node 5 in B may be replaced with the node before the node 5 in a. After the crossover operation of A, B, individuals a and b in the resulting offspring population were 123458679 and 142356789, respectively.
As can be seen from the formula (2), the higher the fitness of the individual, the higher the crossing rate and the lower the mutation rate. The lower the fitness of the individual, the smaller the crossover rate and the larger the mutation rate. Therefore, the genes of good individuals in the population can be better preserved and cannot be destroyed. And for bad individuals in the population, the introduction of new genes is facilitated, and the performance of a genetic algorithm can be improved.
In an exemplary embodiment of the present disclosure, individual a in the parent population is 123456789, node 3 and node 7 in a may be interchanged when mutation is performed on a, and individual a in the resulting child population is 127456389.
Further, after obtaining a child population, if it is determined that the preset condition is not met, taking the child population as the parent population, and executing the first preset step again; and if the preset condition is determined to be met, determining the optimal solution from the child population, wherein the optimal solution is M first individuals with the largest fitness in the child population, and M is an integer greater than 1.
In an exemplary embodiment of the present disclosure, the determining that the preset condition is satisfied includes:
and determining that the preset condition is met when the first number of times of circularly executing the first preset step is larger than or equal to a first preset threshold value or the fitness of the individuals in the offspring population is consistent with the fitness of the individuals in the parent population.
In an exemplary embodiment of the present disclosure, if the first preset threshold is 100, when the first number is greater than or equal to 100, it is determined that a preset condition is satisfied, and M first individuals with the greatest fitness are obtained from the child population as the optimal solution.
In another exemplary embodiment of the present disclosure, when the fitness of the individuals in the child population is consistent with the fitness of the individuals in the parent population, it is determined that a preset condition is satisfied, and M first individuals with the greatest fitness are obtained from the child population as the optimal solution.
In step S13, a first connection number of any two routing inspection nodes is determined from the first routing inspection path.
In one exemplary embodiment of the present disclosure, the first connection number s of any two inspection points (i, j) is calculated in the M first individuals, i.e., M first inspection paths, of the obtained optimal solution of the genetic algorithm ij (0)。
In step S14, the first connection number is input into an ant colony algorithm, and an iterative operation is performed according to the first connection number by using the ant colony algorithm, so as to obtain an optimal inspection path.
Based on the above, as shown in fig. 5, in an exemplary embodiment of the present disclosure, the performing the iterative operation according to the first connection number using the ant colony algorithm includes:
and circularly executing a second preset step until the second times of circularly executing the second preset step is larger than or equal to a second preset threshold value, wherein the second preset step comprises the following steps:
s141, determining first transition probabilities of any two routing inspection nodes according to first connection times;
s142, placing ants at the initial node for inspection, and determining a next node to be inspected of the ants according to the first transfer probability so that the ants inspect the next node to be inspected;
S143, when ants reach the next node to be inspected, taking the next node to be inspected as a current inspection node and acquiring the position information of the ants at the current inspection node;
s144, if the ants are determined to not reach the termination node according to the position information, determining the next node to be inspected of the ants according to the first transfer probability so that the ants inspect the next node to be inspected;
and S145, if the ants reach the termination node according to the position information, acquiring a second routing inspection path of the ants.
In an exemplary embodiment of the present disclosure, determining the transition probabilities of the two routing inspection nodes according to the first connection times includes:
calculating pheromones of the arbitrary two nodes according to the first connection times and pheromone volatilization factors, wherein the pheromone volatilization factors are inversely related to the second times; and calculating the first transition probability according to the pheromone and the distance between any two nodes.
Specifically, the pheromone may be calculated according to formula (3). Equation (3) is shown below:
wherein τ represents the pheromone, t represents the second number of times, ρ represents the normalized second number of times, f (ρ) represents the pheromone volatilization factor, τ ij And (3) representing the pheromone, n representing the number of the inspection nodes in the environment to be inspected, lambda representing the parameter of the scale, and u representing the parameter of the position.
It should be noted that, before the second preset step is circularly executed, i.e., when t=0, the first connection number is s calculated according to the optimal solution M of the genetic algorithm for the first inspection path ij (0),τ ij (0)=S ij (0) +p, p is a pheromone constant, and p is greater than 0.
The formula (3) shows that the pheromone volatilization factors are distributed by using the Laplace probability density function, so that the method can be suitable for updating the pheromone volatilization factors, and on the basis of a certain pheromone, the pheromone volatilization factors are increased at the initial iteration stage of the ant colony algorithm, so that the speed of searching the optimal routing inspection path of the ant colony algorithm is accelerated; at the later stage of algorithm iteration, the pheromone volatilization factor is reduced, and the convergence rate of the ant colony algorithm is accelerated.
Further, after the pheromone is determined, the first transition probability is calculated according to formula (4). Equation (4) is shown below:
wherein A is k ={C-tabU k },tabU k And a tabu table for representing the kth ants, wherein the tabu table is used for counting inspection nodes inspected by the kth ants, k is smaller than or equal to m, and m represents the number of the ants. C represents the set of inspection nodes, alpha represents a pheromone heuristic factor, eta is Representing desirability between inspection node i and inspection node s, β representing desirability heuristic factor, η is =1/d is ,d is Indicating the distance from the patrol node i to the patrol node s.
In an exemplary embodiment of the present disclosure, the determining the next node to be inspected of the ant according to the first transition probability includes:
acquiring a tabu list of ants, wherein the tabu list comprises inspection nodes inspected by the ants; determining nodes to be inspected according to the tabu list; calculating a second transition probability of the current routing inspection node and the node to be routing inspection; and taking the node to be patrolled and examined with the maximum second transition probability as the next patrolling and examining node.
Specifically, j in the formula (4) is the node to be patrolled and examined except for the patrolling and examining node in the tabu table. When the current routing inspection node is i, respectively calculating second transition probabilities of the current routing inspection node and each node to be routing inspectedAnd then from the corresponding +.>And (3) determining the maximum value, and taking the node to be inspected corresponding to the maximum value as the next inspection node.
Based on the foregoing, in an exemplary embodiment of the disclosure, after the second inspection path of the ant is obtained, the method further includes:
S146, if the second times are smaller than the second preset threshold, determining second connection times of any two routing inspection nodes from the second routing inspection path;
s147, calculating the sum of the first connection times and the second connection times;
s148, taking the sum value as the first connection times, and executing the second preset step again.
Specifically, when the second number t is smaller than the second preset threshold, after the second inspection paths of m ants are obtained, the second connection numbers of the arbitrary two inspection nodes i and j are obtained from the m second inspection paths, the sum of the first connection numbers and the second connection numbers is calculated, the sum is used as the first connection number, and the second preset step is executed again.
Based on the foregoing, in an exemplary embodiment of the disclosure, the acquiring the optimal routing path includes:
s149, if the second time is greater than or equal to the second preset threshold, determining a target routing inspection path with the shortest length from the second routing inspection paths;
s150, taking the target inspection path as the optimal inspection path.
Specifically, when the second time t is greater than or equal to the second preset threshold, the target routing inspection path with the shortest length is obtained from m second routing inspection paths to be used as the optimal routing inspection path.
In an exemplary embodiment of the present disclosure, after the path planning is performed on the grid map of the environment to be inspected as illustrated in fig. 2 by using the method of the present disclosure, the final obtained optimal inspection path may be as shown in fig. 6. In fig. 6, the start node and the end node are 242, and the ant starts to patrol the environment to be patrol at 242, and after the patrol is finished, the ant leaves the environment to be patrol at 242. The best inspection path obtained finally is the line in fig. 6.
In summary, according to the method disclosed by the disclosure, on one hand, the superior performances such as parallelism, high efficiency and global searching performance of the genetic algorithm are fully utilized as priori information of the optimal routing inspection path solved by the ant colony algorithm, the pheromone can be rapidly obtained by changing the inherent calculation modes of the intersection rate and the mutation rate, and then the robustness and positive feedback performance of the ant colony algorithm are fully utilized, so that the searching efficiency of the optimal routing inspection path is improved. In still another aspect, by improving the pheromone volatilization factor in the ant colony algorithm, the early-stage pheromone volatilization factor is improved, the searching speed of the ant colony algorithm can be improved, the pheromone volatilization factor is reduced in the later stage, the convergence speed of the ant colony algorithm can be accelerated, and then the optimal inspection path can be obtained more quickly and accurately.
Having introduced a path planning method of an exemplary embodiment of the present invention, a path planning apparatus of an exemplary embodiment of the present invention will be described next with reference to fig. 7.
Referring to fig. 7, a path planning apparatus 70 of an exemplary embodiment of the present invention may include: the system comprises a patrol path generation module 701, an optimal solution acquisition module 702, a connection number determination module 703 and an optimal patrol path determination module 704. Wherein:
the inspection path generation module 701 is configured to obtain a grid map of an environment to be inspected, and generate an inspection path according to the grid map, where the inspection path includes inspection nodes;
the optimal solution obtaining module 702 is configured to input the routing inspection path as an individual of a parent population in a genetic algorithm into the genetic algorithm, and obtain an optimal solution of the genetic algorithm, where the optimal solution is a first routing inspection path determined by the genetic algorithm;
a connection number determining module 703, configured to determine a first connection number of any two routing inspection nodes from the first routing inspection path;
the best inspection path determining module 704 is configured to input the first connection number into an ant colony algorithm, and perform iterative operation according to the first connection number by using the ant colony algorithm, so as to obtain a best inspection path.
In an exemplary embodiment of the present disclosure, the optimal solution obtaining module includes:
the first execution preset step execution unit is configured to cycle the first execution preset step until a preset condition is met, where the first preset step includes:
acquiring the fitness of each individual in the parent population, and determining the average fitness of the parent population according to the fitness of each individual;
performing elite preservation on the parent population according to the fitness of each individual and/or the average fitness to obtain an elite preservation result;
calculating the mutation rate and/or the crossover rate of each individual according to the average fitness, and carrying out mutation and/or crossover operation on the elite retention result according to the mutation rate and/or the crossover rate to obtain a offspring population;
if the preset condition is not met, the offspring population is taken as the parent population, and the first preset step is executed again;
and the optimal solution determining unit is used for determining the optimal solution from the child population if the preset condition is met, wherein the optimal solution is M first individuals with the largest fitness in the child population, and M is an integer larger than 1.
In an exemplary embodiment of the present disclosure, the first performing preset step performing unit includes:
and the preset condition determining unit is used for determining that the preset condition is met when the first number of times of circularly executing the first preset step is larger than or equal to a first preset threshold value or the fitness of the individuals in the offspring population is consistent with that of the individuals in the parent population.
In an exemplary embodiment of the present disclosure, the first performing preset step performing unit further includes:
the individual sequencing unit is used for sequencing the individuals according to the fitness of the individuals from big to small to generate an individual sequence;
the individual copying unit is used for copying individuals with a preset proportion in front of the individual sequence to obtain copied individuals;
an elite retention unit for determining said elite retention result from each of said individuals and said replicated individuals according to said fitness of each of said individuals and/or said average fitness.
In an exemplary embodiment of the present disclosure, the elite retention unit comprises:
a first elite reserving unit configured to reserve N individuals having the greatest fitness among the individuals and the duplicate individuals according to the fitness of the individuals, and to use the N individuals as elite reserving results, where N is an integer greater than 1; or alternatively, the first and second heat exchangers may be,
A second elite preservation unit configured to determine a target individual having a fitness greater than or equal to the average fitness from among the individuals and the duplicated individuals based on the fitness of the individuals and the average fitness, and to take the target individual as the elite preservation result.
In an exemplary embodiment of the present disclosure, the optimal patrol path determining module includes:
the second preset step execution unit is configured to cyclically execute a second preset step until a second number of times of cyclically executing the second preset step is greater than or equal to a second preset threshold, where the second preset step includes:
determining a first transition probability of any two routing inspection nodes according to the first connection times;
placing ants at the initial node for inspection, and determining the next node to be inspected of the ants according to the first transfer probability, so that the ants inspect the next node to be inspected;
when ants reach the next node to be inspected, taking the next node to be inspected as a current inspection node and acquiring the position information of the ants at the current inspection node;
if the ants are determined to not reach the termination node according to the position information, determining the next node to be inspected of the ants according to the first transfer probability, so that the ants inspect the next node to be inspected;
And if the ants reach the termination node according to the position information, acquiring a second routing inspection path of the ants.
In an exemplary embodiment of the present disclosure, the second preset step execution unit further includes:
a second connection number determining unit, configured to determine, if it is determined that the second number is smaller than the second preset threshold, a second connection number of the any two routing inspection nodes from the second routing inspection path;
a sum value calculation unit configured to calculate a sum value of the first connection number and the second connection number;
and a first connection number determining unit, configured to take the sum value as the first connection number, and execute the second preset step again.
In an exemplary embodiment of the present disclosure, the optimal patrol path determining module further includes:
the target routing path determining unit is used for determining a target routing path with the shortest length from the second routing path if the second time is greater than or equal to the second preset threshold value;
and the optimal inspection path determining unit is used for taking the target inspection path as the optimal inspection path.
In an exemplary embodiment of the present disclosure, the second preset step cycle execution unit further includes:
The tabu table acquisition unit is used for acquiring the tabu table of ants, wherein the tabu table comprises inspection nodes inspected by the ants;
the node to be patrolled and examined determining unit is used for determining the node to be patrolled and examined according to the tabu list;
the second transition probability calculation unit is used for calculating the second transition probability of the current routing inspection node and the node to be routing inspected;
and the next inspection node determining unit is used for taking the node to be inspected with the maximum second transition probability as the next inspection node.
In an exemplary embodiment of the present disclosure, the second preset step execution unit further includes:
a pheromone determining unit, configured to calculate the pheromone of the arbitrary two nodes according to the first connection times and a pheromone volatilization factor, where the pheromone volatilization factor is inversely related to the second times;
and the first transition probability calculation unit is used for calculating the first transition probability according to the pheromone and the distance between any two nodes.
Since each functional module of the path planning apparatus according to the embodiment of the present invention is the same as that of the above-described path planning method according to the embodiment of the present invention, a detailed description thereof will be omitted.
Having described the path planning method and the path planning apparatus according to the exemplary embodiment of the present invention, a storage medium according to the exemplary embodiment of the present invention will be described with reference to fig. 8.
Referring to fig. 8, a program product 800 for implementing the above-described method according to an embodiment of the present invention is described, which may employ a portable compact disc read only memory (CD-ROM) and include program code, and may be run on a device, such as a personal computer. However, the program product of the present invention is not limited thereto, and in this document, a readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device.
The program product may employ any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. The readable storage medium can be, for example, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or a combination of any of the foregoing. More specific examples (a non-exhaustive list) of the readable storage medium would include the following: an electrical connection having one or more wires, a portable disk, a hard disk, random Access Memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
The computer readable signal medium may include a data signal propagated in baseband or as part of a carrier wave with readable program code embodied therein. Such a propagated data signal may take any of a variety of forms, including, but not limited to, electro-magnetic, optical, or any suitable combination of the foregoing. A readable signal medium may also be any readable medium that is not a readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device.
Program code embodied on a readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing.
Program code for carrying out operations of the present invention may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, C++ or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computing device, partly on a remote computing device, or entirely on the remote computing device or server. In the case of remote computing devices, the remote computing device may be connected to the user computing device through any kind of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or may be connected to an external computing device (e.g., connected via the Internet using an Internet service provider).
Having described the storage medium of the exemplary embodiment of the present invention, next, an electronic device of the exemplary embodiment of the present invention will be described with reference to fig. 9.
The electronic device 90 shown in fig. 9 is merely an example, and should not be construed as limiting the functionality and scope of use of embodiments of the present invention.
As shown in fig. 9, the electronic device 90 is in the form of a general purpose computing device. Components of the electronic device 90 may include, but are not limited to: the at least one processing unit 910, the at least one storage unit 920, a bus 930 connecting the different system components (including the storage unit 920 and the processing unit 910), and a display unit 940.
Wherein the storage unit stores program code that is executable by the processing unit 910 such that the processing unit 910 performs steps according to various exemplary embodiments of the present invention described in the above-described "exemplary methods" section of the present specification. For example, the processing unit 910 may perform steps S11 to S14 as shown in fig. 1.
The storage unit 920 may include volatile storage units such as a Random Access Memory (RAM) 9201 and/or a cache memory 9202, and may further include a Read Only Memory (ROM) 9203. The storage unit 920 may also include a program/utility 9204 having a set (at least one) of program modules 9205, such program modules 9205 include, but are not limited to: an operating system, one or more application programs, other program modules, and program data, each or some combination of which may include an implementation of a network environment.
Bus 930 may include a data bus, an address bus, and a control bus.
The electronic device 90 may also communicate with one or more external devices 100 (e.g., keyboard, pointing device, bluetooth device, etc.) via an input/output (I/O) interface 950. The electronic device 90 also includes a display unit 940 that is connected to an input/output (I/O) interface 950 for display. Also, electronic device 90 may communicate with one or more networks such as a Local Area Network (LAN), a Wide Area Network (WAN), and/or a public network, such as the Internet, through network adapter 960. As shown, the network adapter 960 communicates with other modules of the electronic device 90 over the bus 930. It should be appreciated that although not shown, other hardware and/or software modules may be used in connection with electronic device 90, including, but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, data backup storage systems, and the like.
It should be noted that although several modules or sub-modules of the path planning apparatus are mentioned in the above detailed description, this division is merely exemplary and not mandatory. Indeed, the features and functionality of two or more units/modules described above may be embodied in one unit/module in accordance with embodiments of the present invention. Conversely, the features and functions of one unit/module described above may be further divided into ones that are embodied by a plurality of units/modules.
Furthermore, although the operations of the methods of the present invention are depicted in the drawings in a particular order, this is not required to either imply that the operations must be performed in that particular order or that all of the illustrated operations be performed to achieve desirable results. Additionally or alternatively, certain steps may be omitted, multiple steps combined into one step to perform, and/or one step decomposed into multiple steps to perform.
While the spirit and principles of the present invention have been described with reference to several particular embodiments, it is to be understood that the invention is not limited to the disclosed embodiments nor does it imply that features of the various aspects are not useful in combination, nor are they useful in any combination, such as for convenience of description. The invention is intended to cover various modifications and equivalent arrangements included within the spirit and scope of the appended claims.

Claims (11)

1. A method of path planning, comprising:
acquiring a grid map of an environment to be inspected, and generating an inspection path according to the grid map, wherein the inspection path comprises inspection nodes;
inputting the patrol path as individuals of a parent population in a genetic algorithm into the genetic algorithm, and acquiring an optimal solution of the genetic algorithm, wherein the optimal solution is a first patrol path determined by the genetic algorithm;
Determining the first connection times of any two routing inspection nodes from the first routing inspection path;
inputting the first connection times into an ant colony algorithm, and performing iterative operation according to the first connection times by utilizing the ant colony algorithm to obtain an optimal inspection path;
the performing iterative operation according to the first connection times by using the ant colony algorithm comprises:
and circularly executing a second preset step until the second times of circularly executing the second preset step is larger than or equal to a second preset threshold value, wherein the second preset step comprises the following steps:
determining a first transition probability of any two routing inspection nodes according to the first connection times;
placing ants at the initial node for inspection, and determining the next node to be inspected of the ants according to the first transfer probability, so that the ants inspect the next node to be inspected;
when ants reach the next node to be inspected, taking the next node to be inspected as a current inspection node and acquiring the position information of the ants at the current inspection node;
if the ants do not reach the termination node according to the position information, determining the next node to be inspected of the ants according to the first transfer probability, so that the ants inspect the next node to be inspected;
If the ants reach the termination node according to the position information, acquiring a second routing inspection path of the ants;
the obtaining the optimal inspection path comprises the following steps:
if the second time is greater than or equal to the second preset threshold value, determining a target routing inspection path with the shortest length from the second routing inspection paths;
and taking the target inspection path as the optimal inspection path.
2. The method of claim 1, wherein the obtaining the optimal solution for the genetic algorithm comprises:
a first preset step is circularly executed until a preset condition is met, wherein the first preset step comprises the following steps:
acquiring the fitness of each individual in the parent population, and determining the average fitness of the parent population according to the fitness of each individual;
performing elite preservation on the parent population according to the fitness of each individual and/or the average fitness to obtain an elite preservation result;
calculating the mutation rate and/or the crossover rate of each individual according to the average fitness, and carrying out mutation and/or crossover operation on the elite retention result according to the mutation rate and/or the crossover rate to obtain a offspring population;
If the preset condition is not met, the offspring population is used as the parent population, and the preset step is executed again;
and if the preset condition is determined to be met, determining the optimal solution from the child population, wherein the optimal solution is M first individuals with the largest fitness in the child population, and M is an integer greater than 1.
3. The method of claim 2, wherein the determining that the preset condition is met comprises:
and determining that the preset condition is met when the first number of times of circularly executing the first preset step is larger than or equal to a first preset threshold value or the fitness of the individuals in the offspring population is consistent with the fitness of the individuals in the parent population.
4. The method of claim 2, wherein said elite retention of said population according to said fitness of each of said individuals and/or said average fitness comprises:
sequencing the individuals according to the fitness of the individuals from big to small to generate an individual sequence;
copying individuals with preset proportions before the individual sequences to obtain copied individuals;
Determining said elite retention result from each said individual and said replicated individual according to said fitness of each said individual and/or said average fitness.
5. The method of claim 4, wherein said determining said elite retention result from each of said individuals and said replicated individuals according to said fitness of each of said individuals and/or said average fitness comprises:
n individuals with the largest fitness among the individuals and the copied individuals according to the fitness of the individuals, and taking the N individuals as elite retention results, wherein N is an integer greater than 1; or alternatively, the first and second heat exchangers may be,
and determining a target individual with a fitness greater than or equal to the average fitness from the individuals and the duplicate individuals according to the fitness of the individuals and the average fitness, and taking the target individual as the elite retention result.
6. The method of claim 1, wherein after the second inspection path for the ant is acquired, the method further comprises:
if the second times are smaller than the second preset threshold, determining second connection times of any two routing inspection nodes from the second routing inspection path;
Calculating the sum of the first connection times and the second connection times;
and taking the sum value as the first connection times, and executing the second preset step again.
7. The method of claim 1, wherein the determining a next node to be inspected for ants based on the first transition probabilities comprises:
acquiring a tabu list of ants, wherein the tabu list comprises inspection nodes inspected by the ants;
determining nodes to be inspected according to the tabu list;
calculating a second transition probability of the current routing inspection node and the node to be routing inspection;
and taking the node to be patrolled and examined with the maximum second transition probability as the next patrolling and examining node.
8. The method of claim 1, wherein determining the transition probabilities of the any two routing nodes based on the first number of connections comprises:
calculating pheromones of the arbitrary two nodes according to the first connection times and pheromone volatilization factors, wherein the pheromone volatilization factors are inversely related to the second times;
and calculating the first transition probability according to the pheromone and the distance between any two nodes.
9. A path planning apparatus, comprising:
The system comprises a routing inspection path generation module, a routing inspection module and a routing inspection module, wherein the routing inspection path generation module is used for acquiring a grid map of an environment to be inspected and generating a routing inspection path according to the grid map, and the routing inspection path comprises routing inspection nodes;
the optimal solution acquisition module is used for inputting the routing inspection path as an individual of a parent population in a genetic algorithm into the genetic algorithm and acquiring an optimal solution of the genetic algorithm, wherein the optimal solution is a first routing inspection path determined by the genetic algorithm;
the connection frequency determining module is used for determining the first connection frequency of any two routing inspection nodes from the first routing inspection path;
the optimal routing inspection path determining module is used for inputting the first connection times into an ant colony algorithm, and performing iterative operation according to the first connection times by utilizing the ant colony algorithm to obtain an optimal routing inspection path;
the optimal inspection path determining module is further configured to circularly execute a second preset step until a second number of times of circularly executing the second preset step is greater than or equal to a second preset threshold, and determine a target inspection path with the shortest length from the second inspection paths after the second number of times is greater than or equal to the second preset threshold; the second preset step of taking the target inspection path as the optimal inspection path includes:
Determining a first transition probability of any two routing inspection nodes according to the first connection times;
placing ants at the initial node for inspection, and determining the next node to be inspected of the ants according to the first transfer probability, so that the ants inspect the next node to be inspected;
when ants reach the next node to be inspected, taking the next node to be inspected as a current inspection node and acquiring the position information of the ants at the current inspection node;
if the ants do not reach the termination node according to the position information, determining the next node to be inspected of the ants according to the first transfer probability, so that the ants inspect the next node to be inspected;
and if the ants reach the termination node according to the position information, acquiring a second routing inspection path of the ants.
10. A computer readable storage medium, on which a computer program is stored, characterized in that the program, when being executed by a processor, implements the steps of the method according to any one of claims 1 to 8.
11. An electronic device, comprising:
a processor; and
a memory for storing executable instructions of the processor;
wherein the processor is configured to perform the steps of the method of any one of claims 1 to 8 via execution of the executable instructions.
CN202210918666.XA 2022-08-01 2022-08-01 Path planning method and device, storage medium and electronic equipment Active CN115079704B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210918666.XA CN115079704B (en) 2022-08-01 2022-08-01 Path planning method and device, storage medium and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210918666.XA CN115079704B (en) 2022-08-01 2022-08-01 Path planning method and device, storage medium and electronic equipment

Publications (2)

Publication Number Publication Date
CN115079704A CN115079704A (en) 2022-09-20
CN115079704B true CN115079704B (en) 2024-02-27

Family

ID=83243304

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210918666.XA Active CN115079704B (en) 2022-08-01 2022-08-01 Path planning method and device, storage medium and electronic equipment

Country Status (1)

Country Link
CN (1) CN115079704B (en)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115451974B (en) * 2022-11-09 2023-04-07 广东电网有限责任公司湛江供电局 Power equipment routing inspection path planning method, system, equipment and medium
CN115801665A (en) * 2022-11-22 2023-03-14 山西大学 Intra-domain route protection method based on forwarding graph
CN115952942B (en) * 2023-03-13 2023-06-02 季华实验室 Multi-target inspection scheduling planning method and device, electronic equipment and storage medium
CN116128014B (en) * 2023-04-17 2023-08-04 深圳市明源云科技有限公司 Hydrant layout method, device, electronic equipment and computer readable storage medium
CN117439899B (en) * 2023-12-20 2024-03-01 陕西华海信息技术有限公司 Communication machine room inspection method and system based on big data

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107463702A (en) * 2017-08-16 2017-12-12 中科院成都信息技术股份有限公司 A kind of database multi-join query optimization method based on evolution algorithm
CN107943045A (en) * 2017-12-08 2018-04-20 江苏商贸职业学院 A kind of method for planning path for mobile robot based on ant colony genetic fusion algorithm
CN110610304A (en) * 2019-08-28 2019-12-24 广西电网有限责任公司电力科学研究院 Cross-region scheduling method of inspection robot based on hybrid genetic-ant colony algorithm
LU102400A1 (en) * 2019-08-06 2021-02-09 Nanjing Seawolf Ocean Tech Co Ltd Path planning method and system for unmanned surface vehicle based on improved genetic algorithm
WO2021035911A1 (en) * 2019-08-28 2021-03-04 青岛蓝海未来海洋科技有限责任公司 Method and system for planning path of unmanned surface vehicle based on forward/reverse data-driven linear parameter-varying genetic algorithm
CN112650248A (en) * 2020-12-23 2021-04-13 齐鲁工业大学 Routing inspection robot path planning method and system based on improved genetic algorithm
CN112666957A (en) * 2020-12-24 2021-04-16 苏州市职业大学 Underwater robot path planning method based on improved ant colony algorithm
CN113759927A (en) * 2021-09-16 2021-12-07 重庆邮电大学 Warehousing robot path planning method based on artificial bee colony-adaptive genetic algorithm

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107463702A (en) * 2017-08-16 2017-12-12 中科院成都信息技术股份有限公司 A kind of database multi-join query optimization method based on evolution algorithm
CN107943045A (en) * 2017-12-08 2018-04-20 江苏商贸职业学院 A kind of method for planning path for mobile robot based on ant colony genetic fusion algorithm
LU102400A1 (en) * 2019-08-06 2021-02-09 Nanjing Seawolf Ocean Tech Co Ltd Path planning method and system for unmanned surface vehicle based on improved genetic algorithm
CN110610304A (en) * 2019-08-28 2019-12-24 广西电网有限责任公司电力科学研究院 Cross-region scheduling method of inspection robot based on hybrid genetic-ant colony algorithm
WO2021035911A1 (en) * 2019-08-28 2021-03-04 青岛蓝海未来海洋科技有限责任公司 Method and system for planning path of unmanned surface vehicle based on forward/reverse data-driven linear parameter-varying genetic algorithm
CN112650248A (en) * 2020-12-23 2021-04-13 齐鲁工业大学 Routing inspection robot path planning method and system based on improved genetic algorithm
CN112666957A (en) * 2020-12-24 2021-04-16 苏州市职业大学 Underwater robot path planning method based on improved ant colony algorithm
CN113759927A (en) * 2021-09-16 2021-12-07 重庆邮电大学 Warehousing robot path planning method based on artificial bee colony-adaptive genetic algorithm

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
基于蚁群-粒子群算法的巡检机器人路径规划;杨天宇;薛阳;张亚飞;;现代计算机(专业版)(29);全文 *
基于遗传蚁群算法的并行测试任务调度与资源配置;方甲永;肖明清;谢娟;;测试技术学报(04);全文 *

Also Published As

Publication number Publication date
CN115079704A (en) 2022-09-20

Similar Documents

Publication Publication Date Title
CN115079704B (en) Path planning method and device, storage medium and electronic equipment
Li et al. Development and investigation of efficient artificial bee colony algorithm for numerical function optimization
Li et al. A multi-agent genetic algorithm for community detection in complex networks
Andradóttir An overview of simulation optimization via random search
Stenz et al. Exploring tree-like and non-tree-like patterns using genome sequences: an example using the inbreeding plant species Arabidopsis thaliana (L.) Heynh
Deep et al. Combined mutation operators of genetic algorithm for the travelling salesman problem
US11561950B2 (en) System and method for facilitating an objective-oriented data structure and an objective via the data structure
CN112364880A (en) Omics data processing method, device, equipment and medium based on graph neural network
CN110957012A (en) Method, device, equipment and storage medium for analyzing properties of compound
CN112561031A (en) Model searching method and device based on artificial intelligence and electronic equipment
Hu et al. A niching backtracking search algorithm with adaptive local search for multimodal multiobjective optimization
Al-Khiaty et al. Matching UML class diagrams using a Hybridized Greedy-Genetic algorithm
Arasteh et al. Bölen: Software module clustering method using the combination of shuffled frog leaping and genetic algorithm
JP2023020910A (en) Method for constructing medicine synergism prediction model, prediction method, and corresponding apparatus
CN114185800A (en) Test case generation method, system, equipment and medium based on genetic algorithm
Ji et al. Ant colony optimization with multi-agent evolution for detecting functional modules in protein-protein interaction networks
Michelakos et al. A hybrid classification algorithm evaluated on medical data
CN116992151A (en) Online course recommendation method based on double-tower graph convolution neural network
Pereira et al. Multi‐objective sunflower optimization: A new hypercubic meta‐heuristic for constrained engineering problems
CN115345106B (en) Verilog-A model construction method, system and equipment for electronic device
Patton et al. A genetic algorithm approach to focused software usage testing
CN114065646B (en) Energy consumption prediction method based on hybrid optimization algorithm, cloud computing platform and system
CN113780394B (en) Training method, device and equipment for strong classifier model
JP2020009122A (en) Control program, control method and system
CN115345303A (en) Convolutional neural network weight tuning method, device, storage medium and electronic equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant