A method, device, equipment and medium for extracting an upper surface based on a geological model

By constructing and filtering an array of triangular faces, removing duplicate and perpendicular triangular faces, and determining the highest triangular face, the problem of low efficiency in extracting the upper surface of geological models is solved, achieving efficient and accurate upper surface extraction.

CN115330964BActive Publication Date: 2026-07-14WUHAN INFOEARTH INFORMATION CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
WUHAN INFOEARTH INFORMATION CO LTD
Filing Date
2022-08-04
Publication Date
2026-07-14

AI Technical Summary

Technical Problem

Existing technologies for extracting the upper surface of complex and massive geological models suffer from low extraction efficiency, slow speed, and low accuracy.

Method used

By constructing a first set of arrays containing the vertices and indices of the triangular faces, removing duplicate triangular faces and those perpendicular to the horizontal direction, determining the highest triangular face, and extracting the upper surface of the model.

Benefits of technology

It improves the accuracy and efficiency of surface extraction from the model and significantly shortens the extraction time.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115330964B_ABST
    Figure CN115330964B_ABST
Patent Text Reader

Abstract

The application provides a geological model-based upper surface extraction method, device, equipment and medium, and relates to the field of urban geological models.The method comprises the following steps: constructing a first total array set according to triangular faces in a model file;traversing all triangular faces according to triangular face serial numbers until all to-be-removed array sets are removed to determine a second total array set; after the to-be-removed array sets are removed, determining a third total array set; traversing all highest triangular faces, extracting each reserved triangular face from the highest triangular face to construct a model upper surface; the to-be-removed array set is determined according to the array set intersection of each vertex associated face of the triangular face; and the reserved triangular face is the highest triangular face in the case that the number of line segments corresponding to the second identification point is the same as the number of triangular faces corresponding to the second identification point.The application is suitable for complex and large-data artificial geological models, saves the calculation and processing time for each processing step, and improves the model extraction efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of urban geological models, and in particular to a method, apparatus, equipment and medium for extracting the upper surface of a geological model. Background Technology

[0002] At present, geological models are mainly artificial models generated by modeling tools. They are large in scope, have certain geological and geographical features, and include surface information and underground geological strata information, as well as irregular outlines. Users can generate 3D model file format model files by using 3D geological modeling tools, and the upper surface of the geological model can display digital information of surface geology in the field of urban geology.

[0003] Current methods for extracting the upper surface of geological models are cumbersome, have significant errors during extraction, and take a relatively long time. In particular, when extracting the upper surface of complex geological models with large amounts of data, there are often problems such as low extraction efficiency, slow speed, and inaccurate extraction of the upper surface. Summary of the Invention

[0004] This invention provides a method, apparatus, equipment, and medium for extracting the upper surface of a geological model, which solves the technical defects of existing technologies that cannot quickly extract the upper surface of a model from complex and large-scale geological models, and achieves efficient extraction of the upper surface of the model.

[0005] In a first aspect, the present invention provides a method for extracting the upper surface based on a geological model, comprising:

[0006] Based on the triangular face associated with each first identifier point in the model file, construct a first set of total arrays consisting of the vertices and triangular face indices of all triangular faces.

[0007] Based on the triangular face index, traverse all triangular faces in the first total array set until all array sets to be removed are eliminated, in order to determine the second total array set;

[0008] After deleting the array set to be deleted from the second total array set, determine the third total array set;

[0009] Traverse all the highest triangles and extract each retained triangle from all the highest triangles to construct the upper surface of the model;

[0010] The set of arrays to be removed is determined by the intersection of the arrays of the faces associated with each vertex of the triangle.

[0011] The set of arrays to be deleted is determined based on the dot product of the normal vector and the perpendicular vector in the second total array set;

[0012] The retained triangle is the highest triangle when the number of line segments corresponding to the second marker point is the same as the number of triangles corresponding to the second marker point.

[0013] The second marker is all markers associated with any highest triangle face;

[0014] The highest triangular face is determined based on the coordinates of the corresponding identifier point in the third total array set.

[0015] According to the method for extracting the upper surface based on a geological model provided by the present invention, the first total array set, composed of the vertices and triangular facets of all triangular faces, is constructed based on the triangular facets associated with each first identifier point in the model file, including:

[0016] Traverse each first marker point in the model file to determine all triangular faces;

[0017] Take the three vertices corresponding to each triangular face as the first constituent element;

[0018] Each triangular face is numbered sequentially, and the corresponding serial number of the numbered triangular face is used as the second component element;

[0019] The first total array set is determined based on the first and second constituent elements corresponding to each triangular face.

[0020] According to the method for extracting the upper surface based on a geological model provided by the present invention, the step of traversing all triangular faces in the first total array set according to the triangular face index until all array sets to be removed are eliminated to determine the second total array set includes:

[0021] Determine the first, second, and third vertices corresponding to the three vertices of any triangle face;

[0022] Determine the first set of arrays associated with the first vertex, determine the second set of arrays associated with the second vertex, and determine the third set of arrays associated with the third vertex;

[0023] The intersection of the first array set, the second data set, and the third array set is determined as the array set to be removed;

[0024] Remove the set of arrays to be removed corresponding to the triangular face from the first total array set;

[0025] Based on the triangular face index, traverse all triangular faces until all array sets to be removed are determined.

