Method for determining crowd gathering

By combining angle parameters and distance parameters, the deep convolutional neural network is used to obtain the coordinates of the center point of the person's head, and the aggregation judgment error caused by the difference between the two-dimensional image and the three-dimensional distance is solved, and accurate crowd aggregation judgment is achieved under various scene types. , reducing dependence and cost on external information.

CN119169526APending Publication Date: 2024-12-20CHONGQING TELECOM SYST INTEGRATION CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411229481.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-03
Publication Date
2024-12-20

AI Technical Summary

Technical Problem

When judging the clustering of people, the existing technology cannot accurately judge the clustering of people in the distance in the two-dimensional image and the real distance in the three-dimensional space, and relying on external tools such as satellite information or detection boxes, the cost is Higher and inefficient.

Method used

By introducing angle parameters and distance parameters, the deep convolutional neural network is used to obtain the coordinates of the center point of the person's head, classify and cluster, calculate the Euclidean distance and radiation distance, adjust the parameters to achieve the best classification effect, and directly from the monitoring screen judging the crowds gather.

Benefits of technology

Accurately judge the crowd gathering under various scene types (distance, medium view, close view, panoramic view), without external information, reducing costs, and improving judgment accuracy and reliability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119169526A_ABST
    Figure CN119169526A_ABST
Patent Text Reader

Abstract

The invention relates to the field of computer image processing, in particular to a method for judging crowd gathering, which comprises the following steps of: 1) determining calibration values of a distance parameter and an angle parameter in a target scene through a calibration test; 2) obtaining head center point coordinates of all personnel in a target scene, and forming a personnel data set corresponding to the target scene; 3) classifying all the personnel according to the calibration values of the distance parameters and the angle parameters and the head center point coordinates of all the personnel, and dividing the personnel data set into a plurality of personnel category sets; and 4) counting the number of people in each people category set, and comparing the number with a preset number threshold to judge whether people in each people category set have a crowd gathering condition or not. According to the method, the problem that the difference exists between the picture distance and the real distance is effectively solved by introducing the angle parameter, and the small target crowd gathering condition in the long-shot scene can be accurately distinguished.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of computer image processing, and in particular to a method for judging crowd gathering. Background Art

[0002] By setting up cameras in public places such as stations, squares, and parks to capture real-time images of the monitored area, and then using deep learning algorithms to obtain the number of people in the specified area of ​​the image, it is possible to determine in advance whether a large-scale crowd gathering will occur, which helps prevent stampedes, terrorist attacks, and other incidents that endanger public safety.

[0003] However, in actual applications, it is found that the current methods for judging crowd gathering have the following problems:

[0004] ① Only by analyzing the distance between each person in the two-dimensional image, and then clustering people according to the different distances, the actual distribution of the crowd is determined. The existing technology ignores the problem that "the distance between each person in the two-dimensional image is different from the actual distance in the three-dimensional space", resulting in the inability of the existing technology to accurately determine whether there is a crowd gathering when the scene is a distant view or a panoramic view (that is, the judgment result is inconsistent with the actual situation);

[0005] ② It is necessary to rely on other tools (such as satellites) to combine other information (such as GPS information provided by satellites) with the two-dimensional images taken by surveillance cameras to determine the crowd gathering situation in the target scene. For example, the "A method, device, equipment and storage medium for identifying crowd gathering points" with the publication number CN117351431A uses additional GPS information as a basis for judgment to determine the gathering center, and then performs neighboring clustering processing based on the gathering center to obtain the crowd clustering area. Compared with ordinary crowd gathering methods, the cost is relatively high. Once accurate GPS information cannot be obtained, the clustering results will inevitably be greatly affected;

[0006] ③ It is necessary to predict two pairs of coordinate values ​​through the detection algorithm to determine the external frame of the target person, and calculate the distance between people based on the size of the detection frame and the internal parameter matrix of the camera, so that the crowd can be divided into different sets. For example, "A Crowd Gathering Detection Method, Device, Storage Medium and Virus Disinfection Equipment" with publication number CN117522979A. The premise for the implementation of this method is to first be able to effectively obtain the person detection frame. This crowd gathering detection algorithm can only effectively obtain the person detection frame when the scene of the real-time picture is medium or close-up. If the proportion of the target person in the two-dimensional image is too small, it will be difficult to obtain the person detection frame. Therefore, if the scene is a distant view or a panoramic view, this crowd gathering detection algorithm cannot use the person detection frame to judge the crowd gathering.

