MPI parallel method, device and electronic equipment across mesh topology

By employing a cross-grid topology MPI parallel method, the coupling problem between three-dimensional dynamic adaptive grids and physicochemical parameterization schemes is solved, achieving efficient data structure mapping and improved forecast accuracy. This method is applicable to numerical weather prediction and climate forecasting in the field of atmospheric science.

CN121597681BActive Publication Date: 2026-05-29INST OF ATMOSPHERIC PHYSICS CHINESE ACADEMY SCI

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
INST OF ATMOSPHERIC PHYSICS CHINESE ACADEMY SCI
Filing Date
2025-10-28
Publication Date
2026-05-29

AI Technical Summary

Technical Problem

Traditional numerical weather prediction models face coupling challenges between three-dimensional dynamic adaptive grids and physicochemical parameterization schemes, which limits the improvement of resolution and simulation accuracy in key areas under limited computational resources.

Method used

The MPI parallel method with cross-grid topology is adopted. By using each underlying surface primitive as a reference unit and performing cylindrical projection along the opposite direction of gravity, the computational space is divided into vertical cylindrical domains, and a two-dimensional virtual index is constructed to achieve efficient input of physicochemical parameterization schemes and feedback of calculation results.

Benefits of technology

It realizes automated and parallel topology mapping from arbitrarily complex unstructured grids to standard one-dimensional vertical single-column data structures, simplifies the coupling complexity between modules, and improves forecast accuracy and efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121597681B_ABST
    Figure CN121597681B_ABST
Patent Text Reader

Abstract

The embodiment of the application provides a MPI parallel method and device across a grid topology and electronic equipment, and relates to the field of atmospheric science, to solve the coupling problem between the three-dimensional dynamic grid and the traditional physical and chemical parameterization scheme. The method is: taking each underlying element as a reference unit, performing column projection in the direction opposite to gravity, and dividing the calculation space corresponding to the target region into each vertical column domain; determining the element number of the underlying element corresponding to each vertical column domain of each target grid point in the calculation space and the height number of each target grid point in the corresponding vertical column domain; based on the element number of the underlying element corresponding to each vertical column domain of each target grid point and the height number of each target grid point in the corresponding vertical column domain, constructing a two-dimensional virtual index of each target grid point, so that the physical and chemical parameterization scheme uses the two-dimensional virtual index to obtain input data and returns the calculation result.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of atmospheric science, and in particular to an MPI parallel method, apparatus and electronic device that spans grid topologies. Background Technology

[0002] In atmospheric science, advances in numerical weather prediction, climate forecasting, and air quality forecasting rely heavily on numerical models built on high-performance parallel computers. A core element of these models is the tight coupling between a dynamic framework that accurately describes atmospheric motion and parameterization schemes that characterize key physicochemical processes.

[0003] Traditional numerical forecasting models (such as the Weather Research and Forecasting Model (WRF) and Model for Prediction Across Scales (MPAS)) are typically based on structured or quasi-structured grids. Their dynamic framework (responsible for solving fluid dynamic equations) and physicochemical parameterization schemes (used to describe physical processes at sub-grid scales) often share the same numerical computation grid. This allows for convenient large-scale parallel computation of message passing interfaces (MPI) using domain decomposition methods such as "cake-cutting," resulting in direct and efficient data exchange and management. However, a key assumption underlying this approach is that most physicochemical parameterization schemes (e.g., those handling pollutant deposition, atmospheric boundary layer, and radiative transfer) require the input data to exhibit a clear one-dimensional monocolumn grid structure in the vertical direction.

[0004] Despite the significant success of traditional numerical weather prediction (NMM) models in many aspects, the increasing demands for forecast accuracy and simulation of multi-scale phenomena present challenges to further improving the resolution of key regions under the constraint of limited computational resources. In recent years, three-dimensional dynamic adaptive mesh technology has attracted considerable attention due to its ability to perform high-resolution simulations of key regions while maintaining computational efficiency, demonstrating great potential for improving simulation accuracy. However, this type of numerical weather prediction model, employing a three-dimensional dynamic adaptive mesh (such as a tetrahedron, hereinafter referred to as a three-dimensional dynamic mesh), fundamentally breaks the traditional grid paradigm of "horizontal two-dimensional + vertical one-dimensional single column." The highly flexible and time-varying grid characteristics of the three-dimensional dynamic mesh create a significant "impedance mismatch" with the requirement of traditional physicochemical parameterization schemes for fixed one-dimensional vertical column data, drastically increasing the coupling difficulty and severely restricting its application in operational forecasting.

[0005] Therefore, how to establish a high-quality cross-mesh topology MPI parallel method to meet the specific needs of time-varying and physicochemical parameterization schemes of three-dimensional dynamic adaptive meshes is an urgent problem to be solved. Summary of the Invention

[0006] This application provides a cross-grid topology MPI parallel method, apparatus, and electronic device to solve the coupling problem between three-dimensional dynamic grids and traditional physical and chemical parameterization schemes, providing key support for improving the accuracy and efficiency of numerical prediction models.

[0007] In a first aspect, embodiments of this application provide a cross-mesh topology MPI parallel method, the method comprising:

[0008] Using each underlying surface primitive as a reference unit, a cylindrical projection is performed along the opposite direction of gravity to divide the computational space corresponding to the target area into vertical cylindrical domains. The underlying surface primitive is a face of an unstructured mesh on the underlying surface, and the vertical cylindrical domains do not overlap.

[0009] Determine the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to each target grid point in the computation space and the height number of each target grid point in its corresponding vertical columnar domain, wherein each target grid point corresponds to a vertical columnar domain in each vertical columnar domain.

[0010] Based on the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to each target grid point, and the height number of each target grid point in its corresponding vertical columnar domain, a two-dimensional virtual index is constructed for each target grid point, so that the physicochemical parameterization scheme can use the two-dimensional virtual index to obtain input data and return calculation results.

[0011] In one optional embodiment, determining the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to each target grid point in the computational space and the height number of each target grid point in its corresponding vertical columnar domain includes:

[0012] Obtain the initial grid point sequence for each vertical columnar domain. The initial grid point sequence includes: each initial grid point contained in the corresponding vertical columnar domain and the grid point data of each initial grid point. The grid point data includes: a first identifier and a second identifier. The first identifier is the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to the corresponding initial grid point, and the second identifier is the height number of the corresponding initial grid point in its corresponding vertical columnar domain.

[0013] The obtained initial grid point sequences are aggregated to obtain the global grid point dataset;

[0014] Identify duplicate grid points in the global grid point dataset, retain unique grid points and grid point data of unique grid points to obtain the target grid point dataset, and based on the target grid point dataset, determine the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to each target grid point and the height number of each target grid point in its corresponding vertical columnar domain. Each grid point in the target grid point dataset uniquely corresponds to one vertical columnar domain.

[0015] In one optional embodiment, obtaining the initial grid sequence for each vertical columnar domain includes:

[0016] Each MPI process identifies the list of underlying surface primitives contained in its local computation space and integrates the obtained lists of underlying surface primitives into a global list of underlying surface primitives.

[0017] Each MPI process independently searches the distribution of each grid point in its local computation space on each vertical columnar domain based on the global underlying primitive list, thus obtaining the grid point distribution information for each MPI process.

[0018] Based on the obtained grid point distribution information, the initial grid point sequence of each vertical columnar domain is generated.

[0019] In one optional embodiment, the obtained initial grid point sequences are aggregated to obtain a global grid point dataset, including:

[0020] For each vertical columnar region, the following operations are performed: Based on the grid distribution density of a vertical columnar region in the vertical direction, grid addition and / or grid deletion are performed on each initial grid point of the vertical columnar region to obtain each standard grid point of the vertical columnar region. The primitive number of the underlying surface primitive of the vertical columnar region is used as the first identifier of each standard grid point, and the height number of each standard grid point in the vertical columnar region is used as the second identifier of each standard grid point, thereby obtaining a standard grid point sequence of the vertical columnar region. The standard grid point sequence includes: each standard grid point and its own grid point data.

