Method for determining warning condition gathering area and electronic equipment
By conducting geographic hash value conversion and cluster analysis on the police sending information of police incidents, the police incident gathering areas and clustered police incidents are determined, which solves the problem of low accuracy of relying on experience in the existing technology, and improves the efficiency and accuracy of police incident handling.
Patent Information
- Application Number
- CN202311514973.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-11-14
- Publication Date
- 2025-05-27
AI Technical Summary
In the prior art, relying on the experience of police officers to determine whether the police incident is a gathering incident, resulting in low accuracy and waste of manpower and material resources.
By obtaining the police dispatch information of the police incident, converting the latitude and longitude into geographical hash values, clustering and analyzing the location points, and determining the police incident gathering area and clustering alarms.
It improves the efficiency of police incident handling, reduces the waste of manpower and material resources, and enhances the accurate identification and prevention of gathered police incidents.
Smart Images

Figure CN120045955A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the technical field of data clustering, and in particular, to a method and an electronic device for determining a police situation aggregation area. Background Art
[0002] Due to the popularity of mobile communication terminals, when an illegal event occurs, usually multiple witnesses or victims will report to the police within a certain period of time and within a certain space. Whether there is a connection between such multiple police situations directly affects the dispatching of police situation handlers and the specific handling methods of police situations, etc.
[0003] In the related art, every time the police center receives a police situation, it will send personnel to handle it. When there is a connection between multiple police situations, these police situations may be aggregated police situations. If relying on the experience of the police officers to judge whether it is an aggregated police situation, on the one hand, it wastes manpower and material resources, and on the other hand, when the police officers lack experience, the accuracy rate is relatively low. Summary of the Invention
[0004] In an exemplary embodiment of this application, a method and an electronic device for determining a police situation aggregation area are provided, which can determine the police situation aggregation area. On the one hand, it can deploy defenses in this police situation aggregation area; on the other hand, when multiple police situations occur in this police situation aggregation area within a certain period of time, these police situations can be directly determined as aggregated police situations, improving the handling efficiency.
[0005] According to the first aspect in the exemplary embodiment, a method for determining a police situation aggregation area is provided, including:
[0006] Obtain the police dispatch information of at least one police situation respectively; wherein, each police dispatch information includes the longitude and latitude of the location where the police situation occurs; the types of at least one police situation are the same;
[0007] Convert the longitude and latitude of each police situation into a geohash value, and determine that the geohash values corresponding to at least one police situation respectively constitute an initial data set;
[0008] Based on the initial data set, cluster at least one position point represented by the initial data set to determine M position point sets; wherein, each position point set includes a target associated position point of one position point among at least one position point, and other position points within a circular area with the target associated position point as the center and a target set radius as the radius; M is an integer greater than or equal to 2;
[0009] For each position point set, determine the area formed by the respective position points included in the position point set as the police situation aggregation area, and the multiple police situations corresponding to the position point set as aggregated police situations.
[0010] According to the second aspect in the exemplary embodiment, an electronic device is provided, including a display screen and a processor;
[0011] A processor, configured to execute:
[0012] Obtain the dispatching information of each of at least one police case; wherein, each dispatching information includes the longitude and latitude of the location where the police case occurred; the types of the at least one police case are the same;
[0013] Convert the longitude and latitude of each police case into a geohash value, and determine that the geohash values corresponding to the at least one police case respectively constitute an initial data set;
[0014] Based on the initial data set, cluster at least one location point represented by the initial data set to determine M location point sets; wherein, each location point set includes a target associated location point of one location point among the at least one location point, and other location points within a circular area with the target associated location point as the center and a target set radius as the radius; M is an integer greater than or equal to 2;
[0015] For each location point set, determine the area formed by the respective location points included in the location point set as a police case aggregation area, and determine that the multiple police cases corresponding to the location point set are aggregation police cases;
[0016] A display screen, configured to execute:
[0017] Display at least one location point; or, display the police case aggregation area.
[0018] According to the third aspect in the exemplary embodiment, there is provided a device for determining a police case aggregation area, and the device includes:
[0019] An information acquisition unit, configured to: obtain the dispatching information of each of at least one police case; wherein, each dispatching information includes the longitude and latitude of the location where the police case occurred; the types of the at least one police case are the same;
[0020] A data conversion unit, configured to: convert the longitude and latitude of each police case into a geohash value, and determine that the geohash values corresponding to the at least one police case respectively constitute an initial data set;
[0021] A location point set determination unit, configured to: based on the initial data set, cluster at least one location point represented by the initial data set to determine M location point sets; wherein, each location point set includes a target associated location point of one location point among the at least one location point, and other location points within a circular area with the target associated location point as the center and a target set radius as the radius; M is an integer greater than or equal to 2;
[0022] A region determination unit, configured to: for each location point set, determine the area formed by the respective location points included in the location point set as a police case aggregation area, and determine that the multiple police cases corresponding to the location point set are aggregation police cases.
[0023] According to a fourth aspect of the exemplary embodiments, a computer storage medium is provided, in which computer program instructions are stored. When the instructions run on a computer, the computer is caused to execute the method for determining a police situation aggregation area as described in the first aspect.
[0024] In the embodiments of the present application, after obtaining the dispatch information of at least one police situation, since each dispatch information includes the longitude and latitude of the place where the police situation occurred, therefore, a geohash value with higher precision for area division is introduced, and the longitude and latitude of each police situation are converted into a geohash value, obtaining an initial data set composed of the geohash values corresponding to at least one police situation respectively. Clustering is performed on each position point based on the initial data set representing at least one position point, and the area formed by each position point included in each position point set is the police situation aggregation area. The police situation aggregation area determined in this way can, on the one hand, be under surveillance for prevention in this police situation aggregation area; on the other hand, when multiple police situations occur in this police situation aggregation area within a period of time, these police situations can be directly determined as aggregated police situations, improving the handling efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0025] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following will briefly introduce the drawings required for the description of the embodiments. Obviously, the following drawings are only some embodiments of the present application. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.
[0026] Figure 1 Exemplarily shows a schematic diagram of the distribution of dispatch information provided by the embodiments of the present application;
[0027] Figure 2 Exemplarily shows a flowchart of a method for determining a police situation aggregation area provided by the embodiments of the present application;
[0028] Figure 3 Exemplarily shows a schematic diagram for determining whether geohash values are the same provided by the embodiments of the present application;
[0029] Figure 4 Exemplarily shows a schematic diagram for calculating the number of associated position points provided by the embodiments of the present application;
[0030] Figure 5 Exemplarily shows a flowchart of a method for determining a density index provided by the embodiments of the present application;
[0031] Figure 6 Exemplarily shows a schematic diagram for calculating a density index provided by the embodiments of the present application;
[0032] Figure 7 Exemplarily shown is a schematic diagram of an area where police incidents gather provided by an embodiment of the present application;
[0033] Figure 8 Exemplarily shown is a flowchart of a complete method for determining an area where police incidents gather provided by an embodiment of the present application;
[0034] Figure 9 Exemplarily shown is a schematic structural diagram of a device for determining an area where police incidents gather provided by an embodiment of the present application;
[0035] Figure 10 Exemplarily shown is a schematic structural diagram of an electronic device provided by an embodiment of the present application. Detailed implementation manners
[0036] To make the objectives, technical solutions, and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present application.
[0037] For ease of understanding, the terms involved in the embodiments of the present application are explained below:
[0038] (1) Geohash value, which can also be called GeoHash value, is a string encoding used to represent geographical locations. GeoHash is essentially a way of spatial indexing. Its basic principle is to understand the Earth as a two-dimensional plane, recursively decompose the plane into smaller sub-blocks, and each sub-block has the same encoding within a certain range of longitude and latitude. Establishing a spatial index in the GeoHash way can improve the efficiency of longitude and latitude retrieval for spatial point of interest (POI) data
[0039] GeoHash converts two-dimensional longitude and latitude into strings. For example, the GeoHash strings of the urban area of Qingdao are WX4ER, WX4G2, WX4G3, etc. Each string represents a certain rectangular area. That is to say, all points (longitude and latitude coordinates) within this rectangular area share the same GeoHash string. In this way, privacy can be protected (only representing the approximate area location rather than specific points), and it is also easier to do caching.
[0040] In Geohash encoding, strings that are similar represent close distances. In this way, prefix matching of strings can be used to query nearby POI information. For example, one is in the urban area and the other is in the suburban area. The GeoHash strings in the urban area are relatively similar to each other, and the strings in the suburban area are also relatively similar to each other, while the similarity degree of the GeoHash strings between the urban area and the suburban area is lower. In addition, different encoding lengths represent different range intervals. The longer the string, the more precise the represented range.
[0041] (2) Analysis radius. In the embodiments of the present application, the set radii involved are all analysis radii, and the size of the analysis radius is related to the type of police situation. For example, the theft type of police situation has one analysis radius, and the loss type of police situation has another analysis radius.
[0042] Every time the police center receives a police situation, it will send personnel to handle it. When there is a connection between multiple police situations, these police situations may be clustered police situations. If relying on the experience of the police officers to judge whether it is a clustered police situation, on the one hand, it wastes manpower and material resources, and on the other hand, when the experience of the police officers is insufficient, the accuracy rate is relatively low.
[0043] For this reason, the embodiments of the present application provide a method for determining the clustered area of police situations. In this method, a geographical hash value with higher accuracy for area division is introduced, and the initial data set representing at least one location point is clustered, and the area formed by each location point included in each location point set is the clustered area of police situations. The clustered area of police situations determined in this way can, on the one hand, be used for prevention by setting up controls in this clustered area of police situations; on the other hand, when multiple police situations occur in this clustered area of police situations within a period of time, these police situations can be directly determined as clustered police situations, improving the handling efficiency.
[0044] After introducing the design concept of the embodiments of the present application, the following briefly introduces the application scenarios applicable to the technical solutions of the embodiments of the present application. It should be noted that the following introduced application scenarios are only used to illustrate the embodiments of the present application rather than to limit. In specific implementation, the technical solutions provided by the embodiments of the present application can be flexibly applied according to actual needs.
[0045] Reference Figure 1 , shows a schematic diagram of the distribution of police dispatch information. Through Figure 1 it can be seen that the location where each police dispatch information represents a police situation is a location point.
[0046] To further illustrate the technical solutions provided by the embodiments of the present application, the following will be described in detail in combination with the accompanying drawings and specific implementation manners. Although the embodiments of the present application provide method operation steps as shown in the following embodiments or drawings, based on routine or non-creative labor, more or fewer operation steps may be included in the method. In steps where there is no necessary causal relationship logically, the execution order of these steps is not limited to the execution order provided by the embodiments of the present application.
[0047] The following combines Figure 1 the application scenario shown, and refers to Figure 2 the flowchart of a method for determining the clustered area of police situations shown to illustrate the technical solutions provided by the embodiments of the present application.
[0048] S201: Obtain the dispatching information of each of at least one police case.
[0049] S202: Convert the longitude and latitude of each police case into a geohash value, and determine that the geohash values corresponding to each of at least one police case constitute an initial data set.
[0050] S203: Based on the initial data set, cluster at least one location point represented by the initial data set to determine M location point sets.
[0051] S204: For each location point set, determine that the area formed by each location point included in the location point set is a police case aggregation area.
[0052] In the embodiment of the present application, after obtaining the dispatching information of each of at least one police case, since each dispatching information includes the longitude and latitude of the place where the police case occurred, therefore, a geohash value with higher precision for regional division is introduced, and the longitude and latitude of each police case are converted into a geohash value, obtaining an initial data set composed of the geohash values corresponding to each of at least one police case. Based on the initial data set representing at least one location point, cluster each location point, and the area formed by each location point included in each location point set is a police case aggregation area. The police case aggregation area determined in this way can, on the one hand, be under surveillance for prevention in this police case aggregation area; on the other hand, when multiple police cases occur in this police case aggregation area within a period of time, these police cases can be directly determined as aggregated police cases, improving the handling efficiency.
[0053] Regarding S201, in order to improve the accuracy, when obtaining police case information, it is possible to target police cases of the same type within a time period (one week, one month, or one year), for example, all police cases of the theft type. In the actual application process, different types of police cases can also be limited. Each police case has a dispatching information, and each dispatching information includes the longitude and latitude of the place where the police case occurred. In a specific example, taking 100 dispatching information corresponding to 100 police cases as an example, that is, there are 100 longitudes and latitudes.
[0054] Regarding S202, applying the standard Geohash algorithm, convert the longitude and latitude of each police case into a geohash value. Since different encoding lengths represent different range intervals, the longer the string, the more precise the represented range. Therefore, different encoding lengths can be preset according to the precision requirements. For example, the encoding length can be set to 9 to 12 bits. An example of a 12-bit geohash value is wtm7xp0r9fns. In this way, 1000 longitudes and latitudes are converted into 1000 8-bit Geohash strings. Therefore, the initial data set stores 1000 geohash values, and each hash value represents a location point, that is, a place where a police case occurred.
[0055] Regarding S203, for the initial data set, clustering is performed on the 1000 position points represented by the data set, and multiple position point sets are obtained. The number of position point sets is represented by M. In each position point set, there is a target associated position point of a position point, and other position points within a circular area centered on the target associated position point and with a target set radius as the radius.
[0056] Exemplarily, the process of determining M position point sets is described through steps A and B:
[0057] A: Based on the initial data set, density identification is performed on at least one position point represented by the initial data set to determine M1 position point sets.
[0058] This process is the first-round clustering process. The first-round clustering process uses density for clustering and has a relatively high accuracy. The specific process includes steps A1 - A3:
[0059] A1: For any one of the at least one position point represented by the initial data set, perform the first operation of determining a position point set to obtain the first position point set.
[0060] In step A1, specifically, any one position point set can be determined through steps A1-1 to A1-3. Taking the process of determining the first position point set as an example:
[0061] A1-1: According to the geographical hash value of the first position point and the first set radius, determine the first quantity of the associated position points of the first position point among the respective position points represented by the initial data set.
[0062] Among them, the first set radius is related to the type of police situation. In the embodiments of the present application, the first set radius is represented by R. The first position point is any one of the position points represented by the initial data set. Among the 1000 position points, taking position point P1 as an example, the associated position points of the first position point are the position points within the first circular area centered on P1 and with R as the radius among the 1000 position points. Count the first quantity S1 of the associated position points of the first position point.
[0063] This step can specifically determine the first quantity through steps A1-1-1 to A1-1-2:
[0064] A1-1-1: According to the correspondence between the length of the geographical hash value and the set length, and the target set length matched by the first set radius.
[0065] Among them, Table 1 shows a correspondence between the length of a geographical hash value and the set length. Based on Table 1, the target set length matched by the first set radius can be determined.
[0066] Table 1 Corresponding relationship between the length of a geographical hash value and a set length
[0067]
[0068]
[0069] For example, if the first set radius R is 0.5 km, it can be seen from Table 1 that the target set length is 8. That is to say, when the geographical hash value is 12 bits long, if the first 8 bits of any two geographical hash values are the same, it can be determined that these two points are both located within a circular area with a radius of R.
[0070] Figure 3 This is a schematic diagram for determining whether geographical hash values are the same provided by an embodiment of the present application. In this schematic diagram, the hash value of point A is WTM7XPFACD9, and the analysis radius is 0.6 km. It can be seen from Table 1 that the first 6 bits need to be judged. Among the 9 points around point A, it can be seen that these 9 points all meet the requirements (the first 6 bits are all WTM7XP), that is to say, these 9 points are all located within a circle with point A as the center and a radius of 0.6 km.
[0071] A1-1-2: Determine the number of each geographical hash value that is the same as each bit of the target length of the geographical hash value of the first position point, and use it as the first quantity of the associated position points of the first position point.
[0072] Figure 4 This is a schematic diagram for calculating the number of associated position points provided by an embodiment of the present application. Among them, determine the position points represented by the geographical hash values that are the same as the first 4 bits of the geographical hash value of position point P1 as the associated position points of position point P1, and use the number of the associated position points of P1 as the first quantity. For example, the associated position points of position point P1 are P2, P4, P7, P9, P10, P18, P23, P30, P35, P44. Denote these 10 associated position points as P1.1, P1.2, P1.3, P1.4, P1.5, P1.6, P1.7, P1.8, P1.9, P1.10 respectively, then the first quantity is 10. By applying this method, the retrieval efficiency can be improved, and the first quantity of the associated position points of the first position point can be determined more quickly.
[0073] A1-2: If the first quantity is greater than the quantity threshold, then determine the density index of each of the associated position points other than the first position point within the first circular area.
[0074] When the first quantity is greater than the quantity threshold, for example, the quantity threshold is 8, then for these 10 associated position points within the first circular area, calculate the density index of each associated position point respectively.
[0075] In this step, the density index can be determined through Figure 5 steps S501 - S503 in
[0076] S501: For each associated position point, determine the second quantity of the position points included in the third circular region centered at the associated position point with a first set radius as the radius.
[0077] Among 10 associated position points, taking P1.1 as an example, if the first set radius is R, then determine the number C1 of the position points included in the third circular region centered at P1.1 with R as the radius.
[0078] S502: Determine the third quantity of the position points included in the fourth circular region centered at the associated position point with a second set radius as the radius.
[0079] Among them, the second set radius is related to the first radius and can be a decimal between 0 and 1 multiplied by the first set radius. For example, it can be 0.5R. Determine the number C2 of the position points included in the circular region centered at P1.1 with 0.5R as the radius.
[0080] S503: Calculate the density index of the associated position point according to the second quantity and the third quantity.
[0081] Exemplarily, determine the density index of the associated position point P1.1 as C2 / C1. Figure 6 This is a schematic diagram for calculating the density index provided by an embodiment of the present application.
[0082] Among them, the density coefficient means that within a specific radius range, when the number of police cases reaches the threshold, the closer to the center, the more obvious the center of the police case clustering. The value range of the density coefficient is from 0 to 1, indicating the degree of the point approaching the center. Assuming the analysis radius is R, then the density coefficient can be the ratio of the number of points within the radius of R / 2 centered at the current center to the number of points within the radius of R.
[0083] A1 - 3: Among the associated position points with a density index greater than the index threshold, determine the position point with the highest density index as the target associated position point of the first position point, and determine the position points included in the second circular region centered at the target associated position point with the second set radius as the radius, to form the first position point set.
[0084] Among them, after determining the first position point set, the position points in this set can be marked as the aggregated state. After obtaining other position point sets subsequently, they are also marked.
[0085] As described above, the density indices corresponding to the 10 associated position points of P1 can be determined. An index threshold is preset, for example, it can be 0.8. Therefore, among the associated position points where the density index is greater than the index threshold, the position point with the highest density index is used as the target associated position point of P1. In this example, the associated position point of position point P1 is P1.5(P10). At this time, it can be determined that the position points included in the second circular area with P1.5 as the center and the second set radius of 0.5R form the first position point set.
[0086] In the first round of iteration process, the target set radius is the second set radius.
[0087] A2: From the initial data set, remove the geographical hash values corresponding to the respective position points in the first position point set, and update the initial data set.
[0088] As described above, taking position point P1 as an example, the calculation process of the position point set corresponding to position point P1 is illustrated, that is, the first iteration process in the first round of iteration process. After the first iteration process ends, in the book publishing data set, the geographical hash values corresponding to the respective position points in the first position point set are removed to update the initial data set. That is to say, the second iteration process in the first round of iteration process is in the updated initial data set.
[0089] A3: For the geographical hash value of any position point in the updated initial data set, continue to perform the first operation of determining the position point set until the density of the associated position point of any position point is less than the density threshold, and M1 position point sets are obtained.
[0090] In the updated initial data set, the second iteration process is performed in the same way as the first iteration process, and a position point set is obtained again. Repeat the execution until the density of any position point is less than the density threshold. In this way, the number of position point sets obtained after the first round of iteration is denoted as M.
[0091] The above-mentioned process of step A and the expanded process of the steps related to step A are all processes of clustering using density. However, in this process, there are some points that are not clustered, such as position points with too few associated position points and position points with too small density. Although these points do not reach the density index limit, they still have a certain degree of density. Therefore, in order to make full use of these position points, the second round of clustering process is performed through step B.
[0092] The second round of clustering process is based on the remaining position points after the first round of clustering and uses the quantity for clustering, and the position points that were not successfully clustered in the first round can also be classified into the corresponding categories.
[0093] B: Based on the reference data set, perform edge point recognition on at least one position point represented by the reference data set to determine M2 position point sets.
[0094] Among them, after removing the geographical hash values of the position points other than the position points included in the M1 position point sets from the initial data set, the data set composed of the remaining geographical hash values is called the reference data set. Denote the number of position points obtained in the second-round clustering process as M2. Both M1 and M2 are integers, and the sum of M1 and M2 is M.
[0095] In the second-round clustering process, it can be implemented through steps B1 to B3:
[0096] B1: For any one of the at least one position point represented by the reference data set, perform a second operation to determine a position point set to determine a second position point set.
[0097] In this step, it can be implemented through steps B1-1 to B1-2:
[0098] B1-1: Among the at least one position point represented in the reference data set, determine the fourth quantity of the position points included in the fifth circular region with the second position point as the center and the first set radius as the radius.
[0099] Among them, the second position point is any one of the at least one position point represented by the reference data set. Take the third set radius as R. The process of determining the second quantity in this step is the same as the process of determining the first quantity in the foregoing embodiment, and will not be elaborated here.
[0100] B1-2: If the fourth quantity is greater than the quantity threshold, determine that the position points within the fifth circular region with the second position point as the center and the first radius as the radius form the second position point set.
[0101] In the second-round iteration process, only the quantity threshold is used for judgment. That is to say, when the second quantity is greater than the quantity threshold, the second position point set can be determined.
[0102] In the second-round iteration process, the target set radius is the first set radius.
[0103] B2: Remove the geographical hash values corresponding to the respective position points within the second position point set from the reference data set, and update the reference data set.
[0104] This update process is the same as the update process in the first-round iteration process, and will not be elaborated here.
[0105] B3: For the geographical hash value of any position point in the updated reference data set, continue to perform the second operation of determining the position point set until the number of associated position points of any position point is less than the number threshold, obtaining M2 position point sets.
[0106] This iterative process is applied in the same way as the first iterative process in the second-round iterative process to perform subsequent iterative processes, and a total of M2 position point sets are obtained.
[0107] The M1 position sets obtained in the first-round iterative process and the M2 position point sets obtained in the second-round iterative process are collectively denoted as M.
[0108] Regarding S204, after obtaining M position point sets, for each position point set, determine the area formed by each position point included in the position point set as the police situation aggregation area.
[0109] For each position point set, a convex polygon can be constructed through a geospatial processing tool, such as the Truf tool, as the police situation aggregation area of this position point set.
[0110] In addition, after determining the police situation aggregation area, the centroid of the convex polygon used to represent the police situation aggregation area can also be determined as the frequent police situation point.
[0111] Figure 7 This is a schematic diagram of a police situation aggregation area provided by an embodiment of the present application. Figure 7 The number of convex polygons in it is only for illustration and does not form a specific limitation.
[0112] In the embodiment of the present application, the police situation aggregation area can be calculated. The multiple police situations corresponding to the position point set of the police situation aggregation area are aggregated police situations, and the centroid of the area is the police situation aggregation point. That is to say, the location where the aggregated police situation occurs can be automatically identified. That is, it can be calculated whether each police situation is an aggregated police situation and where it aggregates, which helps with subsequent deployment.
[0113] To make the implementation solution of the present application more perfect. Figure 8 This is a flowchart of a complete method for determining a police situation aggregation area provided by an embodiment of the present application. Figure 8 It at least includes the following steps:
[0114] S801: Obtain the police dispatch information of at least one police situation respectively.
[0115] S802: Convert the longitude and latitude of each police situation into a geographical hash value, and determine the initial data set composed of the geographical hash values corresponding to at least one police situation respectively.
[0116] S803: For any one of the at least one location point represented by the initial data set, perform a first operation to determine a set of location points, obtaining a first set of location points.
[0117] S804: Remove the respective geographic hash values corresponding to each location point within the first set of location points from the initial data set, updating the initial data set.
[0118] S805: Continue to perform the first operation to determine a set of location points on the geographic hash value of any one location point in the updated initial data set until the density of the associated location points of any one location point is less than the density threshold, obtaining M1 sets of location points.
[0119] S806: For any one of the at least one location point represented by the reference data set, perform a second operation to determine a set of location points, determining a second set of location points.
[0120] S807: Remove the respective geographic hash values corresponding to each location point within the second set of location points from the reference data set, updating the reference data set.
[0121] S808: Continue to perform the second operation to determine a set of location points on the geographic hash value of any one location point in the updated reference data set until the number of associated location points of any one location point is less than the number threshold, obtaining M2 sets of location points.
[0122] S809: For each set of location points among the M (M1 + M2) sets of location points, determine the area formed by the location points included in the set of location points as the police situation aggregation area, and the multiple police situations corresponding to the set of location points as the aggregated police situations.
[0123] S810: Determine the centroid of the convex polygon used to represent the police situation aggregation area as the location with frequent police situations.
[0124] When judging whether a police situation is an aggregated police situation, in the prior art, it relies on the experience of case-handling personnel for analysis and judgment, and it is impossible to detect and handle aggregated police situations in a timely manner, resulting in low case handling efficiency, untimely handling, and a risk of further spread of the case. In the embodiments of the present application, by setting specific analysis radii, analysis times, and police situation quantity thresholds for the occurred police situations, the clustering degree of police situations is calculated after the number of police situations reaches the threshold within a specific radius range; the higher the clustering degree, the closer it indicates to the police situation, and the more obvious the aggregation of police situations. Through algorithm analysis, the occurrence locations of aggregated police situations can be automatically identified, achieving early detection, early prevention and control, timely control and handling of aggregated police situations, and improving the handling efficiency.
[0125] Such as Figure 9As shown, based on the same inventive concept, an embodiment of the present application provides a device for determining a police situation aggregation area. The device includes an information acquisition unit 91, a data conversion unit 92, a location point set determination unit 93, and a region determination unit 94.
[0126] The information acquisition unit 91 is configured to: acquire the dispatch information of each of at least one police situation; wherein, each dispatch information includes the longitude and latitude of the location where the police situation occurs; and the types of at least one police situation are the same;
[0127] The data conversion unit 92 is configured to: convert the longitude and latitude of each police situation into a geographical hash value, and determine an initial data set composed of the geographical hash values corresponding to at least one police situation respectively;
[0128] The location point set determination unit 93 is configured to: based on the initial data set, perform clustering on at least one location point represented by the initial data set to determine M location point sets; wherein, each location point set includes a target associated location point of one location point among at least one location point, and other location points within a circular area with the target associated location point as the center and a target set radius as the radius; M is an integer greater than or equal to 2;
[0129] The region determination unit 94 is configured to: for each location point set, determine the region formed by each location point included in the location point set as the police situation aggregation area, and the multiple police situations corresponding to the location point set as the aggregated police situations.
[0130] In an alternative embodiment, the location point set determination unit 93 is specifically configured to:
[0131] Based on the initial data set, perform density identification on at least one location point represented by the initial data set to determine M1 location point sets;
[0132] Based on the reference data set, perform edge point identification on at least one location point represented by the reference data set to determine M2 location point sets; wherein, the reference data set includes the geographical hash values of the location points obtained by removing the location points included in the M1 location point sets from the initial data set;
[0133] wherein, both M1 and M2 are integers, and the sum of M1 and M2 is M.
[0134] In an alternative embodiment, the location point set determination unit 93 is specifically configured to:
[0135] For any one of at least one location point represented by the initial data set, perform a first operation of determining a location point set to obtain a first location point set;
[0136] Remove the geographical hash values corresponding to each location point in the first location point set from the initial data set, and update the initial data set;
[0137] For the geographical hash value of any location point in the updated initial data set, continue to perform the first operation of determining the location point set until the density of the associated location points of any location point is less than the density threshold, and obtain M1 location point sets.
[0138] In an alternative embodiment, the location point set determination unit 93 is specifically configured to:
[0139] According to the geographical hash value of the first location point and the first set radius, determine the first quantity of the associated location points of the first location point among the location points represented by the initial data set; wherein, the first location point is any location point represented by the initial data set; the associated location points of the first location point are the location points within the first circular region with the first location point as the center and the first set radius as the radius;
[0140] If the first quantity is greater than the quantity threshold, then determine the density index for each of the associated location points other than the first location point within the first circular region;
[0141] Among the associated location points with a density index greater than the index threshold, determine the location point with the highest density index as the target associated location point of the first location point, and determine the location points included within the second circular region with the target associated location point as the center and the second set radius as the radius to form the first location point set;
[0142] The first set radius is related to the type of police situation, and the second set radius is related to the first set radius; the target radius is the second set radius.
[0143] In an alternative embodiment, the location point set determination unit 93 is specifically configured to:
[0144] For each associated location point, determine the second quantity of the location points included within the third circular region with the associated location point as the center and the first set radius as the radius;
[0145] Determine the third quantity of the location points included within the fourth circular region with the associated location point as the center and the second set radius as the radius;
[0146] Calculate the density index of the associated location point according to the second quantity and the third quantity.
[0147] In an alternative embodiment, the location point set determination unit 93 is specifically configured to:
[0148] According to the correspondence between the length of the geographical hash value and the set length, and the target set length matched with the first set radius;
[0149] Determine the number of each geographical hash value that is the same as each bit of the target length of the geographical hash value of the first position point, and use it as the first quantity of the associated position points of the first position point.
[0150] In an optional implementation manner, the position point set determining unit 93 is specifically configured to:
[0151] For any one of the at least one position point represented by the reference data set, perform a second operation of determining the position point set to determine a second position point set;
[0152] Remove the geographical hash values corresponding to each position point in the second position point set from the reference data set, and update the reference data set;
[0153] For the geographical hash value of any one position point in the updated reference data set, continue to perform the second operation of determining the position point set until the number of associated position points of any one position point is less than the quantity threshold, and obtain M2 position point sets.
[0154] In an optional implementation manner, the position point set determining unit 93 is specifically configured to:
[0155] Among the at least one position point represented in the reference data set, determine the fourth quantity of the position points included in the fifth circular area with the second position point as the center and the first set radius as the radius; wherein, the second position point is any one of the at least one position point represented by the reference data set;
[0156] If the fourth quantity is greater than the quantity threshold, determine that the position points within the fifth circular area with the second position point as the center and the first set radius as the radius form a position point set;
[0157] The first set radius is related to the type of the police situation, and the target set radius is the first set radius.
[0158] In an optional implementation manner, for each position point set, after determining that the area formed by each position point included in the position point set is a police situation aggregation area, and the multiple police situations corresponding to the position point set are aggregation police situations, the area determining unit 94 is specifically configured to:
[0159] Determine the centroid of the convex polygon used to represent the police situation aggregation area as the police situation frequent occurrence point.
[0160] Since the device is the device in the method of the embodiment of the present application, and the principle by which the device solves problems is similar to that of the method, the implementation of the device can refer to the implementation of the method, and the repeated parts will not be elaborated.
[0161] As Figure 10 shown, based on the same inventive concept, an embodiment of the present application provides an electronic device, including a processor 101 and a display screen 102.
[0162] The processor 101 is configured to execute:
[0163] Obtain the dispatching information of each of at least one police situation; wherein, each dispatching information includes the longitude and latitude of the location where the police situation occurs; the types of at least one police situation are the same;
[0164] Convert the longitude and latitude of each police situation into a geohash value, and determine that the geohash values corresponding to at least one police situation respectively form an initial data set;
[0165] Based on the initial data set, perform clustering on at least one location point represented by the initial data set to determine M location point sets; wherein, each location point set includes a target associated location point of one location point among at least one location point, and other location points within a circular area with the target associated location point as the center and a target set radius as the radius; M is an integer greater than or equal to 2;
[0166] For each location point set, determine the area formed by each location point included in the location point set as a police situation aggregation area, and the multiple police situations corresponding to the location point set as aggregated police situations;
[0167] The display screen 102 is configured to execute:
[0168] Display at least one location point; or, display the police situation aggregation area.
[0169] In an alternative embodiment, the processor 101 is specifically configured to:
[0170] Based on the initial data set, perform density identification on at least one location point represented by the initial data set to determine M1 location point sets;
[0171] Based on the reference data set, perform edge point identification on at least one location point represented by the reference data set to determine M2 location point sets; wherein, the reference data set includes the geohash values of the location points other than the location points included in the M1 location point sets in the initial data set;
[0172] Wherein, both M1 and M2 are integers, and the sum of M1 and M2 is M.
[0173] In an alternative embodiment, the processor 101 is specifically configured to:
[0174] For any one of the at least one position point represented by the initial data set, perform a first operation of determining a set of position points to obtain a first set of position points;
[0175] Exclude from the initial data set the geo-hash values corresponding to each position point in the first set of position points, and update the initial data set;
[0176] For the geo-hash value of any one position point in the updated initial data set, continue to perform the first operation of determining a set of position points until the density of the associated position points of any one position point is less than the density threshold, to obtain M1 sets of position points.
[0177] In an alternative embodiment, the processor 101 is specifically configured to:
[0178] According to the geo-hash value of the first position point and the first set radius, determine the first quantity of the associated position points of the first position point among the respective position points represented by the initial data set; wherein, the first position point is any one position point represented by the initial data set; the associated position points of the first position point are the position points within a first circular region with the first position point as the center and the first set radius as the radius;
[0179] If the first quantity is greater than the quantity threshold, then determine the density index for each of the associated position points other than the first position point within the first circular region;
[0180] Among the associated position points with a density index greater than the index threshold, determine the position point with the highest density index as the target associated position point of the first position point, and determine that the position points included within a second circular region with the target associated position point as the center and the second set radius as the radius constitute the first set of position points;
[0181] The first set radius is related to the type of the police situation, and the second set radius is related to the first set radius; the target radius is the second set radius.
[0182] In an alternative embodiment, the processor 101 is specifically configured to:
[0183] For each associated position point, determine the second quantity of the position points included within a third circular region with the associated position point as the center and the first set radius as the radius;
[0184] Determine the third quantity of the position points included within a fourth circular region with the associated position point as the center and the second set radius as the radius;
[0185] Calculate the density index of the associated location points according to the second quantity and the third quantity.
[0186] In an alternative embodiment, the processor 101 is specifically configured to:
[0187] According to the correspondence between the length of the geohash value and the set length, and the target set length matched by the first set radius;
[0188] Determine the number of each geohash value that is the same as each bit of the target length of the geohash value of the first location point, and use it as the first quantity of the associated location points of the first location point.
[0189] In an alternative embodiment, the processor 101 is specifically configured to:
[0190] For any one of the at least one location point represented by the reference data set, perform a second operation to determine the location point set to determine the second location point set;
[0191] Remove the geohash values corresponding to each location point in the second location point set from the reference data set, and update the reference data set;
[0192] Continue to perform the second operation to determine the location point set on the geohash value of any one location point in the updated reference data set until the number of associated location points of any one location point is less than the quantity threshold, and obtain M2 location point sets.
[0193] In an alternative embodiment, the processor 101 is specifically configured to:
[0194] Among the at least one location point represented in the reference data set, determine the fourth quantity of the location points included in the fifth circular area with the second location point as the center and the first set radius as the radius; wherein, the second location point is any one of the at least one location point represented by the reference data set;
[0195] If the fourth quantity is greater than the quantity threshold, determine that the location points within the fifth circular area with the second location point as the center and the first set radius as the radius form a location point set;
[0196] The first set radius is related to the type of the police situation, and the target set radius is the first set radius.
[0197] In an alternative embodiment, for each location point set, after determining that the area formed by each location point included in the location point set is a police situation aggregation area, and the multiple police situations corresponding to the location point set are aggregation police situations, the processor 101 is further configured to:
[0198] Determine the centroid of the convex polygon used to represent the police situation aggregation area as the location with frequent police situations.
[0199] The embodiments of the present application also provide a computer storage medium, in which computer program instructions are stored. When the instructions run on a computer, the computer is enabled to execute the steps of the method for determining the alarm aggregation area described above.
[0200] Those skilled in the art should understand that the embodiments of the present application can be provided as a method, a system, or a computer program product. Therefore, the present application can take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware aspects. Moreover, the present application can take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) that contain computer-usable program code.
[0201] The present application is described with reference to the flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to the present application. It should be understood that each flow and / or block in the flowcharts and / or block diagrams, as well as the combination of flows and / or blocks in the flowcharts and / or block diagrams, can be realized by computer program instructions. These computer program instructions can be provided to the processors of general-purpose computers, special-purpose computers, embedded processors, or other programmable data processing devices to generate a machine, such that the instructions executed by the processors of the computer or other programmable data processing devices generate a device for realizing the functions specified in Figure 1 one or more flows and / or Figure 1 blocks or multiple blocks.
[0202] These computer program instructions can also be stored in a computer-readable memory that can direct a computer or other programmable data processing device to work in a specific manner, such that the instructions stored in the computer-readable memory generate a manufactured article including an instruction device, and the instruction device realizes the functions specified in Figure 1 one or more flows and / or Figure 1 blocks or multiple blocks.
[0203] These computer program instructions can also be loaded onto a computer or other programmable data processing device, such that a series of operation steps are executed on the computer or other programmable device to generate a computer-implemented process. Thus, the instructions executed on the computer or other programmable device provide steps for realizing the functions specified in Figure 1 one or more flows and / or Figure 1 blocks or multiple blocks.
[0204] Obviously, those skilled in the art can make various changes and modifications to this application without departing from the scope of this application. Thus, if these modifications and variations of this application fall within the scope of the claims of this application and their equivalent technologies, this application is also intended to cover these changes and modifications.
Claims
1. A method for determining a police situation aggregation area, characterized in that, it includes: Obtaining the police dispatch information of at least one police situation respectively; wherein, each police dispatch information includes the longitude and latitude of the place where the police situation occurred; the types of the at least one police situation are the same; Converting the longitude and latitude of each police situation into a geohash value, and determining that the geohash values corresponding to the at least one police situation respectively constitute an initial data set; Based on the initial data set, clustering at least one location point represented by the initial data set to determine M location point sets; wherein, each location point set includes a target associated location point of one location point among the at least one location point, and other location points within a circular area with the target associated location point as the center and a target set radius as the radius; M is an integer greater than or equal to 2; For each location point set, determining the area formed by each location point included in the location point set as a police situation aggregation area, and the multiple police situations corresponding to the location point set as aggregated police situations.
2. The method according to claim 1, characterized in that, the clustering at least one location point represented by the initial data set based on the initial data set to determine M location point sets includes: Based on the initial data set, performing density identification on at least one location point represented by the initial data set to determine M1 location point sets; Based on a reference data set, performing edge point identification on at least one location point represented by the reference data set to determine M2 location point sets; wherein, the reference data set includes the geohash values of the location points obtained by removing the location points included in the M1 location point sets from the initial data set; wherein, both M1 and M2 are integers, and the sum of M1 and M2 is M.
3. The method according to claim 2, characterized in that, the performing density identification on at least one location point represented by the initial data set based on the initial data set to determine M1 location point sets includes: For any one location point among at least one location point represented by the initial data set, performing a first operation of determining a location point set to obtain a first location point set; Removing the geohash values corresponding to each location point within the first location point set from the initial data set, and updating the initial data set; Continuing to perform the first operation of determining a location point set on the geohash value of any one location point in the updated initial data set until the density of the associated location point of the any one location point is less than a density threshold, to obtain M1 location point sets.
4. The method according to claim 3, characterized in that, the performing the first operation of determining a location point set on any one location point among at least one location point represented by the initial data set to obtain the first location point set includes: According to the geographical hash value of the first position point and the first set radius, determine the first quantity of the associated position points of the first position point among the respective position points represented by the initial data set; wherein, the first position point is any one of the position points represented by the initial data set; the associated position points of the first position point are the position points within the first circular area centered at the first position point and with the first set radius as the radius. If the first quantity is greater than the quantity threshold, determine the density index of each of the associated position points other than the first position point within the first circular area. Among the associated position points with a density index greater than the index threshold, determine the position point with the highest density index as the target associated position point of the first position point, and determine the position points included within the second circular area centered at the target associated position point and with the second set radius as the radius to form the first position point set. The first set radius is related to the type of the police situation, and the second set radius is related to the first set radius; the target radius is the second set radius.
5. The method according to claim 4, wherein, The determining the density index of each of the associated position points other than the first position point within the first circular area includes: For each associated position point, determine the second quantity of the position points included within the third circular area centered at the associated position point and with the first set radius as the radius. Determine the third quantity of the position points included within the fourth circular area centered at the associated position point and with the second set radius as the radius. Calculate the density index of the associated position point based on the second quantity and the third quantity.
6. The method according to claim 4, wherein, The determining the first quantity of the associated position points of the first position point among the respective position points represented by the initial data set according to the geographical hash value of the first position point and the first set radius includes: According to the correspondence between the length of the geographical hash value and the set length, and the target set length matched with the first set radius. Determine the number of each geographical hash value that is the same as each bit of the target length of the geographical hash value of the first position point as the first quantity of the associated position points of the first position point.
7. The method according to claim 2, wherein, The identifying the edge points of at least one position point represented by the reference data set based on the reference data set to determine M2 position point sets includes: For any one of the at least one position point represented by the reference data set, perform the second operation of determining the position point set to determine the second position point set. Remove the geographical hash values corresponding to the respective position points within the second position point set from the reference data set to update the reference data set. For the geohash value of any position point in the updated reference data set, continue to perform the second operation of determining the set of position points until the number of associated position points of any one of the position points is less than the quantity threshold, and obtain M2 sets of position points.
8. The method according to claim 7, wherein, performing the second operation of determining the set of position points for any one of at least one position point represented by the reference data set to determine a second set of position points includes: determining a fourth quantity of position points included in a fifth circular area centered at a second position point with a first set radius in at least one position point represented by the reference data set; wherein, the second position point is any one of at least one position point represented by the reference data set; if the fourth quantity is greater than the quantity threshold, determining that the position points within the fifth circular area centered at the second position point with the first set radius constitute the second set of position points; the first set radius is related to the type of the police situation, and the target set radius is the first set radius.
9. The method according to any one of claims 1 to 8, wherein, after determining, for each set of position points, that the area formed by each position point included in the set of position points is a police situation aggregation area and that the multiple police situations corresponding to the set of position points are aggregated police situations, the method further includes: determining the centroid of the convex polygon representing the police situation aggregation area as the location with frequent police situations.
10. An electronic device, wherein, it includes a display screen and a processor; the processor is configured to execute: acquiring the dispatch information of at least one police situation respectively; wherein, each dispatch information includes the longitude and latitude of the location where the police situation occurs; the types of the at least one police situation are the same; converting the longitude and latitude of each police situation into a geohash value, and determining an initial data set composed of the geohash values corresponding to the at least one police situation respectively; based on the initial data set, clustering at least one position point represented by the initial data set to determine M sets of position points; wherein, each set of position points contains the target associated position points of one of the at least one position point, and other position points within a circular area centered at the target associated position point with a target set radius; M is an integer greater than or equal to 2; for each set of position points, determining that the area formed by each position point included in the set of position points is a police situation aggregation area and that the multiple police situations corresponding to the set of position points are aggregated police situations; the display screen is configured to execute: displaying the at least one position point; or, displaying the police situation aggregation area.