[0007] How to solve the problem in the prior art that "due to the difference between the distance between each person in the two-dimensional image and the actual distance in the three-dimensional space, it is impossible to accurately judge the crowd gathering situation in the distance", while minimizing the cost and not relying on other information except the monitoring screen, so that the crowd gathering situation can be accurately judged when the target scene is panoramic. This has always been a problem that technical personnel in this field need to solve urgently. Summary of the invention

[0008] The purpose of the present invention is to provide a method for judging crowd gathering in view of the corresponding shortcomings of the prior art. By introducing angle parameters, the problem of "difference between picture distance and real distance" is effectively solved, and the gathering of small target people in distant scenes can be accurately distinguished.

[0009] The object of the present invention is to achieve the following scheme: A method for judging crowd gathering, comprising the following steps:

[0010] 1) Determine the calibration values ​​of the distance parameters and angle parameters of the target scene through calibration tests;

[0011] 2) Obtain the coordinates of the center points of the heads of all persons in the target scene to form a person data set corresponding to the target scene;

[0012] 3) Classifying all persons in the person data set according to the calibration value described in step 1) and the coordinates of the center point of the head of each person in the target scene, and dividing the person data set into a plurality of person category sets;

[0013] 4) Count the number of people in each personnel category set, and compare it with the preset number threshold to determine whether there is a crowd gathering in each personnel category set.

[0014] Preferably, in step 1), the distance parameter and angle parameter calibration values ​​corresponding to the target scene are obtained as follows:

[0015] 1-1) Set the preset value of the angle parameter corresponding to the target scene to 0, and the preset value of the distance parameter to 10 pixels;

[0016] 1-2) Obtain the coordinates of the center points of the heads of all persons in the target scene to form a person data set corresponding to the target scene;

[0017] 1-3) Classify all persons in the person data set according to the current distance parameter, angle parameter, and the coordinates of the center point of the head of each person in the target scene, and divide the person data set into multiple person category sets;

[0018] 1-4) Determine the effect of using the current preset values ​​of the distance parameter and the angle parameter to classify all persons in the personnel data set, and readjust the distance parameter according to the distance modification step, repeat steps 1-3) until it is manually determined that the classification effect at this time is optimal in the target scene, and record the distance parameter value when the classification effect is optimal as the distance parameter calibration value;

[0019] 1-5) Use the distance parameter calibration value as the distance parameter preset value, adjust the angle parameter preset value according to the angle modification step, repeat steps 1-3) until it is manually judged that the classification effect at this time is optimal in the target scene, and record the angle parameter value when the classification effect is optimal as the angle parameter calibration value.

[0020] Preferably, the coordinates of the center points of all people's heads in the target scene are acquired in real time by a deep convolutional neural network model.

[0021] Preferably, the deep convolutional neural network model includes P2PNet and FIDTM.

[0022] Preferably, all persons in the personnel data set are classified, and the specific manner of dividing the personnel data set into a plurality of personnel category sets is as follows:

[0023] 3-1) Re-sort the persons in the person data set according to the ascending order of the ordinate of the head center point of each person in the target scene to determine the order of person classification processing;

[0024] 3-2) According to the personnel classification processing order determined in step 3-1), the person with the smallest vertical coordinate of the center point of the head in the personnel data set is taken as the central node, and the remaining persons in the personnel data set are taken as neighbor nodes of the central node, and the Euclidean distance between each neighbor node and the central node is calculated respectively;

[0025] 3-3) Determine the Euclidean distance between each neighbor node and the central node, as well as the magnitude relationship of the radiation distance corresponding to the central node, and classify each neighbor node according to the magnitude relationship:

[0026] If the Euclidean distance between a neighbor node and the central node is less than the radiation distance corresponding to the central node, the neighbor node is determined to belong to the same personnel category set as the central node, and the neighbor node is removed from the personnel data set;