[0021] The obtained standard grid point sequences are aggregated to obtain a global grid point dataset.

[0022] In one optional embodiment, based on the grid distribution density of a vertical columnar domain in the vertical direction, grid addition and / or grid deletion processes are performed on each initial grid point of the vertical columnar domain, including:

[0023] Dynamically detect the grid distribution density of a vertical columnar domain in the vertical direction;

[0024] When a sparse grid region is determined to exist, a virtual grid is added in the sparse grid region;

[0025] When a dense grid region is determined to exist, delete at least one initial grid point in the dense grid region, or add a virtual grid point in the dense grid region and delete at least two initial grid points.

[0026] In one optional embodiment, duplicate grid points in the global grid point dataset are identified, unique grid points and their unique data are retained to obtain the target grid point dataset, including:

[0027] For each global grid point in the global grid point dataset, sort the global grid points using the first identifier as the primary key and the second identifier as the secondary key to obtain an ordered grid point dataset.

[0028] Identify duplicate grid points in an ordered grid point dataset, and retain unique grid points and their data according to preset grid point retention rules to obtain the target grid point dataset.

[0029] In an optional embodiment, the grid data of the virtual grid points further includes: lineage information, which records the grid point identifiers of each parent grid point that generated the virtual grid points and the generation method of the virtual grid points; then the method further includes:

[0030] When the physicochemical parameterization scheme calculates the calculation results of the grid point to be fed back, if the grid point to be fed back is a virtual grid point, the calculation results are allocated based on the spectral information of the virtual grid point, and the allocated calculation results are fed back to the corresponding parent grid point.

[0031] In one optional embodiment, the two-dimensional virtual index consists of a column index and a layer index. The column index is determined based on the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to the target grid point, and the layer index is determined based on the height number of the target grid point in its corresponding vertical columnar domain.

[0032] Secondly, embodiments of this application also provide a cross-mesh topology MPI parallel device, the device comprising:

[0033] The first processing module is used to perform cylindrical projection along the opposite direction of gravity with each underlying surface primitive as a reference unit, and divide the computational space corresponding to the target area into vertical cylindrical domains. The underlying surface primitive is a face of an unstructured mesh on the underlying surface, and the vertical cylindrical domains do not overlap.

[0034] The second processing module is used to determine the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to each target grid point in the computation space and the height number of each target grid point in its corresponding vertical columnar domain, wherein each target grid point corresponds to a vertical columnar domain in each vertical columnar domain.

[0035] The mapping module is used to construct a two-dimensional virtual index for each target grid point based on the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to each target grid point, and the height number of each target grid point in its corresponding vertical columnar domain. This enables the physicochemical parameterization scheme to use the two-dimensional virtual index to obtain input data and return calculation results.

[0036] In an optional embodiment, when determining the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to each target grid point in the computational space and the height number of each target grid point in its corresponding vertical columnar domain, the second processing module is used to:

[0037] Obtain the initial grid point sequence for each vertical columnar domain. The initial grid point sequence includes: each initial grid point contained in the corresponding vertical columnar domain and the grid point data of each initial grid point. The grid point data includes: a first identifier and a second identifier. The first identifier is the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to the corresponding initial grid point, and the second identifier is the height number of the corresponding initial grid point in its corresponding vertical columnar domain.

[0038] The obtained initial grid point sequences are aggregated to obtain the global grid point dataset;

[0039] Identify duplicate grid points in the global grid point dataset, retain unique grid points and grid point data of unique grid points to obtain the target grid point dataset, and based on the target grid point dataset, determine the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to each target grid point and the height number of each target grid point in its corresponding vertical columnar domain. Each grid point in the target grid point dataset uniquely corresponds to one vertical columnar domain.

[0040] In one optional embodiment, when obtaining the initial grid point sequence for each vertical columnar domain, the second processing module is used to:

[0041] Each MPI process identifies the list of underlying surface primitives contained in its local computation space and integrates the obtained lists of underlying surface primitives into a global list of underlying surface primitives.

[0042] Each MPI process independently searches the distribution of each grid point in its local computation space on each vertical columnar domain based on the global underlying primitive list, thus obtaining the grid point distribution information for each MPI process.

[0043] Based on the obtained grid point distribution information, the initial grid point sequence of each vertical columnar domain is generated.

[0044] In one optional embodiment, when the obtained initial grid point sequences are aggregated to obtain a global grid point dataset, the second processing module is used to:

[0045] For each vertical columnar region, the following operations are performed: Based on the grid distribution density of a vertical columnar region in the vertical direction, grid addition and / or grid deletion are performed on each initial grid point of the vertical columnar region to obtain each standard grid point of the vertical columnar region. The primitive number of the underlying surface primitive of the vertical columnar region is used as the first identifier of each standard grid point, and the height number of each standard grid point in the vertical columnar region is used as the second identifier of each standard grid point, thereby obtaining a standard grid point sequence of the vertical columnar region. The standard grid point sequence includes: each standard grid point and its own grid point data.

[0046] The obtained standard grid point sequences are aggregated to obtain a global grid point dataset.

[0047] In an optional embodiment, when performing grid point addition and / or grid point deletion processing on each initial grid point of a vertical columnar domain based on the grid point distribution density in the vertical direction, the second processing module is used to:

[0048] Dynamically detect the grid distribution density of a vertical columnar domain in the vertical direction;

[0049] When a sparse grid region is determined to exist, a virtual grid is added in the sparse grid region;

[0050] When a dense grid region is determined to exist, delete at least one initial grid point in the dense grid region, or add a virtual grid point in the dense grid region and delete at least two initial grid points.

[0051] In one optional embodiment, when identifying duplicate grid points in the global grid point dataset, retaining unique grid points and their data, and obtaining the target grid point dataset, the second processing module is used to:

[0052] For each global grid point in the global grid point dataset, sort the global grid points using the first identifier as the primary key and the second identifier as the secondary key to obtain an ordered grid point dataset.

[0053] Identify duplicate grid points in an ordered grid point dataset, and retain unique grid points and their data according to preset grid point retention rules to obtain the target grid point dataset.

[0054] In an optional embodiment, the grid data of the virtual grid points further includes: phylogenetic information, which records the grid identifiers of each parent grid point that generated the virtual grid points and the generation method of the virtual grid points; then the device further includes: a feedback module, which is used for:

[0055] When the physicochemical parameterization scheme calculates the calculation results of the grid point to be fed back, if the grid point to be fed back is a virtual grid point, the calculation results are allocated based on the spectral information of the virtual grid point, and the allocated calculation results are fed back to the corresponding parent grid point.

[0056] In one optional embodiment, the two-dimensional virtual index consists of a column index and a layer index. The column index is determined based on the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to the target grid point, and the layer index is determined based on the height number of the target grid point in its corresponding vertical columnar domain.

[0057] Thirdly, embodiments of this application also provide an electronic device, including:

[0058] Processor; and

[0059] Stored program memory,

[0060] The program includes instructions that, when executed by the processor, cause the processor to perform the MPI parallel method across mesh topologies as described in the first aspect.

[0061] Fourthly, embodiments of this application also provide a non-transitory computer-readable storage medium storing computer instructions, wherein the computer instructions are used to cause a computer to execute the MPI parallel method across mesh topology as described in the first aspect.

[0062] Fifthly, this application provides a computer program product that, when invoked by a computer, causes the computer to execute the steps of the MPI parallel method across mesh topology as described in the first aspect.

[0063] The beneficial effects of this application are as follows:

