Three-dimensional intelligent route selection search method, medium and equipment for long-distance oil and gas pipelines

By using a three-dimensional intelligent route selection search method and optimization model, multiple differentiated candidate schemes for long-distance oil and gas pipelines are generated, solving the efficiency and quality problems of route selection design under complex terrain and realizing efficient pipeline route planning.

CN122863812BActive Publication Date: 2026-11-10CENT SOUTH UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611355792.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2026-09-03
Publication Date
2026-11-10
Estimated Expiration
2046-09-03

AI Technical Summary

Technical Problem

Existing methods for selecting routes for long-distance oil and gas pipelines cannot quickly search for multiple differentiated candidate solutions under complex terrain conditions, and do not fully consider the pipeline longitudinal profile design and engineering structure costs.

Method used

A three-dimensional intelligent route selection search method is adopted to establish an optimization model that includes design variables, constraints and objective functions. A set of candidate routes is generated by a three-dimensional bidirectional fast search random tree algorithm, and differentiated schemes are screened by bidirectional Hausdorff distance and average deviation.

Benefits of technology

The system can quickly generate multiple differentiated candidate solutions in complex terrain, improving the level of design automation and solution quality, assisting human decision-making, and enhancing the efficiency and reliability of route selection design.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122863812B_ABST
    Figure CN122863812B_ABST
Patent Text Reader

Abstract

This invention relates to the field of intelligent route selection technology, and more particularly to a three-dimensional intelligent route selection search method, medium, and equipment for long-distance oil and gas pipelines. The three-dimensional intelligent route selection search method for long-distance oil and gas pipelines includes: acquiring spatial data of the study area and recording pipeline route selection design constraint parameters, engineering structure discrimination parameters, engineering cost parameters, and algorithm search parameters; establishing an intelligent pipeline route selection optimization model containing design variables, constraints, and an objective function based on the spatial data, pipeline route selection design constraint parameters, engineering structure discrimination parameters, and engineering cost parameters; using a three-dimensional bidirectional fast search random tree algorithm based on the intelligent pipeline route selection optimization model to search for routes and obtain a set of candidate routes; and filtering the candidate route set based on bidirectional Hausdorff distance and average deviation to obtain multiple differentiated schemes. This invention can avoid the concentration of schemes in a single narrow corridor in complex terrain environments with multiple constraints, and provides a rich and reliable selection of alternative schemes.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of intelligent route selection technology, and in particular to a three-dimensional intelligent route selection search method, medium, and equipment for long-distance oil and gas pipelines. Background Technology

[0002] Long-distance pipelines are crucial infrastructure for transporting fluid media such as oil and gas. The macroscopic route and alignment design of pipelines directly impact construction costs, operational safety, and life-cycle benefits; therefore, pipeline route selection is a core task in the planning and design phase. However, due to the vast study areas, diverse terrain conditions, numerous constraints, complex cost calculations, and a large number of potential feasible solutions, pipeline route selection and design is an extremely challenging task. Traditional route selection work relies heavily on engineers' experience, which is time-consuming and labor-intensive, and may overlook potentially superior solutions due to limited time and resources.

[0003] To address the aforementioned issues, some research has explored intelligent pipeline route selection. However, existing methods in automated pipeline route selection research primarily focus on route evaluation indicators such as the shortest horizontal route or length-related costs, while neglecting comprehensive cost factors such as the longitudinal profile design of long-distance pipelines and pipeline engineering structures. Furthermore, although some methods have achieved objectives such as obstacle avoidance, the geometric constraints, regional constraints, and engineering structural constraints of pipelines still require more detailed investigation.

[0004] Therefore, it is necessary to provide a new three-dimensional intelligent route selection and search method, medium, and equipment for long-distance oil and gas pipelines to solve the above-mentioned technical problems. Summary of the Invention

[0005] The main objective of this invention is to provide a three-dimensional intelligent route selection and search method, medium, and equipment for long-distance oil and gas pipelines, aiming to solve the problem that existing methods cannot quickly search for multiple differentiated candidate solutions under complex terrain conditions.

[0006] To achieve the above objectives, this invention proposes a three-dimensional intelligent route selection and search method for long-distance oil and gas pipelines, comprising the following steps: S1: Acquire spatial data of the study area and record pipeline route design constraint parameters, engineering structure discrimination parameters, engineering cost parameters and algorithm search parameters; S2: Establish a smart pipeline route selection optimization model that includes design variables, constraints, and objective functions based on spatial data, pipeline route selection design constraints, engineering structure discrimination parameters, and engineering cost parameters; S3: Based on the intelligent pipeline route selection optimization model, an intelligent pipeline route selection search algorithm is introduced to generate a set of candidate routes, specifically including: S3.1. Based on the intelligent pipeline route selection optimization model, a three-dimensional bidirectional fast search random tree algorithm is used to search for routes and obtain a set of candidate routes. S3.2. Based on the bidirectional Hausdorff distance and average deviation, multiple differentiated schemes are obtained by screening the candidate route set.

[0007] Optionally, in S1, the spatial data includes a digital elevation model, the starting and ending points of the route, obstacles and restricted areas, highways, railways, and rivers; the pipeline route selection design constraint parameters include minimum pipe length, maximum plane deflection angle, maximum longitudinal slope, maximum cross-sectional slope, maximum route extension coefficient, minimum intersection angle, minimum burial depth, maximum main span length, and maximum tunnel length; the engineering structure discrimination parameters include the land feature type, terrain slope threshold, and slope length threshold corresponding to different engineering structures; the engineering cost parameters include the unit cost parameters for earthwork, bends, land acquisition, length-related engineering, underpass engineering structures, and overpass engineering structures; and the algorithm search parameters include search step size, target bias frequency, neighborhood radius, and maximum number of iterations. S2 includes: S2.1 Based on the spatial data of the study area, a three-dimensional pipeline route representation model is established using the pipeline's horizontal intersection points and longitudinal slope change points as design variables; the specific formulas for the three-dimensional pipeline route representation model are as follows: ; in: Represents the set of intersection points of the pipe planes; Represents the set of points where the longitudinal section slopes change; and These represent the sets of x-coordinates and y-coordinates of the intersection points of each pipeline plane, respectively. Indicates the number of intersections of the pipe plane. and These are the x-coordinate and y-coordinate values ​​of the intersection point of the pipe plane, respectively; This represents the set of line mileages corresponding to the points where the longitudinal profile changes slope. This represents the set of design elevations corresponding to the points where the longitudinal section slopes change. Indicates the number of points where the longitudinal profile changes slope. For the first The mileage of the line at each longitudinal section gradient change point. For the first Design elevation of each longitudinal section slope change point; S2.2. Based on the three-dimensional pipeline route representation model, pipeline route selection design constraint parameters are introduced as constraints for the three-dimensional pipeline route representation model, resulting in a constrained three-dimensional pipeline route model; among which, the constraint conditions include geometric constraints, regional constraints, and structural constraints, and the geometric constraints include minimum pipe length. Maximum plane deflection angle , maximum longitudinal slope Maximum slope of cross section and maximum line extension factor Regional constraints include obstacle and restricted area constraints and minimum intersection angle constraints between existing linear features and pipeline routes within the study area. Existing linear features include highways, railways, and rivers. Structural constraints include direct burial section constraints, overpass section constraints, and underpass section constraints. S2.3. Using pipeline construction cost as the objective function of the constrained 3D pipeline route model, the intelligent pipeline route selection optimization model is obtained; objective function The specific formula is as follows: ; in: For earthwork costs, For elbow processing fees, For land acquisition costs, For length-related costs, To reduce the cost of the underground engineering structure, For the cost of the upper span engineering structure; The specific formula for calculating earthwork cost is as follows: ; in: The cross-sectional sections along the pipeline route are numbered. This represents the total number of cross-sectional sections along the pipeline route; This refers to the unit price for earthwork. The length of each earthwork section; The cross-sectional area is calculated based on standard pipeline excavation parameters and terrain conditions. The specific formula for calculating the elbow processing fee is as follows: ; in: , These are the unit costs of cold-bent elbows and hot-bent elbows, respectively. , These refer to the number of cold-bent elbows and hot-bent elbows, respectively. , These are the numbers for cold-bent elbows and hot-bent elbows, respectively; and These are the count values ​​corresponding to cold-bent elbows and hot-bent elbows, respectively. The specific formula for calculating land acquisition costs is as follows: ; in: For the number of land acquisition sites, Number the land acquisition area; The unit price for land acquisition; , The length and width of the land to be acquired shall be specified separately. The specific formula for calculating length-related costs is as follows: ; in: Cost per unit length; This represents the total length of the pipeline route. The underpass section includes a conventional pipe jacking construction section, a mountain tunnel section, a mountain pipe jacking section, and a directional drilling construction section. The specific formula for calculating the structural cost of the underpass project is as follows: ; in: These are the numbers of conventional pipe jacking construction sections, mountain tunnel sections, mountain pipe jacking sections, and directional drilling construction sections, respectively. These are the numbers for the conventional pipe jacking construction section, the mountain tunnel section, the mountain pipe jacking section, and the directional drilling construction section, respectively. These represent the unit cost and length of a conventional pipe jacking construction section, respectively. These represent the unit cost and length of tunnel sections in mountainous areas, respectively. These represent the unit cost and length of the tunnel jacking segment, respectively. These represent the unit cost and length of the directional drilling section, respectively. The specific formula for calculating the cost of the overpass structure is as follows: ; in: This represents the total number of segments spanning the previous segment. Number the segment above; This refers to the unit cost of the upstream segment; This is the length of the upper span.