[0027] If the Euclidean distance between a neighbor node and the central node is ≥ the radiation distance corresponding to the central node, it is determined that the neighbor node and the central node do not belong to the same personnel category set, and the neighbor node is retained in the personnel data set to participate in the next classification process;

[0028] 3-4) Repeat steps 3-1) to 3-3) until all persons in the personnel data set are classified into corresponding personnel category sets.

[0029] Preferably, the calculation formula of the central node radiation distance is as follows:

[0030] R k =d+y k ×θ

[0031] In the formula, R k is the radiation distance corresponding to the kth central node in the personnel data set, d is the distance parameter, and y k It is the ordinate of the center point of the head of the kth person in the personnel data set when the person is the central node, and θ is the angle parameter.

[0032] Preferably, in step 3-3), the Euclidean distance between each neighbor node and the central node is calculated according to the following formula:

[0033]

[0034] Where D k , i is the Euclidean distance between the i-th neighbor node and the central node when the k-th person in the personnel data set is the central node, x k is the horizontal coordinate of the center point of the head of the kth person in the personnel data set when the person is the central node, y k is the ordinate of the center point of the head of the kth person in the personnel data set when the person is the central node, x i is the horizontal coordinate of the i-th neighbor node when the k-th person in the personnel data set is the central node, y i It is the ordinate of the ith neighbor node when the kth person in the personnel dataset is the central node.

[0035] The advantages of the present invention are the following three points:

[0036] (1) The present invention is different from the prior art in that it does not need to obtain a person detection frame, but directly uses the coordinates of the center point of the target person's head to judge the gathering of people in various target scenes. Therefore, regardless of whether the scene is a distant view, a mid-range view, a close-up view, or a panoramic view, even if the proportion of the target person in the picture is very small, the present invention can accurately obtain the coordinates of the center point of the head of each target person on the two-dimensional image corresponding to the target scene. This is the premise for the present invention to accurately judge the gathering of people in various target scenes.

[0037] (2) The present invention introduces an angle parameter and combines it with a distance parameter to effectively solve the problem that "the distance between each person in the two-dimensional image and the real distance in the three-dimensional space is different, which makes it impossible to accurately judge the crowd gathering in the distant view". The present invention can accurately judge the crowd gathering in the near view, the middle view, and the distant view. Even when the scene size of the target scene is a panoramic view, the present invention can accurately judge the crowd gathering.

[0038] (3) The present invention does not rely on other tools (such as satellites) or other information (such as GPS information provided by satellites). It only needs the two-dimensional image captured by the monitoring camera. The present invention can accurately determine the crowd gathering situation of the target scene. Therefore, the present invention has low cost and is not restricted by other external information (information other than the two-dimensional image of the target scene).

[0039] Glossary

[0040] Distance parameter: The distance threshold used to determine whether two people belong to the same classification set. It can be understood as the Euclidean distance between the center points of the two people's heads. For example, for point A (x1, y1) and point B (x2, y2), the Euclidean distance between the two is:

[0041]

[0042] Without considering the angle problem, when the distance between point A and point B is less than the distance parameter, it is considered that the two persons represented by point A and point B belong to the same set.

[0043] Angle parameter: a parameter used to perform weighted processing on the distance between the center points of a person's head. Due to the angle tilt of the camera, the situation of "near is big and far is small" will appear. For example, assuming that point A and point B are both closer to the camera in real space, while point C and point D are both farther away from the camera in real space, and the distance between point A and point B on the image is equal to the distance between point C and point D on the image, then in real space, the distance between point A and point B is smaller than the distance between point C and point D. Assuming that the distance deviation caused by the angle tilt of the camera is not considered, and the classification set of personnel is divided only based on the "distance parameter", the final classification result will have serious errors. Therefore, the present invention sets an angle parameter to participate in the calculation of the radiation distance, and adjusts the deviation caused by the angle tilt of the camera by multiplying it with the vertical coordinate of the center point of the person's head, so that the final classification result is more accurate.

[0044] P2Pnet: Rethinking Counting and Localization in Crowds: APurelyPoint-Based Framework, a deep convolutional neural network model, is mainly used for crowd counting and positioning tasks. P2PNet abandons the traditional method of complex bounding box annotation or region division of the target, and instead regards each individual in the crowd as a point, and achieves counting and positioning by learning and analyzing the features of these points. This point-based representation greatly simplifies the complexity of the problem and can more directly capture the location information of individuals in the crowd.

