An interactive method for batch extraction of regional precipitation
Through the interactive batch processing software built in ArcGIS and R language, the tedious and quality problems of large-scale regional precipitation data integration are solved, and fast and convenient data processing and quality control are achieved, which is suitable for the fields of meteorology and hydrology.
Patent Information
- Application Number
- CN202210571906.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-05-24
- Publication Date
- 2024-09-24
- Estimated Expiration
- 2042-05-24
AI Technical Summary
Existing technologies are difficult to effectively integrate and process large-scale regional precipitation data, resulting in reduced data quality and cumbersome and time-consuming processing, especially as the number of regional sites increases.
An interactive regional precipitation batch extraction method is adopted, and ArcGIS and R language are used to build batch processing software to realize data integration during user-selected periods, including the menu bar, running area and status bar. Through extraction, conversion, filtering, and supplementation, Collection and interpolation modules for rapid processing and quality control of precipitation data.
It achieves fast, convenient and reliable integration of precipitation data, improves data processing speed and quality, and is suitable for applications in the fields of meteorology and hydrology.
Smart Images

Figure CN114968237B
Abstract
Description
Technical Field
[0001] The invention belongs to the field of meteorology and hydrology technology, and in particular relates to an interactive regional precipitation batch extraction method. Background Art
[0002] Precipitation is one of the main climate factors and is also a key monitoring target of my country's meteorological department. In recent years, climate and human activities have intensified, and the spatiotemporal evolution of large-scale precipitation has become an important issue that workers engaged in meteorology, hydrological disasters and other fields need to answer urgently.
[0003] The daily precipitation observed at ground meteorological observation stations is an important source of data. However, due to factors such as data storage format, station establishment year, and data missing, the conversion of precipitation data from a fixed format to a form that can be used for routine research is a rather tedious and time-consuming data processing and integration task. Especially when the region is large, the number of regional precipitation stations increases dramatically. If scientific integration is not carried out, the quality of precipitation data will drop sharply. Common data integration scenarios include direct abandonment of missing data and direct use without processing. The above scenarios cause data waste on the one hand and a decrease in the rationality of the analysis results on the other. At the same time, due to the different influences of regional station establishment years, users often need to perform equal-length processing on the data when integrating precipitation data in the study area. The common operation is to use Excel to eliminate data that does not belong to the study period according to the study period after integrating the single-station data. When the area that users need to analyze is large, this operation is undoubtedly time-consuming.
[0004] In summary, for the daily observed precipitation at ground-based meteorological observation stations, it is urgent to build a scientific and interactive regional precipitation batch processing method to enable users to scientifically integrate the processed regional precipitation datasets for selected time periods without missing any measurements. Summary of the invention
[0005] In order to overcome the deficiencies of the above-mentioned prior art, the object of the present invention is to provide an interactive regional precipitation batch extraction method, which has the characteristics of fast extraction speed, convenience and reliability.
[0006] To achieve the above object, the technical solution adopted by the present invention is: an interactive regional precipitation batch extraction method, comprising the following steps:
[0007] Step S1, collecting precipitation monitoring data from ground meteorological observation stations;
[0008] Step S2, using ArcGIS software, extract the basic information of ground meteorological observation stations in the area according to the user's research area, and export the station IDs in the area as id.txt;
[0009] Step S3, placing the precipitation monitoring data and id.txt in the same folder;
[0010] Step S4, constructing an interactive regional precipitation batch processing software based on R language, including a menu bar area, a running area, and a status bar area;
[0011] Step S5, after the software is built, a coherent regional precipitation batch processing operation can be performed, including: clicking the File menu in the interactive regional precipitation batch processing software interface, and clicking Open in the drop-down menu bar to select the folder where the source data is located; clicking the Extract Long Sequence Value Module, Convert Long Sequence Value Module, and Extract Monitoring Period Module under the Pre-processing Module in turn; then clicking the Read Optional Period button under the Starting Year Selection Module to activate the starting year selection function that interacts with the user, select the starting year, and then click the Selected Post-Click button; running the Site Preliminary Screening Module, Site Secondary Screening Module, and Site Complement Build Module under the Post-processing Module; clicking the Complement-based Interpolation Module and Interpolation Information Integration Module under the Running Module; at this time, a complete regional precipitation batch processing is completed, and clicking the Site Number Module in the Region, the Preliminary Screening Module in the Research Period, the Site Number Module with Missing Measurement Rate Greater than 5%, the Site Number Module with Missing Measurement Rate Less than 5%, the Site Number Module without Missing Measurement, and the Site Number Module after Processing under the Site Number Change Module can display the number of sites under various quality control conditions in the region during this processing.
[0012] The menu bar area includes File and Help menus, wherein the drop-down menu bar under the File menu has three functional modules, namely Open, View and Close. The Open module is used to select the folder where the source data is located, the View module is used to pop up the current working directory, and the Close module is used to close the main interface; the drop-down menu bar under the Help menu has two functional modules, namely About and Need. About is used to pop up an introduction to this interface, and the Need module is used to pop up the source data required to run the software.
[0013] The operation area includes a pre-processing module, a starting year selection module, a post-processing module, an operation module, and a station number change module; wherein the pre-processing module is provided with a long sequence value extraction module, a long sequence value conversion module, and a monitoring period extraction module. The long sequence value extraction module is used to merge and extract the original precipitation data of each station in the provided precipitation file based on the station ID in the region. The long sequence value conversion module is used to convert the original precipitation data of each station after the operation of the long sequence value extraction module into a conventional usage format based on the daily observed precipitation preparation instructions of the ground meteorological observation station. The monitoring period extraction module is used to integrate the station establishment information of the station provided by the user; the starting year selection module is used to construct a function that can select the starting year according to the ideal research period in interaction with the user. By clicking the read optional period button, the starting year selection function that interacts with the user is activated. The user can select the starting year according to the ideal research period, and then click the selected button to set the starting year that the user wants to use for the research; the post-processing module is provided with three functional modules: the site preliminary screening module, the site secondary screening module, and the site complement construction module. The site preliminary screening module is used to select The stations with missing measurements for the whole year are eliminated during the fixed period. The station secondary screening module is used to perform secondary classification of the stations in the station preliminary screening module based on the annual missing measurement rate of 5%, and divide the stations into three categories: no missing measurements, annual missing measurement rate less than 5%, and annual missing measurement rate greater than 5%. The station complement set construction module is used to analyze the distance between the stations with an annual missing measurement rate less than 5% and all stations in the region, and obtain the station complement set required when the measurement is missing; the operation module is divided into three functional modules: the complement set interpolation module, the interpolation information integration module, and the clearing current interpolation module. The complement set interpolation module is used to construct the station complement set module based on the The station complement set constructed by the block performs adjacent station interpolation on the missing data of stations with an annual missing rate of less than 5%. The interpolation information integration module is used to integrate the precipitation data that meets the requirements in the region and record the data of the key processing process. The clearing interpolation module is used to clear the precipitation integration results in this region. The station number change module includes the station number module in the region, the preliminary screening number module during the study period, the station number module with a missing rate greater than 5%, the station number module with a missing rate less than 5%, the station number module without missing measurements, and the processed station number module, which can display the number of stations under various quality control conditions in the region.
[0014] The status bar area records and displays the process of key operations.
[0015] The beneficial effects of the present invention are:
[0016] Compared with the prior art, the present invention has the advantage of flexibly integrating precipitation data according to actual needs because it constructs the function of selecting the required research start time between the earliest station establishment year and the latest monitoring year of the station in the region; the present invention has the advantage of scientifically interpolating and quickly interpolating the missing precipitation data because it constructs the screening condition of using the annual missing rate less than 5% as the screening condition for whether the station data can be further interpolated by adjacent stations during the selected research period; the present invention has the advantage of quickly and clearly grasping the changes in the number of stations in the study area during the processing process because it constructs a station number change module. The present invention greatly improves the processing and integration speed and quality of precipitation monitoring data of ground meteorological observation stations, and is fast and convenient in extracting and processing precipitation sequences with more than 60 stations and longer sequences, which can serve the meteorological and hydrological fields and has a good prospect for promotion and application. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] Figure 1 It is a schematic diagram of the construction framework of the present invention.
[0018] Figure 2 It is a schematic diagram of the initial main interface of the present invention.
[0019] Figure 3 It is a schematic diagram of the main interface for the start year selection function and status bar activation for user interaction.
[0020] Figure 4 It is a schematic diagram of the contents of the result folder after processing of the present invention.
[0021] Figure 5 It is a flow chart of the present invention. DETAILED DESCRIPTION
[0022] The present invention will be further described below in conjunction with the accompanying drawings and specific embodiments. The described embodiments are only typical cases of the present invention. All other embodiments obtained by ordinary technicians in the relevant field based on the above content without making any creative work are within the scope of protection of the present invention.
[0023] This embodiment integrates the daily observed precipitation data of a certain province's ground meteorological observation station. Figure 1 As shown, the following steps are included:
[0024] Step S1, collecting precipitation monitoring data from ground meteorological observation stations. This embodiment collects 828 .txt files from SURF_CLI_CHN_MUL_DAY-PRE-13011-195101.TXT to SURF_CLI_CHN_MUL_DAY-PRE-13011-201912.TXT;
[0025] Step S2, using ArcGIS software to extract basic information of ground meteorological observation stations in a province, and export the station IDs in a province as "id.txt", which contains 119 stations such as 58017, 58111, and 54817;
[0026] Step S3, placing the precipitation monitoring data in S1 and the "id.txt" in S2 in the same folder (E:\softpre);
[0027] Step S4, running an interactive regional precipitation batch processing software constructed by the present invention in R language, such as Figure 2 As shown;
[0028] Step S5, click the "File" menu, click "Open" in the drop-down menu bar, a root directory selection interface pops up, select the folder where the source data is located (E:\softpre); click "Extract long sequence value" under "Pre-processing", based on the site ID (E:\softpre\id.txt) provided by the user, extract the long sequence value in the provided precipitation file (E:\softpre\SURF_CLI_CHN_MUL_DAY-PRE-13011-195101.TXT to E:\softpre\SURF_ CLI_CHN_MUL_DAY-PRE-13011-201912.TXT) to extract and merge the original precipitation data of 119 stations in a province; click "Convert long sequence value" under "Pre-processing" to convert the extracted and merged original precipitation data of 119 stations in a province into a conventional format based on the compilation instructions of daily observed precipitation at ground meteorological observation stations; click "Extract monitoring period" under "Pre-processing" to integrate the station establishment information of 119 stations in a province; when clicking "Read optional period", the starting year selection function that interacts with the user is activated ( Figure 3); between the year of the earliest meteorological station built in a province and the year of the latest data, 1960 is selected as the starting year for this extraction; then click "Select and click" to set the starting year for the study; click "Preliminary screening of stations" under "Post-processing" to eliminate the 119 stations in a province that had missed measurements for the entire year between 1960 and 2019; click "Secondary screening of stations" under "Post-processing" to perform a secondary classification of the stations that did not have missed measurements for the entire year in a province between 1960 and 2019, and divide the stations into those with no missed measurements, those with an annual missed measurement rate of less than 5%, and those with an annual missed measurement rate of less than 5%. greater than 5%; click "Build site complement" under "Post-processing" to analyze the distance between the sites with an annual missing rate of less than 5% in a province and 119 sites in the region during 1960-2019, and obtain the site complement required when missing; click "Interpolation based on complement" under "Run" to interpolate the missing data of sites with an annual missing rate of less than 5% based on the site complement built by S12; click "Interpolation information integration" under "Run" to integrate the precipitation data in a province that meets the time series consistency after processing into the "areapre" folder under the source data folder ( Figure 4 ); Click "Changes in the number of sites" in turn to set up six functions: "Number of sites in the region", "Number of preliminary screening during the study period", "Number of sites with a missing rate greater than 5%", "Number of sites with a missing rate less than 5%", "Number of sites without missing tests", and "Number of sites after processing". The numbers of sites under various quality control conditions in a province are 119, 86, 7, 25, 54, and 79 respectively;
[0029] In summary, the present invention constructs an interactive regional precipitation batch processing method, which overcomes the main shortcomings of a large area, such as a sharp increase in the number of regional precipitation stations, cumbersome and time-consuming precipitation data integration, and a sharp decline in data integration quality, thereby providing convenience, reliability, and rationality for the scientific integration of regional precipitation.
Claims
1. An interactive regional precipitation batch extraction method, characterized in that: The following steps are involved: Step S1, collecting precipitation monitoring data from ground meteorological observation stations; Step S2, using ArcGIS software, extract the basic information of ground meteorological observation stations in the area according to the user's research area, and export the station IDs in the area as id.txt; Step S3, placing the precipitation monitoring data and id.txt in the same folder; Step S4, constructing an interactive regional precipitation batch processing software based on R language, including a menu bar area, a running area, and a status bar area; Step S5, after the software is built, a continuous regional precipitation batch processing operation is performed, including: clicking the File menu in the interactive regional precipitation batch processing software interface, and clicking Open in the drop-down menu bar to select the folder where the source data is located; clicking the Extract Long Sequence Value Module, Convert Long Sequence Value Module, and Extract Monitoring Period Module under the Pre-processing Module in turn; then clicking the Read Optional Period button under the Starting Year Selection Module to activate the starting year selection function that interacts with the user, select the starting year, and then click the Selected Post-Click button; running the Site Preliminary Screening Module, Site Secondary Screening Module, and Site Complementation Module under the Post-processing Module; clicking the Complementation-based Interpolation Module and Interpolation Information Integration Module under the Running Module; at this point, a complete regional precipitation batch processing is completed, and clicking the Site Number Module in the Region, the Preliminary Screening Module in the Research Period, the Site Number Module with Missing Measurement Rate Greater than 5%, the Site Number Module with Missing Measurement Rate Less than 5%, the Site Number Module with No Missing Measurement, and the Site Number Module after Processing under the Site Number Change Module can display the number of sites under various quality control conditions in the region during this processing; The operation area includes a pre-processing module, a starting year selection module, a post-processing module, an operation module, and a station number change module; wherein the pre-processing module is provided with a long sequence value extraction module, a long sequence value conversion module, and a monitoring period extraction module. The long sequence value extraction module is used to merge and extract the original precipitation data of each station in the provided precipitation file based on the station ID in the region. The long sequence value conversion module is used to convert the original precipitation data of each station after the operation of the long sequence value extraction module into a conventional usage format based on the daily observed precipitation preparation instructions of the ground meteorological observation station. The monitoring period extraction module is used to integrate the station establishment information of the station provided by the user; the starting year selection module is used to construct a function that can select the starting year according to the ideal research period in interaction with the user. By clicking the read optional period button, the starting year selection function that interacts with the user is activated. The user can select the starting year according to the ideal research period, and then click the selected button to set the starting year that the user wants to use for the research; the post-processing module is provided with three functional modules: the site preliminary screening module, the site secondary screening module, and the site complement construction module. The site preliminary screening module is used to select The stations with missing measurements for the whole year are eliminated during the fixed period. The station secondary screening module is used to perform secondary classification of the stations in the station preliminary screening module based on the annual missing measurement rate of 5%, and divide the stations into three categories: no missing measurements, annual missing measurement rate less than 5%, and annual missing measurement rate greater than 5%. The station complement set construction module is used to analyze the distance between the stations with an annual missing measurement rate less than 5% and all stations in the region, and obtain the station complement set required when the measurement is missing; the operation module is divided into three functional modules: the complement set interpolation module, the interpolation information integration module, and the clearing current interpolation module. The complement set interpolation module is used to construct the station complement set module based on the The station complement set constructed by the block performs adjacent station interpolation on the missing data of stations with an annual missing rate of less than 5%. The interpolation information integration module is used to integrate the precipitation data that meets the requirements in the region and record the data of the key processing process. The clearing interpolation module is used to clear the precipitation integration results of this region. The station number change module includes the station number module in the region, the preliminary screening number module during the research period, the station number module with a missing rate greater than 5%, the station number module with a missing rate less than 5%, the station number module without missing measurements, and the processed station number module, which can display the number of stations under various quality control conditions in the region. The precipitation file stores precipitation monitoring data.
2. The interactive regional precipitation batch extraction method according to claim 1, characterized in that: The menu bar area includes File and Help menus, wherein the drop-down menu bar under the File menu has three functional modules, namely Open, View and Close. The Open module is used to select the folder where the source data is located, the View module is used to pop up the current working directory, and the Close module is used to close the main interface; the drop-down menu bar under the Help menu has two functional modules, namely About and Need. About is used to pop up an introduction to this interface, and the Need module is used to pop up the source data required to run the software.
3. The interactive regional precipitation batch extraction method according to claim 1, characterized in that: The status bar area records and displays the process of key operations.