[0008] Optionally, in S2.2, the geometric constraints are specifically: ; ; ; ; ; ; in: For the first line Intersection of two planes, For the first line The intersection of the longitudinal sections; For the first The intersection of the pipe planes points to the first The direction vectors of the intersection points of the pipe planes For the first The intersection of the pipe planes points to the first The direction vectors of the intersection points of the pipe planes; For the first Design elevation of each longitudinal section slope change point For the first line Intersection of planes; To obtain the first based on the digital elevation model (DEM) The cross-sectional distance coordinates corresponding to each cross-sectional section Ground elevation interpolation function; at the centerline of the pipeline route The left end of the center line of the pipeline The value is negative, indicating the right end of the pipeline centerline. It is positive; It is half the width of the cross section; This represents the projected width of the slope. This is the total length of the pipeline; The specific obstacles and restricted areas constraints of the region constraints are: ; The minimum intersection angle constraint of the region constraint is specifically: ; in: Minimum intersection angle; For the reason and The pipeline route is characterized; This refers to a collection of obstacles and restricted areas that the pipeline route needs to avoid. The direction vector of the existing linear intersection segment. This refers to the set of all sections within the study area where existing linear features intersect with pipeline routes; This refers to the direction vector of the intersecting sections of the corresponding pipeline lines. This is the set of pipeline segments that intersect. The structural constraints are specifically: ; ; ; in: , and The datasets for the burial depth of all excavated direct-buried sections, the length of the overpass section, and the length of the underpass section are stored along the pipeline route, respectively. Minimum burial depth, The maximum main span length, This represents the maximum tunnel length.

[0009] Optionally, S3.1 includes: S3.1.1, Let the number of iterations be... Starting point of pipeline route selection design and the end point Initialize the starting tree for the root node. With the endpoint tree First Set as active exploration tree , Set as target tree ; and based on regional constraints within the study area, a block index table and sparse constraint data are established for online queries during subsequent search processes; where: and ∈ , The three-dimensional geographic space corresponding to the study area; S3.1.2, Randomly generate a state sampling point. Based on target bias frequency The corresponding state sampling points Set as target point Distance from the state sampling point in the active exploration tree Starting from the nearest node, along the direction Generate candidate new nodes in the direction of the nearest node; and based on the nearest node and candidate new nodes A three-dimensional local pipeline route is generated. The three-dimensional local pipeline route that has been verified by the constraints is used as a candidate local route segment. The route cost of the candidate local route segment is calculated. S3.1.3, with candidate new nodes Find the user-defined neighborhood radius centered on the target. Neighboring nodes within range And verify by , as well as Whether the plane deflection angle formed by the parent nodes satisfies the maximum deflection angle constraint is determined by obtaining the k nearest neighbor set consisting of all neighbor nodes that pass the maximum deflection angle constraint check. , ; S3.1.4, For each neighbor node ,check and If the edges between them satisfy all constraints, calculate the cumulative line cost of each neighboring node based on the line cost of the candidate local line segment; otherwise, select from the set of k nearest neighbors. Remove the neighboring node from the list; and select the neighboring node with the lowest cumulative cost as the next highest cost. The final parent node, and join in ; S3.1.5, For the current set of k nearest neighbors For each neighboring node, verify whether the following relationship holds true: ; If true, and by , and The plane deflection angle formed by the parent node and the .... , and If the plane deflection angles formed by each child node satisfy the maximum plane deflection angle constraint, then... The parent node is updated to and along with Recursively update the cumulative path cost of all descendant nodes in the subtree of the root node; otherwise, keep the parent-child relationship of the active exploration tree and the cumulative path cost of each node unchanged. S3.1.6, Verification and Whether the trees can be connected within a distance threshold is checked, and whether the plane deflection angle formed by the connecting edges and the connecting positions satisfies the maximum deflection angle constraint. If the trees can be connected and the constraint is satisfied, the complete origin-end point route formed by the paths from the root nodes of the two trees to the connecting nodes and their connecting edges is recorded as a candidate solution; then the number of iterations is set. ,judge If the maximum number of iterations has been reached, output the candidate route set; otherwise, swap the roles of the active exploration tree and the target tree, and return to step S3.1.2; where: the distance threshold is the search step size. or neighborhood radius .

[0010] Optionally, the process of establishing the block index table and sparse constraint data in S3.1.1 is as follows: Based on the digital elevation model, the study area is discretized into a grid space, and the regional constraints are transformed into the grid attributes of the corresponding grids covered. Specifically, the entire grid space is divided into several fixed-size blocks, and all grids covered by the regional constraints are stored using a sparse coding method to obtain sparse constraint data, which is then saved as a binary file. Record the local coordinates and raster attributes of each stored raster within the corresponding block, and construct a block index table to record whether each block contains constraints and the file offset of the sparse constraint data corresponding to the block in the binary file; wherein: in the block index table, if a constraint is contained, it is marked as non-empty, and if it does not contain a constraint, it is marked as empty.

[0011] Optionally, in S3.1.2, based on the nearest node and candidate new nodes A 3D local pipeline route is generated. The constrained 3D local pipeline routes are then used as candidate local route segments. The route cost of these candidate local route segments is calculated, specifically including: ① Generate a complete 3D local pipeline path using a 3D adaptive search strategy, specifically: When candidate new nodes When located in a non-special structure region, directly connect to the nearest node. and candidate new nodes The three-dimensional local pipeline route is obtained; When candidate new nodes When located within a special structural region, along arrive The extension direction continues to extend the horizontal line, and the longitudinal profile slope line is extended synchronously in conjunction with the ground line of the longitudinal profile and the maximum longitudinal slope constraint until the endpoint of the special structure is identified. and the endpoint Consider as a new candidate node , that is to say = , forming from point to A three-dimensional local pipeline route including complete special engineering structure sections; among which: special structure areas include tunnels, pipe jacking, directional drilling, and crossings; ② The regional constraints, geometric constraints and structural constraints of the three-dimensional local pipeline are verified in sequence to obtain candidate local pipeline segments, and the objective function value corresponding to the candidate local pipeline is calculated, that is, the pipeline cost.