[0064] In the cross-grid topology MPI parallel method provided in this application embodiment, each underlying surface primitive is used as a reference unit, and a cylindrical projection is performed along the opposite direction of gravity to divide the computational space corresponding to the target region into vertical cylindrical domains. The underlying surface primitive is a face of an unstructured mesh on the underlying surface, and the vertical cylindrical domains do not overlap. Then, the primitive number of the underlying surface primitive corresponding to each target grid point in the computational space and the height number of each target grid point within its corresponding vertical cylindrical domain are determined. Each target grid point corresponds to one vertical cylindrical domain. Based on the primitive number of the underlying surface primitive corresponding to each target grid point's vertical cylindrical domain and the height number of each target grid point within its corresponding vertical cylindrical domain, a two-dimensional virtual index is constructed for each target grid point. This allows the physicochemical parameterization scheme to use the two-dimensional virtual index to obtain input data and return computation results. In this way, a logically regularized vertical air column data structure is constructed for each underlying surface primitive, and a globally consistent two-dimensional virtual index is provided to address the complexity and efficiency bottlenecks of direct coupling. It achieves automated and parallel topological mapping from arbitrarily complex unstructured grids to standard one-dimensional vertical single-column data structures. The physicochemical parameterization scheme can obtain the required input data as if accessing a regular array, shielding the details of underlying MPI parallel communication and complex data structures, enabling seamless integration of complex physicochemical parameterization schemes, and fully leveraging the enormous potential of three-dimensional dynamic adaptive grids in capturing multi-scale phenomena and improving forecast accuracy.

[0065] Furthermore, other features and advantages of this application will be set forth in the following description and will be apparent in part from the description, or may be learned by practicing the application. The objectives and other advantages of this application may be realized and obtained by means of the structures particularly pointed out in the written description, claims, and drawings. Attached Figure Description

[0066] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described herein are used to provide a further understanding of this application, constitute a part of this application, and do not constitute an improper limitation of this application. In the accompanying drawings:

[0067] Figure 1 This is a schematic diagram of an optional system architecture applicable to the embodiments of this application;

[0068] Figure 2 A schematic diagram illustrating the implementation process of a cross-mesh topology MPI parallel method provided in this application embodiment;

[0069] Figure 3 A schematic diagram illustrating the division of vertical columnar domains as provided in an embodiment of this application;

[0070] Figure 4 A schematic diagram illustrating a virtual filler provided in an embodiment of this application;

[0071] Figure 5 A schematic diagram of the structure of a cross-mesh topology MPI parallel device provided in an embodiment of this application;

[0072] Figure 6 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Detailed Implementation

[0073] Embodiments of this application will now be described in more detail with reference to the accompanying drawings. While some embodiments of this application are shown in the drawings, it should be understood that this application can be implemented in various forms and should not be construed as limited to the embodiments set forth herein. Rather, these embodiments are provided to provide a more thorough and complete understanding of this application. It should be understood that the drawings and embodiments of this application are for illustrative purposes only and are not intended to limit the scope of protection of this application.

[0074] It should be understood that the steps described in the method embodiments of this application may be performed in different orders and / or in parallel. Furthermore, the method embodiments may include additional steps and / or omit the steps shown. The scope of this application is not limited in this respect.

[0075] The term "comprising" and its variations as used herein are open-ended, meaning "including but not limited to". The term "based on" means "at least partially based on". The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments". Definitions of other terms will be given in the following description. It should be noted that the concepts of "first", "second", etc., mentioned in this application are used only to distinguish different devices, modules, or units, and are not intended to limit the order of functions performed by these devices, modules, or units or their interdependencies.

[0076] It should be noted that the terms "a" and "a plurality of" used in this application are illustrative rather than restrictive, and those skilled in the art should understand that, unless otherwise expressly indicated in the context, they should be understood as "one or more".

[0077] The names of the messages or information exchanged between multiple devices in the embodiments of this application are for illustrative purposes only and are not intended to limit the scope of these messages or information.

[0078] The design concept of the embodiments of this application is briefly introduced below:

[0079] In atmospheric science, advances in numerical weather prediction, climate forecasting, and air quality forecasting rely heavily on numerical models built on high-performance parallel computers. A core element of these models is the tight coupling between a dynamic framework that accurately describes atmospheric motion and parameterization schemes that characterize key physicochemical processes.

[0080] Traditional numerical weather prediction (NWP) and air quality prediction (AQP) models (hereinafter referred to as numerical prediction models) rely on discretizing complex atmospheric motions and physicochemical processes onto a three-dimensional spatial grid for solution. A key characteristic is that the model's dynamic framework (responsible for solving fluid dynamic equations, such as an approximation of the Navier-Stokes equations) and physicochemical parameterization schemes (used to describe sub-grid-scale physical processes, such as radiative transfer, boundary layer turbulence, cloud microphysics, convection, land surface processes, and atmospheric chemical reactions) typically share the same numerical computation grid. This design avoids the complex data interpolation and information exchange problems introduced by grid mismatches between different model components, thus eliminating the need for additional couplers to coordinate and transfer data. Parallelization of the models primarily relies on high-performance computing (HPC) platforms, implemented through parallel programming models such as MPI.

[0081] Traditional numerical weather prediction models widely employ structured, regular grids, such as horizontal latitude-longitude grids or, to some extent, cube-sphere grids that overcome the extreme singularity problem, superimposed with vertical terrain-following grids. These regular grids possess clear topological structures and neighborhood relationships. When using MPI for parallel computation, a domain decomposition strategy is typically employed, dividing the entire computational domain into several subdomains, with each MPI process responsible for computing one or more subdomains. Due to the regularity of the grids, the boundaries of each subdomain and the identification of its neighboring subdomains are relatively straightforward. Therefore, communication between MPI processes primarily focuses on exchanging information about halo regions or ghost cells at the boundaries of their respective computational domains. These halo regions contain data from neighboring subdomains near their boundaries and are essential for ensuring the correct computation of the difference scheme at the domain boundaries. For example, during finite difference or finite volume calculations, an update at one grid point may require values ​​from its surrounding neighboring grid points. If a neighboring grid point is located in a subdomain managed by another MPI process, it needs to be obtained through MPI communication. This neighbor-based communication model is relatively simple to implement in regular grids, and the communication pattern is relatively fixed and predictable, which is beneficial for optimizing communication efficiency. Since the dynamic framework and the physicochemical parameterization scheme operate on the same regular grid, the dynamic variables required for the physicochemical parameterization calculations (such as temperature, humidity, and wind field) can be directly obtained from the current grid point, and the calculation results (such as heating rate and water vapor source / sink terms) are directly fed back into the dynamic equations of the same grid point, eliminating the need for complex data exchange, interpolation, or mapping operations between irregular and regular grids. This tightly coupled approach simplifies the implementation and maintenance of numerical weather prediction models and helps improve computational efficiency, enabling the models to more effectively utilize large-scale parallel computing resources for high-resolution, long-term numerical weather prediction.

[0082] Despite the significant success of traditional numerical weather prediction models in many aspects, the increasing demands for forecast accuracy and simulation of multi-scale phenomena present challenges to further improving the resolution of key regions under the constraint of limited computing resources. For example, while static nested grid techniques can achieve local refinement to some extent, they are often accompanied by complex nested boundary handling, accumulation of two-way feedback errors, and difficulty in flexibly adapting to dynamically changing weather systems, making efficient and accurate multi-scale simulations still extremely difficult.

[0083] In recent years, three-dimensional dynamic adaptive mesh technology has attracted much attention due to its ability to perform high-resolution simulations of key regions while maintaining computational efficiency, demonstrating great potential for improving simulation accuracy. However, this numerical forecasting model using three-dimensional dynamic adaptive meshes (such as tetrahedrons, hereinafter referred to as three-dimensional dynamic meshes) fundamentally breaks the traditional grid paradigm of "horizontal two-dimensional + vertical one-dimensional single column". The highly flexible and time-varying grid characteristics of three-dimensional dynamic meshes create a significant "impedance mismatch" with the requirement of traditional physicochemical parameterization schemes for fixed one-dimensional vertical column data, greatly increasing the coupling difficulty and severely restricting its application in operational forecasting. In particular, considering how to quickly establish a high-quality MPI parallel coupling method to address the time-varying nature of three-dimensional dynamic adaptive meshes and the specific requirements of physicochemical parameterization schemes, it has become a key technical bottleneck that urgently needs to be solved. Therefore, given that current physicochemical parameterization schemes are unlikely to undergo fundamental changes in the short term to adapt to the unstructured data input of three-dimensional dynamic meshes, developing a parallel mapping technology that can efficiently connect three-dimensional dynamic meshes with traditional one-dimensional columnar physicochemical processes to meet the timeliness requirements of operational forecasting has become a key bottleneck driving the development of the next generation of numerical models.