[0045] FIDTM: refers to Focal Inverse Distance Transform Maps for Crowd Localization and Counting in Dense Crowd, which is a deep convolutional neural network model. This model mainly focuses on solving the problem of crowd positioning and counting in dense crowd scenes. Its core is to use focal inverse distance transform maps (Focal Inverse Distance Transform Maps) to more accurately represent the positional relationship of individuals in the crowd and the distance information to other related points, so as to improve the accuracy of positioning individuals in dense crowds and achieve more accurate crowd counting. Through this unique method, FIDTM can better handle positioning and counting tasks in complex situations such as dense crowds and severe occlusion, overcoming the limitations of traditional methods in these aspects.

[0046] Head center point coordinates: A two-dimensional coordinate system is established on the image formed by the real-time monitoring screen shot by the camera in the target scene. The coordinate value of each person's head in this two-dimensional coordinate system is called the head center point coordinates. Figure 2 As shown, the coordinates of point A in the image are (x1, y1), which means: a plane rectangular coordinate system is constructed with the upper left corner of the image as the origin, the horizontal rightward direction as the positive direction of the X axis, and the vertical downward direction as the positive direction of the Y axis. The distance of point A relative to the origin on the X axis is x1 pixels, and the distance on the Y axis is y1 pixels.

[0047] Pixel: Pixel is the basic unit of image display.

[0048] Close scene: refers to the scene in the two-dimensional image that is closer to the surveillance camera.

[0049] Distant scene: refers to the scene in the two-dimensional image that is far away from the surveillance camera.

[0050] Medium shot: refers to the scene in a two-dimensional image whose distance from the surveillance camera is between the near shot and the far shot.

[0051] Panorama: refers to a two-dimensional image that includes both the near shot, the mid shot and the far shot. BRIEF DESCRIPTION OF THE DRAWINGS

[0052] Figure 1 is a flow chart of the present invention;

[0053] Figure 2 A schematic diagram of the head center point coordinates according to the present invention;

[0054] Figure 3 This is a schematic diagram of the effect of performing crowd gathering detection on a target scene after introducing angle parameters in an embodiment of the present invention;

[0055] Figure 4 It is a schematic diagram of the effect of performing crowd gathering detection on a target scene without considering the camera angle problem in an embodiment of the present invention;

[0056] Figure 5 This is a schematic diagram of the effect of performing crowd gathering detection on the target scene in an embodiment of the present invention using the technical solution disclosed in "A crowd gathering detection method, device, storage medium and virus disinfection equipment" with publication number CN117522979A. DETAILED DESCRIPTION

[0057] like Figure 1 As shown, a method for determining crowd gathering includes the following steps:

[0058] 1) Determine the calibration values ​​of the distance parameters and angle parameters in the target scene through calibration tests in the following manner:

[0059] 1-1) Set the preset value of the angle parameter corresponding to the target scene to 0, and the preset value of the distance parameter to 10 pixels;

[0060] 1-2) Obtain the coordinates of the center points of the heads of all persons in the target scene to form a person data set corresponding to the target scene;

[0061] 1-3) Classify all persons in the person data set according to the current distance parameter, angle parameter, and the coordinates of the center point of the head of each person in the target scene, and divide the person data set into multiple person category sets;

[0062] 1-4) Determine the effect of using the current preset values ​​of the distance parameter and the angle parameter to classify all persons in the personnel data set, and readjust the distance parameter according to the distance modification step, repeat steps 1-3) until it is manually determined that the classification effect at this time is optimal in the target scene, and record the distance parameter value when the classification effect is optimal as the distance parameter calibration value;

[0063] 1-5) Use the distance parameter calibration value as the distance parameter preset value, adjust the angle parameter preset value according to the angle modification step, repeat steps 1-3) until it is manually judged that the classification effect at this time is optimal in the target scene, and record the angle parameter value when the classification effect is optimal as the angle parameter calibration value.

[0064] The distance modification step size and angle modification step size are both empirical values.

