Meteorological data processing method, electronic device and storage medium
Patent Information
- Application Number
- CN202610980059.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-07-02
- Publication Date
- 2026-08-21
AI Technical Summary
但八面体高斯网格气象数据规模庞大,对数据存储与传输造成极大压力
[0007] The meteorological data processing method, electronic device, and storage medium proposed in this application firstly divide the first meteorological data into spherical triangular blocks corresponding to the Northern and Southern Hemispheres by latitude and longitude regions. This preserves the adjacency relationship of each spherical triangular block in physical space and reduces the impact of data jumps on subsequent processing. Secondly, the triangular blocks in the Northern and Southern Hemispheres are rectangularized and mapped into a planar two-dimensional array structure, resulting in a first two-dimensional array and a second two-dimensional array. Then, the first and second two-dimensional arrays, which are geographically mirror-symmetrical north and south, are complementaryly concatenated to generate regular target two-dimensional arrays, thereby restoring the topological correlation of meteorological data in two-dimensional space and reducing redundant space occupation. Finally, multiple target two-dimensional arrays are compressed and encoded. Since each target two-dimensional array is a complementary concatenation of the first and second two-dimensional arrays that are mirror-symmetrical north and south, there is no need to introduce redundant placeholders, and the data in each target two-dimensional array have strong topological correlation. This allows the compression encoding algorithm to make full use of spatial prediction advantages for encoding, improving the overall compression efficiency.
Smart Images