[0084] To address this challenge, this application proposes a parallel MPI method, apparatus, and electronic device across grid topologies. The core idea of ​​this application is to build an efficient and accurate data bridge between dynamically evolving three-dimensional unstructured grids and physicochemical parameterization schemes that require stable one-dimensional input. This aims to solve the coupling problem between three-dimensional dynamic grids and traditional physicochemical parameterization schemes, and provide key support for improving the accuracy and efficiency of numerical weather prediction models. The method includes: using each underlying surface primitive as a reference unit, a cylindrical projection is performed along the opposite direction of gravity to divide the computational space corresponding to the target region into vertical cylindrical domains. Each underlying surface primitive is a face of an unstructured mesh on the underlying surface, and the vertical cylindrical domains do not overlap. Then, the primitive number of the underlying surface primitive corresponding to each target grid point in the computational space and the height number of each target grid point within its corresponding vertical cylindrical domain are determined. Each target grid point corresponds to one vertical cylindrical domain. Finally, based on the primitive number of the underlying surface primitive corresponding to each target grid point's vertical cylindrical domain and the height number of each target grid point within its corresponding vertical cylindrical domain, a two-dimensional virtual index is constructed for each target grid point. This allows the physicochemical parameterization scheme to use the two-dimensional virtual index to obtain input data and return computation results. In this way, a logically regularized vertical air column data structure is constructed for each underlying surface primitive, and a globally consistent two-dimensional virtual index is provided to address the complexity and efficiency bottlenecks of direct coupling. It achieves automated and parallel topological mapping from arbitrarily complex unstructured grids to standard one-dimensional vertical single-column data structures. The physicochemical parameterization scheme can obtain the required input data like accessing a regular array, shielding the details of underlying MPI parallel communication and complex data structures. This enables seamless integration of complex physicochemical parameterization schemes, fully leveraging the enormous potential of three-dimensional dynamic adaptive grids in capturing multi-scale phenomena and improving forecast accuracy. It not only solves the resolution problem of data in the vertical direction but also greatly simplifies the coupling complexity between different modules, laying a solid technical foundation for improving the overall performance and simulation accuracy of Earth system models.

[0085] In particular, the preferred embodiments of this application will be described below with reference to the accompanying drawings. It should be understood that the preferred embodiments described herein are for illustration and explanation only and are not intended to limit this application. Furthermore, the embodiments of this application and the features in the embodiments can be combined with each other without conflict.

[0086] See Figure 1The diagram illustrates an optional system architecture applicable to an embodiment of this application. This system architecture may include: terminal devices (101a, 101b) and server 102. The terminal devices (101a, 101b) and server 102 can interact via a communication network. The communication network may employ wireless communication or wired communication methods. For example, the terminal devices (101a, 101b) can access the network and communicate with server 102 via cellular mobile communication technology. This cellular mobile communication technology may include, for example, 5G (5th generation mobile networks) or next-generation mobile communication technology. Optionally, the terminal devices (101a, 101b) can access the network and communicate with server 102 via short-range wireless communication. This short-range wireless communication method may include, for example, wireless fidelity (Wi-Fi) technology.

[0087] This application embodiment does not impose any limitation on the number of communication devices involved in the above system architecture. For example, the above system architecture may include more terminal devices, or it may include fewer terminal devices, or it may also include other network devices. Figure 1 As shown, only terminal devices (101a, 101b) and server 102 are described as examples. The following is a brief introduction to the above communication devices and their respective functions.

[0088] A terminal device (101a, 101b) is a device that can provide voice and / or data connectivity to a user, and may be a device that supports wired and / or wireless connections.

[0089] For example, terminal devices (101a, 101b) may include, but are not limited to: mobile phones, tablets, laptops, handheld computers, mobile internet devices (MID), wearable devices, virtual reality (VR) devices, augmented reality (AR) devices, wireless terminal devices in industrial control, wireless terminal devices in autonomous driving, wireless terminal devices in smart grids, wireless terminal devices in transportation safety, wireless terminal devices in smart cities, or wireless terminal devices in smart homes, etc.

[0090] In addition, the terminal devices (101a, 101b) may have related clients installed. These clients may be software, such as applications (APP), browsers, short video software, web pages, mini-programs, etc. It should be noted that the terminal devices (101a, 101b) in this embodiment may be the aforementioned clients related to MPI parallelism across mesh topologies.

[0091] Server 102 can be a standalone physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, content delivery networks (CDN), and big data and artificial intelligence platforms.

[0092] The following describes the MPI parallel method across mesh topologies provided by exemplary embodiments of this application in conjunction with the above-described system architecture and with reference to the accompanying drawings. It should be noted that the above-described system architecture is only shown to facilitate understanding of the spirit and principles of this application, and the embodiments of this application are not limited in any way in this respect.

[0093] See Figure 2 The diagram shown illustrates the implementation flow of a cross-mesh topology MPI parallel method provided in this application embodiment. Taking a server as an example, the specific implementation flow of this method is as follows:

[0094] S20: Using each underlying surface primitive as a reference unit, a cylindrical projection is performed along the opposite direction of gravity to divide the computational space corresponding to the target area into vertical cylindrical domains.

[0095] In this context, the underlying surface primitive is an unstructured mesh on the underlying surface, and the vertical columnar domains do not overlap. Each underlying surface primitive corresponds to a vertical columnar domain (i.e., a defined three-dimensional vertical subdomain).

[0096] In this embodiment, the underlying surface is the underlying surface corresponding to the target area. Optionally, the target area can be a city (such as a county or a city), or an area obtained according to a specified area division method; this embodiment of the invention does not limit this. Optionally, the unstructured mesh can be a tetrahedron, or other meshes that break the traditional "horizontal two-dimensional + vertical one-dimensional single column" mesh paradigm (such as square pyramids and pentagonal pyramids); this embodiment of the invention does not limit this.

[0097] For example, assuming the unstructured mesh is a tetrahedron, then a substrate cell is a contact surface of an unstructured mesh on the substrate. The substrate cell is a planar triangle, and the vertical columnar domain is a triangular prism.

[0098] In this embodiment, there are multiple underlying surface primitives on the underlying surface. Taking each underlying surface primitive as a reference unit, a columnar projection is performed along the opposite direction of gravity to divide the computational space corresponding to the target area into non-overlapping vertical columnar domains.

[0099] For example, see Figure 3 The diagram shown is a schematic of the vertical columnar domain division in the embodiment of this application, wherein the unstructured mesh is a tetrahedron and the shape of the underlying surface primitive is a planar triangle. Figure 3 (a) is a schematic diagram of dividing the computational space corresponding to the target region into non-overlapping vertical columnar domains, as shown in the figure. Figure 3 (a) As shown in the figure, 301 is the underlying surface, 302 is the underlying surface element, and 303 is the vertical columnar domain corresponding to the underlying surface element 302. Figure 3 (b) is a schematic diagram of the computation space decomposition of each MPI process. Process 1 corresponds to local computation space 1, process 2 corresponds to local computation space 2, and process 3 corresponds to local computation space 3. Figure 3 (c) is a schematic diagram of the vertical columnar domain across processes, as shown below. Figure 3 As shown in (c), the leftmost vertical column spans processes 1, 2 and 3.

[0100] S21: Determine the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to each target grid point in the computational space, and the height number of each target grid point in its corresponding vertical columnar domain.