[0065] In this step, it is particularly important to note that when dividing the personnel in the personnel data set into different personnel category sets, the quality of the division results depends on the setting of the classification parameters. The classification parameters in this embodiment include distance parameters and angle parameters. For different scenes, due to the different tilt angles and installation heights of the camera, the optimal values ​​of the classification parameters will also be different.

[0066] In order to further ensure the correct selection of classification parameters, the classification parameters obtained in the manner described in step 1) may be fine-tuned again to reduce the mutual influence between the two different classification parameters, the distance parameter and the angle parameter, and obtain the best classification effect:

[0067] ① Set the distance fine-tuning step to 1 pixel and the angle fine-tuning step to 0.01°. The distance fine-tuning step and the angle fine-tuning step are both empirical values.

[0068] ②Adjust the distance parameter and angle parameter simultaneously according to the distance fine-tuning step and angle fine-tuning step, for example:

[0069] Distance parameter d0: d0-9, d0-8, …, d0, d0+1, d0+2, …, d0+9;

[0070] Angle parameter θ0: θ0-0.09, θ0-0.08, …, θ0, θ0+0.01, θ0+0.02, …, θ0+0.09;

[0071] ③ According to the fine-tuned distance parameters, angle parameters, and the coordinates of the center point of the head of each person in the target scene, all persons in the personnel data set are classified and the personnel data set is divided into multiple personnel category sets;

[0072] ④ Repeat steps ②-③ until the classification effect is optimal under human judgment in the target scene, and record the classification parameter value when the classification effect is optimal as the classification parameter calibration value;

[0073] In this embodiment, the classification parameters are calibrated in the above manner, and it can be finally determined that when the distance parameter calibration value is 30 pixels and the angle parameter calibration value is 0.069° under the target scene, the judgment effect on this target scene is the best.

[0074] 2) In the actual application process, a two-dimensional image of the target scene is obtained through a camera, and a neural network model is used to obtain the coordinates of the center points of the heads of all people in the two-dimensional image to form a personnel data set corresponding to the target scene. In this embodiment, the coordinates of the center points of the heads of all people in the target scene are obtained in real time by a deep convolutional neural network model, and the deep convolutional neural network model can use P2PNet or FIDTM. Regardless of whether the scene is a distant view, a mid-range view, a close view, or a panoramic view, even if the proportion of the target person in the picture is very small, these deep convolutional neural network models can still accurately obtain the coordinates of the center points of the heads of each target person in the two-dimensional image of the target scene, and then use these coordinates to judge the gathering of the crowd.

[0075] 3) According to the calibration values ​​of the distance parameters and angle parameters in the target scene, and the coordinates of the center point of the head of each person in the target scene, all persons in the person data set are classified, and the person data set is divided into multiple person category sets;

[0076] 4) Count the number of people in each personnel category set, and compare it with the preset number threshold to determine whether there is a crowd gathering in each personnel category set.

[0077] The setting of the number threshold depends on the needs of the user: when the space of the application scene is relatively narrow or the control rules are relatively strict, a smaller number threshold can be set; when the space of the application scene is relatively wide or the control rules are relatively loose, a larger number threshold can be set. In this embodiment, the number threshold is set to 10. That is to say, if the number of people in a certain personnel category set exceeds 10, the computer will automatically determine that there is a crowd gathering in the target scene.

[0078] It is worth noting that in this embodiment, whether in the calibration test or in the actual application scenario, the process of classifying all persons in the personnel data set is involved. In this embodiment, all persons in the personnel data set are classified and the specific method of dividing the personnel data set into multiple personnel category sets is as follows:

[0079] 3-1) Re-sort the persons in the person data set according to the ascending order of the ordinate of the head center point of each person in the target scene to determine the order of person classification processing;

[0080] This is because when the surveillance camera is tilted, the smaller the vertical coordinate of the center point of the head, the farther the person is from the camera in three-dimensional space. Therefore, when classifying, we should give priority to the person who is farthest from the camera in three-dimensional space. If we give priority to the person who is closest to the camera in three-dimensional space, it will cause misjudgment, and even lead to the wrong conclusion that all the people in the entire target scene and the person closest to the camera belong to the same group.

[0081] 3-2) According to the personnel classification processing order determined in step 3-1), the person with the smallest vertical coordinate of the center point of the head in the personnel data set is taken as the central node, and the remaining persons in the personnel data set are taken as the neighbor nodes of the central node, and the Euclidean distance between each neighbor node and the central node is calculated according to the following formula:

