AIAgent-based spatial data visualization system
By using AIAgent-based data cluster generation and residual calculation mechanisms, the problem of visual misalignment when superimposing millimeter-level and kilometer-level point clouds at the provincial scale was solved, achieving high-precision consistent superposition and accurate interpretation, and improving the spatial location judgment capabilities of emergency management and industrial quality inspection.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- YUNZHONG CENTURY (BEIJING) TECHNOLOGY CO LTD
- Filing Date
- 2025-09-05
- Publication Date
- 2026-04-17
AI Technical Summary
In a large coordinate system at the provincial scale, it is difficult to maintain spatial consistency when millimeter-level point clouds and kilometer-level point clouds are overlaid on the web, especially when switching tiles or displaying across data sources. Sudden visual misalignments can easily occur, affecting users' accurate interpretation of defect locations and spatial relationships.
Through the AIAgent-based data cluster generation, residual calculation, and jump amplitude determination mechanism, the residual value of the reference coordinates of each data cluster in single-precision floating-point conversion is calculated to determine the lower bound value of the spatial jump amplitude, which is then converted into the screen pixel misalignment distribution to generate candidate boundary lines and direction indication information. Finally, these are displayed in the form of heat map, line graph, arrow graph, and reliability index.
It achieves high-precision and consistent overlay of millimeter-level local point clouds and kilometer-level macro point clouds on the Web, improving users' ability to accurately interpret minute defects and their macro spatial relationships. In particular, it enhances the stable correspondence and visualization effect of spatial location in emergency management and industrial quality inspection applications.
Smart Images