[0101] Each target grid point corresponds to one vertical columnar domain. Each target grid point includes: each real grid point and at least one virtual grid point, where each real grid point is a grid point of an unstructured mesh.

[0102] Optionally, in this embodiment of the application, a possible implementation is provided for determining the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to each target grid point in the computational space and the height number of each target grid point in its corresponding vertical columnar domain, specifically by performing the following operations:

[0103] S210: Obtain the initial grid point sequence for each vertical columnar domain.

[0104] The initial grid sequence includes: each initial grid point contained in the corresponding vertical columnar domain and the grid data of each initial grid point. The grid data includes: a first identifier and a second identifier. The first identifier is the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to the corresponding initial grid point, and the second identifier is the height number of the corresponding initial grid point in its corresponding vertical columnar domain.

[0105] In this embodiment of the application, the grid data of a grid point includes, but is not limited to, coordinates, physical quantities, and search identifiers. The coordinates are the physical location of the corresponding grid point, the physical quantities are the results of applying the return force frame after the physical parameterization scheme is calculated (e.g., temperature, humidity, wind field, etc.), and the search identifiers include a first identifier and a second identifier. The search identifier can be represented as: search ID (column_id, z_k), where column_id represents the first identifier and z_k represents the second identifier.

[0106] Optionally, in this embodiment of the application, a possible implementation is provided for obtaining the initial grid point sequence of each vertical columnar domain, specifically by performing the following operations:

[0107] S2100: Each MPI process identifies the list of underlying surface primitives contained in its local computation space and integrates the obtained lists of underlying surface primitives into a global list of underlying surface primitives.

[0108] In this embodiment of the application, each MPI process first checks the list of underlying surface primitives contained in the local computing space it is responsible for, and then shares the list of underlying surface primitives through a set communication operation (e.g., MPI_Allgather), so that each MPI process obtains a complete global list of underlying surface primitives.

[0109] S2101: Each MPI process independently searches the distribution of each grid point in its local computational space on each vertical columnar domain based on the global underlying surface primitive list, thus obtaining the grid point distribution information for each MPI process.

[0110] The grid distribution information includes the vertical columnar domain to which each grid point belongs within the local computation space managed by the corresponding MPI process, as well as the grid point data of each grid point.

[0111] In this embodiment of the application, each MPI process independently searches the distribution of each grid point in its local computation space on each vertical columnar domain according to the global underlying surface primitive list, thereby obtaining the grid point distribution information of each MPI process.

[0112] S2102: Based on the obtained grid point distribution information, generate the initial grid point sequence for each vertical columnar domain.

[0113] In this embodiment of the application, the distribution information of each grid point is collected through a combined communication operation (e.g., MPI_Alltoallv) to obtain the initial grid point sequence of each vertical columnar domain.

[0114] For example, if grid points 1A and 1B in the local computation space of process 1 belong to vertical columnar domain 1, grid points 2A, 2B, and 2C in the local computation space of process 2 belong to vertical columnar domain 1, and grid point 3A in the local computation space of process 3 belongs to vertical columnar domain 1, then the initial grid point sequence of vertical columnar domain 1 includes: grid point 1A, grid point 1B, grid point 2A, grid point 2B, grid point 2C, and grid point 3A.

[0115] In this way, each MPI process first identifies local information, then integrates it into a global view, and finally searches independently. This greatly improves efficiency compared to centralized search, and is especially suitable for ultra-large-scale computing, enabling the rapid construction of a complete initial grid representation for each vertical columnar domain.

[0116] S211: Collect the obtained initial grid point sequences to obtain the global grid point dataset.

[0117] In this embodiment of the application, the obtained initial grid sequence is aggregated and spliced ​​into each process through a set communication operation (e.g., MPI_Allgatherv) to obtain a globally unified and flattened global grid dataset.

[0118] Optionally, instead of directly aggregating the initial grid point sequences to obtain a global grid point dataset, the global grid point dataset can be obtained by aggregating the standard grid point sequences obtained based on the initial grid point sequences. In this embodiment, another possible implementation is provided for aggregating the obtained initial grid point sequences to obtain a global grid point dataset, specifically by performing the following operations:

[0119] S2110: For each vertical columnar domain, perform the following operations respectively: Based on the grid distribution density of a vertical columnar domain in the vertical direction, perform grid addition and / or grid deletion processing on each initial grid point of a vertical columnar domain to obtain each standard grid point of a vertical columnar domain, and use the primitive number of the underlying surface primitive of a vertical columnar domain as the first identifier of each standard grid point, and use the height number of each standard grid point in a vertical columnar domain as the second identifier of each standard grid point, thereby obtaining a standard grid point sequence of a vertical columnar domain.

[0120] The standard grid sequence includes each standard grid point and its individual grid data. Each newly added grid point is a virtual grid point, and the grid data of each virtual grid point also includes lineage information. The lineage information records the grid identifiers of each parent grid point that generated the virtual grid point and the generation method of the virtual grid point. The generation method includes, but is not limited to, optimal interpolation, higher-order interpolation, weighted average, etc.

[0121] In this way, the application of a resolution-adaptive "virtual supplementation" mechanism ensures the completeness and adaptability of the input data required for the physicochemical parameterization scheme. The vertical grid structure of traditional fixed grid models is pre-set by the model developer, with a denser bottom and sparser top. The new mechanism designed in this patent can dynamically detect areas in the vertical columnar domain extracted from the 3D dynamic grid that are too sparse or too dense. By generating virtual grid points or merging / removing redundant grid points, it ensures that the physical process obtains input data that meets its accuracy and stability requirements at all vertical levels, avoiding simulation deviations caused by resolution mismatch.

[0122] Optionally, in this embodiment of the application, another possible implementation is provided for performing grid point addition and / or grid point deletion processing on each initial grid point of a vertical columnar domain based on the grid point distribution density in the vertical direction. Specifically, the following operations are performed:

[0123] S2110-1: Dynamically detect the grid distribution density of a vertical columnar domain in the vertical direction.

[0124] S2110-2: When it is determined that there is a sparse grid region, add virtual grid points in the sparse grid region.

[0125] Among them, the sparse grid region is characterized by the height spacing between two adjacent grid points in a vertical columnar domain being greater than the maximum spacing threshold.

[0126] S2110-3: When it is determined that there is a dense grid region, delete at least one initial grid point in the dense grid region, or add a virtual grid point in the dense grid region and delete at least two initial grid points.

[0127] Among them, the dense grid region is characterized by the height spacing between two adjacent grid points in a vertical columnar domain being less than the minimum spacing threshold.

[0128] Specifically, in this embodiment, it is determined whether the height distance between two adjacent grid points in a vertical columnar domain is greater than the maximum distance threshold. If so, virtual grid points are inserted using optimal interpolation or higher-order interpolation (e.g., Lagrange, cubic spline), and the virtual grid points are assigned spatial positions and initial physical quantities. Simultaneously, it is determined whether the height distance between two adjacent grid points in a vertical columnar domain is less than the minimum distance threshold. If so, grid point merging (e.g., weighted averaging) or selective removal is performed.

[0129] Among them, grid merging generates new virtual grids. At this time, it is necessary to delete the two adjacent grids and assign spatial position and initial physical quantity to the virtual grid. Selective culling refers to deleting one of the two adjacent grids and retaining only one grid.

[0130] For example, see Figure 4 The diagram shown is a schematic representation of virtual padding in an embodiment of this application. Figure 4 (a) is a schematic diagram of the initial grid points of the vertical columnar domain. Figure 4 (b) is a schematic diagram of the standard grid points of the vertical columnar domain. The height spacing between grid point 1 and grid point 2 is greater than the maximum spacing threshold, so a virtual grid point 3 is added between grid point 1 and grid point 2; the height spacing between grid point 4 and grid point 5 is less than the minimum spacing threshold, so grid point 5 is deleted; the height spacing between grid point 6 and grid point 7 is less than the minimum spacing threshold, so grid point 6 is deleted.