[0012] Optionally, verifying the regional constraints of the 3D local pipeline route specifically includes: Based on the block index table, locate the block to which each grid belongs to the 3D local pipeline. If the block marker is empty, the query result is directly returned, i.e., no constraints are included; otherwise, first check whether the grid is within the pre-computed extended bounding box of any region constraint within the block. If it is not within the pre-computed extended bounding box, there is no need to access the sparse constraint data. If it is within the pre-computed extended bounding box, load the sparse grid data of the block and extract the grid attributes. Identify whether the 3D local pipeline line overlaps with the sparse raster data. If so, remove the 3D local pipeline line and proceed directly to S3.1.3; otherwise, retain the 3D local pipeline line. Verifying the geometric constraints of a 3D local pipeline route specifically includes: ① Verify the minimum pipe length of the three-dimensional local pipeline route subject to region constraints. Maximum plane deflection angle , maximum longitudinal slope Maximum slope of cross section and maximum line extension factor ; ② By iteratively detecting the intersection of the line segments, determine whether the planar projection of the 3D local pipeline line that has passed the regional constraint verification in the current iteration intersects with the planar projection of all current candidate local line segments. If they intersect, they are removed; if they do not intersect, they are retained. Verification of the structural constraints of a 3D local pipeline circuit specifically includes: The structural type of the pipeline is determined based on its burial depth, topographic conditions, and spatial relationship with ground obstacles in the three-dimensional local pipeline route; among which, the structural types include direct burial section, overpass section, and underpass section; For different structure types, determine whether the excavated direct burial section meets the minimum burial depth. Does it meet the maximum main span length requirement? And whether the tunnel section meets the maximum tunnel length requirement. If the constraints are met, the three-dimensional local pipeline is retained; otherwise, it is discarded.

[0013] Optionally, S3.2 includes: S3.2.1 Set up candidate routes The candidate routes are sorted according to their cumulative route cost. The candidate route with the lowest cumulative route cost is selected as the baseline route and added to the final solution set. In the candidate route set, let the candidate route number be . ,make ; S3.2.2, Based on the baseline line length Determine the number of sampling points And based on the number of sampling points For the reference line Equivalent interpolation is performed from the starting point to the ending point to obtain the sampling line. ,in: For the first -1 interpolation point; S3.2.3, the lines in the original solution set Convert to sampling form ,in: For the first -1 interpolation point; S3.2.4 Calculate the final solution set Each line and The two-way Hausdorff distance and average deviation between them, and the specific formula for the two-way Hausdorff distance are as follows: ; ; in: For one-way Hausdorff distance, i.e., quantized point set Any point in the set of points The maximum distance between the nearest neighbors in the middle. for The point set, for The point set, ≠ ; For point set The point number in the middle, For point set Point numbering in the middle; To calculate the Euclidean distance between two points; This indicates taking the maximum value of the two one-way distances; average deviation The specific formula for the indicator is as follows: ; in: for and The Euclidean distance between them For the final solution set The Middle Line After equal interval difference, the index is: sampling points, For the lines in the original solution set After equal interval difference, the index is: sampling points, For index, 0≤ ≤ -1; S3.2.5. Based on the bidirectional Hausdorff distance and the average deviation, respectively, the final solution set is... Each line Perform a difference determination, that is, verify whether the following relationship holds: ; in: Define thresholds for users. = ; If the above relationship holds, then determine To differentiate the routes, add the final solution set. , and if Terminate the process and output the final solution set; otherwise, let Return to S3.2.3; where: The number of differentiated line schemes preset for the final output by the user.

[0014] In addition, the present invention also provides a readable storage medium storing computer program instructions, which, when executed by a processor, implement the three-dimensional intelligent route selection search method for long-distance oil and gas pipelines as described above.

[0015] The present invention also provides an electronic device, comprising: at least one processor, at least one memory, and computer program instructions stored in the memory, wherein the computer program instructions are executed by the processor to perform the three-dimensional intelligent route selection search method for long-distance oil and gas pipelines as described above.

[0016] This invention establishes an intelligent pipeline route selection optimization model based on collected and organized fundamental data. It employs a three-dimensional bidirectional fast search random tree algorithm to solve the optimization model, and can search for candidate pipeline routes with lower overall costs while meeting engineering constraints. Multiple candidate routes with significant differences in orientation are filtered through bidirectional Hausdorff distance and average deviation. This invention can avoid concentrating on single, narrow corridors in complex terrain environments with multiple constraints, providing designers with a rich and reliable selection pool, assisting in manual decision-making, and significantly improving the automation level, solution quality, and work efficiency of long-distance pipeline route selection design in complex terrain. It has good engineering application value. Attached Figure Description

[0017] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on the structures shown in these drawings without creative effort.

[0018] Figure 1 This is a flowchart illustrating the three-dimensional intelligent route selection and search method for long-distance oil and gas pipelines in an embodiment of the present invention. Figure 2 This is a grid diagram of the three-dimensional local pipeline search mechanism in embodiment S3.1.2 of the present invention; Figure 3 This is a longitudinal profile diagram of the three-dimensional local pipeline route search mechanism in embodiment S3.1.2 of the present invention; the horizontal axis represents the route mileage corresponding to the longitudinal profile slope change point; the vertical axis represents the design elevation corresponding to the longitudinal profile slope change point. Figure 4 This is a schematic diagram illustrating the process of establishing the block index table and sparse constraint data in embodiment S3.1.1 of the present invention; Figure 5 This is a schematic diagram illustrating the maximum deflection angle constraint verification during neighbor node search in embodiment S3.1.3 of the present invention. Figure 6Updated in Embodiment S3.1.5 of the present invention A schematic diagram of the maximum deflection angle constraint verification when the parent node is present; Figure 7 This is a schematic diagram illustrating the maximum skew angle constraint verification during the rewiring of the wire tree structure in embodiment S3.1.5 of the present invention. Figure 8 Verification in Embodiment S3.1.6 of the present invention and A schematic diagram illustrating the maximum deflection angle constraint verification for connectivity within a distance threshold.

[0019] The realization of the objective, functional features and advantages of the present invention will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. Detailed Implementation

[0020] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the scope of protection of the present invention.

[0021] It should be noted that all directional indications (such as up, down, left, right, front, back, etc.) in the embodiments of the present invention are only used to explain the relative positional relationship and movement of each component in a certain specific posture (as shown in the figure). If the specific posture changes, the directional indication will also change accordingly.

[0022] Furthermore, in this invention, descriptions involving "first," "second," etc., are for descriptive purposes only and should not be construed as indicating or implying their relative importance or implicitly specifying the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one of that feature. In the description of this invention, "a plurality of" means at least two, such as two, three, etc., unless otherwise explicitly specified.

[0023] In this invention, unless otherwise explicitly specified and limited, the terms "connection," "fixed," etc., should be interpreted broadly. For example, "fixed" can mean a fixed connection, a detachable connection, or an integral part; it can mean a mechanical connection or an electrical connection; it can mean a direct connection or an indirect connection through an intermediate medium; it can mean the internal communication of two components or the interaction between two components, unless otherwise explicitly limited. Those skilled in the art can understand the specific meaning of the above terms in this invention according to the specific circumstances.

