Shared point self-occlusion visualization method and system for corner mesh

By processing corner meshes using a self-hidden-elimination visualization method, the problem of the drawing dataset not being a single 3D volume dataset is solved, achieving efficient 3D visualization and dataset conversion, and supporting rapid research of 3D geological models.

CN117078879BActive Publication Date: 2026-11-24CHANGZHOU UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202311065953.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-08-23
Publication Date
2026-11-24
Estimated Expiration
2043-08-23

AI Technical Summary

Technical Problem

Existing technologies for corner mesh visualization suffer from the problem that the dataset being drawn is not a single 3D volume dataset, resulting in time-consuming computation and the inability to be directly converted to a universal format.

Method used

The self-hidden-spotting visualization method for generating corner meshes includes calculating the eight spatial coordinates of the cell mesh, performing deduplication, establishing a mapping relationship between coordinates and position numbers, constructing a geometric type array, and achieving self-hidden-spotting display.

Benefits of technology

It improves the utilization rate of equipment hardware resources, reduces computing time, and the generated dataset can be directly imported into VTK format, supporting the overall cutting and cross-sectional study of three-dimensional geological models.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117078879B_ABST
    Figure CN117078879B_ABST
Patent Text Reader

Abstract

This invention relates to the field of visualization analysis technology, and particularly to a method and system for self-hiding corner mesh visualization, including: outputting corner mesh data according to a corner mesh format; reading the corner mesh data, processing the input data, and generating multiple arrays of key corner mesh attributes; calculating eight spatial coordinates for all cell grids in the corner mesh and storing them in a coordinate array; removing duplicate spatial coordinates from the coordinate array to ensure that the spatial coordinates in the deduplicated coordinate array are unique; traversing the deduplicated coordinate array to obtain a dictionary data structure mapping multiple spatial coordinate values ​​to coordinate position numbers; constructing the correspondence between spatial coordinates and coordinate position numbers; and establishing a geometric type array for self-hiding display of the corner mesh. This invention solves the problems of long processing time and limitations in dataset conversion and mesh format conversion in existing methods.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of visualization analysis technology, and in particular to a visualization method and system for self-hidden disappearance of shared points in corner meshes. Background Technology

[0002] 3D modeling and visualization of oil reservoirs are crucial components of "digital oilfields" and form the basis for reservoir numerical simulation. Corner grids, as a type of structured grid, are irregular hexahedral grids. Each cell's position can be represented by i, j, and k, and the face connecting the top and bottom grid points vertically can be tilted. The coordinates of its eight vertices are stored independently, without interference, allowing for a better representation of the reservoir's internal characteristics. In current reservoir numerical simulation research, oil reservoirs are characterized by complex structural features and well-developed faults, and are mostly represented using corner grids.

[0003] VTK format, as a universal grid data format, is widely used in visualization. Most visualization software supports direct reading and writing of VTK format files, and also supports mutual conversion between VTK and other grid file formats. In the VTK format dataset structure, the use of shared points between cells in the topology allows for the self-hiding display of grid surfaces composed of identical grid points.

[0004] Currently, as the mesh size studied in numerical simulations increases, higher demands are placed on mesh visualization. When visualizing corner meshes, data volume preprocessing is required to reduce the number of faces the computer needs to draw, thereby improving display efficiency. However, most traditional preprocessing methods determine the overlap relationship between faces in the mesh elements and draw non-overlapping faces separately. While this preprocessing method improves display efficiency, it has the following shortcomings:

[0005] 1. The graphics obtained by traditional preprocessing methods are the result of stitching together three-dimensional polygons in the three-dimensional view. The dataset for drawing is not a single three-dimensional volume dataset in spatial form. When performing overall cutting of the three-dimensional geological model, viewing the profile, or other studies, it is necessary to recalculate, which is time-consuming.

[0006] 2. Although corner grids are a common grid format in reservoir engineering, they are not a common grid format in computer visualization. The drawing datasets obtained by traditional preprocessing methods cannot be directly converted into more universal grid formats, which has certain limitations. Summary of the Invention