[0026] Remove all array sets to be removed from the first total array set to determine the second total array set.

[0027] According to the method for extracting the upper surface based on a geological model provided by the present invention, the step of determining the third total array set after deleting the array set to be deleted from the second total array set includes:

[0028] Determine the dot product of the normal vector of each array set in the second total array set with the perpendicular vector in the three-dimensional coordinate system;

[0029] The set of arrays whose dot product values ​​are less than a preset value is identified as the set of arrays to be deleted.

[0030] The array set to be deleted is removed from the second total array set to determine the third total array set.

[0031] According to the method for extracting the upper surface of a geological model provided by the present invention, before traversing all the highest triangular faces and extracting each retained triangular face from all the highest triangular faces to construct the upper surface of the model, the method includes:

[0032] Based on the third total array set, determine all third identifier points related to the third total array set;

[0033] Based on the line segments associated with each third identifier point, construct an initial set of line segments, which consists of the endpoints of all line segments.

[0034] The initial line segment set is updated based on all line segments in the third total data set, and the updated line segment set is determined such that the updated line segment set contains all the line segments.

[0035] According to the geological model-based upper surface extraction method provided by the present invention, after determining all third marker points related to the third total array set, the method further includes:

[0036] The highest marker point is determined based on the coordinate information of the third marker point;

[0037] Iterate through all the highest marker points, and determine the highest triangle corresponding to each highest marker point from the third total array set to obtain all the highest triangles.

[0038] According to the method for extracting the upper surface of a geological model provided by the present invention, the step of traversing all the highest triangular faces and extracting each retained triangular face from all the highest triangular faces to construct the upper surface of the model includes:

[0039] Based on the third total data set and the updated line segment set, if the number of line segments corresponding to any second identifier point is the same as the number of triangles corresponding to the second identifier point, the highest triangle corresponding to the second identifier point is determined to be a retained triangle.

[0040] Iterate through all the highest triangles until all the remaining triangles are determined;

[0041] Extract all retained triangles and construct the upper surface of the model based on all retained triangles.

[0042] Secondly, a surface extraction device based on a geological model is also provided, comprising:

[0043] Construction Unit: Used to construct a first set of arrays based on the triangles associated with each first identifier point in the model file, with the vertices and triangle numbers of all triangles as components;

[0044] Processing unit: The user traverses all triangles in the first total array set according to the triangle face number until all array sets to be removed are eliminated, so as to determine the second total array set;

[0045] Determining Unit: After deleting the array set to be deleted from the second total array set, determine the third total array set;

[0046] Extraction Unit: Traverse all the highest triangles and extract each retained triangle from all the highest triangles to construct the upper surface of the model;

[0047] The set of arrays to be removed is determined by the intersection of the arrays of the faces associated with each vertex of the triangle.

[0048] The set of arrays to be deleted is determined based on the dot product of the normal vector and the perpendicular vector in the second total array set;

[0049] The retained triangle is the highest triangle when the number of line segments corresponding to the second marker point is the same as the number of triangles corresponding to the second marker point.

[0050] The second marker is all markers associated with any highest triangle face;

[0051] The highest triangular face is determined based on the coordinates of the corresponding identifier point in the third total array set.

[0052] Thirdly, an electronic device is also provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the above-described geological model-based upper surface extraction method.

[0053] Fourthly, a non-transitory computer-readable storage medium is also provided, on which a computer program is stored, which, when executed by a processor, implements the above-described method for extracting the upper surface based on a geological model.

[0054] This invention provides a method, apparatus, device, and medium for extracting the upper surface of a geological model. First, duplicate triangular faces are removed from a first total array set constructed from the model file to obtain a second total array set. Then, triangular faces perpendicular to the horizontal direction are removed from the second total array set to obtain a third total array set. Finally, the upper surface of the model is extracted from the highest triangular face determined by the third total array set. This invention is particularly suitable for complex geological models with large amounts of data. Based on the sequential processing logic of this invention, each processing step saves computation time and improves processing efficiency. From the perspective of overall model extraction, each processing step is closely related and inseparable, resulting in more accurate extraction of the model's upper surface while significantly saving extraction time and improving model extraction efficiency. Attached Figure Description

[0055] To more clearly illustrate the technical solutions in this 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 some embodiments of this invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.

[0056] Figure 1 This is one of the flowcharts of the geological model-based upper surface extraction method provided by the present invention;

[0057] Figure 2 This is a schematic diagram of the process for constructing the first total array set provided by the present invention;

[0058] Figure 3 This is a flowchart illustrating the process of determining the second total array set provided by the present invention;

[0059] Figure 4 This is a flowchart illustrating the process of determining the third total array set provided by the present invention;

[0060] Figure 5 This is the second flowchart of the geological model-based upper surface extraction method provided by the present invention;

[0061] Figure 6 This is the third flowchart of the geological model-based upper surface extraction method provided by the present invention;

[0062] Figure 7 This is a schematic diagram of the process for constructing the upper surface of the model provided by the present invention;

[0063] Figure 8 This is a schematic diagram of the structure of the geological model-based upper surface extraction device provided by the present invention;

[0064] Figure 9 This is a schematic diagram of the structure of the electronic device provided by the present invention. Detailed Implementation

[0065] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this invention. All other embodiments obtained by those skilled in the art based on the embodiments of this invention without creative effort are within the scope of protection of this invention.