[0024] Furthermore, the technical solutions of the various embodiments of the present invention can be combined with each other, but only if they are feasible for those skilled in the art. If the combination of technical solutions is contradictory or cannot be implemented, it should be considered that such combination of technical solutions does not exist and is not within the scope of protection claimed by the present invention.

[0025] This invention proposes a three-dimensional intelligent route selection search method, medium, and equipment for long-distance oil and gas pipelines, aiming to solve the problem that existing methods cannot quickly search for multiple differentiated candidate solutions under complex terrain conditions.

[0026] See Figure 1 A three-dimensional intelligent route selection search method for long-distance oil and gas pipelines includes the following steps: S1 (Basic Data Collection and Organization): Acquire spatial data of the study area and record pipeline route design constraints, engineering structure discrimination parameters, engineering cost parameters, and algorithm search parameters. In S1, spatial data includes a Digital Elevation Model (DEM), route start and end points, obstacles and restricted areas, highways, railways, and rivers. Pipeline route design constraints include minimum pipe length, maximum planar deflection angle, maximum longitudinal slope, maximum cross-sectional slope, maximum route extension coefficient, minimum intersection angle, minimum burial depth, maximum main span length, and maximum tunnel length. Engineering structure discrimination parameters include the land feature type, terrain slope threshold, and slope length threshold corresponding to different engineering structures. Engineering cost parameters include unit cost parameters for earthwork, bends, land acquisition, length-related engineering, underpass structures, and overpass structures. Algorithm search parameters include search step size, target bias frequency, neighborhood radius, and maximum number of iterations. S2 (Establishing a smart pipeline route selection optimization model): Based on spatial data, pipeline route selection design constraint parameters, engineering structure discrimination parameters, and engineering cost parameters, establish a smart pipeline route selection optimization model that includes design variables, constraints, and objective functions; S2 includes: S2.1 (Establishing a 3D Pipeline Route Representation Model): Based on the spatial data of the study area, a 3D pipeline route representation model is established using the pipeline's horizontal intersection points and longitudinal slope change points as design variables. This model describes the pipeline's horizontal alignment and longitudinal elevation changes, respectively. The specific formulas for the 3D pipeline route representation model are as follows: ; in: Represents the set of intersection points of the pipe planes; Represents the set of points where the longitudinal section slopes change; and These represent the sets of x-coordinates and y-coordinates of the intersection points of each pipeline plane, respectively. Indicates the number of intersections of the pipe plane. and These are the x-coordinate and y-coordinate values ​​of the intersection point of the pipe plane, respectively; This represents the set of line mileages corresponding to the points where the longitudinal profile changes slope. This represents the set of design elevations corresponding to the points where the longitudinal section slopes change. Indicates the number of points where the longitudinal profile changes slope. For the first The mileage of the line at each longitudinal section gradient change point. For the first Design elevation of each longitudinal section slope change point; S2.2 (Determining Constraints): Based on the 3D pipeline route representation model, pipeline route selection design constraint parameters are introduced as constraints for the 3D pipeline route representation model, resulting in a constrained 3D pipeline route model. The constraints include geometric constraints, regional constraints, and structural constraints. Geometric constraints include minimum pipe length. Maximum plane deflection angle , maximum longitudinal slope Maximum slope of cross section and maximum line extension factor Regional constraints include obstacle and restricted area constraints and minimum intersection angle constraints between existing linear features and pipeline routes within the study area. Existing linear features include highways, railways, and rivers. Structural constraints include direct burial section constraints, overpass section constraints, and underpass section constraints. In S2.2, the geometric constraints are specifically: ; ; ; ; ; ; in: For the first line Intersection of two planes, For the first line The intersection of the longitudinal sections; For the first The intersection of the pipe planes points to the first The direction vectors of the intersection points of the pipe planes For the first The intersection of the pipe planes points to the first The direction vectors of the intersection points of the pipe planes; For the first Design elevation of each longitudinal section slope change point For the first line Intersection of planes; To obtain the first based on the digital elevation model (DEM) The cross-sectional distance coordinates corresponding to each cross-sectional section Ground elevation interpolation function; at the centerline of the pipeline route The left end of the center line of the pipeline The value is negative, indicating the right end of the pipeline centerline. It is positive; It is half the width of the cross section; This represents the projected width of the slope. This is the total length of the pipeline; Area constraints include specific obstacles and restricted areas that need to be avoided. In addition, when the pipeline route crosses existing roads, railways or rivers within the study area, it must also meet the minimum crossing angle constraint.

[0027] The specific obstacles and restricted areas constraints of the region constraints are: ; The minimum intersection angle constraint of the region constraint is specifically: ; in: Minimum intersection angle; For the reason and The pipeline route is characterized; This refers to a collection of obstacles and restricted areas that the pipeline route needs to avoid. The direction vector of the existing linear intersection segment. This refers to the set of all sections within the study area where existing linear features intersect with pipeline routes; This refers to the direction vector of the intersecting sections of the corresponding pipeline lines. This is the set of pipeline segments that intersect. Generally, pipeline projects typically involve excavating and directly burying sections underground. For this type of project, the burial depth must meet the minimum burial depth requirement. For the overpass and underpass sections, the maximum main span length needs to be considered separately. With maximum tunnel length Constraints. Structural constraints are specifically: ; ; ; in: , and Each dataset stores the burial depth of all excavated direct-buried sections, the length of the overpass section, and the length of the underpass section along the pipeline route. Their values ​​are determined during the route search process based on... and Data, combined with topographic and feature information, is dynamically determined; Minimum burial depth, The maximum main span length, This represents the maximum tunnel length.

[0028] S2.3 (Establishing the Comprehensive Cost Objective Function): Using pipeline construction cost as the constraint, the objective function of the three-dimensional pipeline route model is obtained, resulting in the intelligent pipeline route selection optimization model; objective function The specific formula is as follows: ; in: For earthwork costs, For elbow processing fees, For land acquisition costs, For length-related costs, To reduce the cost of the underground engineering structure, Cost of the upper span engineering structure.

[0029] In this embodiment, the pipeline construction cost includes earthwork cost, elbow processing fee, land acquisition cost, length-related cost, underpass structure cost, and overpass structure cost. The specific calculation formula is as follows: (1) Earthwork cost: ; in: The cross-sectional sections along the pipeline route are numbered. This represents the total number of cross-sectional sections along the pipeline route; This refers to the unit price for earthwork. The length of each earthwork section; This refers to the cross-sectional area calculated based on standard pipeline excavation parameters and terrain conditions.

[0030] (2) Elbow processing fee: ; in: , The unit cost of cold-bent elbows and hot-bent elbows, respectively. and The configuration of elbows must be considered at both the plane intersection and the longitudinal section intersection. , These refer to the number of cold-bent elbows and hot-bent elbows, respectively. , These are the numbers for cold-bent elbows and hot-bent elbows, respectively; and These are the count values ​​corresponding to cold-bent elbows and hot-bent elbows, respectively. In this embodiment, In this embodiment, the angle threshold is typically preset by the designer. If the angle of deviation at the intersection of the plane or the intersection of the longitudinal section is greater than Hot-bent elbows are used; if the deflection angle is less than or equal to However, it is greater than the empirical value (the empirical value in this embodiment is...). If the angle is less than or equal to 0, then a cold-bent elbow should be configured; When necessary, the pipe's own elasticity can be used to achieve the desired change of direction, eliminating the need for elbows.

[0031] (3) Land acquisition costs: ; in: For the number of land acquisition sites, Number the land acquisition area; The unit price for land acquisition; , The length and width of the land to be acquired shall be specified separately.