[0131] In this way, by adding and deleting grid points based on vertical density, the numerical stability requirements of the physical parameterization scheme are dynamically ensured for the data density of each vertical columnar domain. This solves the problem of potentially uneven data density extracted from irregular 3D grids: in sparse grid areas, virtual grid points are added to avoid computational distortion, and in dense grid areas, redundancy is eliminated to improve computational efficiency. This ensures that the physical processes obtain high-quality output data in all regions, thereby significantly improving the accuracy and reliability of the final weather forecast or climate simulation.

[0132] S2111: Collect the obtained standard grid point sequences to obtain a global grid point dataset.

[0133] In this embodiment of the application, the obtained standard grid sequence is aggregated and spliced ​​into each process through a set communication operation (e.g., MPI_Allgatherv) to obtain a global grid dataset.

[0134] S212: Identify duplicate grid points in the global grid point dataset, retain unique grid points and grid point data of unique grid points to obtain the target grid point dataset, and based on the target grid point dataset, determine the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to each target grid point and the height number of each target grid point in its corresponding vertical columnar domain.

[0135] Each grid point in the target grid dataset uniquely corresponds to one of the vertical column domains.

[0136] Optionally, in this embodiment of the application, another possible implementation is provided to identify duplicate grid points in the global grid point dataset, retain unique grid points and grid point data of unique grid points, and obtain the target grid point dataset, specifically by performing the following operations:

[0137] S2120: For each global grid point contained in the global grid point dataset, sort the global grid points using the first identifier of each global grid point as the primary key and the second identifier as the secondary key to obtain an ordered grid point dataset.

[0138] In this embodiment, an efficient parallel sorting algorithm (e.g., sample sorting or bucket sort) is used to sort the global grid points contained in the global grid dataset using the first identifier of the search identifier as the primary key and the second identifier of the search identifier as the secondary key, thereby obtaining an ordered grid dataset.

[0139] In this way, the sorted ordered grid dataset not only ensures that grid points that logically belong to the same vertical triangular prism are clustered and stored in the data structure in an orderly manner, laying the foundation for subsequent mapping and access, but also enables the rapid identification of duplicate data from the ordered grid dataset.

[0140] S2121: Identify duplicate grid points in an ordered grid point dataset, and retain unique grid points and their data according to preset grid point retention rules to obtain the target grid point dataset.

[0141] The preset grid point retention rules can include retaining the first item, numerical averaging, or selecting the best quality. Since there are grid points at the boundary between two vertical columnar domains, these grid points will exist in both the grid point sequence corresponding to the first vertical columnar domain and the grid point sequence corresponding to the second vertical columnar domain. These grid points will have two grid point data points, making them duplicate grid points.

[0142] In this embodiment, the ordered grid dataset is traversed, duplicate grid points are identified and processed, and a unique grid point is retained according to the preset grid point retention rules to ensure that each logical location has only one clear grid point.

[0143] This ensures the uniqueness and correctness of the target grid dataset used to build the index, avoids physical calculation errors or numerical instability caused by data duplication, and ensures that there is only one clear grid data for each logical location.

[0144] S22: Based on the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to each target grid point, and the height number of each target grid point in its corresponding vertical columnar domain, construct a two-dimensional virtual index for each target grid point, so that the physicochemical parameterization scheme can use the two-dimensional virtual index to obtain input data and return calculation results.

[0145] The two-dimensional virtual index consists of a column index and a layer index. The column index is determined based on the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to the target grid point, and the layer index is determined based on the height number of the target grid point in its corresponding vertical columnar domain. The two-dimensional virtual index can be represented as (i_column, k_level), where i_column represents the column index and k_level represents the layer index.

[0146] In this embodiment, the column index of each target grid point is determined based on the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to each target grid point, and the layer index of each target grid point is determined based on the height number of each target grid point in its corresponding vertical columnar domain. A continuous integer mapping from 1 to N (the total number of globally unique triangular prisms) is constructed for each target grid point to form the column index i_column of each target grid point. A layer index k_level from 1 to M (the vertical layer number of the corresponding grid point in the vertical columnar domain) is then assigned to each target grid point. The two-dimensional virtual index provides an abstract data access layer for the physical process that is independent of the underlying complexity, significantly improving the efficiency and convenience of physical and chemical processes accessing distributed data in a parallel environment. By globally parallel sorting the grid point data of all processes and generating a concise two-dimensional virtual index, the physical process module can obtain the required data as if accessing a regular array, shielding the details of the underlying MPI parallel communication and complex data structures.

[0147] Where N is the total number of vertical columnar domains, and M is the number of vertical layers in a vertical columnar domain. The vertical columnar domains of each vertical columnar domain can be the same or different.

[0148] Furthermore, in this embodiment, a set of concise application programming interfaces (APIs) is provided, such as get_column_data(i_column, k_level, field_name), where (i_column, k_level) represents a two-dimensional virtual index and field_name represents a physical quantity. This allows physicochemical parameterization schemes to use the two-dimensional virtual index to obtain input data (grid data corresponding to the target grid point) and return calculation results. Internally, the coupler API is responsible for accurately mapping the two-dimensional virtual index to the target grid point (the actually stored, optimized three-dimensional grid data or its derivatives).

[0149] Optionally, in this embodiment of the application, when the physicochemical parameterization scheme calculates the calculation result of the grid point to be fed back, if the grid point to be fed back is a virtual grid point, the calculation result is allocated based on the spectral information of the virtual grid point, and the allocated calculation result is fed back to the corresponding parent grid point.

[0150] The calculation results can be feedback quantities such as energy and water vapor. The distribution of the calculation results can be achieved through the inverse relationship of the interpolation weights (or its transpose, considering conservation).

[0151] This establishes a "lineage tracing" relationship between virtual grid points and original 3D grid points, ensuring the precise application of physical process feedback and the overall conservation of the model. During the virtual interpolation process, detailed records are kept of which original 3D grid points generated each virtual grid point and how they were generated. When the physical process calculates the feedback quantity, this lineage information can be used to precisely allocate or interpolate the feedback quantity back to the original 3D grid points corresponding to the power core, ensuring the accurate transfer of energy and matter during the coupling process. Furthermore, the allocation of calculation results is also efficiently implemented in parallel, ensuring that contributions are correctly accumulated, achieving closed-loop, efficient, bidirectional coupling between the power core and the physicochemical module.

[0152] Optionally, in this embodiment, when a change in the three-dimensional dynamic adaptive mesh is detected, S20-S22 are re-executed to reconstruct the cylindrical projection and two-dimensional virtual index for each unstructured mesh after the change, so as to ensure that the two-dimensional virtual index is consistent with the current state of the three-dimensional dynamic adaptive mesh.

[0153] Furthermore, based on the same technical concept, embodiments of this application provide a cross-mesh topology MPI parallel device, which is used to implement the above-described method flow of embodiments of this application. For example, see [link to relevant documentation]. Figure 5As shown, the cross-grid topology MPI parallel device 500 may include: a first processing module 501, a second processing module 502, a mapping module 503, and a feedback module 504, wherein:

[0154] The first processing module 501 is used to perform columnar projection along the opposite direction of gravity with each underlying surface primitive as a reference unit, and divide the computational space corresponding to the target area into vertical columnar domains. The underlying surface primitive is a face of an unstructured mesh on the underlying surface, and the vertical columnar domains do not overlap.

[0155] The second processing module 502 is used to determine the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to each target grid point in the computation space and the height number of each target grid point in its corresponding vertical columnar domain, wherein each target grid point corresponds to a vertical columnar domain in each vertical columnar domain.

[0156] The mapping module 503 is used to construct a two-dimensional virtual index for each target grid point based on the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to each target grid point and the height number of each target grid point in its corresponding vertical columnar domain, so that the physicochemical parameterization scheme can use the two-dimensional virtual index to obtain input data and return calculation results.