[0082]

[0083] Where D k , i is the Euclidean distance between the i-th neighbor node and the central node when the k-th person in the personnel data set is the central node, x k is the horizontal coordinate of the center point of the head of the kth person in the personnel data set when the person is the central node, y k is the ordinate of the center point of the head of the kth person in the personnel data set when the person is the central node, x i is the horizontal coordinate of the i-th neighbor node when the k-th person in the personnel data set is the central node, y i It is the ordinate of the ith neighbor node when the kth person in the personnel dataset is the central node.

[0084] 3-3) Determine the Euclidean distance between each neighbor node and the central node, as well as the magnitude relationship of the radiation distance corresponding to the central node, and classify each neighbor node according to the magnitude relationship:

[0085] If the Euclidean distance between a neighbor node and the central node is less than the radiation distance corresponding to the central node, the neighbor node is determined to belong to the same personnel category set as the central node, and the neighbor node is removed from the personnel data set;

[0086] If the Euclidean distance between a neighbor node and the central node is ≥ the radiation distance corresponding to the central node, it is determined that the neighbor node and the central node do not belong to the same personnel category set, and the neighbor node is retained in the personnel data set to participate in the next classification process;

[0087] The calculation formula of the central node radiation distance in this embodiment is as follows:

[0088] R k =d+yk ×θ

[0089] In the formula, R k is the radiation distance corresponding to the kth central node in the personnel data set, d is the distance parameter, and y k It is the ordinate of the center point of the head of the kth person in the personnel data set when the person is the central node, and θ is the angle parameter.

[0090] 3-4) Repeat steps 3-1) to 3-3) until all persons in the personnel data set are classified into corresponding personnel category sets.

[0091] In this embodiment, Figure 3 This is a schematic diagram of the judgment result of the crowd gathering situation in the target scene when the distance parameter calibration value is 30 pixels and the angle parameter calibration value is 0.069 degrees using the above method. Figure 4 This is a schematic diagram of the judgment results of the crowd gathering situation in the same target scene when the camera angle problem is not considered (that is, the angle parameter is 0). Figure 5 It is a schematic diagram of the effect of detecting crowd gatherings in the target scene in an embodiment of the present invention according to the technical solution disclosed in "A crowd gathering detection method, device, storage medium and virus disinfection equipment" with publication number CN117522979A.

[0092] By comparison, it can be found that although the technical solution with publication number CN117522979A can effectively classify people in the near and medium shots, for the distant shots, the proportion of the human head target in the picture is too small, so it is difficult to obtain the detection frame, and thus it is impossible to accurately classify the distant shots, and it is impossible to accurately judge the gathering of people in the distant shots. Figure 4 Although it is possible to judge the gathering of people in the near distance, the effect of the camera angle on the classification effect is not taken into account. When the distance parameter is set to 78, the classification effect is the best, and it is impossible to effectively judge the gathering of people in the far distance. This is because the same distance in three-dimensional space will appear "larger near and smaller far" in the camera image. Conversely, the same distance in the camera image will appear "smaller near and larger far" in three-dimensional space. Figure 4 Although the distance parameter can meet the classification effect of people in the near scene, it cannot accurately classify people in the far scene, and cannot accurately judge the gathering of people in the far scene (for example, several people who are not gathered together are judged as a group of people gathered together). Figure 3As shown, the present invention introduces angle parameters, and can classify people in the near view, middle view, and far view at the same time, so as to accurately determine their gathering situation. By using the technical solution of the present invention, large-scale crowd gatherings in abnormal time periods or sudden events can be identified in the shopping mall area, and timely responses can be made, which greatly ensures the safety of the target scene in the monitoring area.

[0093] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modification made to the present invention by those skilled in the art without departing from the spirit of the present invention shall fall within the protection scope of the present invention.

Claims

1. A method for determining crowd gathering, characterized in that: The following steps are involved: 1) Determine the calibration values ​​of the distance parameters and angle parameters of the target scene through calibration tests; 2) Obtain the coordinates of the center points of the heads of all persons in the target scene to form a person data set corresponding to the target scene; 3) Classifying all persons in the person data set according to the calibration value described in step 1) and the coordinates of the center point of the head of each person in the target scene, and dividing the person data set into a plurality of person category sets; 4) Count the number of people in each personnel category set, and compare it with the preset number threshold to determine whether there is a crowd gathering in each personnel category set.