[0032] (4) Length-related costs: ; in: Cost per unit length (e.g., pipe material cost); This represents the total length of the pipeline.

[0033] (5) Cost of the underpass structure: ; in: These are the numbers of conventional pipe jacking construction sections, mountain tunnel sections, mountain pipe jacking sections, and directional drilling construction sections, respectively. These are the numbers for the conventional pipe jacking construction section, the mountain tunnel section, the mountain pipe jacking section, and the directional drilling construction section, respectively. These represent the unit cost and length of a conventional pipe jacking construction section, respectively. These represent the unit cost and length of tunnel sections in mountainous areas, respectively. These represent the unit cost and length of the tunnel jacking segment, respectively. These represent the unit cost and length of the directional drilling section, respectively. Specific applicable scenarios are: conventional pipe jacking is used when pipelines cross existing highways and railways; directional drilling is typically used when crossing rivers; and in mountainous areas with a slope ≥45°, tunnels are constructed when the slope length is ≥350m, while pipe jacking is used when the slope length is <350m.

[0034] (6) Cost of the overpass structure: ; in: This represents the total number of segments spanning the previous segment. Number the segment above; This refers to the unit cost of the upstream segment; This is the length of the upper span.

[0035] S3 (Proposes a smart pipeline route selection search algorithm): Based on the smart pipeline route selection optimization model, a smart pipeline route selection search algorithm is introduced to generate a set of candidate routes, specifically including: S3.1 (Using a three-dimensional bidirectional fast search random tree algorithm for route search): Based on the intelligent pipeline route selection optimization model, a three-dimensional bidirectional fast search random tree algorithm is used to search for routes and obtain a set of candidate routes. S3.1 includes: S3.1.1, Let the number of iterations be... Starting point of pipeline route selection design and the end point Initialize the starting tree for the root node. With the endpoint tree First Set as active exploration tree , Set as target tree ; and based on regional constraints within the study area, a block index table and sparse constraint data are established for online queries during subsequent search processes; where: and ∈ , The three-dimensional geographic space corresponding to the study area; See Figure 4 In S3.1.1, the process of establishing the block index table and sparse constraint data is as follows: Based on the digital elevation model, the study area is discretized into a grid space, and the regional constraints are transformed into the grid attributes of the corresponding grids covered. Specifically, the entire grid space is divided into several blocks of fixed size (64×64 in this embodiment), and all grids covered by the regional constraints are stored using a sparse coding method to obtain sparse constraint data, which is then saved as a binary file. Record the local coordinates and raster attributes of each stored raster within the corresponding block, and construct a block index table to record whether each block contains constraints and the file offset of the sparse constraint data corresponding to the block in the binary file; wherein: in the block index table, if a constraint is contained, it is marked as non-empty, and if it does not contain a constraint, it is marked as empty.

[0036] S3.1.2, Randomly generate a state sampling point. Based on target bias frequency The corresponding state sampling points Set as target point Distance from the state sampling point in the active exploration tree Starting from the nearest node, along the direction Generate candidate new nodes in the direction of the nearest node; and based on the nearest node and candidate new nodes A three-dimensional local pipeline route is generated. The three-dimensional local pipeline route that has been verified by the constraints is used as a candidate local route segment. The route cost of the candidate local route segment is calculated. See Figure 2 and Figure 3 In S3.1.2, based on the nearest node and candidate new nodes A 3D local pipeline route is generated. The constrained 3D local pipeline routes are then used as candidate local route segments. The route cost of these candidate local route segments is calculated, specifically including: ① Generate a complete 3D local pipeline path using a 3D adaptive search strategy, specifically: When candidate new nodes When located in a non-special structure region, directly connect to the nearest node. and candidate new nodes The three-dimensional local pipeline route is obtained; When candidate new nodes When located within a special structural region, along arrive The extension direction continues to extend the horizontal line, and the longitudinal profile slope line is extended synchronously in conjunction with the ground line of the longitudinal profile and the maximum longitudinal slope constraint until the endpoint of the special structure is identified. and the endpoint Consider as a new candidate node , that is to say = , forming from point to A three-dimensional local pipeline route includes complete special engineering structure sections; wherein: special structure areas include tunnels, pipe jacking, directional drilling, and crossings; this embodiment thus avoids cutting off special structure sections with fixed step lengths, ensuring the integrity of the local route in terms of geometry, structure, and cost evaluation.

[0037] ② The regional constraints, geometric constraints and structural constraints of the three-dimensional local pipeline are verified in sequence to obtain candidate local pipeline segments, and the objective function value corresponding to the candidate local pipeline is calculated, that is, the pipeline cost.

[0038] Verifying the regional constraints of a 3D local pipeline route specifically includes: Based on the block index table, locate the block to which each grid belongs to the 3D local pipeline. If the block marker is empty, the query result is directly returned, i.e., no constraints are included; otherwise, first check whether the grid is within the pre-computed extended bounding box of any region constraint within the block. If it is not within the pre-computed extended bounding box, there is no need to access the sparse constraint data. If it is within the pre-computed extended bounding box, load the sparse grid data of the block and extract the grid attributes. Identify whether the 3D local pipeline line overlaps with the sparse raster data. If so, remove the 3D local pipeline line and proceed directly to S3.1.3; otherwise, retain the 3D local pipeline line. Verifying the geometric constraints of a 3D local pipeline route specifically includes: ① Verify the minimum pipe length of the three-dimensional local pipeline route subject to region constraints. Maximum plane deflection angle , maximum longitudinal slope Maximum slope of cross section and maximum line extension factor ; ② By iteratively detecting the intersection of the line segments, determine whether the planar projection of the 3D local pipeline line that has passed the regional constraint verification in the current iteration intersects with the planar projection of all current candidate local line segments. If they intersect, they are removed; if they do not intersect, they are retained. In this embodiment, the line segment intersection detection specifically involves: By traversing the planar projection segments of the 3D local pipeline routes that have passed the regional constraint verification in the new current iteration and the planar projection segments of all other candidate local route segments except for those adjacent to them, the bounding box intersection judgment method is first used for preliminary screening, and then the two-dimensional vector cross product method is used to determine whether there is an intersection or overlap between the two route segments. If there is an intersection or overlap, it is determined that a self-intersection has occurred and the candidate route segment is removed. If there is no intersection, the candidate route segment is retained.

[0039] Verification of the structural constraints of a 3D local pipeline circuit specifically includes: The structural type of the pipeline is determined based on its burial depth, topographic conditions, and spatial relationship with ground obstacles in the three-dimensional local pipeline route; among which, the structural types include direct burial section, overpass section, and underpass section; For different structure types, determine whether the excavated direct burial section meets the minimum burial depth. Does it meet the maximum main span length requirement? And whether the tunnel section meets the maximum tunnel length requirement. If the constraints are met, the three-dimensional local pipeline is retained; otherwise, it is discarded.

[0040] S3.1.3, with candidate new nodes Find the user-defined neighborhood radius centered on the target. Neighboring nodes within range And verify by , as well as Whether the plane deflection angle formed by the parent nodes satisfies the maximum deflection angle constraint is determined by obtaining the k nearest neighbor set consisting of all neighbor nodes that pass the maximum deflection angle constraint check. , See the calibration process. Figure 5 ; S3.1.4, For each neighbor node ,check and If the edges between nodes satisfy all constraints, calculate the cumulative path cost for each neighbor node; otherwise, start from the k nearest neighbor set. Remove the neighboring node from the list; and select the neighboring node with the lowest cumulative cost as the next highest cost. The final parent node, and join in ; The specific formula for calculating cumulative line costs is as follows: ;