[0066] It should be noted that, in the description of the embodiments of the present invention, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.

[0067] The terms "first," "second," etc., used in this application are used to distinguish similar objects and not to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that embodiments of this application can be implemented in orders other than those illustrated or described herein, and the objects distinguished by "first," "second," etc., are generally of the same class and the number of objects is not limited; for example, a first object can be one or more.

[0068] Figure 1 This is one of the flowcharts illustrating the upper surface extraction method based on a geological model provided by the present invention. The present invention discloses an upper surface extraction method based on a geological model, comprising:

[0069] Based on the triangular face associated with each first identifier point in the model file, construct a first set of total arrays consisting of the vertices and triangular face indices of all triangular faces.

[0070] Based on the triangular face index, traverse all triangular faces in the first total array set until all array sets to be removed are eliminated, in order to determine the second total array set;

[0071] After deleting the array set to be deleted from the second total array set, determine the third total array set;

[0072] Traverse all the highest triangles and extract each retained triangle from all the highest triangles to construct the upper surface of the model;

[0073] The set of arrays to be removed is determined by the intersection of the arrays of the faces associated with each vertex of the triangle.

[0074] The set of arrays to be deleted is determined based on the dot product of the normal vector and the perpendicular vector in the second total array set;

[0075] The retained triangle is the highest triangle when the number of line segments corresponding to the second marker point is the same as the number of triangles corresponding to the second marker point.

[0076] The second marker is all markers associated with any highest triangle face;

[0077] The highest triangular face is determined based on the coordinates of the corresponding identifier point in the third total array set.

[0078] In step 101, the 3D model file format is a standard model file format with good portability, making it very suitable for interaction between 3D software models. In the 3D model file format, specific identifiers are typically used to identify material library file names. For example, the characters 'g' and 'o' can be used to identify groups; specific identifiers can be used to specify material names within the material library file; the character 'v' can be used to represent the position information of the identifier point; the character 'vt' can be used to represent the texture information of the identifier point; the character 'vn' can be used to represent the normal information of the identifier point; and the character 'f' can be used to represent the identifier face. Specifically, the model file referred to in this invention consists of several groups, and each group consists of several faces, and each face consists of three vertices. The material library file mainly stores the material information and texture information of each group. The material information includes ambient light, diffuse light, reflected light, self-illumination, and the sharpness of reflected specular highlights, etc.; the texture information is an image, which is superimposed onto the 3D model during rendering based on the coordinates of the texture points.

[0079] Those skilled in the art will understand that a 3D model file format mainly consists of a 3D model file format file and a material library file. The 3D model file format file primarily stores information such as model markers and face groups. Marker points are composed of three arrays: position information, normal information, and texture information. The position information refers to the model coordinates of the marker points. Optionally, the coordinates of the model marker points can be determined by a coordinate system formed by the X, Y, and Z axes. The normal information is also determined by a coordinate system formed by the X, Y, and Z axes, and its value ranges from 0 to 1. It is mainly used to calculate the reflection direction of ambient light when rendering the model. The texture information has a value range of 0 to 1 and is mainly used to record the texture mapping position.

[0080] In this invention, the triangular facets refer to faces composed of marker points. This invention aims to address a method for processing triangular faces formed by three marker points. Based on the triangular faces associated with each first marker point in the model file, it constructs a first total array set, with the vertices and triangular facet indices of all triangular faces as its constituent elements. In this embodiment, firstly, all first marker points are determined according to the model file; then, the triangular faces associated with each first marker point are determined; and finally, a first total array set is constructed based on each triangular facet. The constituent elements of the first total array set include the vertices and triangular facet indices of the triangular faces.

[0081] In step 102, based on the triangular face index, all triangular faces in the first total array set are traversed until all array sets to be eliminated are removed, thereby determining the second total array set. The array sets to be eliminated are determined based on the intersection of the array sets of faces associated with each vertex of the triangular face. The triangular face index is used to traverse all triangular faces in order to determine the array sets to be eliminated. The determination of the array sets to be eliminated will be further described in the following embodiments. The present invention aims to traverse all triangular faces, determine all array sets to be eliminated, and remove all array sets to be eliminated from the first total array set to determine the second total array set.

[0082] In step 103, after deleting the array set to be deleted from the second total array set, a third total array set is determined. The array set to be deleted is determined based on the dot product of the normal vector and the perpendicular direction vector in the second total array set. The purpose of this step is to delete the triangular faces perpendicular to the XY axis plane in the three-dimensional coordinate system. For example, if the model in this invention is a cylinder, the purpose of this step is to delete the circumferential surface between the upper and lower bases of the model, leaving only the upper and lower bases.

[0083] In step 104, all the highest triangles are traversed, and each retained triangle is extracted from all the highest triangles to construct the upper surface of the model. The retained triangle is the highest triangle where the number of line segments corresponding to the second marker point is the same as the number of triangles corresponding to the second marker point. The second marker point is all the marker points associated with any highest triangle. The highest triangle is determined according to the marker point coordinates corresponding to the third total array set. In this embodiment, all the highest triangles are first determined according to the marker point coordinates corresponding to the third total array set. All the highest triangles are traversed, and the highest triangle where the number of line segments corresponding to all the marker points associated with any highest triangle is the same as the number of triangles is determined as the retained triangle.