Figure CN121166957B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of data processing technology, and more specifically, to an AIAgent-based spatial data visualization system. Background Technology
[0002] In existing technologies, provincial or city-level 3D spatial data visualization systems typically require loading and displaying large-scale building point clouds, terrain point clouds, and localized high-precision detection point clouds on a web-based platform. For example, in emergency material management and industrial quality inspection scenarios, it is often necessary to simultaneously display the overall spatial environment of the factory warehouse and the millimeter-level bottle defect detection results, thereby achieving a unified display of the macro environment and micro defects.
[0003] However, in current technologies, browser-side rendering primarily relies on single-precision floating-point calculations performed by the GPU. Single-precision floating-point numbers have a limited number of effective bits. When the processing scope expands to global coordinates at the provincial scale (such as ECEF), the smallest resolvable unit reaches sub-meter or even meter levels. In this situation, when millimeter-level local point cloud data is overlaid with kilometer-level large-scale building point clouds, rounding errors occur due to insufficient precision.
[0004] To mitigate this issue, existing visualization engines employ a relative centering method, converting the coordinates of each tile or data batch into a small range of values relative to the local center to reduce floating-point errors. However, this method can lead to inconsistencies in the relative centers of multiple data sources or tiles when loaded simultaneously. When users zoom, pan, or switch perspectives in the browser, the residual errors between different data sources cannot be canceled out, resulting in noticeable abrupt misalignments on the screen. This misalignment may be difficult to detect at a distance, but when users zoom in to view a local point cloud, sub-meter-level errors are magnified into jumps of multiple pixels, disrupting the spatial correspondence between the bottle defect point cloud and the building point cloud. Summary of the Invention
[0005] This invention provides an AIAgent-based spatial data visualization system that solves the technical problem of maintaining spatial consistency when millimeter-level and kilometer-level point clouds are overlaid on the web under a large coordinate system at the provincial scale. This is especially true when switching tiles or displaying across data sources, where sudden visual misalignments can easily occur, affecting the user's accurate interpretation of defect locations and spatial relationships.
[0006] This invention provides an AIAgent-based spatial data visualization system, comprising:
[0007] The data cluster generation module receives raw spatial data through AIAgent, initializes and generates a cluster set containing multiple data clusters; wherein, the data clusters include at least environmental data clusters and target data clusters, and outputs the reference coordinates and boundary information of active data units for each data cluster through AIAgent;
[0008] The residual calculation module, based on the rules of single-precision floating-point arithmetic, calculates the residual value of the reference coordinates of each data cluster in the single-precision floating-point conversion;
[0009] The jump amplitude determination module uses the environmental data cluster as a benchmark, calculates the residual difference between the target data cluster and the environmental data cluster, and determines the lower bound of the spatial jump amplitude based on the residual difference.
[0010] The pixel misalignment quantization module obtains the screen parameters, viewing angle parameters and spatial distance of each pixel of the display device, converts the lower bound of the spatial jump amplitude into the screen pixel misalignment distribution, and normalizes the pixel misalignment distribution into a visual intensity value.
[0011] The boundary and direction generation module projects the boundary information of active data units onto the screen coordinate system to generate candidate boundary lines; based on the direction of the residual difference, it generates spatial misalignment direction indication information.
[0012] The consistency analysis module calculates the mean of pixel misalignment distribution in the user's specified area to obtain the interpretation reliability index.
[0013] The visualization overlay module displays the visualization intensity value, candidate boundary line, direction indication information, and judgment reliability index in read-only overlay form as heat map layer, line layer, arrow layer, and index label.
[0014] Furthermore, the raw spatial data is received via AIAgent, and a cluster set containing multiple data clusters is initialized and generated, including:
[0015] AIAgent receives raw spatial data from each data source, extracts the candidate center coordinates of the corresponding active data unit, the boundary description information of the spatial boundary range of the active data unit, and the purpose label of each active data unit from each raw spatial data, forming a set of active data units; active data units with purpose labels of environment and target are respectively assigned to environment data cluster and target data cluster, forming a cluster set containing environment data cluster and target data cluster; the average value of the candidate center coordinates of each active data unit in the data cluster is calculated, and the average value is used as the reference coordinate of the cluster.
[0016] Furthermore, based on the rules of single-precision floating-point arithmetic, the residual values of the reference coordinates of each data cluster in the single-precision floating-point conversion are calculated, including:
[0017] Define single-precision floating-point conversion rules, including:
[0018] The rounding mode adopts the rounding mode specified by the IEEE 754 standard to the nearest even number;
[0019] An anomaly is marked when the component value of the reference coordinate is greater than the maximum value that can be represented by a single-precision floating-point number;
[0020] An anomaly is marked when the component value of the reference coordinate is less than the minimum value that can be represented by a single-precision floating-point number;
[0021] When the component values of the reference coordinates are between the minimum and maximum values that can be represented by a single-precision floating-point number, they are marked as normal.
[0022] For normal reference coordinates, perform single-precision floating-point conversion operations on each component of the reference coordinates according to the single-precision floating-point conversion rules to obtain the single-precision reference coordinates of the data cluster;
[0023] The difference between each component in the reference coordinates of the data cluster and the corresponding component in the single-precision reference coordinates of the data cluster is obtained to form the residual vector.
[0024] The arithmetic square root of the sum of the squares of the coordinate differences in each direction is used as the residual magnitude of the data cluster.
[0025] Furthermore, using the environmental data cluster as a benchmark, the residual difference between the target data cluster and the environmental data cluster is calculated. Based on the residual difference, the lower bound of the spatial jump amplitude is determined, including:
[0026] The residual difference vector is obtained by subtracting the residual vectors of the target data cluster and the environmental data cluster.
[0027] For each residual difference vector, calculate the square value of each component of the residual difference vector; sum the square values of each component and then perform an arithmetic square root operation to obtain the lower bound value of the spatial jump amplitude.
[0028] Furthermore, the screen parameters, viewing angle parameters, and spatial distance corresponding to each pixel of the display device are obtained. The lower bound of the spatial jump amplitude is converted into the screen pixel misalignment distribution, and the pixel misalignment distribution is normalized into a visual intensity value, including:
[0029] Read the screen width and screen height in pixels of the display device;
[0030] Read the horizontal and vertical viewing angles of the display device's rendering module;
[0031] Obtain the spatial distance map of each pixel in the display device. The position (i,j) in the spatial distance map represents the straight-line distance from the spatial point corresponding to the pixel in the i-th column and j-th row on the display device to the observer.
[0032] The equivalent focal length is obtained by dividing half the number of pixels in the screen width by the tangent of half the horizontal viewing angle.
[0033] Multiplying the equivalent focal length by the lower bound of the spatial jump amplitude value yields the pixel misalignment value of the corresponding pixel.
[0034] Arrange the pixel misalignment values of each pixel according to their positions (i,j) to form a pixel misalignment distribution;
[0035] Determine the maximum and minimum pixel misalignment values in the pixel misalignment distribution, and then perform maximum and minimum value normalization on the pixel misalignment value of each pixel to obtain the corresponding visualization intensity value.
[0036] Furthermore, the boundary information of active data units is projected onto the screen coordinate system to generate candidate boundary lines; based on the direction of the residual difference, spatial misalignment direction indication information is generated, including:
[0037] Based on the prior camera position and camera attitude, a view transformation matrix is generated to convert the world coordinate system 3D coordinates to the camera coordinate system 3D coordinates;
[0038] By combining the horizontal viewing angle, the number of pixels in the screen width, and the number of pixels in the screen height, a projection matrix is generated to convert the 3D coordinates of the camera coordinate system into normalized device coordinates;
[0039] The screen mapping operator is obtained by combining the view transformation matrix and the projection matrix;
[0040] For each 3D vertex coordinate in the boundary information of the active data unit, coordinate transformation is performed through the screen mapping operator to obtain the corresponding screen pixel coordinates; all screen pixel coordinates are arranged according to the vertex connection order in the boundary information of the active data unit to form a projected vertex sequence.
[0041] Define the screen viewport as a rectangular area with horizontal pixel coordinates from 0 to the number of pixels in the screen width minus 1 and vertical pixel coordinates from 0 to the number of pixels in the screen height minus 1; draw line segments on the projection vertex sequence in connection order and extract the line segments within the screen viewport; summarize all the extracted line segments to form a set of candidate boundary lines.
[0042] Divide the residual difference vector by the lower bound of the corresponding spatial jump amplitude to obtain the unit direction vector.
[0043] Convert the unit direction vector into an updated unit direction vector using the view transformation matrix;
[0044] For each candidate boundary line in the candidate boundary line set, extract all screen pixels covered by the candidate boundary line, read the spatial distance values corresponding to all screen pixels covered from the spatial distance map, calculate the average value of all spatial distance values, and obtain the representative depth of the candidate boundary line.
[0045] The screen direction vector of the candidate boundary line is obtained by multiplying the updated unit direction vector by the equivalent focal length and then dividing by the representative depth of the candidate boundary line.
[0046] Anchor points are selected on the candidate boundary lines according to a preset pixel step size;
[0047] Assign a direction angle to the candidate boundary line for each anchor point to determine the arrow direction;
[0048] The arrow length is determined by the ratio of the two-dimensional length of the screen direction vector to the preset reference length;
[0049] Arrow graphics are generated based on anchor point location, arrow direction, and arrow length. All arrow graphics are associated with candidate boundary lines according to their corresponding anchor points to form a set of directional indication information.
[0050] Furthermore, for a specified area of the user, the mean of the pixel misalignment distribution is calculated to obtain the interpretation reliability index, including:
[0051] Receive the user's specified area; for pixels in the display device that belong to the specified area, mark them as 1; extract the pixels marked as 1 to obtain the set of valid pixels; traverse the coordinates (i,j) of each pixel in the set of valid pixels, extract the pixel misalignment value corresponding to the coordinates (i,j) of each pixel from the pixel misalignment distribution, arrange all pixel misalignment values to form a pixel misalignment value sequence; calculate the sum of all pixel misalignment values in the pixel misalignment value sequence, divide the sum by the number of valid pixels, and obtain the interpretation reliability index.
[0052] Furthermore, the visualized intensity values, candidate boundary lines, direction indication information, and interpretation reliability index are displayed in a read-only overlay format as heatmap layers, line layers, arrow layers, and index labels, including:
[0053] The visual intensity value of each pixel is input into a preset color mapping function to calculate the corresponding RGB color and form a heat map layer.
[0054] Each candidate boundary line is marked with a pixel as 1, and a preset RGB color is displayed for the pixels marked as 1, forming a line layer;
[0055] Iterate through each arrow graphic in the directional indicator information set; using the anchor point of the arrow graphic as the center, draw a triangular arrow according to the arrow direction. The length of the triangular arrow is determined by the length of the arrow graphic. Display the triangular arrow in a preset RGB color to form an arrow layer.
[0056] Take the center pixel coordinates of the screen center of the specified area as the annotation center, and annotate the interpretation reliability index at the annotation center to form an index annotation layer;
[0057] Heatmap layers, line layers, arrow layers, and index labels are overlaid on the display device for display.
[0058] The beneficial effects of this invention are as follows: By introducing an AIAgent-based data cluster generation, residual calculation, and jump amplitude determination mechanism, it effectively overcomes the visual misalignment problem caused by insufficient single-precision floating-point calculation accuracy in large-scale coordinate systems at the provincial or city level, achieving high-precision consistent overlay of millimeter-level local point clouds and kilometer-level macro point clouds on the Web. The system can not only transform residual differences into quantifiable pixel misalignment distributions and present them intuitively using multi-layered graphics such as heatmaps, boundary lines, directional arrows, and reliability indices, but also maintain stable spatial correspondence across data sources and multi-tile scenarios, thereby improving users' ability to accurately interpret minute defects and their macroscopic spatial relationships in applications such as emergency management and industrial quality inspection. Attached Figure Description
[0059] Figure 1 This is a block diagram of the spatial data visualization system based on AIAgent of the present invention. Detailed Implementation
[0060] The subject matter described herein will now be discussed with reference to exemplary embodiments. It should be understood that these embodiments are discussed only to enable those skilled in the art to better understand and implement the subject matter described herein, and changes may be made to the function and arrangement of the elements discussed without departing from the scope of this specification. Various processes or components may be omitted, substituted, or added as needed in the examples. Furthermore, features described in some examples may be combined in other examples.
[0061] like Figure 1 As shown, the spatial data visualization system based on AIAgent includes:
[0062] The data cluster generation module receives raw spatial data through AIAgent, initializes and generates a cluster set containing multiple data clusters; wherein, the data clusters include at least environmental data clusters and target data clusters, and outputs the reference coordinates and boundary information of active data units for each data cluster through AIAgent;
[0063] The residual calculation module, based on the rules of single-precision floating-point arithmetic, calculates the residual value of the reference coordinates of each data cluster in the single-precision floating-point conversion;
[0064] The jump amplitude determination module uses the environmental data cluster as a benchmark, calculates the residual difference between the target data cluster and the environmental data cluster, and determines the lower bound of the spatial jump amplitude based on the residual difference.
[0065] The pixel misalignment quantization module obtains the screen parameters, viewing angle parameters and spatial distance of each pixel of the display device, converts the lower bound of the spatial jump amplitude into the screen pixel misalignment distribution, and normalizes the pixel misalignment distribution into a visual intensity value.
[0066] The boundary and direction generation module projects the boundary information of active data units onto the screen coordinate system to generate candidate boundary lines; based on the direction of the residual difference, it generates spatial misalignment direction indication information.
[0067] The consistency analysis module calculates the mean of pixel misalignment distribution in the user's specified area to obtain the interpretation reliability index.
[0068] The visualization overlay module displays the visualization intensity value, candidate boundary line, direction indication information, and judgment reliability index in read-only overlay form as heat map layer, line layer, arrow layer, and index label.
[0069] In one embodiment of the present invention, raw spatial data is received via AIAgent, and a cluster set containing multiple data clusters is initialized and generated, including:
[0070] AIAgent receives raw spatial data from each data source, extracts the candidate center coordinates of the corresponding active data unit, the boundary description information of the spatial boundary range of the active data unit, and the purpose label of each active data unit from each raw spatial data, forming a set of active data units; active data units with purpose labels of environment and target are respectively assigned to environment data cluster and target data cluster, forming a cluster set containing environment data cluster and target data cluster; the average value of the candidate center coordinates of each active data unit in the data cluster is calculated, and the average value is used as the reference coordinate of the cluster.
[0071] In detail, AIAgent represents a tool scheduling agent that performs one-time data access and rule-making during the initialization phase. Its responsibilities include: receiving raw spatial data, extracting candidate center coordinates, extracting boundary description information, reading usage labels, and outputting a set of active data units and a set of clusters. This can be implemented directly using existing open-source frameworks, such as LangChain's Agent or Haystack's Agent, which act as a tool invoker and complete the one-time initialization through registered tool functions.
[0072] In detail, the purpose tag is a business role identifier used for clustering, and its values must include at least:
[0073] Environmental labels, such as provincial building point clouds and 3D terrain tiles, are macroscopic reference data.
[0074] Target labels, such as data blocks of any local high-precision object, can be point clouds of building components.
[0075] In detail, raw spatial data represents spatial data volumes or their indexes obtained directly from various data sources, which may be point cloud blocks, 3D tiles, collections of objects, etc.
[0076] In detail, an active data unit represents the smallest spatial data granularity that can independently participate in display and computation, such as a tile, a point cloud block, or a building object.
[0077] In detail, the candidate center coordinates represent the representative coordinates of the spatial location of a single active data unit.
[0078] Detailed boundary description information for the active data cell space boundary range represents the geometric boundary description of the active data cell space coverage range, which is a continuous sequence of vertices.
[0079] In detail, the environmental data cluster, target data cluster, and cluster set are two basic clusters aggregated according to their purpose tags, as well as the cluster set structure.
[0080] In detail, the reference coordinates are the cluster-level representative coordinates obtained by taking the equally weighted average of the candidate center coordinates of all active data units within each data cluster.
[0081] Specifically, AIAgent filters out all active data units labeled "environment" to form environmental data clusters. Environmental data clusters characterize the macroscopic spatial environment and typically contain data with broad coverage and large spatial scales. Examples include building point cloud units within a province or terrain point cloud units within a factory area. Simultaneously, AIAgent filters out all active data units labeled "target" to form target data clusters. Target data clusters characterize specific objects requiring focused attention and typically contain data with smaller spatial scales and higher accuracy requirements.
[0082] It should be noted that for the environmental data cluster, AIAgent extracts candidate center coordinates for all active data units within the cluster. These candidate values are then summed for each of the X, Y, and Z components of the 3D coordinate system. The summation is then divided by the total number of active data units in the cluster to obtain the average values of the X, Y, and Z components. The 3D coordinates formed by combining these three average values are the reference coordinates for the environmental data cluster. For the target data cluster, the same calculation method is used: candidate center coordinates for all active data units are extracted, and the average values of the X, Y, and Z components are calculated separately. These average values are then combined to obtain the reference coordinates for the target data cluster. The average values are used as the reference coordinates because they comprehensively reflect the overall spatial position of all active data units within the cluster, avoiding the impact of accidental deviations in the coordinates of a single unit on the overall cluster positioning.
[0083] In one embodiment of the present invention, based on the rules of single-precision floating-point arithmetic, the residual value of the reference coordinates of each data cluster in the single-precision floating-point conversion is calculated, including:
[0084] Define single-precision floating-point conversion rules, including:
[0085] The rounding mode adopts the rounding mode specified by the IEEE 754 standard to the nearest even number;
[0086] An anomaly is marked when the component value of the reference coordinate is greater than the maximum value that can be represented by a single-precision floating-point number;
[0087] An anomaly is marked when the component value of the reference coordinate is less than the minimum value that can be represented by a single-precision floating-point number;
[0088] When the component values of the reference coordinates are between the minimum and maximum values that can be represented by a single-precision floating-point number, they are marked as normal.
[0089] For normal reference coordinates, perform single-precision floating-point conversion operations on each component of the reference coordinates according to the single-precision floating-point conversion rules to obtain the single-precision reference coordinates of the data cluster;
[0090] The difference between each component in the reference coordinates of the data cluster and the corresponding component in the single-precision reference coordinates of the data cluster is obtained to form the residual vector.
[0091] The arithmetic square root of the sum of the squares of the coordinate differences in each direction is used as the residual magnitude of the data cluster.
[0092] In detail, the single-precision floating-point conversion rule adopts the rounding mode of the IEEE 754 standard to the nearest even number, which is a common method used in floating-point processing to reduce the accumulation of rounding errors.
[0093] In detail, the IEEE 754 standard is an internationally recognized floating-point arithmetic standard. Its defined rounding to the nearest even number mode is a common method to reduce the accumulation of rounding errors in floating-point processing. When the value to be converted is exactly in the middle of two adjacent representable single-precision floating-point numbers, the floating-point number with an even mantissa (binary) is selected as the conversion result; if the value to be converted is closer to a certain adjacent representable floating-point number, then that floating-point number is directly selected as the conversion result. Suppose the decimal value to be converted is 2.5, which in binary representation is exactly between two adjacent representable values of the single-precision floating-point number 10.1 (corresponding to decimal 2.5) (the actual representation of single-precision floating-point numbers requires combining the exponent and mantissa, but this is simplified here). In this case, it is necessary to determine the parity of the mantissa of the two adjacent values and select the value with an even mantissa as the conversion result. For example, if the value to be converted is 2.3, since it is closer to 2.0 (assuming 2.0 is the closer one among the adjacent representable floating-point numbers), then 2.0 is directly used as the conversion result.
[0094] In detail, the reference coordinates are three-dimensional spatial coordinates, containing three components: X, Y, and Z. Each component requires individual numerical evaluation, based on the representable range of a single-precision floating-point number. The maximum representable value of a single-precision floating-point number is approximately 3.4028235 × 10⁻⁶. 38 The minimum representable value (the smallest positive representable value) is approximately 1.17549435 × 10⁻⁶. -38 (The range of negative values is symmetrical to that of positive values, and the judgment logic is consistent).
[0095] Anomaly 1: When the value of a component of the reference coordinate exceeds the maximum value that a single-precision floating-point number can represent, it is marked as an anomaly. Such values exceed the range that the exponent of a single-precision floating-point number can represent, and cannot be accurately stored in single-precision format. Forcibly converting them will cause numerical overflow and produce a large error, so they must be excluded from subsequent calculations.
[0096] Abnormal State 2: When the value of a component of the reference coordinate is less than the minimum value that can be represented by a single-precision floating-point number, it is marked as abnormal. Such values exceed the precision that the mantissa of a single-precision floating-point number can represent. After conversion, they will be represented as 0 or a value very close to 0, completely losing the precision information of the original value. They also need to be excluded from subsequent calculations.
[0097] Normal state: When the value of a component of the reference coordinate is between the minimum and maximum values that can be represented by a single-precision floating-point number, it is marked as normal. Such values can be effectively converted using single-precision floating-point number format, and the conversion retains most of the original precision information, making them valid for subsequent calculations.
[0098] In detail, after the status judgment of the reference coordinate components is completed, the conversion operation is performed only for the reference coordinates in which all components are in a normal state, according to the aforementioned single-precision floating-point conversion rules, and the conversion must be performed separately for the X, Y, and Z components of the reference coordinates.
[0099] Specifically, for the X component of the reference coordinates, it is rounded to the nearest even number according to IEEE 754 rounding mode and converted into a corresponding single-precision floating-point number, which serves as the X component of the single-precision reference coordinates. Similarly, the Y and Z components of the reference coordinates are converted into single-precision floating-point numbers, which also serve as the Y and Z components of the single-precision reference coordinates. The combination of these three converted components forms the single-precision reference coordinates for this data cluster.
[0100] In detail, the residual vector represents the vector of accuracy loss of the reference coordinates in each direction (X, Y, Z) in three-dimensional space. Its calculation requires the corresponding components of the original reference coordinates and the single-precision reference coordinates, specifically:
[0101] Subtract the X component value of the single-precision reference coordinate from the X component value of the original reference coordinate to obtain the coordinate difference of the X component; using the same method, calculate the difference between the Y component of the original reference coordinate and the Y component of the single-precision reference coordinate (Y component coordinate difference), and the difference between the Z component of the original reference coordinate and the Z component of the single-precision reference coordinate (Z component coordinate difference).
[0102] Forming the residual vector: Combine the X component coordinate difference, Y component coordinate difference, and Z component coordinate difference obtained above in the order of XYZ to form a three-dimensional vector, which is the residual vector of the data cluster.
[0103] Each component of the residual vector directly reflects the magnitude of accuracy loss in the corresponding spatial direction: if the absolute value of the difference of a certain component is large, it indicates that the accuracy loss of the original reference coordinates in that direction due to single-precision transformation is more severe; if the absolute value of the difference is small, it indicates that the accuracy loss in that direction is less severe. Through the residual vector, one can intuitively understand the distribution of accuracy loss in three-dimensional space.
[0104] In detail, the residual magnitude transforms the three-dimensional precision loss of the residual vector into a single numerical value, used to represent the overall precision loss of the data cluster reference coordinates due to single-precision transformation. Specifically:
[0105] The squared values of the X component coordinate differences in the residual vector are obtained by squaring the X component coordinate differences. The same method is used to calculate the squared values of the Y component coordinate differences and the Z component coordinate differences, respectively.
[0106] Add the squared differences of the X, Y, and Z components obtained above to get the sum of the squares of the three component differences.
[0107] Performing an arithmetic square root operation on the above sum of squares yields the residual magnitude of the data cluster.
[0108] The larger the residual amplitude, the more severe the overall accuracy loss of the data cluster reference coordinates due to single-precision transformation; the smaller the residual amplitude, the less severe the overall accuracy loss.
[0109] In one embodiment of the present invention, using an environmental data cluster as a reference, the residual difference between the target data cluster and the environmental data cluster is calculated, and the lower bound of the spatial jump amplitude is determined based on the residual difference, including:
[0110] The residual difference vector is obtained by subtracting the residual vectors of the target data cluster and the environmental data cluster.
[0111] For each residual difference vector, calculate the square value of each component of the residual difference vector; sum the square values of each component and then perform an arithmetic square root operation to obtain the lower bound value of the spatial jump amplitude.
[0112] In detail, the residual difference vector represents the difference between the residual vectors of the target data cluster and the environmental data cluster. It is used to visualize the difference in accuracy loss between the two data clusters in the three spatial directions of X, Y, and Z, and to clarify the magnitude and direction of the difference.
[0113] Since the environmental data cluster is a macroscopic spatial benchmark (such as the terrain and buildings of the factory area), its accuracy loss can be regarded as the benchmark error. By subtracting the residuals of the target cluster and the environmental cluster, the influence of the benchmark error can be removed, and only the additional accuracy loss difference of the target data cluster relative to the benchmark can be retained.
[0114] Each component of the residual difference vector directly reflects the difference in accuracy loss between the target cluster and the environment cluster in the corresponding spatial direction:
[0115] If the X-direction component of the residual difference vector is positive, it indicates that the accuracy loss of the target cluster in the X-direction is greater than that of the environment cluster; if it is negative, it indicates that the accuracy loss of the target cluster in the X-direction is less than that of the environment cluster. The larger the absolute value, the more significant the difference in accuracy loss in the X-direction. The components in the Y and Z directions have the same meaning as those in the X-direction. Through the residual difference vector, we can determine the distribution characteristics of the accuracy loss difference between the two data clusters in three-dimensional space, such as whether the difference in the X-direction is dominant or whether the differences in the Y and Z directions are more prominent.
[0116] It should be noted that since each component of the residual difference vector represents a difference in a certain direction, direct superposition would lead to distortion due to the cancellation of positive and negative values. Therefore, it is necessary to transform the differences in each direction into a non-negative overall amplitude through summation of squares and taking the arithmetic square root (i.e., L2 norm), while avoiding the cancellation problem and ensuring that the result truly reflects the overall degree of difference between the two clusters. The lower bound of the spatial jump amplitude is an overall quantitative indicator of the residual difference vector. The lower bound of the spatial jump amplitude represents the minimum misalignment distance that the target data cluster may experience in space relative to the surrounding data cluster due to differences in precision loss.
[0117] Specifically, the residual vector represents the precision loss caused by single-precision floating-point conversion, while the residual difference vector reflects the minimum difference in precision loss between two data clusters. In practical applications, due to the potential introduction of additional errors, the true spatial misalignment between the two data clusters will be at least the lower bound of the spatial jump amplitude.
[0118] In one embodiment of the present invention, the screen parameters, viewing angle parameters, and spatial distance corresponding to each pixel of the display device are obtained; the lower bound of the spatial jump amplitude is converted into the screen pixel misalignment distribution; and the pixel misalignment distribution is normalized into a visual intensity value, including:
[0119] Read the screen width and screen height in pixels of the display device;
[0120] Read the horizontal and vertical viewing angles of the display device's rendering module;
[0121] Obtain the spatial distance map of each pixel in the display device. The position (i,j) in the spatial distance map represents the straight-line distance from the spatial point corresponding to the pixel in the i-th column and j-th row on the display device to the observer.
[0122] The equivalent focal length is obtained by dividing half the number of pixels in the screen width by the tangent of half the horizontal viewing angle.
[0123] Multiplying the equivalent focal length by the lower bound of the spatial jump amplitude value yields the pixel misalignment value of the corresponding pixel.
[0124] Arrange the pixel misalignment values of each pixel according to their positions (i,j) to form a pixel misalignment distribution;
[0125] Determine the maximum and minimum pixel misalignment values in the pixel misalignment distribution, and then perform maximum and minimum value normalization on the pixel misalignment value of each pixel to obtain the corresponding visualization intensity value.
[0126] In detail, screen width in pixels refers to the total number of pixels in the horizontal direction of the display device, such as the common 1920 pixels (corresponding to the horizontal pixels of a 1080P screen); screen height in pixels refers to the total number of pixels in the vertical direction of the display device, such as 1080 pixels (corresponding to the vertical pixels of a 1080P screen). Screen width in pixels and screen height in pixels define the pixel coordinate system of the screen: each pixel on the screen can be uniquely located by its column number i and row number j.
[0127] In detail, the horizontal viewing angle refers to the spatial angle that the display device's rendering module can cover in the horizontal direction, measured in radians or angles, such as 60 degrees (meaning the sum of the angles formed by the horizontal edge of the screen and the observer's line of sight is 60 degrees). The vertical viewing angle refers to the spatial angle that the rendering module can cover in the vertical direction, and its calculation logic is the same as that of the horizontal viewing angle. Viewing angle parameters define the correspondence between screen pixels and spatial angles: the larger the viewing angle, the wider the spatial range that the screen can present, and the larger the spatial angle corresponding to a single pixel; the smaller the viewing angle, the narrower the spatial range that the screen presents, and the smaller the spatial angle corresponding to a single pixel.
[0128] In detail, the spatial distance map is a two-dimensional data graph perfectly aligned with the screen's pixel coordinate system. The value stored at each position (i,j) in the graph represents the straight-line distance from the spatial point corresponding to the pixel in the i-th column and j-th row on the display device to the observer. For example, if the pixel in the 100th column and 200th row of the screen corresponds to a spatial point on the wall of a building in the scene, the value stored at that position is the straight-line distance from the observer to that wall.
[0129] Because different pixels correspond to different spatial points at different distances from the observer, spatial jumps of the same physical scale will result in a greater screen misalignment on pixels that are closer to the viewer. This is similar to how the image of a near object being displaced is more noticeable to the eye than that of a distant object.
[0130] In detail, the equivalent focal length is a virtual optical parameter used to correlate the horizontal viewing angle of a display device with the number of pixels in the screen width, forming a conversion coefficient from spatial angle to the number of pixels.
[0131] The calculation of equivalent focal length depends only on the number of pixels in the screen width and the horizontal angle of view. The formula is: Equivalent focal length = half the number of pixels in the screen width ÷ half the tangent of the horizontal angle of view.
[0132] The specific derivation logic is based on the geometric relationship of a right triangle: taking the observer's line of sight as the vertex, the line connecting the horizontal edge of the screen to the line of sight forms a right triangle. Half the number of pixels across the screen width is the opposite side of this triangle (corresponding to the number of pixels in half the horizontal width of the screen), half the horizontal viewing angle is the acute angle of this triangle (corresponding to the angle from the line of sight to the horizontal edge of the screen), and the equivalent focal length is the adjacent side of this triangle (corresponding to the virtual lens focal length). According to trigonometric relationships, tangent = opposite side ÷ adjacent side; therefore, adjacent side (equivalent focal length) = opposite side ÷ tangent, as shown in the formula above.
[0133] In detail, the unit of equivalent focal length is pixels per radian, representing the number of pixels on the screen corresponding to every 1 radian (or 1 angle) of spatial angular change. For example, if the equivalent focal length is 1000 pixels per radian, it means that a 1-radian angular change in space will be represented by a 1000-pixel displacement on the screen. The equivalent focal length determines the pixel scale of spatial jumps on the screen: the larger the equivalent focal length, the more obvious the pixel misalignment corresponding to the same spatial jump; the smaller the equivalent focal length, the weaker the pixel misalignment corresponding to the same spatial jump.
[0134] In detail, the misalignment value of each pixel needs to be calculated individually based on its corresponding spatial distance, as follows: Pixel misalignment value = Equivalent focal length × Lower bound of spatial jump amplitude ÷ Spatial distance corresponding to that pixel. It is important to note that different pixels on the screen correspond to different spatial distances. Pixels closer to the observer (smaller spatial distance values) have larger pixel misalignment values; conversely, pixels farther from the observer (larger spatial distance values) have smaller pixel misalignment values. This aligns with the laws of human vision. That is, minute displacements of nearby objects will appear as noticeable screen misalignment, while identical displacements of distant objects are difficult to perceive, ensuring that the pixel misalignment value accurately reflects the misalignment effect observed by the user. If spatial distance is not considered (i.e., assuming all pixels are at the same distance), the misalignment value of all pixels will be identical, failing to reflect the misalignment differences in different areas of the screen, leading to distorted visualization results. Therefore, personalized calculations combined with spatial distance maps are crucial to ensuring the accuracy of the results.
[0135] In detail, pixel misalignment represents the amount of displacement on the screen caused by a physical jump in the spatial location of a pixel. For example, if the misalignment value of a pixel is 5 pixels, it means that the spatial point at that location will shift 5 pixels on the screen due to a physical jump. This offset is a visible misalignment that the user can directly observe. The larger the offset, the easier it is for the user to notice the misalignment; the smaller the offset, the harder it is for the user to notice the misalignment.
[0136] In detail, the pixel misalignment value calculated for each pixel's position needs to be mapped one-to-one with the pixel's coordinates (i,j), and organized into a two-dimensional data matrix with column i from left to right and row j from top to bottom. For example, the misalignment value for position (0,0) (the top left pixel of the screen) is stored in the first row and first column of the matrix, and the misalignment value for position 1919,1079 (the bottom right pixel of a 1080P screen) is stored in the 1080th row and 1920th column of the matrix.
[0137] In detail, because the misalignment values of different pixels can vary considerably (for example, some pixels may have a misalignment value of 0.1 pixels, while others may have a misalignment value of 10 pixels), directly using them for visualization would result in pixels with small misalignment values having no color difference, while pixels with large misalignment values would have saturated colors, making it impossible to clearly distinguish the strength of the misalignment. Therefore, it is necessary to normalize the misalignment values to the range of 0 to 1 through maximum and minimum value normalization to obtain the visualization intensity value.
[0138] It should be noted that the visualization intensity value ranges from 0 to 1 and is the core indicator used to map "color depth":
[0139] An intensity value close to 1 indicates that the misalignment value of the pixel is close to the maximum value in the distribution, corresponding to a darker area (such as red) in the heat map, indicating to the user that the misalignment in this area is significant;
[0140] An intensity value close to 0 indicates that the misalignment of the pixel is close to the minimum value in the distribution, corresponding to a lighter-colored area (such as blue) in the heat map, indicating to the user that the misalignment in that area is slight.
[0141] The intensity value is between 0 and 1, and the color depth gradually changes with the intensity value, realizing the mapping from the intensity of the misalignment to the color depth.
[0142] In one embodiment of the present invention, the boundary information of active data units is projected onto the screen coordinate system to generate candidate boundary lines; based on the direction of the residual difference, spatial misalignment direction indication information is generated, including:
[0143] Based on the prior camera position and camera attitude, a view transformation matrix is generated to convert the world coordinate system 3D coordinates to the camera coordinate system 3D coordinates;
[0144] By combining the horizontal viewing angle, the number of pixels in the screen width, and the number of pixels in the screen height, a projection matrix is generated to convert the 3D coordinates of the camera coordinate system into normalized device coordinates;
[0145] The screen mapping operator is obtained by combining the view transformation matrix and the projection matrix;
[0146] For each 3D vertex coordinate in the boundary information of the active data unit, coordinate transformation is performed through the screen mapping operator to obtain the corresponding screen pixel coordinates; all screen pixel coordinates are arranged according to the vertex connection order in the boundary information of the active data unit to form a projected vertex sequence.
[0147] Define the screen viewport as a rectangular area with horizontal pixel coordinates from 0 to the number of pixels in the screen width minus 1 and vertical pixel coordinates from 0 to the number of pixels in the screen height minus 1; draw line segments on the projection vertex sequence in connection order and extract the line segments within the screen viewport; summarize all the extracted line segments to form a set of candidate boundary lines.
[0148] Divide the residual difference vector by the lower bound of the corresponding spatial jump amplitude to obtain the unit direction vector.
[0149] Convert the unit direction vector into an updated unit direction vector using the view transformation matrix;
[0150] For each candidate boundary line in the candidate boundary line set, extract all screen pixels covered by the candidate boundary line, read the spatial distance values corresponding to all screen pixels covered from the spatial distance map, calculate the average value of all spatial distance values, and obtain the representative depth of the candidate boundary line.
[0151] The screen direction vector of the candidate boundary line is obtained by multiplying the updated unit direction vector by the equivalent focal length and then dividing by the representative depth of the candidate boundary line.
[0152] Anchor points are selected on the candidate boundary lines according to a preset pixel step size;
[0153] Assign a direction angle to the candidate boundary line for each anchor point to determine the arrow direction;
[0154] The arrow length is determined by the ratio of the two-dimensional length of the screen direction vector to the preset reference length;
[0155] Arrow graphics are generated based on anchor point location, arrow direction, and arrow length. All arrow graphics are associated with candidate boundary lines according to their corresponding anchor points to form a set of directional indication information.
[0156] In detail, the view transformation matrix connects world space and camera space. Its generation depends entirely on the prior camera position and camera attitude, thus converting the 3D boundary coordinates of all active data units into a coordinate system with the camera as the observation origin, conforming to the human eye's viewing perspective. Camera position refers to the camera's 3D coordinates in the world coordinate system. If the camera moves along the X-axis in the world coordinate system, the view transformation matrix must include the corresponding X-axis translation parameter to ensure that all world coordinate points translate synchronously with the camera position change. Similarly, when the camera moves along the Y-axis or Z-axis, the matrix must include the translation parameter for the corresponding axis. Camera attitude refers to the camera's orientation (e.g., horizontal rotation angle, vertical pitch angle). If the camera rotates horizontally by 30 degrees, the view transformation matrix must include the corresponding XY-plane rotation parameter; if the camera pitches by 15 degrees, the matrix must include the corresponding XZ-plane rotation parameter. Through the combination of rotation and translation parameters, the view transformation matrix can accurately convert 3D points in the world coordinate system (such as the boundary vertices of active data units) into 3D points in the camera coordinate system.
[0157] In detail, the projection matrix is used to connect the camera space and the display device space. Its generation combines the horizontal viewing angle, the number of pixels in the screen width, and the number of pixels in the screen height, thereby compressing the three-dimensional points in the camera coordinate system into two-dimensional normalized device coordinates (the coordinate range is usually -1 to 1).
[0158] The horizontal viewing angle determines the spatial range that the camera can cover horizontally, while the number of pixels in the screen width determines the total number of pixels horizontally. Combining these two factors determines how many normalized device coordinate units (NCOs) correspond to a 1-radian horizontal angle in the camera space. For example, the larger the horizontal viewing angle, the narrower the NCO range corresponding to the same horizontal spatial range; the larger the number of pixels in the screen width, the greater the conversion ratio from NCOs to pixel coordinates.
[0159] The number of pixels for screen height is used to match the vertical aspect ratio, ensuring that the projected 2D coordinates are not stretched due to an imbalance in the screen's aspect ratio. For example, when the screen width is 1920 pixels and the height is 1080 pixels, the projection matrix must include a vertical scaling parameter so that the vertical 3D range in camera space matches the 1080-pixel height ratio of the screen.
[0160] In detail, the screen mapping operator is the result of a combination of the view transformation matrix and the projection matrix. The operation order is first view transformation and then projection transformation. That is, for any 3D point in the world coordinate system, it is first transformed into a 3D point in the camera coordinate system through the view transformation matrix, then transformed into normalized device coordinates through the projection matrix, and finally obtained through a linear mapping from normalized device coordinates to screen pixel coordinates.
[0161] In detail, for each 3D vertex coordinate in the active data unit boundary information, coordinate transformation is performed one by one using the screen mapping operator to obtain the corresponding screen pixel coordinates for each vertex. Then, according to the preset vertex connection order in the active data unit boundary information (e.g., vertices are connected in the order of front left-top → front right-top → back right-top → back left-top → front left-top to form the top surface boundary), the transformed screen pixel coordinates are arranged in the same order to form a projected vertex sequence. The projected vertex sequence is used to preserve the original topological structure of the boundary, ensuring that the projected 2D line segments accurately reflect the shape of the 3D boundary.
[0162] In detail, the horizontal pixel coordinates range from 0 to the screen width in pixels minus 1, and the vertical pixel coordinates range from 0 to the screen height in pixels minus 1. This range represents the actual screen area visible to the user; line segments outside this range have no visual significance. Line segments are drawn in the order of connection for the projected vertex sequence, and a viewport-level cropping operation is performed on each segment: if the segment is entirely within the viewport, the entire segment is retained; if part of the segment is within the viewport, the portion within the viewport is cropped; if the segment is completely outside the viewport, it is discarded. All cropped segments are aggregated to form a candidate boundary line set. These candidate boundary lines mark the extent of active data units on the screen, used to quickly locate areas where misalignment may occur (such as the intersection of the boundaries between environmental and target data clusters).
[0163] In detail, the residual difference vector contains both direction and magnitude information, while the direction indicator only needs to retain the direction information. Therefore, the residual difference vector needs to be normalized: each component of the residual difference vector is divided by the lower bound of the corresponding spatial jump magnitude to obtain the unit direction vector.
[0164] For example, if the residual difference vector is (2m, 4m, 0m) and the lower bound of the spatial jump amplitude is 20m, then the unit direction vector is... Its vector length is 1. This eliminates the interference of amplitude on direction, so that the unit direction vector only represents the spatial direction of the misalignment and does not contain information about the magnitude of the misalignment.
[0165] It's important to note that, consistent with the 3D boundary vertex coordinate transformation logic, the unit direction vector, currently in the world coordinate system, needs to be converted to an updated unit direction vector in the camera coordinate system via a view transformation matrix. This ensures that the direction vector matches the viewpoint displayed on the screen. For example, a misalignment along the positive X-axis in the world coordinate system should be displayed as a misalignment along the positive Y-axis on the screen after the camera is rotated horizontally by 90 degrees. Updating the unit direction vector accurately reflects the direction after this viewpoint change.
[0166] In detail, the screen pixels covered by the candidate boundary lines may correspond to different spatial distances (e.g., one end of the boundary line corresponds to a nearby object, and the other end corresponds to a distant object). If a single distance is used directly to calculate the direction vector, the arrow direction will not conform to the perspective rules. Therefore, it is necessary to calculate the representative depth of each candidate boundary line:
[0167] Extract the coordinates of all screen pixels covered by the candidate boundary line;
[0168] Read the spatial distance values corresponding to these pixels from the spatial distance map;
[0169] Calculate the arithmetic mean of these spatial distance values to obtain the representative depth of the candidate boundary line.
[0170] The depth is used to provide an average distance reference for calculating the screen orientation vector, ensuring that the arrow direction conforms to the visual perspective rule of objects appearing larger when closer and smaller when farther away.
[0171] In detail, the screen orientation vector is the projection of the update unit orientation vector onto the screen plane. It needs to be calculated in combination with the equivalent focal length and the representative depth. The formula is: Screen orientation vector = Update unit orientation vector × Equivalent focal length ÷ Representative depth.
[0172] The equivalent focal length is used to connect the camera's field of view with the screen pixels, ensuring that when the three-dimensional orientation is converted to the screen orientation, it can match the pixel scale of the screen.
[0173] The depth is used to adjust the length of the orientation vector according to perspective rules. The greater the depth (the farther the boundary line), the shorter the screen orientation vector; the smaller the depth (the closer the boundary line), the longer the screen orientation vector, which matches the visual effect that the direction of near objects changes more obviously as observed by the human eye.
[0174] The final form of the screen orientation vector is a two-dimensional vector (corresponding to the horizontal and vertical pixel directions of the screen), which directly reflects the misalignment direction observed on the screen.
[0175] In detail, for each candidate boundary line, anchor points are selected according to a preset pixel step size (preferably every 50 pixels): starting from the initial pixel coordinates of the boundary line, a point is marked along the boundary line every preset pixel step size; these points are the anchor points. The preset pixel step size needs to balance arrow density and visual clarity: too small a step size will result in arrows that are too dense, obscuring the boundary line; too large a step size will result in arrows that are sparse, failing to fully reflect the misalignment direction of the boundary line. It is usually set according to the screen resolution; for example, the preset step size for a 1920×1080 screen can be set to 50 pixels.
[0176] In detail, the arrow's direction is determined by the angle of the screen orientation vector. For example, if the screen orientation vector is (5 pixels, 0 pixels) (horizontally to the right), the arrow points to the right of the screen; if the vector is (0 pixels, -3 pixels) (vertically downwards), the arrow points downwards. By understanding the correspondence between the vector angle and the screen coordinate system, the arrow's direction angle can be accurately calculated.
[0177] The arrow length is determined by the ratio of the two-dimensional length of the screen direction vector to a preset baseline length. The preset baseline length is a set standard arrow length (e.g., 10 pixels). If the two-dimensional length of the screen direction vector is 5 pixels, then the arrow length is 5 pixels ÷ preset baseline length × preset baseline length (i.e., 5 pixels); if the vector length is 15 pixels, then the arrow length is 15 pixels ÷ preset baseline length × preset baseline length (i.e., 15 pixels). This calculation method ensures that the arrow length is proportional to the actual length of the screen direction vector, reflecting the relative magnitude of the direction vector.
[0178] In detail, a triangular arrow shape is drawn according to the anchor point position → arrow direction → arrow length (one vertex of the triangle is the anchor point, and the other two vertices extend along the arrow direction, with the length conforming to the calculation result). Then, each arrow shape is associated with its corresponding anchor point and candidate boundary line (e.g., marking which anchor point of which boundary line the arrow belongs to). All the associated arrow shapes together form a set of directional indication information.
[0179] The detailed directional information set is used to provide users with misalignment direction guidance. By observing the direction of the arrows, users can directly determine the misalignment trend of the target data cluster relative to the surrounding data cluster (e.g., an arrow pointing to the right indicates that the target cluster is misaligned to the right relative to the surrounding cluster). Combined with candidate boundary lines, users can quickly grasp the location and direction of the misalignment.
[0180] In one embodiment of the present invention, for a specified area of the user, the mean value of the pixel misalignment distribution is calculated to obtain the reading reliability index, including:
[0181] Receive the user's specified area; for pixels in the display device that belong to the specified area, mark them as 1; extract the pixels marked as 1 to obtain the set of valid pixels; traverse the coordinates (i,j) of each pixel in the set of valid pixels, extract the pixel misalignment value corresponding to the coordinates (i,j) of each pixel from the pixel misalignment distribution, arrange all pixel misalignment values to form a pixel misalignment value sequence; calculate the sum of all pixel misalignment values in the pixel misalignment value sequence, divide the sum by the number of valid pixels, and obtain the interpretation reliability index.
[0182] In detail, users specify an area through the interactive functions of the display device (such as mouse selection, touch selection, and inputting coordinate range). The spatial form of the specified area must match the screen pixel coordinate system. Common forms include:
[0183] Rectangular region: By specifying the pixel coordinates of the top left and bottom right corners of a rectangle, the pixel coverage area in the horizontal direction (range of i) and vertical direction (range of j) can be determined.
[0184] Circular region: The user specifies the center pixel coordinates and radius (in pixels), and all pixels whose distance to the center is less than or equal to the radius are determined through geometric calculations;
[0185] Custom polygon region: The user specifies the pixel coordinates of multiple vertices, and all pixels within the region are determined by a polygon interior point determination algorithm (such as ray casting).
[0186] Regardless of the form, it must ultimately be converted into the coverage area of pixel coordinates.
[0187] In detail, the process involves iterating through the pixel misalignment value sequence, summing all misalignment values to obtain the total of the sequence (i.e., the sum of all valid pixel misalignment values within the specified area); counting the total number of coordinates in the set of valid pixels (i.e., the length of the sequence); and dividing the sum of misalignment values by the number of valid pixels to obtain the interpretation reliability index. The interpretation reliability index reflects the average degree of misalignment in the specified area, thus determining the reliability of the user's interpretation.
[0188] The smaller the interpretation reliability index, the less severe the average misalignment of pixels in the specified area, the more accurate the spatial correspondence between target data and environmental data, and the more reliable the results of user interpretation in this area (such as identifying defect locations and confirming the association between the target and the background).
[0189] The higher the reliability index, the more severe the average misalignment of pixels within the specified area, the greater the spatial correspondence between the target data and the environmental data, and the lower the reliability of the results of user interpretation in this area. It is necessary to be wary of misjudgments caused by misalignment.
[0190] In one embodiment of the present invention, the visualization intensity value, candidate boundary line, direction indication information, and judgment reliability index are displayed in a read-only overlay format as a heat map layer, line layer, arrow layer, and index label, including:
[0191] The visual intensity value of each pixel is input into a preset color mapping function to calculate the corresponding RGB color and form a heat map layer.
[0192] Each candidate boundary line is marked with a pixel as 1, and a preset RGB color is displayed for the pixels marked as 1, forming a line layer;
[0193] Iterate through each arrow graphic in the directional indicator information set; using the anchor point of the arrow graphic as the center, draw a triangular arrow according to the arrow direction. The length of the triangular arrow is determined by the length of the arrow graphic. Display the triangular arrow in a preset RGB color to form an arrow layer.
[0194] Take the center pixel coordinates of the screen center of the specified area as the annotation center, and annotate the interpretation reliability index at the annotation center to form an index annotation layer;
[0195] Heatmap layers, line layers, arrow layers, and index labels are overlaid on the display device for display.
[0196] In detail, the heatmap is used to convert visual intensity values into color shades, allowing users to quickly identify high and low misalignment areas on the screen by color, thus mapping intensity values to RGB colors.
[0197] The default color mapping function is the core tool for associating visualization intensity values with RGB colors, following a positive correlation between color gradient and intensity. That is, the larger the visualization intensity value (corresponding to more severe pixel misalignment), the darker the mapped color; the smaller the intensity value (corresponding to less severe pixel misalignment), the lighter the mapped color.
[0198] The preferred preset color mapping logic is as follows:
[0199] Visual intensity values close to 0 (minimum misalignment): mapped to light blue (RGB values such as (135, 206, 235));
[0200] Visualization intensity values between 0.3 and 0.7 (moderate misalignment): mapped to gradient colors (e.g., transitioning from green (144,238,144) to yellow (255,255,153));
[0201] Visual intensity values close to 1 (maximum misalignment): mapped to dark red (RGB values such as 220, 20, 60).
[0202] In detail, for each pixel of the display device, perform the following operations:
[0203] Read the visual intensity value of the pixel;
[0204] Input the intensity value into the preset color mapping function, and the function will calculate the unique corresponding RGB color value (e.g., an intensity value of 0.8 corresponds to RGB(255,165,0)).
[0205] Assign the RGB color value to the pixel to complete the color rendering of a single pixel;
[0206] Repeat the above steps until all pixels are assigned the corresponding RGB color, and the color set of all pixels together forms the heatmap.
[0207] In detail, the line layer is used to present candidate boundary lines as prominent lines, marking the screen extent of active data units. Candidate boundary lines are high-risk areas for misalignment across data clusters (such as the intersection of the boundary between the environment data cluster and the target data cluster).
[0208] The candidate boundary line set contains multiple line segments within the screen viewport, each consisting of a series of consecutive screen pixels (e.g., a boundary line might cover horizontal pixels from pixel coordinates (100, 200) to (150, 200)). When generating the line layer, these pixels belonging to the boundary lines must first be selected.
[0209] For each candidate boundary line, extract the coordinates of all screen pixels it covers;
[0210] These pixels are marked as 1 (1 represents that they belong to the boundary line and need to be rendered with color);
[0211] Pixels not covered by the boundary line are not marked (or marked as 0, meaning no boundary color needs to be rendered).
[0212] Marked as 1 to locate boundary line pixels, preventing non-boundary pixels from being rendered incorrectly, and ensuring that the line layer only renders the true boundaries of active data units.
[0213] Set a preset RGB color for the pixel marked as 1. This color must have high contrast characteristics (such as pure red RGB(255,0,0) or pure blue RGB(0,0,255)) to ensure that the boundary line is clearly visible against the background of the heatmap layer and is not obscured by heatmap areas of similar color;
[0214] Assign the preset RGB color to all pixels marked as 1, while keeping unmarked pixels transparent (this does not affect the display of other layers).
[0215] The collection of all pixels assigned a boundary color together forms the line layer.
[0216] Line layers solve the problem of blurred boundary areas in heatmaps. For example, a high misalignment area in a heatmap may cover multiple data clusters, but a line layer can clearly delineate the boundaries of different data clusters with striking lines, helping users understand which data cluster's boundary the misalignment occurs near.
[0217] In detail, the arrow layer is used to convert the spatial misalignment direction into triangular arrows on the screen, allowing users to quickly determine the misalignment trend of the target data cluster relative to the environmental data cluster by the direction of the arrow.
[0218] The directional indicator information set includes three types of parameters for each candidate boundary line: anchor point position, arrow direction, and arrow length. These parameters directly determine the drawing effect of the arrow.
[0219] The anchor point is the center point of the arrow, which is the specific coordinates (e.g., pixels (200, 300)) on the screen where the arrow needs to be drawn. Ensure that the arrow is precisely aligned with the candidate boundary line (the anchor points are all located on the corresponding boundary line).
[0220] The direction of the arrow is determined by the angle of the screen direction vector (e.g., a vector pointing to the right corresponds to an arrow pointing to the right, and a vector pointing upwards corresponds to an arrow pointing upwards), ensuring that the direction of the arrow is consistent with the actual misalignment direction;
[0221] The arrow length is determined by the ratio of the two-dimensional length of the screen direction vector to a preset baseline length (e.g., if the preset baseline length is 10 pixels and the vector length is 5 pixels, then the arrow length is 5 pixels). This ensures that the arrow length intuitively reflects the relative size of the direction vector (the longer the vector, the longer the arrow, and the more obvious the tendency to indicate a misaligned direction). A triangle is the simplest graphic that clearly indicates direction; users can quickly identify the direction by the direction the apex of the triangle points, avoiding confusion caused by complex graphics.
[0222] For example, if the anchor point is , the direction is right, and the length is 8 pixels, then the tip of the triangle is located at (200+8,300), and the other two vertices are located at (200+8,300-4) and (200+8,300+4) respectively, forming a symmetrical triangular arrow.
[0223] Set a preset RGB color for all triangular arrows. This color should be distinguishable from the heatmap layer and line layer (e.g., use red for the line layer and blue RGB(0,0,255) for the arrow layer) to avoid confusion between the arrows and the boundary lines or heatmap colors; all drawn triangular arrows are combined to form an arrow layer (areas without arrows remain transparent).
[0224] Arrow layers fill the information gap where only the intensity and boundary of misalignment are known, but the direction of misalignment is unknown. For example, if a user discovers a severely misaligned area through a heatmap, a line layer indicates that the area is located at the boundary of a target data cluster, but an arrow layer can further clarify whether the target cluster is misaligned to the left or right.
[0225] In detail, the index labeling layer is used to present the reliability index of the interpretation in the form of numerical labels, allowing users to quickly determine whether the spatial correspondence of a specified area is reliable through specific values.
[0226] The annotation center must be selected from the center pixel coordinates of the specified area on the screen to ensure that the annotation position accurately corresponds to the area of interest to the user, avoiding confusion caused by annotations deviating from the designated area. The method for determining this is as follows:
[0227] If the specified area is a rectangle: calculate the average of the coordinates of the top left corner and the bottom right corner of the rectangle to obtain the horizontal center i value ((top left corner i + bottom right corner i) / 2) and the vertical center j value ((top left corner j + bottom right corner j) / 2). The combination of the two is the screen center pixel coordinates.
[0228] If the specified area is circular: the center pixel coordinates of the circle are directly used as the screen center pixel coordinates;
[0229] If the specified area is a polygon: calculate the mean of the coordinates of all vertices of the polygon, obtain the horizontal and vertical center values, and combine them to obtain the screen center pixel coordinates.
[0230] The pixel coordinates at the center of the screen are the visual focus when a user observes a specified area. Marking them here allows users to see the index at first glance without having to search for it separately, thus improving ease of use.
[0231] For example, read the reliability index (e.g., 0.8 pixels or 2.5 pixels) of a specified area; use the center pixel coordinates of the specified area as the annotation center, and draw the index text at that location. The index text format must be clear and legible, ensuring it remains clearly identifiable against a colored background;
[0232] Add a semi-transparent background border to the text to avoid blurring caused by the text overlapping with the heatmap or line graph.
[0233] The index text and background boxes of all specified areas together form the index label layer.
[0234] The index labeling layer transforms the abstract mean calculation result into a concrete numerical label. Users can quickly determine the reliability of a region by the index size without having to calculate it themselves. For example, an index of 0.3 pixels indicates a slight misalignment and the interpretation is reliable, while an index of 3.0 pixels indicates a severe misalignment and the interpretation needs careful verification, providing a quantitative basis for users' decision-making.
[0235] The embodiments of this example have been described above. However, this example is not limited to the specific implementation methods described above. The specific implementation methods described above are merely illustrative and not restrictive. Those skilled in the art can make many other forms based on the guidance of this example, and all of them are within the protection scope of this example.
Claims
1. A spatial data visualization system based on AIAgent, characterized in that, include: The data cluster generation module receives raw spatial data through AIAgent, initializes and generates a cluster set containing multiple data clusters; wherein, the data clusters include at least environmental data clusters and target data clusters, and outputs the reference coordinates and boundary information of active data units for each data cluster through AIAgent; The residual calculation module, based on the rules of single-precision floating-point arithmetic, calculates the residual value of the reference coordinates of each data cluster in the single-precision floating-point conversion; The jump amplitude determination module uses the environmental data cluster as a benchmark, calculates the residual difference between the target data cluster and the environmental data cluster, and determines the lower bound of the spatial jump amplitude based on the residual difference. The pixel misalignment quantization module obtains the screen parameters, viewing angle parameters and spatial distance of each pixel of the display device, converts the lower bound of the spatial jump amplitude into the screen pixel misalignment distribution, and normalizes the pixel misalignment distribution into a visual intensity value. The boundary and direction generation module projects the boundary information of active data units onto the screen coordinate system to generate candidate boundary lines; based on the direction of the residual difference, it generates spatial misalignment direction indication information. The consistency analysis module calculates the mean of pixel misalignment distribution in the user's specified area to obtain the interpretation reliability index. The visualization overlay module displays the visualization intensity value, candidate boundary line, direction indication information, and judgment reliability index in read-only overlay form as heat map layer, line layer, arrow layer, and index label.
2. The spatial data visualization system based on AIAgent according to claim 1, characterized in that, The AIAgent receives raw spatial data and initializes a cluster set containing multiple data clusters, including: AIAgent receives raw spatial data from each data source, extracts the candidate center coordinates of the corresponding active data unit, the boundary description information of the spatial boundary range of the active data unit, and the purpose label of each active data unit from each raw spatial data, forming a set of active data units; active data units with purpose labels of environment and target are respectively assigned to environment data cluster and target data cluster, forming a cluster set containing environment data cluster and target data cluster; the average value of the candidate center coordinates of each active data unit in the data cluster is calculated, and the average value is used as the reference coordinate of the cluster.
3. The spatial data visualization system based on AIAgent according to claim 2, characterized in that, Based on the rules of single-precision floating-point arithmetic, the residual values of the reference coordinates of each data cluster in the single-precision floating-point transformation are calculated, including: Define single-precision floating-point conversion rules, including: The rounding mode adopts the rounding mode specified by the IEEE 754 standard to the nearest even number; An anomaly is marked when the component value of the reference coordinate is greater than the maximum value that can be represented by a single-precision floating-point number; An anomaly is marked when the component value of the reference coordinate is less than the minimum value that can be represented by a single-precision floating-point number; When the component values of the reference coordinates are between the minimum and maximum values that can be represented by a single-precision floating-point number, they are marked as normal. For normal reference coordinates, perform single-precision floating-point conversion operations on each component of the reference coordinates according to the single-precision floating-point conversion rules to obtain the single-precision reference coordinates of the data cluster; The difference between each component in the reference coordinates of the data cluster and the corresponding component in the single-precision reference coordinates of the data cluster is obtained to form the residual vector. The arithmetic square root of the sum of the squares of the coordinate differences in each direction is used as the residual magnitude of the data cluster.
4. The spatial data visualization system based on AI Agent according to claim 3, characterized in that, Using the environmental data cluster as a benchmark, calculate the residual difference between the target data cluster and the environmental data cluster. Based on the residual difference, determine the lower bound of the spatial jump amplitude, including: The residual difference vector is obtained by subtracting the residual vectors of the target data cluster and the environmental data cluster. For each residual difference vector, calculate the square value of each component of the residual difference vector; sum the square values of each component and then perform an arithmetic square root operation to obtain the lower bound value of the spatial jump amplitude.
5. The spatial data visualization system based on AIAgent according to claim 4, characterized in that, Obtain the screen parameters, viewing angle parameters, and spatial distance of each pixel of the display device; convert the lower bound of the spatial jump amplitude into the screen pixel misalignment distribution; and normalize the pixel misalignment distribution into a visual intensity value, including: Read the screen width and screen height in pixels of the display device; Read the horizontal and vertical viewing angles of the display device's rendering module; Obtain the spatial distance map of each pixel in the display device. The position (i,j) in the spatial distance map represents the straight-line distance from the spatial point corresponding to the pixel in the i-th column and j-th row on the display device to the observer. The equivalent focal length is obtained by dividing half the number of pixels in the screen width by the tangent of half the horizontal viewing angle. Multiplying the equivalent focal length by the lower bound of the spatial jump amplitude value yields the pixel misalignment value of the corresponding pixel. Arrange the pixel misalignment values of each pixel according to their positions (i,j) to form a pixel misalignment distribution; Determine the maximum and minimum pixel misalignment values in the pixel misalignment distribution, and then perform maximum and minimum value normalization on the pixel misalignment value of each pixel to obtain the corresponding visualization intensity value.
6. The spatial data visualization system based on AI Agent according to claim 5, characterized in that, Project the boundary information of active data units onto the screen coordinate system to generate candidate boundary lines; Based on the direction of the residual difference, spatial misalignment direction indication information is generated, including: Based on the prior camera position and camera attitude, a view transformation matrix is generated to convert the world coordinate system 3D coordinates to the camera coordinate system 3D coordinates; By combining the horizontal viewing angle, the number of pixels in the screen width, and the number of pixels in the screen height, a projection matrix is generated to convert the 3D coordinates of the camera coordinate system into normalized device coordinates; The screen mapping operator is obtained by combining the view transformation matrix and the projection matrix; For each 3D vertex coordinate in the boundary information of the active data unit, coordinate transformation is performed through the screen mapping operator to obtain the corresponding screen pixel coordinates; all screen pixel coordinates are arranged according to the vertex connection order in the boundary information of the active data unit to form a projected vertex sequence. Define the screen viewport as a rectangular area with horizontal pixel coordinates from 0 to the number of pixels in the screen width minus 1 and vertical pixel coordinates from 0 to the number of pixels in the screen height minus 1; draw line segments on the projection vertex sequence in connection order and extract the line segments within the screen viewport; summarize all the extracted line segments to form a set of candidate boundary lines. Divide the residual difference vector by the lower bound of the corresponding spatial jump amplitude to obtain the unit direction vector. Convert the unit direction vector into an updated unit direction vector using the view transformation matrix; For each candidate boundary line in the candidate boundary line set, extract all screen pixels covered by the candidate boundary line, read the spatial distance values corresponding to all screen pixels covered by the spatial distance map, calculate the average value of all spatial distance values, and obtain the representative depth of the candidate boundary line. The screen direction vector of the candidate boundary line is obtained by multiplying the updated unit direction vector by the equivalent focal length and then dividing by the representative depth of the candidate boundary line. Anchor points are selected on the candidate boundary lines according to a preset pixel step size; Assign a direction angle to the candidate boundary line for each anchor point to determine the arrow direction; The arrow length is determined by the ratio of the two-dimensional length of the screen direction vector to the preset reference length; Arrow graphics are generated based on anchor point location, arrow direction, and arrow length. All arrow graphics are associated with candidate boundary lines according to their corresponding anchor points to form a set of directional indication information.
7. The spatial data visualization system based on AIAgent according to claim 6, characterized in that, For a specified area specified by the user, the mean value of the pixel misalignment distribution is calculated to obtain the interpretation reliability index, including: Receive the user's specified area; for pixels in the display device that belong to the specified area, mark them as 1; extract the pixels marked as 1 to obtain the set of valid pixels; traverse the coordinates (i,j) of each pixel in the set of valid pixels, extract the pixel misalignment value corresponding to the coordinates (i,j) of each pixel from the pixel misalignment distribution, arrange all pixel misalignment values to form a pixel misalignment value sequence; calculate the sum of all pixel misalignment values in the pixel misalignment value sequence, divide the sum by the number of valid pixels, and obtain the interpretation reliability index.
8. The spatial data visualization system based on AIAgent according to claim 7, characterized in that, The visualization intensity values, candidate boundary lines, direction indication information, and interpretation reliability index are displayed in a read-only overlay format as heatmap layers, line layers, arrow layers, and index labels, including: The visual intensity value of each pixel is input into a preset color mapping function to calculate the corresponding RGB color and form a heat map layer. Each candidate boundary line is marked with a pixel as 1, and a preset RGB color is displayed for the pixels marked as 1, forming a line layer; Iterate through each arrow graphic in the directional indicator information set; using the anchor point of the arrow graphic as the center, draw a triangular arrow according to the arrow direction. The length of the triangular arrow is determined by the length of the arrow graphic. Display the triangular arrow in a preset RGB color to form an arrow layer. Take the center pixel coordinates of the screen center of the specified area as the annotation center, and annotate the interpretation reliability index at the annotation center to form an index annotation layer; Heatmap layers, line layers, arrow layers, and index label layers are overlaid on the display device for display.
Citation Information
Patent Citations
Real-time three-dimensional city modeling and dynamic updating method and system based on deep learning
CN120495579A
Spatial visual display method and system combined with earthquake disaster situation database
CN120523868A