[0041] in: Indicates from node arrive The cost of the root node; From arrive The cost of the root node; calculate and The local line engineering cost between them, i.e., the objective function value; S3.1.5, For the current set of k nearest neighbors For each neighboring node, verify whether the following relationship holds true: ; If true, and by , and The plane deflection angle formed by the parent node and the .... , and If the plane deflection angles formed by each child node satisfy the maximum plane deflection angle constraint, then... The parent node is updated to and along with Recursively update the cumulative path cost of all descendant nodes in the subtree of the root node; otherwise, maintain the parent-child relationships of the active exploration tree and the cumulative path cost of each node unchanged; see also Figure 6 and Figure 7 ; S3.1.6, Verification and Whether the trees can be connected within a distance threshold is checked, and whether the plane deflection angle formed by the connecting edges and the connecting positions satisfies the maximum deflection angle constraint. If the trees can be connected and the constraint is satisfied, the complete origin-end point route formed by the paths from the root nodes of the two trees to the connecting nodes and their connecting edges is recorded as a candidate solution; then the number of iterations is set. ,judge If the maximum number of iterations has been reached, output the candidate route set; otherwise, swap the roles of the active exploration tree and the target tree, and return to step S3.1.2; where: the distance threshold is the search step size. or neighborhood radius See Figure 8 .

[0042] S3.2 (Screening of Differentiated Schemes in the Final Candidate Route Set): Based on the bidirectional Hausdorff distance and average deviation, multiple differentiated schemes are obtained by screening the candidate route set.

[0043] S3.2 includes: S3.2.1 Set up candidate routes The candidate routes are sorted according to their cumulative route cost. The candidate route with the lowest cumulative route cost is selected as the baseline route and added to the final solution set. In the candidate route set, let the candidate route number be . ,make ; S3.2.2, Based on the baseline line length Determine the number of sampling points And based on the number of sampling points For the reference line Equivalent interpolation is performed from the starting point to the ending point to obtain the sampling line. ,in: For the first -1 interpolation point; Number of sampling points The specific calculation formula is as follows: ; in: , These are the minimum and maximum sampling point thresholds, respectively; The neighborhood radius; S3.2.3, the lines in the original solution set Convert to sampling form ,in: For the first -1 interpolation point; S3.2.4 Calculate the final solution set Each line and The two-way Hausdorff distance and average deviation between them, and the specific formula for the two-way Hausdorff distance are as follows: ; ; in: For one-way Hausdorff distance, i.e., quantized point set Any point in the set of points The maximum distance between the nearest neighbors in the middle. for The point set, for The point set, ≠ ; For point set The point number in the middle, For point set Point numbering in the middle; To calculate the Euclidean distance between two points; This means taking the maximum value of the two unidirectional distances to ensure symmetry and capture the most severe deviations in both directions, and is more sensitive to extreme local misalignments; average deviation The specific formula for the indicator is as follows: ; in: for and The Euclidean distance between them For the final solution set The Middle Line After equal interval difference, the index is: sampling points, For the lines in the original solution set After equal interval difference, the index is: sampling points, For index, 0≤ ≤ -1; This embodiment is illustrated by... This method quantifies the overall spatial misalignment between two lines, is insensitive to local outliers, and focuses on the overall deviation trend of the lines. By forming complementary structures, robust assessment of the similarity of long-distance pipeline routes can be achieved.

[0044] S3.2.5. Based on the bidirectional Hausdorff distance and the average deviation, respectively, the final solution set is... Each line Perform a difference determination, that is, verify whether the following relationship holds: ; in: Define thresholds for users. = ; If the above relationship holds, then determine To differentiate the routes, add the final solution set. , and if Terminate the process and output the final solution set; otherwise, let Return to S3.2.3; where: The number of differentiated line schemes preset for the final output by the user.

[0045] This embodiment also provides a readable storage medium storing computer program instructions, which, when executed by a processor, implement the three-dimensional intelligent route selection search method for long-distance oil and gas pipelines as described above.

[0046] It should be noted that the device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Furthermore, in the accompanying drawings of the device embodiments provided by this invention, the connection relationships between modules indicate that they have communication connections, which can be specifically implemented as one or more communication buses or signal lines. Those skilled in the art can understand and implement this without any creative effort.

[0047] This embodiment also includes an electronic device, comprising: at least one processor, at least one memory, and computer program instructions stored in the memory, wherein the computer program instructions are executed by the processor to perform the three-dimensional intelligent route selection search method for long-distance oil and gas pipelines as described above.

[0048] For example, the computer program may be divided into one or more modules / units, which are stored in the memory and executed by the processor to complete the present invention. The one or more modules / units may be a series of computer program instruction segments capable of performing a specific function, which describe the execution process of the computer program in the electronic device.

[0049] The electronic device can be a mobile phone, desktop computer, laptop, handheld computer, cloud server, or other computing device. The electronic device may include, but is not limited to, processors and memory. For example, the electronic device may also include input / output devices, network access devices, buses, etc.

[0050] The processor can be a Central Processing Unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor can be a microprocessor or any conventional processor. The processor is the control center of the electronic device, connecting all parts of the electronic device via various interfaces and lines.

[0051] The memory can be used to store the computer program and / or modules. The processor implements the computer program by running or executing the computer program and / or modules stored in the memory, and by calling data stored in the memory. The memory may mainly include a program storage area and a data storage area. The program storage area may store the operating system, at least one application program required for a function (such as sound playback function, image playback function, etc.), etc.; the data storage area may store data created according to the use of the mobile phone (such as audio data, phonebook, etc.). In addition, the memory may include high-speed random access memory, and may also include non-volatile memory, such as hard disk, memory, plug-in hard disk, smart media card (SMC), secure digital card (SD) card, flash card, at least one disk storage device, flash memory device, or other volatile solid-state storage device.

[0052] If the modules / units integrated in the electronic device are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, all or part of the processes in the methods of the above embodiments of the present invention can also be implemented by a computer program instructing related hardware. The computer program can be stored in a readable storage medium, and when executed by a processor, it can implement the steps of the various method embodiments described above. The computer program includes computer program code, which can be in the form of source code, object code, executable files, or certain intermediate forms. The computer-readable medium can include: any entity or device capable of carrying the computer program code, recording media, USB flash drives, portable hard drives, magnetic disks, optical disks, computer memory, read-only memory (ROM), random access memory (RAM), electrical carrier signals, telecommunication signals, and software distribution media, etc. The above descriptions are merely preferred embodiments of the present invention and do not limit the scope of the present invention. Any equivalent structural transformations made based on the inventive concept of the present invention and the description and drawings of the present invention, or direct / indirect applications in other related technical fields, are included within the protection scope of the present invention.

Claims