Figure CN122621174A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of meteorological data processing, and in particular to a meteorological data processing method, electronic device, and storage medium. Background Technology
[0002] Currently, mainstream high-precision meteorological models generally adopt octahedral Gaussian grids (OGG), which, compared to traditional latitude and longitude grids, can eliminate polar grid singularities and have higher computational efficiency. However, octahedral Gaussian grid meteorological data is massive in scale, placing enormous pressure on data storage and transmission. Existing compression algorithms have poor compression performance for octahedral Gaussian grid meteorological data, making it difficult to meet practical application requirements. Therefore, improving the compression efficiency of octahedral Gaussian grid meteorological data has become an urgent problem to be solved. Summary of the Invention
[0003] The main objective of this application is to propose a meteorological data processing method, electronic device, and storage medium, which aims to improve the compression efficiency of octahedral Gaussian grid meteorological data.
[0004] To achieve the above objectives, a first aspect of this application proposes a meteorological data processing method, the method comprising: Acquire first meteorological data, wherein the first meteorological data is octahedral Gaussian grid data; The first meteorological data is divided into latitude and longitude regions to obtain multiple first spherical triangular block data of the Northern Hemisphere and second spherical triangular block data of the Southern Hemisphere, wherein the first spherical triangular block data and the second spherical triangular block data correspond one-to-one; Each of the first spherical triangle block data is processed by rectangularization to obtain a first two-dimensional array that corresponds one-to-one with the first spherical triangle block data; Each of the second spherical triangle block data is processed by rectangularization to obtain a second two-dimensional array that corresponds one-to-one with the second spherical triangle block data; The first two-dimensional array and the second two-dimensional array, which indicate the geographical region as a north-south mirror image, are complementaryly spliced together to generate the target two-dimensional array; The multiple target two-dimensional arrays are compressed and encoded to generate a first meteorological data bitstream.
[0005] To achieve the above objectives, a second aspect of this application provides an electronic device, which includes a memory and a processor. The memory stores a computer program, and the processor executes the computer program to implement the method described in the first aspect.
[0006] To achieve the above objectives, a third aspect of the present application provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the method described in the first aspect.
[0007] The meteorological data processing method, electronic device, and storage medium proposed in this application firstly divide the first meteorological data into spherical triangular blocks corresponding to the Northern and Southern Hemispheres by latitude and longitude regions. This preserves the adjacency relationship of each spherical triangular block in physical space and reduces the impact of data jumps on subsequent processing. Secondly, the triangular blocks in the Northern and Southern Hemispheres are rectangularized and mapped into a planar two-dimensional array structure, resulting in a first two-dimensional array and a second two-dimensional array. Then, the first and second two-dimensional arrays, which are geographically mirror-symmetrical north and south, are complementaryly concatenated to generate regular target two-dimensional arrays, thereby restoring the topological correlation of meteorological data in two-dimensional space and reducing redundant space occupation. Finally, multiple target two-dimensional arrays are compressed and encoded. Since each target two-dimensional array is a complementary concatenation of the first and second two-dimensional arrays that are mirror-symmetrical north and south, there is no need to introduce redundant placeholders, and the data in each target two-dimensional array have strong topological correlation. This allows the compression encoding algorithm to make full use of spatial prediction advantages for encoding, improving the overall compression efficiency. Attached Figure Description
[0008] Figure 1 This is an application environment diagram of a meteorological data processing method in one embodiment; Figure 2 This is a flowchart of a meteorological data processing method in one embodiment; Figure 3 This is a composite image of meteorological data processing methods in one embodiment, showing data from the Northern and Southern Hemispheres. Figure 4 This is a schematic diagram of the structure of a meteorological data processing system in one embodiment; Figure 5 This is a schematic diagram of the meteorological data processing method in one embodiment; Figure 6 This is a schematic diagram of the hardware structure of the electronic device provided in the embodiments of this application. Detailed Implementation
[0009] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.
[0010] The terms "first," "second," etc., used in the specification, claims, and the above-mentioned drawings are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence.
[0011] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used herein is for the purpose of describing embodiments of this application only and is not intended to limit this application.
[0012] With the rapid development of global climate observation and high-resolution numerical weather prediction technologies, the volume of meteorological data is growing exponentially. Currently, mainstream high-precision meteorological models widely adopt octahedral Gaussian grids (OGG). Compared to traditional latitude and longitude grids, OGG has no grid singularity in polar regions, resulting in higher computational efficiency. However, OGG meteorological data, often reaching petabyte levels, places enormous pressure on storage and network transmission. Therefore, compressing meteorological data using efficient scientific data compression algorithms has become an urgent need. The core principle of modern data compression algorithms is to use the local smoothness (spatial correlation) of data in two-dimensional or three-dimensional space for predictive encoding. The number of OGG grid points varies with latitude and must be "flattened" into a one-dimensional array for storage in memory. This one-dimensional storage format severely disrupts the spatial correlation of the meteorological field on a two-dimensional sphere. Currently, there are three main schemes for OGG data compression: direct one-dimensional compression, interpolation resampling transformation, and zero-padding alignment. Direct one-dimensional compression directly inputs a one-dimensional OGG array into the compressor. However, because the one-dimensional OGG array loses the spatial two-dimensional / three-dimensional correlation of the data, there are drastic physical spatial jumps at the polar regions and longitude seams, making the compressor ineffective for prediction and resulting in extremely low compression ratios. Interpolation resampling transformation first resamples the OGG grid into a regular two-dimensional latitude and longitude grid using bilinear or bicubic interpolation before performing two-dimensional compression. However, this scheme disrupts the mathematical closure of the original forecast data, introducing interpolation errors. Furthermore, the data volume expands after interpolation in high-latitude regions, reducing the scientific fidelity of meteorological data, and the compression process is time-consuming. Zero-padding alignment uses the grid number of the longest latitude circle at the equator as a benchmark, filling the ends of shorter high-latitude latitude circles with zeros or invalid values, forcibly aligning them into a two-dimensional rectangular matrix. However, zero-padding alignment introduces a large number of redundant placeholders, resulting in an extremely sparse matrix. This increases the computational overhead of compression and decompression, wasting memory and interfering with the dictionary generation or prediction accuracy of the compression algorithm. In other words, existing compression schemes for OGG data have poor compression performance and are difficult to meet practical application requirements. Therefore, this application provides a meteorological data processing method, electronic device, and storage medium to improve the compression efficiency of octahedral Gaussian grid meteorological data.
[0013] The meteorological data processing method, electronic device, and storage medium provided in this application are specifically described through the following embodiments. First, the meteorological data processing method in this application embodiment is described.
[0014] The meteorological data processing method provided in this embodiment of the invention can be applied to, for example, Figure 1 In the application environment, client 110 communicates with server 120 via a network. Server 120 receives first meteorological data from client 110. Then, server 120 divides the first meteorological data into latitude and longitude regions to obtain multiple first spherical triangular block data of the Northern Hemisphere and second spherical triangular block data of the Southern Hemisphere. The first spherical triangular block data and the second spherical triangular block data correspond one-to-one. Then, server 120 performs rectangularization processing on each first spherical triangular block data to obtain a first two-dimensional array corresponding to the first spherical triangular block data. At the same time, server 120 performs rectangularization processing on each second spherical triangular block data to obtain a second two-dimensional array corresponding to the second spherical triangular block data. Then, server 120 performs complementary splicing of the first two-dimensional array and the second two-dimensional array, which indicate that the geographical area is mirror-symmetric in the north-south direction, to generate a target two-dimensional array. Finally, server 120 compresses and encodes multiple target two-dimensional arrays to generate a first meteorological data bitstream. By segmenting the first meteorological data into latitude and longitude regions to obtain spherical triangular blocks corresponding one-to-one with the Northern and Southern Hemispheres, the adjacency relationship of each spherical triangular block in physical space can be preserved, reducing the impact of data jumps on subsequent processing. Next, the triangular blocks in the Northern and Southern Hemispheres are rectangularized and mapped into planar two-dimensional array structures, resulting in a first two-dimensional array and a second two-dimensional array. Then, the geographically mirror-symmetrical first and second two-dimensional arrays are complementaryly concatenated to generate regular target two-dimensional arrays, thereby restoring the topological correlation of meteorological data in two-dimensional space and reducing redundant space occupation. Finally, multiple target two-dimensional arrays are compressed and encoded. Since each target two-dimensional array is a complementary concatenation of the north-south mirror-symmetrical first and second two-dimensional arrays, there is no need to introduce redundant placeholders, and the data in each target two-dimensional array have strong topological correlation. This allows the compression encoding algorithm to more fully utilize the advantages of spatial prediction for encoding, improving overall compression efficiency. The client 110 can be, but is not limited to, various personal computers, laptops, smartphones, tablets, and portable wearable devices. The server 120 can be implemented using a standalone server or a server cluster consisting of multiple servers. The present invention will now be described in detail through specific embodiments.
[0015] Figure 2This is an optional flowchart of the meteorological data processing method provided in the embodiments of this application. Figure 2 The method may include, but is not limited to, steps S101 to S106.
[0016] Step S101: Obtain first meteorological data, wherein the first meteorological data is octahedral Gaussian grid data; Step S102: The first meteorological data is divided into latitude and longitude regions to obtain multiple first spherical triangular block data of the Northern Hemisphere and second spherical triangular block data of the Southern Hemisphere, wherein the first spherical triangular block data and the second spherical triangular block data correspond one-to-one; Step S103: Perform rectangularization on each of the first spherical triangle block data to obtain a first two-dimensional array that corresponds one-to-one with the first spherical triangle block data; Step S104: Perform rectangularization on each of the second spherical triangle block data to obtain a second two-dimensional array that corresponds one-to-one with the second spherical triangle block data; Step S105: The first two-dimensional array and the second two-dimensional array, which indicate that the geographical region is mirror-symmetric in the north-south direction, are complementaryly spliced together to generate the target two-dimensional array. Step S106: Compress and encode the multiple target two-dimensional arrays to generate a first meteorological data bitstream.
[0017] First, by segmenting the first meteorological data into latitude and longitude regions, spherical triangular blocks corresponding one-to-one with the Northern and Southern Hemispheres are obtained. This preserves the adjacency relationship of each spherical triangular block in physical space, reducing the impact of data jumps on subsequent processing. Second, the triangular blocks in the Northern and Southern Hemispheres are rectangularized and mapped into planar two-dimensional array structures, resulting in a first two-dimensional array and a second two-dimensional array. Then, the geographically mirror-symmetrical first and second two-dimensional arrays are complementaryly concatenated to generate regular target two-dimensional arrays, thereby restoring the topological correlation of meteorological data in two-dimensional space and reducing redundant space occupation. Finally, multiple target two-dimensional arrays are compressed and encoded. Since each target two-dimensional array is a complementary concatenation of the north-south mirror-symmetrical first and second two-dimensional arrays, there is no need to introduce redundant placeholders, and the data in each target two-dimensional array have strong topological correlation. This allows the compression encoding algorithm to fully utilize the advantages of spatial prediction for encoding, improving the overall compression efficiency.
[0018] The Octahedral Gaussian Grid (OGG) is a global unstructured grid used by mainstream meteorological models. Its characteristic is that the number of grid points on each latitude circle decreases linearly from the equator to the poles. The first meteorological data is octahedral Gaussian Grid (OGG) data, which can be stored in memory as a one-dimensional array. Each element in this array corresponds to a meteorological observation or forecast value for a grid point, such as temperature, air pressure, wind speed, humidity, and precipitation. The first spherical triangular block data is the set of meteorological data corresponding to the spherical triangular blocks in the Northern Hemisphere, and the second spherical triangular block data is the set of meteorological data corresponding to the spherical triangular blocks in the Southern Hemisphere. The spherical triangular blocks in the Northern and Southern Hemispheres can be obtained by dividing the global OGG grid along the equator and four equidistant meridians. Each spherical triangular block corresponds to a spherical region within a 90-degree longitude interval.
[0019] For example, on a sphere, the OGG (Ocean Geographic Geometry) can be divided into eight spherical triangular blocks by four equidistant meridians (with longitude intervals of 90°) and the equator. There are four spherical triangular blocks in the Northern Hemisphere and four in the Southern Hemisphere. As an example, the first meteorological data is a one-dimensional array V[K], where K refers to the total number of grid points. The indices of V[K] are segmented according to the latitude and longitude intervals of the equator, yielding arrays corresponding to the four spherical triangular blocks in the Northern Hemisphere and the four in the Southern Hemisphere. The array corresponding to one spherical triangular block in the Northern Hemisphere is considered as the first spherical triangular block data, and the array corresponding to one spherical triangular block in the Southern Hemisphere is considered as the second spherical triangular block data. The longitude intervals are [0°, 90°), [90°, 180°), [180°, 270°), and [270°, 360°). The arrays corresponding to the four spherical triangular blocks in the Northern Hemisphere are denoted as... , , , These are arrays corresponding to the longitude intervals [0°, 90°), [90°, 180°), [180°, 270°), and [270°, 360°); the data for the four spherical triangular blocks in the Southern Hemisphere are denoted as... , , , These are arrays that correspond one-to-one with the longitude intervals [0°, 90°), [90°, 180°), [180°, 270°), and [270°, 360°].
[0020] This application does not limit how the first meteorological data is obtained. For example, in some embodiments, the first meteorological data V[K] arranged in one dimension is read from the original meteorological model output file.
[0021] This application does not limit how latitude and longitude regions are segmented. In some embodiments, a pre-calculated OGG grid index lookup table (LUT) records the physical latitude and longitude coordinates of each index K in the first meteorological data V[K], along with the identifier of the corresponding spherical triangle block. Based on the OGG grid index lookup table, the one-dimensional meteorological data array V[K] is precisely segmented into eight spherical triangle blocks according to latitude and longitude intervals. Specifically, each element V[K] in the one-dimensional meteorological data array is traversed, and the latitude and longitude corresponding to each element are obtained by querying a lookup table. For elements located in the Northern Hemisphere, they are assigned to the corresponding first spherical triangle block data in the Northern Hemisphere according to the longitude interval of the element's corresponding longitude. The first spherical triangle block data can be in the form of a one-dimensional array, and the longitude interval can be [0°, 90°), [90°, 180°), [180°, 270°), [270°, 360°). For elements located in the Southern Hemisphere, they are assigned to the corresponding second spherical triangle block data in the Southern Hemisphere according to the longitude interval of the element's corresponding longitude. The second spherical triangle block data can also be in the form of a one-dimensional array. For elements located at the equator, poles, or longitude quadrant boundaries, their corresponding spherical triangle block data is determined according to a preset unique assignment rule to avoid duplicate data assignment or omission.
[0022] This application does not limit how each of the first spherical triangle block data is processed for rectangularization. For example, in some embodiments, rectangularization transformation is performed on the first spherical triangle block data for each Northern Hemisphere. Taking advantage of the characteristic that the number of grid points in the OGG grid increases in an arithmetic sequence from the pole to the equator, the spherical triangle block data is mapped to the corresponding positions in the two-dimensional array through index mapping to generate the first two-dimensional array. As a preferred embodiment, an N-row × N-column two-dimensional array of the Northern Hemisphere is created, where N is the number of discrete grids on the equator corresponding to the first spherical triangular block data, that is, the number of meteorological data on the equator in the first spherical triangular block data, which is the same as the number of discrete grids; meteorological data of the same latitude in the first spherical triangular block data are all regarded as the first meteorological data set; the meteorological data in each of the first meteorological data sets are sorted and the first meteorological data sets are sorted to obtain the second meteorological data sets arranged in sequence; the Northern Hemisphere two-dimensional array is traversed row by row to determine the second meteorological data set at the same position as the traversed row of the Northern Hemisphere two-dimensional array, and the meteorological data of the determined second meteorological data set are sequentially filled into different columns of the traversed row of the Northern Hemisphere two-dimensional array to obtain the first two-dimensional array.
[0023] As an example, create a two-dimensional array of size N rows × N columns as the Northern Hemisphere two-dimensional array, and initialize the Northern Hemisphere two-dimensional array with null or invalid values. Iterate through all elements in the first spherical triangular block data, grouping them according to their corresponding latitude values, and grouping all elements of the same latitude into a first meteorological data set. Sort all first meteorological data sets in descending order of latitude (from pole to equator); then sort the elements within each first meteorological data set in ascending order of longitude (from west to east), and combine the first meteorological data sets after these two sortings into their respective second meteorological data sets. Iterate through the Northern Hemisphere two-dimensional array row by row, the first... OK( (from 0 to N-1) corresponds to the... The second meteorological data set is used to sequentially fill the elements of this second meteorological data set into the second two-dimensional array of the Northern Hemisphere. The 0th column to the 1st column Columns. After filling, the effective data is only distributed along the main diagonal and lower left corner of the two-dimensional array in the Northern Hemisphere, forming a lower triangular distribution of the first two-dimensional array. Among them, the row index... Represents latitude levels; row 0 corresponds to the vicinity of the poles or the pole level, and row N-1 corresponds to the equatorial level; column index. This represents the discrete longitude position within the current latitude level. In this embodiment, by creating an N×N two-dimensional array corresponding to the grid resolution, the spatial integrity of the data mapping is ensured; meteorological data at the same latitude are grouped into a set and sorted, so that the arrangement order of meteorological data in the two-dimensional array is completely consistent with the latitude and longitude order in physical space, strictly preserving the spatial correlation of the data; the row-by-row filling method matches the geometric characteristics of the OGG grid, where the number of grid points gradually increases from the pole to the equator, ensuring the accuracy and efficiency of the rectangularization process. This process does not involve any floating-point operations, resulting in extremely low computational overhead and improving the efficiency of subsequent compression.
[0024] This application does not limit how the data for each of the second spherical triangular blocks is processed for rectangularization. For example, in some embodiments, the same rectangularization method as in the Northern Hemisphere is used to process the data for each of the second spherical triangular blocks in the Southern Hemisphere to generate a second two-dimensional array. In a preferred embodiment, an N-row × N-column two-dimensional array of the Southern Hemisphere is created, where N is the number of discrete grids on the equator corresponding to the second spherical triangular block data, i.e., the number of meteorological data on the equator in the second spherical triangular block data, which is the same as the number of discrete grids; meteorological data at the same latitude in the second spherical triangular block data are all used as a third meteorological data set; the meteorological data in each of the third meteorological data sets are sorted, and the third meteorological data sets are sorted to obtain sequentially arranged fourth meteorological data sets; the Southern Hemisphere two-dimensional array is traversed row by row to determine the fourth meteorological data set at the same position as the traversed row of the Southern Hemisphere two-dimensional array, and the meteorological data of the determined fourth meteorological data set are sequentially filled into different columns of the traversed row of the Southern Hemisphere two-dimensional array to obtain a second two-dimensional array.
[0025] As an example, a two-dimensional array of the Southern Hemisphere with dimensions N rows × N columns can be created, initialized with null or invalid values. Iterate through all elements in the second spherical triangular block data, grouping them according to their latitude values, and grouping all elements of the same latitude into a third meteorological data set. Sort all third meteorological data sets in descending latitude (from the South Pole to the Equator); then sort the elements in each third meteorological data set in west-to-east longitude order, combining the three sorted third meteorological data sets into their respective fourth meteorological data sets. Iterate through the Southern Hemisphere two-dimensional array row by row, the first row... OK( (from 0 to N-1) corresponds to the... The fourth meteorological data set. Elements from the fourth meteorological data set are sequentially filled into the second element of the Southern Hemisphere two-dimensional array. The 0th column to the 1st column After filling, the effective data is only distributed along the main diagonal and lower left corner of the two-dimensional array in the Southern Hemisphere, forming a second two-dimensional array with a lower triangular distribution.
[0026] This application does not limit how complementary splicing is performed. In a preferred embodiment, the second two-dimensional array is subjected to a two-dimensional plane central symmetric flipping process to generate a third two-dimensional array; the first two-dimensional array and the third two-dimensional array are complementaryly spliced to generate an initial two-dimensional array; the data elements on the main diagonal of the initial two-dimensional array are smoothed to obtain the target two-dimensional array, wherein a total of 4 target two-dimensional arrays are generated from the first meteorological data.
[0027] As an example, a two-dimensional plane central symmetry flipping operation is performed on a second two-dimensional array of N rows × N columns. Specifically, for a valid element at index ([[]] , ) in the second two-dimensional array (0 ≤ [[[]] ≤[[[]] < N), it is mapped to the coordinate position (N - 1 - [[[]] , N - 1 - [[[]] ) in the second two-dimensional array to obtain a third two-dimensional array, thus rotating 180 degrees. "Rotating 180 degrees" does not actually move physical pixels, but is achieved through the inverse mapping of coordinate indices. After the flipping is completed, the valid data of the third two-dimensional array is distributed in the upper right corner area of the main diagonal. Then, an initial two-dimensional array with a size of N × N is created, and each coordinate position ([[[]] , ) in the initial two-dimensional array is traversed. The elements of the first two-dimensional array are assigned to the initial two-dimensional array in index order; the elements of the third two-dimensional array are assigned to the initial two-dimensional array in index order. After the splicing is completed, the initial two-dimensional array is a 100% dense regular matrix.
[0028] As an example, as [[[]] Figure 3 shown, [[[]] Figure 3 the northern hemisphere triangle ([[[]] ) in [[[]] fills the main diagonal and the lower left corner area of the matrix, and the northern hemisphere triangle ([[[]] ) is the first two-dimensional array. The southern hemisphere triangle ([[[]] ) is the second two-dimensional array, and the rotated southern hemisphere triangle ([[[]] ) is in the upper right corner area of the filled matrix, and the rotated southern hemisphere triangle ([[[]] ) is the third two-dimensional array. The hypotenuses of both (corresponding to the meridional cutting lines) perfectly fit on the main diagonal of the square matrix M. If the northern hemisphere triangle ([[[]] ) and the southern hemisphere triangle ([[[]] [[ID=##]] ) are directly sent for compression, conventional compression algorithms, which only recognize rectangular blocks, cannot handle them; if they are forcibly complemented into rectangles, half of the storage space will be wasted. To eliminate the irregular shape, a "two-dimensional space rotation (or central symmetry flipping)" operation is performed on the southern hemisphere triangle ([[[]] ). That is, it is rotated by 180 degrees on the logical plane, so that its right-angled vertex is transferred from the lower left corner to the upper right corner, and the hypotenuse that originally faced the right now faces the lower left side. It should be noted that in the underlying implementation of the software code, this "rotation of 180 degrees" does not actually move physical pixels, but is achieved through the inverse mapping of coordinate indices. The hypotenuse is actually a "longitude-direction cutting line" formed by connecting the grid points at the end (or the front) of each latitude circle. When splicing, the rotated southern hemisphere triangle ( ) and the Northern Hemisphere triangle ( The triangles are precisely folded and joined together seamlessly along this longitudinal cutting line (hypotenuse). As another example, in a two-dimensional mapping, the acute vertex of a right triangle corresponds to the pole (1 grid point), the longest right-angled base corresponds to the equator (N grid points), and the hypotenuse corresponds to the longitudinal grid boundary cutting line. The rotated Southern Hemisphere triangle (… ) and the Northern Hemisphere triangle ( (This is precisely because the southern hemisphere triangle is formed by complementary joining along its hypotenuse.) ) and the Northern Hemisphere triangle ( The length of the hypotenuse (longitude boundary) and the number of data points are exactly the same, and they fit together perfectly along the diagonal (hypotenuse) to form a perfect square matrix M. The main diagonal and lower left corner area are formed by Fill. Matrix The upper right corner area is rotated Filling. Through this "geometric jigsaw puzzle" operation, two irregular data blocks are merged into a standard two-dimensional tensor that is 100% filled and has no redundant placeholders, so that subsequent two-dimensional / three-dimensional data compression algorithms can run in the most efficient full-load state.
[0029] It should be noted that the first two-dimensional array is a spherical triangular block indicating the geographical region as the Northern Hemisphere, and the second two-dimensional array is a spherical triangular block indicating the geographical region as the Southern Hemisphere. These two spherical triangular blocks are mirror-symmetrical.
[0030] As yet another example, the corresponding size for the Northern Hemisphere is The first two-dimensional array The dimensions corresponding to the Southern Hemisphere are The second two-dimensional array Perform complementary splicing to create a size of initial two-dimensional array The matrix assignment mapping formula is as follows: ; in, For row index, For column indices, the second two-dimensional array After coordinate transformation This achieves a centrally symmetrical flip on a two-dimensional plane. At this point, the hypotenuses of both perfectly fit along the main diagonal of the matrix, forming a 100% dense rectangular matrix. The upper right triangular area of the matrix corresponds to a rotation of 180 degrees. , The lower left triangular region of the matrix corresponds to the first two-dimensional array. .
[0031] This application does not limit the compression algorithm used for compression encoding. For example, in some embodiments, multiple generated target two-dimensional arrays are input into a preset compression encoder for compression encoding, and the compression encoder outputs a first meteorological data bitstream. The compression encoder can use a lossy compression algorithm with error limits or a lossless compression algorithm.
[0032] Understandably, in one embodiment, the meteorological data processing method further includes: acquiring a second meteorological data bitstream, wherein the second meteorological data bitstream is generated using the same method as the first meteorological data bitstream; decompressing the second meteorological data bitstream to obtain multiple target two-dimensional arrays to be split; splitting the target two-dimensional arrays to be split to obtain a fourth two-dimensional array and a fifth two-dimensional array indicating that the geographical region is mirror-symmetric in a north-south direction; performing inverse right-angle conversion on the fourth two-dimensional array to obtain third spherical triangle block data for the Northern Hemisphere, wherein the fourth two-dimensional array corresponds one-to-one with the third spherical triangle block data; performing inverse right-angle conversion on the fifth two-dimensional array to obtain fourth spherical triangle block data for the Southern Hemisphere, wherein the fifth two-dimensional array corresponds one-to-one with the fourth spherical triangle block data; and splicing the third spherical triangle block data and the fourth spherical triangle block data by latitude and longitude regions to obtain the second meteorological data array. This method can restore the second meteorological data bitstream to a second meteorological data array, achieving complete closed-loop processing of meteorological data. By acquiring the compressed second meteorological data bitstream and decompressing it, a second meteorological data array consistent with the original input format can be obtained. This process is completely transparent to the upper-level meteorological application software, and the decompressed data can be used directly without modifying the original code.
[0033] Understandably, the smoothing of the data elements on the main diagonal of the initial two-dimensional array to obtain the target two-dimensional array includes: S201, take each meteorological data element on the main diagonal of the initial two-dimensional array as a boundary data point; S202, Select multiple meteorological data elements in the initial two-dimensional array whose distance from the boundary data points satisfies a preset distance, and obtain multiple reference samples corresponding to each boundary data point; S203, based on multiple reference samples of each boundary data point, obtain the meteorological data prediction value of each boundary data point; S204, Based on the boundary data points and the corresponding meteorological data prediction values, determine the residuals; S205, in the initial two-dimensional array, the boundary data points are replaced with the residuals to obtain the target two-dimensional array.
[0034] The target two-dimensional array is a regular matrix. Since the main diagonal of the regular matrix is the physical seam where data from the Northern and Southern Hemispheres meet, the values here may exhibit discontinuous jumps, and direct compression would reduce encoding efficiency. By using the elements on the main diagonal as boundary data points, selecting their neighboring elements as reference samples to calculate predicted values, and then replacing the original values with the residuals between the original and predicted values, high-frequency numerical jumps at the seams can be effectively eliminated without sacrificing data accuracy. Because the residual values are much smaller than the original jump values, the compression algorithm maintains a very high spatial prediction hit rate when compressing and encoding the processed array, further improving the compression ratio. It should be noted that during the decompression stage, the original data values can be recovered through the reverse residual restoration operation.
[0035] As an example, the initial two-dimensional array is ,in, Row index and It is a column index in the initial two-dimensional array. = The corresponding elements are those on the main diagonal, marked as boundary data points. For each boundary data point, two neighboring data elements in the initial two-dimensional array that satisfy a preset distance condition are selected as reference samples. For example, the elements to the right of the boundary data point can be selected. and above As a reference sample, these two points are adjacent to the boundary data points on the physical sphere.
[0036] Based on the reference sample, a preset prediction algorithm is used to calculate the predicted meteorological data value P for the boundary data points. , The average value of adjacent points can be used as the predicted value: P[ , ]=( + ) / 2.
[0037] Calculate the difference between the original and predicted values of the boundary data points to obtain the residual Δ[ , The residual is calculated as follows: Δ[ , ]= -P[ , Because meteorological data has strong spatial correlation, the residual value usually approaches 0.
[0038] Finally, the original values of the boundary data points in the initial two-dimensional array are replaced with the corresponding residuals Δ[ , ], to generate a smoothed target two-dimensional array.
[0039] Understandably, there are multiple sets of the first meteorological data; each set of the first meteorological data corresponds to at least one stacking dimension; the step of compressing and encoding the multiple target two-dimensional arrays to generate the first meteorological data bitstream includes: S301, stack multiple target two-dimensional arrays of the same stacking dimension vertically to obtain an initial tensor; S302, according to the size of the stacking dimension, stack the initial tensors one on top of the other to obtain the target tensor; S303, Based on the preset compression encoder and the target tensor, a first meteorological data bitstream is generated, wherein the stacking dimension includes at least one of the atmospheric vertical height dimension, variable dimension, and time dimension.
[0040] By stacking multiple target two-dimensional arrays with the same stacking dimension into an initial tensor, and then stacking them according to their dimension size into a higher-dimensional target tensor, the correlation of meteorological data across multiple dimensions such as atmospheric vertical height, channel, variable, and time can be fully utilized, further improving the coding efficiency of the compression algorithm. Furthermore, the flexible combination of various stacking dimensions can adapt to the compression requirements of different types of meteorological data, demonstrating strong versatility.
[0041] The stacking dimension is used to combine the dimensions of multiple target two-dimensional arrays, including the atmospheric vertical height dimension, variable dimension, and time dimension. For example, the atmospheric vertical height dimension refers to meteorological data corresponding to different atmospheric vertical height dimensions, such as meteorological data at 1000 hPa, 850 hPa, and 700 hPa. The time dimension refers to meteorological data at different times and different forecast times. The variable dimension can be different meteorological physical quantities, such as temperature, humidity, and air pressure. The initial tensor is a three-dimensional data structure formed by stacking multiple target two-dimensional arrays under the same stacking dimension. The target tensor is a multi-dimensional data structure formed by further stacking multiple initial tensors along the stacking dimension. For example, when the stacking dimension is the atmospheric vertical height dimension, the format of the target tensor is [L×4×N×N], where L is the number of vertical layers, 4 is the number of longitude quadrants, and N is the grid resolution.
[0042] The preset compression encoder can be a pre-configured algorithm module for compressing and encoding multidimensional tensors, supporting error-constrained lossy compression algorithms or lossless compression algorithms.
[0043] As an example, multiple target 2D arrays under the same stacking dimension are stacked vertically along a direction perpendicular to the 2D plane to form a 3D initial tensor. For example, target 2D arrays corresponding to the four longitude quadrants of the same height layer are stacked along the channel dimension to form an initial tensor of shape [4×N×N].
[0044] Based on the size of the stacking dimension, multiple initial tensors are stacked sequentially up and down along that dimension to form a higher-dimensional target tensor. For example, if the original data contains L atmospheric vertical height layers, then L initial tensors of shape [4×N×N] are stacked along the height dimension to form a four-dimensional target tensor of shape [L×4×N×N].
[0045] The target tensor is input into a preset compression encoder for compression encoding. If an error-constrained lossy compression algorithm is used, the meteorological data before and after compression must meet the following requirements. ,in This represents the maximum acceptable absolute error in meteorology, used to limit the numerical deviation between the same meteorological data point before and after compression. This indicates that the coordinates in the target tensor before compression encoding are... The original meteorological data values.
[0046] in, This indicates that after decompressing and restoring the first meteorological data bitstream, the coordinates are in the target tensor. The meteorological data values recovered at the corresponding locations. , , Let be the coordinate index in the target tensor, where This represents the row index in the target two-dimensional array. This represents the column index in the target two-dimensional array. The stacked dimension index represents the target two-dimensional array, which is used to indicate at least one of different atmospheric vertical height layers, different meteorological variables, different time layers, or different longitude quadrants.
[0047] In some embodiments, the error constraint applies to every meteorological data point in the target tensor, that is, for any coordinate in the target tensor. All satisfy the above error constraints. The maximum permissible absolute error threshold... It can be preset according to the type of meteorological data and the required operational accuracy. For example, when the meteorological data is temperature data, the maximum permissible absolute error threshold can be set in advance. Can be set to When the meteorological data is air pressure, humidity, wind speed, or precipitation data, the maximum permissible absolute error threshold is... The settings can be configured according to the allowable error range of the corresponding meteorological elements. After the compression encoder completes the encoding, it generates the first meteorological data bitstream.
[0048] In other embodiments, when the target tensor is a four-dimensional tensor, any meteorological data point in the target tensor can be represented by coordinates. It means that, among them, This represents the index of the first stacked dimension in the target tensor, used to indicate one of the following: atmospheric vertical height layer, meteorological variable, or time layer. This indicates a longitude quadrant index or a channel index. This represents the row index in the target two-dimensional array. This represents the column index in the target two-dimensional array. Correspondingly, the meteorological data before and after compression satisfy... .in, This indicates that the coordinates in the target tensor before compression encoding are... The original meteorological data values. This indicates that after decompressing and restoring the first meteorological data bitstream, the coordinates are in the target tensor. The meteorological data values recovered at the corresponding locations. This represents the preset maximum permissible absolute error threshold. The above error constraint is used to ensure that the decompressed and restored meteorological data is close to the original meteorological data before compression within the preset error range.
[0049] In a preferred embodiment, referencing Figure 4 The technical solution of the present invention will be further described, and a meteorological data processing system is proposed. The system includes a user terminal and access layer, an auxiliary support module, a core processing platform, a storage layer, and an external service interface.
[0050] (1) User terminals and access layer include user terminals and access layer. User terminals: for meteorological researchers, forecasters or automated meteorological business systems. Users submit storage / compression requests for massive amounts of meteorological data or initiate requests to retrieve and decompress historical data through the terminal. Access layer: as the unified API gateway of the system, it is responsible for receiving high-concurrency meteorological data processing requests, performing flow control and load balancing, and distributing requests to the backend support modules and core processing platform.
[0051] (2) The auxiliary support modules include an authentication module, a task management module, and a log module. The authentication module authenticates and verifies the permissions of users or subsystems requesting access to the high-precision meteorological dataset. The task management module manages the asynchronous computing queue in the background, slicing and scheduling petabyte-scale global grid compression tasks (e.g., allocating them to different computing nodes by meteorological variables or by altitude layer). The log module records the system status throughout the entire lifecycle of meteorological data processing, especially recording the data volume before and after compression, compression time, set error limits, and accuracy verification logs for decompression and restoration.
[0052] (3) The core processing platform includes a data acquisition module, a preprocessing module, an analysis engine, a rule engine, and a result generation module. Data acquisition module: responsible for reading one-dimensional octahedral Gaussian grid (OGG) data arrays from the original meteorological model output files. The octahedral Gaussian grid (OGG) data array is the first meteorological data, and extracting dimensional information (such as the number of grids at the equator, the number of vertical layers, etc.). Preprocessing module (patch segmentation): based on the mathematical topological relationship of OGG, generates a one-dimensional to two-dimensional mapping lookup table, logically dividing the global one-dimensional grid data into 8 spherical triangular blocks (4 in the Northern Hemisphere and 4 in the Southern Hemisphere). Analysis engine (core of regularized mapping calculation): using the lookup table generated by preprocessing, performs high-speed "geometric folding and complementary splicing" in memory; seamlessly splices the Southern Hemisphere patches after rotation / flipping with the Northern Hemisphere patches, converting the irregular one-dimensional array into a 100% dense regular two-dimensional / three-dimensional tensor, perfectly restoring the spatial topological correlation of the data. Rule Engine: Dynamically allocates compression strategies based on the compression requirements specified by the user terminal. For example, it determines the appropriate smoothness prediction model for the current meteorological variables (such as temperature and precipitation); applies the "boundary smoothness prediction penalty" rule at the seams; dynamically decides whether to call the underlying SZ, ZFP, or lossless compression algorithm, and sets reasonable absolute / relative error thresholds. Result Generation Module: Performs underlying data compression encoding (or decompression and decoding). It converts the rule tensors generated by the analysis engine into a high-compression-ratio binary bitstream and encapsulates necessary metadata (such as grid resolution parameters, mapping version numbers, etc.) to generate the final archiveable compressed file. If a decompression request is made, it performs reverse splitting and one-dimensional rearrangement to generate the original one-dimensional OGG format data and feeds it back to the user.
[0053] (4) The storage layer includes a relational database, file storage units, and a caching unit. Relational database: stores metadata indexes (time, variable type, spatial range) of meteorological data, system configuration parameters, and the aforementioned fixed "Mapping Lookup Table (LUT)". File storage unit: uses a distributed file system (such as HDFS, Ceph, or S3 object storage) to securely and persistently store massive compressed binary meteorological data blocks. Because this invention significantly improves the compression rate, the hardware storage cost of this unit will be greatly reduced. Caching unit: (such as a Redis / Memcached cluster) is used for high-speed caching of hot meteorological data or caching frequently used spatial mapping lookup tables to achieve real-time, memory-level regularized reordering speed.
[0054] (5) External service interface. The compressed / decompressed standardized meteorological data streams are pushed or distributed to external meteorological business systems (such as disaster early warning platforms, aviation meteorological services, and meteorological bureau nodes in various provinces and cities) through the external service interface, supporting lightweight data transmission under high-speed networks.
[0055] In yet another preferred embodiment, reference is made to... Figure 5 The technical solution of the present invention will be further described below, with specific steps as follows: Step A: Data Parsing and Patch Segmentation Module. Input Format: Receives a one-dimensional OGG meteorological sequence (as shown in the one-dimensional array column on the left side of the figure) output by a weather forecasting model (such as IFS). This one-dimensional OGG meteorological sequence is the first meteorological data. Because the Earth's spherical grid is forcibly flattened into one dimension, adjacent array elements may exhibit significant jumps across polar regions or longitude seams in real physical space. Processing: Based on the geometric topological definition of the octahedral Gaussian grid, the global sphere is logically segmented into 8 spherical triangular patch data along the equator and four equidistant meridians (intervals of 90 degrees). Morphological Evolution: The one-dimensional sequence is precisely segmented into 4 in the Northern Hemisphere and 4 in the Southern Hemisphere, totaling 8 discrete spherical triangular patches. These discrete spherical triangular patches are the spherical triangular patch data. At this stage, the grid points within each patch still retain a high degree of local physical correlation.
[0056] Step B: Topology-preserving right-angled and complementary stitching module. Process: This is a crucial step in breaking down the barriers of unstructured meshes, involving two steps: "right-angled" and "rotation and complementary stitching." First, right-angled: Utilizing the property that the number of mesh points in the OGG mesh increases arithmetically from the poles to the equator, spherical triangular faces are directly rearranged into discrete isosceles right-angled triangle matrices through memory index mapping. Next is rotation and complementary stitching: Take the isosceles right-angled triangle matrix corresponding to a spherical triangular facet in the Northern Hemisphere (e.g., facet 1) and the isosceles right-angled triangle matrix corresponding to a spherical triangular facet in the Southern Hemisphere (e.g., facet 5). The spherical triangular facet in the Southern Hemisphere is then centrally symmetrically flipped (or rotated 180 degrees) in a two-dimensional plane. Morphological evolution: The rotated spherical triangular facet in the Southern Hemisphere perfectly matches the "hypotenuse" of the spherical triangular facet in the Northern Hemisphere. After being combined, the two elements fit together perfectly to form a dense, regular two-dimensional rectangular matrix (without any redundant or invalid bits due to zero padding). The entire global grid is ultimately transformed into four such regular two-dimensional rectangular matrices. Within this regular two-dimensional rectangular matrix, the two-dimensional spatial continuity of the meteorological data is perfectly physically restored.
[0057] Step C, Tensor Construction and Data Compression Module. The four regular two-dimensional matrices generated in Step B are stacked to obtain a regularized tensor. Furthermore, if the original data includes an atmospheric vertical height layer, it is further stacked along the height dimension to construct a regularized tensor containing three-dimensional spatial information. This regularized tensor is input into the underlying data compressor. Morphological Evolution: The two-dimensional mesh is stacked into a "three-dimensional / multi-dimensional data cube (tensor)". Due to the recombination in Step B, the data inside this cube is extremely smooth and possesses strong spatial correlation. The compressor can efficiently perform spatial prediction and bit-plane encoding, ultimately outputting a binary bitstream with a drastically reduced volume (010110...), achieving an extreme data compression ratio.
[0058] Step D: Data Decompression and Reverse Reconstruction Module. Processing Procedure: When the user needs to read the raw meteorological data, the strict inverse process of steps A to C is executed. First, the binary bitstream is decompressed, restoring four regular two-dimensional rectangular matrices. The rectangles are split into two right-angled triangles along the secondary diagonal of the matrices, and the triangle originally belonging to the Southern Hemisphere is rotated 180 degrees in the reverse direction to restore its right-angled state. The eight triangular data blocks are reconnected in concatenation according to the grid index order of the OGG official documentation. Output Format: The final output is a reconstructed one-dimensional OGG meteorological sequence that is completely consistent with the initial input format. This process is completely transparent to the upper-level meteorological application software and does not require any changes to the original meteorological model's reading code.
[0059] This application also provides an electronic device, which includes a memory and a processor. The memory stores a computer program, and the processor executes the computer program to implement the above-described meteorological data processing method. This electronic device can be any smart terminal, including tablet computers, in-vehicle computers, etc.
[0060] Please see Figure 6 , Figure 6 The hardware structure of an electronic device according to another embodiment is illustrated. The electronic device includes: The processor 901 can be implemented using a general-purpose CPU (Central Processing Unit), microprocessor, application-specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of this application. The memory 902 can be implemented as a read-only memory (ROM), a static storage device, a dynamic storage device, or a random access memory (RAM). The memory 902 can store the operating system and other application programs. When the technical solutions provided in the embodiments of this specification are implemented through software or firmware, the relevant program code is stored in the memory 902 and is called and executed by the processor 901 using the meteorological data processing method of the embodiments of this application. The input / output interface 903 is used to implement information input and output; The communication interface 904 is used to enable communication and interaction between this device and other devices. Communication can be achieved through wired means (such as USB, Ethernet cable, etc.) or wireless means (such as mobile network, WIFI, Bluetooth, etc.). Bus 905 transmits information between various components of the device (e.g., processor 901, memory 902, input / output interface 903, and communication interface 904); The processor 901, memory 902, input / output interface 903, and communication interface 904 are connected to each other within the device via bus 905.
[0061] This application also provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the above-described meteorological data processing method.
[0062] Memory, as a non-transitory computer-readable storage medium, can be used to store non-transitory software programs and non-transitory computer-executable programs. Furthermore, memory may include high-speed random access memory, and may also include non-transitory memory, such as at least one disk storage device, flash memory device, or other non-transitory solid-state storage device. In some embodiments, memory may optionally include memory remotely located relative to the processor, and these remote memories can be connected to the processor via a network. Examples of such networks include, but are not limited to, the Internet, intranets, local area networks, mobile communication networks, and combinations thereof.
[0063] The meteorological data processing method, electronic device, and storage medium provided in this application segment the first meteorological data by latitude and longitude regions to obtain spherical triangular block data corresponding one-to-one with the Northern and Southern Hemispheres. This preserves the adjacency relationship of each spherical triangular block data in physical space and reduces the impact of data jumps on subsequent processing. Next, the triangular block data of the Northern and Southern Hemispheres are respectively processed by rectangularization, mapped into a planar two-dimensional array structure to obtain a first two-dimensional array and a second two-dimensional array. Then, the geographically north-south mirror-symmetrical first two-dimensional array and second two-dimensional array are complementaryly spliced to generate a regular target two-dimensional array, thereby restoring the topological correlation of meteorological data in two-dimensional space and reducing redundant space occupation. Finally, multiple target two-dimensional arrays are compressed and encoded. Since each target two-dimensional array is a complementary splicing of the north-south mirror-symmetrical first two-dimensional array and second two-dimensional array, there is no need to introduce redundant placeholders, and the data in each target two-dimensional array have strong topological correlation. This allows the compression encoding algorithm to more fully utilize the advantages of spatial prediction for encoding, improving overall compression efficiency.
[0064] The embodiments described in this application are for the purpose of more clearly illustrating the technical solutions of the embodiments of this application, and do not constitute a limitation on the technical solutions provided by the embodiments of this application. As those skilled in the art will know, with the evolution of technology and the emergence of new application scenarios, the technical solutions provided by the embodiments of this application are also applicable to similar technical problems.
[0065] Those skilled in the art will understand that the technical solutions shown in the figures do not constitute a limitation on the embodiments of this application, and may include more or fewer steps than shown, or combine certain steps, or different steps.
[0066] Those skilled in the art will understand that all or some of the steps in the methods disclosed above, as well as the functional modules / units in the systems and devices, can be implemented as software, firmware, hardware, or suitable combinations thereof.
[0067] The terms “first,” “second,” “third,” “fourth,” etc. (if present) in the specification and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this application described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms “comprising” and “having,” and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.
[0068] It should be understood that in this application, "at least one (item)" means one or more, and "more than" means two or more. "And / or" is used to describe the relationship between related objects, indicating that three relationships can exist. For example, "A and / or B" can represent three cases: only A exists, only B exists, and both A and B exist simultaneously, where A and B can be singular or plural. The character " / " generally indicates that the preceding and following related objects are in an "or" relationship. "At least one (item) of the following" or similar expressions refer to any combination of these items, including any combination of single or plural items. For example, at least one (item) of a, b, or c can represent: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, and c can be single or multiple.
[0069] The units described above 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.
[0070] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.
[0071] If the integrated unit is implemented as a software functional unit 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 all 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 multiple 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 of the various embodiments of this application. The aforementioned storage medium includes various media capable of storing programs, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0072] The preferred embodiments of the present application have been described above with reference to the accompanying drawings, but this does not limit the scope of the claims of the present application. Any modifications, equivalent substitutions, and improvements made by those skilled in the art without departing from the scope and substance of the embodiments of the present application shall be within the scope of the claims of the present application.
Claims
1. A meteorological data processing method, characterized in that, The method includes: Acquire first meteorological data, wherein the first meteorological data is octahedral Gaussian grid data; The first meteorological data is divided into latitude and longitude regions to obtain multiple first spherical triangular block data of the Northern Hemisphere and second spherical triangular block data of the Southern Hemisphere, wherein the first spherical triangular block data and the second spherical triangular block data correspond one-to-one; Each of the first spherical triangle block data is processed by rectangularization to obtain a first two-dimensional array that corresponds one-to-one with the first spherical triangle block data; Each of the second spherical triangle block data is processed by rectangularization to obtain a second two-dimensional array that corresponds one-to-one with the second spherical triangle block data; The first two-dimensional array and the second two-dimensional array, which indicate the geographical region as a north-south mirror image, are complementaryly spliced together to generate the target two-dimensional array; The multiple target two-dimensional arrays are compressed and encoded to generate a first meteorological data bitstream.
2. The method according to claim 1, characterized in that, The step of performing rectangularization on each of the first spherical triangle block data to obtain a first two-dimensional array corresponding one-to-one with the first spherical triangle block data includes: Create an N-row × N-column two-dimensional array of the Northern Hemisphere, where N is the number of discrete grids on the equator corresponding to each first spherical triangular block data; Meteorological data at the same latitude in the first spherical triangular block data are all taken as the first meteorological data set; The meteorological data in each of the first meteorological data sets are sorted, and the first meteorological data sets are sorted to obtain the second meteorological data sets arranged in order. The second meteorological data set is determined by traversing the Northern Hemisphere two-dimensional array row by row, and the meteorological data of the determined second meteorological data set are sequentially filled into different columns of the traversed row of the Northern Hemisphere two-dimensional array to obtain the first two-dimensional array.
3. The method according to claim 2, characterized in that, The step of performing rectangularization on each of the second spherical triangle block data to obtain a second two-dimensional array corresponding one-to-one with the second spherical triangle block data includes: Create an N-row × N-column two-dimensional array of the Southern Hemisphere, where N is the number of discrete grids on the equator corresponding to each second spherical triangular block data; Meteorological data at the same latitude in the second spherical triangular block data are all used as the third meteorological data set; The meteorological data in each of the third meteorological data sets are sorted, and the third meteorological data sets are sorted to obtain the fourth meteorological data sets arranged in sequence. The Southern Hemisphere two-dimensional array is traversed row by row to determine the fourth meteorological data set at the same position as the traversed row of the Southern Hemisphere two-dimensional array. The meteorological data of the determined fourth meteorological data set are then sequentially filled into different columns of the traversed row of the Southern Hemisphere two-dimensional array to obtain the second two-dimensional array.
4. The method according to claim 3, characterized in that, The step of complementaryly concatenating the first two-dimensional array and the second two-dimensional array, which indicate a north-south mirror-symmetric geographical region, to generate a target two-dimensional array includes: Perform a two-dimensional planar center-symmetric flipping process on the second two-dimensional array to generate a third two-dimensional array; An initial two-dimensional array is generated by complementary concatenation of the first two-dimensional array and the third two-dimensional array. The data elements on the main diagonal of the initial two-dimensional array are smoothed to obtain the target two-dimensional array.
5. The method according to claim 4, characterized in that, The step of smoothing the data elements on the main diagonal of the initial two-dimensional array to obtain the target two-dimensional array includes: Each meteorological data element on the main diagonal of the initial two-dimensional array is used as a boundary data point; In the initial two-dimensional array, select multiple meteorological data elements whose distance from the boundary data points meets the preset distance to obtain multiple reference samples corresponding to each boundary data point; Meteorological data prediction values for each boundary data point are obtained based on multiple reference samples for each boundary data point. Based on the boundary data points and the corresponding meteorological data prediction values, the residuals are determined; In the initial two-dimensional array, the boundary data points are replaced with the residuals to obtain the target two-dimensional array.
6. The method according to claim 1, characterized in that, Multiple sets of the first meteorological data are configured; each set of the first meteorological data corresponds to at least one stacking dimension. The step of compressing and encoding multiple target two-dimensional arrays to generate a first meteorological data bitstream includes: Multiple target two-dimensional arrays with the same stacking dimension are stacked vertically to obtain an initial tensor; Based on the size of the stacking dimension, the initial tensors are stacked one on top of the other to obtain the target tensor. Based on a preset compression encoder and the target tensor, a first meteorological data bitstream is generated, wherein the stacking dimension includes at least one of the atmospheric vertical height dimension, variable dimension, and time dimension.
7. The method according to any one of claims 1 to 6, characterized in that, The method further includes: Acquire the second meteorological data bitstream; The second meteorological data bitstream is decompressed and restored to obtain the second meteorological data array.
8. The method according to claim 7, characterized in that, The step of decompressing and restoring the second meteorological data bitstream to obtain the second meteorological data array includes: The second meteorological data bitstream is decompressed to obtain multiple two-dimensional arrays of targets to be split. The two-dimensional array of the target to be split is split to obtain a fourth two-dimensional array and a fifth two-dimensional array that indicate the geographical region as a north-south mirror image. The fourth two-dimensional array is de-rectified to obtain the third spherical triangle block data of the Northern Hemisphere, wherein the fourth two-dimensional array corresponds one-to-one with the third spherical triangle block data; The fifth two-dimensional array is de-rectified to obtain the fourth spherical triangle block data of the Southern Hemisphere, wherein the fifth two-dimensional array corresponds one-to-one with the fourth spherical triangle block data; The data from the third and fourth spherical triangular blocks are spliced together by latitude and longitude regions to obtain the second meteorological data array.
9. An electronic device, characterized in that, The electronic device includes a memory and a processor. The memory stores a computer program, and the processor executes the computer program to implement the meteorological data processing method according to any one of claims 1 to 8.
10. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by the processor, it implements the meteorological data processing method according to any one of claims 1 to 8.