2. The method for determining crowd gathering according to claim 1, characterized in that: In step 1), the distance parameter and angle parameter calibration values ​​corresponding to the target scene are obtained as follows: 1-1) Set the preset value of the angle parameter corresponding to the target scene to 0, and the preset value of the distance parameter to 10 pixels; 1-2) Obtain the coordinates of the center points of the heads of all persons in the target scene to form a person data set corresponding to the target scene; 1-3) Classify all persons in the person data set according to the current distance parameter, angle parameter, and the coordinates of the center point of the head of each person in the target scene, and divide the person data set into multiple person category sets; 1-4) Determine the effect of using the current preset values ​​of the distance parameter and the angle parameter to classify all persons in the personnel data set, and readjust the distance parameter according to the distance modification step, repeat steps 1-3) until it is manually determined that the classification effect at this time is optimal in the target scene, and record the distance parameter value when the classification effect is optimal as the distance parameter calibration value; 1-5) Use the distance parameter calibration value as the distance parameter preset value, adjust the angle parameter preset value according to the angle modification step, repeat steps 1-3) until it is manually judged that the classification effect at this time is optimal in the target scene, and record the angle parameter value when the classification effect is optimal as the angle parameter calibration value.

3. The method for determining crowd gathering according to claim 1 or 2, characterized in that: The coordinates of the center points of all people's heads in the target scene are acquired in real time by a deep convolutional neural network model.

4. The method for determining crowd gathering according to claim 3, characterized in that: The deep convolutional neural network model includes P2PNet and FIDTM.

5. The method for determining crowd gathering according to claim 1 or 2, characterized in that: The specific method of classifying all persons in the personnel data set and dividing the personnel data set into multiple personnel category sets is as follows: 3-1) Re-sort the persons in the person data set according to the ascending order of the ordinate of the head center point of each person in the target scene to determine the order of person classification processing; 3-2) According to the personnel classification processing order determined in step 3-1), the person with the smallest vertical coordinate of the center point of the head in the personnel data set is taken as the central node, and the remaining persons in the personnel data set are taken as neighbor nodes of the central node, and the Euclidean distance between each neighbor node and the central node is calculated respectively; 3-3) Determine the Euclidean distance between each neighbor node and the central node, as well as the magnitude relationship of the radiation distance corresponding to the central node, and classify each neighbor node according to the magnitude relationship: If the Euclidean distance between a neighbor node and the central node is less than the radiation distance corresponding to the central node, the neighbor node is determined to belong to the same personnel category set as the central node, and the neighbor node is removed from the personnel data set; If the Euclidean distance between a neighbor node and the central node is ≥ the radiation distance corresponding to the central node, it is determined that the neighbor node and the central node do not belong to the same personnel category set, and the neighbor node is retained in the personnel data set to participate in the next classification process; 3-4) Repeat steps 3-1) to 3-3) until all persons in the personnel data set are classified into corresponding personnel category sets.

6. The method for determining crowd gathering according to claim 5, characterized in that: The calculation formula of the central node radiation distance is as follows: R k =d+y k ×θ In the formula, R k is the radiation distance corresponding to the kth central node in the personnel data set, d is the distance parameter, and y k It is the ordinate of the center point of the head of the kth person in the personnel data set when the person is the central node, and θ is the angle parameter.

7. The method for determining crowd gathering according to claim 5, characterized in that: In step 3-3), the Euclidean distance between each neighbor node and the central node is calculated according to the following formula: Where D k , i is the Euclidean distance between the i-th neighbor node and the central node when the k-th person in the personnel data set is the central node, x k is the horizontal coordinate of the center point of the head of the kth person in the personnel data set when the person is the central node, y k is the ordinate of the center point of the head of the kth person in the personnel data set when the person is the central node, x i is the horizontal coordinate of the i-th neighbor node when the k-th person in the personnel data set is the central node, y i It is the ordinate of the ith neighbor node when the kth person in the personnel dataset is the central node.