1. A three-dimensional intelligent route selection and search method for long-distance oil and gas pipelines, characterized in that, Includes the following steps: S1: Acquire spatial data of the study area and record pipeline route design constraint parameters, engineering structure discrimination parameters, engineering cost parameters and algorithm search parameters; S2: Establish a smart pipeline route selection optimization model that includes design variables, constraints, and objective functions based on spatial data, pipeline route selection design constraints, engineering structure discrimination parameters, and engineering cost parameters; S3: Based on the intelligent pipeline route selection optimization model, an intelligent pipeline route selection search algorithm is introduced to generate a set of candidate routes, specifically including: S3.1, Based on the intelligent pipeline route selection optimization model, a three-dimensional bidirectional fast search random tree algorithm is used to search for candidate routes and obtain a set of candidate routes; S3.1 includes: S3.1.1, Let the number of iterations be... Starting point of pipeline route selection design and the end point Initialize the starting tree for the root node. With the endpoint tree First Set as active exploration tree , Set as target tree ; and based on regional constraints within the study area, a block index table and sparse constraint data are established for online queries during subsequent search processes; where: and ∈ , The three-dimensional geographic space corresponding to the study area; S3.1.2, Randomly generate a state sampling point. Based on target bias frequency The corresponding state sampling points Set as target point Distance from the state sampling point in the active exploration tree Starting from the nearest node, along the direction Generate candidate new nodes in the direction of the nearest node; and based on the nearest node and candidate new nodes A three-dimensional local pipeline route is generated. The three-dimensional local pipeline route that has been verified by the constraints is used as a candidate local route segment. The route cost of the candidate local route segment is calculated. In S3.1.2, based on the nearest node and candidate new nodes A 3D local pipeline route is generated. The constrained 3D local pipeline routes are then used as candidate local route segments. The route cost of these candidate local route segments is calculated, specifically including: ① Generate a complete 3D local pipeline path using a 3D adaptive search strategy, specifically: When candidate new nodes When located in a non-special structure region, directly connect to the nearest node. and candidate new nodes The three-dimensional local pipeline route is obtained; When candidate new nodes When located within a special structural region, along arrive The extension direction continues to extend the horizontal line, and the longitudinal profile slope line is extended synchronously in conjunction with the ground line of the longitudinal profile and the maximum longitudinal slope constraint until the endpoint of the special structure is identified. and the endpoint Consider as a new candidate node , that is to say = , forming from point to A three-dimensional local pipeline route including complete special engineering structure sections; among which: special structure areas include tunnels, pipe jacking, directional drilling, and crossings; ② The regional constraints, geometric constraints and structural constraints of the three-dimensional local pipeline are verified in sequence to obtain candidate local pipeline segments, and the objective function value corresponding to the candidate local pipeline is calculated, i.e., the pipeline cost; S3.1.3, with candidate new nodes Find the user-defined neighborhood radius centered on the target. Neighboring nodes within range And verify by , as well as Whether the plane deflection angle formed by the parent nodes satisfies the maximum deflection angle constraint is determined by obtaining the k nearest neighbor set consisting of all neighbor nodes that pass the maximum deflection angle constraint check. , ; S3.1.4, For each neighbor node ,check and If the edges between them satisfy all constraints, calculate the cumulative line cost of each neighboring node based on the line cost of the candidate local line segment; otherwise, select from the set of k nearest neighbors. Remove the neighboring node from the list; and select the neighboring node with the lowest cumulative cost as the next highest cost. The final parent node, and join in ; S3.1.5, For the current set of k nearest neighbors For each neighboring node, verify whether the following relationship holds true: ; If true, and by , and The plane deflection angle formed by the parent node and the .... , and If the plane deflection angles formed by each child node satisfy the maximum plane deflection angle constraint, then... The parent node is updated to and along with Recursively update the cumulative path cost of all descendant nodes in the subtree of the root node; otherwise, keep the parent-child relationship of the active exploration tree and the cumulative path cost of each node unchanged. S3.1.6, Verification and Whether the trees can be connected within a distance threshold is checked, and whether the plane deflection angle formed by the connecting edges and the connecting positions satisfies the maximum deflection angle constraint. If the trees can be connected and the constraint is satisfied, the complete origin-end point route formed by the paths from the root nodes of the two trees to the connecting nodes and their connecting edges is recorded as a candidate solution; then the number of iterations is set. = +1, judgment If the maximum number of iterations has been reached, output the candidate route set; otherwise, swap the roles of the active exploration tree and the target tree, and return to step S3.1.2; where: the distance threshold is the search step size. or neighborhood radius ; S3.

2. Based on the bidirectional Hausdorff distance and average deviation, multiple differentiated schemes are obtained by screening the candidate route set.

2. The three-dimensional intelligent route selection and search method for long-distance oil and gas pipelines according to claim 1, characterized in that, In S1, the spatial data includes a digital elevation model, the starting and ending points of the route, obstacles and restricted areas, highways, railways, and rivers; the pipeline route selection design constraint parameters include minimum pipe length, maximum plane deflection angle, maximum longitudinal slope, maximum cross-sectional slope, maximum route extension coefficient, minimum intersection angle, minimum burial depth, maximum main span length, and maximum tunnel length; the engineering structure discrimination parameters include the land feature type, terrain slope threshold, and slope length threshold corresponding to different engineering structures; the engineering cost parameters include the unit cost parameters for earthwork, bends, land acquisition, length-related engineering, underpass structures, and overpass structures. The algorithm's search parameters include search step size, target bias frequency, neighborhood radius, and maximum number of iterations; S2 includes: S2.1 Based on the spatial data of the study area, a three-dimensional pipeline route representation model is established using the pipeline's horizontal intersection points and longitudinal slope change points as design variables; the specific formulas for the three-dimensional pipeline route representation model are as follows: ; in: Represents the set of intersection points of the pipe planes; Represents the set of points where the longitudinal section slopes change; and These represent the sets of x-coordinates and y-coordinates of the intersection points of each pipeline plane, respectively. Indicates the number of intersections of the pipe plane. and These are the x-coordinate and y-coordinate values ​​of the intersection point of the pipe plane, respectively; This represents the set of line mileages corresponding to the points where the longitudinal profile changes slope. This represents the set of design elevations corresponding to the points where the longitudinal section slopes change. Indicates the number of points where the longitudinal profile changes slope. For the first The mileage of the line at each longitudinal section gradient change point. For the first Design elevation of each longitudinal section slope change point; S2.

2. Based on the three-dimensional pipeline route representation model, pipeline route selection design constraint parameters are introduced as constraints for the three-dimensional pipeline route representation model, resulting in a constrained three-dimensional pipeline route model; among which, the constraint conditions include geometric constraints, regional constraints, and structural constraints, and the geometric constraints include minimum pipe length. Maximum plane deflection angle , maximum longitudinal slope Maximum slope of cross section and maximum line extension factor Regional constraints include obstacle and restricted area constraints and minimum intersection angle constraints between existing linear features and pipeline routes within the study area. Existing linear features include highways, railways, and rivers. Structural constraints include direct burial section constraints, overpass section constraints, and underpass section constraints. S2.

3. Using pipeline construction cost as the objective function of the constrained 3D pipeline route model, the intelligent pipeline route selection optimization model is obtained; objective function The specific formula is as follows: ; in: For earthwork costs, For elbow processing fees, For land acquisition costs, For length-related costs, To reduce the cost of the underground engineering structure, For the cost of the upper span engineering structure; The specific formula for calculating earthwork cost is as follows: ; in: The cross-sectional sections along the pipeline route are numbered. This represents the total number of cross-sectional sections along the pipeline route; This refers to the unit price for earthwork. The length of each earthwork section; The cross-sectional area is calculated based on standard pipeline excavation parameters and terrain conditions. The specific formula for calculating the elbow processing fee is as follows: ; in: , These are the unit costs of cold-bent elbows and hot-bent elbows, respectively. , These refer to the number of cold-bent elbows and hot-bent elbows, respectively. , These are the numbers for cold-bent elbows and hot-bent elbows, respectively; and These are the count values ​​corresponding to cold-bent elbows and hot-bent elbows, respectively. The specific formula for calculating land acquisition costs is as follows: ; in: For the number of land acquisition sites, Number the land acquisition area; The unit price for land acquisition; , The length and width of the land to be acquired shall be specified separately. The specific formula for calculating length-related costs is as follows: ; in: Cost per unit length; This represents the total length of the pipeline route. The underpass section includes a conventional pipe jacking construction section, a mountain tunnel section, a mountain pipe jacking section, and a directional drilling construction section. The specific formula for calculating the structural cost of the underpass project is as follows: ; in: These are the numbers of conventional pipe jacking construction sections, mountain tunnel sections, mountain pipe jacking sections, and directional drilling construction sections, respectively. These are the numbers for the conventional pipe jacking construction section, the mountain tunnel section, the mountain pipe jacking section, and the directional drilling construction section, respectively. These represent the unit cost and length of a conventional pipe jacking construction section, respectively. These represent the unit cost and length of tunnel sections in mountainous areas, respectively. These represent the unit cost and length of the tunnel jacking segment, respectively. These represent the unit cost and length of the directional drilling section, respectively. The specific formula for calculating the cost of the overpass structure is as follows: ; in: This represents the total number of segments spanning the previous segment. Number the segment above; This refers to the unit cost of the upstream segment; This is the length of the upper span.