[0157] In an optional embodiment, when determining the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to each target grid point in the computational space and the height number of each target grid point in its corresponding vertical columnar domain, the second processing module 502 is used to:

[0158] Obtain the initial grid point sequence for each vertical columnar domain. The initial grid point sequence includes: each initial grid point contained in the corresponding vertical columnar domain and the grid point data of each initial grid point. The grid point data includes: a first identifier and a second identifier. The first identifier is the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to the corresponding initial grid point, and the second identifier is the height number of the corresponding initial grid point in its corresponding vertical columnar domain.

[0159] The obtained initial grid point sequences are aggregated to obtain the global grid point dataset;

[0160] Identify duplicate grid points in the global grid point dataset, retain unique grid points and grid point data of unique grid points to obtain the target grid point dataset, and based on the target grid point dataset, determine the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to each target grid point and the height number of each target grid point in its corresponding vertical columnar domain. Each grid point in the target grid point dataset uniquely corresponds to one vertical columnar domain.

[0161] In an optional embodiment, when obtaining the initial grid sequence for each vertical columnar domain, the second processing module 502 is used to:

[0162] Each MPI process identifies the list of underlying surface primitives contained in its local computation space and integrates the obtained lists of underlying surface primitives into a global list of underlying surface primitives.

[0163] Each MPI process independently searches the distribution of each grid point in its local computation space on each vertical columnar domain based on the global underlying primitive list, thus obtaining the grid point distribution information for each MPI process.

[0164] Based on the obtained grid point distribution information, the initial grid point sequence of each vertical columnar domain is generated.

[0165] In an optional embodiment, when the obtained initial grid point sequences are aggregated to obtain a global grid point dataset, the second processing module 502 is used to:

[0166] For each vertical columnar region, the following operations are performed: Based on the grid distribution density of a vertical columnar region in the vertical direction, grid addition and / or grid deletion are performed on each initial grid point of the vertical columnar region to obtain each standard grid point of the vertical columnar region. The primitive number of the underlying surface primitive of the vertical columnar region is used as the first identifier of each standard grid point, and the height number of each standard grid point in the vertical columnar region is used as the second identifier of each standard grid point, thereby obtaining a standard grid point sequence of the vertical columnar region. The standard grid point sequence includes: each standard grid point and its own grid point data.

[0167] The obtained standard grid point sequences are aggregated to obtain a global grid point dataset.

[0168] In an optional embodiment, when performing grid point addition and / or grid point deletion processing on each initial grid point of a vertical columnar domain based on the grid point distribution density in the vertical direction, the second processing module 502 is used to:

[0169] Dynamically detect the grid distribution density of a vertical columnar domain in the vertical direction;

[0170] When a sparse grid region is determined to exist, a virtual grid is added in the sparse grid region;

[0171] When a dense grid region is determined to exist, delete at least one initial grid point in the dense grid region, or add a virtual grid point in the dense grid region and delete at least two initial grid points.

[0172] In an optional embodiment, when identifying duplicate grid points in the global grid dataset, retaining unique grid points and their data, and obtaining the target grid dataset, the second processing module 502 is used to:

[0173] For each global grid point in the global grid point dataset, sort the global grid points using the first identifier as the primary key and the second identifier as the secondary key to obtain an ordered grid point dataset.

[0174] Identify duplicate grid points in an ordered grid point dataset, and retain unique grid points and their data according to preset grid point retention rules to obtain the target grid point dataset.

[0175] In an optional embodiment, the grid data of the virtual grid points further includes: phylogenetic information, which records the grid identifiers of each parent grid point that generated the virtual grid points and the generation method of the virtual grid points; then the device further includes: a feedback module, the feedback module 504 being used for:

[0176] When the physicochemical parameterization scheme calculates the calculation results of the grid point to be fed back, if the grid point to be fed back is a virtual grid point, the calculation results are allocated based on the spectral information of the virtual grid point, and the allocated calculation results are fed back to the corresponding parent grid point.

[0177] In one optional embodiment, the two-dimensional virtual index consists of a column index and a layer index. The column index is determined based on the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to the target grid point, and the layer index is determined based on the height number of the target grid point in its corresponding vertical columnar domain.

[0178] Based on the description of the method and apparatus embodiments above, an exemplary embodiment of the present invention also provides an electronic device, including: at least one processor; and a memory communicatively connected to the at least one processor. The memory stores a computer program executable by the at least one processor, which, when executed by the at least one processor, causes the electronic device to perform the method according to an embodiment of the present invention.

[0179] This application also provides a non-transitory computer-readable storage medium storing a computer program, wherein the computer program, when executed by a computer's processor, is used to cause the computer to perform a method according to an embodiment of this application.

[0180] This application also provides a computer program product, including a computer program, wherein the computer program, when executed by a computer's processor, is used to cause the computer to perform a method according to an embodiment of this application.

[0181] See Figure 6The diagram illustrates a structural block diagram of an electronic device 600 that can serve as a server or client in this application, serving as an example of hardware devices applicable to various aspects of this application. The electronic device is intended to represent various forms of digital electronic computer devices, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital processors, cellular phones, smartphones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely illustrative and are not intended to limit the implementation of the application described and / or claimed herein.

[0182] like Figure 6 As shown, the electronic device 600 includes a computing unit 601, which can perform various appropriate actions and processes based on a computer program stored in a read-only memory (ROM) 602 or a computer program loaded from a storage unit 608 into a random access memory (RAM) 603. The RAM 603 may also store various programs and data required for the operation of the device 600. The computing unit 601, ROM 602, and RAM 603 are interconnected via a bus 604. An input / output (I / O) interface 605 is also connected to the bus 604.

[0183] Multiple components in electronic device 600 are connected to I / O interface 605, including: input unit 606, output unit 607, storage unit 608, and communication unit 609. Input unit 606 can be any type of device capable of inputting information to electronic device 600. Input unit 606 can receive input digital or character information and generate key signal inputs related to user settings and / or function control of electronic device. Output unit 607 can be any type of device capable of presenting information and may include, but is not limited to, a display, speaker, video / audio output terminal, vibrator, and / or printer. Storage unit 608 may include, but is not limited to, disks and optical discs. Communication unit 609 allows electronic device 600 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks, and may include, but is not limited to, modems, network cards, infrared communication devices, wireless communication transceivers and / or chipsets, such as Bluetooth devices, WiFi devices, worldwide interoperability for microwave access (WiMax) devices, cellular communication devices, and / or the like.

[0184] The computing unit 601 can be a variety of general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of the computing unit 601 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. The computing unit 601 performs the various methods and processes described above. For example, in some embodiments, the above-described cross-mesh topology MPI parallel method can be implemented as a computer software program tangibly contained in a machine-readable medium, such as storage unit 608. In some embodiments, part or all of the computer program can be loaded and / or installed on the electronic device 600 via ROM 602 and / or communication unit 609. In some embodiments, the computing unit 601 can be configured to perform the above-described cross-mesh topology MPI parallel method by any other suitable means (e.g., by means of firmware).

[0185] The program code used to implement the methods of this application may be written in any combination of one or more programming languages. This program code may be provided to a processor or controller of a general-purpose computer, special-purpose computer, or other programmable data processing device, such that when executed by the processor or controller, the functions / operations specified in the flowcharts and / or block diagrams are implemented. The program code may be executed entirely on a machine, partially on a machine, as a standalone software package partially on a machine and partially on a remote machine, or entirely on a remote machine or server.

[0186] In the context of this application, a machine-readable medium can be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, apparatus, or device. A machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can be, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, RAM, ROM, erasable programmable read-only memory (EPROM) or flash memory, optical fibers, compact disc read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.

[0187] As used in this application, the terms "machine-readable medium" and "computer-readable medium" refer to any computer program product, device, and / or apparatus (e.g., disk, optical disk, memory, programmable logic device, PLD) used to provide machine instructions and / or data to a programmable processor, including machine-readable media that receive machine instructions as machine-readable signals. The term "machine-readable signal" refers to any signal used to provide machine instructions and / or data to a programmable processor.