[0084] This invention determines that a point is inside a plane if the number of triangles and line segments associated with that point are equal; otherwise, if the number of triangles and line segments associated with that point are not equal, it is determined that the point is on the edge of the plane. Since the upper surface needs to be extracted, all points need to be traversed, and the highest point is determined by comparing their Z-axis coordinates. Then, based on the relationship between points and planes, other triangles in this plane are searched in turn.

[0085] This invention provides a method, apparatus, device, and medium for extracting the upper surface of a geological model. First, duplicate triangular faces are removed from a first total array set constructed from the model file to obtain a second total array set. Then, triangular faces perpendicular to the horizontal direction are removed from the second total array set to obtain a third total array set. Finally, the upper surface of the model is extracted from the highest triangular face determined by the third total array set. This invention is particularly suitable for complex geological models with large amounts of data. Based on the sequential processing logic of this invention, each processing step saves computation time and improves processing efficiency. From the perspective of overall model extraction, each processing step is closely related and inseparable, resulting in more accurate extraction of the model's upper surface while significantly saving extraction time and improving model extraction efficiency.

[0086] Figure 2 This is a flowchart illustrating the process of constructing a first total array set provided by the present invention. The step of constructing a first total array set, composed of the vertices and triangular face numbers of all triangular faces, based on the triangular faces associated with each first identifier point in the model file, includes:

[0087] Traverse each first marker point in the model file to determine all triangular faces;

[0088] Take the three vertices corresponding to each triangular face as the first constituent element;

[0089] Each triangular face is numbered sequentially, and the corresponding serial number of the numbered triangular face is used as the second component element;

[0090] The first total array set is determined based on the first and second constituent elements corresponding to each triangular face.

[0091] In step 1011, each first identifier point can be associated with two, three, or even more triangular faces. For example, based on one first identifier point in the model file, three triangular faces can be determined, and based on another first identifier point in the model file, four triangular faces can be determined. The process is repeated for each first identifier point in the model file until all triangular faces are determined.

[0092] In step 1012, the purpose of this step is to determine the first total array set, which is determined by each triangle face as a unit. Specifically, the three vertices corresponding to each triangle face are determined. The vertices can be represented by three-dimensional coordinates. Accordingly, the first component can be represented as the coordinate information of the three vertices of one of the triangle faces.

[0093] In step 1013, according to step 1012, the present invention determines the coordinate information of the three vertices corresponding to each triangular face, and then numbers all the triangular faces so that each triangular face has a corresponding serial number and the coordinate information of the three vertices.

[0094] In step 1014, the first total array set is the total set of the first and second components corresponding to each triangle face. The determination of the first total array set is to represent all triangle faces in the model by using the form of an array set, and to achieve full coverage of all triangle faces. Although it contains duplicate triangle faces, in the subsequent processing, the first total array set will be gradually deduplicated and vertical triangle faces will be removed, and finally, the representation data of the array set containing only the upper surface of the model will be formed. This invention converts complex and large-scale model files into array sets. After deduplication, screening and filtering of the triangle faces in the array set, the array set used to represent the upper surface of the model is determined, and then the upper surface of the model is constructed based on the final array set.

[0095] Figure 3 This is a flowchart illustrating the process of determining the second total array set provided by the present invention. The step of traversing all triangles in the first total array set according to the triangle face index until all array sets to be removed are eliminated, in order to determine the second total array set, includes:

[0096] Determine the first, second, and third vertices corresponding to the three vertices of any triangle face;

[0097] Determine the first set of arrays associated with the first vertex, determine the second set of arrays associated with the second vertex, and determine the third set of arrays associated with the third vertex;

[0098] The intersection of the first array set, the second data set, and the third array set is determined as the array set to be removed;

[0099] Remove the set of arrays to be removed corresponding to the triangular face from the first total array set;

[0100] Based on the triangular face index, traverse all triangular faces until all array sets to be removed are determined.

[0101] Remove all array sets to be removed from the first total array set to determine the second total array set.

[0102] In step 1021, any triangular face in the first total array set has three vertices that make up the triangular face, that is, the first vertex, the second vertex and the third vertex corresponding to the three vertices of any triangular face are determined. In such an embodiment, the first vertex, the second vertex and the third vertex are all marker points, that is, they can be represented by coordinate information in a three-dimensional coordinate system.

[0103] In step 1022, the first array set associated with the first vertex is determined, the second array set associated with the second vertex is determined, and the third array set associated with the third vertex is determined. Since the face information corresponding to each marker point can be directly determined based on the file structure or data content of the model file, and the first array set can optionally be the face information corresponding to the marker point, the first array set associated with the first vertex, the second array set associated with the second vertex, and the third array set associated with the third vertex can be determined based on the marker points in the model file.

[0104] In step 1023, the intersection of the first array set, the second data set, and the third array set is determined as the array set to be eliminated. The first array set is the set of triangles associated with the first vertex, the second array set is the set of triangles associated with the second vertex, and the third array set is the set of triangles associated with the third vertex. That is, the intersection of the three is the set of duplicate triangles, which is the array set to be eliminated.

[0105] In step 1024, the array set to be removed corresponding to the triangle face is removed from the first total array set. This step can remove the array set to be removed corresponding to the triangle face in step 1021 from the first total array set. However, there is more than one triangle face in the first total array set, so in subsequent steps, each array set to be removed corresponding to all triangle faces will be removed.

