A multi-stage location-based, progressively decreasing method and system for detecting close contacts of confirmed epidemic patients
By adopting a location-based multi-stage gradually reduced residual K-means clustering method in epidemic prevention and control, the problem of high computational complexity and poor real-time performance of close contact personnel screening in the prior art is solved, and fast and efficient close contact personnel detection is achieved.
Patent Information
- Application Number
- CN202010267024.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-04-03
- Publication Date
- 2025-04-01
- Estimated Expiration
- 2040-04-03
AI Technical Summary
In the prior art, when screening and detecting close contacts of confirmed patients, there are problems such as data accuracy dependence, low screening strictness, poor real-timeness and high computational complexity, especially when processing large-scale data, it is difficult to achieve effective calculations.
Using a location-based multi-stage gradually reduced residual K-means clustering method, by slicing and clustering user location data, the residual K-means algorithm is used to continuously ignore the categories and samples that exclude risks, reduce the computational complexity and improve the calculation speed.
It has achieved rapid finding close contacts of confirmed patients, significantly improved computing speed, reduced resource consumption, made large-scale data clustering possible, and effectively supported epidemic prevention and control measures.
Smart Images

Figure CN113496782B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to a location-based multi-stage and gradually decreasing method and system for detecting close contacts of confirmed epidemic patients, which belongs to the epidemic propagation network mining technology based on location services, and specifically involves user location data acquisition, geographic location information analysis, and geographic location information clustering. Background Art
[0002] Close contacts in epidemiology: Close contacts refer to members who live directly with confirmed or highly suspected virus cases. They include colleagues in the office, students and head teachers in a class at school, colleagues and classmates in the same classroom or dormitory, passengers on the same plane, etc. Other forms of direct contacts include those accompanying virus patients, taking taxis, taking elevators, etc., and the history of contacts determined by comprehensive assessment of health and epidemic prevention personnel based on epidemiological investigations and on-site conditions, as well as other forms of direct contacts.
[0003] Especially for some asymptomatic infected people, they are unaware that they are carrying the virus. In this case, once they come into close contact with other people, it is easy for them to infect others. If the close contacts of the patients are not controlled, it is easy to cause an outbreak and spread of the virus. Therefore, it is very important to detect the close contacts of the patients in a timely manner.
[0004] A common method is to use traffic data to screen the flow paths of people. This method has the problems of heavy reliance on data accuracy, low screening rigor, and poor real-time performance. If a clustering method is used to detect close contacts, it is difficult to complete the calculation using ordinary clustering algorithms for such millions of big data in actual operation. The present invention considers using a multi-stage location-based clustering method that reduces the computational complexity of the algorithm, thereby greatly improving the calculation speed. Summary of the invention
[0005] In view of the above problems, the object of the present invention is to provide a location-based multi-stage and progressively reduced method and system for detecting close contacts of confirmed epidemic patients, which can quickly find close contacts of confirmed patients.
[0006] To achieve the above purpose, the present invention adopts the following technical solution: a multi-stage location-based method for detecting close contacts of confirmed epidemic patients, comprising the following contents:
[0007] 1) Collect the location data of users in a city within one day from the map software, slice the user location data from 8:00 to 22:00, and slice it every T hours, with a total of 14 / T+1 time slices. The number of slices is not fixed. The number of time slices selected every day can be different according to the specific requirements of different cities. For cities with more serious diseases, it can be sliced every half an hour, with a total of 30 time slices per day. For cities with less serious diseases, it can be sliced every 1 hour, with a total of 15 time slices per day.
[0008] 2) Cluster each time slice, with each user as a sample point. The sample points are divided into three categories: confirmed infected persons with a characteristic value of 1; persons with unknown risk with a characteristic value of 0; and persons with excluded risk with a characteristic value of -1. The classes are also divided into three categories: risk class with a characteristic value of 1; unknown risk class with a characteristic value of 0; and excluded risk class with a characteristic value of -1. In each clustering, only one sample point with an initial characteristic value of 1 is given;
[0009] 3) Use the residual K-means method for clustering. First, according to the regional division or regional characteristics of the city, an initial category number K value is given, and all sample points are clustered according to the residual K-means method. At the beginning of clustering, the initial eigenvalues of all categories are 0, that is, the risk cannot be excluded. In the clustering process, for confirmed infected persons with an eigenvalue of 1, if they have never appeared in a certain category during multiple iterations, it can be considered that under this confidence level, the characteristics of this category can be rewritten as -1, and this category can be ignored in subsequent calculations. For non-infected persons with an eigenvalue of -1, if they are continuously classified in the category of excluded risk during multiple iterations, it can be considered that the eigenvalue of the sample can be marked as -1 under this confidence level, and these samples can be ignored in subsequent processes. Using this method, the amount of data that needs to be involved in the calculation can be continuously reduced;
[0010] 4) Continue to perform residual K-means clustering on the remaining sample points. During the iteration process, the categories and samples that exclude risks are gradually ignored in the calculation, and the categories that cannot exclude risks are continuously clustered. When the clustering result remains unchanged, the iteration ends and the clustering is completed. The remaining sample points in the cluster cannot exclude the risk of close contact with confirmed patients. At this time, a large part of the initial nodes have been discarded. It is precisely because of the continuous discarding of excluded risk nodes that the residual K-means algorithm can meet the clustering requirements. For close contacts in each time slice, their infection probability can be determined based on frequency superposition.
[0011] Preferably, in step 1), the user location data from 8:00 to 22:00 is sliced, wherein in each time slice, for a user m, its location can be represented by a location function l(m).
[0012] Preferably, in step 3), the residual K-means method is used for clustering. During the clustering process, for the sample point m, it is necessary to calculate its distance to each class, and divide the sample point into the class closest to it. The distance from the sample point m to the class n can be expressed as d=l(m)-l(c_n), where c represents the center of the class n.
[0013] Preferably, in step 3), the residual K-means method is used for clustering. After each iteration, the center position of the class needs to be updated for the class that has changed in this iteration. The center of the class is calculated using the mean method. For example, for points A(x1, y1), B(x2, y2) and C(x3, y3), the center can be expressed as (x1+x2+x3) / 3 and (y1+y2+y3) / 3.
[0014] Preferably, in step 3), during the clustering process, for confirmed infected persons with a characteristic value of 1, if they have never appeared in a certain class during multiple iterations, it can be considered that under this confidence level, the characteristic of this class can be rewritten as -1, and this class can be ignored in subsequent calculations; for non-infected persons with a characteristic value of -1, if they are continuously classified into the category of excluded risk during multiple iterations, it can be considered that under this confidence level, the characteristic value of the sample can be marked as -1, and these samples can be ignored in subsequent processes; wherein, the more iterations there are, the higher the confidence level that this class or this sample point can be excluded, and the fewer iterations there are, the lower the confidence level that this class can be excluded.
[0015] A multi-stage, gradually decreasing location-based close contact detection system for confirmed epidemic patients, characterized in that it includes: a user location data slicing module, which is used to collect user location data in a city within a day from map software, and slice the user location data from 8:00 to 22:00, wherein the slice is sliced once every T hours, and a total of 14 / T+1 time slices are set; a geographic location information clustering module, which is used to perform multi-stage, gradually decreasing residual K-means clustering according to the user location data in each time slice, and continuously ignores categories and samples that have been excluded from the risk of infection during the clustering process, thereby greatly reducing the time complexity of the clustering operation, making it possible to use a large-scale clustering algorithm to find close contacts; an infection probability discrimination module, for each time slice, the geographic location information clustering module will give samples with infection risks in the time slice, and the module will perform superposition based on the above data samples and give corresponding infection probabilities based on the frequency.
[0016] Since the present invention adopts the above technical scheme, it has the following advantages: 1. Based on the clustering needs of large-scale data, the present invention makes improvements based on the general clustering algorithm, and in accordance with the actual application needs, proposes a feasible clustering method in this scenario, namely residual K-means clustering. This method can exclude some clusters and some nodes by eliminating the data manually confirmed in multiple screenings to improve the calculation efficiency, so that the user location data can be fully utilized and the clustering speed is greatly improved. 2. The present invention is an effective prevention and control screening tool; for data providers, data warehouses can be used more effectively for mining in actual application scenarios; for users, authorized data sharing can have a clearer and more accurate assessment of their own action paths to take precautions and preparations. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] The attached figure shows the process of clustering using the residual K-means method. Each layer in the figure represents the result of continuing K-means clustering on the clustering results of some of the previous layers that have not eliminated risks. DETAILED DESCRIPTION
[0018] The present invention is described in detail below in conjunction with the accompanying drawings. However, it should be understood that the accompanying drawings are provided only for a better understanding of the present invention and should not be construed as limiting the present invention. In the description of the present invention, it should be understood that the terms "first", "second", etc. are only used for descriptive purposes and should not be construed as indicating or implying relative importance.
[0019] A brief explanation of the K-means clustering algorithm:
[0020] K-means algorithm refers to the K-means clustering algorithm, and its steps can be described as follows:
[0021] 1) Pre-select the cluster centers of K classes.
[0022] 2) For each sample point, calculate its distance to each cluster center, assign the sample point to the class with the shortest distance to the cluster center, and update the center value of the changed class.
[0023] 3) Continue to iterate in step 2) of the above K-means algorithm until each category no longer changes, and the iteration ends.
[0024] The K-means method is a simple and intuitive location-based clustering method. However, when faced with a large amount of data, it has great difficulties in calculation due to the need for continuous iteration.
[0025] The residual K-means algorithm proposed in the present invention can ignore this category and the sample points that definitely belong to this category in subsequent iterations when it is found that a confirmed patient is definitely not in a certain category. In the process of finding close contacts of confirmed patients, the residual K-means algorithm can discard the amount of calculation that can be discarded, thereby greatly improving the calculation speed and reducing the resource consumption of the K-means clustering algorithm. It is suitable for finding close contacts of confirmed patients.
[0026] The multi-stage location-based, progressively decreasing method for detecting close contacts of confirmed epidemic patients provided by the present invention includes the following contents:
[0027] 1) Collect the location data of users in a city within one day from a certain map software, slice the user location data from 8:00 to 22:00, slice it every T hours, and set 14 / T+1 time slices (time snapshots) in total. Among them, the number of slices is not fixed, and the number of time slices selected every day can be different according to the specific requirements of different cities. For example, for cities with more serious problems, it can be sliced once every half an hour, and a total of 30 time slices can be set every day. For cities with less serious problems, it can be sliced once every 1 hour, and a total of 15 slices can be set every day.
[0028] 2) Cluster each time slice. Each user is a sample point, and the sample points are divided into three categories: confirmed infected persons with a characteristic value of 1; unknown risk persons with a characteristic value of 0; and excluded risk persons with a characteristic value of -1. Classes are also divided into three types: risk class with a characteristic value of 1; unknown risk class with a characteristic value of 0; and excluded risk class with a characteristic value of -1. In each clustering, only one sample point with an initial characteristic value of 1 is given.
[0029] 3) Clustering is performed using the residual K-means method proposed in the present invention. First, according to the regional division or regional characteristics of the city, an initial category number K value is given, and all sample points are clustered according to the K-means method. At the beginning of clustering, the initial eigenvalues of all categories are 0, that is, the risk cannot be excluded. In the clustering process, for confirmed infected persons with an eigenvalue of 1, if they have never appeared in a certain category during multiple iterations, it can be considered that under this confidence level, the characteristics of this category can be rewritten as -1, and this category can be ignored in subsequent calculations. For non-sick persons with an eigenvalue of -1, if they are continuously classified in the category of excluding risks during multiple iterations, it can be considered that the eigenvalue of the sample can be marked as -1 under this confidence level, and these samples can be ignored in subsequent processes. Using this method, the amount of data that needs to be involved in the calculation can be continuously reduced, thereby greatly improving the calculation speed.
[0030] 4) Continue to perform residual K-means clustering on the remaining sample points. During the iteration process, the categories and samples that exclude risks are gradually ignored in the calculation, and the categories that cannot exclude risks are continuously clustered. When the clustering results remain unchanged, the iteration ends and the clustering is completed. The remaining sample points in the cluster cannot exclude the risk of close contact with confirmed patients. At this point, a large part of the initially existing nodes have been discarded, and it is precisely because of the continuous discarding of risk-excluded nodes that the residual K-means algorithm proposed in the present invention can meet the clustering requirements. For close contacts in each time slice, their infection probability can be determined based on frequency superposition.
[0031] In the above step 1), the user location data from 8:00 to 22:00 is sliced, wherein in each time slice, for a user m, its location can be represented by the location function l(m).
[0032] In the above step 3), the residual K-means method proposed in the present invention is used for clustering. In the clustering process, for a sample point m, its distance to each class needs to be calculated, and the sample point is divided into the class closest to it. The distance from the sample point m to the class n can be expressed as d = l(m) - l(c_n), where c represents the center of the class n.
[0033] In the above step 3), the residual K-means method proposed in the present invention is used for clustering. After each iteration, the center position of the class needs to be updated for the class that has changed in this iteration. The center of the class is calculated using the mean method. For example, for points A(x1,y1), B(x2,y2) and C(x2,y2), the center can be expressed as (x1+x2+x3) / 3 and (y1+y2+y3) / 3.
[0034] In the above step 3), during the clustering process, for confirmed infected persons with a characteristic value of 1, if they have never appeared in a certain category during multiple iterations, it can be considered that under this confidence level, the characteristics of this category can be rewritten as -1, and this category can be ignored in subsequent calculations. For non-infected persons with a characteristic value of -1, if they are continuously classified into the category of excluded risk during multiple iterations, it can be considered that the characteristic value of this sample can be marked as -1 under this confidence level, and these samples can be ignored in subsequent processes. Among them, the more iterations there are, the higher the confidence level that this category or this sample point can be excluded, and the fewer iterations there are, the lower the confidence level that this category can be excluded.
[0035] In the above step 4), during the iteration process, the categories that exclude risks are gradually ignored in the calculation, and the categories that cannot exclude risks are continuously clustered. When the clustering result remains unchanged, the iteration ends and the clustering is completed. This process can be understood as follows: for a known confirmed patient, the sample with a feature value of 1 will be classified into a certain category, then in the next clustering process, the clustering process in the above step 3) needs to be performed again for this category until the clustering result remains unchanged.
[0036] In step 4), during the iteration process, the categories that exclude risks are gradually ignored in the calculation, and the categories that cannot exclude risks are continuously clustered. When the clustering result remains unchanged, the iteration ends and the clustering is completed. In this clustering process, the number of nodes that need to participate in the clustering also decreases with the clustering process. When the clustering approaches termination, the node data tends to converge. The result after the clustering is that in the time slice, each confirmed patient and his close contacts at that moment.
[0037] In step 4), for close contacts in each time slice, their infection probability can be determined based on frequency superposition. For different time slices, if the same sample is judged to have a high frequency of infection risk in different time slices, it can be judged that its infection probability is high; if it is judged to have a low frequency of infection risk, it can be judged that the infection probability is relatively low.
[0038] The core idea of the residual K-means algorithm is to continuously discard classes and nodes that have been excluded from the risk during the clustering process. Since the infectious range of a confirmed patient is limited, in actual operation, a large part of the nodes can be ignored in this process, so that the amount of data involved in the calculation can be reduced as much as possible, which can greatly improve the operation speed of the clustering algorithm. Compared with a general spatiotemporal clustering algorithm, the calculation speed may not be so fast, or even unsolvable. However, for such a deterministic problem, that is, finding close contacts of confirmed patients, the residual K-means algorithm can greatly improve the speed of clustering by discarding nodes and classes that can be discarded, and has a high technical advantage. In this scenario, it is feasible to cluster using the residual K-means algorithm proposed in the present invention.
[0039] Based on the above-mentioned location-based multi-stage and gradually decreasing method for detecting close contacts of confirmed epidemic patients, the present invention also provides a location-based multi-stage and gradually decreasing system for detecting close contacts of confirmed epidemic patients, including: a user location data slicing module, used to collect the location data of users in a city within one day from a certain map software, and slice the user location data from 8:00 to 22:00, wherein the slice is sliced once every T hours, and a total of 14 / T+1 time slices are set; a geographic location information clustering module, used to perform the multi-stage and gradually decreasing residual K-means clustering proposed by the present invention according to the user location data in each time slice, by continuously ignoring the categories and samples that have been excluded from the infection risk during the clustering process, thereby greatly reducing the time complexity of the clustering operation, making it possible to find close contacts using a large-scale clustering algorithm; an infection probability discrimination module, for each time slice, the geographic location information clustering module will give a sample with an infection risk under the time slice, and the module will perform superposition based on the above data samples and give a corresponding infection probability based on the frequency.
[0040] The above embodiments are only used to illustrate the present invention, wherein the structure, connection mode and manufacturing process of each component may be changed. Any equivalent transformations and improvements based on the technical solution of the present invention should not be excluded from the protection scope of the present invention.
Claims
1. A location-based multi-stage and progressively decreasing method for detecting close contacts of confirmed epidemic patients, characterized in that: Includes the following: 1) Collect the user's location data in a city within a day from the map software, slice the user's location data from 8:00 to 22:00, and T Slice once every hour, a total of 14 / T + 1 time slice. The number of slices is not fixed. According to the specific requirements of different cities, the number of time slices selected each day varies accordingly. For cities with more serious diseases, a slice is selected every half an hour, with a total of 30 slices set per day. For cities with less serious diseases, a slice is selected every 1 hour, with a total of 15 slices set per day. 2) Cluster each time slice, with each user as a sample point. The sample points are divided into three categories: confirmed infected persons with a feature value of 1; Those with unknown risk whose eigenvalue is 0; For those with an eigenvalue of -1, the class of excluded risk is also divided into three types: the class of existing risk with an eigenvalue of 1; The risk unknown class has a feature value of 0; The risk class with an eigenvalue of -1 is excluded, and only one sample point with an initial eigenvalue of 1 is given in each clustering; 3) Use the residual K-means method for clustering. First, according to the regional division or regional characteristics of the city, an initial category number K value is given, and all sample points are clustered according to the residual K-means method. At the beginning of clustering, the initial eigenvalues of all categories are 0, that is, the risk cannot be excluded. In the clustering process, for confirmed infected persons with an eigenvalue of 1, if they have never appeared in a certain category during multiple iterations, it can be considered that under this eigenvalue, the characteristics of this category can be rewritten as -1, and this category can be ignored in subsequent calculations. For non-infected persons with an eigenvalue of -1, if they are continuously classified in the category of excluded risk during multiple iterations, it can be considered that the eigenvalue of the sample under this eigenvalue can be marked as -1, and these samples can be ignored in subsequent processes. Using this method, the amount of data required to participate in the calculation can be continuously reduced; 4) Continue to perform residual K-means clustering on the remaining sample points. During the iteration process, the categories and samples that exclude risks are gradually ignored in the calculation, and the categories that cannot exclude risks are continuously clustered. When the clustering result remains unchanged, the iteration ends and the clustering is completed. The remaining sample points in the cluster cannot exclude the risk of close contact with confirmed patients. At this time, a large part of the initial nodes have been discarded. It is precisely because of the continuous discarding of excluded risk nodes that the residual K-means algorithm can meet the clustering requirements. For close contacts in each time slice, their infection probability can be determined based on frequency superposition.
2. A location-based multi-stage, progressively decreasing method for detecting close contacts of confirmed epidemic patients as claimed in claim 1, characterized in that: In step 1), the user location data from 8:00 to 22:00 is sliced, wherein in each time slice, for a user m , whose position can be expressed using the position function l ( m ) is used to indicate.
3. A location-based multi-stage and progressively decreasing method for detecting close contacts of confirmed epidemic patients as claimed in claim 1, characterized in that: In step 3), the residual K-means method is used for clustering. During the clustering process, for the sample points m , it is necessary to calculate the distance to each class and divide the sample point into the class closest to it. m To Class n The distance can be expressed as d = l ( m )- l ( c _ n ),in, c Representation Class n center.
4. A location-based multi-stage, progressively decreasing method for detecting close contacts of confirmed epidemic patients as claimed in claim 1, characterized in that: In step 3), the residual K-means method is used for clustering. After each iteration, the center position of the class needs to be updated for the class that has changed in this iteration. The center of the class is calculated using the mean method. A ( x 1, y 1) B ( x 2, y 2) and C ( x 3, y 3), the center can be expressed as ( x 1 + x 2 + x 3) / 3 and ( y 1 + y 2 + y 3) / 3.
5. A location-based multi-stage and progressively decreasing method for detecting close contacts of confirmed epidemic patients as claimed in claim 1, characterized in that: In the step 3), during the clustering process, for confirmed infected persons with an eigenvalue of 1, if they have never appeared in a certain class during multiple iterations, it can be considered that under this eigenvalue, the characteristic of this class can be rewritten as -1, and this class can be ignored in subsequent calculations. For non-infected persons with an eigenvalue of -1, if they are continuously classified into the category of excluded risk during multiple iterations, it can be considered that the eigenvalue of this sample under this eigenvalue can be marked as -1, and these samples can be ignored in subsequent processes; wherein, the more iterations there are, the higher the confidence that this class or this sample point can be excluded, and the fewer iterations there are, the lower the confidence that this class can be excluded.
6. A location-based multi-stage and progressively decreasing system for detecting close contacts of confirmed epidemic patients, characterized in that: include: The user location data slicing module is used to collect the user's location data in a city within a day from the map software, and slice the user location data from 8:00 to 22:00, where every T Slice once every hour, a total of 14 / T + 1 time slice; The geographic location information clustering module is used to perform multi-stage, successively reduced residual K-means clustering based on the user location data in each time slice. By continuously ignoring categories and samples that have been excluded from the risk of infection during the clustering process, the time complexity of the clustering operation is greatly reduced, making it possible to use large-scale clustering algorithms to find close contacts; Infection probability identification module, for each time slice, the geographic location information clustering module will give samples with infection risks in that time slice. This module will superimpose the samples with infection risks and give the corresponding infection probability based on the frequency.
Citation Information
Patent Citations
Disease prevention and treatment method and system
CN102043895A
Infectious disease prevention and control method and system
CN107256327A