CN112765295A - Regional meteorological data splicing system - Google Patents
Regional meteorological data splicing system Download PDFInfo
- Publication number
- CN112765295A CN112765295A CN202110040186.3A CN202110040186A CN112765295A CN 112765295 A CN112765295 A CN 112765295A CN 202110040186 A CN202110040186 A CN 202110040186A CN 112765295 A CN112765295 A CN 112765295A
- Authority
- CN
- China
- Prior art keywords
- grid
- sub
- grid point
- mapping relation
- data
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
- 238000013507 mapping Methods 0.000 claims abstract description 39
- 238000000034 method Methods 0.000 claims abstract description 11
- 238000013506 data mapping Methods 0.000 claims abstract description 10
- 230000008569 process Effects 0.000 claims abstract description 8
- 238000013461 design Methods 0.000 claims abstract description 6
- 230000006870 function Effects 0.000 claims description 14
- 238000004088 simulation Methods 0.000 description 5
- 238000010586 diagram Methods 0.000 description 2
- 230000010354 integration Effects 0.000 description 2
- 230000009286 beneficial effect Effects 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 230000006872 improvement Effects 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 238000012545 processing Methods 0.000 description 1
- 238000012827 research and development Methods 0.000 description 1
- 238000012800 visualization Methods 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/20—Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
- G06F16/29—Geographical information databases
-
- G—PHYSICS
- G01—MEASURING; TESTING
- G01W—METEOROLOGY
- G01W1/00—Meteorology
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02A—TECHNOLOGIES FOR ADAPTATION TO CLIMATE CHANGE
- Y02A90/00—Technologies having an indirect contribution to adaptation to climate change
- Y02A90/10—Information and communication technologies [ICT] supporting adaptation to climate change, e.g. for weather forecasting or climate simulation
Landscapes
- Engineering & Computer Science (AREA)
- Environmental & Geological Engineering (AREA)
- Theoretical Computer Science (AREA)
- Databases & Information Systems (AREA)
- Environmental Sciences (AREA)
- Ecology (AREA)
- Biodiversity & Conservation Biology (AREA)
- Atmospheric Sciences (AREA)
- Remote Sensing (AREA)
- Data Mining & Analysis (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Life Sciences & Earth Sciences (AREA)
- Management, Administration, Business Operations System, And Electronic Commerce (AREA)
Abstract
A regional meteorological data splicing system relates to the technical field of computer design and solves the problems that in the existing meteorological data merging process, merging consumption time is long, execution efficiency is low and the like. The grid point mapping relation establishing module automatically generates a target grid according to original input data, establishes a mapping relation from input sub-area grid points to target grid points, and stores the mapping relation as a file; the grid point data mapping module applies for an array for each sub-area, reads data in the sub-area into a memory, establishes a pointer array with the shape consistent with that of a target grid, wherein each element in the pointer array corresponds to a grid point at a corresponding position in the target grid, establishes a mapping relation between grids according to the grid point mapping relation, and assigns each array element to an address of the sub-area grid point data with the mapping relation.
Description
Technical Field
The invention relates to the technical field of computer design, in particular to a regional meteorological data splicing system.
Background
In the last decade, the improvement of computer computing and storage capacity provides the possibility of high-resolution numerical simulation and data assimilation of an earth system, but at present, common supercomputers are still labourious for simulation of hundreds of meters of resolution in a wide area. To solve this problem, the space region is usually divided into many sub-regions in the simulation stage, and the molecular region stores the simulation result. However, the subsequent analysis and visualization of the simulation results often requires merging the data of multiple sub-regions into a whole. The difficulty in merging the data of multiple sub-regions is that when the amount of merged data is large, the process takes too long to meet the requirements of practical applications. The research and development of regional meteorological data splicing aim at solving the problem that a large amount of data are merged and time is consumed too much.
In the past, when multi-region high-resolution meteorological data are merged, a nearest neighbor method is usually adopted to map the numerical value of each grid point of each subregion to a target grid which can contain all the subregions, so as to achieve the purpose of data splicing. The process is generally carried out in two steps, firstly, the mapping relation of each grid point in two sets of grids is found out through the longitude and latitude coordinates of each grid point in the sub-area grid and the target grid, and the mapping relation is output as a file; then, the mapping of the grid point data from the sub-area grid to the target grid is performed through the mapping relation. Experience shows that when the data size is large, the time consumed by the second step is far longer than that consumed by the first step, so that the problem of large time consumption in data combination is solved, and the key point is to improve the execution efficiency of the second step.
The C language has strong control capability on the pointer and simultaneously has the inherent advantages of the compiled language in execution efficiency, so that the C language is selected as a development language for splicing regional weather data.
Disclosure of Invention
The invention provides a regional meteorological data splicing system, aiming at solving the problems of low execution efficiency and the like caused by long merging time in the existing meteorological data merging process.
The regional meteorological data splicing system comprises two main functional modules and two auxiliary functional modules; the two main function modules are respectively a grid point mapping relation establishing module and a grid point data mapping module; the two auxiliary function modules are respectively a command line parameter analysis module and a software information output module;
the grid point mapping relation establishing module automatically generates a target grid according to original input data, establishes a mapping relation from input sub-area grid points to target grid points and stores the mapping relation as a file;
the grid point data mapping module applies for an array for each sub-area, reads data in the sub-area into a memory, establishes a pointer array with the shape consistent with that of a target grid, wherein each element in the pointer array corresponds to a grid point at a corresponding position in the target grid, establishes an inter-grid mapping relation according to the grid point mapping relation, and assigns each array element to an address of the sub-area grid point data with the mapping relation;
the command line parameter analysis module analyzes the command line parameters according to the design specification of Linux;
the software information output module provides necessary software information for users according to the design specification of Linux.
The invention has the beneficial effects that: the splicing system can simplify the original complicated area data splicing process and greatly improve the efficiency of the work.
Drawings
FIG. 1 is a schematic block diagram of a regional weather data splicing system according to the present invention;
FIG. 2 is a diagram illustrating a mapping relationship between sub-region grid points and target grid points according to the present invention.
Detailed Description
The present embodiment will be described with reference to fig. 1 and 2, in which the regional weather data splicing system splices weather data of a plurality of spatial regions into a whole, and the data splicing operation can be performed more efficiently by the pointer operation in the C language. The system comprises two main function modules and two auxiliary function modules, wherein the two main function modules comprise a grid point mapping relation establishing module and a grid point data mapping module, and the two auxiliary function modules comprise a command line parameter analyzing module and a software information output module.
The grid point mapping relation establishing module is used for establishing a relation between each grid point in the target grid and the sub-area grid point closest to the grid point in space if a plurality of sub-area grid points can be found in a certain range. The detailed flow of the module work is as follows:
d. and determining the boundary of the target grid according to the latitude and longitude ranges covered by all the sub-area grid points.
e. And calculating the longitude and latitude of each point of the target grid according to the grid distance of the given target grid.
f. And calculating the grid element in the target grid according to the latitude and longitude of each grid point of each sub-area, and recording the position of the grid in the sub-area and the position of the grid in the target grid.
g. And c, traversing each grid point of the target grid, finding out which grid points in the sub-areas fall near the target grid point according to the record in the step c, respectively calculating the space distance between the grid points of the sub-areas and the target grid point, and recording the grid point of the sub-area closest to the target grid point, namely establishing the mapping relation between the grid point and the target grid point.
The grid point data mapping module applies for an array for each sub-area and reads data in the sub-area into the memory. Then, a pointer array with the shape consistent with that of the target grid is established, each element in the array corresponds to a grid point at a corresponding position in the target grid, and according to the established mapping relation between grids, the address of sub-area grid point data with the mapping relation is given to each array element, and the method is combined with the graph 1.
In this embodiment, not every sub-area grid will be mapped to a certain target grid, because part of the sub-area grids will be eliminated due to the insufficient distance to the surrounding target grids. Conversely, for each target grid, there is not necessarily a sub-area grid mapped to it, because some target grids may be too far away from any sub-area grid, in which case the target grid may be assigned a missing value. After the pointer array is completed, the data mapping can be completed only by outputting the data pointed by each element of the array to the hard disk.
The command line parameter analysis module is developed by adopting the command line software specification of Linux, and the details of command line options are as follows. In order to analyze the command line options and parameters, data integration (data integration) adopts a getopt _ long function to analyze the command line options and parameters, and a special module performs corresponding processing on each option parameter. When a user executes a dataint command, the command line parameter parsing module first parses the command line options and parameters, and then determines which function module to execute and which parameters to assign to the function module. It is not in parallel with the rest of the modules, just because the command line parameter parser module determines whether other modules should be executed.
The software information output module: dataint provides display functionality for user help, software licenses, versions, etc. information that a user may invoke to display through a corresponding command line option.
The second embodiment is described with reference to fig. 2, and the second embodiment is an example of the regional weather data splicing system according to the first embodiment: in the embodiment, the dataint system is developed by adopting the Linux command line tool standard, so the using method is similar to other Linux commands. FIG. 2 shows the relationship between the operation of modules in a dataint system.
Firstly, a user calls a grid point mapping relationship establishing module to establish a mapping relationship from each sub-area grid point in original data to a target grid point according to the original data, and the mapping relationship is output on a disk in a NetCDF format file form.
In the process, the command line parameter analysis module calls the lattice mapping relationship establishment module to generate a lattice mapping relationship file mp.nc according to input files of in01.nc, in02.nc, in03.nc and the like.
Then, the user calls the grid point data mapping module, and reads the grid point mapping relation file and the original data which are output just now together, so that the final output data can be obtained. In the process, the command line parameter analyzing module calls the lattice point data mapping module, reads input data in01.nc, in02.nc, in03.nc and other input files by using the just generated lattice point relation mapping file mp.nc, and finally splices the input data into a new data file out.nc.
The software information output module is mainly used for displaying the display functions of the information of the system, such as user help, software license, version and the like, to the user.
The technical features of the embodiments described above may be arbitrarily combined, and for the sake of brevity, all possible combinations of the technical features in the embodiments described above are not described, but should be considered as being within the scope of the present specification as long as there is no contradiction between the combinations of the technical features.
The above-mentioned embodiments only express several embodiments of the present invention, and the description thereof is more specific and detailed, but not construed as limiting the scope of the invention. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the inventive concept, which falls within the scope of the present invention. Therefore, the protection scope of the present patent shall be subject to the appended claims.
Claims (2)
1. Regional meteorological data concatenation system, characterized by: the system comprises two main function modules and two auxiliary function modules; the two main function modules are respectively a grid point mapping relation establishing module and a grid point data mapping module; the two auxiliary function modules are respectively a command line parameter analysis module and a software information output module;
the grid point mapping relation establishing module automatically generates a target grid according to original input data, establishes a mapping relation from input sub-area grid points to target grid points and stores the mapping relation as a file;
the grid point data mapping module applies for an array for each sub-area, reads data in the sub-area into a memory, establishes a pointer array with the shape consistent with that of a target grid, wherein each element in the pointer array corresponds to a grid point at a corresponding position in the target grid, establishes an inter-grid mapping relation according to the grid point mapping relation, and assigns each array element to an address of the sub-area grid point data with the mapping relation;
the command line parameter analysis module analyzes the command line parameters according to the design specification of Linux;
the software information output module provides necessary software information for users according to the design specification of Linux.
2. The regional weather data splicing system of claim 1, wherein: the specific process of the lattice point mapping relationship establishing module is as follows:
a. determining the boundary of the target grid according to the latitude and longitude ranges covered by all the sub-area grid points;
b. calculating the longitude and latitude of each point of a given target grid according to the grid distance of the target grid;
c. calculating the grid position of each grid point in the target grid according to the longitude and latitude of each grid point of each sub-area, and recording the position of the grid in the sub-area and the position of the grid in the target grid;
d. traversing each grid point of the target grid, calculating the space distance from the sub-region grid point to the target grid point according to the position information recorded in the step c, and marking the sub-region grid point closest to the target grid point, namely: and establishing a mapping relation from the grid point to the target grid point.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110040186.3A CN112765295B (en) | 2021-01-13 | 2021-01-13 | Regional meteorological data splicing system |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110040186.3A CN112765295B (en) | 2021-01-13 | 2021-01-13 | Regional meteorological data splicing system |
Publications (2)
Publication Number | Publication Date |
---|---|
CN112765295A true CN112765295A (en) | 2021-05-07 |
CN112765295B CN112765295B (en) | 2022-12-20 |
Family
ID=75699950
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202110040186.3A Active CN112765295B (en) | 2021-01-13 | 2021-01-13 | Regional meteorological data splicing system |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN112765295B (en) |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20110010464A1 (en) * | 2009-07-09 | 2011-01-13 | Movix (Uk) Ltd. | Data Processing System Using Geographical Locations |
CN106528773A (en) * | 2016-11-07 | 2017-03-22 | 山东首讯信息技术有限公司 | Spark platform supported spatial data management-based diagram calculation system and method |
CN112148774A (en) * | 2020-09-29 | 2020-12-29 | 华能新能源股份有限公司 | High-resolution spatial multi-region meteorological data processing system and method |
-
2021
- 2021-01-13 CN CN202110040186.3A patent/CN112765295B/en active Active
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20110010464A1 (en) * | 2009-07-09 | 2011-01-13 | Movix (Uk) Ltd. | Data Processing System Using Geographical Locations |
CN106528773A (en) * | 2016-11-07 | 2017-03-22 | 山东首讯信息技术有限公司 | Spark platform supported spatial data management-based diagram calculation system and method |
CN112148774A (en) * | 2020-09-29 | 2020-12-29 | 华能新能源股份有限公司 | High-resolution spatial multi-region meteorological data processing system and method |
Also Published As
Publication number | Publication date |
---|---|
CN112765295B (en) | 2022-12-20 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN102541521B (en) | Automatic operating instruction generating device based on structured query language and method | |
CN104778124A (en) | Automatic testing method for software application | |
CN112148774B (en) | High-resolution space multi-region meteorological data processing system and method | |
CN110968495A (en) | Container cloud platform performance evaluation method and device | |
CN102591787B (en) | The data processing method of JAVA card and device | |
CN111309734A (en) | Method and system for automatically generating table data | |
CN105447035A (en) | Data scanning method and apparatus | |
CN104375211A (en) | Weather forecast contour map updating method and system | |
CN112765295B (en) | Regional meteorological data splicing system | |
CN115659900B (en) | Method, apparatus and medium for presenting an integrated circuit layout | |
CN112632303A (en) | Distributed storage method, analysis method and device for image data | |
CN105446752A (en) | Triggering method and device of control in application program and mobile terminal | |
CN112614207A (en) | Contour line drawing method, device and equipment | |
CN109697234B (en) | Multi-attribute information query method, device, server and medium for entity | |
CN109634215B (en) | Nuclear power plant operation procedure design method based on planar graph coding technology | |
CN108647026B (en) | Visual interface integration method and system based on dynamic grid | |
CN107704685B (en) | Mesh division method and device | |
CN116208465A (en) | Intelligent monitoring and early warning method and system for electric power information communication condition | |
CN115758950A (en) | Automatic drawing method, device and computer readable storage medium | |
CN113553454B (en) | Primitive data processing method and device and electronic equipment | |
CN115657166A (en) | Method and device for determining weather forecast value across multiple climate areas | |
CN115471582A (en) | Map generation method and device, computer equipment and storage medium | |
CN114840190A (en) | Code generation method and device, computer equipment and storage medium | |
CN114154095A (en) | Page picture generation method, device, equipment and storage medium | |
CN113704380A (en) | Distributed superposition analysis method and device based on spatial grid and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |