Soil environment quality vector data quality inspection method, system, equipment and medium
By introducing a negative buffer judgment mechanism, cross-boundary land parcels can be accurately identified and segmented, solving the problems of misjudgment and missed detection in traditional methods, and realizing efficient quality inspection and automated remediation of soil environmental quality vector data.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- SICHUAN ACAD OF ENVIRONMENTAL SCI
- Filing Date
- 2026-02-04
- Publication Date
- 2026-05-26
AI Technical Summary
Traditional methods cannot accurately determine the relationship between a land parcel and the administrative boundary, leading to misjudgment or omission of cross-boundary land parcels, which affects the reliability and efficiency of soil environmental quality vector data inspection results.
A negative buffer judgment mechanism is introduced. By shrinking the geometric boundary of the land parcel inward by a preset tolerance distance to form a negative buffer land parcel, the intersection relationship between the land parcel and the administrative region boundary is judged to ensure accurate identification of cross-boundary land parcels and automatic geometric segmentation and attribute updates.
It improves the accuracy and efficiency of cross-boundary land parcel identification, reduces the subjectivity of human intervention, ensures the topological accuracy and coding standardization of data, and meets the needs of large-scale data update and maintenance.
Smart Images

Figure CN122086875A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of data processing technology, and more specifically, to a method, system, device, and medium for quality inspection of soil environmental quality vector data. Background Technology
[0002] Vector data on soil environmental quality for construction land is digitized data describing the spatial location, shape, and attribute characteristics of land parcels. It requires regular updates and maintenance in soil pollution prevention and control. To ensure data quality, updated vector data must undergo rigorous quality checks, with administrative division consistency checks being a key focus and challenge. This check aims to verify whether land parcels have been correctly divided according to administrative boundaries. If a land parcel crosses a county-level administrative boundary without being divided, it will cause spatial logical inconsistencies in the data, directly affecting the scientific validity and accuracy of soil environmental management. Therefore, accurately determining the spatial relationship between land parcels and administrative boundaries is a crucial step in ensuring the spatial topological correctness of the vector data.
[0003] However, traditional geometric intersection judgment methods can only identify whether the boundary line intersects with the land parcel, but cannot determine whether the boundary line only contacts the edge of the land parcel or actually penetrates the interior of the land parcel. This leads to a large number of land parcels that only have boundary contact being misjudged as cross-boundary land parcels, while some real cross-boundary land parcels may be missed due to the complex way the boundary overlaps, affecting the reliability of the quality inspection results. Summary of the Invention
[0004] The purpose of this application is to provide a method, system, device and medium for quality inspection of soil environmental quality vector data, so as to solve the above-mentioned problems.
[0005] In a first aspect, embodiments of this application provide a method for quality inspection of soil environmental quality vector data. The method includes: acquiring soil environmental quality vector data and administrative region boundary data; determining a first boundary line intersecting with each plot in the vector data based on the administrative region boundary data; determining a negative buffer plot of the plot; wherein the negative buffer plot is used to characterize a geometric object formed by shrinking the geometric boundary of the plot inward by a preset tolerance distance and located inside the plot; if the first boundary line intersects with the negative buffer plot, the plot is determined to be a cross-boundary plot; otherwise, the plot is determined to be a non-cross-boundary plot. In the implementation of the above scheme, by introducing a negative buffer judgment mechanism, the spatial relationship detection between land parcels and administrative boundaries is improved from the traditional boundary intersection judgment to the internal crossing judgment, thereby improving the accuracy of cross-boundary land parcel identification. On the other hand, through geometric calculation using the negative buffer method, the complex spatial relationship judgment is transformed into a precise mathematical operation, avoiding the subjectivity and inconsistency of manual inspection, thus improving the quality inspection effect of the above-mentioned soil environmental quality vector data quality inspection method. Furthermore, the above scheme has a small computational load and can quickly process multiple land parcels in batches. Compared with traditional manual inspection or semi-automatic tools, it has higher processing efficiency and can meet the quality inspection needs of regular updates and maintenance of large-scale soil environmental quality vector data.
[0006] In one implementation of the first aspect, the method further includes: when the land parcel is determined to be a cross-boundary land parcel, determining a second boundary line that crosses the land parcel in the first boundary line; merging the second boundary line into a land parcel dividing line; using the land parcel dividing line to geometrically divide the land parcel to obtain at least one sub-land parcel of the land parcel; for each sub-land parcel, determining the administrative region to which the sub-land parcel belongs based on the spatial location of the sub-land parcel and the administrative region boundary data, and updating the land parcel attributes of the sub-land parcel. In the implementation of the above scheme, by merging the second boundary line identified by the negative buffer into the land parcel dividing line, and geometrically dividing the cross-boundary land parcels accordingly, the land parcels can be accurately divided along the administrative boundary. Then, based on the spatial location of the sub-land parcels, the administrative region to which they belong is automatically determined and the attribute information is updated. This eliminates the tedious operation of manually dividing and editing attributes one by one in the relevant software after detecting problems in the traditional method. The automated repair mechanism in the above scheme can process all cross-boundary land parcels identified by quality inspection in batches, thereby improving the repair efficiency of cross-boundary land parcels and reducing labor and time costs. On the other hand, by using the actual crossing boundary determined by the negative buffer as the dividing benchmark, the topological accuracy of the dividing position is guaranteed, avoiding geometric deviations introduced by manual operation, which is conducive to improving the repair effect of vector data.
[0007] In one implementation of the first aspect, the land parcel attribute includes a land parcel identifier; updating the land parcel attribute of the sub-land parcel includes: extracting a prefix character of a preset number of digits from the administrative region code of the administrative region to which the sub-land parcel belongs, to obtain a first code segment; determining a fixed intermediate code of the land parcel identifier, to obtain a second code segment; determining a serial number of the sub-land parcel based on the serial numbers of existing land parcels within the administrative region to which the sub-land parcel belongs; determining a third code segment based on the serial number of the sub-land parcel; generating a land parcel identifier of the sub-land parcel based on the first code segment, the second code segment, and the third code segment; and updating the land parcel attribute of the sub-land parcel using the generated land parcel identifier. In the implementation of the above scheme, by extracting the administrative region code prefix, fixing the intermediate code, and automatically generating new serial numbers based on existing land parcel serial numbers, it is ensured that the land parcel identifiers of the sub-land parcels have global uniqueness, coding standardization, and continuity within their respective administrative regions, thus avoiding identifier duplication or coding errors caused by manual intervention. On the other hand, it realizes the full automation of land parcel identifier generation, eliminating the need for manual compilation and verification, greatly improving the efficiency of identifier allocation, while ensuring a strict correspondence between identifiers and administrative divisions, and enhancing the traceability and management standardization of the repaired data.
[0008] In one implementation of the first aspect, the land parcel attributes include land area; updating the land parcel attributes includes: obtaining the coordinate reference system of the sub-land parcel; when the coordinate reference system is a geographic coordinate system, calculating the land area of the sub-land parcel using geodetic methods based on the reference ellipsoid parameters corresponding to the geographic coordinate system; when the coordinate reference system is a projected coordinate system, directly calculating the land area of the sub-land parcel based on the geometric objects of the sub-land parcel; and updating the land parcel attributes using the calculated land area. In the implementation of the above scheme, by identifying the coordinate reference system type of the sub-land parcel and calculating the ellipsoid area using geodetic methods based on the reference ellipsoid parameters in the geographic coordinate system, compared with traditional planar area calculation methods, the systematic error caused by the curvature of the Earth is effectively eliminated, thereby improving the accuracy of area calculation and ensuring that the repaired land parcel area data strictly conforms to the requirements of surveying and mapping specifications. On the other hand, by automatically calculating and updating the land area, the compatibility and intelligence level of the above-mentioned soil environmental quality vector data quality inspection method are enhanced, improving the efficiency and reliability of large-scale vector data repair.
[0009] In one implementation of the first aspect, determining the administrative region to which the sub-plot belongs based on its spatial location and the administrative region boundary data includes: calculating a representative point of the sub-plot; wherein the representative point is located within the geometry of the sub-plot; determining a target administrative region surface feature containing the representative point in the administrative region boundary data; and determining the target administrative region surface feature as the administrative region to which the sub-plot belongs when a unique target administrative region surface feature exists. In the implementation of the above scheme, by calculating the representative point located within the geometry of the sub-plot and performing a uniqueness determination based on the spatial inclusion relationship between the representative point and the administrative region boundary data, the topological accuracy and unique certainty of the administrative affiliation determination of the sub-plot are ensured, avoiding affiliation disputes or incorrect matching caused by slight overlap of geometric boundaries or ambiguous spatial relationships near the plot dividing line. Furthermore, by adopting a representative point spatial query mechanism, the computational complexity and resource consumption of spatial relationship determination are reduced, improving the batch processing efficiency of administrative affiliation after large-scale plot division, and achieving efficient integration of real-time attribute updates and automated processes.
[0010] In one implementation of the first aspect, determining the negative buffer plots of the land parcel includes: calculating the shortest distance from each point inside the land parcel to the geometric boundary of the land parcel; and removing points whose shortest distance is not greater than a preset tolerance distance from the land parcel to obtain the negative buffer plots of the land parcel. In the implementation of the above scheme, by calculating the shortest distance from each point inside the land parcel to the geometric boundary and removing edge points whose distance is not greater than the preset tolerance distance, accurate geometric stripping and core area extraction of the negative buffer plots are achieved, ensuring the mathematical rigor and algorithmic feasibility of the negative buffer judgment, and avoiding internal voids or irregular boundaries caused by the complex shape of geometric objects. On the other hand, by constructing negative buffer plots through a point set screening mechanism based on a distance threshold, the above-mentioned soil environmental quality vector data quality inspection method supports batch processing of land parcels of arbitrary shapes, enhancing the adaptability and robustness of the negative buffer algorithm to vector data of different scales and shapes.
[0011] In one implementation of the first aspect, the method further includes: performing at least one of the following checks on the vector data: integrity check, coordinate system check, field check, content check, topology check, and administrative division check, wherein: the integrity check is used to check at least one of the following: file naming standardization, directory structure compliance, GDB format integrity, and land parcel quantity consistency of the vector data; the coordinate system check is used to check whether the coordinate reference system of the vector data conforms to the requirements of the geodetic coordinate system; the field check is used to check at least one of the following: layer compliance, field quantity accuracy, field name standardization, field type correctness, and field length definition compliance of the vector data; the content check is used to check at least one of the following: field value domain validity, land parcel identification code encoding rule compliance, land parcel identification code uniqueness, required field integrity, and element code fixed value compliance of the vector data; the topology check is used to check the geometric overlap between land parcels in the vector data; and the administrative division check is used to check the consistency between the administrative division attributes of land parcels and their spatial locations in the vector data. In the implementation of the above scheme, by integrating six core checks—integrity, coordinate system, fields, content, topology, and administrative divisions—and setting specific normative verification rules for each check, full-dimensional and full-chain automated monitoring of soil environmental quality vector data quality was achieved. This ensured the compliance and integrity of data in key aspects such as file organization, spatial reference, structural definition, attribute content, geometric topology, and logical consistency, avoiding data quality risks caused by inconsistent standards or omissions in traditional manual checks. On the other hand, by coupling multi-dimensional check items with the negative buffer cross-boundary land detection and automatic repair functions, a closed-loop quality management process of detection-diagnosis-repair-verification was constructed. This is conducive to improving the intelligence level and processing efficiency of the above-mentioned soil environmental quality vector data quality inspection method, and enhancing the reliability and decision support capabilities of soil environmental vector data in pollution prevention and control applications.
[0012] Secondly, this application provides a soil environmental quality vector data quality inspection system, including: a data acquisition module and a cross-boundary land parcel identification module connected to the data acquisition module, wherein: the data acquisition module is used to acquire soil environmental quality vector data and administrative region boundary data; the cross-boundary land parcel identification module is used to determine, based on the administrative region boundary data, a first boundary line intersecting with each parcel in the vector data; and to determine the negative buffer parcel of the parcel; wherein the negative buffer parcel is used to characterize a geometric object formed by shrinking the geometric boundary of the parcel inward by a preset tolerance distance and located inside the parcel; if the first boundary line intersects with the negative buffer parcel, the parcel is determined to be a cross-boundary land parcel; otherwise, the parcel is determined to be a non-cross-boundary land parcel.
[0013] Thirdly, embodiments of this application provide an electronic device, including: a processor, a memory, and a communication bus, wherein the processor and the memory communicate with each other through the communication bus; the memory stores computer program instructions that can be executed by the processor, and the computer program instructions are read and executed by the processor to perform the method provided in the first aspect or any possible implementation of the first aspect.
[0014] Fourthly, embodiments of this application provide a computer-readable storage medium storing computer program instructions, which, when read and executed by a processor, perform the method provided in the first aspect or any possible implementation thereof.
[0015] Other features and advantages of this application will be set forth in the following description and will be apparent in part from the description or may be learned by practicing embodiments of this application. The objectives and other advantages of this application may be realized and obtained by means of the structures particularly pointed out in the written description, claims and drawings. Attached Figure Description
[0016] To more clearly illustrate the technical solutions of the embodiments of this application, the accompanying drawings used in the embodiments of this application will be briefly introduced below. It should be understood that the following drawings only show some embodiments of this application and should not be regarded as a limitation of the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0017] Figure 1 A flowchart illustrating the soil environmental quality vector data quality inspection method provided in this application embodiment; Figure 2 A flowchart illustrating the automatic remediation scheme for cross-boundary land parcels provided in this application embodiment; Figure 3 This is a schematic diagram of the structure of the soil environmental quality vector data quality inspection system provided in the embodiments of this application; Figure 4 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Detailed Implementation
[0018] The technical solutions in the embodiments of this application will now be described with reference to the accompanying drawings.
[0019] With the in-depth application of Geographic Information System (GIS) technology, vector data on soil environmental quality of construction land exhibits characteristics of large data scale, complex geometric shape, and multiple attribute dimensions, placing higher demands on the automation and intelligence level of quality inspection technology. Currently, spatial data quality inspection is evolving from the standardization verification of single elements to a comprehensive assessment of integrated quality dimensions such as spatial topological relationships, logical consistency, and geometric accuracy. Among these, the accurate determination of the spatial relationship between land parcels and administrative boundaries has become a focus of industry technical research.
[0020] Existing technical solutions generally suffer from the following drawbacks. First, manual inspection is inefficient and unable to meet the large-scale quality inspection needs of tens of thousands of plots. Furthermore, it relies heavily on the professional experience of inspectors, leading to strong subjectivity and a high rate of false positives and false negatives. Second, traditional automated tools can only perform simple geometric intersection judgments and cannot effectively distinguish between the two topological forms of "contact" and "crossing" between plot boundaries and administrative boundaries. This results in many normal plots with only tangent boundaries being misjudged as cross-boundary plots, while some plots that truly cross administrative boundaries are missed due to complex boundary overlaps, leading to insufficient reliability of the inspection results.
[0021] In view of this, this application provides a method for quality inspection of soil environmental quality vector data. This method improves the spatial relationship detection between land parcels and administrative boundaries from the traditional boundary intersection judgment to the internal crossing judgment by introducing a negative buffer judgment mechanism, thereby improving the accuracy of cross-boundary land parcel identification. On the other hand, through geometric calculation using the negative buffer method, the complex spatial relationship judgment is transformed into a mathematical operation that can be executed precisely, avoiding the subjectivity and inconsistency of manual inspection, thereby improving the quality inspection effect of the above-mentioned soil environmental quality vector data quality inspection method. Furthermore, the above scheme has a small computational load and can quickly process multiple land parcels in batches. Compared with traditional manual inspection or semi-automatic tools, it has higher processing efficiency and can meet the quality inspection needs of regular updates and maintenance of large-scale soil environmental quality vector data.
[0022] Please see Figure 1 The diagram illustrates a flowchart of the soil environmental quality vector data quality inspection method provided in this application embodiment. The soil environmental quality vector data quality inspection method provided in this application embodiment can be applied to electronic devices, which may include physical devices such as servers, PCs, tablets, or smartphones, or virtual devices such as virtual machines or containers. The electronic device can be a single device, a combination of multiple devices, or a cluster of a large number of devices. The above-mentioned soil environmental quality vector data quality inspection method may include: Step S110: Obtain soil environmental quality vector data and administrative region boundary data.
[0023] The aforementioned soil environmental quality vector data refers to a digital description dataset of soil pollution status stored in the form of geometric elements such as points, lines, and surfaces. Its geometric part typically uses polygonal elements to represent the spatial boundaries and morphology of land parcels, while the attribute part records the soil environmental attribute information of each parcel in the form of structured data tables. This dataset is generally organized in a geospatial database format (such as GeoDataBase) and includes fields such as parcel identification code, administrative region code, parcel name, land area, soil pollution risk management and remediation stage, soil environmental quality category, groundwater quality category, soil pollution risk assessment status, and post-management requirements. A spatial reference system is established based on the national geodetic coordinate system to achieve precise parcel location and spatial analysis. Soil environmental quality vector data usually originates from environmental management information systems or soil pollution status survey database platforms, and is generated by professional institutions through operational activities such as detailed soil pollution status surveys, risk assessments, and risk management and remediation effectiveness evaluations. Soil environmental quality vector data is generally collected and generated by technical units with environmental data collection and management qualifications, in accordance with unified data standards and quality control specifications, through methods such as on-site surveying, satellite image interpretation, and digitization of historical archives. It is then centrally stored, updated, and maintained through an environmental data management platform to form a spatial database product of soil environmental quality covering a specific area.
[0024] The aforementioned administrative boundary data refers to a dataset of the spatial extent and administrative jurisdiction boundaries of administrative divisions at all levels, stored in vector format. Its geometric portion typically uses areal features to represent the full spatial coverage of county-level administrative regions, or linear features to precisely describe the jurisdictional boundaries between adjacent administrative regions. This dataset includes key attribute fields such as county-level administrative region codes and names. It is established based on a coordinate system consistent with soil environmental quality vector data and serves as a spatial segmentation benchmark and administrative affiliation reference. It is the core spatial benchmark data for implementing cross-boundary detection of land parcels and verification of administrative division consistency. Administrative boundary data usually originates from standard geographic information data products released by authoritative surveying and mapping geographic information service institutions, or is processed and provided by qualified third-party service providers based on basic geographic information databases. Administrative boundary data can be produced through high-precision satellite remote sensing image interpretation, aerial photogrammetry, ground control point measurement, and integration of administrative region boundary survey results. After rigorous data quality control and topological consistency verification, it forms a vector format administrative division dataset that meets surveying and mapping specifications. This dataset serves as a standard benchmark layer for spatial analysis and is widely used in spatial overlay and affiliation determination in various thematic geographic information systems.
[0025] Electronic devices executing the aforementioned soil environmental quality vector data quality inspection method can load two types of source data via local file system reading or network data interface acquisition. For example, they can directly access GeoDataBase format files stored on local disks or network storage locations by calling geospatial data processing libraries (such as the GDAL / OGR driver engine), use the fiona library to list the spatial layer sets in the GDB database, and then use the geopandas library to read the specified vector layer into a data frame object containing geometric objects and attribute table structures. For administrative boundary data, the same technology stack can be used to read the corresponding GDB format boundary layer. In a distributed deployment scenario, the device can send data requests through standardized spatial data service interfaces (such as OGC WFS service or custom RESTful API), receive GeoJSON or Shapefile format data streams returned by the server, and parse them into a set of geometric features in memory, thereby completing the automated acquisition and preprocessing loading of source data.
[0026] Step S120: Based on the administrative region boundary data, determine the first boundary line that intersects with each plot in the vector data.
[0027] The first boundary line can be determined by at least one of the following methods in step S120 above: The first method: fast intersection query based on R-tree spatial index; The R-tree spatial index described above is a dynamically balanced tree data structure optimized for multidimensional spatial data, widely used in Geographic Information Systems (GIS) and spatial database management systems to accelerate spatial query operations. This index constructs a tree structure by hierarchically organizing the minimum bounding rectangles (MBRs) of spatial objects. Leaf nodes store the MBRs of actual spatial features and pointers to those features, while non-leaf nodes store the aggregated bounding rectangles of their child MBRs and point to those child nodes. The R-tree is constructed following a bottom-up aggregation principle, grouping spatially adjacent features or subtrees to the same parent node, maintaining a balanced tree depth and ensuring stable query efficiency. When performing spatial range queries, the R-tree traverses downwards from the root node, quickly pruning irrelevant branches through intersection tests between MBRs, and performing precise geometric calculations only on candidate leaf nodes. This reduces the time complexity from O(n²) of brute-force enumeration to O(nlogn), lowering I / O overhead and CPU computational load. Furthermore, R-trees support dynamic insertion and deletion operations, enabling efficient handling of spatial datasets updated over time.
[0028] In this approach, an R-tree spatial index structure can be constructed first for the administrative boundary line elements. This structure organizes the minimum bounding rectangle of the boundary line into a tree-like hierarchical system. Then, each parcel element is traversed, and the range query capability of the R-tree is used to quickly retrieve the set of candidate boundary lines that intersect with the parcel boundary range of its minimum bounding rectangle. For each boundary line in the candidate set, a precise geometric intersection calculation is performed, and the boundary lines that have a non-empty intersection with the parcel geometric object are retained as the first boundary lines.
[0029] The second approach: employing a grid space partitioning preprocessing mechanism; In this approach, the spatial extent of administrative boundary data and land parcel data can be divided into grid cells of equal size, establishing a mapping relationship between the grid cells and the two types of spatial features. During intersection queries, the grid set occupied by the land parcel can be determined first, and then only the boundary line features that intersect with the grid set can be loaded for precise geometric intersection judgment. Spatial coarse screening significantly reduces the number of geometric objects involved in the calculation, optimizing I / O overhead and computational load.
[0030] The third approach: a differential processing strategy based on geometry type; In this approach, when administrative boundary data is stored as isal features, the intersection of the plot's isal features and the administrative boundary's isal features can be directly calculated, and the intersection result is converted into a linear geometric object as the first boundary line. When administrative boundary data is stored as linear features, the line-area intersection algorithm is directly used to determine whether the boundary line passes through the interior of the plot. This strategy selects the optimal calculation path based on the geometric type of the data source, reducing unnecessary data format conversions and improving geometric calculation efficiency and result accuracy.
[0031] Step S130: Determine the negative buffer plot of the land parcel; wherein, the negative buffer plot is used to characterize the geometric object formed after shrinking the geometric boundary of the land parcel inward by a preset tolerance distance and located inside the land parcel.
[0032] The aforementioned negative buffer plot refers to the internal core region geometric object extracted from the original plot surface features through topological transformation operations. It is defined as a subset region strictly located within the original plot, formed by shrinking the plot's geometric boundary inwards along the normal direction by a preset tolerance distance. This geometric object is obtained by eliminating all internal point sets whose distance from the plot boundary is less than or equal to the tolerance distance. Essentially, it constitutes the safety kernel of the original plot surface features, ensuring that its boundary maintains spatial isolation from any external geometric object at least within the tolerance distance. At the geometric topology level, the negative buffer plot is the morphological erosion result of the original plot in Euclidean space. Its boundary maintains a constant offset distance from the original plot boundary, which can be used to accurately distinguish the contact and crossing relationships between the external boundary line and the plot. Only when the external boundary line has a non-empty intersection with this internal core region will it constitute a substantial crossing of the plot's interior. This geometric construction serves as the mathematical basis for determining whether a plot is truly divided by administrative boundaries in spatial analysis, effectively eliminating interference from pseudo-crossing situations such as tangent or partially overlapping boundaries.
[0033] Optionally, step S130 may include: calculating the shortest distance from each point inside the plot to the geometric boundary of the plot; removing points whose shortest distance is not greater than a preset tolerance distance from the plot to obtain the negative buffer plot.
[0034] In a projected coordinate system, the aforementioned shortest distance can be determined using Euclidean distance, which is the length of the straight line segment between a point and the nearest point on the boundary. This distance satisfies the Pythagorean theorem in two-dimensional planar space, exhibiting rotational invariance and scale consistency. In a geographic coordinate system, considering the influence of the Earth's curvature, the aforementioned shortest distance can be determined using geodesic distance, which is the length of the shortest great circle arc connecting two points along the surface of the Earth's ellipsoid. This distance is calculated based on geodesic formulas (such as the Vincenty algorithm or the Karney algorithm) and can accurately reflect the true spatial interval between points and line features on the sphere or ellipsoid.
[0035] The implementation method for obtaining the negative buffer plot in step S130 above is as follows: Parse the polygonal geometric object of the plot, obtain the coordinate sequence of all vertices of its outer boundary loop, and generate a discrete point set within the plot at a predetermined resolution, or directly use all coordinate points constituting the polygon as the point set to be processed; then, for each point in the point set, calculate the shortest distance to each line segment of the boundary loop. This distance calculation uses the perpendicular distance from a point to a line segment or the Euclidean distance formula in the projected coordinate system, and calls a geodetic algorithm to calculate the geodesic distance in the geographic coordinate system. After completing the distance calculation, perform a point set filtering operation, removing all points whose shortest distance is less than or equal to a preset tolerance distance, retaining only the internal core point set whose distance to the boundary is greater than the tolerance distance. Finally, based on the filtered retained point set, use a polygon reconstruction algorithm (such as the concave hull algorithm or constrained Delaunay triangulation) to generate a new closed geometric object, which is the negative buffer plot of the original plot. negative buffer plots The definition can be: .in, Points within the plot To the plot boundary The shortest distance; Preset tolerance distance; For negative buffer operators; Indicates land parcel Inward contraction The geometric object obtained after distance.
[0036] After setting the above preset tolerance distance When considering the following factors, one or more of the following can be taken into account: (1) Spatial data accuracy: can be determined based on the geometric accuracy and acquisition error range of soil environmental quality vector data. The lower limit is usually set on the order of coordinate resolution or the smallest cartographic unit to avoid misjudgment due to small amplitude errors introduced by data acquisition, digitization, or coordinate transformation; if If the value is too small, it may not be able to effectively filter out pseudo-cross-boundary situations involving boundary contact. If too large, it will excessively erode the effective area inside the plot, and may miss plots that actually cross boundaries but have shallow crossing depths. (2) Geometric complexity: It can weigh the geometric complexity of the plot against the changes in boundary curvature. For plots with tortuous, narrow, or numerous microstructures, The size can be appropriately reduced to retain sufficient internal core area, ensuring the topological effectiveness of negative buffer plots; conversely, for plots with regular shapes and smooth boundaries, The value can be appropriately increased to improve computational efficiency. (3) Coordinate reference system: The type of coordinate reference system directly affects the distance measurement scale. Under the geographic coordinate system, the coordinate reference system can be increased to improve the computational efficiency. Convert to degrees or radians, and consider the scaling effect of the Earth's ellipsoid curvature on distance calculations, while directly using meters in the projected coordinate system. It is necessary to ensure the consistency of ε's scale across different central meridian projection zones. (4) Calculation stability: The value should match the numerical tolerance of the geometry calculation library to avoid geometry being empty or topological anomalies caused by the precision limitations of floating-point operations.
[0037] Taking a certain application scenario as an example, in this application scenario, a preset tolerance distance can be used. Set as The value of meters was chosen based on the following considerations: (1) This value is much smaller than the actual size of the plot, which is usually on the order of several meters to hundreds of meters in length. The meter is only 0.1 micrometers, which will not have a substantial impact on the geometry of the land parcel; (2) This value is greater than the rounding error of floating-point calculation, and the machine precision of IEEE 754 double-precision floating-point number is approximately The cumulative error in coordinate calculation is usually in meter level The value can effectively overcome numerical calculation errors; (3) This value can effectively distinguish between true boundary crossing and small deviations caused by coordinate discretization.
[0038] The above scheme achieves precise geometric stripping and core area extraction of negative buffer plots by calculating the shortest distance from each point inside the plot to the geometric boundary and removing edge points whose distance is not greater than a preset tolerance distance. This ensures the mathematical rigor and algorithmic feasibility of the negative buffer judgment and avoids problems such as internal voids or irregular boundaries caused by the complex shape of geometric objects. On the other hand, by constructing negative buffer plots through a point set screening mechanism based on a distance threshold, the above-mentioned soil environmental quality vector data quality inspection method supports batch processing of plots of arbitrary shapes, enhancing the adaptability and robustness of the negative buffer algorithm to vector data of different scales and shapes.
[0039] Step S140: If the first boundary line intersects with the negative buffer parcel, the parcel is determined to be a cross-boundary parcel; otherwise, the parcel is determined to be a non-cross-boundary parcel.
[0040] Step S140 above can determine whether the first boundary line intersects with the negative buffer plot based on geometric intersection operation. Specifically: for the first boundary line With the plot of land negative buffer plots Perform a set intersection operation to calculate the geometric intersection of the two sets. Intersection operations can be performed by calling the `intersection` method in the geometry calculation engine. This method uses a scan-line algorithm and boundary representation transformation technique to accurately calculate the shared spatial portion between two geometric objects. If the intersection result is a non-empty set, then... Characterizing the first boundary line With negative buffer plots If at least one common point or line segment exists, the boundary line is determined to cross the interior of the land parcel, and the land parcel is considered a transboundary land parcel; otherwise, if the intersection result is an empty set, i.e. Characterizing the first boundary line With negative buffer plots If the land parcels are spatially separated, the boundary line is determined to be either in contact with the land parcel boundary or not intersecting at all. In this case, the land parcel is a correctly divided non-cross-boundary land parcel.
[0041] Understandably, the above scheme forms an internal fidelity region after stripping the thin edge layer by shrinking the original land parcel boundary inward along the normal direction by a preset tolerance distance. This region topologically excludes all point sets whose distance from the boundary is less than the tolerance distance, thus effectively isolating edge contact situations that are susceptible to interference from boundary micro-overlap or digital precision errors. When the external administrative boundary line interacts with the land parcel, if it is only tangent or partially coincident, its geometric trajectory will be limited to the area of the removed thin edge layer and cannot intersect with the internal core area. Conversely, if the boundary line substantially crosses the interior of the land parcel, it will penetrate the thin edge layer and enter the internal core area, forming a non-empty geometric intersection with the negative buffer land parcel. Therefore, by detecting the intersection relationship between the boundary line and the negative buffer land parcel, the problem of determining spatial topological relationships can be transformed into a distance measurement problem of boundary crossing depth. Using whether it intrudes into the internal core area as the criterion for cross-boundary determination, this solves the technical deficiency of traditional methods that cannot quantitatively distinguish between contact and crossing, and achieves robust judgment of the cross-boundary status of land parcels.
[0042] Please see Figure 2 Optionally, the above-mentioned methods for quality inspection of soil environmental quality vector data may also include: Step S210: When a land parcel is determined to be a transboundary land parcel, a second boundary line is determined within the first boundary line that crosses the land parcel.
[0043] Although the aforementioned first boundary line has been determined to have crossing behavior through negative buffer detection, its set may contain redundant line segments that only have minor regional intersections or local contacts with negative buffer plots. If such boundary lines are directly used for segmentation, it may lead to the generation of unexpected fragmented polygons or segmentation failure. Therefore, a secondary geometric verification can be performed on each line segment in the first boundary line to select the boundary lines that actually cross plots as the second boundary lines.
[0044] Step S220: Merge the second boundary line into a plot dividing line.
[0045] Step S220 above merges multiple scattered second boundary lines into a single parcel dividing line, aiming to eliminate geometric redundancy and ensure the topological integrity and geometric continuity of the dividing trajectory during the dividing process. Although the second boundary lines are a set of administrative boundaries that cross the parcels, they may consist of multiple spatially adjacent but geometrically separate line segments. If they are used directly for dividing without merging, it will lead to repeated cutting, micro-fragmented polygons, or unexpected topological errors at the junctions of the boundary lines. By performing topological fusion on the second boundary lines using a geometric merging operation, spatially adjacent line segments can be fused into continuous and non-overlapping line features, forming a single geometric line object that conforms to the dividing input specifications. This merging not only eliminates redundant endpoints and micro-overlaps, ensuring the overall continuity and consistent direction of the dividing trajectory, but also avoids geometric fragments or isolated polygons caused by discontinuities in the input line features during iterative dividing. This ensures that the parcel dividing results form independent and closed sub-parcel polygons in terms of topology, while simplifying the complexity of dividing calculations and improving the execution efficiency of batch processing.
[0046] The above scheme can merge the second boundary line into a plot dividing line in at least one of the following ways: The first approach: geometric merging based on topological fusion operators; This method can directly call the merging functions such as unary_union or cascaded_union in the geometry processing library, take the multi-line set formed by the second boundary line as input, and the operator automatically performs spatial proximity analysis, overlap elimination and endpoint connection, and outputs a single line feature with consistent topology and no redundancy.
[0047] The second approach: employing a node fusion and edge reconstruction strategy; This method can extract the endpoint coordinates of all second boundary line segments and construct a point set; then, through spatial clustering or distance threshold determination, neighboring endpoints with Euclidean distance less than a preset threshold are merged into the same logical node to complete node deduplication; finally, based on the connection relationship between the fused node set and the original line segments, a graph traversal algorithm (such as depth-first search) is used to regenerate a connected string of lines as the plot dividing line.
[0048] The third method: Indirect merging method based on buffer-boundary extraction; This method performs a small-radius buffer operation on the second boundary line set, expanding the linear features into planar strips; then, it performs a polygon merging operation on the generated planar strips to form a single connected surface; finally, it extracts the outer boundary line of the merged surface as the parcel dividing line.
[0049] Step S230: Use the land parcel dividing lines to geometrically divide the land parcel to obtain at least one sub-land parcel of the land parcel.
[0050] Step S230 above utilizes parcel dividing lines to geometrically segment the parcels, aiming to achieve spatial reconstruction and atomization of administrative affiliation for cross-boundary parcels, generating geometric topological units that conform to administrative division standards. By using dividing lines as cutting trajectories to perform spatial segmentation operations on the original parcel polygons, the geometric objects of the parcels can be precisely split at the locations where administrative boundaries cross, generating several independent, closed-boundary, and non-overlapping sub-parcel polygons. This segmentation process not only completes the physical reconstruction of the geometric form but also refines the spatial granularity of the parcels, ensuring that each sub-parcel belongs entirely to a single administrative jurisdiction, thereby eliminating cross-boundary logical contradictions at the geometric level. The sub-parcels generated after segmentation inherit the topological validity of the original parcels, with their boundaries strictly adhering to administrative boundaries and satisfying polygon closure requirements. This lays a precise spatial foundation for subsequent administrative affiliation determination, attribute field cascading updates, and data standardization processing, ensuring that the restoration results conform to the data entry standards and application specifications for soil environmental quality vector data in both geometric and attribute dimensions.
[0051] The above scheme can geometrically divide the land parcel using at least one of the following methods: The first method: Direct segmentation based on geometric segmentation operators; This method takes the plot polygons and plot dividing lines as input, calls the split function in the geometry processing library, and internally performs intersection calculations between line segments and polygons, intersection point insertion, polygon decomposition, and topological reconstruction, outputting a set of split polygons. This method relies on mature computational geometry algorithms, which can automatically handle the calculation of intersection points between line segments and polygon boundaries, polygon traversal, and ring organization, ensuring that the segmentation results are topologically closed and mutually exclusive.
[0052] The second method: using the reverse application of the polygon clipping algorithm; This method treats the plot polygons as the objects to be clipped. Half-plane clipping regions are formed on both sides of the plot dividing line. A polygon clipping algorithm (such as the Sutherland-Hodgman or Weiler-Atherton algorithm) is used to iteratively clip the plots, generating independent polygons located on both sides of the dividing line. This method is based on vertex traversal and boundary classification, explicitly handling the intersection determination of the clipping edge with each edge of the clipped polygon and the selection of vertices.
[0053] The third approach: based on planar subdivision and polygon reconstruction strategies; This method first embeds the plot polygons and plot dividing lines into a planar space, then applies constrained Delaunay triangulation to the composite geometric object formed by the two, generating a triangular mesh covering the entire area. Next, the triangles are grouped and labeled according to their spatial relationship with the dividing lines (intersecting or lateral). Finally, adjacent triangles belonging to the same group are subjected to polygon extraction and boundary tracing, and merged to generate several closed sub-polygons as the segmentation result. This method achieves refined segmentation of complex geometry through the intermediate representation of the triangular mesh, and can stably handle non-standard geometric cases such as self-intersecting dividing lines, multiple points, or plots containing holes, ensuring the topological robustness and geometric integrity of the segmentation result.
[0054] Step S240: For each sub-plot, based on the spatial location and administrative boundary data of the sub-plot, determine the administrative region to which the sub-plot belongs, and update the plot attributes of the sub-plot.
[0055] The above step S240 can determine the administrative region to which the sub-plot belongs through at least one of the following methods: The first method: based on the spatial inclusion determination of representative points; Optionally, step S240 above determines the administrative region to which the sub-plot belongs based on the spatial location and administrative region boundary data of the sub-plot, including: calculating a representative point of the sub-plot; wherein the representative point is located within the geometry of the sub-plot; determining the target administrative region surface feature containing the representative point in the administrative region boundary data; when there is a unique target administrative region surface feature, determining the target administrative region surface feature as the administrative region to which the sub-plot belongs.
[0056] The aforementioned representative points refer to the reference coordinate points extracted from the geometric objects of sub-plots, strictly located within them, and capable of stably representing the overall spatial position of the geometry. In vector geometric operations, representative points can be selected from the topological centroid of the sub-plot polygon, i.e., the point determined by the arithmetic mean of the polygon's vertex coordinates, or geometrically internal points calculated by the algorithm when the centroid falls exactly outside the polygon, ensuring that they are always within the closed region enclosed by the polygon boundary. Representative points can serve as spatial proxies for sub-plots, used to perform efficient spatial inclusion queries and administrative attribution determinations, avoiding the high computational overhead and topological ambiguity caused by directly using complex polygon boundaries for spatial relationship calculations. The selection of representative points must meet the principles of uniqueness, stability, and internality, meaning that the representative points generated for the same geometric object in different computational environments should remain consistent and unaffected by minor deformations of the polygon boundaries, thereby ensuring the repeatability and reliability of the administrative attribution determination for sub-plots.
[0057] The above method uses the topological centroid or representative interior point of the sub-plot's geometric object as the location anchor point to ensure that the point is strictly located inside the sub-plot and can stably represent its spatial location. Then, the spatial index structure is used to query the administrative boundary data to locate the county-level surface feature containing the representative point. When the query result is unique, the administrative code and administrative name corresponding to the surface feature are directly assigned as the administrative affiliation attribute of the sub-plot.
[0058] The above scheme calculates representative points located within the geometry of sub-plots and makes uniqueness determination based on the spatial inclusion relationship between these representative points and administrative boundary data. This ensures the topological accuracy and unique certainty of the administrative affiliation determination for sub-plots, avoiding affiliation disputes or incorrect matching caused by slight overlap of geometric boundaries or ambiguity of spatial relationships near the plot dividing line. On the other hand, by adopting a representative point spatial query mechanism, the computational complexity and resource consumption of spatial relationship determination are reduced, the batch processing efficiency of administrative affiliation after large-scale plot division is improved, and the real-time nature of attribute updates and the efficient connection of automated processes are achieved.
[0059] The second method: Determined based on the principle of maximizing area proportion; This method performs geometric intersection operations on each sub-plot and the surface elements of each county-level administrative region to calculate the area of the overlapping part between the sub-plot and each administrative region; compares the size of each overlapping area, and determines the administrative region to which the sub-plot belongs by having the largest overlapping area that exceeds a preset proportion threshold (e.g., 50%).
[0060] The third method: based on the location and determination of the largest inscribed circle center; This method calculates the maximum inscribed circle that can be accommodated inside the polygon of the sub-plot, and determines the coordinates of its center as the core location point of the sub-plot. Since the center of the inscribed circle must be located inside the polygon and is farthest from all boundaries, it has the highest spatial stability. Then, the administrative area features where the center of the circle is located are queried as the ownership of the sub-plot.
[0061] The above scheme merges the second boundary lines identified by the negative buffer into plot dividing lines, and uses this to geometrically divide cross-boundary plots. It can accurately divide plots along administrative boundaries, and then automatically determine the administrative region to which the sub-plots belong and update their attribute information based on their spatial location. This eliminates the tedious operation of manually dividing and editing attributes one by one in relevant software after detecting problems in traditional methods. The automated repair mechanism in the above scheme can process all cross-boundary plots identified by quality inspection in batches, thereby improving the repair efficiency of cross-boundary plots and reducing labor and time costs. On the other hand, by using the actual crossing boundary determined by the negative buffer as the dividing benchmark, the topological accuracy of the dividing position is guaranteed, avoiding geometric deviations introduced by manual operation, which is conducive to improving the repair effect of vector data.
[0062] Optionally, the above-mentioned land parcel attributes include a land parcel identifier. The above-mentioned step S240 of updating the land parcel attributes of the sub-land parcel includes: extracting a prefix character of a preset number of digits from the administrative region code of the administrative region to which the sub-land parcel belongs, and obtaining a first code segment; determining a fixed intermediate code of the land parcel identifier, and obtaining a second code segment; determining the serial number of the sub-land parcel based on the serial number of existing land parcels within the administrative region to which the sub-land parcel belongs; determining a third code segment based on the serial number of the sub-land parcel; generating a land parcel identifier of the sub-land parcel based on the first code segment, the second code segment, and the third code segment; and updating the land parcel attributes of the sub-land parcel using the generated land parcel identifier.
[0063] The aforementioned land parcel identifier is a unique, structured coded identifier assigned to each land parcel element in the soil environmental quality vector data. It is used to achieve precise location, traceability, and management of land parcels throughout the data's entire lifecycle. In terms of coding structure, the land parcel identifier adopts a segmented string construction, consisting of three segments sequentially concatenated: an administrative region code prefix (first segment), a fixed intermediate code (second segment), and a serial number (third segment). For example, the land parcel identifier can use an 18-bit coding structure, defined as: , , ,in, This represents the string concatenation operation. This indicates the administrative region code prefix, which is also the first code segment. This indicates that the first 6 characters of the administrative region code XZQDM field are extracted as the administrative region prefix; This indicates a fixed intermediate code, also known as the second code segment; This represents an 8-digit serial number, also known as the third code segment. For an 8-digit decimal string, the serial number generation scheme can be as follows: Let the set of existing land parcels within the administrative region be... This includes existing land parcels and newly generated land parcels, from each land parcel Extracting the serial number from the BSM: Convert the serial number to an integer: ; Calculate the maximum serial number: Therefore, the new serial number for the aforementioned sub-plot can be set as follows: Format the new serial number as an 8-character string: If the number of bits is less than 8, pad with leading zeros. The final generated BSM is: For example: if XZQDM is 510100000000, then... If the maximum serial number of the existing land parcel is 123, then the new serial number of the sub-parcel can be configured as follows: , The new BSM is .
[0064] The above solution ensures that the land parcel identifiers of the sub-parcels are globally unique, have standardized coding, and are continuous within their respective administrative regions by extracting the administrative region code prefix, fixing the intermediate code, and automatically generating new serial numbers based on existing land parcel serial numbers. This avoids duplicate identifiers or coding errors caused by manual intervention. On the other hand, it achieves full automation of land parcel identifier generation, eliminating the need for manual compilation and verification, significantly improving identifier allocation efficiency. At the same time, it ensures a strict correspondence between identifiers and administrative divisions, enhancing the traceability and management standardization of the restored data.
[0065] Optionally, the aforementioned land parcel attributes include land area. Step S240, updating the land parcel attributes of the sub-parcel, includes: obtaining the coordinate reference system of the sub-parcel; when the coordinate reference system is a geographic coordinate system, calculating the land area of the sub-parcel using geodetic methods based on the reference ellipsoid parameters corresponding to the geographic coordinate system; when the coordinate reference system is a projected coordinate system, directly calculating the land area of the sub-parcel based on the geometric objects of the sub-parcel; and updating the land parcel attributes using the calculated land area. For example, this implementation involves: first obtaining the coordinate reference system (CRS) of the vector data and determining whether it is a geographic coordinate system; if it is a geographic coordinate system, then extracting the ellipsoid parameters corresponding to the coordinate system, including the semi-major axis. and flatness Geod objects are constructed based on ellipsoidal parameters. For polygons defined by a sequence of latitude and longitude coordinates: ,in, Indicates longitude. This represents latitude. The ellipsoidal area is calculated using the trapezoidal rule in geodesy, which decomposes the polygon into a series of geodetic quadrilaterals. The area of each quadrilateral is calculated using surface integrals on the ellipsoidal surface. The formula is: ,in, This represents the projection region of the polygon onto the ellipsoid. This represents the radius of curvature of the ellipsoid at that point. Alternatively, the ellipsoid area can be calculated by calling the `geometry_area_perimeter` method of the geodetic object. This method performs high-precision calculations based on the Vincenty or Karney algorithm, returning the ellipsoid area and perimeter, with the absolute value of the area taken as the final result. If it is a projected coordinate system, the planar area can be directly obtained using the `area` attribute of the geometric object.
[0066] The above-mentioned scheme identifies the coordinate reference system type of sub-plots and calculates the ellipsoid area using geodetic methods based on the reference ellipsoid parameters in the geographic coordinate system. Compared with traditional planar area calculation methods, it effectively eliminates systematic errors caused by the curvature of the Earth, thereby improving the accuracy of area calculation and ensuring that the area data of the restored plots strictly meets the requirements of surveying and mapping specifications. On the other hand, by automatically calculating and updating the land use area, the compatibility and intelligence level of the above-mentioned soil environmental quality vector data quality inspection method are enhanced, improving the efficiency and reliability of large-scale vector data restoration.
[0067] In addition to the land parcel identification and land area, step S240 can also synchronously update the administrative division attributes of the sub-land parcels, including updating the XZQDM administrative district code and XZQMC administrative district name fields to accurately reflect the new administrative affiliation after the sub-land parcels are divided. In addition, the attribute field values of the original plot can be retained unchanged, such as: plot name (DKMC), plot code (DKDM), use code (YSDM), soil pollution risk management and remediation stage (DKTRWRFXGKHXFJD), completion time (TRWRFXGKHXFJDWCSJ), soil environmental quality (TRHJZL), groundwater quality (DXSZL), soil pollution risk assessment status (TRWRFXPGQK), list management status (TRWRFXGKHXFMLGLQK), data update time (DKSJZXGXSJ), post-management requirements (HQGLYQ), remarks (BZ), and geometric feature fields (Shape_Length, Shape_Area), etc., to ensure that the sub-plots inherit the business context and survey results of the original plots, maintain the integrity and traceability of the data chain, and meet the strict requirements of soil environmental management for the continuity of plot attributes.
[0068] Optionally, the above-mentioned quality inspection method for soil environmental quality vector data may further include: performing at least one of the following checks on the vector data: integrity check, coordinate system check, field check, content check, topology check, and administrative division check, wherein: Integrity checks are performed to verify at least one of the following: file naming conventions, directory structure compliance, GDB format integrity, and consistency of the number of land parcels in the vector data. Coordinate system check is used to check whether the coordinate reference system of vector data conforms to the requirements of the geodetic coordinate system. Field checks are used to check at least one of the following for vector data: compliance with layer specifications, accuracy of field quantity, standardization of field names, correctness of field types, and compliance of field length definitions. Content checks are used to check at least one of the following in vector data: validity of field value ranges, compliance of parcel identification code coding rules, uniqueness of parcel identification codes, completeness of required fields, and compliance of fixed values of feature codes. Topology check is used to check for geometric overlap between parcels in vector data; Administrative division check is used to check the consistency between the administrative division attributes of each plot in vector data and its spatial location.
[0069] The following sections describe each of the above inspections: I. Integrity Check: The integrity check aims to verify the basic structural integrity and delivery compliance of soil environmental quality vector data at the file system level and container format level. It mainly includes file naming check, file organization check, GDB format check and quantity check, among which: (1) File naming check: Through regular expression matching or string pattern comparison, verify whether the naming of electronic result data files conforms to the established naming specifications, and ensure that the file name contains necessary meta-information such as timestamp, regional code, and data version and follows the unified naming convention. (2) File organization check: Based on the preset directory tree template, recursively scan the directory hierarchy structure of the submitted data, verify whether the naming, existence and interrelationship of each level of subdirectories meet the specification requirements, and ensure the logicality and retrieval of data archiving. (3) GDB format check: For the geodatabase container, by parsing the binary structure or metadata of the system table files, data table files, and spatial index files under the GDB directory, the necessary core files (such as .gdbtable, .gdbtablx, .spx, etc.) are verified to be complete and undamaged. At the same time, the integrity of the spatial reference system definition, domain definition, and relation class definition is checked to ensure the soundness of the geodatabase in terms of physical storage and logical structure. (4) Quantity check: By comparing the total number of submitted land parcel elements with the soil pollution status survey list or the previous period's results database, the set difference operation is used to identify missing or redundant land parcel identifiers, verifying the coverage integrity and incremental update consistency of the dataset, thereby ensuring the completeness and business integrity of vector data deliverables from a macro perspective. The file naming check and file organization check in the above check items can be checked manually, while the GDB format check and quantity check can be implemented through automated scripts.
[0070] II. Coordinate System Check: The coordinate system check aims to verify whether the coordinate reference system of the soil environmental quality vector data strictly conforms to the technical requirements of the CGCS2000 National Geodetic Coordinate System. This check first extracts the coordinate reference system definition from the spatial metadata of the dataframe object, and then uses the pyproj library to parse the coordinate system object to obtain the standard EPSG code. Subsequently, the check logic confirms the coordinate system compliance by determining whether the code belongs to the valid code set of the CGCS2000 coordinate system: EPSG code 4490 corresponds to the CGCS2000 geographic coordinate system, while codes 4525, 4526, 4527, and 4547 correspond to 3-degree zone Gauss-Kruger projection coordinate systems using different central meridians (such as 105°E, 108°E, and 111°E).
[0071] III. Field Inspection: The purpose is to comprehensively verify the structural definition and field metadata standardization of soil environmental quality vector data, including five dimensions: layer compliance, field quantity accuracy, field naming standardization, field type correctness, and field length definition rationality. Among them: (1) Layer Inspection: By comparing the consistency between the actual layer name and the remarks requirements, it is ensured that the processed data layer meets the specified requirements of the business scenario. (2) Field quantity check: Verify whether the data table accurately contains 18 standard fields, specifically including BSM land parcel identification code, YSDM land use code, XZQDM administrative region code, XZQMC administrative region name, DKMC land parcel name, DKDM land parcel code, YDMJ land area, DKTRWRFXGKHXFJD land parcel soil pollution risk control and remediation stage, TRWRFXGKHXFJDWCSJ completion time, TRHJZL soil environmental quality, DXSZL groundwater quality, TRWRFXPGQK soil pollution risk assessment status, TRWRFXGKHXFMLGLQK directory management status, DKSJZXGXSJ data update time, HQGLYQ post-management requirements, BZ remarks, and geometric feature fields Shape_Length perimeter and Shape_Area area. Any missing or redundant fields are considered structural errors. (3) Field name check: Verify that the naming of each field is completely consistent with the standard definition, and eliminate spelling errors or non-standard naming issues. (4) Field type check: This mainly checks whether the data type of each field meets the specification requirements. Specifically, identification fields such as BSM, YSDM, and XZQDM should be string types, measurement fields such as YDMJ, Shape_Length, and Shape_Area should be floating-point types, and time fields such as TRWRFXGKHXFJDWCSJ and DKSJZXGXSJ should be date and time types. Field length definition check: By reading the GDB schema definition, the length constraints (such as the upper limit of the number of characters) of string type fields are parsed to ensure that they are consistent with the length definition required by the specification, and to prevent attribute values from being truncated due to the field length being too short. (5) Area field type check: Specifically for the YDMJ land area field, it is verified whether it is a numerical type that can participate in numerical calculations, so as to ensure the correct execution of subsequent numerical operations such as area calculation and statistical analysis, and to avoid calculation anomalies caused by incorrect types.
[0072] IV. Content Inspection: The purpose is to verify the domain integrity, coding compliance, uniqueness constraints and mandatory requirements of vector data attribute values, covering five dimensions: enumeration value verification, coding rule verification, uniqueness verification, mandatory requirement verification and fixed value matching. Among them: (1) Value domain inspection: Domain constraint verification is implemented for code type fields: For enumeration type fields, the allowed value set is clearly defined and outside assignment is prohibited. For example, the DKTRWRFXGKHXFJD field is only allowed to take the values 01 risk screening, 02 risk assessment, 03 risk control, 04 repair, 05 risk control effect assessment, 06 repair effect assessment, 07 post-management, 08 removal, 09 other. The TRHJZL field is limited to the values 01 priority control class, 02 safe utilization class, 03 strict control class, 04 not developed and utilized for the time being, 05 not divided, 06 other. The DXSZL field is limited to the values 01 priority control class, 02 safe utilization class, 03 strict control class, 04 not developed and utilized for the time being, 05 not divided, 06 other. Values are limited to 01 priority control category, 02 safe utilization category, 03 strict control category, and 04 unclassified. The TRWRFXPGQK field is limited to 01 implemented, 02 not implemented, 03 not applicable, and 04 other. The TRWRFXGKHXFMLGLQK field is limited to 01 included, 02 not included, and 03 other. For numerical range fields, legal closed intervals are defined and out-of-bounds values are rejected. For example, the DKDM field has a value range of 5100000000000 to 5200000000000, and the YDMJ field has a value range of 0.00 to 10000000000.00. (2) BSM encoding rule check: The compliance of the identifier code structure is verified by pattern matching. The field value is required to be an 18-bit string, and the first 6 bits must be consistent with the first 6 bits of XZQDM, the 7th to 10th bits must be a fixed value of 0000, and the 11th to 18th bits must be 8-bit numeric codes. (3) BSM uniqueness check: Duplicate items are identified through frequency statistics. If a BSM code appears more than once in the dataset, it is determined that there is a duplicate identification error. (4) Required field check: Data completeness is ensured through null value detection. Except for TRWRFXGKHXFJDWCSJ completion time, HQGLYQ post-management requirements, and BZ remarks, which are allowed to be null, all other fields must not have null values. (5) YSDM fixed value check: The correctness of the feature code is verified through exact matching. The field value must be a fixed string 2080050600. Any deviation is determined to be a code assignment error.
[0073] V. Topology Check: This section aims to verify the geometric topological integrity of vector data and the spatial exclusivity between plot elements, focusing on plot overlap detection and geometric validity determination. The `is_valid` attribute of the `shapely` library can be used to verify the topological validity of each plot polygon. If invalid geometric conditions such as self-intersection or incorrect loop direction are found, a geometric repair mechanism is triggered to eliminate topological defects. For plot overlap detection, a two-stage efficient query strategy based on an R-tree spatial index is adopted: First, an R-tree index covering the minimum bounding rectangle of all plots is pre-built, optimizing the spatial query time complexity from O(n²) of brute-force enumeration to O(nlogn). Then, for each plot, the index is used to quickly retrieve a subset of candidate plots whose boundaries intersect, and precise geometric intersection calculations are performed to confirm true overlap. The degree of overlap is quantified using the overlap rate calculation formula: .in, and These represent the geometric objects of the two plots of land. This represents the area calculation function; This represents the intersection operation of sets. This formula achieves a relative measure of overlap intensity by normalizing the intersection area to a smaller plot area. A preset threshold is set. As a criterion for determining effective overlap, only when the intersection area exceeds 1% of the smaller plot area is it considered a substantial overlap. This measure can effectively filter out micro-overlap artifacts caused by numerical accuracy errors or digital tolerances.
[0074] Furthermore, a semantic annotation mechanism is used to distinguish the reasonableness of overlaps: if the BZ remarks field of overlapping plots contains the words "reasonable overlap", it is determined to be a reasonable overlap that conforms to the business scenario; otherwise, it is determined to be an unreasonable overlap that violates the principle of spatial mutual exclusion, and an error message is output for manual verification. This inspection mechanism establishes a balance between topological constraints and business rules, ensuring both the rigor of data geometric logic and providing flexible handling space for specific exceptions.
[0075] VI. Administrative Division Check: This check aims to verify the consistency and accuracy of the matching between the administrative division attribute field values of the land parcels and their spatial locations. The core judgment strategy for this check is the representative point spatial inclusion method: First, the administrative boundary data is read to obtain the county-level polygon layer, ensuring that it is consistent with the vector data to be checked in the coordinate reference system to avoid spatial query errors caused by coordinate system differences; then, a spatial index structure is constructed for the county-level polygon layer to optimize subsequent query efficiency. When traversing each land parcel feature, the topological centroid or representative interior point of its geometric object is calculated as the spatial location anchor point, and the county-level polygon feature containing the representative point is quickly retrieved through the spatial index. When a unique county-level polygon contains the representative point, the administrative code (XZQDM) and administrative name (XZQMC) attributes of the county-level polygon are extracted, and a double consistency check is performed: on the one hand, it verifies whether the XZQDM field value of the land parcel completely matches the XZQDM code of the county-level polygon or satisfies the prefix consistency rule; on the other hand, it checks whether the XZQMC field of the land parcel matches the XZQMC name of the county-level polygon. If a land parcel's representative point does not fall within any county-level area, is located within multiple county-level areas, or has an attribute field value that is inconsistent with the standard code name of its county-level area, it is determined to be an incorrect administrative division attribute. This check item uses a dual constraint mechanism of spatial location verification and attribute value comparison to ensure that the land parcel has the correct administrative affiliation in both geometric space and attribute semantic dimensions, thereby eliminating data logic contradictions caused by incorrect assignment of administrative division codes or spatial misalignment.
[0076] The aforementioned integrity checks, coordinate system checks, field checks, content checks, topology checks, and administrative division checks constitute a modular and configurable quality inspection system, supporting flexible strategies for independent and combined execution. Based on factors such as data delivery stage, quality inspection level requirements, or differences in business scenarios, specific inspection items can be dynamically enabled or disabled through inspection item configuration files or user interface parameter selection, enabling on-demand switching from single-item checks to comprehensive quality inspection. In terms of execution mode, a serial pipeline approach can be used to execute items sequentially according to a preset logical order to avoid state conflicts and data dependency issues. Alternatively, a parallel computing framework can be used for distributed acceleration of unrelated inspection items (such as coordinate system checks and field checks), thereby optimizing computing resource utilization and overall processing latency while ensuring the comprehensiveness and accuracy of the checks.
[0077] The aforementioned solution integrates six core checks—integrity, coordinate system, fields, content, topology, and administrative divisions—and sets specific normative verification rules for each check. This achieves full-dimensional, end-to-end automated monitoring of soil environmental quality vector data quality, ensuring compliance and integrity in key aspects such as file organization, spatial reference, structural definition, attribute content, geometric topology, and logical consistency. This avoids data quality risks caused by inconsistent standards or omissions in traditional manual checks. Furthermore, by coupling multi-dimensional check items with negative buffer cross-boundary land detection and automatic repair functions, a closed-loop quality management process of detection-diagnosis-repair-verification is constructed. This improves the intelligence level and processing efficiency of the aforementioned soil environmental quality vector data quality inspection method, enhancing the reliability and decision support capabilities of soil environmental vector data in pollution prevention and control applications.
[0078] Based on the same inventive concept, this application also provides a soil environmental quality vector data quality inspection system 300, comprising: Data acquisition module 310 is used to acquire soil environmental quality vector data and administrative region boundary data; The cross-boundary land parcel identification module 320 is used to determine the first boundary line intersecting with each parcel in the vector data based on administrative region boundary data; and to determine the negative buffer parcels of the parcels; wherein, the negative buffer parcels are used to characterize the geometric objects formed by shrinking the geometric boundary of the parcels inward by a preset tolerance distance and located inside the parcels; if the first boundary line intersects with the negative buffer parcels, the parcels are determined to be cross-boundary parcels, otherwise, the parcels are determined to be non-cross-boundary parcels.
[0079] Optionally, the aforementioned soil environmental quality vector data quality inspection system 300 also includes: The automatic repair module 330 is used to determine the second boundary line that crosses the land parcel in the first boundary line when the land parcel is determined to be a cross-boundary land parcel; merge the second boundary line into a land parcel dividing line; use the land parcel dividing line to geometrically divide the land parcel to obtain at least one sub-land parcel; for each sub-land parcel, determine the administrative region to which the sub-land parcel belongs based on the spatial location and administrative region boundary data of the sub-land parcel, and update the land parcel attributes of the sub-land parcel.
[0080] It is understood that the soil environmental quality vector data quality inspection system 300 provided in this application embodiment can be used to execute the soil environmental quality vector data quality inspection method provided in this application embodiment. Its implementation principle and the resulting technical effects have been introduced in the foregoing method embodiment. For the sake of brevity, any part not mentioned in the device embodiment can be referred to the corresponding content in any of the foregoing method embodiments.
[0081] Please see Figure 3To facilitate understanding of the working principle of the soil environmental quality vector data quality inspection system 300, an application case of the system in a specific application scenario is provided below. In this scenario, the soil environmental quality vector data quality inspection system 300 may include: The data acquisition module 310 is responsible for reading the GDB format vector data and administrative boundary data to be inspected. The system can use the Fiona library to list the layers in the GDB, use the geopandas library to read the layer data, obtain a data frame object containing geometric objects and attribute data, and separate the geometric data and attribute data for subsequent spatial and attribute inspections.
[0082] The cross-boundary land parcel identification module 320 distinguishes between contact and crossing of the land parcel boundary by applying a negative buffer to the geometric boundary of the parcel. This solves the technical problem that traditional geometric intersection judgment cannot distinguish between boundary contact and internal crossing. The aforementioned cross-boundary land parcel identification module 320 first reads administrative region boundary data to obtain a county-level boundary line layer, ensuring that the coordinate reference system of the vector data and the boundary line layer is consistent, and establishes a spatial index for the boundary line layer. Then, it traverses each land parcel element in the vector data, querying boundary line elements that intersect with the boundary range of that land parcel based on the spatial index. For each queried boundary line, the system performs a negative buffer judgment to determine whether the boundary line crosses the interior of the land parcel. Let the land parcel... The geometric boundary is Define the negative buffer operator for: .in, Point to the border The shortest distance, Preset tolerance distance. Negative buffer. Indicates land parcel Inward contraction The geometric object obtained after distance. Let the administrative region boundary line be... The judgment criterion is defined as: if Then determine the boundary line. Crossing plots Within the territory, the land parcel is not divided according to administrative boundaries. If Then determine the boundary line. If the land parcel only touches or does not intersect with the parcel boundary, the parcel has been correctly divided. The above-mentioned preset tolerance distance can be set as follows: .
[0083] The automatic repair module 330 employs a geometric segmentation algorithm, which is the core technology for achieving accurate land parcel segmentation. The automatic repair module 330 first uses a negative buffer judgment method to identify all cross-boundary land parcels, and then collects all boundary lines crossing each cross-boundary land parcel. Let the land parcels be... The geometric objects are The set of boundary lines crossing this plot is The system uses the geometric merging operator `unary_union` to merge the set of boundary lines into a single dividing line: Then, the geometric splitting operator is used to divide the land parcel into a set of sub-parcels: Each of them This represents a geometric object of a sub-plot after the land parcel has been divided. For each sub-plot... Calculate its representative point: The representative point is guaranteed to be located inside the geometric object and represent the spatial position of the geometric object. The county-level surface where the representative point is located is determined through spatial inclusion relationships. Let the set of county-level surfaces be denoted as . If there is a unique county-level surface Make: Then extract The administrative district attributes of the sub-plots are updated using the XZQDM and XZQMC attributes.
[0084] The aforementioned automatic repair module 330 can calculate the ellipsoidal area of the sub-plots to update the YDMJ attribute and generate a new BSM to update the BSM attribute of the sub-plots. This geometric segmentation algorithm can accurately segment plots according to administrative boundaries and automatically update all relevant attributes of the segmented sub-plots without manual intervention.
[0085] The BSM generation algorithm is a key technology for ensuring the uniqueness and standardization of land parcel identifiers. It is used to generate new BSMs for sub-parcels after they have been divided. The BSM land parcel identifier uses an 18-bit encoding structure, defined as follows: ,in This represents the string concatenation operation. Indicates the prefix of the administrative region code. This indicates a fixed intermediate code. This represents an 8-digit serial number. Specifically: This indicates that the first 6 characters are extracted from XZQDM as the administrative region prefix; It is a fixed value; It is an 8-digit decimal string. The serial number generation algorithm is as follows: Let the set of existing land parcels within this administrative region be... This includes existing land parcels and newly generated land parcels, from each land parcel Extracting the serial number from the BSM: Convert the serial number to an integer: ; Calculate the maximum serial number: The new serial number is: ; Format as an 8-character string: That is, if the number of bits is less than 8, it is padded with leading zeros. The final generated new BSM is: .
[0086] Ellipsoid area calculation is used to calculate the actual area of sub-plots on the ellipsoid surface and is a key technology to ensure the accuracy of area calculation. It is used in the automatic repair module to update the YDMJ attributes of the segmented sub-plots. Traditional planar area calculation methods ignore the curvature of the Earth, which can produce significant errors over large areas. This system adopts an ellipsoid area calculation method based on geodesy. The automatic repair module 330 can first obtain the coordinate reference system (CRS) of the vector data to determine whether it is a geographic coordinate system. If it is a geographic coordinate system, it extracts the corresponding ellipsoid parameters, including the semi-major axis 'a' and the flattening 'f', and constructs a geodetic object (Geod) based on the ellipsoid parameters. For polygons defined by latitude and longitude coordinate sequences: ,in Indicates longitude. Representing latitude, the ellipsoidal area is calculated using the trapezoidal rule in geodesy, which decomposes the polygon into a series of geodetic quadrilaterals. The area of each geodetic quadrilateral is calculated using surface integrals on the ellipsoidal surface. The specific formula is as follows: ,in This represents the projection region of the polygon onto the ellipsoid. This represents the radius of curvature of the ellipsoid at that point. The system calls the `geometry_area_perimeter` method of the geodetic object. This method performs high-precision calculations based on the Vincenty or Karney algorithm, returning the ellipsoid's area and perimeter, and taking the absolute value of the area as the final result. If it is a projected coordinate system, the planar area is directly obtained using the `area` attribute of the geometric object. The ellipsoid area calculation method takes into account the Earth's curvature, improving accuracy by 0.1% to 1% compared to planar area calculations, meeting surveying and mapping specifications and ensuring the accuracy of the plot area data.
[0087] The integrity check module 340 is used to check the file organization and data integrity of vector data. The check items of the integrity check module 340 include file naming check, file organization check, GDB format check, and quantity check.
[0088] The coordinate system check module 350 is used to check whether the coordinate reference system of vector data conforms to the requirements of the CGCS2000 national geodetic coordinate system.
[0089] The Field Inspection Module 360 is used to check the standardization of the field structure of vector data. The inspection items in the Field Inspection Module 360 include layer inspection, field quantity inspection, field name inspection, field type inspection, and area field type inspection.
[0090] Content inspection module 370 is used to check the standardization and accuracy of attribute values in vector data. The inspection items of content inspection module 370 include value range inspection, BSM encoding rule inspection, BSM uniqueness inspection, required field inspection, and YSDM fixed value inspection.
[0091] The topology check module 380 is used to check the geometric validity of vector data and the overlap of land parcels.
[0092] The administrative division check module 390 is used to check whether the value of the administrative division attribute field of the land parcel matches its spatial location.
[0093] Optionally, the soil environmental quality vector data quality inspection system 300 may further include: The results summary module is used to generate inspection result reports and output them to a specified directory.
[0094] The results summary module can read the inspection results summary table template and update the corresponding inspection items in the summary table based on the inspection results of each inspection module. For items that passed the inspection, enter "correct"; for items that failed the inspection, enter "error information" and the relevant land parcel BSM; for items that require manual verification, enter "remarks". The summary table of inspection results is organized according to the order of the inspection codes. For example, the order of the codes is as follows: for integrity checks, 1101 file naming check, 1102 file organization check, 1201 GDB format check, and 1301 quantity check; for coordinate system checks, 2101 coordinate system check and 2202 cross-county administrative region land parcel check (it can be understood that the function implemented by the above-mentioned cross-boundary land parcel identification module 320 is the function of cross-line administrative region land parcel check); for field checks, 3101 layer check, 3201 field quantity check, 3202 field name check, 3203 field type check, 3204 field length definition check, and 3205 area field type check; for content checks, 3301 value range check, 3302 BSM encoding rule check, 3501 BSM uniqueness check, 3601 required field check, and 3206 YSDM fixed value check; for topology checks, 4101 land parcel overlap check; and for administrative division checks, 3701 administrative region code consistency check. The above-mentioned results summary module can also generate inspection result file names with timestamps and save the updated summary table to a specified directory for easy access and archiving by quality inspectors.
[0095] Furthermore, the aforementioned soil environmental quality vector data inspection system 300 also provides a graphical user interface (GUI) to facilitate vector data inspection operations. The GUI, implemented using the tkinter library, employs a dark theme and includes a file selection module, output settings module, progress display module, control button module, and log display module. The file selection module supports adding multiple GDB files, selecting administrative boundary GDBs, and selecting CSV templates. The output settings module allows setting the output directory, choosing whether to save the CSV report, and enabling automatic repair. The progress display module shows the current inspection step, progress bar, and completion percentage. The control button module provides functions such as start inspection, stop inspection, open output directory, and exit program. The log display module displays real-time logs, inspection results, and error details. The interface supports batch processing of multiple GDB files, automatically traversing all GDB files in a selected folder for inspection and generating corresponding inspection result reports.
[0096] The aforementioned Soil Environmental Quality Vector Data Inspection System 300 achieves fully automated inspection of vector data, covering 19 inspection items and encompassing all quality inspection aspects, including integrity, coordinate system, field standardization, content accuracy, topological relationships, and consistency with administrative divisions. This significantly improves inspection efficiency, enabling the comprehensive inspection of thousands of plots within minutes. Furthermore, it accurately identifies plots crossing administrative boundaries using a negative buffer judgment method, solving the technical challenge of traditional methods failing to distinguish between boundary contact and internal crossings, thus avoiding omissions and misjudgments inherent in manual inspections. In addition, it provides an automatic repair function for cross-boundary plots, accurately dividing plots according to administrative boundaries and automatically updating relevant attributes, greatly reducing manual processing workload. The use of an ellipsoidal area calculation method ensures the accuracy of plot area calculations, meeting surveying and mapping specifications. It supports batch processing and result aggregation, meeting the needs of large-scale data quality inspection. A user-friendly graphical interface lowers the barrier to entry, facilitating operation for non-professionals.
[0097] Figure 4 This is a schematic diagram of an electronic device provided in an embodiment of this application. (Refer to...) Figure 4 The electronic device 400 includes a processor 410, a memory 420, and a communication interface 430. These components are interconnected and communicate with each other via a communication bus 440 and / or other forms of connection mechanism (not shown).
[0098] The memory 420 includes one or more (only one is shown in the figure), which may be, but is not limited to, Random Access Memory (RAM), Read Only Memory (ROM), Programmable Read-Only Memory (PROM), Erasable Programmable Read-Only Memory (EPROM), Electrically Erasable Programmable Read-Only Memory (EEPROM), etc. The processor 410 and other possible components may access the memory 420 to read and / or write data therein.
[0099] Processor 410 includes one or more (only one is shown in the figure), which can be an integrated circuit chip with signal processing capabilities. The processor 410 described above can be a general-purpose processor, including a central processing unit (CPU), a microcontroller unit (MCU), a network processor (NP), or other conventional processors; it can also be a special-purpose processor, including a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components.
[0100] Communication interface 430 includes one or more (only one is shown in the figure), which can be used to communicate directly or indirectly with other devices to exchange data. For example, communication interface 430 can be an Ethernet interface; it can be a mobile communication network interface, such as an interface for 3G, 4G, or 5G networks; or it can be other types of interfaces with data transmission and reception functions.
[0101] One or more computer program instructions may be stored in the memory 420, and the processor 410 may read and run these computer program instructions to implement the soil environmental quality vector data quality inspection method provided in the embodiments of this application and other desired functions.
[0102] Understandable. Figure 4 The structure shown is for illustrative purposes only; the electronic device 400 may also include more than [other components]. Figure 4 The more or fewer components shown, or having the same Figure 4 The different configurations shown. Figure 4 The components shown can be implemented using hardware, software, or a combination thereof. For example, electronic device 400 can be a single server (or other device with computing power), a combination of multiple servers, a cluster of a large number of servers, etc., and can be either a physical device or a virtual device.
[0103] This application also provides a computer-readable storage medium storing computer program instructions. These computer program instructions are read and executed by a processor to perform the soil environmental quality vector data quality inspection method provided in this application. For example, the computer-readable storage medium can be implemented as follows: Figure 4 The memory 420 in the electronic device 400, or a separate storage product (such as a USB flash drive, portable hard drive, etc.).
[0104] In the embodiments provided in this application, it should be understood that the disclosed systems and methods can be implemented in other ways. The system embodiments described above are merely illustrative. For example, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. Furthermore, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Additionally, the coupling or direct coupling or communication connection shown or discussed may be indirect coupling or communication connection through some communication interfaces, devices, or units, and may be electrical, mechanical, or other forms.
[0105] Furthermore, the units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0106] Furthermore, the functional modules in the various embodiments of this application can be integrated together to form an independent part, or each module can exist independently, or two or more modules can be integrated to form an independent part.
[0107] It should be noted that if the function is implemented as a software functional module and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0108] In this document, relational terms such as first and second are used only to distinguish one entity or operation from another entity or operation, without necessarily requiring or implying any such actual relationship or order between these entities or operations.
[0109] The above description is merely an embodiment of this application and is not intended to limit the scope of protection of this application. Various modifications and variations can be made to this application by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the scope of protection of this application.
Claims
1. A method for quality inspection of soil environmental quality vector data, characterized in that, The method includes: Acquire soil environmental quality vector data and administrative boundary data; Based on the administrative region boundary data, determine the first boundary line that intersects with each plot in the vector data; Determine the negative buffer plot of the land parcel; wherein, the negative buffer plot is used to characterize the geometric object formed by shrinking the geometric boundary of the land parcel inward by a preset tolerance distance and located inside the land parcel; If the first boundary line intersects with the negative buffer land parcel, the land parcel is determined to be a cross-boundary land parcel; otherwise, the land parcel is determined to be a non-cross-boundary land parcel.
2. The method for quality inspection of soil environmental quality vector data according to claim 1, characterized in that, The method further includes: When the land parcel is determined to be a cross-boundary land parcel, a second boundary line is determined within the first boundary line that crosses the land parcel; The second boundary line is merged into a plot dividing line; The land parcel is geometrically divided using the land parcel dividing line to obtain at least one sub-land parcel of the land parcel; For each of the sub-plots, based on the spatial location of the sub-plot and the administrative region boundary data, the administrative region to which the sub-plot belongs is determined, and the plot attributes of the sub-plot are updated.
3. The method for quality inspection of soil environmental quality vector data according to claim 2, characterized in that, The land parcel attributes include a land parcel identifier; updating the land parcel attributes of the sub-land parcel includes: Extract a prefix character of a preset number of digits from the administrative region code of the administrative region to which the sub-plot belongs, and obtain the first code segment; Determine the fixed intermediate code of the land parcel identifier and obtain the second code segment; The serial number of the sub-plot is determined based on the serial numbers of existing plots within the administrative region to which the sub-plot belongs; Based on the serial number of the sub-plot, determine the third code segment; Based on the first code segment, the second code segment, and the third code segment, generate the land parcel identifier for the sub-land parcel; Update the land parcel attributes of the sub-parcel using the generated parcel identifier.
4. The method for quality inspection of soil environmental quality vector data according to claim 2, characterized in that, The land parcel attributes include land area; updating the land parcel attributes of the sub-parcel includes: Obtain the coordinate reference system of the sub-plot; When the coordinate reference system is a geographic coordinate system, the land area of the sub-plot is calculated using geodetic surveying methods based on the reference ellipsoid parameters corresponding to the geographic coordinate system. When the coordinate reference system is a projected coordinate system, the land area of the sub-plot is directly calculated based on the geometric objects of the sub-plot; The land use area obtained from the calculation is used to update the land parcel attributes of the sub-parcel.
5. The method for quality inspection of soil environmental quality vector data according to claim 2, characterized in that, Determining the administrative region to which the sub-plot belongs based on its spatial location and the administrative region boundary data includes: Calculate a representative point for the sub-plot; wherein the representative point is located within the geometry of the sub-plot; Determine the target administrative region surface features containing the representative points from the administrative region boundary data; When there is a unique target administrative area feature, the target administrative area feature is determined as the administrative area to which the sub-plot belongs.
6. The method for quality inspection of soil environmental quality vector data according to claim 1, characterized in that, The determination of the negative buffer plots of the land parcel includes: Calculate the shortest distance from each point inside the plot to the geometric boundary of the plot; Points whose shortest distance is not greater than the preset tolerance distance are removed from the land parcel to obtain the negative buffer land parcel.
7. The method for quality inspection of soil environmental quality vector data according to any one of claims 1 to 6, characterized in that, The method further includes: The vector data shall be subjected to at least one of the following checks: integrity check, coordinate system check, field check, content check, topology check, and administrative division check, wherein: The integrity check is used to check at least one of the following: file naming conventions, directory structure compliance, GDB format integrity, and consistency of the number of land parcels in the vector data. The coordinate system check is used to check whether the coordinate reference system of the vector data conforms to the requirements of the geodetic coordinate system. The field check is used to check at least one of the following: layer compliance, field quantity accuracy, field name standardization, field type correctness, and field length definition compliance of the vector data. The content check is used to check at least one of the following: the validity of field value ranges of the vector data, the compliance of land parcel identification code encoding rules, the uniqueness of land parcel identification codes, the completeness of required fields, and the compliance of fixed values of element codes. The topology check is used to check the geometric overlap between various parcels in the vector data; The administrative division check is used to check the consistency between the administrative division attributes of each plot in the vector data and its spatial location.
8. A soil environmental quality vector data quality inspection system, characterized in that, include: The data acquisition module and the cross-boundary land parcel identification module connected to the data acquisition module, wherein: The data acquisition module is used to acquire soil environmental quality vector data and administrative region boundary data; The cross-boundary land parcel identification module is used to determine, based on the administrative region boundary data, a first boundary line intersecting with each parcel in the vector data; and to determine the negative buffer parcel of the parcel; wherein, the negative buffer parcel is used to characterize a geometric object formed by shrinking the geometric boundary of the parcel inward by a preset tolerance distance and located inside the parcel; if the first boundary line intersects with the negative buffer parcel, the parcel is determined to be a cross-boundary land parcel; otherwise, the parcel is determined to be a non-cross-boundary land parcel.
9. An electronic device, characterized in that, include: A processor, a memory, and a communication bus, wherein the processor and the memory communicate with each other via the communication bus; The memory stores program instructions that can be executed by the processor, and the processor can execute the method as described in any one of claims 1 to 7 by calling the program instructions.
10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer instructions that, when executed by a computer, cause the computer to perform the method as described in any one of claims 1 to 7.