A method for enterprise patrol task generation and route planning
By establishing a unified model in the intelligent inspection system and using custom matching algorithms and ant colony algorithms to optimize routes, the inefficiency caused by the reliance on manual task generation in existing technologies has been solved. This has enabled automated inspection task generation and path planning, improving the management efficiency and resource utilization of chemical enterprises.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-04-01
- Publication Date
- 2026-04-14
AI Technical Summary
In existing intelligent patrol systems, task generation relies on manual processes, resulting in uneven task allocation, low efficiency, and a lack of full-process automation and optimization.
By establishing a unified model, matching patrol points and patrol items, using a custom matching algorithm and fitness function for task allocation and path planning, and combining ant colony optimization to optimize routes, automated generation and adjustment are achieved.
It improves the efficiency and accuracy of patrol tasks, reduces human error, saves labor costs, and ensures that patrol officers can complete their tasks efficiently.
Smart Images

Figure CN118228995B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of route planning technology, specifically to a method for generating inspection tasks and planning routes to enhance the inspection management of chemical enterprises. Background Technology
[0002] In today's society, all industries face the challenge of safety and environmental protection, especially manufacturing enterprises, for whom this issue requires even more urgent attention. Safety accidents can not only lead to product quality problems but also pose a significant threat to the property and personal safety of the public. Therefore, strengthening enterprises' awareness of safety and environmental management and implementing preventative measures has become particularly important. Against this backdrop, strengthening the safety management of chemical processes has become a crucial foundation for preventing accidents, eliminating safety hazards, and building a long-term mechanism for safe production.
[0003] In recent years, with the continuous development of computer technology, intelligent inspection methods have gradually replaced traditional inspection methods in various fields. However, the development of intelligent inspection methods is still imperfect. Due to the uncertainty of factors such as time, distance, and personnel, the management of inspection tasks in chemical enterprises usually faces the following problems: the scheduling and generation of inspection tasks still rely on manual labor, the efficiency of inspection task execution is low, and the schedule of inspectors is not reasonably arranged.
[0004] In contrast, automated patrol task generation and route planning can effectively solve the problems of traditional patrol methods. First, intelligent generation algorithms can automatically generate patrol tasks based on the specific circumstances and requirements of chemical enterprises, avoiding subjective factors and errors inherent in manual scheduling. Second, intelligent route planning can rationally plan patrol routes based on the location of patrol points and the patrol personnel's schedule, minimizing travel time and distance and improving patrol efficiency. In summary, the application of patrol task generation and route planning methods can not only improve the safety and environmental management level of chemical enterprises but also save resources and costs, and improve the management efficiency of enterprises.
[0005] A search revealed Chinese patent application number 202310762197.1, published on June 26, 2023, which discloses a method for factory inspection task allocation and route planning. This method includes: obtaining factory inspection tasks; allocating these tasks according to equipment inspection cycles using a greedy algorithm to obtain task allocation results; calculating the distance between the inspected equipment for each task based on the task allocation results; and planning the inspection route for each task based on a genetic algorithm, according to the task allocation results and the required distance between the inspected equipment for each task, to minimize the total inspection distance and optimize the inspection time for each task. While this method involves task allocation and path planning, it lacks initial task generation. To further improve the efficiency and accuracy of inspection work, an automatic task generation and matching method is needed, forming a comprehensive process from task generation to job matching to route planning, and the route's quality influencing the selection of the task set, thereby reducing employee workload.
[0006] Chinese patent application number CN202310910025.4, published on September 5, 2023, discloses a vehicle path planning method based on an improved ant colony algorithm to overcome many shortcomings of the traditional ant colony algorithm in vehicle path planning tasks. While vehicle path planning and patrol path planning share similarities, patrols involve more relevant factors, including priority and task completion time requirements. Therefore, a path planning method tailored to the actual production needs of chemical enterprises is required. This method mainly includes path planning, updating the path based on task conditions, and selecting a task set based on the optimal planned path.
[0007] To address these issues, this invention primarily provides a novel method for generating enterprise inspection tasks and planning routes. Summary of the Invention
[0008] This invention addresses the problems of uneven task allocation and low efficiency caused by the need for manual task generation and route selection in existing intelligent patrol systems. It provides a method for generating enterprise patrol tasks and planning routes, which can intelligently match points and items, generate tasks, allocate tasks, plan routes, and automatically adjust routes, thereby avoiding problems caused by human factors and improving the overall efficiency of patrols.
[0009] To achieve the above objectives, the present invention provides the following technical solution:
[0010] To address the shortcomings of existing intelligent inspection systems in generating tasks, this invention establishes a unified model that matches inspection points and items based on characteristics. Tasks are then assigned to corresponding positions, and path planning is performed for each position. The optimal task allocation and path planning scheme is selected based on the path planning results, thereby improving the efficiency of enterprise inspections and saving labor costs. Traditional inspection systems require manual task input and assignment, while intelligent task generation can automatically generate tasks, making it suitable for various chemical enterprises, thus saving labor costs and achieving efficient management.
[0011] A method for generating enterprise inspection tasks and planning routes includes the following steps:
[0012] S1. Obtain information on patrol points, patrol items, and the job responsibilities and work status of employees within the company, and generate a patrol task list.
[0013] S2. Group patrol points and patrol items of the same type into one point using a custom matching algorithm;
[0014] S3. Initialize the generated patrol tasks by using the matching degree function to assign them to positions. After assignment, use the fitness function to optimize and reorganize the tasks assigned to each position.
[0015] S4. Use path planning algorithms to plan the routes for the inspection tasks of enterprise employees, and select the globally optimal inspection route based on cost.
[0016] S5. Automatically adjust patrol routes based on employee location and patrol status.
[0017] Further, in step S1, information on inspection points, inspection items, and the job responsibilities and work status of employees within the company are obtained to generate an inspection task list, specifically:
[0018] Obtain information on all inspection points within a chemical enterprise: Inspection point information includes point number, point name, department, workshop, point description, location (x, y, z), type (general inspection point, level 1 major hazard source, level 2 major hazard source, level 3 major hazard source, level 4 major hazard source, important location, high-level process, others), start / stop status, and whether it is bound to an NFC card;
[0019] Obtain all inspection item information within the chemical enterprise: Inspection item information includes project name, project number, department, workshop, project description, location (x, y, z), type (general inspection point, first-level major hazard source, second-level major hazard source, third-level major hazard source, fourth-level major hazard source, important parts, high-level processes, others), start / stop status, sorting, inspection cycle, frequency, and frequency type (high frequency, low frequency);
[0020] Obtain all job information within a chemical company: job title, job type, job level, affiliated base, department, superior position, and working hours;
[0021] In step S1, the patrol points and patrol items are matched using a custom matching algorithm, and items of the same type are grouped into one point; the grouped list of items is then used to generate tasks based on frequency.
[0022] The attributes of each patrol point are represented by a matrix as follows:
[0023]
[0024] Among them: Q i (i = 1, 2, ..., m) represents the i-th patrol point; q ij (i = 1, 2, ..., m; j = 1, 2, ..., n) represents the j-th attribute of the i-th patrol point.
[0025] The attributes of the inspection item can be represented by a matrix as follows:
[0026]
[0027] Among them: A i Let A represent the i-th inspection item. ij (i = 1, 2, ..., c; j = 1, 2, ..., k) represents the j-th attribute of the i-th inspection item.
[0028] The attribute matrix of the patrol point and the attribute matrix of the patrol item have a mapping relationship, that is, the attribute matrix Q of the patrol point. m×n Each attribute q ij All can correspond to matrix A c×k The multi-line attribute values, i.e.
[0029] q 11 →(a 1i , ...a ci );q 1n →(a 1n …a cn );
[0030] q ij →(a 1×((i-1)·n+j) …a c×((i-1)·n+j) ).
[0031] The attribute value of the i-th inspection item is represented by a 6-dimensional vector. Indicates, that is μ i Refers to the value of the department, ξ i Point location / project description value, o i Point location / item number value, ω i Refers to type value, τi Point location / project name value, φ i The location value of the point / project is indicated; the attribute value of the j-th inspection point is similar. a, b, c, d, e, f represent the corresponding attribute weights, ranging from [0, 5]. A larger value indicates a larger weight coefficient for that item. Define the matching degree m. ij The calculation formula is:
[0032] m ij =[(μ i -μ j ) 2 ·a+(ξ i -ξ j ) 2 ·b+(o i -o j ) 2 ·c+
[0033] (ω i -ω j ) 2 ·d+(τ i -τ j ) 2 ·e+(φ i -φ j ) 2 ·f+1] -1
[0034] Based on the matching degree above, the sample set of inspection items is divided into different locations, resulting in a set of location-item associations. Corresponding location-item tasks are generated based on the frequency type of the inspection items. For high-frequency inspection items, tasks can be generated by evenly distributing time according to the cycle, such as days, hours, or shifts. For low-frequency inspection items, an alternating strategy of weekly, monthly, or yearly cycles is used for task generation. For example, if a low-frequency inspection item requires two inspections per week, an alternating strategy can be adopted. The first inspection can be scheduled from Monday to Saturday, and the second inspection from Tuesday to Sunday. This strategy ensures that the inspection time is evenly distributed within the cycle, avoiding excessive concentration of inspections on a single day or several days.
[0035] Step S2 initializes the job assignment of the generated patrol tasks using a matching degree function, and then optimizes and reorganizes the patrol tasks assigned to each job using a fitness function, specifically as follows:
[0036] Consider n job positions and m task sets. Each task has a start time and a finish time requirement. The goal is to ensure that employees can complete all their tasks within a certain time period. Each task can be assigned to a job position. U = {u0, u1, ..., u...} n-1 Let S = {t0, t1, ..., t} represent the job set. m-1 Let A represent the task set.i It is a set of tasks assigned to the job position. Where x ij ={0, 1}, x ij Denotes the decision variable, if task t j Assigned to user u i x ij =1, otherwise x ij =0; |A i | represents A i cardinality; s t (t j ) and f t (t j ) represents task t j The task allocation problem can be described as follows: (The task allocation problem requires a specific start time and completion time.)
[0037] Where f1 represents maximizing the number of tasks assigned; tasks are assigned cyclically based on the matching degree between task descriptions and job responsibilities, with the goal of equal and fair task allocation. The matching degree ξ between each task description and job responsibility is calculated by word segmentation and can be expressed as:
[0038]
[0039] Where c1 represents the number of words matching the task description and job responsibilities, c2 represents the number of words segmented for the task description, and c3 represents the number of words segmented for the job responsibilities.
[0040] After initializing job assignments, a fitness function is used to optimize and reorganize the assigned tasks. The fitness function needs to consider the following metrics:
[0041] The average distribution of workload across all positions is represented by the indicator u1.
[0042]
[0043] The distance between all tasks for a given position on a given day is represented by the index u2;
[0044]
[0045] The dispersion of time intervals between multiple patrol tasks at a single location is represented by the index u3.
[0046]
[0047] (4) The completion rate of an employee's daily patrol tasks is represented by the indicator ∈;
[0048] The overall fitness function is designed as follows:
[0049]
[0050] The NUM set of patrol task allocation schemes with high adaptability is selected as the input parameters for path planning.
[0051] Furthermore, route planning is conducted for the company's employee inspection tasks, specifically as follows:
[0052] Based on the patrol tasks assigned to each position within the company, for all patrol tasks of each position, the path planning is optimized using the ant colony algorithm, taking into account characteristics such as location, item information, and required patrol time. The specific steps are as follows:
[0053] Select m ants and scatter them at various task points as initial points. Each task is executed only once. Use N... k Let P represent the set of unexecuted tasks. Calculate the probability P of selecting tasks i to j according to the following rules. ij Choose the endpoint with the highest probability, that is:
[0054]
[0055] Where τ ij Indicates pheromone intensity, de ij ft represents the distance from i to j. ij pr represents the difference between the task's required end time and the current time. ij The numbers represent the priority of the task, and a, β, c, and d represent the weights.
[0056] Initialize the pheromone concentration with the same amount, and update the pheromone concentration after each selection step.
[0057] τ ij (k+1)=(1-ρ)τ ij (k)+Δτ ij (k)
[0058]
[0059] Where ρ represents the pheromone evaporation coefficient, with a value range of (0, 1), C k Let k be the cost of the path taken by the k-th ant in this iteration, which is the combined cost of distance, time, etc. choose This indicates that the k-th ant chooses to pass through the road segment.
[0060] (3) Continue until all ants have no tasks to perform, i.e., N k If the pheromone level is 0, or the iteration count is reached, the loop terminates and the path with the higher pheromone level is output as the optimal path.
[0061] (4) Take the above-generated NUM set patrol task allocation scheme with high fitness as input, and finally output the NUM set optimal path scheme.
[0062] (5) Based on the above NUM optimal path schemes, calculate the minimum total cost of each optimal path scheme; that is, the distance cost required for each post to patrol is expressed as de. j The time cost is te j The total cost of each optimal path solution is Select the one with the lowest cost from the NUM solutions as the final task generation and path planning solution.
[0063] Furthermore, the patrol route is automatically adjusted based on the employee's location and patrol status, specifically as follows:
[0064] Since the tasks and routes for each position were determined when the optimal route was initially selected, the tasks of employees in that position remain unchanged during their patrols to prevent disruption to others' work. However, unfinished tasks can be identified during the patrol process, and the route can be automatically adjusted accordingly. Employees in that position can patrol according to the designated route or conduct patrols randomly.
[0065] If random patrols are conducted, by determining the employee's current location and setting that location as the starting point, the input parameters for the route planning algorithm for the employee's current unexecuted tasks are modified. Instead of selecting m ants and scattering them across various task locations as the initial point, the algorithm selects m ants and sets the current employee's location as the initial point. Subsequent steps remain unchanged, thus generating an optimal route. When the employee has no tasks to perform, the patrol route is empty.
[0066] This results in a solution for automatically generating and planning inspection tasks throughout the entire process, which can help companies save on labor costs.
[0067] Compared with existing technologies, the beneficial effects of this invention are as follows: The method for generating inspection tasks and planning routes for chemical enterprises provided by this invention can greatly reduce the time and effort required for manual operation through automated and intelligent task generation and route planning; it can quickly generate task lists and optimized inspection routes according to preset rules and conditions, thereby saving time and resources; it can avoid human errors and deviations; it can generate more accurate and comprehensive task lists and inspection routes based on accurate data and requirements according to certain algorithms and rules; it can better utilize resources and ensure that inspectors can complete tasks efficiently. Attached Figure Description
[0068] Figure 1 This is a flowchart illustrating the overall generation process of the present invention;
[0069] Figure 2 This is an information diagram showing the correspondence between inspection points and item attributes in this invention;
[0070] Figure 3 This is a schematic diagram illustrating the principle of the inspection point matching method of the present invention. Detailed Implementation
[0071] To make the objectives and advantages of this invention clearer, the invention will be specifically described below with reference to embodiments. It should be understood that the following text is merely used to describe one or more specific embodiments of the invention and does not strictly limit the scope of protection specifically claimed by the invention.
[0072] Taking a chemical enterprise as an example, this paper provides a method for generating inspection tasks and planning routes in a chemical enterprise, including the following steps:
[0073] Obtain information on inspection locations, inspection items, and the job responsibilities and work status of employees within the company to generate an inspection task list; the following is a partial list for reference: Inspection location information is as follows:
[0074]
[0075] The inspection items are as follows:
[0076]
[0077]
[0078]
[0079] Group and match the item information.
[0080] The following matching formula is used to match similar attributes of inspection points and inspection items. The attribute correspondence is as follows: Figure 2 As shown, the principle of patrol point matching is as follows: Figure 3 As shown; calculate the matching degree between each inspection item and each inspection point, select the inspection item with the highest matching degree, and assign it to the inspection point.
[0081] m ij =[(μ i -μ j ) 2 ·a+(ξ i -ξ j ) 2 ·b+(o i -o j ) 2 ·c+(ω i -ω j ) 2 ·d+(τ i -τ j ) 2·e+(φ i -φ j ) 2 ·f+1] -1 The execution result correspondence is as follows:
[0082]
[0083] The matched point information is used to generate tasks based on the frequency of the items.
[0084] For example, patrol item XC02-001-3, twice a week, generates two tasks with start and end times specified as Monday-Thursday and Wednesday-Sunday respectively. Tasks can be executed within these periods, and all other task attributes remain the same. One month's worth of tasks are generated each time, as listed above, resulting in a total of 86 patrol tasks per month.
[0085] Assign tasks to different positions.
[0086] The following is a partial list of positions:
[0087]
[0088] The above job and task sets will be allocated using the following formula:
[0089]
[0090] After allocation, substitute each parameter into the following formula for allocation optimization:
[0091] The average distribution of workload across all positions is represented by the indicator u1.
[0092]
[0093] The distance between all tasks for a given position on a given day is represented by the index u2;
[0094]
[0095] (3) The dispersion of time intervals between multiple patrol tasks at a single location is represented by the index u3;
[0096]
[0097] (4) The completion rate of an employee's daily patrol tasks is represented by the indicator ∈;
[0098] The overall fitness function is designed as follows:
[0099]
[0100] Task assignment result 1 is:
[0101]
[0102]
[0103] Task assignment result 2 is:
[0104]
[0105] Plan the route for the tasks of the position.
[0106]
[0107] Taking the task of the head of the operations management department as an example, the route is planned by substituting the relevant parameters of the task into the formula, and an optimal path is obtained: GL10300B001-1->GL10300B001-3->GL11700B002-1->GL11700B002-2
[0108] Plan the entire plant's routes using the above method and calculate the total cost required for each task.
[0109]
[0110] Ultimately, task allocation result 1 was found to be optimal.
[0111] Automatically adjust patrol routes.
[0112] During the inspection, if the head of the operations management department prioritizes inspecting GL11700B002-1, the remaining tasks and current location will be obtained, and the route will be replanned as GL11700B002-2->GL10300B001-1->GL10300B001-3. Alternatively, if the monthly tasks have been completed in the first week, and only the weekly tasks need to be performed in the second week, the route will also be replanned in the same way.
[0113] The embodiments of the present invention have been described in detail above with reference to the accompanying drawings. However, the present invention is not limited to the above embodiments. For those skilled in the art, after learning the contents described in the present invention, several equivalent changes and substitutions can be made without departing from the principle of the present invention. These equivalent changes and substitutions should also be considered to fall within the protection scope of the present invention.
Claims
1. A method for generating enterprise inspection tasks and planning routes, characterized in that, Includes the following steps: S1. Obtain patrol point information, patrol item information, and the job responsibilities and work status of internal employees to generate a patrol task list; use a custom matching algorithm to group similar patrol points and patrol items into one point. S2. Initialize the generated patrol tasks by using the matching degree function to assign positions, and then use the fitness function to optimize and reorganize the patrol tasks assigned to each position. S3. Use path planning algorithms to plan the routes for employee patrol tasks and select the globally optimal patrol route based on cost. S4. Automatically adjust patrol routes based on employee location and patrol status; In step S1, a custom matching algorithm is used to group similar inspection points and items into one point. Specifically: The attributes of each patrol point are represented by a matrix as follows: ; in, This is the i-th patrol point; This refers to the j-th attribute of the i-th patrol point. The attributes of the inspection item can be represented by a matrix as follows: ; in: This represents the i-th inspection item. For the i-th inspection item, the j-th attribute is... The attribute matrix of patrol points and the attribute matrix of patrol items have a mapping relationship, that is, the attribute matrix of patrol points... Each attribute Both can correspond to matrices The multi-line attribute values, namely: ; ; ; The attribute value of the i-th inspection item is represented by a 6-dimensional vector. It means, that is , Refers to the value of the department, Point location / project description value, Point location / project number value, Refers to type value, Point location / project name value, The location value of the indicator point / project; the attribute value of the j-th inspection point is similar; This indicates the corresponding attribute weight, with a value range of 100%. A larger value indicates a larger weight coefficient for that item; defining the matching degree. The calculation formula is: ; Based on the above matching degree, the inspection item sample set is divided into different locations to obtain the location item association set; Step S2 initializes the job assignment of the generated patrol tasks using a matching degree function, and then optimizes and reorganizes the patrol tasks assigned to each job using a fitness function, specifically as follows: Given n job positions and m task sets, then Indicates a set of job positions. Represents a task set; let It is a set of tasks assigned to the job position. ,in , Denotes decision variables, if the task Assigned to user ,but ,otherwise ; express The cardinality; and Indicates task The required start and finish times; the task allocation problem is described as follows: ; in, To maximize the number of tasks assigned, tasks are allocated cyclically based on the match between task descriptions and job responsibilities. Each task description and job responsibility is segmented into words to calculate the match between the task description and the job responsibility description. Represented as: ; in This indicates the number of words that match the task description and job responsibilities. This indicates the number of word segments in the task description. This indicates the number of word segments representing job responsibilities; After initializing job assignments, a fitness function is used to optimize and reorganize the assigned tasks. The following metrics are considered for the fitness function: (1) The average distribution of workload across all positions, using indicators express; ; (2) The distance between all tasks of a position on a given day, expressed by indicators. express; ; (3) The dispersion of time intervals between multiple patrol tasks at a single location, expressed by the indicator express; ; (4) The completion rate of an employee's daily patrol tasks, expressed as an indicator. express; The overall fitness function is designed as follows: ; The NUM set of patrol task allocation schemes is selected as the input parameters for path planning; In step S3, a path planning algorithm is used to plan the path for the employee's patrol task, and the globally optimal patrol path is selected based on cost. Specifically: Based on the patrol tasks assigned to each position within the company, for all patrol tasks of each position, the path planning is performed using an improved ant colony algorithm, taking into account the location, item information, and required patrol time. The specific steps are as follows: S3.1 Select m ants and scatter them at various task locations as initial points. Each task is executed only once. Let i represent the set of unexecuted tasks. Calculate the probability of selecting tasks i through j according to the following rules. Choose the endpoint with the highest probability, that is: ; in Indicates pheromone intensity, This represents the distance from i to j. This represents the difference between the task's required end time and the current time. The numbers represent the priority of the task, and a, β, c, and d represent the weights. S3.2 Initialize the pheromone concentration with the same amount. After each selection step, update the pheromone concentration, that is: ; ; in This represents the pheromone evaporation coefficient, with a value range of (0, 1). This represents the path traversal cost of the kth ant in this loop, which is the combined cost of distance and time. This indicates that the k-th ant chose to traverse the given path. S3.3, until all ants have no tasks to perform, that is... If the value is 0, or the number of iterations is reached, the loop terminates and the path with the highest pheromone is output as the optimal path. S3.
4. Take the NUM set patrol task allocation scheme generated in step S2 as input, and finally output the optimal path scheme for the NUM set. S3.
5. Based on the NUM optimal path schemes in S3.4, calculate the minimum total cost of each optimal path scheme; that is, the distance cost required for each post to patrol is expressed as... The time cost is The total cost of each optimal path solution is: ; Finally, the path with the lowest cost is selected from the NUM optimal path schemes as the final task generation and optimal inspection path.
2. The method for generating enterprise inspection tasks and planning routes according to claim 1, characterized in that, In step S4, the patrol route is automatically adjusted based on the employee's location and patrol status, specifically as follows: Staff members can choose to patrol according to the patrol route or conduct random patrols. If random patrol is selected, the current position of the employee is determined and set as the starting position. The employee's current unexecuted task is used as the input to step S3.1 to execute the algorithm. The step S3.1 of selecting m ants and scattering them at various task points as the initial point is modified to selecting m ants and using the current employee's location as the initial point. Subsequent steps remain unchanged, thus generating an optimal patrol route.
Citation Information
Patent Citations
Vehicle path planning method based on improved ant colony algorithm
CN116698073A
Task optimization sorting and path guiding method for construction violation patrol
CN115271179A
Factory inspection task allocation and route planning method
CN116859915A