[0007] To address the shortcomings of existing methods, the technical solution adopted in this invention is: a method for visualizing shared points of corner meshes by self-hiding, comprising the following steps:

[0008] Step 1: Output corner grid data according to the corner grid format;

[0009] Furthermore, the corner mesh data includes SPECGRID, COORD, and ZCORN. In SPECGRID, NX, NY, and NZ represent the number of meshes in the corner mesh data file in the X, Y, and Z directions, respectively. COORD represents the top and bottom coordinates of the vertical lines of the corner mesh, and ZCORN represents the depth values ​​of the eight vertices of the unit mesh.

[0010] Step 2: Read the corner grid data, process the read data, and generate multiple arrays of key corner grid attributes;

[0011] Step 3: Calculate the eight spatial coordinates of all cell grids in the corner grid and store them in a coordinate array;

[0012] Furthermore, the formulas for the eight spatial coordinates are as follows:

[0013]

[0014] In the formula, NX, NY, and NZ represent the total number of corner grids in the X, Y, and Z directions, respectively; i, j, and k represent the position numbers of the grids in the X, Y, and Z directions during the assignment of the XYZ array; ZCORN is the ZCORN array; CellIds and Pillars are (NX*NY*NZ)*8 two-dimensional arrays and (4*NX*NY)*2*3 three-dimensional arrays, respectively; pi is the number of the eight spatial coordinates of a single corner grid; index is the dimension number of the corner grid at position (i,j,k); ":" indicates all dimension data; S(index,pi,Pillar) is the error coefficient function.

[0015] Furthermore, the formula for S(index,pi,Pillar) is:

[0016]

[0017] In the formula, index and Pillar represent the dimension number of the corner grid at position (i,j,k) and the related data extracted from the Pillars array, respectively.

[0018] Step 4: Remove duplicate spatial coordinates from the coordinate array to ensure that the spatial coordinates in the resulting deduplicated coordinate array are unique.

[0019] Furthermore, step four specifically includes:

[0020] Step 41: Perform partitioning operation, selecting the coordinate array XYZ[0,0,:] as the reference and the boundary element v;

[0021] Step 42: Move the coordinates of elements smaller than v in the remaining dataset (excluding XYZ[0,0,:]) to the left of v, and move the coordinates of elements greater than or equal to v to the right of v.

[0022] Step 43: Repeat steps 41-42 for the obtained left and right partitions until all coordinates in the coordinate array are ordered.

[0023] Step 44: Traverse the sorted coordinate array. If the next coordinate is equal to the current coordinate, no operation is performed. If they are not equal, the current coordinate is put into a new array. When traversing to the last element of the coordinate array, the current element is directly put into a new array.

[0024] Step 5: Traverse the deduplication coordinate array, using the current spatial coordinate value as the key and the coordinate position number as the value. After the traversal is complete, a dictionary data structure with multiple one-to-one mapping relationships is obtained.

[0025] Step 6: Establish the correspondence between spatial coordinates and location numbers;

[0026] Furthermore, step six specifically includes:

[0027] Create a two-dimensional array, traverse the XYZ array, obtain its 8 spatial coordinates according to the fixed order of UnstructuredGrid grid [0,1,3,2,4,5,7,6] in VTK, and store the position numbers into the created two-dimensional array.

[0028] Step 7: Create an array of geometric types to display the self-hiding effect of the corner mesh.

[0029] The beneficial effects of this invention are:

[0030] 1. In the 3D visualization of corner grids, a large amount of irrelevant data is eliminated, and the self-hiding display of grid surfaces with the same grid points is achieved, which reduces the hardware resource consumption of the device and improves the display efficiency.

[0031] 2. The generated drawing dataset can be used as the original dataset in VTK format. When displaying it again, the data can be directly imported without further calculations.

[0032] 3. The generated drawing dataset is a single 3D volume dataset. When performing overall cutting of the 3D geological model, viewing cross-sections, and other studies, parallel computing operations can be performed on this dataset, which can significantly reduce computing time and completely preserve the internal details of the 3D geological model. Attached Figure Description

