Saddle-shaped Field Region Recognition Method, Device and Electronic Equipment
By acquiring wind field and air pressure data, and automatically identifying saddle field areas using the target detection model and segmentation model, the problem of cumbersome identification operations in the prior art is solved, the identification efficiency is improved and labor costs are saved.
Patent Information
- Application Number
- CN202510181670.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-02-19
- Publication Date
- 2025-07-08
- Estimated Expiration
- 2045-02-19
AI Technical Summary
In the prior art, saddle field area identification operations are cumbersome and lack of convenient identification methods, resulting in low efficiency and high labor costs.
By acquiring the target wind field data and air pressure data, determining the isobaric line image and wind field image, combining the target detection model and segmentation model, the saddle field area is automatically identified.
It realizes convenient identification of saddle field areas, improves identification efficiency and saves labor costs.
Smart Images

Figure CN119649396B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer technology, and in particular to a saddle field area recognition method, device and electronic equipment. Background Art
[0002] A saddle-shaped field area can refer to the middle area where two high pressures and two low pressures are staggered, and can also be called a saddle-shaped pressure field. At present, in the identification of saddle-shaped field areas, the saddle-shaped field areas are usually found on the weather map manually, which leads to cumbersome operations. Based on this, there is currently no good solution for how to conveniently identify saddle-shaped field areas. Summary of the invention
[0003] In view of this, an embodiment of the present invention provides a saddle-type field area identification method, device and electronic device to solve the problem that the related technology has cumbersome operation when realizing saddle-type field area identification; that is, the embodiment of the present invention can conveniently perform saddle-type field area identification to improve the identification efficiency of saddle-type field areas and effectively save labor costs.
[0004] According to one aspect of an embodiment of the present invention, a method for identifying a saddle field region is provided, the method comprising:
[0005] Acquire target wind field data and target air pressure data, wherein the target wind field data includes grid point wind field information of each grid point in the target area, and the target air pressure data includes grid point air pressure values of each grid point;
[0006] Based on the target air pressure data, at least one target isobar is determined; and based on each target isobar in the at least one target isobar, a target isobar image is determined, wherein the target isobar image includes mapped isobars of each target isobar;
[0007] Based on the target wind field data, a target wind field image is generated, wherein a wind field image is used to indicate the size of each wind field in the corresponding wind field data; and based on the target isobar image and the target wind field image, a target image to be detected is generated;
[0008] Calling the target detection model to perform saddle field area detection on the target image to be detected, obtaining at least one area to be segmented indication data of the target image to be detected, and determining the image to be segmented corresponding to the corresponding area to be segmented indication data based on each area to be segmented indication data in the at least one area to be segmented indication data;
[0009] The target segmentation model is called to perform saddle field region segmentation on the images to be segmented corresponding to the respective indication data of the regions to be segmented, so as to obtain saddle field region indication data corresponding to the corresponding indication data of the regions to be segmented.
[0010] According to another aspect of the embodiments of the present invention, there is provided a saddle-shaped field area recognition device, the device comprising:
[0011] An acquisition unit, configured to acquire target wind field data and target air pressure data, where the target wind field data includes grid point wind field information of each grid point in a target area, and the target air pressure data includes grid point air pressure values of the respective grid points;
[0012] A processing unit, configured to determine at least one target isobar based on the target air pressure data; and determine a target isobar image based on each target isobar in the at least one target isobar, where the target isobar image includes mapped isobars of the respective target isobars;
[0013] The processing unit is further configured to generate a target wind field image based on the target wind field data, where a wind field image is used to indicate the magnitude of each wind field in the corresponding wind field data; and generate a target image to be detected based on the target isobar image and the target wind field image;
[0014] The processing unit is further configured to call a target detection model to perform saddle-shaped field area detection on the target image to be detected, obtain at least one data indicating a region to be segmented of the target image to be detected, and determine a corresponding image to be segmented corresponding to each data indicating a region to be segmented based on each data indicating a region to be segmented in the at least one data indicating a region to be segmented;
[0015] The processing unit is further configured to call a target segmentation model to perform saddle-shaped field area segmentation on the image to be segmented corresponding to each data indicating a region to be segmented, and obtain data indicating a saddle-shaped field area corresponding to each data indicating a region to be segmented.
[0016] According to another aspect of the embodiments of the present invention, there is provided an electronic device, the electronic device comprising a processor and a memory storing a program, wherein the program includes instructions that, when executed by the processor, cause the processor to execute the method mentioned above.
[0017] According to another aspect of the embodiments of the present invention, there is provided a computer program product, including a computer program, wherein the computer program, when executed by a processor, is used to cause a computer to execute the method mentioned above.
[0018] In an embodiment of the present invention, after obtaining target wind field data and target air pressure data, at least one target isobar can be determined based on the target air pressure data; and based on each target isobar in the at least one target isobar, a target isobar image can be determined. The target wind field data includes grid wind field information of each grid point in the target area, the target air pressure data includes grid air pressure values of each grid point, and the target isobar image includes mapped isobars of each target isobar. Correspondingly, a target wind field image can be generated based on the target wind field data, and a wind field image is used to indicate the magnitude of each wind field in the corresponding wind field data; and a target image to be detected can be generated based on the target isobar image and the target wind field image. Further, a target detection model can be called to perform saddle field area detection on the target image to be detected, obtaining at least one data indicating a region to be segmented of the target image to be detected, and respectively determining a corresponding image to be segmented for each data indicating a region to be segmented based on each data indicating a region to be segmented in the at least one data indicating a region to be segmented; based on this, a target segmentation model can be called to perform saddle field area segmentation on each corresponding image to be segmented for each data indicating a region to be segmented, obtaining data indicating a saddle field area corresponding to each data indicating a region to be segmented. It can be seen that the embodiment of the present invention can obtain at least one data indicating a saddle field area (i.e., data indicating a saddle field area corresponding to each data indicating a region to be segmented) under the weather indicated by the target wind field data and the target air pressure data through the target image to be detected, the target detection model, and the target segmentation model, so as to realize the identification of the saddle field area; based on this, the embodiment of the present invention can conveniently perform saddle field area identification, improve the identification efficiency of the saddle field area, and effectively save labor costs. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] In the following description of exemplary embodiments with reference to the accompanying drawings, more details, features, and advantages of the present invention are disclosed. In the drawings:
[0020] Figure 1 FIG. shows a schematic flow chart of a method for identifying a saddle field area according to an exemplary embodiment of the present invention;
[0021] Figure 2 FIG. shows a schematic diagram of a target isobar image according to an exemplary embodiment of the present invention;
[0022] Figure 3 FIG. shows a schematic diagram of a target wind field image according to an exemplary embodiment of the present invention;
[0023] Figure 4 FIG. shows a schematic diagram of an air pressure grid image according to an exemplary embodiment of the present invention;
[0024] Figure 5 FIG. shows a schematic diagram of a target image to be detected according to an exemplary embodiment of the present invention;
[0025] Figure 6 Shows a schematic diagram of a target segmentation characterization image according to an exemplary embodiment of the present invention;
[0026] Figure 7 Shows a schematic flowchart of another saddle field region recognition method according to an exemplary embodiment of the present invention;
[0027] Figure 8 Shows a schematic diagram of detecting a training label according to an exemplary embodiment of the present invention;
[0028] Figure 9 Shows a schematic diagram of a segmentation label according to an exemplary embodiment of the present invention;
[0029] Figure 10 Shows a schematic block diagram of a saddle field region recognition device according to an exemplary embodiment of the present invention;
[0030] Figure 11 Shows a structural block diagram of an exemplary electronic device that can be used to implement the embodiments of the present invention. Detailed implementation manners
[0031] The embodiments of the present invention will be described in more detail below with reference to the accompanying drawings. Although some embodiments of the present invention are shown in the drawings, it should be understood that the present invention can be implemented in various forms and should not be construed as limited to the embodiments set forth herein. On the contrary, these embodiments are provided to more thoroughly and completely understand the present invention. It should be understood that the drawings and embodiments of the present invention are only for exemplary purposes and are not used to limit the protection scope of the present invention.
[0032] It should be understood that the various steps recorded in the method embodiments of the present invention can be executed in different orders and / or in parallel. In addition, the method embodiments may include additional steps and / or omit the steps shown. The scope of the present invention is not limited in this regard.
[0033] The term "including" and its variants used herein are open-ended, that is, "including but not limited to". The term "based on" is "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". The relevant definitions of other terms will be given in the following description. It should be noted that the concepts such as "first" and "second" mentioned in the present invention are only used to distinguish different devices, modules or units, and are not used to limit the order or interdependence relationship of the functions performed by these devices, modules or units.
[0034] It should be noted that the modifications of "one" and "multiple" mentioned in the present invention are illustrative rather than restrictive. Those skilled in the art should understand that, unless otherwise clearly specified in the context, it should be understood as "one or more".
[0035] The names of the messages or information exchanged between multiple devices in the embodiments of the present invention are only for illustrative purposes, and are not used to limit the scope of these messages or information.
[0036] It should be noted that the execution subject of the saddle-shaped field area recognition method provided in the embodiments of the present invention can be one or more electronic devices, and the present invention does not make any limitations in this regard; among them, the electronic device can be a terminal (i.e., a client) or a server. Then, when the execution subject includes multiple electronic devices, and at least one terminal and at least one server are included in the multiple electronic devices, the saddle-shaped field area recognition method provided in the embodiments of the present invention can be jointly executed by the terminal and the server. Correspondingly, the terminal mentioned here may include, but is not limited to: smart phones, laptop computers, desktop computers, and so on. The server mentioned here can be an independent physical server, or 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, and big data and artificial intelligence platforms, and so on.
[0037] Based on the above description, the embodiments of the present invention propose a saddle-shaped field area recognition method, which can be executed by the above-mentioned electronic devices (terminals or servers); or, the saddle-shaped field area recognition method can be jointly executed by the terminal and the server. For the sake of convenience of description, in the following, the case where the electronic device executes the saddle-shaped field area recognition method will be taken as an example for illustration; as Figure 1 shown, the saddle-shaped field area recognition method may include the following steps S101-S105:
[0038] S101, obtain target wind field data and target air pressure data, where the target wind field data includes the grid point wind field information of each grid point in the target area, and the target air pressure data includes the grid point air pressure values of each grid point.
[0039] Optionally, the target wind field data may be the wind field data of the target area at the target monitoring moment, and the target air pressure data may be the air pressure data of the target area at the target monitoring moment; correspondingly, the target wind field data including the grid wind field information of each grid point in the target area may mean that the target wind field data includes the grid wind field information of each grid point in the target area at the target monitoring moment, and the target air pressure data including the grid air pressure value of each grid point may mean that the target air pressure data includes the grid air pressure value of each grid point in the target area at the target monitoring moment. Optionally, the target area may be any area, and the target monitoring moment may be any monitoring moment, which is not limited in the embodiments of the present invention.
[0040] Optionally, the grid wind field information of a grid point may include, but is not limited to: the grid wind field direction of the corresponding grid point, the grid wind field intensity (also referred to as the wind field magnitude), and the grid coordinates, etc.; optionally, the target air pressure data may include the grid air pressure information of each grid point, and the grid air pressure information of a grid point may include, but is not limited to, the grid coordinates and the grid air pressure value of the corresponding grid point, etc. (that is, the target air pressure data may include the grid air pressure value and the grid coordinates of each grid point, etc.). Optionally, a grid coordinate may be the coordinate of the corresponding grid point in the geographic coordinate system, that is, a grid coordinate may include the longitude and latitude of the corresponding grid point; or, a grid coordinate may also be the coordinate of the corresponding grid point in the pixel coordinate system, that is, a grid coordinate may include the abscissa and ordinate of the corresponding grid point, and so on. Optionally, the target air pressure data and the target wind field data may be the data at the ground of the target area.
[0041] Optionally, the acquisition methods of the target air pressure data and the target wind field data may include, but are not limited to, the following several types:
[0042] The first acquisition method: The storage space of the electronic device may store the data sets to be recognized for each area in multiple areas. The data set to be recognized for an area may include the data to be recognized at each monitoring moment in at least one monitoring moment in the corresponding area. A data to be recognized may include the wind field data and the air pressure data of an area at a monitoring moment, and multiple areas include the target area, and the data set to be recognized for the target area includes the data to be recognized for the target area at the target monitoring moment; in this case, the target wind field data and the target air pressure data may be determined from the data sets to be recognized for each area, so as to acquire the target wind field data and the target air pressure data.
[0043] The second acquisition method: The electronic device can obtain the air pressure data download link and use the air pressure data downloaded based on the air pressure data download link as the target air pressure data; correspondingly, it can obtain the wind field data download link and use the wind field data downloaded based on the wind field data download link as the target wind field data. Alternatively, it can also obtain the data to be recognized download link and use the wind field data in the data to be recognized downloaded based on the data to be recognized download link as the target wind field data, and use the air pressure data in the downloaded data to be recognized as the target air pressure data.
[0044] The third acquisition method: The electronic device can obtain the original wind field data and the original air pressure data. The original wind field data can include the wind field monitoring data of each monitoring site among multiple monitoring sites, and the original air pressure data can include the air pressure monitoring data of each monitoring site. One wind field monitoring data can be used to indicate the wind field direction and wind field intensity of the corresponding monitoring site, and one air pressure monitoring data can be used to indicate the air pressure value of the corresponding monitoring site. The multiple monitoring sites can be the monitoring sites in the target area; based on this, the target wind field data can be generated based on the wind field monitoring data of each monitoring site, and the target air pressure data can be generated based on the air pressure monitoring data of each monitoring site, so as to achieve the acquisition of the target wind field data and the target air pressure data, and so on.
[0045] Optionally, when generating target wind field data based on the wind field monitoring data of each monitoring site, the grid spacing at the corresponding regional scale of the target area can be determined, and the target area can be divided into grids according to the grid spacing to determine each grid point among the multiple grid points in the target area (i.e., the grid coordinates of each grid point can be determined). Based on the wind field monitoring data of each monitoring site, the grid wind field direction and grid wind field intensity of each grid point can be determined to generate the target wind field data. Optionally, for any grid point in the target area, the electronic device can determine the top P monitoring sites with the closest distance to the grid point from multiple monitoring sites, and through the inverse distance weight interpolation method (Inverse Distance Weight, IDW), based on the wind field monitoring data of each of the determined P monitoring sites, determine the grid wind field direction and grid wind field intensity of the grid point (such as weighted summing the wind field intensities of each of the determined P monitoring sites based on the wind field direction of each of the determined P monitoring sites), where P is an integer greater than 1; or the wind field direction and wind field intensity of the monitoring site closest to the grid point can be used as the grid wind field direction and grid wind field intensity of the grid point, etc. Optionally, the grid spacing can be set according to experience or actual requirements, and the embodiments of the present invention do not limit this. For example, taking the grid coordinates as the coordinates of the corresponding grid point in the geographic coordinate system as an example, the grid interval can include the longitude interval and the latitude interval; assuming that both the longitude interval and the latitude interval are 0.5, and the longitude range of the target area is 60 - 150, and the latitude range is 10 - 60, then the data height (i.e., the number of rows, also known as the longitudinal number of grid points) can be (60 - 10) / 0.5 + 1 = 101, and the data width (i.e., the number of columns, also known as the horizontal number of grid points) can be (150 - 60) / 0.5 + 1 = 181, etc.
[0046] Optionally, when generating target air pressure data based on the air pressure monitoring data of each monitoring site, the grid air pressure value of each grid point can be determined based on the air pressure monitoring data of each monitoring site to generate the target air pressure data. Optionally, for any grid point in the target area, the top Q monitoring sites with the closest distance to the grid point can be determined from multiple monitoring sites, and the air pressure values of each of the determined Q monitoring sites can be weighted and summed through the inverse distance weight interpolation method to obtain the grid air pressure value of the grid point, where Q is an integer greater than 1; or the air pressure value of the monitoring site closest to the grid point can be used as the grid air pressure value of the grid point, etc.
[0047] In summary, whether it is grid data or site data, it is possible to obtain target air pressure data and target wind field data to achieve saddle-shaped field area recognition, making the saddle-shaped field area recognition method mentioned in the embodiments of the present invention have a wide range of applications.
[0048] S102. Based on the target air pressure data, determine at least one target isobar; and based on each target isobar among the at least one target isobars, determine a target isobar image, where the target isobar image includes the mapped isobars of each target isobar.
[0049] Optionally, when determining at least one target isobar based on the target air pressure data, the electronic device may use an isoline drawing algorithm (which may also be referred to as an isoline tracing algorithm or an isobar drawing algorithm) to draw at least one target isobar based on the target air pressure data, so as to determine at least one target isobar. Among them, one isobar may include multiple isobaric points, that is, one isobar may be a sequence of isobaric points. That is to say, one isobar may include the isobaric point data of each isobaric point in the corresponding isobar. An isobaric point data may include the isobaric point air pressure value and the isobaric point coordinates of the corresponding isobaric point. The isobaric point air pressure values of each isobaric point in one isobar are the same; among them, when an isobaric point is a grid point, the isobaric point air pressure value of the isobaric point is equal to the grid point air pressure value of the grid point, and the isobaric point coordinates of the isobaric point are equal to the grid point coordinates of the grid point.
[0050] Optionally, the air pressure value of an isobar (the isobaric point air pressure value of each isobaric point in one isobar is the air pressure value of the corresponding isobar) can be divisible by a preset air pressure value; optionally, the preset air pressure value can be set according to experience or actual needs, and the embodiments of the present invention do not limit this.
[0051] Optionally, when determining a target isobar image based on each target isobar among the at least one target isobars, the electronic device may map each target isobar among the at least one target isobars respectively to determine the target isobar image, that is, each target isobar can be mapped into the target isobar image respectively. Optionally, the electronic device may initialize the target isobar image so that the resolution of the target isobar image is the preset resolution, and the pixel values of each pixel point in the target isobar image can be initialized to the initial isobar map pixel value; based on this, each target isobar among the at least one target isobars can be traversed, and the currently traversed target isobar is used as the current target isobar; then, based on the isobaric point coordinates of each isobaric point in the current target isobar respectively, the mapped pixel points of each isobaric point in the current target isobar in the target isobar image can be determined. Optionally, both the preset resolution and the initial isobar map pixel value can be set according to experience or actual needs, and the embodiments of the present invention do not limit this; exemplarily, the preset resolution may be 1000×1000, and the initial isobar map pixel value may be 255. That is, the initialized target isobar image may be a two-dimensional matrix with a resolution of the preset resolution and single-channel pixel values all being the initial isobar map pixel value.
[0052] In one embodiment, when the isobaric point coordinates of an isobaric point include the longitude and latitude of the corresponding isobaric point, at least one target isobar can be an isobar in a geographic coordinate system; in this case, the minimum latitude in a region (such as the target region) can correspond to the bottom of an image (such as the target isobar image), the maximum latitude in a region can correspond to the top of an image, the maximum longitude of a region can correspond to the right part of an image, and the minimum longitude of a region can correspond to the left part of an image, so as to achieve mapping (also known as linear mapping). Based on this, for any isobaric point in the current target isobar, the mapped abscissa of any isobaric point can be calculated based on the longitude of any isobaric point, the minimum longitude in the target region, the maximum longitude in the target region, and the maximum abscissa in the target isobar image (i.e., the maximum abscissa of the preset resolution), and the mapped ordinate of any isobaric point can be calculated based on the latitude of any isobaric point, the minimum latitude in the target region, the maximum latitude in the target region, and the maximum ordinate in the target isobar image (i.e., the maximum ordinate of the preset resolution), so as to determine the mapped pixel point of any isobaric point in the target isobar image based on the mapped abscissa and mapped ordinate of any isobaric point, to determine the position where the current target isobar is located (i.e., to determine the mapped pixel points of each isobaric point in the current target isobar in the target isobar image); optionally, the pixel point in the target isobar image that is closest to the mapped abscissa and mapped ordinate of any isobaric point can be used as the mapped pixel point of any isobaric point in the target isobar image, or rounding operations can be performed on the mapped abscissa and mapped ordinate of any isobaric point to use the pixel point indicated by the rounded mapped abscissa and rounded mapped ordinate of any isobaric point as the mapped pixel point of any isobaric point in the target isobar image, and so on. Exemplarily, assuming that the preset resolution is 1000×1000, the mapped abscissa of any isobaric point can be: (longitude of any isobaric point - minimum longitude in the target region) × 1000 / (maximum longitude in the target region - minimum longitude in the target region), and the mapped ordinate of any isobaric point can be: 1000 - (latitude of any isobaric point - minimum latitude in the target region) × 1000 / (maximum latitude in the target region - minimum latitude in the target region), and so on.
[0053] In another implementation, when the isobaric point coordinates of an isobaric point include the abscissa and ordinate of the corresponding isobaric point, at least one target isobar can be an isobar in the pixel coordinate system; in this case, the maximum ordinate in a region can correspond to the bottom of an image, the minimum ordinate in a region can correspond to the top of an image, the maximum abscissa in a region can correspond to the right part of an image, and the minimum abscissa in a region can correspond to the left part of an image, so as to achieve mapping. Based on this, for any isobaric point in the current target isobar, the mapped abscissa of any isobaric point can be calculated based on the abscissa of any isobaric point, the minimum abscissa in the target region, the maximum abscissa in the target region, and the maximum abscissa in the target isobar image, and the mapped ordinate of any isobaric point can be calculated based on the ordinate of any isobaric point, the minimum ordinate in the target region, the maximum ordinate in the target region, and the maximum ordinate in the target isobar image, so as to determine the mapped pixel point of any isobaric point in the target isobar image based on the mapped abscissa and mapped ordinate of any isobaric point, so as to determine the location of the current target isobar in the target isobar image, and so on.
[0054] Correspondingly, the air pressure value of the current target isobar can be determined, and the maximum isobar air pressure value (i.e., the maximum value among the air pressure values of each target isobar) and the minimum isobar air pressure value (i.e., the minimum value among the air pressure values of each target isobar) can be determined from at least one target isobar, so as to calculate the mapped air pressure value of each isobaric point in the current target isobar (which can also be called the pixel value of the location where the current target isobar is located in the target isobar image) based on the air pressure value of the current target isobar, the maximum isobar air pressure value, and the minimum isobar air pressure value, and the mapped air pressure value of each isobaric point in the current target isobar can be used as the pixel value of the mapped pixel point of each isobaric point in the current target isobar in the target isobar image (the mapped pixel point of a point in an image can also be called the mapped pixel point of the corresponding point in the corresponding image), so as to update the target isobar image through the pixel value of the location where the current target isobar is located in the target isobar image. It can be seen that the embodiments of the present invention can map at least one target isobar to the target isobar image in an equal proportion manner.
[0055] Optionally, the electronic device can use Equation 1.1 to calculate the pixel value of the location where the current target isobar is located in the target isobar image (i.e., calculate the mapped air pressure value of each isobaric point in the current target isobar):
[0056] Equation 1.1
[0057] Among them, press_value1 can represent the pixel value of the position where the current target isobar line is located in the target isobar line image, press_value can represent the air pressure value of the current target isobar line, press_min can represent the minimum air pressure value of the isobar line, and press_max can represent the maximum air pressure value of the isobar line.
[0058] Based on this, the current target isobar line can be mapped to the target isobar line image according to the mapped pixel points of each isobar point in the current target isobar line in the target isobar line image and the pixel value of the position where the current target isobar line is located in the target isobar line image, so that the pixel value of the mapped pixel point of each isobar point in the current target isobar line in the target isobar line image is the pixel value of the position where the current target isobar line is located in the target isobar line image, so that the target isobar line image includes the mapped isobar line of the current target isobar line.
[0059] Furthermore, after traversing each target isobar line in at least one target isobar line, it is possible to map each target isobar line to the target isobar line image, so that the target isobar line image includes the mapped isobar lines of each target isobar line, that is, the pixel value of the mapped pixel point of each isobar point in any target isobar line in the target isobar line image is the pixel value of the position where any target isobar line is located in the target isobar line image, as Figure 2 shown.
[0060] S103. Based on the target wind field data, generate a target wind field image, and a wind field image is used to indicate the magnitude of each wind field in the corresponding wind field data; and based on the target isobar line image and the target wind field image, generate a target image to be detected.
[0061] In the embodiment of the present invention, the grid point wind field information of a grid point may include the grid point wind field direction and the grid point wind field intensity of the corresponding grid point. Optionally, when generating the target wind field image based on the target wind field data, for any grid point in the target area, the electronic device may determine the wind field arrow length of any grid point based on the grid point wind field intensity of any grid point; and after obtaining the wind field arrow lengths of each grid point, generate a target wind field image based on the wind field arrow lengths of each grid point and the grid point wind field direction. The target wind field image may include wind field representation arrows on the mapped pixel points of each grid point, as Figure 3As shown; in other words, wind field representation arrows can be generated on the mapped pixel points of each grid point in the target wind field image; optionally, before generating the wind field representation arrows on the mapped pixel points of each grid point, the target wind field image can be initialized to a two-dimensional matrix of single-channel pixels with a preset resolution (i.e., a single-channel image), and at this time, the pixel values of each pixel point in the target wind field image are all the initial pixel values of the wind field image. Optionally, the initial pixel value of the wind field image can be set according to experience or actual requirements, and the embodiments of the present invention do not limit this; exemplarily, the initial pixel value of the wind field image can be 255.
[0062] Optionally, the length of the wind field representation arrow on the mapped pixel point of a grid point can be the wind field arrow length of the corresponding grid point. At this time, the wind field arrow length of a grid point can be calculated for the pixel coordinate system. Then, the electronic device can determine the mapped pixel point of any grid point in the target wind field image (i.e., the mapped pixel point of any grid point in the target wind field image), and use the mapped pixel point of any grid point in the target wind field image as the arrow starting point corresponding to any grid point. And based on the arrow starting point, the wind field arrow length of any grid point, and the grid point wind field direction, determine the arrow ending point corresponding to any grid point, so as to generate the wind field representation arrow on the mapped pixel point of any grid point in the target wind field image according to the arrow starting point and arrow ending point corresponding to any grid point; or, the wind field arrow length of a grid point can be calculated for the geographic coordinate system. Then, based on the grid point coordinates, the wind field arrow length, and the grid point wind field direction of any grid point, determine the longitude and latitude coordinate ending point of any grid point (at this time, the distance between the grid point coordinates and the longitude and latitude coordinate ending point of any grid point is equal to the wind field arrow length of any grid point), and map the grid point coordinates and the longitude and latitude coordinate ending point of any grid point respectively to obtain the mapped pixel point of any grid point in the target wind field image and the mapped pixel point of the longitude and latitude coordinate ending point of any grid point in the target wind field image. Thus, use the mapped pixel point of any grid point in the target wind field image as the arrow starting point corresponding to any grid point, and use the mapped pixel point of the longitude and latitude coordinate ending point of any grid point in the target wind field image as the arrow ending point corresponding to any grid point, so as to generate the wind field representation arrow on the mapped pixel point of any grid point in the target wind field image according to the arrow starting point and arrow ending point corresponding to any grid point, and so on. It should be noted that the mapping method of a grid point or the longitude and latitude coordinate ending point of a grid point can refer to the above mapping method of the isobaric point, and the embodiments of the present invention will not elaborate here.
[0063] Optionally, when generating a wind field representation arrow on the mapped pixel point of any grid point in the target wind field image according to the arrow start point and arrow end point corresponding to any grid point, the first arrow setting data corresponding to any grid point can also be determined, and a wind field representation arrow on the mapped pixel point of any grid point is generated in the target wind field image according to the arrow start point, arrow end point and the first arrow setting data corresponding to any grid point; optionally, the first arrow setting data corresponding to any grid point may include at least one of the following: the first arrow pixel value corresponding to any grid point (which can be used to indicate the arrow color), the first arrow head shape, the first arrow tail shape, the first arrow width, etc. Optionally, any data in the first arrow setting data can be set according to experience or actual requirements (in this case, any data corresponding to each grid point can be the same, for example, the first arrow pixel value corresponding to each grid point can be 0), and can also be calculated according to the corresponding calculation method (in this case, any data corresponding to different grid points can be different), etc.; exemplarily, the first arrow width corresponding to any grid point can be positively correlated with the wind field arrow length of any grid point, that is, it can be positively correlated with the grid point wind field intensity of any grid point.
[0064] In one implementation, when determining the wind field arrow length of any grid point based on the grid point wind field intensity of any grid point, a preset arrow length threshold can be determined, and the maximum grid point wind field intensity (that is, the maximum value among the grid point wind field intensities of each grid point) and the minimum grid point wind field intensity (that is, the minimum value among the grid point wind field intensities of each grid point) can be determined from the target wind field data; and based on the preset arrow length threshold, the maximum grid point wind field intensity, the minimum grid point wind field intensity and the grid point wind field intensity of any grid point, the wind field arrow length of any grid point is calculated. For example, the wind field arrow length of any grid point can be: (the grid point wind field intensity of any grid point - the minimum grid point wind field intensity) × the preset arrow length threshold / (the maximum grid point wind field intensity - the minimum grid point wind field intensity). In another implementation, the wind field intensity intervals corresponding to each wind field arrow length among multiple wind field arrow lengths can be determined; based on this, the wind field arrow length corresponding to the wind field intensity interval to which the grid point wind field intensity of any grid point belongs can be used as the wind field arrow length of any grid point, etc. Optionally, the preset arrow length threshold, the multiple wind field arrow lengths and the wind field intensity intervals corresponding to each wind field arrow length can be set according to experience or actual requirements, and the embodiments of the present invention do not limit this.
[0065] Further, when generating the target image to be detected based on the target isobar image and the target wind field image, the electronic device may also generate a target air pressure image based on the target air pressure data, and generate the target image to be detected based on the target isobar image, the target wind field image, and the target air pressure image; specifically, the target isobar image, the target wind field image, and the target air pressure image may be stitched to obtain the target image to be detected, and the target image to be detected is a three-channel image, so that these three single-channel images respectively occupy the three channels of the RGB (RGB color mode) of the three-channel image; it should be noted that the embodiments of the present invention do not limit the arrangement order of each image in the stitching process, that is, a single-channel image may occupy any channel of the three-channel image.
[0066] In a specific implementation, the electronic device may map the target air pressure data to obtain a grid air pressure mapping image, and the pixel value of the mapped pixel point of a grid in the grid air pressure mapping image may be determined based on the grid air pressure value of the corresponding grid; and the mapped pixel points of each grid in the grid air pressure mapping image are respectively expanded outward at the same speed until the grids expanded by the mapped pixel points of each grid in the grid air pressure mapping image contact each other, so as to obtain the air pressure grid image corresponding to the grid air pressure mapping image, and the air pressure grid image may include the grids expanded by the mapped pixel points of each grid in the grid air pressure mapping image, as Figure 4 shown; wherein, the color of a grid is the color indicated by the pixel value of the corresponding mapped pixel point (that is, the mapped pixel point of the grid in the corresponding grid), that is to say, a grid may include the mapped pixel point of a grid, and the pixel values of all pixel points in a grid are the pixel values of the mapped pixel point of the grid in the corresponding grid. Based on this, the target isobar image, the target wind field image, and the air pressure grid image may be stitched to obtain the target image to be detected, and the target image to be detected is a three-channel image, as Figure 5 shown; that is to say, the air pressure grid image may be used as the target air pressure image to implement the above-mentioned generation of the target air pressure image based on the target air pressure data, and the generation of the target image to be detected based on the target isobar image, the target wind field image, and the target air pressure image. It can be seen that the embodiments of the present invention may be centered on the mapped pixel point of each grid, and expand outward in a rectangular manner according to the pixel value of the mapped pixel point of each grid in the grid air pressure mapping image until they contact each other; based on this, the embodiments of the present invention may make the pixel value characteristics of the mapped pixel points of each grid more obvious by expanding the mapped pixel points, that is, make the grid air pressure values of each grid more prominent in the image, so as to improve the accuracy of the target image to be detected.
[0067] Optionally, the pixel values of the pixels in the grid point pressure mapping image other than the mapped pixel points of each grid point may all be the initial pixel values of the grid point pressure image; optionally, the initial pixel values of the grid point pressure image may be set according to experience or actual requirements, and the embodiments of the present invention do not limit this; optionally, the resolution of the grid point pressure mapping image may be a preset resolution. Optionally, when mapping the target pressure data to obtain the grid point pressure mapping image, for any grid point in the target area, the electronic device may determine the mapped pixel point of the grid point in the grid point pressure mapping image, and calculate the mapped pressure value of the grid point based on the grid point pressure value of the grid point, the maximum grid point pressure value in the target pressure data, and the minimum grid point pressure value in the target pressure data, and use the mapped pressure value of the grid point as the pixel value of the mapped pixel point of the grid point in the grid point pressure mapping image (i.e., the pixel value of the mapped pixel point of any grid point in the grid point pressure mapping image can be calculated), so as to obtain the grid point pressure mapping image based on the pixel values of the mapped pixel points of each grid point in the grid point pressure mapping image. Optionally, the electronic device may use Formula 1.2 to calculate the mapped pressure value of any grid point:
[0068] Formula 1.2
[0069] wherein, latt_press1 may represent the mapped pressure value of any grid point, latt_press may represent the grid point pressure value of any grid point, latt_press_min may represent the maximum grid point pressure value in the target pressure data, and latt_press_max may represent the minimum grid point pressure value in the target pressure data.
[0070] In another specific implementation, the electronic device may also use the grid point pressure mapping image as the target pressure image to implement generating the target pressure image based on the target pressure data, and generating the target image to be detected based on the target isobar image, the target wind field image, and the target pressure image, and so on.
[0071] S104, call the target detection model to perform saddle field area detection on the target image to be detected, obtain at least one segmentation area indication data of the target image to be detected, and respectively determine the corresponding segmentation image corresponding to the corresponding segmentation area indication data based on each segmentation area indication data in the at least one segmentation area indication data.
[0072] Optionally, a segmentation area indication data may include the area information (also referred to as area position information) of a segmentation area. The area position of a segmentation area may include the area coordinates (such as diagonal point coordinates) of the corresponding segmentation area, or may include the lower left corner point coordinates, length, and width of the corresponding segmentation area, etc.
[0073] In one embodiment, the electronic device may further determine an initial segmentation representation image based on each target isobar. An isobar includes a plurality of isobaric points. The pixel value of the mapped pixel point of each isobaric point in each target isobar in the initial segmentation representation image is the first pixel value, and the pixel values of all pixel points in the initial segmentation representation image except the mapped pixel points of each isobaric point in each target isobar are the second pixel value. Then, based on the target wind field data and the initial segmentation representation image, a target segmentation representation image is determined, so that the target wind field data and each target isobar can be mapped into the target segmentation representation image. The pixel value of the mapped pixel point of each grid point in the target segmentation representation image is the third pixel value (which can also be called the second arrow pixel value), and the target segmentation representation image may include wind field representation arrows on the mapped pixel points of each grid point. That is to say, based on the target wind field data, wind field representation arrows can be generated on the mapped pixel points of each grid point in the target segmentation representation image, and the target segmentation representation image may include the mapping results of each target isobar, as Figure 6 shown. It should be understood that the pixel value of a pixel point in the target segmentation representation image except the wind field representation arrow on the mapped pixel point of each grid point is the pixel value of the corresponding pixel point in the initial segmentation representation image, and the color of the wind field representation arrow on the mapped pixel point of each grid point in the target segmentation representation image may be the color indicated by the third pixel value. Optionally, the first pixel value, the second pixel value, and the third pixel value can all be set according to experience or actual needs, and the embodiments of the present invention do not limit this. For example, the first pixel value may be (0, 0, 0), the second pixel value may be (255, 255, 255), and the third pixel value may be (0, 0, 255). It should be noted that the specific implementation manner of generating wind field representation arrows on the mapped pixel points of each grid point in the target segmentation representation image can refer to the above-mentioned implementation manner of generating wind field representation arrows on the mapped pixel points of each grid point in the target wind field image, and the embodiments of the present invention will not elaborate here. Among them, the wind field representation arrows on the mapped pixel points of each grid point in the target segmentation representation image can be generated based on the second arrow setting data. Any data in the second arrow setting data can be the same as or different from any data in the first arrow setting data, and the embodiments of the present invention do not limit this.
[0074] Based on this, when determining the corresponding segmented image for each region-to-be-segmented indication data in at least one region-to-be-segmented indication data respectively, the electronic device can respectively crop the corresponding segmented image for each region-to-be-segmented indication data from the target segmentation representation image based on each region-to-be-segmented indication data in at least one region-to-be-segmented indication data, so as to determine the segmented image corresponding to each region-to-be-segmented indication data. In other words, for any region-to-be-segmented indication data in at least one region-to-be-segmented indication data, the corresponding segmented image for any region-to-be-segmented indication data can be cropped from the target segmentation representation image according to any region-to-be-segmented indication data. The segmented image corresponding to one region-to-be-segmented indication data can include the region-to-be-segmented indicated by the corresponding region-to-be-segmented indication data. Optionally, one segmented image can include one saddle field region. Optionally, the resolution of the target segmentation representation image is the same as the resolution of the target image to be detected. It should be understood that the target segmentation representation image can more prominently represent the target wind field data and at least one target isobar, that is, the representation of the wind field and the isobar can be made clearer, so that the segmented images corresponding to each region-to-be-segmented indication data obtained from the target segmentation representation image can more accurately reflect the wind field characteristics and isobar characteristics, so as to improve the recognition accuracy of the subsequent saddle field region.
[0075] In another implementation, the pixel value of the mapped pixel point of any isobar point in each target isobar in the initial segmentation representation image can also be determined based on the isobar pressure value of any isobar point, that is, the initial segmentation representation image can be a target isobar image (that is, the determination method of the initial segmentation representation image can be the same as the determination method of the target isobar image), so as to determine the target segmentation representation image, and then crop the corresponding segmented image for each region-to-be-segmented indication data from the target segmentation representation image. In yet another implementation, the electronic device can respectively crop the corresponding segmented image for each region-to-be-segmented indication data from the target image to be detected, that is to say, the corresponding segmented image for any region-to-be-segmented indication data can be cropped from the target image to be detected according to any region-to-be-segmented indication data, so as to determine the segmented image corresponding to each region-to-be-segmented indication data, and so on.
[0076] S105, call the target segmentation model to respectively perform saddle field region segmentation on the segmented images corresponding to each region-to-be-segmented indication data, and obtain the saddle field region indication data corresponding to each region-to-be-segmented indication data.
[0077] In an embodiment of the present invention, for any one of the at least one region-to-be-segmented indication data, the electronic device may call a target segmentation model to perform saddle field region segmentation on the image to be segmented corresponding to any one of the region-to-be-segmented indication data, so as to obtain saddle field region indication data corresponding to any one of the region-to-be-segmented indication data.
[0078] Among them, one saddle field region indication data can be used to indicate one saddle field region. Optionally, one saddle field region indication data may include the pixel prediction category (also referred to as pixel category) of each pixel point in the corresponding image to be segmented (i.e., the image to be segmented corresponding to the corresponding region-to-be-segmented indication data). The pixel prediction category of a pixel point can be used to indicate whether the corresponding pixel point is located within the saddle field region of the corresponding segmented image (such as the corresponding image to be segmented or the following segmentation training image), that is, the pixel prediction category of a pixel point can be used to indicate whether the corresponding pixel point is located within the saddle field region. That is to say, a pixel prediction category can be a category located in the saddle field region (used to indicate that the corresponding pixel point is located within the saddle field region) or a category not located in the saddle field region (used to indicate that the corresponding pixel point is not located within the saddle field region); Exemplarily, one saddle field region indication data can be a saddle field region indication image. The pixel points in a saddle field region indication image correspond one-to-one with the pixel points in the corresponding image to be segmented, and the pixel value located in the saddle field region is used to represent the category located in the saddle field region, and the pixel value not located in the saddle field region is used to represent the category not located in the saddle field region. Optionally, one saddle field region indication data may also include the boundary point sequence of the saddle field region in the corresponding image to be segmented. A boundary point sequence may include multiple pixel points in the corresponding image to be segmented. At this time, one saddle field region indication data can be used to indicate that the pixel points located within the boundary point sequence are the pixel points located within the saddle field region, and the pixel points not located within the boundary point sequence are the pixel points not located within the saddle field region, and so on. Optionally, both the pixel value located in the saddle field region and the pixel value not located in the saddle field region can be set according to experience or actual requirements, and the embodiments of the present invention do not limit this; Exemplarily, the pixel value located in the saddle field region can be 255, and the pixel value not located in the saddle field region can be 0, and so on.
[0079] In an embodiment of the present invention, after obtaining target wind field data and target air pressure data, at least one target isobar can be determined based on the target air pressure data; and based on each target isobar in the at least one target isobar, a target isobar image can be determined. The target wind field data includes the grid point wind field information of each grid point in the target area, the target air pressure data includes the grid point air pressure values of each grid point, and the target isobar image includes the mapped isobars of each target isobar. Correspondingly, a target wind field image can be generated based on the target wind field data, and a wind field image is used to indicate the magnitude of each wind field in the corresponding wind field data; and a target image to be detected can be generated based on the target isobar image and the target wind field image. Further, a target detection model can be called to detect the saddle field area of the target image to be detected, and at least one data indicating the area to be segmented of the target image to be detected can be obtained. Based on each data indicating the area to be segmented in the at least one data indicating the area to be segmented, the corresponding image to be segmented corresponding to the data indicating the area to be segmented can be determined; based on this, a target segmentation model can be called to segment the saddle field area of each image to be segmented corresponding to the data indicating the area to be segmented, and the data indicating the saddle field area corresponding to the corresponding data indicating the area to be segmented can be obtained. It can be seen that the embodiment of the present invention can obtain at least one data indicating the saddle field area (i.e., the data indicating the saddle field area corresponding to each data indicating the area to be segmented) under the weather indicated by the target wind field data and the target air pressure data through the target image to be detected, the target detection model, and the target segmentation model, etc., so as to realize the recognition of the saddle field area; based on this, the embodiment of the present invention can conveniently perform the recognition of the saddle field area, improve the recognition efficiency of the saddle field area, and effectively save labor costs.
[0080] Based on the above description, an embodiment of the present invention further proposes a more specific method for identifying a saddle field area. Correspondingly, the method for identifying a saddle field area can be executed by the above-mentioned electronic device (terminal or server); or, the method for identifying a saddle field area can be jointly executed by the terminal and the server. For the convenience of description, in the following, it is taken as an example that the electronic device executes the method for identifying a saddle field area; please refer to Figure 7 , and the method for identifying a saddle field area may include the following steps S701-S710:
[0081] S701, obtain a plurality of detection training data, and obtain the detection training labels corresponding to each detection training data in the plurality of detection training data. One detection training data includes the training wind field data and training air pressure data of a training area at a monitoring moment. One training wind field data includes the grid point wind field information of each training grid point in a training area, and one training air pressure data includes the grid point air pressure values of each training grid point in a training area.
[0082] Optionally, if multiple detection training data are stored in the internal storage space of the electronic device, the multiple detection training data can be obtained from the internal storage space; alternatively, a detection training data download link can be obtained, and the detection training data downloaded based on the detection training data download link can be used as the multiple detection training data, so as to obtain the multiple detection training data, and so on.
[0083] Optionally, a detection training label may include, but is not limited to, the region information and region category labels of each annotation region in at least one annotation region corresponding to the corresponding detection training data, and so on. Optionally, the region information of an annotation region may include the region coordinates of the corresponding annotation region, and may also include the coordinates of the lower left corner point, length, and width of the corresponding annotation region, and so on. Optionally, the region category label of an annotation region may be a saddle field region category, and the saddle field region category can be used to indicate a region including a saddle field region.
[0084] In one implementation, the detection training labels corresponding to the respective detection training data may be stored in the internal storage space of the electronic device, and then the detection training labels corresponding to the respective detection training data can be obtained from the internal storage space. In another implementation, the data downloaded based on the detection training data download link may also include the detection training labels corresponding to the respective training detection data, and at this time, the detection training labels corresponding to the respective detection training data can be obtained from the data downloaded based on the detection training data download link. In still another implementation, for any one of the multiple detection training data, an initial training segmentation representation image corresponding to any one of the detection training data can be generated based on the training air pressure data in any one of the detection training data; and based on the training wind field data and the initial training segmentation representation image in any one of the detection training data, a target training segmentation representation image corresponding to any one of the detection training data can be determined; based on this, the detection training label corresponding to any one of the detection training data can be obtained through the target training segmentation representation image, and so on. Among them, the generation method of the initial training segmentation representation image corresponding to any one of the detection training data is the same as the determination method of the above-mentioned initial segmentation representation image (that is, based on the training air pressure data in any one of the detection training data, at least one isobar corresponding to any one of the detection training data can be determined, and based on each isobar in at least one isobar corresponding to any one of the detection training data, the initial training segmentation representation image corresponding to any one of the detection training data can be determined, so as to generate the initial training segmentation representation image corresponding to any one of the detection training data), which will not be elaborated in the embodiments of the present invention; correspondingly, the determination method of the target training segmentation representation image corresponding to any one of the detection training data is the same as the determination method of the above-mentioned target segmentation representation image, which will not be elaborated in the embodiments of the present invention.
[0085] Optionally, when obtaining the detection training label corresponding to any detection training data by using the target training segmentation representation image, the electronic device may output the target training segmentation representation image corresponding to any detection training data, and when detecting a region box annotation operation performed by a user (such as an annotator) on the target training segmentation representation image corresponding to any detection training data, obtain the detection training label corresponding to any detection training data based on at least one region box (i.e., the annotation region) indicated by the region box annotation operation. In other words, the region information of each annotation region in the detection training label corresponding to any detection training data may be determined based on at least one region box indicated by the region box annotation operation; optionally, the saddle field region category may be used as the region category label of each annotation region in the detection training label corresponding to any detection training data.
[0086] Optionally, the detection training label corresponding to any detection training data may also be an image with at least one region box indicated by the region box annotation operation annotated on the target training segmentation representation image corresponding to any detection training data, that is to say, the detection training label corresponding to any detection training data may be a sample image including at least one annotation region, such as Figure 8 shown, and so on. Based on this, the detection training label corresponding to a detection training data may be used to indicate the region box of each saddle field region corresponding to the corresponding detection training data in the image.
[0087] It should be understood that since the target training segmentation representation image corresponding to any detection training data is relatively intuitive, it is convenient for the user to better identify at least one saddle field region corresponding to any detection training data, so as to more accurately perform the region box annotation operation, and the accuracy of the detection training labels corresponding to each detection training data can be improved.
[0088] S702. Based on each detection training data, determine the image to be detected corresponding to each detection training data.
[0089] In the embodiment of the present invention, for any detection training data among multiple detection training data, the electronic device may determine the image to be detected corresponding to any detection training data based on any detection training data; specifically, based on the training air pressure data in any detection training data, determine at least one isobar corresponding to any detection training data, and based on each isobar in the at least one isobar corresponding to any detection training data, determine the isobar image corresponding to any detection training data, and based on the training wind field data in any detection training data, generate the wind field image corresponding to any detection training data, so as to generate the image to be detected corresponding to any detection training data based on the isobar image and the wind field image corresponding to any detection training data.
[0090] Exemplarily, the electronic device can also map the training barometric pressure data in any detection training data to obtain a training grid barometric pressure mapping image corresponding to any detection training data, and expand the mapped pixel points of each training grid in the training grid barometric pressure mapping image corresponding to any detection training data outward at the same speed until the grids expanded by the mapped pixel points of each training grid in the training grid barometric pressure mapping image corresponding to any detection training data are in contact with each other, so as to obtain a barometric pressure grid image corresponding to any detection training data, and then perform stitching processing on the isobar image, wind field image, and barometric pressure grid image corresponding to any detection training data to obtain a to-be-detected image corresponding to any detection training data, and so on. It should be understood that the determination method of the to-be-detected image corresponding to any detection training data can be the same as the generation method of the target to-be-detected image, and the embodiments of the present invention will not be elaborated herein.
[0091] In other embodiments, for any detection training data among multiple detection training data, the electronic device can also obtain the detection training label corresponding to any detection training data through the to-be-detected image corresponding to any detection training data; that is, the to-be-detected image corresponding to any detection training data can be output, and when it is detected that the user performs a region box annotation operation on the region box of the to-be-detected image corresponding to any detection training data, based on at least one region box indicated by the region box annotation operation, the detection training label corresponding to any detection training data can be obtained, and so on.
[0092] S703, call the initial detection model to respectively perform saddle field region detection on the to-be-detected images corresponding to each detection training data, and obtain at least one detection training region indication data corresponding to the corresponding detection training data.
[0093] Optionally, a detection model can be a model in the YOLO (You Only Look Once, an object recognition and localization algorithm based on deep neural network) series of models, or a model in the SSD (Single Shot MultiBox Detector, an object detection algorithm) series of models, etc. Optionally, a detection model can be used for object detection (also known as object recognition), can identify the objects on the image in the form of rectangular boxes (i.e., region boxes), and can give the categories and locations of the objects. Among them, a detection training area indication data can be used to indicate a detection training area in the to-be-detected image corresponding to the corresponding detection training data. Optionally, a detection training area indication data can include the area information of a detection training area in the to-be-detected image corresponding to the corresponding detection training data; Optionally, the area information of a detection training area can include the area coordinates of the corresponding detection training area, or can also include the coordinates of the lower left corner point, length, and width of the corresponding detection training area, etc. Optionally, a detection training area indication data can also include the saddle field area prediction probability of the corresponding detection training area; A saddle field area prediction probability can be used to indicate the probability value that the corresponding detection training area includes a saddle field area, and / or a saddle field area prediction probability can be used to indicate the probability value that the corresponding detection training area does not include a saddle field area, etc.
[0094] S704. Calculate the detection model loss value of the initial detection model based on at least one detection training area indication data and detection training labels corresponding to each detection training data.
[0095] In one implementation, a detection training area indication data may include the prediction probability and area information of the saddle field area of a detection training area, and a detection training label may include the area information and area category label of each labeled area corresponding to the corresponding detection training data; in this case, for any detection training area indication data corresponding to any detection training data among multiple detection training data, the electronic device may, based on the area information in any detection training area indication data, determine a matching labeled area that matches the detection training area indicated by any detection training area indication data from the detection training label corresponding to any detection training data, and may calculate the probability prediction loss value (such as cross-entropy loss value or exponential loss value, etc.) under any detection training area indication data based on the saddle field area prediction probability and the area category label of the matching labeled area in any detection training area indication data, and perform a summation operation on the probability prediction loss values under each detection training area indication data corresponding to each detection training data to obtain the detection model loss value. Optionally, the electronic device may calculate the matching degree between the detection training area indicated by any detection training area indication data and each labeled area in the detection training label corresponding to any detection training data based on the area information in any detection training area indication data and the area information of each labeled area in the detection training label corresponding to any detection training data, and use the labeled area with the largest matching degree with the detection training area indicated by any detection training area indication data as the matching labeled area; optionally, the matching degree between a detection training area and a labeled area may refer to the overlapping degree between the corresponding detection training area and the corresponding labeled area, or may refer to the reciprocal of the mean absolute error between the area information of the corresponding detection training area and the area information of the corresponding labeled area, and so on.
[0096] Optionally, since the area category labels of the labeled areas may all be the saddle field area category; the electronic device may also not determine the matching labeled area that matches the detection training area indicated by any detection training area indication data, but directly calculate the probability prediction loss value under any detection training area indication data based on the saddle field area prediction probability and the saddle field area category in any detection training area indication data, and so on.
[0097] In another implementation, the electronic device may calculate a first detection loss value based on the region information in each detection training region indication data corresponding to each detection training data and the region information of each labeled region in the detection training label corresponding to each detection training data, and calculate a second detection loss value based on the saddle field region prediction probability in each detection training region indication data corresponding to each detection training data and the region category label of each labeled region in the detection training label corresponding to each detection training data. Then, a weighted sum of the first detection loss value and the second detection loss value is obtained to get the detection model loss value. Optionally, for any detection training region indication data corresponding to any detection training data among multiple detection training data, a region position loss value (such as mean absolute error loss value or mean square error loss value, etc.) under any detection training region indication data may be calculated based on the region information of the detection training region indicated by any detection training region indication data and the region information of the matching labeled region, and a summation operation is performed on the region position loss values under each detection training region indication data corresponding to each detection training data to obtain the first detection loss value. Optionally, a summation operation may be performed on the probability prediction loss values under each detection training region indication data corresponding to each detection training data to obtain the second detection loss value.
[0098] In yet another implementation, the electronic device may determine the number of correctly detected regions based on at least one detection training region indication data and the detection training label corresponding to each detection training data, and calculate the detection recall rate based on the number of correctly detected regions. Then, the reciprocal of the detection recall rate is used as the detection model loss value, and so on. Optionally, the number of correctly detected regions may be the number of detection training regions correctly detected in each detection training region indication data corresponding to each detection training data. Optionally, a correctly detected detection training region may refer to a detection training region whose matching degree with a labeled region in the corresponding detection training label is greater than a preset matching degree threshold, and / or the saddle field region category probability value indicated by the saddle field region prediction probability (i.e., the probability value belonging to the saddle field region category) is greater than a preset probability threshold, and so on. Based on this, the ratio between the number of correctly detected regions and the total number of detection training regions corresponding to each detection training data may be used as the detection recall rate. Optionally, both the preset matching degree threshold and the preset probability threshold may be set according to experience or actual requirements, and the embodiments of the present invention do not limit this.
[0099] S705, Optimize the model parameters in the initial detection model in the direction of reducing the detection model loss value to obtain the initial detection model after model optimization, and determine the target detection model based on the initial detection model after model optimization.
[0100] Optionally, the electronic device can continue to perform model training on the initial detection model after model optimization until the convergence condition is met (such as the number of iterations reaches the preset detection iteration threshold, or the loss value of the detection model in the current iteration is less than the preset detection model loss threshold, etc.) to determine the target detection model (such as using the detection model when the convergence condition is reached as the target detection model). Optionally, both the preset detection iteration threshold and the preset detection model loss threshold can be set according to experience or actual requirements, and the embodiments of the present invention do not limit this.
[0101] Further, the electronic device can also obtain multiple segmentation training images and obtain the segmentation labels of each segmentation training image among the multiple segmentation training images. The segmentation label of a segmentation training image can be used to indicate the pixel points located within the saddle field region in the corresponding segmentation training image and the pixel points not located within the saddle field region in the corresponding segmentation training image. A segmentation training image can include one saddle field region. That is to say, a segmentation label can include the pixel point category labels of each pixel point in the corresponding segmentation training image; and call the initial segmentation model to perform saddle field region segmentation on each segmentation training image respectively to obtain the pixel division result of the corresponding segmentation training image. A pixel division result is used to indicate whether each pixel point in the corresponding segmentation training image is located within the saddle field region. Then correspondingly, based on the pixel division results and segmentation labels of each segmentation training image, the segmentation model loss value of the initial segmentation model can be calculated; thus, the model parameters in the initial segmentation model can be optimized in the direction of reducing the segmentation model loss value to obtain the initial segmentation model after model optimization, and based on the initial segmentation model after model optimization, the target segmentation model can be determined. Optionally, a pixel point category label can be the category of being located within the saddle field region or the category of not being located within the saddle field region. Based on this, the embodiments of the present invention can obtain a target segmentation model with better model performance to improve the accuracy of saddle field region segmentation through the target segmentation model.
[0102] Optionally, multiple segmentation training images may be stored in the internal storage space of the electronic device. In this case, multiple segmentation training images can be obtained from the internal storage space; alternatively, a download link for the segmentation training images can be obtained, and the segmentation training images downloaded based on the download link for the segmentation training images can be used as the multiple segmentation training images; alternatively, for any one of the multiple detection training data, corresponding to each annotation region in the detection training label corresponding to any one of the detection training data, a segmentation training image at the corresponding annotation region can be cropped from the image to be detected corresponding to any one of the detection training data (i.e., the image sub-regions at each cropped annotation region can be used as the segmentation training images), so as to obtain the segmentation training images at each annotation region in the image to be detected corresponding to each detection training data, so as to obtain multiple segmentation training images; alternatively, corresponding to each annotation region in the detection training label corresponding to any one of the detection training data, a segmentation training image at the corresponding annotation region can be cropped from the target training segmentation representation image corresponding to any one of the detection training data, so as to obtain the segmentation training images at each annotation region in the target training segmentation representation image corresponding to each detection training data, so as to obtain multiple segmentation training images, and so on.
[0103] In one implementation, the electronic device can obtain the segmentation labels of each segmentation training image from its internal storage space; alternatively, the segmentation labels of each segmentation training image can also be obtained based on the download link for the segmentation training images.
[0104] In another implementation, for any one of the multiple segmentation training images, the electronic device can obtain the initial segmentation label of any one of the segmentation training images. The initial segmentation label of a segmentation training image may include the region boundary of the saddle field region in the corresponding segmentation training image; and based on the initial segmentation label of any one of the segmentation training images, the segmentation label of any one of the segmentation training images is generated. The segmentation label of a segmentation training image includes the pixel labels (i.e., pixel class labels) of each pixel point in the corresponding segmentation training image; optionally, the pixel labels of the pixel points located within the region boundary of the saddle field region in a segmentation training image are supported to be the pixel values of the saddle field region, and the pixel labels of the pixel points not located within the region boundary of the saddle field region in a segmentation training image are supported to be the pixel values not located in the saddle field region. The pixel values of the saddle field region are used to indicate the pixel points located within the saddle field region, and the pixel values not located in the saddle field region are used to indicate the pixel points not located within the saddle field region. In this case, a segmentation label can be a single-channel image, and the resolution of a segmentation label is the same as the resolution of the corresponding segmentation training image. For example, as Figure 9As shown, the pixel value in the saddle field area can be 255, and the pixel value not in the saddle field area can be 0, so as to generate a segmentation label for segmenting the training image. Optionally, when obtaining the initial segmentation label of any segmentation training image, the local storage of the electronic device can store the initial segmentation labels of each segmentation training image. At this time, the initial segmentation label of any segmentation training image can be obtained from the local storage; or, the electronic device can output any segmentation training image. When detecting the saddle field area boundary annotation operation performed by the user on any segmentation training image, based on the area boundary of the saddle field area indicated by the saddle field area boundary annotation operation, the initial segmentation label of any segmentation training image is generated, and so on.
[0105] Optionally, a segmentation model can be a Unet model (a pixel-level classification model that can output the category (i.e., pixel value) of each pixel point, and pixels of different categories will display different colors), or a model in the deeplab (a semantic segmentation model) series, and so on. Optionally, for any segmentation training image among multiple segmentation training images, the initial segmentation model can be called to segment the saddle field area of any segmentation training image to obtain the pixel division result of any segmentation training image. Optionally, the pixel division result of a segmentation training image can include the predicted pixel point categories of each pixel point in the corresponding segmentation training image; or, the pixel division result of a segmentation training image can include the pixel point category prediction probabilities of each pixel point in the corresponding segmentation training image. A pixel point category prediction probability can be used to indicate the probability that the corresponding pixel point belongs to the category in the saddle field area, that is, it can be used to indicate the probability that the corresponding pixel point is within the saddle field area, and so on. Based on this, the electronic device can calculate the pixel category prediction loss values (such as cross-entropy loss value or exponential loss value, etc.) of each pixel point in any segmentation training image based on the pixel division result and segmentation label of any segmentation training image, and perform a summation operation on the pixel category prediction loss values of each pixel point in each segmentation training image to obtain the above-mentioned segmentation model loss value.
[0106] Optionally, the electronic device can continue to train the initial segmentation model after model optimization until the convergence condition is reached (such as the number of iterations reaches the preset segmentation iteration number threshold, or the segmentation model loss value in the current iteration is less than the preset segmentation model loss threshold, etc.) to obtain the target segmentation model (such as using the segmentation model when the convergence condition is reached as the target segmentation model). Optionally, both the preset segmentation iteration number threshold and the preset segmentation model loss threshold can be set according to experience or actual requirements, and the embodiments of the present invention do not limit this.
[0107] In summary, the embodiments of the present invention can utilize visual representation technology to represent the elements of manual judgment in a matrix of an image-like form, and then obtain corresponding detection training labels and / or segmentation labels through the target training segmentation representation image, so as to obtain samples for deep learning algorithm training, and thus obtain a target detection model and a target segmentation model with better model performance.
[0108] S706, obtain target wind field data and target air pressure data. The target wind field data includes the grid point wind field information of each grid point in the target area, and the target air pressure data includes the grid point air pressure values of each grid point.
[0109] S707, based on the target air pressure data, determine at least one target isobar; and based on each target isobar in the at least one target isobar, determine a target isobar image, where the target isobar image includes the mapped isobars of each target isobar.
[0110] S708, based on the target wind field data, generate a target wind field image, where one wind field image is used to indicate the magnitude of each wind field in the corresponding wind field data; and based on the target isobar image and the target wind field image, generate a target image to be detected.
[0111] S709, call the target detection model to perform saddle field area detection on the target image to be detected, obtain at least one data indicating the area to be segmented of the target image to be detected, and respectively determine the image to be segmented corresponding to the data indicating the area to be segmented based on each data indicating the area to be segmented in the at least one data indicating the area to be segmented.
[0112] S710, call the target segmentation model to perform saddle field area segmentation on the image to be segmented corresponding to each data indicating the area to be segmented, and obtain the data indicating the saddle field area corresponding to the data indicating the area to be segmented.
[0113] In the embodiments of the present invention, after obtaining a plurality of detection training data and the detection training labels corresponding to each of the detection training data in the plurality of detection training data, the corresponding images to be detected for each of the detection training data can be determined respectively based on each of the detection training data; and the initial detection model can be called to perform saddle field area detection on the images to be detected corresponding to each of the detection training data, so as to obtain at least one detection training area indication data corresponding to the corresponding detection training data. Based on this, the detection model loss value of the initial detection model can be calculated based on at least one detection training area indication data and the detection training label corresponding to each of the detection training data; and the model parameters in the initial detection model can be optimized in the direction of reducing the detection model loss value, so as to obtain the initial detection model with optimized model, and based on the initial detection model with optimized model, the target detection model can be determined, which can improve the model performance of the target detection model, so as to improve the accuracy of saddle field area detection. Correspondingly, after obtaining the target wind field data and the target air pressure data, at least one target isobar can be determined based on the target air pressure data; and based on each of the target isobars in the at least one target isobar, a target isobar image can be determined, where the target isobar image includes the mapped isobars of each of the target isobars. Moreover, a target wind field image can be generated based on the target wind field data; and a target image to be detected can be generated based on the target isobar image and the target wind field image. Based on this, the target detection model can be called to perform saddle field area detection on the target image to be detected, so as to obtain at least one area indication data to be segmented of the target image to be detected, and based on each of the area indication data to be segmented in the at least one area indication data to be segmented, the image to be segmented corresponding to the corresponding area indication data to be segmented can be determined respectively; and the target segmentation model can be called to perform saddle field area segmentation on the images to be segmented corresponding to each of the area indication data to be segmented, so as to obtain the saddle field area indication data corresponding to the corresponding area indication data to be segmented. It can be seen that the embodiments of the present invention propose a method for identifying saddle field areas based on deep learning, which can conveniently identify saddle field areas through the target detection model and the target segmentation model, so as to improve the identification efficiency of saddle field areas and effectively save labor costs.
[0114] Based on the description of the related embodiments of the above saddle field area identification method, the embodiments of the present invention also propose a saddle field area identification device, which can be a computer program (including program code) running in an electronic device; as Figure 10 shown, the saddle field area identification device can include an acquisition unit 1001 and a processing unit 1002. The saddle field area identification device can execute Figure 1 or Figure 7 the saddle field area identification method shown, that is, the saddle field area identification device can run the above units:
[0115] An acquisition unit 1001, configured to acquire target wind field data and target air pressure data, where the target wind field data includes grid point wind field information of each grid point in a target area, and the target air pressure data includes grid point air pressure values of the each grid point;
[0116] A processing unit 1002, configured to determine at least one target isobar based on the target air pressure data; and determine a target isobar image based on each target isobar in the at least one target isobar, where the target isobar image includes mapped isobars of the each target isobar;
[0117] The processing unit 1002 is further configured to generate a target wind field image based on the target wind field data, where a wind field image is used to indicate the magnitude of each wind field in the corresponding wind field data; and generate a target image to be detected based on the target isobar image and the target wind field image;
[0118] The processing unit 1002 is further configured to call a target detection model to perform saddle field area detection on the target image to be detected, obtain at least one segmentation area indication data of the target image to be detected, and determine a corresponding segmentation image corresponding to each segmentation area indication data based on each segmentation area indication data in the at least one segmentation area indication data;
[0119] The processing unit 1002 is further configured to call a target segmentation model to perform saddle field area segmentation on the segmentation images corresponding to the respective segmentation area indication data, and obtain saddle field area indication data corresponding to the respective segmentation area indication data.
[0120] In one implementation, the processing unit 1002 may further be configured to: determine an initial segmentation representation image based on the each target isobar; and determine a target segmentation representation image based on the target wind field data and the initial segmentation representation image;
[0121] When the processing unit 1002 determines the segmentation images corresponding to the respective segmentation area indication data based on each segmentation area indication data in the at least one segmentation area indication data, it may be configured to: respectively crop the segmentation images corresponding to the respective segmentation area indication data from the target segmentation representation image based on each segmentation area indication data in the at least one segmentation area indication data, so as to implement determining the segmentation images corresponding to the respective segmentation area indication data.
[0122] In another implementation, when generating the target image to be detected based on the target isobar image and the target wind field image, the processing unit 1002 may specifically be configured to: map the target air pressure data to obtain a grid air pressure mapping image, where the pixel value of the mapped pixel point of a grid point in the grid air pressure mapping image is determined based on the grid air pressure value of the corresponding grid point; expand the mapped pixel points of each grid point in the grid air pressure mapping image outward at the same speed respectively until the grids expanded by the mapped pixel points of each grid point in the grid air pressure mapping image are in contact with each other, so as to obtain an air pressure grid image corresponding to the grid air pressure mapping image, where the air pressure grid image includes the grids expanded by the mapped pixel points of each grid point in the grid air pressure mapping image; wherein, the color of a grid is the color indicated by the pixel value of the corresponding mapped pixel point; splice the target isobar image, the target wind field image and the air pressure grid image to obtain a target image to be detected, and the target image to be detected is a three-channel image.
[0123] In another implementation, the grid wind field information of a grid point includes the grid wind field direction and the grid wind field intensity of the corresponding grid point; when generating the target wind field image based on the target wind field data, the processing unit 1002 may specifically be configured to: for any grid point in the target area, determine the wind field arrow length of the any grid point based on the grid wind field intensity of the any grid point; after obtaining the wind field arrow lengths of all grid points, generate a target wind field image based on the wind field arrow lengths and the grid wind field directions of all grid points, where the target wind field image includes wind field representation arrows on the mapped pixel points of all grid points.
[0124] In another implementation, the acquisition unit 1001 may further be configured to: acquire a plurality of detection training data, and acquire detection training labels corresponding to the respective detection training data in the plurality of detection training data, where one detection training data includes training wind field data and training air pressure data of a training area at a monitoring moment, one training wind field data includes grid wind field information of each training grid point in a training area, and one training air pressure data includes grid air pressure values of each training grid point in a training area;
[0125] The processing unit 1002 can also be used to: respectively determine the images to be detected corresponding to the respective detection training data based on the respective detection training data; call the initial detection model to respectively perform saddle field region detection on the images to be detected corresponding to the respective detection training data, and obtain at least one detection training region indication data corresponding to the corresponding detection training data; calculate the detection model loss value of the initial detection model based on the at least one detection training region indication data and the detection training labels corresponding to the respective detection training data; optimize the model parameters in the initial detection model in the direction of reducing the detection model loss value to obtain the initial detection model after model optimization, and determine the target detection model based on the initial detection model after model optimization.
[0126] In another implementation manner, when the acquisition unit 1001 acquires the detection training labels corresponding to the respective detection training data in the plurality of detection training data, it can specifically be used to: for any one of the plurality of detection training data, generate an initial training segmentation representation image corresponding to the any one of the detection training data based on the training air pressure data in the any one of the detection training data; determine the target training segmentation representation image corresponding to the any one of the detection training data based on the training wind field data in the any one of the detection training data and the initial training segmentation representation image; and obtain the detection training label corresponding to the any one of the detection training data through the target training segmentation representation image.
[0127] In another implementation manner, the acquisition unit 1001 can also be used to: acquire a plurality of segmentation training images, and acquire the segmentation labels of the respective segmentation training images in the plurality of segmentation training images, where the segmentation label of a segmentation training image is used to indicate the pixel points located within the saddle field region in the corresponding segmentation training image and the pixel points not located within the saddle field region in the corresponding segmentation training image.
[0128] The processing unit 1002 can also be used to: call the initial segmentation model to respectively perform saddle field region segmentation on the respective segmentation training images to obtain the pixel division results of the corresponding segmentation training images, where one pixel division result is used to indicate whether each pixel point in the corresponding segmentation training image is located within the saddle field region; calculate the segmentation model loss value of the initial segmentation model based on the pixel division results and the segmentation labels of the respective segmentation training images; optimize the model parameters in the initial segmentation model in the direction of reducing the segmentation model loss value to obtain the initial segmentation model after model optimization, and determine the target segmentation model based on the initial segmentation model after model optimization.
[0129] In another embodiment, when the obtaining unit 1001 obtains the segmentation labels of the respective segmentation training images among the plurality of segmentation training images, it may specifically be used for: for any one of the plurality of segmentation training images, obtaining the initial segmentation label of the any one of the segmentation training images, where the initial segmentation label of a segmentation training image includes the regional boundary of the saddle-shaped field region in the corresponding segmentation training image; generating the segmentation label of the any one of the segmentation training images based on the initial segmentation label of the any one of the segmentation training images, where the segmentation label of a segmentation training image includes the pixel labels of each pixel point in the corresponding segmentation training image; wherein, the pixel labels of the pixel points located within the regional boundary of the saddle-shaped field region in a segmentation training image are supported to be the pixel values of the saddle-shaped field region, and the pixel labels of the pixel points not located within the regional boundary of the saddle-shaped field region in a segmentation training image are supported to be the pixel values not located in the saddle-shaped field region, the pixel values of the saddle-shaped field region are used to indicate the pixel points located within the saddle-shaped field region, and the pixel values not located in the saddle-shaped field region are used to indicate the pixel points not located within the saddle-shaped field region.
[0130] According to an embodiment of the present invention, Figure 10 Each unit in the saddle-shaped field region recognition device shown can be respectively or entirely combined into one or several other units to form, or some of the units can be further split into multiple smaller units with functional reduction to form, which can achieve the same operation without affecting the realization of the technical effects of the embodiments of the present invention. The above units are divided based on logical functions. In practical applications, the function of one unit can also be realized by multiple units, or the functions of multiple units can be realized by one unit.
[0131] Based on the descriptions of the above method embodiments and device embodiments, an exemplary embodiment of the present invention further 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 that can be executed by the at least one processor, and when the computer program is executed by the at least one processor, it is used to cause the electronic device to execute the method according to the embodiments of the present invention.
[0132] An exemplary embodiment of the present invention further provides a computer program product, including a computer program, wherein when the computer program is executed by a processor of a computer, it is used to cause the computer to execute the method according to the embodiments of the present invention.
[0133] Reference Figure 11, a block diagram of an electronic device 1100 that can be a server or a client of the present invention will now be described. It is an example of a hardware device that can be applied to various aspects of the present invention. The electronic device is intended to represent various forms of digital electronic computer devices or various forms of mobile devices. The components shown herein, their connections and relationships, and their functions are merely examples. As Figure 11 shown, the electronic device 1100 includes a computing unit 1101, which can perform various appropriate actions and processes according to a computer program stored in a read-only memory (ROM) 1102 or a computer program loaded from a storage unit 1108 into a random access memory (RAM) 1103. In the RAM 1103, various programs and data required for the operation of the electronic device 1100 can also be stored. The computing unit 1101, the ROM 1102, and the RAM 1103 are connected to each other via a bus 1104. An input / output (I / O) interface 1105 is also connected to the bus 1104.
[0134] A plurality of components in the electronic device 1100 are connected to the I / O interface 1105, including: an input unit 1106, an output unit 1107, a storage unit 1108, and a communication unit 1109. The input unit 1106 can be any type of device that can input information into the electronic device 1100. The input unit 1106 can receive input digital or character information, and generate key signal inputs related to user settings and / or function controls of the electronic device. The output unit 1107 can be any type of device that can present information, and can include, but is not limited to, a display, a speaker, and / or a printer. The storage unit 1108 can include, but is not limited to, a magnetic disk and an optical disk. The communication unit 1109 allows the electronic device 1100 to exchange information / data with other devices via a computer network such as the Internet and / or various telecommunication networks, and can include, but is not limited to, a modem, a network card, an infrared communication device, a wireless communication transceiver, and / or a chipset, etc. The computing unit 1101 can be various general and / or special processing components having processing and computing capabilities. Some examples of the computing unit 1101 include, but are not limited to, a central processing unit (CPU), and any appropriate processor, controller, etc. The computing unit 1101 executes the various methods and processes described above. In some embodiments, the computing unit 1101 can be configured to execute the saddle-shaped field region recognition method in any other appropriate manner (for example, by means of firmware).
[0135] Moreover, it should be understood that the above-disclosed is only a preferred embodiment of the present invention. Of course, it cannot be used to limit the scope of the rights of the present invention. Therefore, equivalent changes made according to the claims of the present invention still fall within the scope covered by the present invention.
Claims
1. A method for identifying a saddle field region, characterized in that Including: Obtain target wind field data and target air pressure data, where the target wind field data includes grid point wind field information of each grid point in the target area, and the target air pressure data includes the grid point air pressure values of the respective grid points; Based on the target air pressure data, determine at least one target isobar; and based on each target isobar in the at least one target isobar, determine a target isobar image, where the target isobar image includes the mapped isobars of the respective target isobars; Based on the target wind field data, generate a target wind field image, where one wind field image is used to indicate the magnitude of each wind field in the corresponding wind field data; And based on the target isobar image and the target wind field image, generate a target image to be detected, including: mapping the target air pressure data to obtain a grid point air pressure mapped image, where the pixel value of the mapped pixel point of a grid point in the grid point air pressure mapped image is determined based on the grid point air pressure value of the corresponding grid point; respectively expand the mapped pixel points of the respective grid points in the grid point air pressure mapped image outward at the same speed until the grids expanded by the mapped pixel points of the respective grid points in the grid point air pressure mapped image come into contact with each other, so as to obtain an air pressure grid image corresponding to the grid point air pressure mapped image, where the air pressure grid image includes the grids expanded by the mapped pixel points of the respective grid points in the grid point air pressure mapped image, and the color of one grid is the color indicated by the pixel value of the corresponding mapped pixel point; perform splicing processing on the target isobar image, the target wind field image, and the air pressure grid image to obtain a target image to be detected, where the target image to be detected is a three-channel image; Invoke a target detection model to perform saddle field area detection on the target image to be detected, obtain at least one segmentation area indication data of the target image to be detected, and respectively determine a segmented image corresponding to the corresponding segmentation area indication data based on each segmentation area indication data in the at least one segmentation area indication data; where one segmentation area indication data includes the area position information of a segmented area; Invoke a target segmentation model to perform saddle field area segmentation on the segmented images corresponding to the respective segmentation area indication data.
2. The method according to claim 1, characterized in that The method further includes: Based on the respective target isobars, determine an initial segmentation characterization image; Based on the target wind field data and the initial segmentation characterization image, determine a target segmentation characterization image; The step of respectively determining a segmented image corresponding to the corresponding segmentation area indication data based on each segmentation area indication data in the at least one segmentation area indication data includes: Respectively based on each segmentation area indication data in the at least one segmentation area indication data, crop out the segmented image corresponding to the corresponding segmentation area indication data from the target segmentation characterization image, so as to realize determining the segmented images corresponding to the respective segmentation area indication data.
3. The method according to claim 1 or 2, characterized in that, The grid point wind field information of a grid point includes the grid point wind field direction and grid point wind field intensity of the corresponding grid point; the step of generating a target wind field image based on the target wind field data includes: For any grid point in the target area, determine the length of the wind field arrow for the grid point based on the grid point wind field intensity of the grid point; After obtaining the wind field arrow lengths of the respective grid points, generate a target wind field image based on the wind field arrow lengths and grid point wind field directions of the respective grid points, where the target wind field image includes wind field representation arrows on the mapped pixel points of the respective grid points.
4. The method according to claim 1 or 2, characterized in that The method further includes: Obtain a plurality of detection training data, and obtain the detection training labels corresponding to the respective detection training data in the plurality of detection training data. One detection training data includes the training wind field data and training air pressure data of a training area at a monitoring moment. One training wind field data includes the grid point wind field information of each training grid point in a training area, and one training air pressure data includes the grid point air pressure values of each training grid point in a training area; Based on the respective detection training data, determine the images to be detected corresponding to the respective detection training data; Call an initial detection model, and perform saddle field area detection on the images to be detected corresponding to the respective detection training data to obtain at least one detection training area indication data corresponding to the respective detection training data; Based on the at least one detection training area indication data and the detection training labels corresponding to the respective detection training data, calculate the detection model loss value of the initial detection model; In the direction of reducing the detection model loss value, optimize the model parameters in the initial detection model to obtain the initial detection model after model optimization, and determine the target detection model based on the initial detection model after model optimization.
5. The method according to claim 4, characterized in that, The obtaining of the detection training labels corresponding to the respective detection training data in the plurality of detection training data includes: For any detection training data in the plurality of detection training data, generate an initial training segmentation characterization image corresponding to the detection training data based on the training air pressure data in the detection training data; Based on the training wind field data in the detection training data and the initial training segmentation characterization image, determine the target training segmentation characterization image corresponding to the detection training data; Through the target training segmentation characterization image, obtain the detection training label corresponding to the detection training data.
6. The method according to claim 1 or 2, characterized in that The method further includes: Obtain a plurality of segmentation training images, and obtain the segmentation labels of the respective segmentation training images in the plurality of segmentation training images. The segmentation label of a segmentation training image is used to indicate the pixel points located in the saddle field area and the pixel points not located in the saddle field area in the corresponding segmentation training image; Call an initial segmentation model, and perform saddle field area segmentation on the respective segmentation training images to obtain the pixel division results of the respective segmentation training images. A pixel division result is used to indicate whether each pixel point in the corresponding segmentation training image is located in the saddle field area; Based on the pixel division results and segmentation labels of the respective segmentation training images, calculate the segmentation model loss value of the initial segmentation model; Optimize the model parameters in the initial segmentation model in the direction of reducing the loss value of the segmentation model to obtain an initial segmentation model with optimized model, and determine the target segmentation model based on the initial segmentation model with optimized model.
7. The method according to claim 6, wherein The obtaining the segmentation labels of each of the multiple segmentation training images includes: For any one of the multiple segmentation training images, obtain the initial segmentation label of the any one of the segmentation training images. The initial segmentation label of a segmentation training image includes the regional boundary of the saddle field region in the corresponding segmentation training image. Based on the initial segmentation label of the any one of the segmentation training images, generate the segmentation label of the any one of the segmentation training images. The segmentation label of a segmentation training image includes the pixel labels of each pixel point in the corresponding segmentation training image. Wherein, the pixel labels of the pixel points within the regional boundary of the saddle field region in a segmentation training image are supported to be the pixel values of the pixels in the saddle field region, and the pixel labels of the pixel points not within the regional boundary of the saddle field region in a segmentation training image are supported to be the pixel values of the pixels not in the saddle field region. The pixel value of the pixels in the saddle field region is used to indicate the pixel points within the saddle field region, and the pixel value of the pixels not in the saddle field region is used to indicate the pixel points not within the saddle field region.
8. A saddle-shaped field area recognition device, characterized in that, The device includes: An acquisition unit, configured to acquire target wind field data and target air pressure data. The target wind field data includes the grid point wind field information of each grid point in the target area, and the target air pressure data includes the grid point air pressure values of the each grid point. A processing unit, configured to determine at least one target isobar based on the target air pressure data; and determine a target isobar image based on each target isobar in the at least one target isobar. The target isobar image includes the mapped isobars of the each target isobar. The processing unit is further configured to generate a target wind field image based on the target wind field data. A wind field image is supported to be used to indicate the magnitude of each wind field in the corresponding wind field data; and generate a target image to be detected based on the target isobar image and the target wind field image, including: map the target air pressure data to obtain a grid point air pressure mapped image. The pixel value of the mapped pixel point of a grid point in the grid point air pressure mapped image is determined based on the grid point air pressure value of the corresponding grid point; expand the mapped pixel points of the each grid point in the grid point air pressure mapped image outward at the same speed until the grids expanded by the mapped pixel points of the each grid point in the grid point air pressure mapped image contact each other to obtain a pressure grid image corresponding to the grid point air pressure mapped image. The pressure grid image includes the grids expanded by the mapped pixel points of the each grid point in the grid point air pressure mapped image. Wherein, the color of a grid is the color indicated by the pixel value of the corresponding mapped pixel point; splice and process the target isobar image, the target wind field image and the pressure grid image to obtain a target image to be detected. The target image to be detected is a three-channel image. The processing unit is further configured to call a target detection model to detect a saddle field region of the target image to be detected, obtain at least one segmentation region indication data of the target image to be detected, and respectively determine a segmented image corresponding to the corresponding segmentation region indication data based on each segmentation region indication data in the at least one segmentation region indication data; wherein, one segmentation region indication data includes region position information of one segmentation region. The processing unit is further configured to call a target segmentation model to respectively perform saddle field region segmentation on the segmented images corresponding to the respective segmentation region indication data.
9. An electronic device, characterized in that, Comprising: A processor; And A memory storing a program, wherein the program includes instructions that, when executed by the processor, cause the processor to execute the method according to any one of claims 1-7.
Citation Information
Patent Citations
Wind shear region identification method and device, storage medium and terminal
CN115861811A