Visual processing method and device of edge data, computer equipment and storage medium
By triangulating the equipment data of power equipment and building the Vino graph, and edge filtering of the three-dimensional grid model is solved, the problem of poor edge data visualization effect in the three-dimensional grid model in the existing technology is solved, a more concise and coherent three-dimensional model is achieved, and the edge visualization effect is improved.
Patent Information
- Application Number
- CN202411742091.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-29
- Publication Date
- 2025-03-14
- Estimated Expiration
- 2044-11-29
AI Technical Summary
The prior art is difficult to realize efficient visualization of edge data in a three-dimensional mesh model, resulting in poor visualization of edge data in the mesh.
By triangulating the equipment data of power equipment, a Vino diagram is constructed, and the three-dimensional grid model is edge filtered, redundant edges are identified and eliminated, and the target three-dimensional grid model is obtained. Then, based on the coordinate data of points on the edge of the target three-dimensional grid model, collision processing and visualization simulation are performed to improve the visual effect of the edge.
Through edge filtering, the three-dimensional model is simplified, making it more concise and coherent, improving the consistency between the target three-dimensional model and the simulation model of power equipment, thereby improving the visualization effect of edges.
Smart Images

Figure CN119625220A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of digital twin technology, and in particular to a method, apparatus, computer device, storage medium and computer program product for visualizing edge data. Background Art
[0002] At present, the technical route of digital twin of power equipment mainly adopts multi-physics field rapid simulation and equipment external sensor data interaction to realize virtual perception of internal status information of power equipment. For production and operation personnel, after obtaining the multi-physics field simulation results of the internal status of the equipment through multi-physics field rapid calculation, the results need to be presented in real time and accurately in the front-end software.
[0003] The existing technology mainly visualizes the overall data of mesh surfaces and mesh volumes, but it is difficult to realize the visualization processing of geometric edges in the mesh volume or along a certain path, resulting in poor visualization effect of edge data in the mesh volume. Summary of the invention
[0004] Based on this, it is necessary to provide a method, device, computer equipment, computer-readable storage medium and computer program product for edge data visualization of a three-dimensional grid model in order to solve the above technical problems.
[0005] In a first aspect, the present application provides a method for visualizing edge data. The method comprises:
[0006] Performing triangulation processing on the equipment data of the electric equipment to obtain a triangulated network of the electric equipment;
[0007] Constructing a Voronoi diagram of the electric power equipment according to the triangles in the triangulated network;
[0008] Performing edge filtering on the three-dimensional grid model obtained based on the Voronoi diagram to obtain a target three-dimensional grid model of the electric power equipment;
[0009] According to the coordinate data of the points on the edge of the target three-dimensional grid model, a visual simulation result of the edge is obtained.
[0010] In one embodiment, edge filtering is performed on the three-dimensional grid model obtained based on the Voronoi diagram to obtain a target three-dimensional grid model of the power equipment, including:
[0011] Merging the intersections of the approximate straight lines in the three-dimensional mesh model obtained based on the Voronoi diagram to obtain a merged three-dimensional mesh model; the approximate straight lines represent non-straight edges in the three-dimensional mesh model that are composed of multiple line segments and are approximately straight.
[0012] Reorganizing the point-line structure in the merged three-dimensional mesh model to obtain a reorganized three-dimensional mesh model;
[0013] Merging the intersections of arcs in the reorganized three-dimensional mesh model to obtain a re-merged three-dimensional mesh model; the arcs represent non-straight edges in the three-dimensional mesh model that are not approximately straight and are composed of multiple line segments;
[0014] The re-merged three-dimensional grid model is reorganized again to obtain a target three-dimensional grid model of the electric power equipment.
[0015] In one embodiment, obtaining a visualization simulation result of an edge according to coordinate data of a point on the edge of a target three-dimensional mesh model includes:
[0016] A ray is emitted from the coordinate data of a point on the edge of the target three-dimensional grid model, the ray is used to detect the simulation model that is collided with, and obtain the coordinates of the collision point in the simulation model; the simulation model represents the collision body of the power equipment in the virtual engine; the points on the edge include the first vertex, the middle point and the last vertex;
[0017] Converting the coordinates of the collision point into local coordinates in a volume rendering model of the target three-dimensional mesh model;
[0018] According to the local coordinates, obtaining simulation data of the edge of the target three-dimensional mesh model from which the ray is emitted;
[0019] The simulation data of the edge is visualized to obtain a visualized simulation result of the edge.
[0020] In one embodiment, before obtaining the visual simulation result of the edge according to the coordinate data of each vertex on the edge of the target three-dimensional mesh model, the method further includes:
[0021] For a straight edge in the target three-dimensional mesh model, obtaining coordinate data of a middle point of the straight edge according to coordinate data of a first vertex and a tail vertex of the straight edge;
[0022] For the curved edge in the target three-dimensional mesh model, the curved edge is divided into a plurality of straight line segments, and the coordinate data of the middle point of each straight line segment is obtained according to the coordinate data of the first vertex and the last vertex of each straight line segment.
[0023] In one embodiment, triangulation processing is performed on equipment data of the electric equipment to obtain a triangulated network of the electric equipment, including:
[0024] Based on the equipment data of the power equipment, a super triangle is constructed, and the super triangle is stored in a triangle linked list; the super triangle includes all the equipment data;
[0025] Inserting each of the device data into the triangle linked list in sequence to obtain an updated triangle linked list;
[0026] The optimized triangles obtained based on the local optimization criterion are inserted into the updated triangle linked list to obtain the triangulated network.
[0027] In one embodiment, obtaining the Voronoi diagram of the power equipment according to the triangles in the triangulated network includes:
[0028] Determine the circumscribed circle of each triangle in the triangulated network;
[0029] The centers of the circumscribed circles are connected to obtain a Voronoi diagram of the electric power equipment.
[0030] In a second aspect, the present application also provides a device for visualizing edge data. The device comprises:
[0031] A triangulation module, used for performing triangulation processing on the equipment data of the electric equipment to obtain a triangulated network of the electric equipment;
[0032] A Voronoi diagram generating module, used for constructing a Voronoi diagram of the electric power equipment according to the triangles in the triangulated network;
[0033] An edge filtering module, used for performing edge filtering on the three-dimensional grid model obtained based on the Voronoi diagram to obtain a target three-dimensional grid model of the electric power equipment;
[0034] The visualization processing module is used to obtain the simulation data of the power equipment on the edge according to the coordinate data of the points on the edge of the target three-dimensional grid model.
[0035] In a third aspect, the present application further provides a computer device. The computer device includes a memory and a processor, the memory stores a computer program, and the processor implements the following steps when executing the computer program:
[0036] Performing triangulation processing on the equipment data of the electric equipment to obtain a triangulated network of the electric equipment;
[0037] Constructing a Voronoi diagram of the electric power equipment according to the triangles in the triangulated network;
[0038] Performing edge filtering on the three-dimensional grid model obtained based on the Voronoi diagram to obtain a target three-dimensional grid model of the electric power equipment;
[0039] According to the coordinate data of the points on the edge of the target three-dimensional grid model, a visual simulation result of the edge is obtained.
[0040] In a fourth aspect, the present application further provides a computer-readable storage medium. The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the following steps are implemented:
[0041] Performing triangulation processing on the equipment data of the electric equipment to obtain a triangulated network of the electric equipment;
[0042] Constructing a Voronoi diagram of the electric power equipment according to the triangles in the triangulated network;
[0043] Performing edge filtering on the three-dimensional grid model obtained based on the Voronoi diagram to obtain a target three-dimensional grid model of the electric power equipment;
[0044] According to the coordinate data of the points on the edge of the target three-dimensional grid model, a visual simulation result of the edge is obtained.
[0045] In a fifth aspect, the present application further provides a computer program product. The computer program product includes a computer program, and when the computer program is executed by a processor, the following steps are implemented:
[0046] Performing triangulation processing on the equipment data of the electric equipment to obtain a triangulated network of the electric equipment;
[0047] Constructing a Voronoi diagram of the electric power equipment according to the triangles in the triangulated network;
[0048] Performing edge filtering on the three-dimensional grid model obtained based on the Voronoi diagram to obtain a target three-dimensional grid model of the electric power equipment;
[0049] According to the coordinate data of the points on the edge of the target three-dimensional grid model, a visual simulation result of the edge is obtained.
[0050] The above-mentioned edge data visualization processing method, device, computer equipment, storage medium and computer program product triangulate the equipment data of the power equipment to obtain the triangulated network of the power equipment; construct the Voronoi diagram of the power equipment based on the triangles in the triangulated network; perform edge filtering on the three-dimensional mesh model obtained based on the Voronoi diagram to obtain the target three-dimensional mesh model of the power equipment; obtain the visualization simulation result of the power equipment on the edge based on the coordinate data of the points on the edge of the target three-dimensional mesh model. This method is used to identify and eliminate redundant edges in the three-dimensional mesh model through edge filtering, so that the processed target three-dimensional model is more concise and coherent, and the consistency between the target three-dimensional model and the simulation model of the power equipment is improved, and then the visualization simulation result of the edge is obtained by collision processing the target three-dimensional model, thereby improving the visualization effect of the edge. BRIEF DESCRIPTION OF THE DRAWINGS
[0051] Figure 1 A diagram showing an application environment of a method for visualizing edge data in an embodiment;
[0052] Figure 2 A schematic diagram of a flow chart of a method for visualizing edge data in one embodiment;
[0053] Figure 3 is a schematic diagram of a process of generating a Voronoi diagram in one embodiment;
[0054] Figure 4 A schematic flow chart of steps for obtaining a target three-dimensional mesh model of an electric power device in one embodiment;
[0055] Figure 5 It is a schematic diagram of the principle of merging the intersection points of multiple approximate straight lines in a three-dimensional grid model obtained based on the Voronoi diagram in one embodiment;
[0056] Figure 6 A schematic diagram of renaming edges in a merged three-dimensional mesh model in one embodiment;
[0057] Figure 7 is a schematic diagram of a target three-dimensional mesh model obtained after edge filtering in one embodiment;
[0058] Figure 8 is a schematic diagram of splitting a curved edge into multiple straight line segments in one embodiment;
[0059] Fig. 9 Schematic diagram of inserting each device data into a triangle linked list in sequence in one embodiment; wherein (a) is a schematic diagram of inserting a new node P, (b) is a schematic diagram of determining how to connect P with other vertices, (c) is a schematic diagram of deleting edge AB, and (d) is a schematic diagram of forming a triangle;
[0060] Fig.10 A schematic diagram of a flow chart of a method for visualizing edge data in another embodiment;
[0061] Fig.11 A schematic diagram of a flow chart of a method for visualizing edge data in another embodiment;
[0062] Fig.12 is a structural block diagram of a device for visualizing edge data in an embodiment;
[0063] Fig.13 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION
[0064] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0065] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant regulations.
[0066] The edge data visualization processing method provided in the embodiment of the present application can be applied to Figure 1 In the application environment shown. Among them, the power device 101 communicates with the terminal 102 through the network. The data storage system can store the data that the terminal 102 needs to process. The data storage system can be integrated on the terminal / server 102, or it can be placed on the cloud or other network servers. The device data of the power device 101 is collected by the sensor and sent to the terminal 102; the terminal 102 performs triangulation processing on the device data of the power device 101 to obtain the triangulated network of the power device 101; according to the triangles in the triangulated network, the Voronoi diagram of the power device 101 is constructed; the three-dimensional mesh model obtained based on the Voronoi diagram is edge filtered to obtain the target three-dimensional mesh model of the power device 101; according to the coordinate data of the points on the edge of the target three-dimensional mesh model, the visual simulation result of the power device 101 on the edge is obtained. Among them, the power device 101 can be but not limited to various devices in the power field. The terminal 102 can be but not limited to various personal computers, laptops, smart phones, tablets, Internet of Things devices, portable wearable devices, etc.
[0067] In one embodiment, Figure 2As shown in the figure, a visualization method for edge data is provided. Figure 1 The terminal 102 in the example is used as an example to illustrate, and the following steps are included:
[0068] Step S201 , triangulating the equipment data of the power equipment to obtain a triangulated network of the power equipment.
[0069] Among them, triangulation refers to the process of dividing a plane or surface (such as equipment data of power equipment) into a series of triangles. Triangulation can simulate the surface of complex objects (such as power equipment).
[0070] A triangulated network is a set of adjacent and non-overlapping triangles that meet certain geometric and topological conditions.
[0071] Specifically, a sensor is installed on the power equipment side; the sensor collects the equipment data of the power equipment and sends the equipment data to the terminal. The terminal performs Delaunay triangulation on the equipment data of the power equipment to obtain a triangulated network of the power equipment.
[0072] Among them, Delaunay triangulation is a special method of triangulation based on point sets, which can maximize the minimum angle and avoid generating too narrow triangles. In MATLAB, you can use the delaunay or delaunayTriangulation function to perform Delaunay triangulation.
[0073] Step S202: constructing a Voronoi diagram of the power equipment based on the triangles in the triangulated network.
[0074] Among them, the Voronoi Diagram, also known as the Thiessen polygon, can also be called the Voronoi diagram. The Voronoi diagram is composed of continuous polygons composed of the perpendicular bisectors of the lines connecting two adjacent points.
[0075] Specifically, a Voronoi diagram of the electric power equipment is generated based on the centers of the circumscribed circles of the triangles in the triangulated network. Figure 3 This is a schematic diagram of the generation process of the Voronoi diagram. It can be understood that if there are several triangles around a central point, then the polygon centered on it will have several edges. This is because in the construction process of the Voronoi diagram, the center of the circumscribed circle of each triangle is a vertex in the Voronoi diagram, and the polygon formed by the centers of the circumscribed circles of all triangles adjacent to the point is the shape of the point in the Voronoi diagram. Therefore, there are as many Voronoi vertices as there are adjacent triangles, thus forming a polygon with as many edges.
[0076] Step S203, performing edge filtering processing on the three-dimensional grid model obtained based on the Voronoi diagram to obtain a target three-dimensional grid model of the power equipment.
[0077] Specifically, firstly, the vertices and edges of the Voronoi diagram are used to construct a VTU (used to represent unstructured grid data) model based on triangular faces, and the VTU model is used as a three-dimensional grid model of the power equipment. Then, the three-dimensional grid model is subjected to edge filtering, mainly to identify and remove redundant edges in the three-dimensional grid model, so that the processed target three-dimensional grid model is as close as possible to the simulation model of the power equipment. It can be understood that after eliminating some edges in the three-dimensional grid model, the vertices in the three-dimensional grid model will also be reduced.
[0078] Step S204, obtaining a visualization simulation result of the edge according to the coordinate data of the points on the edge of the target three-dimensional mesh model.
[0079] The visualized simulation result is a visualized form of simulation data for the power equipment, for example, the visualized simulation result may be a temperature curve of a temperature simulation value of the power equipment.
[0080] Specifically, a collision body is constructed in the virtual engine, and this collision body is a simulation model of the power equipment. The rays emitted by the coordinate data of the points on the edge of the target three-dimensional grid model collide with the simulation model, and then the simulation data of the power equipment is obtained according to the coordinates of the collision points in the simulation model, and then the simulation data is visualized to obtain the visualized simulation results of the edge. The visualized simulation results can also be displayed on the terminal, or sent to the terminal of the manager of the power equipment for display.
[0081] In the above-mentioned edge data visualization processing method, the equipment data of the power equipment is triangulated to obtain the triangulated network of the power equipment; the Voronoi diagram of the power equipment is constructed based on the triangles in the triangulated network; the three-dimensional mesh model obtained based on the Voronoi diagram is edge filtered to obtain the target three-dimensional mesh model of the power equipment; and the visualization simulation result of the power equipment on the edge is obtained based on the coordinate data of the points on the edge of the target three-dimensional mesh model. This method is used to identify and eliminate redundant edges in the three-dimensional mesh model through edge filtering, so that the processed target three-dimensional model is more concise and coherent, and the consistency between the target three-dimensional model and the simulation model of the power equipment is improved, and then the visualization simulation result of the edge is obtained by collision processing the target three-dimensional model, thereby improving the visualization effect of the edge.
[0082] In one embodiment, Figure 4 As shown, the above step S203 performs edge filtering on the three-dimensional grid model obtained based on the Voronoi diagram to obtain a target three-dimensional grid model of the power equipment, which specifically includes the following contents:
[0083] Step S401, merging the intersections of the approximate straight lines in the three-dimensional mesh model obtained based on the Voronoi diagram to obtain a merged three-dimensional mesh model; the approximate straight line represents a non-straight edge in the three-dimensional mesh model that is approximately a straight line.
[0084] Since there are too many edges in the three-dimensional mesh model based on the triangular face obtained based on the Voronoi diagram, in order to match the edges of the simulation model of the power equipment, it is also necessary to filter the edges in the three-dimensional mesh model. Specifically, the edges in the three-dimensional mesh model can be divided into two categories: straight edges and non-straight edges, among which the non-straight edges can be divided into arcs and approximate straight lines; wherein the approximate straight line consists of at least two line segments. The angle between two adjacent line segments is close to 180°, so that two or more line segments look similar to a straight line, but in fact they are not a straight line. In view of this, the approximate straight line can be set to the angle between the two adjacent line segments being greater than or equal to 170° and the angle between the two adjacent line segments being less than 180°, that is, if 180°≥the angle between the two adjacent line segments≥170°, the two adjacent line segments are set to an approximate straight line; then the two adjacent line segments are merged at their intersection, that is, the intersection of the two adjacent line segments is eliminated, so that the two adjacent line segments contained in the approximate straight line are merged into one edge. The method of merging two or more line segments included in an approximate straight line into one side is similar to the method of merging the two line segments into one side mentioned above, and both are merged at the intersection, so that the two or more line segments belonging to the approximate straight line are merged into one side.
[0085] It should be noted that in the present application, line segments and edges essentially mean the same thing. To facilitate distinction, the line segments that need to be merged in the three-dimensional mesh model can be called line segments, and the new line segments obtained after merging can be called edges.
[0086] Figure 5 The figure is a schematic diagram of the principle of merging the intersection points of multiple approximate straight lines in a three-dimensional mesh model obtained based on the Voronoi diagram. If the angle between the edge between vertex 1 and vertex 2 (which can be called line segment 1) and the edge between vertex 2 and vertex 3 (which can be called line segment 2) is greater than or equal to 170° and less than 180°, then the intersection point between line segment 1 and line segment 2 (i.e., vertex 2) can be eliminated, thereby merging the two edges of line segment 1 and line segment 2 into one edge (which can be called edge 1).
[0087] Step S402, reorganizing the point and line structures in the merged three-dimensional mesh model to obtain a reorganized three-dimensional mesh model.
[0088] After completing the merging process of the approximate straight lines, it is necessary to recalculate the point-line structure in order to accurately locate the simulation data of the edge in the subsequent process. Specifically, the line segments in the three-dimensional grid model obtained based on the Voronoi diagram are named LineSegment1 (or line segment 1), LineSegment2 (or line segment 2), LineSegment3 (or line segment 3), LineSegment4 (or line segment 4), etc.; at the same time, the label Edge is given to each line segment. In the process of merging the approximate straight lines, for all the line segments belonging to the approximate straight lines, the original label Edge of the line segment is deleted, and the combined label Edge of the edge obtained after the merging of these line segments is added. New names are also set for the edges, such as StraightEdge1 (or edge 1), StraightEdge2 (or edge 2), StraightEdge3 (or edge 3), StraightEdge4 (or edge 4), StraightEdge5 (or edge 5), etc., that is, the merged edges are renamed and labeled, and the labels and names of the merged line segments are cancelled. Figure 6 A schematic diagram of renaming edges in a merged 3D mesh model.
[0089] Step S403, merging the intersections of arcs in the reorganized three-dimensional mesh model to obtain a re-merged three-dimensional mesh model; the arcs represent non-straight edges in the three-dimensional mesh model that are composed of multiple line segments and are not approximately straight lines.
[0090] The arc is composed of at least two line segments. The angle between two adjacent line segments is smaller than the angle of the approximate straight line. For example, the angle between two adjacent line segments constituting the arc can be close to 170° but less than 170 degrees, so that two or more line segments appear to be approximate to the arc.
[0091] To address this, the arc can be set to an angle between two adjacent line segments greater than or equal to 120° and less than 170°, that is, if 170°≥the angle between two adjacent line segments≥120°, the two adjacent line segments are set to an arc; then the two adjacent line segments are merged at their intersection, that is, the intersection of the two adjacent line segments is eliminated, so that the two adjacent line segments included in the arc are merged into one edge. The method of merging more than two line segments included in the arc into one edge is similar to the above method of merging two line segments into one edge, and both are merged at the intersection, so that more than two line segments belonging to the arc are merged into one edge.
[0092] Step S404, reorganizing the merged three-dimensional mesh model again to obtain a target three-dimensional mesh model of the power equipment.
[0093] Specifically, during the arc merging process, for all line segments belonging to the arc, the original label Edge of the line segment is deleted, and the combined label Edge of the edges obtained after the line segments are merged is added. New names are also set for the edges, such as ArcEdge1, ArcEdge2, ArcEdge3, etc., that is, the merged edges are renamed and labeled, and the labels and names of the merged line segments are cancelled. Finally, the target three-dimensional mesh model of the power equipment is output. Figure 7 Schematic diagram of the target three-dimensional mesh model obtained after edge filtering.
[0094] In this embodiment, by merging the approximate straight lines and arcs in the three-dimensional mesh model obtained based on the Voronoi diagram, a large number of redundant line segments in the three-dimensional mesh model are effectively eliminated, so that the target three-dimensional mesh model obtained after edge filtering processing is more concise and coherent, and the consistency between the target three-dimensional model and the simulation model of the power equipment is greatly improved.
[0095] In one embodiment, the above step S204 obtains a visualization simulation result of the edge based on the coordinate data of the point on the edge of the target three-dimensional mesh model, and specifically includes the following contents: a ray is emitted from the coordinate data of the point on the edge of the target three-dimensional mesh model, and the ray is used to detect the simulation model that collides with it, and the coordinates of the collision point in the simulation model are obtained; the simulation model represents the collision body of the power equipment in the virtual engine; the points on the edge include the first vertex, the middle point and the tail vertex; the coordinates of the collision point are converted into local coordinates in the volume rendering model of the target three-dimensional mesh model; based on the local coordinates, the simulation data of the edge from which the ray is emitted in the target three-dimensional mesh model is obtained; the simulation data of the edge is visualized to obtain a visualization simulation result of the edge.
[0096] The collision point represents the point in the simulation model that collides with the ray.
[0097] The visualized simulation result may be a simulation curve generated based on the simulation data.
[0098] Specifically, in a virtual engine (such as Unreal Engine, UE engine for short), a ray is emitted from the coordinate data of a point on the edge of the target three-dimensional mesh model (such as the first vertex, the middle point or the tail vertex), and the ray is used to detect the simulation model that is collided with, and obtain the coordinate data of the point in the simulation model that is collided with by the ray, that is, obtain the coordinate data of the collision point. The terminal can also construct a volume rendering model based on the three-dimensional mesh model in advance; wherein the volume rendering model is used to project the three-dimensional data onto a two-dimensional image. The terminal converts the coordinate data of the collision point into local coordinates in the volume rendering model through matrix calculation; through the local coordinates, the simulation data of the edge from which the ray is emitted in the target three-dimensional mesh model is obtained, for example, based on the local coordinates and the triangular face data in the target three-dimensional mesh model, the proportion of the effect on each point on the edge from which the ray is emitted is calculated according to the coordinate position of the triangular face vertices in the target three-dimensional mesh model, that is, the centroid coordinates, so as to interpolate the simulation data (such as temperature) of each point on the edge, for example, through the interpolation of a piecewise polynomial (100 equally divided points), to ensure the smoothness and continuity of the simulation data of each point. Finally, the simulation data of the edge from which the ray is emitted is visualized to obtain the visualized simulation result of the edge, for example, a smooth temperature curve is generated based on the interpolated temperature.
[0099] In this embodiment, the coordinates of the collision point in the simulation model are converted into local coordinates in the volume rendering model of the target three-dimensional mesh model; then, based on the local coordinates, the simulation data of the edge emitting the ray in the target three-dimensional mesh model is obtained; and then the simulation data of the edge is visualized to obtain the visualized simulation result of the edge. While realizing the efficient acquisition of simulation data, the visualized simulation result can be further smoothed by interpolation, thereby improving the visualization effect of the visualized simulation result.
[0100] In one embodiment, in the above step S204, before obtaining the visual simulation result of the edge according to the coordinate data of the points on the edge of the target three-dimensional mesh model, it also includes: for the straight edge in the target three-dimensional mesh model, according to the coordinate data of the first vertex and the tail vertex of the straight edge, obtaining the coordinate data of the middle point of the straight edge; for the curved edge in the target three-dimensional mesh model, dividing the curved edge into multiple straight line segments, according to the coordinate data of the first vertex and the tail vertex of each straight line segment, obtaining the coordinate data of the middle point of each straight line segment.
[0101] The first vertex refers to the point at the beginning of the edge, and the last vertex refers to the point at the end of the edge.
[0102] The curved edge refers to the edge obtained by merging the edge through the edge filtering process in steps S401 to S404.
[0103] It should be noted that for the generated target three-dimensional mesh model, currently only the coordinate data of the first and last two vertices of each edge can be obtained. In order to improve the visualization effect of the edge, it is also necessary to obtain the coordinate data of the middle points on the edge to make the visualization simulation results smoother and the visualization effect better.
[0104] For the straight edge in the target 3D mesh model, the coordinate data of other intermediate points on the straight edge can be calculated based on the coordinate data of the first vertex and the coordinate data of the last vertex of the straight edge. For example, assuming that the coordinate data of the first vertex a of a straight edge is a (x1, y1, z1), and the coordinate data of the last vertex b is b (x2, y2, z2), and the straight edge contains a total of 100 points (including point a and point b), then the straight-line distance d between each point is:
[0105]
[0106] From point a to point b, the coordinate data of each intermediate point are:
[0107]
[0108]
[0109]
[0110] …
[0111] …
[0112] …
[0113]
[0114] Then the terminal obtains the coordinate data of all points on the edge of the straight line.
[0115] For the curved edges in the target three-dimensional mesh model, we can take advantage of the multi-segment triangle (that is, all curves are composed of straight lines) to divide the curved edges into multiple straight line segments, and then use the above method to calculate the coordinate data of the intermediate points of the straight line edges, and obtain the coordinate data of the intermediate points of each straight line segment according to the coordinate data of the first vertex and the last vertex of each straight line segment. For example, assuming that a curved edge is composed of 4 segments, each segment is assigned 25 points (that is, the curve includes 100 points in total, and the number of points of each segment = 100 / number of segments), and then obtain the coordinates of the intermediate points on the 4 segments by calculating the coordinate data of the intermediate points of the straight line edges. The schematic diagram of splitting the curved edge into multiple straight line segments is shown below. Figure 8 shown.
[0116] In this embodiment, the coordinate data of the first vertex and the last vertex of the straight line edge are used to calculate the coordinate data of each intermediate point of the straight line edge, thereby achieving effective acquisition of the coordinate data of each point on the edge of the target three-dimensional mesh model. The number of intermediate points can also be flexibly set according to the computing resources and visualization fluency requirements of the actual application scenario. In the visualization processing stage, the number of points on the edge can be further increased through interpolation processing, thereby further enhancing the visualization fluency and greatly improving the visualization effect of the edge of the target three-dimensional mesh model.
[0117] In one embodiment, the above step S201 triangulates the equipment data of the power equipment to obtain a triangulated network of the power equipment, which specifically includes the following contents: constructing a super triangle based on the equipment data of the power equipment, and storing the super triangle in a triangle linked list; the super triangle includes all the equipment data; inserting each equipment data into the triangle linked list in turn to obtain an updated triangle linked list; inserting the optimized triangle obtained based on the local optimization criterion into the updated triangle linked list to obtain a triangulated network.
[0118] In MATLAB, the steps to generate a triangulated network of equipment data for power equipment using Delaunay triangulation are as follows:
[0119] (1) Based on the equipment data of the power equipment, a super triangle is constructed. This super triangle contains all the equipment data. The super triangle is then stored in a triangle linked list. The triangle linked list can also be called a triangle adjacency list. In the triangle adjacency list, each node represents a triangle, and the edges between nodes represent the adjacency relationship between triangles.
[0120] (2) If Fig. 9 As shown, each device data is inserted into the triangle linked list in sequence, specifically including: (a) inserting a new node P: preparing to insert the device data (node P) into the triangle linked list; (b) deciding how to connect P with other vertices: finding the triangle whose circumscribed circle contains the inserted device data in the triangle linked list, which can be called the affected triangle of the device data; (c) deleting the side AB: deleting the common side of the affected triangle; (d) forming a triangle: connecting the inserted device data with all the vertices of the affected triangle, thus completing the insertion of a device data into the triangle linked list;
[0121] (3) Optimize the newly formed local triangle according to the optimization criteria to obtain the optimized triangle. Store the optimized triangle in the triangle linked list;
[0122] (4) Step (2) of this embodiment is executed repeatedly until all the equipment data are inserted, and finally the triangulated network of the power equipment is output.
[0123] In this embodiment, a Delaunay triangulation algorithm is used to generate a triangulated network based on the equipment data of the power equipment, so as to simulate the surface of the power equipment through triangles, thereby laying a foundation for constructing a target three-dimensional mesh model of the power equipment in subsequent steps.
[0124] In one embodiment, the above step S202 constructs the Voronoi diagram of the power equipment based on the triangles in the triangulated network, which specifically includes the following contents: determining the circumscribed circle of each triangle in the triangulated network; connecting the centers of each circumscribed circle to obtain the Voronoi diagram of the power equipment.
[0125] Specifically, each triangle in the triangulated network is traversed; the center and radius of the circumscribed circle of each triangle are calculated based on the coordinates of the three vertices of each triangle. The centers of each circumscribed circle are connected by smooth line segments, and finally the Voronoi diagram of the power equipment is obtained.
[0126] In this embodiment, by connecting the centers of the circumscribed circles of each triangle in the triangulated network, the Voronoi diagram of the power equipment is effectively obtained, providing reliable data support for obtaining the three-dimensional mesh model of the power equipment in the subsequent steps.
[0127] In one embodiment, Fig.10 As shown in Figure 2, another visualization method for edge data is provided. This method is applied to Figure 1 The terminal in is used as an example to illustrate, including the following steps:
[0128] Step S1001, triangulate the equipment data of the power equipment to obtain a triangulated network of the power equipment.
[0129] Step S1002: construct a Voronoi diagram of the power equipment based on the triangles in the triangulated network.
[0130] Step S1003, merging the intersection points of the approximate straight lines in the three-dimensional mesh model obtained based on the Voronoi diagram to obtain a merged three-dimensional mesh model; and reorganizing the point-line structure in the merged three-dimensional mesh model to obtain a reorganized three-dimensional mesh model.
[0131] Step S1004, merging the intersections of arcs in the reorganized three-dimensional mesh model to obtain a re-merged three-dimensional mesh model; reorganizing the re-merged three-dimensional mesh model again to obtain a target three-dimensional mesh model of the power equipment.
[0132] Step S1005, a ray is emitted from the coordinate data of a point on the edge of the target three-dimensional grid model, the ray is used to detect the simulation model that collides with it, and obtain the coordinates of the collision point in the simulation model; the simulation model represents the collision body of the power equipment in the virtual engine; the points on the edge include the first vertex, the middle point and the last vertex.
[0133] Step S1006, converting the coordinates of the collision point into local coordinates in the volume rendering model of the target three-dimensional mesh model; obtaining simulation data of the edge of the target three-dimensional mesh model from which the ray is emitted according to the local coordinates.
[0134] Step S1007 , performing visualization processing on the simulation data of the edge to obtain a visualization simulation result of the edge.
[0135] The above-mentioned edge data visualization processing method can achieve the following beneficial effects: through edge filtering processing, redundant edges in the three-dimensional grid model are identified and eliminated, so that the processed target three-dimensional model is more concise and coherent, and the consistency between the target three-dimensional model and the simulation model of the power equipment is improved. Then, the visual simulation results of the edges are obtained by collision processing of the target three-dimensional model, thereby improving the visualization effect of the edges.
[0136] In order to more clearly illustrate the edge data visualization processing method provided by the embodiment of the present disclosure, the above edge data visualization processing method is specifically described below with a specific embodiment. Fig.11 As shown in Figure 2, another edge data visualization method is provided, which can be applied to Figure 1 The terminal in the package includes the following contents:
[0137] In this embodiment, the Voronoi diagram is flexibly used to draw the model space points, and the reduction algorithm and UE rigid body collision technology are used to obtain the temperature value based on the detailed coordinate points of the model space points. The edges of the VTU model are merged to be consistent with the actual model through a filtering algorithm, and the coordinate values of each point on the edge are calculated based on the vertices of the edge, and then the temperature is obtained through the coordinate values. Compared with the existing mesh triangles, this technical aspect can obtain the simulation value of the model edge instead of the simulation value of the triangle. This technical solution realizes the flexible selection of the edge and the accurate acquisition of the simulation value of each point on the edge, and then outputs the simulation curve.
[0138] It should be understood that, although the various steps in the flowcharts involved in the above-mentioned embodiments are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps does not have a strict order restriction, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above-mentioned embodiments can include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the steps or stages in other steps.
[0139] Based on the same inventive concept, the embodiment of the present application also provides an edge data visualization processing device for implementing the edge data visualization processing method involved above. The implementation solution provided by the device to solve the problem is similar to the implementation solution recorded in the above method, so the specific limitations in the embodiments of one or more edge data visualization processing devices provided below can refer to the limitations of the edge data visualization processing method above, and will not be repeated here.
[0140] In one embodiment, Fig.12 As shown, a device 1200 for visualizing edge data is provided, comprising: a triangulation module 1201, a Voronoi diagram generation module 1202, an edge filtering module 1203 and a visualization processing module 1204, wherein:
[0141] The triangulation module 1201 is used to perform triangulation processing on the equipment data of the power equipment to obtain the triangulated network of the power equipment.
[0142] The Voronoi diagram generating module 1202 is used to construct a Voronoi diagram of the power equipment according to the triangles in the triangulated network.
[0143] The edge filtering module 1203 is used to perform edge filtering on the three-dimensional grid model obtained based on the Voronoi diagram to obtain a target three-dimensional grid model of the power equipment.
[0144] The visualization processing module 1204 is used to obtain simulation data of the power equipment on the edge according to the coordinate data of the points on the edge of the target three-dimensional grid model.
[0145] In one embodiment, the triangulation module 1201 is also used to merge the intersection points of approximate straight lines in the three-dimensional mesh model obtained based on the Voronoi diagram to obtain a merged three-dimensional mesh model; the approximate straight lines represent non-straight edges that are approximately straight lines and are composed of multiple line segments in the three-dimensional mesh model; the point-line structure in the merged three-dimensional mesh model is reorganized to obtain a reorganized three-dimensional mesh model; the intersection points of arcs in the reorganized three-dimensional mesh model are merged to obtain a re-merged three-dimensional mesh model; the arcs represent non-straight edges that are not approximately straight lines and are composed of multiple line segments in the three-dimensional mesh model; the re-merged three-dimensional mesh model is reorganized again to obtain a target three-dimensional mesh model of the power equipment.
[0146] In one embodiment, the visualization processing module 1204 is also used to emit a ray from the coordinate data of a point on the edge of the target three-dimensional mesh model, the ray is used to detect the simulation model that collides with it, and obtain the coordinates of the collision point in the simulation model; the simulation model represents the collision body of the power equipment in the virtual engine; the points on the edge include the first vertex, the middle point and the tail vertex; the coordinates of the collision point are converted into local coordinates in the volume rendering model of the target three-dimensional mesh model; according to the local coordinates, the simulation data of the edge from which the ray is emitted in the target three-dimensional mesh model is obtained; the simulation data of the edge is visualized to obtain a visualization simulation result of the edge.
[0147] In one embodiment, the edge data visualization processing device 1200 also includes a midpoint acquisition module, which is used to obtain the coordinate data of the midpoint of the straight edge in the target three-dimensional mesh model based on the coordinate data of the first vertex and the tail vertex of the straight edge; for the curved edge in the target three-dimensional mesh model, the curved edge is divided into multiple straight line segments, and the coordinate data of the midpoint of each straight line segment is obtained based on the coordinate data of the first vertex and the tail vertex of each straight line segment.
[0148] In one embodiment, the triangulation module 1201 is also used to construct a super triangle based on the equipment data of the power equipment, and store the super triangle in a triangle linked list; the super triangle includes all the equipment data; each equipment data is inserted into the triangle linked list in turn to obtain an updated triangle linked list; the optimized triangle obtained based on the local optimization criterion is inserted into the updated triangle linked list to obtain a triangular network.
[0149] In one embodiment, the Voronoi diagram generating module 1202 is further used to determine the circumscribed circle of each triangle in the triangulated network; connect the centers of the circumscribed circles to obtain the Voronoi diagram of the power equipment.
[0150] Each module in the above-mentioned edge data visualization processing device can be implemented in whole or in part by software, hardware, or a combination thereof. Each of the above-mentioned modules can be embedded in or independent of a processor in a computer device in the form of hardware, or can be stored in a memory in a computer device in the form of software, so that the processor can call and execute operations corresponding to each of the above modules.
[0151] In one embodiment, a computer device is provided. The computer device may be a terminal, and its internal structure diagram may be as follows: Fig.13As shown. The computer device includes a processor, a memory, an input / output interface, a communication interface, a display unit and an input device. The processor, the memory and the input / output interface are connected through a system bus, and the communication interface, the display unit and the input device are connected to the system bus through the input / output interface. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The input / output interface of the computer device is used to exchange information between the processor and an external device. The communication interface of the computer device is used to communicate with an external terminal in a wired or wireless manner, and the wireless manner can be realized through WIFI, a mobile cellular network, NFC (near field communication) or other technologies. When the computer program is executed by the processor, a method for visualizing edge data is realized. The display unit of the computer device is used to form a visually visible picture, which can be a display screen, a projection device or a virtual reality imaging device. The display screen can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer device can be a touch layer covering the display screen, or a button, trackball or touchpad set on the computer device shell, or an external keyboard, touchpad or mouse.
[0152] Those skilled in the art will understand that Fig.13 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0153] In one embodiment, a computer device is further provided, including a memory and a processor, wherein a computer program is stored in the memory, and the processor implements the steps in the above method embodiments when executing the computer program.
[0154] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps in the above-mentioned method embodiments are implemented.
[0155] In one embodiment, a computer program product is provided, including a computer program, which implements the steps in the above method embodiments when executed by a processor.
[0156] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. Non-relational databases may include distributed databases based on blockchains, etc., but are not limited to this. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., but are not limited to this.
[0157] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0158] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.
Claims
1. A method for visualizing edge data, characterized in that: The method comprises: Performing triangulation processing on the equipment data of the electric equipment to obtain a triangulated network of the electric equipment; Constructing a Voronoi diagram of the electric power equipment according to the triangles in the triangulated network; Performing edge filtering on the three-dimensional grid model obtained based on the Voronoi diagram to obtain a target three-dimensional grid model of the electric power equipment; According to the coordinate data of the points on the edge of the target three-dimensional grid model, a visual simulation result of the edge is obtained.
2. The method according to claim 1, characterized in that The performing edge filtering on the three-dimensional grid model obtained based on the Voronoi diagram to obtain the target three-dimensional grid model of the electric power equipment includes: Merging the intersections of the approximate straight lines in the three-dimensional mesh model obtained based on the Voronoi diagram to obtain a merged three-dimensional mesh model; the approximate straight lines represent non-straight edges in the three-dimensional mesh model that are composed of multiple line segments and are approximately straight. Reorganizing the point-line structure in the merged three-dimensional mesh model to obtain a reorganized three-dimensional mesh model; Merging the intersections of arcs in the reorganized three-dimensional mesh model to obtain a re-merged three-dimensional mesh model; the arcs represent non-straight edges in the three-dimensional mesh model that are not approximately straight and are composed of multiple line segments; The re-merged three-dimensional grid model is reorganized again to obtain a target three-dimensional grid model of the electric power equipment.
3. The method according to claim 1, characterized in that The step of obtaining a visualization simulation result of an edge according to coordinate data of a point on the edge of the target three-dimensional grid model comprises: A ray is emitted from the coordinate data of a point on the edge of the target three-dimensional grid model, the ray is used to detect the simulation model that is collided with, and obtain the coordinates of the collision point in the simulation model; the simulation model represents the collision body of the power equipment in the virtual engine; the points on the edge include the first vertex, the middle point and the last vertex; Converting the coordinates of the collision point into local coordinates in a volume rendering model of the target three-dimensional mesh model; According to the local coordinates, obtaining simulation data of the edge of the target three-dimensional mesh model from which the ray is emitted; The simulation data of the edge is visualized to obtain a visualized simulation result of the edge.
4. The method according to claim 3, characterized in that Before obtaining the visual simulation result of the edge according to the coordinate data of each vertex on the edge of the target three-dimensional mesh model, the method further includes: For a straight edge in the target three-dimensional mesh model, obtaining coordinate data of a middle point of the straight edge according to coordinate data of a first vertex and a tail vertex of the straight edge; For the curved edge in the target three-dimensional mesh model, the curved edge is divided into a plurality of straight line segments, and the coordinate data of the middle point of each straight line segment is obtained according to the coordinate data of the first vertex and the last vertex of each straight line segment.
5. The method according to claim 1, characterized in that The triangulation process is performed on the equipment data of the electric equipment to obtain the triangulated network of the electric equipment, including: Based on the equipment data of the power equipment, a super triangle is constructed, and the super triangle is stored in a triangle linked list; the super triangle includes all the equipment data; Inserting each of the device data into the triangle linked list in sequence to obtain an updated triangle linked list; The optimized triangles obtained based on the local optimization criterion are inserted into the updated triangle linked list to obtain the triangulated network.
6. The method according to claim 1, characterized in that The step of obtaining the Voronoi diagram of the electric power equipment according to the triangles in the triangulated network comprises: Determine the circumscribed circle of each triangle in the triangulated network; The centers of the circumscribed circles are connected to obtain a Voronoi diagram of the electric power equipment.
7. A visual processing device for edge data, characterized in that: The device comprises: A triangulation module, used for performing triangulation processing on the equipment data of the electric equipment to obtain a triangulated network of the electric equipment; A Voronoi diagram generating module, used for constructing a Voronoi diagram of the electric power equipment according to the triangles in the triangulated network; An edge filtering module, used for performing edge filtering on the three-dimensional grid model obtained based on the Voronoi diagram to obtain a target three-dimensional grid model of the electric power equipment; The visualization processing module is used to obtain the simulation data of the power equipment on the edge according to the coordinate data of the points on the edge of the target three-dimensional grid model.
8. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 6 are implemented.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.
10. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.
Citation Information
Patent Citations
Fitting optimization method of triangular mesh data and system for achieving fitting optimization method
CN102737407A
Unknown space autonomous exploration planning method
CN113625721A
Automatic grid subdivision method based on delaunay triangularization
CN114742918A
Virtual simulation roadway three-dimensional modeling method, device, equipment, medium and product
CN118172505A