[0188] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device for displaying information to the user (e.g., a cathode ray tube (CRT) or liquid crystal display (LCD) monitor); and a keyboard and pointing device (e.g., a mouse or trackball) through which the user provides input to the computer. Other types of devices can also be used to provide interaction with the user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including sound input, voice input, or tactile input).

[0189] The systems and technologies described herein can be implemented in computing systems that include backend components (e.g., as data servers), or computing systems that include middleware components (e.g., application servers), or computing systems that include frontend components (e.g., user computers with graphical user interfaces or web browsers through which users can interact with implementations of the systems and technologies described herein), or any combination of such backend, middleware, or frontend components. The components of the system can be interconnected via digital data communication of any form or medium (e.g., communication networks). Examples of communication networks include local area networks (LANs), wide area networks (WANs), and the Internet.

[0190] Computer systems can include clients and servers. Clients and servers are generally located far apart and typically interact through communication networks. Client-server relationships are created by computer programs running on the respective computers and having a client-server relationship with each other.

[0191] Furthermore, it should be understood that the above-disclosed embodiments are merely preferred embodiments of this application and should not be construed as limiting the scope of the invention. Therefore, any equivalent variations made in accordance with the claims of this invention are still within the scope of this application.

Claims

1. A cross-mesh topology MPI parallel method, characterized in that, include: Using each underlying surface primitive as a reference unit, a cylindrical projection is performed along the opposite direction of gravity to divide the computational space corresponding to the target area into vertical cylindrical domains. The underlying surface primitive is a face of an unstructured mesh on the underlying surface, and the vertical cylindrical domains do not overlap. Obtain the initial grid point sequence of each vertical columnar domain, wherein the initial grid point sequence includes: each initial grid point contained in the corresponding vertical columnar domain and the grid point data of each initial grid point, and the grid point data includes: a first identifier and a second identifier, wherein the first identifier is the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to the corresponding initial grid point, and the second identifier is the height number of the corresponding initial grid point in its corresponding vertical columnar domain. For each vertical columnar region, the following operations are performed: based on the grid distribution density of a vertical columnar region in the vertical direction, grid addition and / or grid deletion processes are performed on each initial grid point of the vertical columnar region to obtain each standard grid point of the vertical columnar region. The primitive number of the underlying surface primitive of the vertical columnar region is used as the first identifier of each standard grid point, and the height number of each standard grid point in the vertical columnar region is used as the second identifier of each standard grid point, thereby obtaining the standard grid point sequence of the vertical columnar region. The standard grid point sequence includes: each standard grid point and its respective grid point data. The obtained standard grid point sequences are aggregated to obtain a global grid point dataset; Identify duplicate grid points in the global grid dataset, retain unique grid points and their data to obtain a target grid dataset, and based on the target grid dataset, determine the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to each target grid point in the computational space and the height number of each target grid point in its corresponding vertical columnar domain. Each target grid point corresponds to one vertical columnar domain in the vertical columnar domains, and each grid point in the target grid dataset uniquely corresponds to one vertical columnar domain in the vertical columnar domains. Based on the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to each target grid point, and the height number of each target grid point in its corresponding vertical columnar domain, a two-dimensional virtual index is constructed for each target grid point, so that the physicochemical parameterization scheme can use the two-dimensional virtual index to obtain input data and return calculation results.

2. The method as described in claim 1, characterized in that, The step of obtaining the initial grid point sequence for each of the vertical columnar domains includes: Each MPI process identifies the list of underlying surface primitives contained in its local computation space and integrates the obtained lists of underlying surface primitives into a global list of underlying surface primitives. Each MPI process independently searches the distribution of each grid point in its local computation space on each vertical columnar domain according to the global underlying surface primitive list, thereby obtaining the grid point distribution information of each MPI process. Based on the obtained grid point distribution information, the initial grid point sequence of each vertical columnar domain is generated.

3. The method as described in claim 1, characterized in that, The process of adding and / or deleting grid points based on the grid point distribution density of a vertical columnar domain in the vertical direction includes: Dynamically detect the grid distribution density of a vertical columnar domain in the vertical direction; When a sparse grid region is determined to exist, a virtual grid is added in the sparse grid region; When a dense grid region is determined to exist, at least one initial grid point is deleted from the dense grid region, or a virtual grid point is added to the dense grid region and at least two initial grid points are deleted.

4. The method as described in claim 1, characterized in that, The process of identifying duplicate grid points in the global grid point dataset, retaining unique grid points and their data, and obtaining the target grid point dataset includes: For each global grid point contained in the global grid point dataset, sort the global grid points using the first identifier of each global grid point as the primary key and the second identifier as the secondary key to obtain an ordered grid point dataset. Identify duplicate grid points in the ordered grid point dataset, and retain unique grid points and their data according to preset grid point retention rules to obtain the target grid point dataset.

5. The method as described in claim 3, characterized in that, The grid data of the virtual grid points further includes: phylogenetic information, which records the grid point identifiers of each parent grid point that generated the virtual grid point and the generation method of the virtual grid point; then the method further includes: When the physicochemical parameterization scheme calculates the calculation result of the grid point to be fed back, if the grid point to be fed back is the virtual grid point, the calculation result is allocated based on the spectral information of the virtual grid point, and the allocated calculation result is fed back to the corresponding parent grid point.

6. The method as described in claim 1, characterized in that, The two-dimensional virtual index consists of a column index and a layer index. The column index is determined based on the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to the target grid point, and the layer index is determined based on the height number of the target grid point in its corresponding vertical columnar domain.

7. A cross-mesh topology MPI parallel device, characterized in that, include: The first processing module is used to perform columnar projection along the opposite direction of gravity with each underlying surface primitive as a reference unit, and divide the computational space corresponding to the target area into vertical columnar domains. The underlying surface primitive is a face of an unstructured mesh on the underlying surface, and the vertical columnar domains do not overlap. The second processing module is used to obtain the initial grid point sequence of each of the vertical columnar domains. The initial grid point sequence includes: each initial grid point contained in the corresponding vertical columnar domain and the grid point data of each initial grid point. The grid point data includes: a first identifier and a second identifier. The first identifier is the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to the corresponding initial grid point, and the second identifier is the height number of the corresponding initial grid point in its corresponding vertical columnar domain. For each vertical columnar domain, the following operations are performed: based on the grid point distribution density of a vertical columnar domain in the vertical direction, grid point addition processing and / or grid point deletion processing are performed on each initial grid point of the vertical columnar domain to obtain each standard grid point of the vertical columnar domain. The primitive number of the underlying surface primitive of the vertical columnar domain is used as the first identifier of each standard grid point, and the first identifier of each standard grid point is obtained from the first grid point of the vertical columnar domain. The height number in the vertical columnar domain is used as the second identifier of each standard grid point, thereby obtaining the standard grid point sequence of the vertical columnar domain. The standard grid point sequence includes: each standard grid point and its respective grid point data. The obtained standard grid point sequences are aggregated to obtain a global grid point dataset. Duplicate grid points in the global grid point dataset are identified, and unique grid points and their grid point data are retained to obtain a target grid point dataset. Based on the target grid point dataset, the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to each target grid point in the computational space and the height number of each target grid point in its corresponding vertical columnar domain are determined. Each target grid point corresponds to one vertical columnar domain in the vertical columnar domains, and each grid point in the target grid point dataset uniquely corresponds to one vertical columnar domain in the vertical columnar domains. The mapping module is used to construct a two-dimensional virtual index for each target grid point based on the primitive number of the underlying surface primitive of the vertical columnar domain corresponding to each target grid point and the height number of each target grid point in its corresponding vertical columnar domain, so that the physicochemical parameterization scheme can use the two-dimensional virtual index to obtain input data and return calculation results.

8. An electronic device, comprising: processor; as well as Stored program memory, The program includes instructions that, when executed by the processor, cause the processor to perform the method as described in any one of claims 1-6.