Task automatic allocation method and device based on DEM technology, equipment and medium
By using DEM technology and k-means clustering algorithm, the problem of unreasonable task point allocation in complex terrain was solved, realizing automated and accurate task allocation, reducing construction costs and improving construction efficiency and safety.
Patent Information
- Application Number
- CN202311455806.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-11-03
- Publication Date
- 2025-10-21
- Estimated Expiration
- 2043-11-03
AI Technical Summary
Traditional task allocation methods are time-consuming and costly in complex terrain exploration, and are affected by the limitations of human observation, resulting in unreasonable task point allocation.
Data processing and preprocessing are performed using DEM technology, combined with k-means clustering algorithm. Task point scores are calculated based on distance, elevation, slope and relative slope, and automatic task allocation is achieved using computer equipment and media.
It enables the rational allocation of task points in complex terrain, saving manpower and time costs, reducing human error, and improving construction efficiency and safety.
Smart Images

Figure CN119962848B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of petroleum geophysical exploration and processing, and relates to a task allocation method, in particular to a task automatic allocation method and device, equipment and medium based on DEM technology. Background Art
[0002] In field exploration, especially when working in complex terrain, traditional task allocation often relies on human observation of maps and estimated distances between various work points. This task allocation method is not only time-consuming but also limited by map accuracy, environmental complexity, and the limitations of human observation. It is common for a construction worker to be assigned to tasks with large elevation or distance differences, resulting in significant time and labor costs.
[0003] A DEM is a digital terrain model used to represent elevation information at various locations on the Earth's surface. Its high resolution provides detailed topographic information and is widely used in resource exploration, geodesy, and land use planning. Using DEM elevation information, it's possible to clearly determine the topography of a work area, avoiding the limitations of manual task assignment.
[0004] Therefore, there is an urgent need for a method to use DEM technology to solve task allocation in complex terrain, quickly complete the allocation task and ensure the allocation quality. Summary of the Invention
[0005] In order to solve the above deficiencies in the prior art, one object of the present invention is to provide a method for automatic task allocation based on DEM technology, which can automatically and reasonably allocate task points in complex terrain, saving the time and labor costs of construction workers;
[0006] Another object of the present invention is to provide an apparatus, a computer device, and a computer-readable storage medium for executing the above method.
[0007] In order to achieve the above purpose, the technical solution adopted by the present invention is as follows:
[0008] A method for automatic task allocation based on DEM technology includes the following steps performed in sequence:
[0009] S1. Data Processing
[0010] Collect DEM data and the coordinates of each task point, convert the DEM data into a grid format to facilitate subsequent analysis and calculation, and create a 3D terrain model through visual analysis to help users visualize terrain and landform features and facilitate users to observe specific conditions;
[0011] Preprocessing DEM data is an important step to improve accuracy. In DEM data, the appearance of outliers will seriously affect subsequent calculations and analysis, so certain measures need to be taken to remove these outliers.
[0012] On the other hand, in order to eliminate the noise in the DEM data, it needs to be smoothed.
[0013] Integrate DEM data and coordinates of each task point so that analysis and calculation can be performed in the same coordinate system;
[0014] Set relevant parameter limits: according to the daily task volume, number of field construction personnel and work deadlines, set elevation limits, plane distance limits and the number of tasks per group, and make further calculations based on the limit values.
[0015] Among them, elevation restriction: limits the maximum and minimum elevation distances between task points;
[0016] Plane distance restriction: limit the distance between each task point;
[0017] Task quantity limit: limit the number of task points in each group;
[0018] S2. Score calculation
[0019] Select one of the task points as the task center point, and determine the scores of the remaining task points by comprehensively calculating the distance, elevation, surface slope, and relative slope between the task center point and the remaining task points.
[0020] S3. Task Allocation
[0021] In order to reasonably allocate each task point into a group of tasks, a task allocation method based on the k-means clustering algorithm is proposed;
[0022] The k-means clustering algorithm is used to group the task points: the task center point and several other task points that meet the requirements are grouped together, and the remaining task points are grouped according to the requirements so that the number of task points in each group and the sum of the scores of each task point meet the requirements; the task points that do not meet the requirements are regrouped until they meet the requirements, and the groups of tasks that meet the requirements are assigned one by one to the construction personnel of the earthquake team.
[0023] Furthermore, the score calculation described in step S2 is achieved through the following steps:
[0024] S21. With the task center point as the center of the circle, determine all remaining task points that meet the conditions according to the set inspection range R. The conditional formula is as follows:
[0025] d(P,Pm)≤R
[0026] Among them, i represents the task center point; jm represents the other task points j1, j2, j3...jm, m is a positive integer; d(P i ,P jm ) represents the Euclidean distance between the task center point and the other task points;
[0027] S22. Calculate the relevant parameters between the task center point and the remaining task points:
[0028] a. The distance d between the task center and the other task points ijm for:
[0029]
[0030] Among them, x i ,y i , z i is the three-dimensional coordinate of the task center point, x jm ,y jm , z jm are the three-dimensional coordinates of the remaining task points;
[0031] b. The elevation difference h between the task center point and the remaining task points ijm for:
[0032] h ijm =|z i -z jm |
[0033] c. The surface slope r between the mission center point and the remaining mission points ijm for:
[0034]
[0035] Among them, dz ijm Indicates the elevation change between the mission center point and the remaining mission points, dx ijm and dy ijm Indicates the distance change between the task center point and the other task points along the x and y directions;
[0036] d. Relative slope s between the task center point and the remaining task points ijm for:
[0037]
[0038] Among them, z max represents the maximum elevation value among the other task points, z represents the elevation value of the task center point, d max Indicates the maximum distance between the remaining task points and the task center point;
[0039] The relative slope ranges from 0 to 1, with larger values indicating a steeper surface;
[0040] S23. Determine the scores of the remaining task points
[0041] All other task points are weighted according to distance, elevation difference, surface slope and relative slope. The calculation formula is as follows:
[0042] score jm =w1d ijm +w2h ijm +w3r ijm +w4s ijm
[0043] Among them, score jm represents the score of the jmth remaining task point, w1, w2, w3 and w4 are the weights of distance, elevation difference, surface slope and relative slope respectively;
[0044] The remaining task points are used for subsequent task assignments.
[0045] Furthermore, after the task allocation in step S3 is completed, the task allocation is optimized, and the cluster center c of the kth group is expressed by the following formula: i,k :
[0046]
[0047] Among them, n i,k represents the size of the kth cluster of task center point i, x k ,y k ,z k represents the geographic three-dimensional coordinates of the task center point i, T i,k Represents the set of geographic 3D coordinates of all points in the k-th cluster;
[0048] In order to minimize the distance between task points in each group, the following loss function needs to be minimized:
[0049]
[0050] Among them, m i Indicates the number of clusters of task center point i;
[0051] After the above calculations, the optimization of task allocation is achieved.
[0052] Distribute tasks and provide related reminders based on task allocation:
[0053] Task distribution: Each assigned task is packaged and sent directly to the field construction personnel who will perform the task. Each field construction personnel can only see their own tasks, thus avoiding construction errors.
[0054] Reminder of the number of equipment to be carried: According to the number of tasks, the number of equipment required for the task will be automatically calculated after the task is assigned, and a certain amount of surplus will be given as preparation;
[0055] Dangerous situation reminder: When assigned, the dangerous areas around the construction area will be automatically marked and sent to the construction personnel of the field earthquake team in the form of a map, while reminding the bad weather during the construction period and construction safety operations.
[0056] Furthermore, the outliers in step S1 are removed by calculating the mean and standard deviation of the DEM data and removing the values that exceed the standard deviation as outliers. The calculation formula is as follows:
[0057]
[0058]
[0059] A=[μ-2σ,u+2σ]
[0060] Among them, μ is the mean, n is the number of elevations, x i is the elevation of point i, σ is the standard deviation, and A is the standard deviation range.
[0061] Furthermore, the smoothing process in step S1 is performed by using a Gaussian smoothing method and selecting appropriate filter radius and standard deviation parameters:
[0062]
[0063] Among them, G(x) is the smoothed elevation and x is the distance.
[0064] This method multiplies each pixel value in the DEM data by a Gaussian kernel coefficient and then performs weighted averaging to achieve smoothing.
[0065] The present invention also provides a task automatic allocation device based on DEM technology, comprising:
[0066] Data processing unit: used to integrate the DEM data into the same coordinate system after pre-processing and the coordinates of each task point;
[0067] Score calculation unit: used to determine the scores of the remaining task points;
[0068] Task allocation unit: used for task allocation.
[0069] The present invention also provides a computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the automatic task allocation method based on DEM technology described in any one of the above items is implemented.
[0070] The present invention also provides a computer-readable storage medium, which stores a computer program for executing any of the above-mentioned automatic task allocation methods based on DEM technology.
[0071] Due to the adoption of the above technical solution, the present invention has the following beneficial effects compared with the prior art:
[0072] (1) The automatic task allocation method based on DEM technology provided by the present invention utilizes the elevation information of DEM technology to reasonably allocate task points in complex terrain. Compared with the traditional manual allocation method, it not only saves the manpower and time costs of construction workers, but also reduces the subjectivity and error of manual allocation.
[0073] (2) The automatic task allocation method based on DEM technology provided by the present invention enables field construction workers to quickly receive task-related reminders, thereby increasing work efficiency while also ensuring safety and quality;
[0074] (3) The automatic task allocation method based on DEM technology provided by the present invention applies the k-means clustering algorithm to automatic task allocation for the first time;
[0075] (4) The device, computer equipment and computer-readable storage medium provided by the present invention can quickly and effectively implement the automatic task allocation method based on DEM technology. BRIEF DESCRIPTION OF THE DRAWINGS
[0076] The present invention will be described in further detail below with reference to the accompanying drawings and specific embodiments.
[0077] Figure 1 Schematic diagram of the automatic task allocation method based on DEM technology in Example 1;
[0078] Figure 2 This is a flow chart of the automatic task allocation device based on DEM technology in Example 2, wherein: 1. Data processing unit; 2. Score calculation unit; 3. Task allocation unit. DETAILED DESCRIPTION
[0079] The present invention will be further described in detail below through specific embodiments. It should be understood that the preferred embodiments described herein are only used to illustrate and understand the present invention and are not intended to limit the present invention.
[0080] Unless otherwise specified, the materials and reagents used in the examples of the present invention can be obtained from commercial sources. Experimental methods without specific conditions in the examples are generally performed under conventional conditions or the conditions recommended by the manufacturer.
[0081] Example 1 A method for automatic task allocation based on DEM technology
[0082] This embodiment is a method for automatically allocating tasks based on DEM technology, and its schematic diagram is shown in FIG. Figure 1 As shown, the specific operations include:
[0083] S1. Data Processing
[0084] Collect DEM data and the coordinates of each task point, convert the DEM data into a grid format to facilitate subsequent analysis and calculation, and create a 3D terrain model through visual analysis to help users visualize terrain and landform features and facilitate users to observe specific conditions. The specific methods are as follows:
[0085] Select an appropriate grid size based on the resolution of the DEM data and the required analysis accuracy to ensure sufficient resolution to capture the terrain features in the DEM. Then import the DEM data into ArcGIS software, open the DEM data, and use the "Raster to Point" tool to convert the DEM data into point data, creating a point grid consisting of the center point of each pixel in the DEM. Then use the "Point to Raster" tool to convert the point data back to raster data, creating a raster grid consisting of the value of each point in the point grid. After conversion, use the Kriging interpolation tool in ArcGIS software to fill in the missing data to obtain a smooth elevation surface across the entire grid. Finally, use the 3D terrain visualization tool in ArcGIS software to display the complete DEM grid data;
[0086] Preprocess the DEM data: Calculate the mean and standard deviation of the DEM data, and remove values that exceed the standard deviation as outliers. The calculation formula is as follows:
[0087]
[0088]
[0089] A=[μ-2σ,μ+2σ]
[0090] Among them, μ is the mean, n is the number of elevations, x i is the elevation of point i, σ is the standard deviation, and A is the standard deviation range.
[0091] On the other hand, in order to eliminate the noise in the DEM data, the Gaussian smoothing method is used, and the appropriate filter radius and standard deviation parameters are selected to perform smoothing:
[0092]
[0093] Among them, G(x) is the smoothed elevation and x is the distance.
[0094] Integrate DEM data and the coordinates of each task point so that analysis and calculation can be performed in the same coordinate system.
[0095] Set relevant parameter limits: according to the daily task volume, number of field construction personnel and work deadlines, set elevation limits, plane distance limits and the number of tasks per group, and make further calculations based on the limit values.
[0096] Among them, elevation restriction: the distance difference between the maximum and minimum elevations of each task point is limited to within 20 meters;
[0097] Plane distance restriction: limit the distance difference between each task point to within 500 meters;
[0098] Task quantity limit: limit the number of task points in each group to within 100;
[0099] S2. Score calculation
[0100] Select one of the task points as the task center point, and determine the scores of the remaining task points by comprehensively calculating the distance, elevation, surface slope, and relative slope between the task center point and the remaining task points.
[0101] S21. With the task center point as the center of the circle, determine all remaining task points that meet the conditions according to the set inspection range R. The conditional formula is as follows:
[0102] d(P i ,P jm )≤R
[0103] Among them, i represents the task center point; jm represents the other task points, m is a positive integer; d(P i ,P jm ) represents the Euclidean distance between the task center point and the other task points;
[0104] S22. Calculate the relevant parameters between the task center point and the remaining task points:
[0105] a. The distance d between the task center and the other task points ijm for:
[0106]
[0107] Among them, x i ,y i , z i is the three-dimensional coordinate of the task center point, x jm ,y jm , z jm are the three-dimensional coordinates of the remaining task points;
[0108] b. The elevation difference h between the task center point and the remaining task points ijm for:
[0109] h ijm =|z i -z jm |
[0110] c. The surface slope r between the mission center point and the remaining mission points ijm for:
[0111]
[0112] Among them, dz ijm Indicates the elevation change between the mission center point and the remaining mission points, dx ijm and dy ijm Indicates the distance change between the task center point and the other task points along the x and y directions;
[0113] d. Relative slope s between the task center point and the remaining task points ijm for:
[0114]
[0115] Among them, z max represents the maximum elevation value among the other task points, z represents the elevation value of the task center point, d max Indicates the maximum distance between the remaining task points and the task center point;
[0116] The relative slope ranges from 0 to 1, with larger values indicating a steeper surface;
[0117] S23. Determine the scores of the remaining task points
[0118] All other task points are weighted according to distance, elevation difference, surface slope and relative slope. The calculation formula is as follows:
[0119] score jm =w1d ijm +w2h ijm +w3r ijm +w4s ijm
[0120] Among them, score jm represents the score of the jmth remaining task point, w1, w2, w3 and w4 are the weights of distance, elevation difference, surface slope and relative slope respectively;
[0121] The remaining task points are used for subsequent task assignments;
[0122] S3. Task Allocation
[0123] In order to reasonably allocate each task point into a group of tasks, a task allocation method based on the k-means clustering algorithm is proposed;
[0124] The k-means clustering algorithm is used to group the task points: the task center point and several other task points that meet the requirements are grouped together, and the remaining task points are grouped according to the requirements so that the number of task points in each group and the sum of the scores of each task point meet the requirements; the task points that do not meet the requirements are regrouped until they meet the requirements, and the groups of tasks that meet the requirements are assigned one by one to the construction personnel of the earthquake team.
[0125] To optimize the task allocation, the cluster center c of the kth group is expressed by the following formula: i,k :
[0126]
[0127] Among them, n i,k represents the size of the kth cluster of task center point i, x k ,y k ,z k represents the geographic three-dimensional coordinates of the task center point i, T i,k Represents the set of geographic 3D coordinates of all points in the k-th cluster;
[0128] In order to minimize the distance between task points in each group, the following loss function needs to be minimized:
[0129]
[0130] Among them, m i Indicates the number of clusters of task center point i;
[0131] After the above calculations, the optimization of task allocation is achieved.
[0132] Distribute tasks and provide related reminders based on task allocation:
[0133] Task distribution: Each assigned task is packaged and sent directly to the field construction personnel who will perform the task. Each field construction personnel can only see their own tasks, thus avoiding construction errors.
[0134] Reminder of the number of equipment to be carried: According to the number of tasks, the number of equipment required for the task will be automatically calculated after the task is assigned, and a certain amount of surplus will be given as preparation;
[0135] Dangerous situation reminder: When assigned, the dangerous areas around the construction area will be automatically marked and sent to the construction personnel of the field earthquake team in the form of a map, while reminding the bad weather during the construction period and construction safety operations.
[0136] Example 2: A task automatic allocation device based on DEM technology
[0137] Figure 2 A flowchart of an automatic task allocation device based on DEM technology according to an embodiment of the present invention is shown, including:
[0138] Data processing unit 1: used to integrate the DEM data into the same coordinate system after preprocessing and the coordinates of each task point;
[0139] Score calculation unit 2: used to determine the scores of the remaining task points;
[0140] Task allocation unit 3: used for task allocation.
[0141] Example 3: A computer device
[0142] This embodiment provides a computer device, which includes: a memory, a processor, and a computer program stored in the memory and executable on the processor, so as to implement the above-mentioned automatic task allocation method based on DEM technology.
[0143] The memory is used to store non-transitory computer-readable instructions. Specifically, the memory may include one or more computer program products, which may include various forms of computer-readable storage media, such as volatile memory and / or non-volatile memory. The volatile memory may include, for example, random access memory (RAM) and / or cache memory. The non-volatile memory may include, for example, read-only memory (ROM), a hard disk, flash memory, etc.
[0144] The processor may be a central processing unit (CPU) or other forms of processing units with data processing capabilities and / or instruction execution capabilities, and may control other components in the electronic device to perform desired functions. The processor is configured to execute the computer-readable instructions stored in the memory.
[0145] Those skilled in the art should understand that in order to solve the technical problem of how to obtain a good user experience, this embodiment may also include well-known structures such as a communication bus and an interface, and these well-known structures should also be included in the scope of protection of this disclosure.
[0146] For detailed description of this embodiment, please refer to the corresponding description in the aforementioned embodiments, which will not be repeated here.
[0147] Example 4 A computer-readable storage medium
[0148] This embodiment provides a computer-readable storage medium storing a computer program. When the computer program is executed by a processor, the automatic task allocation method based on the DEM technology is implemented.
[0149] The computer-readable storage medium stores non-transitory computer-readable instructions, which, when executed by a processor, execute all or part of the steps of the aforementioned methods.
[0150] The above-mentioned computer-readable storage media include, but are not limited to, optical storage media (e.g., CD-ROMs and DVDs), magneto-optical storage media (e.g., MOs), magnetic storage media (e.g., magnetic tapes or mobile hard disks), media with built-in rewritable non-volatile memory (e.g., memory cards), and media with built-in ROM (e.g., ROM cartridges).
[0151] It should be noted that the above description is merely a preferred embodiment of the present invention and is not intended to limit the present invention. Although the present invention has been described in detail with reference to the above embodiments, those skilled in the art may still modify the technical solutions described in the above embodiments or replace some of the technical features therein with equivalents. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principles of the present invention shall be included within the scope of protection of the present invention.
Claims
1. A method for automatic task allocation based on DEM technology, characterized in that: The process includes the following steps: S1. Data Processing Collect DEM data and the coordinates of each task point, pre-process the DEM data, remove outliers, perform smoothing, and then integrate the DEM data and the coordinates of each task point into the same coordinate system; S2. Score calculation Select one of the task points as the task center point, and determine the scores of the remaining task points by comprehensively calculating the distance, elevation, surface slope, and relative slope between the task center point and the remaining task points. S3. Task Allocation The k-means clustering algorithm is used to group the task points: the task center point and several other task points that meet the requirements are grouped together, and the remaining task points are grouped according to the requirements so that the number of task points in each group and the sum of the scores of each task point meet the requirements; the task points that do not meet the requirements are regrouped until they meet the requirements, and the tasks in each group that meet the requirements are assigned one by one to the construction personnel of the earthquake team; The score calculation in step S2 is achieved through the following steps: S21. With the task center point as the center of the circle, determine all remaining task points that meet the conditions according to the set inspection range R. The conditional formula is as follows: d(P i ,P jm )≤R Among them, i represents the task center point; jm represents the other task points, m is a positive integer; d(P i ,P jm ) represents the Euclidean distance between the task center point and the other task points; S22. Calculate the relevant parameters between the task center point and the remaining task points: a. The distance d between the task center and the other task points ijm for: Among them, x i ,y i , z i is the three-dimensional coordinate of the task center point, x jm ,y jm , z jm are the three-dimensional coordinates of the remaining task points; b. The elevation difference h between the task center point and the remaining task points ijm for: h ijm =|z i -z jm | c. The surface slope r between the mission center point and the remaining mission points ijm for: Among them, dz ijm Indicates the elevation change between the mission center point and the remaining mission points, dx ijm and dy ijm Indicates the distance change between the task center point and the other task points along the x and y directions; d. Relative slope s between the task center point and the remaining task points ijm for: Among them, z max represents the maximum elevation value among the other task points, z represents the elevation value of the task center point, d max Indicates the maximum distance between the remaining task points and the task center point; S23. Determine the scores of the remaining task points All other task points are weighted according to distance, elevation difference, surface slope and relative slope. The calculation formula is as follows: score jm =w1d ijm +w2h ijm +w3r ijm +w4s ijm Among them, score jm represents the score of the jmth remaining task point, w1, w2, w3 and w4 are the weights of distance, elevation difference, surface slope and relative slope respectively; The remaining task points are used for subsequent task assignments.
2. The automatic task allocation method based on DEM technology according to claim 1, characterized in that: After the task allocation in step S3 is completed, the task allocation is optimized. The cluster center c of the kth group is expressed by the following formula: i,k : Among them, n i,k represents the size of the kth cluster of task center point i, x k ,y k ,z k represents the geographic three-dimensional coordinates of the task center point i, T i,k Represents the set of geographic 3D coordinates of all points in the k-th cluster; In order to minimize the distance between task points in each group, the following loss function needs to be minimized: Among them, m i Indicates the number of clusters of task center point i; After the above calculations, the optimization of task allocation is achieved.
3. The automatic task allocation method based on DEM technology according to claim 1, characterized in that: The outlier removal in step S1 is to remove values that exceed the standard deviation as outliers. The calculation formula is as follows: A=[μ-2σ,μ+2σ] Among them, μ is the mean, n is the number of elevations, x i is the elevation of point i, σ is the standard deviation, and A is the standard deviation range.
4. The automatic task allocation method based on DEM technology according to any one of claims 1 to 3, characterized in that: The smoothing process in step S1 is to use Gaussian smoothing method to perform smoothing process. Among them, G(x) is the smoothed elevation and x is the distance.
5. A device for the automatic task allocation method based on DEM technology according to any one of claims 1 to 4, characterized in that: include: Data processing unit: used to integrate the DEM data into the same coordinate system after pre-processing and the coordinates of each task point; Score calculation unit: used to determine the scores of the remaining task points; Task allocation unit: used for task allocation.
6. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the computer program, the automatic task allocation method based on DEM technology according to any one of claims 1 to 4 is implemented.
7. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a computer program for executing the automatic task allocation method based on DEM technology according to any one of claims 1 to 4.
Citation Information
Patent Citations
Task allocation path determination method and device and electronic equipment
CN113269480A
Staged multi-base unmanned aerial vehicle task allocation and flight path planning method
CN113671985A