3. The three-dimensional intelligent route selection and search method for long-distance oil and gas pipelines according to claim 2, characterized in that, In S2.2, the geometric constraints are specifically: ; ; ; ; ; ; in: For the first line Intersection of two planes, For the first line The intersection of the longitudinal sections; For the first The intersection of the pipe planes points to the first The direction vectors of the intersection points of the pipe planes For the first The intersection of the pipe planes points to the first The direction vectors of the intersection points of the pipe planes; For the first Design elevation of each longitudinal section slope change point For the first line Intersection of planes; To obtain the first based on the digital elevation model (DEM) The cross-sectional distance coordinates corresponding to each cross-sectional section Ground elevation interpolation function; at the centerline of the pipeline route The left end of the center line of the pipeline The value is negative, indicating the right end of the pipeline centerline. It is positive; It is half the width of the cross section; This represents the projected width of the slope. This is the total length of the pipeline; The specific obstacles and restricted areas constraints of the region constraints are: ; The minimum intersection angle constraint of the region constraint is specifically: ; in: Minimum intersection angle; For the reason and The pipeline route is characterized; This refers to a collection of obstacles and restricted areas that the pipeline route needs to avoid. The direction vector of the existing linear intersection segment. This refers to the set of all sections within the study area where existing linear features intersect with pipeline routes; This refers to the direction vector of the intersecting sections of the corresponding pipeline lines. This is the set of pipeline segments that intersect. The structural constraints are specifically: ; ; ; in: , and The datasets for the burial depth of all excavated direct-buried sections, the length of the overpass section, and the length of the underpass section are stored along the pipeline route, respectively. Minimum burial depth, The maximum main span length, This represents the maximum tunnel length.

4. The three-dimensional intelligent route selection and search method for long-distance oil and gas pipelines according to claim 1, characterized in that, In S3.1.1, the process of establishing the block index table and sparse constraint data is as follows: Based on the digital elevation model, the study area is discretized into a grid space, and the regional constraints are transformed into the grid attributes of the corresponding grids covered. Specifically, the entire grid space is divided into several fixed-size blocks, and all grids covered by the regional constraints are stored using a sparse coding method to obtain sparse constraint data, which is then saved as a binary file. Record the local coordinates and raster attributes of each stored raster within the corresponding block, and construct a block index table to record whether each block contains constraints and the file offset of the sparse constraint data corresponding to the block in the binary file; wherein: in the block index table, if a constraint is contained, it is marked as non-empty, and if it does not contain a constraint, it is marked as empty.

5. The three-dimensional intelligent route selection and search method for long-distance oil and gas pipelines according to claim 4, characterized in that, Verifying the regional constraints of a 3D local pipeline route specifically includes: Based on the block index table, locate the block to which each grid belongs to the 3D local pipeline. If the block marker is empty, the query result is directly returned, i.e., no constraints are included; otherwise, first check whether the grid is within the pre-computed extended bounding box of any region constraint within the block. If it is not within the pre-computed extended bounding box, there is no need to access the sparse constraint data. If it is within the pre-computed extended bounding box, load the sparse grid data of the block and extract the grid attributes. Identify whether the 3D local pipeline line overlaps with the sparse raster data. If so, remove the 3D local pipeline line and proceed directly to S3.1.3; otherwise, retain the 3D local pipeline line. Verifying the geometric constraints of a 3D local pipeline route specifically includes: ① Verify the minimum pipe length of the three-dimensional local pipeline route subject to region constraints. Maximum plane deflection angle , maximum longitudinal slope Maximum slope of cross section and maximum line extension factor ; ② By iteratively detecting the intersection of the line segments, determine whether the planar projection of the 3D local pipeline line that has passed the regional constraint verification in the current iteration intersects with the planar projection of all current candidate local line segments. If they intersect, they are removed; if they do not intersect, they are retained. Verification of the structural constraints of a 3D local pipeline circuit specifically includes: The structural type of the pipeline is determined based on its burial depth, topographic conditions, and spatial relationship with ground obstacles in the three-dimensional local pipeline route; among which, the structural types include direct burial section, overpass section, and underpass section; For different structure types, determine whether the excavated direct burial section meets the minimum burial depth. Does it meet the maximum main span length requirement? And whether the tunnel section meets the maximum tunnel length requirement. If the constraints are met, the three-dimensional local pipeline is retained; otherwise, it is discarded.

6. The three-dimensional intelligent route selection and search method for long-distance oil and gas pipelines according to any one of claims 1 to 3, characterized in that, S3.2 includes: S3.2.1 Set up candidate routes The candidate routes are sorted according to their cumulative route cost. The candidate route with the lowest cumulative route cost is selected as the baseline route and added to the final solution set. In the candidate route set, let the candidate route number be . ,make ; S3.2.2, Based on the baseline line length Determine the number of sampling points And based on the number of sampling points For the reference line Equivalent interpolation is performed from the starting point to the ending point to obtain the sampling line. ,in: For the first -1 interpolation point; S3.2.3, the lines in the original solution set Convert to sampling form ,in: For the first -1 interpolation point; S3.2.4 Calculate the final solution set Each line and The two-way Hausdorff distance and average deviation between them, and the specific formula for the two-way Hausdorff distance are as follows: ; ; in: For one-way Hausdorff distance, i.e., quantized point set Any point in the set of points The maximum distance between the nearest neighbors in the middle. for The point set, for The point set, ≠ ; For point set The point number in the middle, For point set Point numbering in the middle; To calculate the Euclidean distance between two points; This indicates taking the maximum value of the two one-way distances; average deviation The specific formula for the indicator is as follows: ; in: for and The Euclidean distance between them For the final solution set The Middle Line After equal interval difference, the index is: sampling points, For the lines in the original solution set After equal interval difference, the index is: sampling points, For index, 0≤ ≤ -1; S3.2.

5. Based on the bidirectional Hausdorff distance and the average deviation, respectively, the final solution set is... Each line Perform a difference determination, that is, verify whether the following relationship holds: ; in: Define thresholds for users. = ; If the above relationship holds, then determine To differentiate the routes, add the final solution set. , and if Terminate the process and output the final solution set; otherwise, let Return to S3.2.3; where: The number of differentiated line schemes preset for the final output by the user.

7. A readable storage medium, characterized in that, It stores computer program instructions, which, when executed by a processor, implement the three-dimensional intelligent route selection search method for long-distance oil and gas pipelines as described in any one of claims 1 to 6.

8. An electronic device, characterized in that, include: The method comprises at least one processor, at least one memory, and computer program instructions stored in the memory, wherein the computer program instructions are executed by the processor as described in any one of claims 1 to 6, and is a three-dimensional intelligent route selection search method for long-distance oil and gas pipelines.