[0033] Figure 1 This is a flowchart of the self-hidden corner mesh sharing point visualization method of the present invention;

[0034] Figure 2 It refers to the topological order of the corner grid and the UnstructuredGrid grid in VTK;

[0035] Figure 3 This is a schematic diagram illustrating the effects of direct drawing of corner meshes versus self-hidden line drawing. Detailed Implementation

[0036] The present invention will be further described below with reference to the accompanying drawings and embodiments. The drawings are simplified schematic diagrams, which only illustrate the basic structure of the present invention in a schematic manner, and therefore only show the components related to the present invention.

[0037] like Figure 1 As shown, the self-hidden corner mesh sharing point visualization method includes the following steps:

[0038] Step 1: Using meshing software, output corner mesh data according to the corner mesh format;

[0039] The corner grid data describing the geological model is generated using the Petrel grid software. The corner grid data includes SPECGRID, COORD, and ZCORN. SPECGRID contains three parts: NX, NY, and NZ, which represent the number of grids in the X, Y, and Z directions, respectively. COORD represents the top and bottom coordinates of the vertical lines of the corner grid, and ZCORN represents the depth values ​​of the eight vertices of each cell.

[0040] Step 2: Read the corner mesh data, process the input data, and generate multiple arrays of key corner mesh attributes:

[0041] The corner grid data is read in as a string, and the string is split into multiple substrings using " / " as the delimiter; then the substrings are traversed.

[0042] If the first character of a substring is SPECGRID, then the values ​​of the 2nd, 3rd, and 4th characters of the string correspond to NX, NY, and NZ, respectively.

[0043] If the first character of a substring is COORD, then the second to the last character of the string represent the top and bottom coordinates of the vertical line. This data is stored as an array and denoted as the COORD array.

[0044] If the first character of a substring is ZCORN, then the second to the last character of the string represent the depth values ​​of the eight vertices of each cell grid. This value is stored as an array and denoted as the ZCORN array.

[0045] Step 3: Calculate the eight spatial coordinates of all cells in the corner grid and store them in a coordinate array:

[0046] Specifically, it includes:

[0047] 1. Create a two-dimensional array of size (NX*NY)*4, denoted as the pil_id array, and assign values ​​to it as follows:

[0048]

[0049] In the formula, NX and NY represent the total number of corner grids in the X and Y directions, respectively, and i and j represent the position numbers of the grids in the X and Y directions during the assignment of the pil_id array.

[0050] 2. Create a two-dimensional array of size (NX*NY*NZ)*8, denoted as the CellIds array, and assign values ​​to it as follows:

[0051]

[0052] In the formula, NX, NY, and NZ represent the total number of corner grids in the X, Y, and Z directions, respectively; i, j, and k represent the position numbers of the grids in the X, Y, and Z directions during the assignment of the CellIds array; and m represents the dimension number of CellIds.

[0053] 3. Create a three-dimensional array of size (4*NX*NY)*2*3, denoted as the Pillars array. The assignment process is as follows:

[0054]

[0055] In the formula, NX and NY represent the total number of corner meshes in the X and Y directions, respectively; i and j represent the position numbers of the meshes in the X and Y directions during the assignment of the Pillars array, respectively; COORD is the COORD array, which is an array generated when reading the corner mesh file; w represents the array position offset during the assignment of the Pillars array; and s and t are the index numbers.

[0056] 4. Create a 3D array of size (NX*NY*NZ)*8*3, denoted as the XYZ array, which is the coordinate array, to store the eight spatial coordinates of all cell grids in the corner grid. The assignment process is as follows:

[0057]