[0106] In step 1025, all triangles are traversed according to their triangular face indices until all sets of triangles to be removed are determined. In step 1023, the set of triangles to be removed is determined for any triangle in the first total set of triangles. To determine all sets of triangles to be removed, the triangles can be traversed sequentially according to their triangular face indices, for example, starting from number 1, starting with triangle 2, then triangle 3, then triangle 4, and so on, until all triangles are traversed, thus determining all sets of triangles to be removed.

[0107] In step 1026, all array sets to be removed are eliminated from the first total array set to determine the second total array set. It should be understood that steps 1021 to 1024 provide a technical solution for eliminating the array set to be removed corresponding to any triangular face from the first total array set, while steps 1025 to 1026 provide a technical solution for eliminating all array sets to be removed from the first total array set to determine the second total array set. According to steps 1021 to 1026, duplicate triangular faces are eliminated from the first total array set, and the second total array set is used to represent the model file with the duplicate triangular faces removed.

[0108] Those skilled in the art will understand that, in an optional embodiment, by employing the technical solutions described in steps 1021 to 1026, it is possible to process one million triangular face data in just 700 milliseconds, which is faster and more time-saving than the prior art.

[0109] Figure 4 This is a flowchart illustrating the process of determining the third total array set provided by the present invention. The step of determining the third total array set after deleting the array set to be deleted from the second total array set includes:

[0110] Determine the dot product of the normal vector of each array set in the second total array set with the perpendicular vector in the three-dimensional coordinate system;

[0111] The set of arrays whose dot product values ​​are less than a preset value is identified as the set of arrays to be deleted.

[0112] The array set to be deleted is removed from the second total array set to determine the third total array set.

[0113] In step 1031, the second total array set includes multiple array sets, each array set including the three vertices corresponding to the triangle face and the index corresponding to the triangle face. Those skilled in the art will understand that, based on the basic information stored in the model file, the normal vector of each triangle face can be determined, and then the dot product value of the normal vector of each array set in the second total array set and the vertical direction vector in the three-dimensional coordinates can be determined.

[0114] In step 1032, the preset value is 0. Optionally, it can also be 0.1, 0.01, or 0.001, that is, the array set with a dot product value less than 0.01 is determined as the array set to be deleted. Optionally, the array set with a dot product value of 0 can also be determined as the array set to be deleted.

[0115] In step 1033, the present invention determines all array sets whose dot product values ​​are less than a preset value based on the dot product value of the normal vector of each array set and the vertical direction vector in the three-dimensional coordinates, and determines them as array sets to be deleted. The array sets to be deleted are then deleted from the second total array set to determine the third total array set, and then the triangular faces perpendicular to the horizontal direction between the upper and lower bases in the model are deleted.

[0116] Figure 5 This is the second flowchart of the geological model-based upper surface extraction method provided by the present invention. Before traversing all the highest triangular faces and extracting each retained triangular face from all the highest triangular faces to construct the upper surface of the model, the method includes:

[0117] Based on the third total array set, determine all third identifier points related to the third total array set;

[0118] Based on the line segments associated with each third identifier point, construct an initial set of line segments, which consists of the endpoints of all line segments.

[0119] The initial line segment set is updated based on all line segments in the third total data set, and the updated line segment set is determined such that the updated line segment set contains all the line segments.

[0120] In step 201, the third total array set is the total array set determined after the first total array set is deduplicated by removing vertical triangles from the model. Based on the three vertices of the triangles in all arrays of the third total array set, all third identifier points related to the third total array set are determined.

[0121] In step 202, an initial set of line segments is constructed based on the line segments associated with each third identifier point, with the endpoints of all line segments as the constituent elements. Those skilled in the art will understand that each line segment consists of two third identifier points, and each third identifier point can be a component of multiple line segments. Therefore, the constituent elements of the initial set of line segments are the two endpoints of each line segment.

[0122] In step 203, each triangular face consists of three vertices, and every two points can form a line segment. Therefore, each triangular face will have three points and three lines. The present invention aims to determine an updated set of line segments to calculate the subsequent number of line segments based on this updated set. Therefore, the updated set of line segments needs to filter out duplicate line segments. For example, if there is a first line segment and a second line segment, where the indices of the two points constituting the first line segment are (10, 11) and the indices of the two points constituting the second line segment are (11, 10), and the first line segment exists in the updated set of line segments, the second line segment will not participate in subsequent calculations.

[0123] Figure 6 This is the third flowchart of the geological model-based upper surface extraction method provided by the present invention. After determining all third marker points related to the third total array set, it further includes:

[0124] The highest marker point is determined based on the coordinate information of the third marker point;

[0125] Iterate through all the highest marker points, and determine the highest triangle corresponding to each highest marker point from the third total array set to obtain all the highest triangles.

[0126] In step 301, in such an embodiment, it is assumed that there are the following third marker points: (1, 2, 3), (2, 9, 10), (8, 2, 6), (7, 8, 2), (2, 3, 10), (10, 1, 3), (5, 4, 9). Then, the coordinate information of the third marker point is determined according to the set coordinate in the Z-axis to determine whether it is the highest marker point. In this invention, the third marker point with a Z-axis coordinate value of 10 can be defined as the highest marker point. Alternatively, the highest point can be determined by comparing the Z-axis coordinate values ​​of all marker points. In this case, the third marker points (2, 9, 10) and (2, 3, 10) are the highest marker points. In other embodiments, the third marker point with a Z-axis coordinate value greater than 8 can also be defined as the highest marker point. In this case, the third marker points (2, 9, 10), (2, 3, 10), and (5, 4, 9) are the highest marker points.

