Real-time dynamic splicing method and device for massive tiles
Through dynamic splicing and building a tile tree structure, the problem of long-term drawing and complex service consumption of large-scale geographical elements is solved, efficient and flexible geospatial data services are achieved, and response speed is optimized and costs are reduced.
Patent Information
- Application Number
- CN202510592622.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-09
- Publication Date
- 2025-08-15
- Estimated Expiration
- 2045-05-09
AI Technical Summary
The existing technology takes a very long time in the process of cutting maps on a large scale, resulting in a complex number of map services, which makes it difficult to meet the needs of frequent updates of geographical factors. In addition, the traditional open source solution GeoWebCache has insufficient efficiency and flexibility.
By dynamically splicing multiple sets of tiles based on the same slicing scheme, a tile tree structure is built, and a binary tree structure and a first-level caching mechanism can be used to quickly find, locate and respond, optimize service response speed and system performance, and reduce the number of map services.
It significantly improves the efficiency of map cutting and service release, optimizes the response speed of client requests, reduces cost and resource consumption, enhances service flexibility and scalability, and improves data consistency and accuracy.
Smart Images

Figure CN120104715B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of geospatial data processing, and in particular to a method and device for real-time dynamic splicing of massive tiles. Background Art
[0002] In geospatial data processing, various geospatial data need to be made into compact tiles. These data include vector data, such as shapefiles or geodatabase feature classes for points, lines, and surfaces; and raster data, such as satellite images, digital elevation models, etc. Using ArcGIS Pro or ArcMap software, appropriate symbolization and labeling settings are made according to the data type and characteristics, and the layer order and transparency are adjusted to make the map present the expected display effect. After confirming that all color schemes and settings are correct, the slicing task can be started. ArcGIS will cut the map data into a series of tiles according to the set parameters and slicing scheme, and store them in the specified cache location. The slicing process takes a long time, and the specific duration depends on the scale and complexity of the map data. Taking the slicing of image data of levels 0-19 in a specified area as an example, it takes 3 months in a single-machine environment.
[0003] The resulting tiled artifacts use Esri's proprietary data format and storage structure. This format compresses and organizes tile data for efficient storage and fast local access. It may include ArcGIS-specific metadata and optimizations. The resulting artifacts (compact tiles) are also used to publish WMTS services.
[0004] Currently, there are two main ways to publish WMTS services. One is through ArcGIS Server, but because it's not open source and expensive, the open source solution GeoWebCache has emerged. Whether publishing through ArcGIS Server or GeoWebCache, the output is typically published as a single WMTS service for a single slice. However, in practice, slicing large areas of geographic features is often extremely time-consuming. For example, fully slicing a specific area can take months, which is clearly insufficient given the current rapid update of geographic features. Therefore, most people choose to slice map features according to fixed rules and then perform the mapping, coloring, and slicing operations separately. While this approach improves slicing efficiency to a certain extent, it also introduces new problems. For example, if a map of a specific area is sliced into 10 tiles, publishing it will generate 10 map services. For map users, 10 services may be acceptable, but when the number of slices increases to 20, 30, or even more, it undoubtedly introduces significant inconvenience to map users and is difficult to accept.
[0005] Therefore, how to invent a real-time dynamic splicing method for massive tiles that can not only ensure the efficiency of cutting maps, but also reduce the number of map services and provide more convenient and efficient services for map callers has become an urgent problem to be solved. Summary of the Invention
[0006] To this end, the present invention provides a method and device for real-time dynamic splicing of massive tiles. This method dynamically splices multiple groups of tiles based on the same slicing scheme, merging them into a single WMTS service output. Using a binary tree structure, it rapidly locates and locates client-requested tiles. Furthermore, thanks to a first-level cache mechanism, it quickly responds to recurring tile requests with the same row and column numbers, significantly improving service response speed and overall system performance.
[0007] To achieve the above objectives, the present invention provides the following technical solution: a method for real-time dynamic splicing of massive tiles, comprising:
[0008] Store several compact tiles generated based on the same tiling scheme in a set location on the server;
[0009] Adding a unique identifier to each tile generated by the compact slice; the unique identifier serves as a root node for indexing the tile;
[0010] Load the tile into GeoWebCache, and dynamically analyze the tile through GeoWebCache to obtain the bounds and corresponding level ranges of the tile;
[0011] Determine the stacking order of the tiles in the overall display according to the order in which the tiles are loaded into GeoWebCache; save the bounding range of the tiles, the level range corresponding to the tiles, and the stacking order data of the tiles according to the set storage method;
[0012] According to the root node, based on the relationship between the bounding range of the tile and the hierarchical range corresponding to the tile, the tiles are extended downward in a tree structure to construct a tile tree structure;
[0013] The Wmts service processes the service request input by the user and outputs service metadata or tile image data.
[0014] As a preferred solution for the real-time dynamic splicing method of massive tiles, the steps for the Wmts service to process the service request input by the user are as follows:
[0015] If a GetCapabilities request is received, obtain and output the service metadata;
[0016] If a GetTile request is received, the target tile is located in the tile tree structure according to the set parameters in the URL input by the client; the target tile is overlapped and superimposed, invalid tiles and blank images are removed, the target result image is obtained and output to the client; the target result image is cached and a mapping relationship between the cache path and the row and column numbers is constructed to improve the response speed of subsequent identical GetTile requests.
[0017] As a preferred solution for the real-time dynamic splicing method of massive tiles, in the process of storing the compact slices in a set location of the server, the storage methods include: local disk storage, Hadoop distributed file system storage and network file system storage.
[0018] As a preferred solution of the method for real-time dynamic splicing of massive tiles, in the process of the Wmts service processing the GetCapabilities request, the service metadata includes: coordinate system, tile matrix set, layer information, service operation, service restriction conditions and tile matrix specific information;
[0019] The layer information includes: layer name, title, abstract description and data format;
[0020] The service operation includes: supported request types and parameters of the request types;
[0021] The service restrictions include: access rights and terms of use;
[0022] The tile matrix specific information includes: resolution, scale denominator and range.
[0023] As an optimal solution for the real-time dynamic splicing method of massive tiles, during the process of the Wmts service processing the GetTile request, the GetTile request adds the setting parameters to the URL input by the client through the HTTP GET method; the setting parameters include: layer name, tile matrix set name, tile row number, tile column number and tile zoom level.
[0024] The present invention also provides a device for real-time dynamic splicing of massive tiles, based on the above method for real-time dynamic splicing of massive tiles, comprising:
[0025] A compact slice storage module, used for storing a plurality of compact slices generated based on the same slicing scheme in a set location of the server;
[0026] A tile identification adding module, configured to add a unique identification to each tile generated by the compact slice; the unique identification serves as a root node for indexing the tile;
[0027] A tile dynamic analysis and processing module is used to load the tile into GeoWebCache, dynamically analyze the tile through GeoWebCache, and obtain the bounds and corresponding level ranges of the tile;
[0028] A tile overlay order determination module is used to determine the overlay order of the tiles in the overall display according to the order in which the tiles are loaded into GeoWebCache; and save the bounds of the tiles, the level ranges corresponding to the tiles, and the overlay order data of the tiles according to a set storage method;
[0029] A tile tree structure construction module is configured to construct a tile tree structure by extending and splicing the tiles downward in a tree structure based on the root node and the relationship between the bounding range of the tile and the hierarchical range corresponding to the tile;
[0030] The Wmts service processing module is used to process the service request input by the user through the Wmts service and output service metadata or tile image data.
[0031] As a preferred solution for the device for real-time dynamic splicing of massive tiles, in the Wmts service processing module, the submodule for the Wmts service to process the service request input by the user includes:
[0032] A GetCapabilities request processing submodule, configured to obtain and output the service metadata upon receiving a GetCapabilities request;
[0033] The GetTile request processing submodule is used to locate the target tile in the tile tree structure according to the set parameters in the URL input by the client upon receiving a GetTile request; perform an overlay operation on the target tile, remove invalid tiles and blank images, obtain the target result image and output it to the client; cache the target result image and construct a mapping relationship between the cache path and the row and column numbers to improve the response speed of subsequent identical GetTile requests.
[0034] As a preferred solution for the real-time dynamic splicing device of massive tiles, in the compact slice storage module, in the process of storing the compact slice in the set location of the server, the storage methods include: local disk storage, Hadoop distributed file system storage and network file system storage.
[0035] As a preferred solution for the device for real-time dynamic splicing of massive tiles, in the GetCapabilities request processing submodule of the Wmts service processing module, during the process of the Wmts service processing the GetCapabilities request, the service metadata includes: coordinate system, tile matrix set, layer information, service operation, service restriction conditions and tile matrix specific information;
[0036] The layer information includes: layer name, title, abstract description and data format;
[0037] The service operation includes: supported request types and parameters of the request types;
[0038] The service restrictions include: access rights and terms of use;
[0039] The tile matrix specific information includes: resolution, scale denominator and range.
[0040] As a preferred solution for the real-time dynamic splicing device of massive tiles, in the GetTile request processing submodule in the Wmts service processing module, during the process of the Wmts service processing the GetTile request, the GetTile request adds the setting parameters in the URL input by the client through the HTTP GET method; the setting parameters include: layer name, tile matrix set name, tile row number, tile column number and tile zoom level.
[0041] The present invention has the following advantages:
[0042] First, it significantly improves the efficiency of map slicing and service publishing. Traditional map slicing methods are extremely time-consuming for large-scale geographic features. For example, a comprehensive map slicing of a specific area can take months on a single machine. This invention significantly reduces slicing time by segmenting map features according to reasonable rules and processing them separately. Furthermore, it can dynamically splice multiple sets of tiles at runtime and merge them into a single WMTS service, avoiding the problem of complex services caused by excessive segmentation. This makes map service publishing more efficient and convenient, significantly improving the overall efficiency of geospatial data processing and meeting the practical needs of frequent geographic feature updates.
[0043] Second, the client request response speed is optimized: using the binary tree structure, the tiles requested by the client can be quickly found and located. When the client initiates a request, the system can use the binary search method to quickly traverse the tree nodes based on the request parameters, through the reverse operation of the slicing scheme and the tree node index number rules, to accurately locate the area where the target tile is located and obtain the result image. At the same time, the first-level cache mechanism quickly responds to tile requests with the same row and column numbers. The next time there is a request with the same row and column number, the image is directly obtained based on the mapping relationship between the cache path and the row and column number. There is no need to repeatedly match nodes from the tree structure, which greatly reduces the response time, provides a smoother and more efficient user experience for the map caller, and significantly optimizes the response speed of client requests and system performance.
[0044] Third, it reduces costs and resource consumption: Compared to ArcGIS Server, a closed and expensive publishing method, this invention is developed based on the open-source GeoWebCache. This not only saves software acquisition costs but also reduces the hardware resource consumption, including storage and computing resources, associated with long map slicing times and the maintenance of a large number of services by optimizing the map slicing and service publishing processes. For example, during the map slicing process, the shortened slicing time means less server runtime and lower energy consumption, thus reducing the overall operating costs of geospatial data services.
[0045] Fourth, enhanced service flexibility and scalability: The dynamic splicing method of this invention allows for the flexible integration of compact tiles from different sources based on the same tiling scheme without requiring large-scale re-slicing. This facilitates the timely adjustment and expansion of map service content based on actual business needs. Whether adding new geographic area data or updating and optimizing existing data, this can be easily accomplished, greatly enhancing the flexibility and scalability of geospatial data services and better adapting to ever-changing business scenarios and user needs.
[0046] Fifth, improved data consistency and accuracy: When merging multiple tile packages, the data format, resolution, and overall boundary consistency and accuracy across the entire WMTS service are ensured by reordering the tiles in memory based on hierarchy and extent, and uniformly acquiring and processing service metadata. This helps avoid map display errors or analytical biases caused by data inconsistencies, provides a more reliable data foundation for various geographic information applications based on this service, and improves the quality and usability of geospatial data. BRIEF DESCRIPTION OF THE DRAWINGS
[0047] To more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following briefly introduces the drawings required for the embodiments or the description of the prior art. Obviously, the drawings described below are merely exemplary, and those skilled in the art can, without inventive effort, derive other implementation drawings based on the provided drawings.
[0048] The structures, proportions, sizes, etc. illustrated in this specification are intended solely to complement the contents disclosed herein and to facilitate understanding and reading by persons skilled in the art. They are not intended to limit the conditions under which the present invention may be implemented and therefore have no substantive technical significance. Any structural modifications, changes in proportions, or adjustments in sizes, without affecting the efficacy and objectives of the present invention, shall remain within the scope of the technical contents disclosed herein.
[0049] Figure 1 This is a flow chart of the method for real-time dynamic splicing of massive tiles provided in Example 1 of the present invention;
[0050] Figure 2 Schematic diagram of a tile tree structure in the method for real-time dynamic splicing of massive tiles provided in Example 1 of the present invention;
[0051] Figure 3 This is a schematic diagram of the architecture of the device for real-time dynamic splicing of massive tiles provided in Example 2 of the present invention. DETAILED DESCRIPTION
[0052] The following describes the implementation of the present invention using specific embodiments. Those skilled in the art will readily understand the other advantages and benefits of the present invention from the disclosure herein. Obviously, the embodiments described are only a portion of the present invention, not all of it. All other embodiments derived by persons of ordinary skill in the art based on the embodiments of the present invention without inventive effort are intended to fall within the scope of protection of the present invention.
[0053] Example 1
[0054] See also Figure 1 Embodiment 1 of the present invention provides a method for real-time dynamic splicing of massive tiles, comprising the following steps:
[0055] S1. storing a plurality of compact slices generated based on the same slicing scheme in a set location on the server;
[0056] S2. Add a unique identifier to each tile generated by the compact slice; the unique identifier serves as a root node for indexing the tile;
[0057] S3. Load the tile into GeoWebCache, and dynamically analyze the tile through GeoWebCache to obtain the bounds and corresponding level ranges of the tile;
[0058] S4. Determine the stacking order of the tiles in the overall display according to the order in which the tiles are loaded into GeoWebCache; save the bounding range of the tiles, the level range corresponding to the tiles, and the stacking order data of the tiles according to the set storage method;
[0059] S5. Based on the root node and the relationship between the bounding range of the tile and the hierarchical range corresponding to the tile, extend the tiles downward in a tree structure to construct a tile tree structure.
[0060] S6. Process the service request input by the user through the Wmts service and output service metadata or tile image data.
[0061] In this embodiment, in step S1, a plurality of compact slices generated based on the same slicing scheme are stored in a set location of the server;
[0062] Specifically, several compact slices generated based on the same set of slicing schemes are stored and deployed to a designated location that can be read by the server.
[0063] Storage methods are diverse, including but not limited to local disk storage, Hadoop Distributed File System (HDFS), and Network File System (NFS). Local storage is suitable for scenarios with smaller data volumes and extremely high read and write speed requirements, enabling fast data access. HDFS storage, with its high fault tolerance and scalability, can meet the needs of reliable storage and processing of large-scale data. NFS storage facilitates file resource sharing between hosts with different operating systems, promoting efficient data flow and collaboration. In actual operation, it is necessary to carefully select the most suitable storage method based on the server's performance configuration, data scale, and business application scenario to ensure the stability, efficiency, and security of compact slice data storage.
[0064] In this embodiment, in step S2, a unique identifier is added to each tile generated by the compact slice; the unique identifier serves as a root node for indexing the tile;
[0065] Specifically, a unique identifier is set for each tile generated by the compact slice to accurately describe this group of tiles, and this identifier is used as the root node of the tile index.
[0066] In this embodiment, in step S3, the tile is loaded into GeoWebCache, and GeoWebCache dynamically analyzes the tile to obtain the bounds and corresponding level ranges of the tile;
[0067] Specifically, the tiles generated by the compact slices are loaded into GeoWebCache. We will not discuss the specific methods of GeoWebCache reading HDFS and NFS files at this stage. By configuring GeoWebCache, we ensure that tiles can be loaded smoothly, laying the foundation for subsequent operations such as map display.
[0068] After loading into GeoWebCache, GeoWebCache automatically performs dynamic analysis on the loaded tiles to accurately obtain the boundaries of the tiles and the level range corresponding to the tiles.
[0069] In this embodiment, in step S4, the stacking order of the tiles in the overall display is determined according to the order in which the tiles are loaded into GeoWebCache; the bounding range of the tiles, the level range corresponding to the tiles, and the stacking order data of the tiles are saved according to the set storage method;
[0070] Specifically, the order in which the tiles are overlaid in the overall display is determined based on the order in which the tiles are loaded into GeoWebCache in step S3. After the determination is completed, the key metadata information, such as the tile boundaries, the level range corresponding to the tile, and the tile overlay order data, is saved through database storage or memory cache. It should be noted that the saved metadata information is only valid during the current system startup. The next time the system is started, the analysis and saving operations will be performed again to adapt to possible changes in the slice data and configuration.
[0071] In this embodiment, in step S5, based on the root node and the relationship between the bounding range of the tile and the hierarchical range corresponding to the tile, the tiles are extended downward in a tree structure to construct a tile tree structure.
[0072] Specifically, according to the root node of the tile, based on the relationship between the bounding range of the tile and the hierarchical range corresponding to the tile, the root nodes of each tile are extended downward in a tree structure to construct a tile tree structure. Figure 2As shown, in such a tree structure, tile nodes 0-0-0 and 0-0-1 together represent a specific map range block. In this tree, the index number of each node is determined by its last digit. For example, if there are 500 such map range blocks in the second level, then the tile node index number corresponding to the last range block is 0-0-500. When entering the next level, the index numbers will be arranged in sequence starting from 0-0-500-0. A part of metadata information is attached to each node, and this metadata information identifies which result package each tile is located in. Based on the above structural analysis, multiple tile result packages are basically reordered in memory according to the level and range. And the reordered structure is cached in memory.
[0073] In this embodiment, in step S6, the service request input by the user is processed by the Wmts service, and service metadata or tile image data is output.
[0074] Specifically, the steps of processing the service request input by the user by the Wmts service are as follows:
[0075] S61. If a GetCapabilities request is received, obtain and output the service metadata;
[0076] Specifically, GetCapabilities is used to retrieve a wide range of service metadata, including information about the coordinate systems supported by the service, tile matrix sets, layer information (such as layer name, title, abstract description, and data format), service operations (such as supported request types and parameters), service restrictions (such as access permissions and terms of use), and detailed information about each tile matrix (such as resolution, scale denominator, and boundaries). This metadata is crucial, providing clients with comprehensive insight into the capabilities and resources of the WMTS service, enabling them to construct subsequent requests accurately. When merging multiple layers, metadata primarily focuses on the data format, resolution, and overall boundaries. Given that the data format is pre-agreed to be either PNG or JPEG and a consistent tiling scheme is used during data preparation, resolution consistency is ensured. To determine the overall boundaries, a simple intersection operation is performed on the boundaries of each row of tree nodes.
[0077] S62. If a GetTile request is received, the target tile is located in the tile tree structure according to the set parameters in the URL input by the client; the target tile is overlapped and superimposed, invalid tiles and blank images are removed, the target result image is obtained and output to the client; the target result image is cached and a mapping relationship between the cache path and the row and column numbers is constructed to improve the response speed of subsequent identical GetTile requests.
[0078] Specifically, the client sends a GetTile request to the Wmts service by specifying parameters such as the layer name, tile matrix set name, tile row number, tile column number, and tile zoom level. The server then extracts the corresponding tile image data (common formats such as PNG, JPEG, etc.) from the map data based on these parameters and returns it to the client for displaying the specific area of the map in the map application.
[0079] The GetTile request adds the setting parameters to the URL input by the client via HTTP GET; the setting parameters include: layer name, tile matrix set name, tile row number, tile column number and tile zoom level.
[0080] Specific examples include:
[0081] "http: / / XXXXX:80 / GeoWebCache / gishub / layer_group / XXX / wmts?layer=[layer name]&style=&tilematrixset=c&Service=WMTS&Request=GetTile&Version=1.0.0&Format=image%2Fpng&TileMatrix=8&TileCol=185&TileRow=34".
[0082] In the above example, the client explicitly specifies the service type, version, request action, target layer, tile matrix set, zoom level, specific row and column numbers, and image format through an HTTP GET request.
[0083] When a client initiates a request, the system matches the layer name in the request with the root node of each tree. If a match is found, the first condition is met. Subsequently, a match is performed against the row and column numbers in the request. For example, if the request URL contains tilematrix = 8, tilerow = 34, and tilecol = 185, the tile requested by the client is located at level 8 of the tree. Based on row number 185 and column number 34, by reversing the tiling scheme, the tile is determined to be within the bounds of [87.5830, 43.8574218, 87.62912, 43.9045]. Because the tree node index generation rule covers this bounds, a binary search is used during tree node traversal to determine whether the tile is within the specified range, allowing for quick location of the seventh-level index. The eighth-level index is then generated by concatenating the seventh-level indexes. This allows for the quick acquisition of the requested tile's overall serial number prefix, for example: 1-2-3-4-5-6-7-8-XXX. Based on this index prefix, all tiles with serial numbers beginning with 1-2-3-4-5-6-7-8 are retrieved. Next, the tiles are overlaid in the order of XXX, eliminating invalid tiles and blank images to create the final image.
[0084] In this embodiment, the system searches and matches in the memory tree structure according to the row and column numbers of the request to obtain the corresponding result image, and then responds to the client with the image. At the same time, in order to optimize the efficiency of subsequent request processing, the system will cache the result image to a third-party memory or local storage. After completing the caching operation, a mapping relationship will be constructed inside the server to associate the cache path with the row and column numbers. The next time a request with the same row and column number comes in, the system will be able to quickly and directly locate the result image based on this mapping relationship, without having to match the node from the tree structure again, which greatly improves the response speed and system performance.
[0085] It should be noted that the method of the embodiments of the present disclosure can be performed by a single device, such as a computer or server. The method of the embodiments of the present disclosure can also be applied in a distributed scenario, where multiple devices cooperate to perform the method. In such a distributed scenario, one of the multiple devices may only perform one or more steps of the method of the embodiments of the present disclosure, and the multiple devices will interact with each other to complete the method.
[0086] It should be noted that the above description is limited to some embodiments of the present disclosure. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recited in the claims may be performed in an order different from that described in the above embodiments and still achieve the desired results. Furthermore, the processes depicted in the accompanying drawings do not necessarily require the specific order or sequential order shown to achieve the desired results. In certain embodiments, multitasking and parallel processing are also possible or may be advantageous.
[0087] Example 2
[0088] See also Figure 3 Embodiment 2 of the present invention further provides a device for real-time dynamic splicing of massive tiles, comprising:
[0089] The compact slice storage module 001 is used to store a plurality of compact slices generated based on the same slicing scheme in a set location on the server;
[0090] The tile identification adding module 002 is used to add a unique identification to each tile generated by the compact slice; the unique identification serves as the root node for indexing the tile;
[0091] The tile dynamic analysis processing module 003 is used to load the tile into GeoWebCache, and dynamically analyze the tile through GeoWebCache to obtain the tile's boundary range and corresponding level range;
[0092] The tile stacking order determination module 004 is used to determine the stacking order of the tiles in the overall display according to the order in which the tiles are loaded into the GeoWebCache; save the bounding range of the tiles, the level range corresponding to the tiles, and the stacking order data of the tiles according to the set storage method;
[0093] A tile tree structure construction module 005 is configured to construct a tile tree structure by extending and splicing the tiles downward in a tree structure based on the root node and the relationship between the bounding range of the tile and the hierarchical range corresponding to the tile;
[0094] The Wmts service processing module 006 is used to process the service request input by the user through the Wmts service and output service metadata or tile image data.
[0095] In this embodiment, in the Wmts service processing module 006, the submodules of the Wmts service for processing the service request input by the user include:
[0096] GetCapabilities request processing submodule 061, configured to obtain and output the service metadata upon receiving a GetCapabilities request;
[0097] The GetTile request processing submodule 062 is used to locate the target tile in the tile tree structure according to the set parameters in the URL input by the client if a GetTile request is received; perform an overlay operation on the target tile, eliminate invalid tiles and blank images, obtain the target result image and output it to the client; cache the target result image and construct a mapping relationship between the cache path and the row and column numbers to improve the response speed of subsequent identical GetTile requests.
[0098] In this embodiment, in the compact slice storage module 001, in the process of storing the compact slice in a set location of the server, the storage methods include: local disk storage, Hadoop distributed file system storage and network file system storage.
[0099] In this embodiment, in the GetCapabilities request processing submodule 061 of the Wmts service processing module 006, when the Wmts service processes the GetCapabilities request, the service metadata includes: coordinate system, tile matrix set, layer information, service operation, service restriction condition and tile matrix specific information;
[0100] The layer information includes: layer name, title, abstract description and data format;
[0101] The service operation includes: supported request types and parameters of the request types;
[0102] The service restrictions include: access rights and terms of use;
[0103] The tile matrix specific information includes: resolution, scale denominator and range.
[0104] In this embodiment, in the GetTile request processing submodule 062 in the Wmts service processing module 006, during the process of the Wmts service processing the GetTile request, the GetTile request adds the setting parameters to the URL input by the client through the HTTP GET method; the setting parameters include: layer name, tile matrix set name, tile row number, tile column number and tile zoom level.
[0105] It should be noted that the information interaction, execution process, etc. between the modules of the above-mentioned system are based on the same concept as the method embodiment in Example 1 of the present application, and the technical effects they bring are the same as those of the method embodiment of the present application. For specific contents, please refer to the description in the method embodiment shown above in the present application, and no further details will be given here.
[0106] Example 3
[0107] Embodiment 3 of the present invention provides a non-transitory computer-readable storage medium, in which program code for a method for real-time dynamic splicing of massive tiles is stored. The program code includes instructions for executing the method for real-time dynamic splicing of massive tiles of embodiment 1 or any possible implementation thereof.
[0108] Computer-readable storage media can be any available medium that can be accessed by a computer, or a data storage device such as a server or data center that includes one or more available media. The available media can be magnetic media (e.g., floppy disks, hard disks, magnetic tapes), optical media (e.g., DVDs), or semiconductor media (e.g., solid-state drives (SSDs)).
[0109] Example 4
[0110] Embodiment 4 of the present invention provides an electronic device, including: a memory and a processor;
[0111] The processor and the memory communicate with each other through a bus; the memory stores program instructions that can be executed by the processor, and the processor calls the program instructions to execute the real-time dynamic splicing method of massive tiles in embodiment 1 or any possible implementation thereof.
[0112] Specifically, the processor can be implemented by hardware or by software. When implemented by hardware, the processor can be a logic circuit, an integrated circuit, etc.; when implemented by software, the processor can be a general-purpose processor, which is implemented by reading software code stored in a memory. The memory can be integrated into the processor or located outside the processor and exist independently.
[0113] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of the present invention is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable systems. The computer instructions can be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions can be transmitted from a website, computer, server or data center to another website, computer, server or data center via a wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) mode.
[0114] Obviously, those skilled in the art will appreciate that the various modules or steps of the present invention described above can be implemented using a general-purpose computing system. They can be centralized on a single computing system or distributed across a network of multiple computing systems. Alternatively, they can be implemented using program code executable by a computing system, and thus, they can be stored in a storage system and executed by the computing system. In some cases, the steps shown or described herein can be performed in a different order than that shown, or they can be fabricated into separate integrated circuit modules, or multiple modules or steps can be fabricated into a single integrated circuit module. Thus, the present invention is not limited to any particular combination of hardware and software.
[0115] Although the present invention has been described in detail above using general descriptions and specific embodiments, it will be apparent to those skilled in the art that modifications and improvements may be made thereto. Therefore, such modifications and improvements, without departing from the spirit of the present invention, are intended to be within the scope of protection claimed herein.
Claims
1. A method for real-time dynamic splicing of massive tiles, characterized in that: include: Store several compact tiles generated based on the same tiling scheme in a set location on the server; Adding a unique identifier to each tile generated by the compact slice; The unique identifier is used as the root node for indexing the tile; Load the tile into GeoWebCache, and dynamically analyze the tile through GeoWebCache to obtain the bounds and corresponding level ranges of the tile; Determine the stacking order of the tiles in the overall display according to the order in which the tiles are loaded into GeoWebCache; save the bounding range of the tiles, the level range corresponding to the tiles, and the stacking order data of the tiles according to the set storage method; According to the root node, based on the relationship between the bounding range of the tile and the hierarchical range corresponding to the tile, the tiles are extended downward in a tree structure to construct a tile tree structure; Process the service request input by the user through the Wmts service and output service metadata or tile image data; Based on the root node of the tile, and based on the relationship between the bounds of the tile and the hierarchical range corresponding to the tile, a tree structure is constructed by extending and splicing the root nodes of each tile downwards. In the tree structure, tile nodes 0-0-0 and 0-0-1 together represent a specific map range block. In this tree, the index number of each node is determined by its last digit; each node has a piece of metadata information attached to it, which identifies which product package each tile is located in; Reorder multiple tile result packages in memory according to level and range, and cache the reordered structure in memory; When the client initiates a request, the layer name in the request is matched with the root node of each tree. If the match is successful, the first condition is met; Then, match the row and column numbers in the request; In the process of traversing the tree nodes, a binary search method is used to determine whether the tile is within the specified range, and invalid tiles and blank images are eliminated to finally obtain the result image.
2. The method for real-time dynamic splicing of massive tiles according to claim 1, characterized in that: The steps for the Wmts service to process the service request input by the user are as follows: If a GetCapabilities request is received, obtain and output the service metadata; If a GetTile request is received, the target tile is located in the tile tree structure according to the setting parameters in the URL input by the client; The target tiles are overlapped and superimposed, invalid tiles and blank images are removed, the target result image is obtained and output to the client; the target result image is cached and a mapping relationship between the cache path and the row and column numbers is constructed to improve the response speed of subsequent identical GetTile requests.
3. The method for real-time dynamic splicing of massive tiles according to claim 2, characterized in that: In the process of storing the compact slices in a set location of the server, storage methods include: local disk storage, Hadoop distributed file system storage and network file system storage.
4. The method for real-time dynamic splicing of massive tiles according to claim 3, characterized in that: In the process of the Wmts service processing the GetCapabilities request, the service metadata includes: coordinate system, tile matrix set, layer information, service operation, service restriction conditions and tile matrix specific information; The layer information includes: layer name, title, abstract description and data format; The service operation includes: supported request types and parameters of the request types; The service restrictions include: access rights and terms of use; The tile matrix specific information includes: resolution, scale denominator and range.
5. The method for real-time dynamic splicing of massive tiles according to claim 4, characterized in that: In the process of the Wmts service processing the GetTile request, the GetTile request adds the setting parameters to the URL input by the client through the HTTP GET method; The setting parameters include: layer name, tile matrix set name, tile row number, tile column number and tile zoom level.
6. A device for real-time dynamic splicing of massive tiles, adopting the method for real-time dynamic splicing of massive tiles according to any one of claims 1 to 5, characterized in that: include: A compact slice storage module, used for storing a plurality of compact slices generated based on the same slicing scheme in a set location of the server; A tile identification adding module, configured to add a unique identification to each tile generated by the compact slice; the unique identification serves as a root node for indexing the tile; A tile dynamic analysis and processing module is used to load the tile into GeoWebCache, dynamically analyze the tile through GeoWebCache, and obtain the bounds and corresponding level ranges of the tile; A tile overlay order determination module is used to determine the overlay order of the tiles in the overall display according to the order in which the tiles are loaded into GeoWebCache; and save the bounds of the tiles, the level ranges corresponding to the tiles, and the overlay order data of the tiles according to a set storage method; A tile tree structure construction module is configured to construct a tile tree structure by extending and splicing the tiles downward in a tree structure based on the root node and the relationship between the bounding range of the tile and the hierarchical range corresponding to the tile; The Wmts service processing module is used to process the service request input by the user through the Wmts service and output service metadata or tile image data.
7. The real-time dynamic splicing device for massive tiles according to claim 6, characterized in that: In the Wmts service processing module, the submodule for the Wmts service to process the service request input by the user includes: A GetCapabilities request processing submodule, configured to obtain and output the service metadata upon receiving a GetCapabilities request; The GetTile request processing submodule is used to locate the target tile in the tile tree structure according to the set parameters in the URL input by the client upon receiving a GetTile request; perform an overlay operation on the target tile, remove invalid tiles and blank images, obtain the target result image and output it to the client; cache the target result image and construct a mapping relationship between the cache path and the row and column numbers to improve the response speed of subsequent identical GetTile requests.
8. The real-time dynamic splicing device for massive tiles according to claim 7, characterized in that: In the compact slice storage module, in the process of storing the compact slice in a set location of the server, the storage methods include: local disk storage, Hadoop distributed file system storage and network file system storage.
9. The real-time dynamic splicing device for massive tiles according to claim 8, characterized in that: In the GetCapabilities request processing submodule of the Wmts service processing module, during the process of the Wmts service processing the GetCapabilities request, the service metadata includes: coordinate system, tile matrix set, layer information, service operation, service restriction conditions and tile matrix specific information; The layer information includes: layer name, title, abstract description and data format; The service operation includes: supported request types and parameters of the request types; The service restrictions include: access rights and terms of use; The tile matrix specific information includes: resolution, scale denominator and range.
10. The real-time dynamic splicing device for massive tiles according to claim 9, characterized in that: In the GetTile request processing submodule of the Wmts service processing module, during the process of the Wmts service processing the GetTile request, the GetTile request adds the setting parameters to the URL input by the client via HTTP GET; The setting parameters include: layer name, tile matrix set name, tile row number, tile column number and tile zoom level.
Citation Information
Patent Citations
Method of and system for defining a service for serving map images
CN113632076A