[0058] In the formula, NX, NY, and NZ represent the total number of corner grids in the X, Y, and Z directions, respectively; i, j, and k represent the position numbers of the grids in the X, Y, and Z directions during the assignment of the XYZ arrays; ZCORN is the ZCORN array, which is generated when reading the corner grid file; CellIds and Pillars are the arrays generated in formulas (2) and (3), respectively; index is the dimension number of the corner grid at position (i, j, k); pi represents the number of the eight spatial coordinates of a single corner grid; pi%4 represents the remainder obtained by dividing pi by 4; ":" represents all the data in that dimension; S(index, pi, Pillar) represents the error coefficient function; the function S(index, pi, Pillar) is defined as:

[0059]

[0060] In the formula, index and Pillar are the dimension number of the corner grid at position (i,j,k) and the related data extracted from the Pillars array, respectively.

[0061] Step 4: Remove duplicate spatial coordinates from the coordinate array to ensure that the spatial coordinates in the resulting deduplicated coordinate array are unique.

[0062] Step 41: Perform partitioning operation, selecting the coordinate array XYZ[0,0,:] as the reference and the boundary element v;

[0063] Step 42: Move the coordinates of elements smaller than v in the remaining data set to the left of v, and move the coordinates of elements greater than or equal to v to the right of v.

[0064] Step 43: Repeat steps 41-42 for the obtained left and right partitions until all coordinates in the coordinate array are ordered.

[0065] Step 44: Traverse the sorted coordinate array. If the next coordinate is equal to the current coordinate, no operation is performed. If they are not equal, the current coordinate is put into a new array. When traversing to the last element of the coordinate array, the current element is directly put into the new array. The new array obtained at this time does not contain duplicate coordinates. This new array is called the deduplicated coordinate array.