[0127] In step 302, since the model has been hollowed out in steps 101 to 103, the resulting model is an array set that only includes the upper and lower surfaces. Based on each highest marker point, one or more corresponding highest triangles can be determined. By traversing all the highest marker points, all the highest triangles corresponding to each highest marker point can be determined from the third total array set, thereby obtaining all the highest triangles.

[0128] Figure 7 This is a schematic diagram of the process for constructing the upper surface of a model provided by the present invention. The step of traversing all the highest triangles and extracting each retained triangle from all the highest triangles to construct the upper surface of the model includes:

[0129] Based on the third total data set and the updated line segment set, if the number of line segments corresponding to any second identifier point is the same as the number of triangles corresponding to the second identifier point, the highest triangle corresponding to the second identifier point is determined to be a retained triangle.

[0130] Iterate through all the highest triangles until all the remaining triangles are determined;

[0131] Extract all retained triangles and construct the upper surface of the model based on all retained triangles.

[0132] In step 3021, the highest triangle obtained in step 302 is not the final component used to represent the upper surface of the model. It also includes incomplete triangles. Each triangle consists of three vertices, and every two points can form a line segment. Therefore, each triangle will have three points and three lines. In fact, a complete triangle should have the condition that the number of line segments corresponding to its three second marker points is the same as the number of triangles corresponding to the second marker points. Only when the number of line segments corresponding to each second marker point is the same as the number of triangles corresponding to the second marker point is the highest triangle corresponding to the second marker point determined as the retained triangle.

[0133] In step 3022, all the highest triangles are traversed until all the retained triangles are determined. All the highest triangles are traversed according to the method in step 3021, and each second marker point in each highest triangle is judged. If the number of line segments corresponding to the second marker point is different from the number of triangles corresponding to the second marker point, no processing is done. If the number of line segments corresponding to the second marker point is the same as the number of triangles corresponding to the second marker point, it is marked. If all three second marker points corresponding to any highest triangle are marked, the highest triangle is determined to be a retained triangle.

[0134] In step 3023, all retained triangles are extracted, and the upper surface of the model is constructed based on all retained triangles. In this invention, the model is generated based on all retained triangles and the corresponding marker points, and the upper surface of the model is constructed.

[0135] Those skilled in the art will understand that, in an optional embodiment, by employing the technical solutions described in steps 3021 to 3023, the upper surface of a model with one million triangular face data can be obtained in just 10 seconds, which is faster and more time-saving than the prior art.

[0136] Figure 8 This is a schematic diagram of the structure of the geological model-based upper surface extraction device provided by the present invention. The present invention discloses a geological model-based upper surface extraction device, including a construction unit 1: used to construct a first total array set with the vertices and triangular face numbers of all triangular faces as components according to the triangular face associated with each first identifier point in the model file. The working principle of the construction unit 1 can be referred to the aforementioned step 101, and will not be repeated here.

[0137] The geological model-based upper surface extraction device also includes a processing unit 2: the user traverses all triangular faces in the first total array set according to the triangular face number until all array sets to be removed are eliminated, so as to determine the second total array set. The working principle of the processing unit 2 can be referred to the aforementioned step 102, and will not be repeated here.

[0138] The geological model-based upper surface extraction device further includes a determination unit 3: after deleting the array set to be deleted from the second total array set, a third total array set is determined. The working principle of the determination unit 3 can be referred to the aforementioned step 103, and will not be repeated here.

[0139] The geological model-based upper surface extraction device also includes an extraction unit 4: traversing all the highest triangular faces and extracting each retained triangular face from all the highest triangular faces to construct the upper surface of the model. The working principle of the extraction unit 4 can be referred to the aforementioned step 104, and will not be repeated here.

[0140] The set of arrays to be removed is determined by the intersection of the arrays of the faces associated with each vertex of the triangle.

[0141] The set of arrays to be deleted is determined based on the dot product of the normal vector and the perpendicular vector in the second total array set;

[0142] The retained triangle is the highest triangle when the number of line segments corresponding to the second marker point is the same as the number of triangles corresponding to the second marker point.

[0143] The second marker is all markers associated with any highest triangle face;

[0144] The highest triangular face is determined based on the coordinates of the corresponding identifier point in the third total array set.

[0145] This invention provides a method, apparatus, device, and medium for extracting the upper surface of a geological model. First, duplicate triangular faces are removed from a first total array set constructed from the model file to obtain a second total array set. Then, triangular faces perpendicular to the horizontal direction are removed from the second total array set to obtain a third total array set. Finally, the upper surface of the model is extracted from the highest triangular face determined by the third total array set. This invention is particularly suitable for complex geological models with large amounts of data. Based on the sequential processing logic of this invention, each processing step saves computation time and improves processing efficiency. From the perspective of overall model extraction, each processing step is closely related and inseparable, resulting in more accurate extraction of the model's upper surface while significantly saving extraction time and improving model extraction efficiency.