[0066] For example: Select any two points p in the XYZ array a (x a ,y a ,z a ), p b (x b ,y b ,z b The relationship between the sizes of two points is defined as follows:

[0067] If x a >x b Then p a >p b ;

[0068] If x a =x b ,y a >y b Then p a >p b ;

[0069] If x a =x b ,y a =y b ,z a >z b Then p a >p b ;

[0070] If x a =x b ,y a =y b ,z a =z b Then p a =p b .

[0071] Step 5: Traverse the deduplication coordinate array, using the current spatial coordinate value as the key and the position number of the current coordinate as the value. After the traversal is complete, a dictionary data structure with multiple one-to-one mapping relationships is obtained.

[0072] Construct a dictionary data structure for key-value mapping relationships. The relationship between key and value is a one-to-one mapping relationship, and the data type is dictionary. The key is the value of a single spatial coordinate, and the value is the mapping data, which is the sequential number of the single spatial coordinate in the deduplication coordinate array.

[0073] Step 6: Establish the correspondence between spatial coordinates and location numbers;

[0074] Create a 2D array of size (NX*NY*NZ)*8. Iterate through the XYZ array, obtaining its 8 spatial coordinates according to the fixed order of the UnstructuredGrid grid [0,1,3,2,4,5,7,6] in VTK, and store them in the 2D array (NX*NY*NZ)*8. The topological order of the corner grid and the UnstructuredGrid grid [0,1,3,2,4,5,7] in VTK is as follows: Figure 2As shown; then, the location number is obtained through the dictionary data structure of the key-value mapping relationship obtained in step five, and the location number is stored in the created two-dimensional array. After the traversal is completed, the two-dimensional data is recorded as the coordinate position array.

[0075] Step 7: Create an array of geometric types to display the self-hidden corner mesh visualization effect;

[0076] Describing the corner grid using the UnstructuredGrid grid in VTK requires a total of three data points:

[0077] 1. Spatial point data composed of three-dimensional coordinate points;

[0078] 2. The linear Cell type defined in VTK;

[0079] 3. Vertex list, which is the topological order corresponding to the dataset in 1.

[0080] Create a one-dimensional array of size NX*NY*NZ, assigning all values ​​to 12, where 12 represents the Hexahedron type; the one-dimensional array is a geometry type array; in the VTK format, the corner mesh is described using the UnstructuredGrid mesh in VTK, and the keyword code for this dataset is 12; the coordinate position array, the deduplicated coordinate array, and the geometry type array constitute the source data in the VTK format, enabling self-hidden corner mesh visualization. The direct drawing effect and the self-hidden corner mesh drawing effect are shown below. Figure 3 As shown.

[0081] Based on the above-described preferred embodiments of the present invention, and through the foregoing description, those skilled in the art can make various changes and modifications without departing from the inventive concept. The technical scope of this invention is not limited to the contents of the specification, but must be determined according to the scope of the claims.

Claims

1. A visualization method for self-hidden disappearance of shared points in corner meshes, characterized in that, Includes the following steps: Step 1: Output corner grid data according to the corner grid format; Corner grid data includes SPECGRID, COORD, and ZCORN. In SPECGRID... NX , NY and NZ These represent the number of grids in the X, Y, and Z directions of the corner grid data file, respectively; COORD represents the top and bottom coordinates of the vertical lines of the corner grid; and ZCORN represents the depth values ​​of the 8 vertices of the cell grid. Step 2: Read the corner grid data, process the read data, and generate multiple arrays of key corner grid attributes; Step 3: Calculate the eight spatial coordinates of all cell grids in the corner grid and store them in a coordinate array; The formula for the eight spatial coordinates is: (4) In the formula, NX , NY , NZ These represent the total number of corner meshes in the X, Y, and Z directions, respectively. i , j , k They are respectively XYZ During array assignment, the grid's position number in the X, Y, and Z directions is used, and ZCORN is the ZCORN array; and They are respectively Two-dimensional arrays and A three-dimensional array, The numbering of the eight spatial coordinates of a single corner point grid. index The position is ( i , j , k The dimension number of the corner grid; ":" indicates all data in the dimension; It is a function of error coefficients; The formula is: (5) In the formula, index , Pillar These represent the dimension number of the corner grid at position (i,j,k) and the related data extracted from the Pillars array, respectively. Step 4: Remove duplicate spatial coordinates from the coordinate array to ensure that the spatial coordinates in the resulting deduplicated coordinate array are unique. Step 5: Traverse the deduplicated coordinate array to obtain a dictionary data structure that maps multiple spatial coordinate values ​​to coordinate position numbers; Step 6: Establish the correspondence between spatial coordinates and coordinate position numbers; Step 7: Create a geometry type array and perform self-hiding display of corner mesh.

2. The method for visualizing shared points of corner meshes by self-hidden disappearance according to claim 1, characterized in that, Step four specifically includes: Step 41: Perform partitioning operation, selecting the coordinate array XYZ[0,0,:] as the reference and the boundary element v; Step 42: Move the coordinates of elements less than v in the remaining data set to the left of v, and move the coordinates of elements greater than or equal to v to the right of v. Step 43: Repeat steps 41-42 for the obtained left and right partitions until all coordinates in the coordinate array are ordered. Step 44: Traverse the sorted coordinate array. If the next coordinate is equal to the current coordinate, no operation is performed. If they are not equal, the current coordinate is put into a new array. When traversing to the last element of the coordinate array, the current element is directly put into a new array.

3. The method for visualizing shared points of corner meshes by self-hidden disappearance according to claim 1, characterized in that, Step six specifically includes: Create a two-dimensional array and iterate through it. XYZ Array, according to VTK for UnstructuredGrid grid The corresponding 8 spatial coordinates are obtained in a fixed order, and the position numbers are stored in the created two-dimensional array.

4. A visualization system for self-hidden corner removal of shared points in corner meshes, characterized in that, include: Memory is used to store instructions that can be executed by the processor; A processor for executing instructions to implement the shared-point self-hiding visualization method for corner meshes as described in any one of claims 1-3.

5. A computer-readable medium storing computer program code, characterized in that, The computer program code, when executed by a processor, implements the shared point self-hiding visualization method for corner meshes as described in any one of claims 1-3.

Citation Information

Patent Citations

  • Real-time segmentation and three-dimensional visualization method for angular point grid geologic model

    CN115908733A

  • Shale reservoir fracturing complex fracture numerical discretization method and device

    CN116335647A