[0146] Figure 9 This is a schematic diagram of the structure of the electronic device provided by the present invention. For example... Figure 9 As shown, the electronic device may include: a processor 910, a communication interface 920, a memory 930, and a communication bus 940, wherein the processor 910, the communication interface 920, and the memory 930 communicate with each other through the communication bus 940. The processor 910 can call logical instructions in the memory 930 to execute a method for extracting the upper surface based on a geological model, including: constructing a first total array set composed of the vertices and triangular face numbers of all triangular faces based on the triangular faces associated with each first marker point in the model file; traversing all triangular faces in the first total array set according to the triangular face numbers until all triangular face sets to be removed are eliminated to determine a second total array set; after deleting the triangular face sets to be deleted from the second total array set, determining a third total array set; traversing all highest triangular faces and extracting each retained triangular face from all highest triangular faces to construct the upper surface of the model; the triangular face sets to be removed are determined based on the intersection of the array sets of faces associated with each vertex of the triangular face; the triangular face sets to be deleted are determined based on the dot product of the normal vector and the perpendicular direction vector in the second total array set; the retained triangular face is the highest triangular face when the number of line segments corresponding to the second marker point is the same as the number of triangular faces corresponding to the second marker point; the second marker point is all marker points associated with any highest triangular face; the highest triangular face is determined based on the coordinates of the marker points corresponding to the third total array set.

[0147] Furthermore, the logical instructions in the aforementioned memory 930 can be implemented as software functional units and, when sold or used as independent products, can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, essentially, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0148] On the other hand, the present invention also provides control software for running programs or instructions on a control terminal. When the program or instructions are executed by the control terminal, the above-described method for extracting the upper surface based on a geological model is performed. This method includes: constructing a first total array set with the vertices and triangular face numbers of all triangular faces as components, based on the triangular faces associated with each first identifier point in the model file; traversing all triangular faces in the first total array set according to the triangular face numbers until all triangular faces to be removed are eliminated, thereby determining a second total array set; after deleting the triangular faces to be removed from the second total array set, determining a third total array set; traversing all the highest triangular faces... The model's upper surface is constructed by extracting each retainable triangle from all the highest triangles. The set of triangles to be removed is determined by the intersection of the arrays of faces associated with each vertex of the triangle. The set of triangles to be deleted is determined by the dot product of the normal vector and the perpendicular vector in the second total array. The retainable triangle is the highest triangle when the number of line segments corresponding to the second marker point is the same as the number of triangles corresponding to the second marker point. The second marker point is all marker points associated with any highest triangle. The highest triangle is determined by the coordinates of the marker points corresponding to the third total array.

[0149] On the other hand, the present invention also provides a computer program product, which includes a computer program that can be stored on a non-transitory computer-readable storage medium. When the computer program is executed by a processor, the computer is able to execute a surface extraction method based on a geological model provided by the methods described above. This method includes: constructing a first total array set with the vertices and triangular face numbers of all triangular faces as components, based on the triangular faces associated with each first identifier point in the model file; traversing all triangular faces in the first total array set according to the triangular face numbers until all array sets to be removed are eliminated, thereby determining a second total array set; and deleting the array sets to be deleted from the second total array set. After merging, a third total array set is determined; all highest triangles are traversed, and each retained triangle is extracted from all highest triangles to construct the upper surface of the model; the array set to be eliminated is determined based on the intersection of the array sets of faces associated with each vertex of the triangle; the array set to be deleted is determined based on the dot product of the normal vector and the perpendicular direction vector in the second total array set; the retained triangle is the highest triangle when the number of line segments corresponding to the second marker point is the same as the number of triangles corresponding to the second marker point; the second marker point is all marker points associated with any highest triangle; the highest triangle is determined based on the coordinates of the marker points corresponding to the third total array set.

[0150] In another aspect, the present invention also provides a non-transitory computer-readable storage medium storing a computer program thereon, which, when executed by a processor, implements the above-described method for extracting the upper surface based on a geological model. This method includes: constructing a first total array set based on the triangular faces associated with each first identifier point in the model file, using the vertices and triangular face indices of all triangular faces as components; traversing all triangular faces in the first total array set according to the triangular face indices until all triangular faces to be removed are eliminated, thereby determining a second total array set; deleting the triangular faces to be removed from the second total array set, thereby determining a third total array set; traversing the... There is a highest triangle face. Each retained triangle face is extracted from all the highest triangle faces to construct the upper surface of the model. The set of triangle faces to be removed is determined by the intersection of the array sets of faces associated with each vertex of the triangle face. The set of triangle faces to be deleted is determined by the dot product of the normal vector and the perpendicular vector in the second total array set. The retained triangle face is the highest triangle face when the number of line segments corresponding to the second marker point is the same as the number of triangle faces corresponding to the second marker point. The second marker point is all marker points associated with any highest triangle face. The highest triangle face is determined by the coordinates of the marker points corresponding to the third total array set.

[0151] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate. 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. Those skilled in the art can understand and implement this without any creative effort.

[0152] Through the above description of the embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus necessary general-purpose hardware platforms, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solutions, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods described in the various embodiments or some parts of the embodiments.

[0153] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A method for extracting the upper surface based on a geological model, characterized in that, include: Based on the triangular face associated with each first identifier point in the model file, construct a first set of total arrays consisting of the vertices and triangular face indices of all triangular faces. Based on the triangular face index, traverse all triangular faces in the first total array set until all array sets to be removed are eliminated, in order to determine the second total array set; After deleting the array set to be deleted from the second total array set, determine the third total array set; Traverse all the highest triangles and extract each retained triangle from all the highest triangles to construct the upper surface of the model; The set of arrays to be removed is determined by the intersection of the arrays of the faces associated with each vertex of the triangle. The set of arrays to be deleted is determined based on the dot product of the normal vector and the perpendicular vector in the second total array set; The retained triangle is the highest triangle when the number of line segments corresponding to the second marker point is the same as the number of triangles corresponding to the second marker point. The second marker is all markers associated with any highest triangle face; The highest triangular face is determined based on the coordinates of the corresponding marker points in the third total array set; Before traversing all the highest triangles and extracting each retained triangle from all the highest triangles to construct the upper surface of the model, the process includes: Based on the third total array set, determine all third identifier points related to the third total array set; Based on the line segments associated with each third identifier point, construct an initial set of line segments, which consists of the endpoints of all line segments. The initial line segment set is updated based on all line segments in the third total array set, and the updated line segment set is determined such that the updated line segment set contains all the line segments.

2. The method for extracting the upper surface based on a geological model according to claim 1, characterized in that, The first set of arrays, constructed based on the triangles associated with each first identifier point in the model file, consists of the vertices and triangle indices of all triangles, including: Traverse each first marker point in the model file to determine all triangular faces; Take the three vertices corresponding to each triangular face as the first constituent element; Each triangular face is numbered sequentially, and the corresponding serial number of the numbered triangular face is used as the second component element; The first total array set is determined based on the first and second constituent elements corresponding to each triangular face.

3. The method for extracting the upper surface based on a geological model according to claim 1, characterized in that, The process of traversing all triangles in the first total array set according to the triangle face index, until all array sets to be removed are eliminated, to determine the second total array set includes: Determine the first, second, and third vertices corresponding to the three vertices of any triangle face; Determine the first set of arrays associated with the first vertex, determine the second set of arrays associated with the second vertex, and determine the third set of arrays associated with the third vertex; The intersection of the first set of arrays, the second set of arrays, and the third set of arrays is determined as the set of arrays to be removed; Remove the set of arrays to be removed corresponding to the triangular face from the first total array set; Based on the triangular face index, traverse all triangular faces until all array sets to be removed are determined. Remove all array sets to be removed from the first total array set to determine the second total array set.

4. The method for extracting the upper surface based on a geological model according to claim 1, characterized in that, After deleting the array set to be deleted from the second total array set, determining the third total array set includes: Determine the dot product of the normal vector of each array set in the second total array set with the perpendicular vector in the three-dimensional coordinate system; The set of arrays whose dot product values ​​are less than a preset value is identified as the set of arrays to be deleted. The array set to be deleted is removed from the second total array set to determine the third total array set.

5. The method for extracting the upper surface based on a geological model according to claim 1, characterized in that, After determining all third identifiers associated with the third total array set, the process further includes: The highest marker point is determined based on the coordinate information of the third marker point; Iterate through all the highest marker points, and determine the highest triangle corresponding to each highest marker point from the third total array set to obtain all the highest triangles.

6. The method for extracting the upper surface based on a geological model according to claim 5, characterized in that, The process of traversing all the highest triangles and extracting each retained triangle from all the highest triangles to construct the upper surface of the model includes: Based on the third total array set and the updated line segment set, if the number of line segments corresponding to any second identifier point is the same as the number of triangles corresponding to the second identifier point, the highest triangle corresponding to the second identifier point is determined to be a retained triangle. Iterate through all the highest triangles until all the remaining triangles are determined; Extract all retained triangles and construct the upper surface of the model based on all retained triangles.

7. A surface extraction device based on a geological model, characterized in that, include: Construction Unit: Used to construct a first set of arrays based on the triangles associated with each first identifier point in the model file, with the vertices and triangle numbers of all triangles as components; Processing unit: The user traverses all triangles in the first total array set according to the triangle face number until all array sets to be removed are eliminated, so as to determine the second total array set; Determining Unit: After deleting the array set to be deleted from the second total array set, determine the third total array set; Extraction Unit: Traverse all the highest triangles and extract each retained triangle from all the highest triangles to construct the upper surface of the model; The set of arrays to be removed is determined by the intersection of the arrays of the faces associated with each vertex of the triangle. The set of arrays to be deleted is determined based on the dot product of the normal vector and the perpendicular vector in the second total array set; The retained triangle is the highest triangle when the number of line segments corresponding to the second marker point is the same as the number of triangles corresponding to the second marker point. The second marker is all markers associated with any highest triangle face; The highest triangular face is determined based on the coordinates of the corresponding marker points in the third total array set; Before traversing all the highest triangles and extracting each retained triangle from them to construct the upper surface of the model, the extraction unit is also used for: Based on the third total array set, determine all third identifier points related to the third total array set; Based on the line segments associated with each third identifier point, construct an initial set of line segments, which consists of the endpoints of all line segments. The initial line segment set is updated based on all line segments in the third total array set, and the updated line segment set is determined such that the updated line segment set contains all the line segments.

8. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the upper surface extraction method based on a geological model as described in any one of claims 1 to 6.

9. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the geological model-based upper surface extraction method as described in any one of claims 1 to 6.