Activity situation real-time analysis method and system based on two-dimensional and three-dimensional integration
By integrating CIM and BIM data to construct a three-dimensional spatial voxel grid, permeability and particle density are calculated to assess congestion risk and plan evacuation routes. This solves the problem that traditional two-dimensional analysis methods cannot accurately assess three-dimensional spatial congestion risk, and enables precise analysis and intelligent early warning for complex locations.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- HUBEI JIFANG TECH CO LTD
- Filing Date
- 2026-01-13
- Publication Date
- 2026-05-01
AI Technical Summary
Existing technologies cannot accurately analyze and predict the flow of people and potential congestion risks in three-dimensional space. They ignore the geometric constraints of three-dimensional space, making it impossible to accurately assess the congestion risks in complex locations.
A real-time activity status analysis method based on two-dimensional and three-dimensional integration is adopted. By acquiring CIM basic geographic data and BIM building models, a three-dimensional spatial voxel mesh is generated, geometric permeability and particle density are calculated, a three-dimensional guided traffic map is constructed, and congestion risk assessment is carried out using back pressure conduction and potential energy field, and evacuation routes are planned.
It enables precise analysis and intelligent early warning of the flow of people in three-dimensional space, and can provide early warning of potential congestion risks, thereby improving the safety management capabilities and emergency response efficiency of large event venues.
Smart Images

Figure CN121960153A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of visual analysis, and more particularly to a method and system for real-time analysis of activity status based on two-dimensional and three-dimensional integration. Background Technology
[0002] With the acceleration of urbanization and the increasing frequency of large-scale public events, the security management of large event venues faces unprecedented challenges. These venues typically have complex three-dimensional spatial structures, including multi-level grandstands, multi-level transportation hubs, and underground passages, with pedestrian flow exhibiting significant three-dimensional characteristics. Meanwhile, modern security systems are equipped with numerous sensing devices, such as video surveillance cameras, GPS positioning systems, and turnstiles, which can collect dynamic data such as personnel location and movement trajectories in real time.
[0003] Existing technologies mainly employ two-dimensional map visualization methods, directly marking the location data of people collected by sensors onto a flat map. They then use heat maps, trajectory lines, and other methods to display the distribution and movement trends of the population, and assess congestion risk based on regional population statistics or density calculations.
[0004] The methods described above neglect the geometric constraints of three-dimensional space. For example, the congestion risk of a gathering of 100 people in an open plaza is completely different from that in a narrow stairwell; similarly, the safety situation differs fundamentally between a single-level space with multiple evacuation exits and a high-rise grandstand with only a single passageway, even with the same population density. Therefore, existing technologies cannot accurately analyze and predict the flow of people and potential congestion risks in three-dimensional space. Summary of the Invention
[0005] This application provides a method and system for real-time analysis of activity patterns based on a two-dimensional and three-dimensional integrated approach, which is used to accurately analyze and predict the flow of people and potential congestion risks in three-dimensional space.
[0006] To achieve the above objectives, the embodiments of this application adopt the following technical solutions: Firstly, a method for real-time analysis of activity status based on integrated two-dimensional and three-dimensional analysis is provided, the method comprising: Acquire the CIM basic geographic data and BIM building model of the event venue, generate a three-dimensional space of the event venue based on the CIM basic geographic data and BIM building model, and perform voxel discretization processing on the three-dimensional space to generate a spatial voxel mesh. Traverse each voxel in the spatial voxel grid, calculate the geometric permeability parameter, construct the adjacency matrix between voxels, and generate a three-dimensional guided graph based on the adjacency matrix. In response to receiving the target transmitted from the camera, two-dimensional dynamic data is acquired, and the target is mapped to the particle increment within the corresponding voxel based on the two-dimensional dynamic data; The particle density and average viscosity within each voxel are determined in real time based on the particle increment of each voxel, and the flow resistance of each voxel is calculated based on the particle density, average viscosity and geometric permeability parameters within each voxel. The remaining permeability of each voxel is dynamically updated based on particle density; The preset security key nodes are used as observation points of downstream voxels. Based on the observation points of downstream voxels, the upstream voxels are traversed in reverse along the three-dimensional directional pathway diagram. The back pressure transmission value is calculated based on the remaining permeability of each voxel. Based on the back pressure transmission value, the back pressure generated by the downstream voxel is superimposed on the potential energy field of the upstream voxel, and the calculation is iterated until the back pressure decays to zero. If the total potential energy of the upstream voxel after superimposed backtracking pressure exceeds the safety threshold, it is determined that the corresponding area has a risk of future congestion overflow. Identify high-potential-energy clusters and low-potential-energy cavities in three-dimensional space, and determine the evacuation path with the least resistance based on the high-potential-energy clusters and low-potential-energy cavities. Control commands are generated and output based on the evacuation path of least resistance.
[0007] In one possible implementation of the first aspect, the three-dimensional space is discretized using voxelization to generate a spatial voxel mesh, including: Extract the geometric topology of the building in three-dimensional space, and recursively segment the three-dimensional space based on the geometric topology to obtain multiple voxels; The spatial complexity of the three-dimensional space is determined based on the geometric topology, and the voxel density of each voxel is adaptively adjusted according to the spatial complexity to generate a spatial voxel mesh.
[0008] In another possible implementation of the first aspect, the geometric permeability parameter is calculated, including: Obtain the physical attribute data of each voxel in the spatial voxel grid, where the physical attribute data includes the width, slope and area occupied by obstacles in the physical space corresponding to each voxel; The basic traffic capacity coefficient is calculated based on the width, the slope attenuation factor is calculated based on the slope, and the obstacle blockage coefficient is calculated based on the proportion of area occupied by the obstacle. The geometric permeability parameter is obtained by weighted summation of the basic traffic capacity coefficient, slope attenuation factor, and obstacle blockage coefficient.
[0009] In another possible implementation of the first aspect, an adjacency matrix between voxels is constructed, and a three-dimensional directed pathway graph is generated based on the adjacency matrix, including: Traverse all voxels in the spatial voxel grid and identify the neighboring voxels of each voxel; Determine whether there is physical connectivity between adjacent voxels; If physical connectivity exists, determine the direction of connectivity and directionality, where directionality includes unidirectional or bidirectional; An adjacency matrix is constructed based on the connectivity direction and directionality, where the matrix elements in the adjacency matrix represent the flow weights between voxels; Generate a 3D guided graph based on the adjacency matrix.
[0010] In another possible implementation of the first aspect, the remaining permeability of each voxel is dynamically updated according to the particle density, including: The ratio of the total volume of particles within a voxel to the voxel's spatial capacity is calculated based on particle density, and this ratio is used as the space occupancy rate. When the space occupancy rate is lower than the preset saturation density threshold, the product of the space occupancy rate and the geometric permeability parameter is calculated to obtain the target value; Subtract the target value from the geometric permeability parameter to obtain the remaining permeability; When the space occupancy rate reaches or exceeds the saturation density threshold, the remaining permeability is set to zero, indicating a completely blocked state.
[0011] In another possible implementation of the first aspect, the upstream voxels are traversed in reverse along a three-dimensional directed pathway based on the observation points of the downstream voxels, and the back pressure conduction value is calculated based on the residual permeability of each voxel, including: Obtain the flow resistance value at the observation point of the downstream voxel; The initial back pressure intensity is calculated based on the flow resistance value, where the greater the flow resistance, the higher the initial back pressure intensity. Starting from the observation point of the downstream voxel, back pressure is transmitted to the adjacent upstream voxel based on the initial back pressure intensity along the reverse edge of the three-dimensional guided graph. The attenuation coefficient of back pressure during conduction is calculated based on the residual permeability of each voxel, and the back pressure conduction value is calculated based on the attenuation coefficient.
[0012] In another possible implementation of the first aspect, if the total potential energy of the upstream voxel's potential field after superimposed backtracking pressure exceeds a safety threshold, then the corresponding region is determined to have a risk of future congestion overflow, including: Calculate the initial potential energy of the upstream voxel, which is equal to the product of the flow resistance and the particle density. The total potential energy of the potential field is obtained by adding the original potential energy value to the superimposed back pressure value. If the total potential energy exceeds the safety threshold, it is determined that the region corresponding to the upstream voxel has a risk of future congestion overflow.
[0013] In another possible implementation of the first aspect, high-potential-energy clusters and low-potential-energy cavities in three-dimensional space are identified, and the evacuation path of least resistance is determined based on the high-potential-energy clusters and low-potential-energy cavities, including: Iterate through each voxel to obtain the total potential energy value, and mark the continuous regions with total potential energy values higher than the high potential energy threshold as high potential energy clusters; Continuous regions with total potential energy values below the low potential energy threshold are marked as low potential energy voids. Starting with voxels in high potential energy clusters, calculate the potential energy gradient with adjacent voxels, and select the direction with the fastest decrease in potential energy gradient as the preferred flow direction. Iteratively search along the preferred flow direction until a low-potential-energy cavity is reached, generating a search path; Generate the evacuation path with the least resistance based on all voxels along the search path.
[0014] Secondly, this application provides an electronic device, comprising: The memory is configured to store instructions; and The processor is configured to retrieve the instructions from the memory and, when executing the instructions, to implement the aforementioned real-time activity situation analysis method based on two-dimensional and three-dimensional integration.
[0015] Thirdly, this application provides a machine-readable storage medium storing instructions that cause a machine to execute the aforementioned real-time activity situation analysis method based on two-dimensional and three-dimensional integration.
[0016] The above technical solutions effectively address the problem that traditional two-dimensional analysis methods cannot accurately assess the risk of congestion in three-dimensional space. By integrating CIM basic geographic data and BIM building models, a complete three-dimensional spatial representation is constructed. Adaptive voxelization technology is employed to ensure both detailed depiction of complex spatial structures and control computational complexity. By introducing geometric permeability parameters and three-dimensional guided traffic maps, the physical traffic characteristics and topological connectivity of three-dimensional space are accurately quantified, providing a solid spatial foundation for personnel flow analysis. By mapping visually perceived two-dimensional data to particle distribution in three-dimensional voxel space, the organic integration of real-time monitoring data and spatial models is achieved. By introducing back pressure conduction mechanisms and potential energy field superposition methods, a quantitative assessment of the impact of downstream congestion on upstream areas is realized, enabling early warning of potential congestion spillover risks. By identifying high-potential-energy clusters and low-potential-energy cavities and planning optimal evacuation routes based on potential energy gradients, a scientific basis for emergency evacuation is provided. In summary, by fully considering the geometric constraints of three-dimensional space, the dynamic changes in personnel density, and the transmission effect of spatial pressure, this system enables accurate analysis and intelligent early warning of personnel flow patterns in complex three-dimensional scenarios. It significantly improves the safety management capabilities and emergency response efficiency of large-scale event venues, providing strong technical support for ensuring public safety.
[0017] Other features and advantages of the embodiments of this application will be described in detail in the following detailed description section. Attached Figure Description
[0018] Figure 1 A flowchart illustrating a real-time activity situation analysis method based on integrated two-dimensional and three-dimensional systems, provided for embodiments of this application; Figure 2 This is a schematic diagram of a three-dimensional potential energy field distribution provided in an embodiment of this application. Detailed Implementation
[0019] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. It should be understood that the specific embodiments described herein are only for illustration and explanation of the embodiments of this application and are not intended to limit the embodiments of this application. All other embodiments obtained by those skilled in the art based on the embodiments of this application without creative effort are within the scope of protection of this application.
[0020] It should be noted that if the embodiments of this application involve directional indicators (such as up, down, left, right, front, back, etc.), the directional indicators are only used to explain the relative positional relationship and movement of each component in a certain specific posture (as shown in the figure). If the specific posture changes, the directional indicators will also change accordingly.
[0021] Furthermore, if the embodiments of this application involve descriptions such as "first" or "second," these descriptions are for descriptive purposes only and should not be construed as indicating or implying their relative importance or implicitly specifying the number of technical features indicated. Therefore, features defined with "first" or "second" may explicitly or implicitly include at least one of those features. Additionally, the technical solutions of various embodiments can be combined with each other, but this must be based on the ability of those skilled in the art to implement them. If the combination of technical solutions is contradictory or impossible to implement, it should be considered that such a combination of technical solutions does not exist and is not within the scope of protection claimed in this application.
[0022] Figure 1 The illustration shows a flowchart of a real-time activity situation analysis method based on a two-dimensional and three-dimensional integrated approach according to an embodiment of this application. Figure 1 As shown in the figure, this application provides a method for real-time analysis of activity status based on two-dimensional and three-dimensional integration, which may include the following steps.
[0023] S101. Obtain the CIM basic geographic data and BIM building model of the event venue, generate the three-dimensional space of the event venue based on the CIM basic geographic data and BIM building model, perform voxel discretization processing on the three-dimensional space, and generate a spatial voxel mesh. S102. Traverse each voxel in the spatial voxel grid, calculate the geometric permeability parameter, construct the adjacency matrix between voxels, and generate a three-dimensional guided graph based on the adjacency matrix. S103. In response to receiving the target transmitted from the camera, acquire two-dimensional dynamic data, and map the target to the particle increment within the corresponding voxel based on the two-dimensional dynamic data. S104. Based on the particle increment of each voxel, determine the particle density and average viscosity within each voxel in real time, and calculate the flow resistance of each voxel based on the particle density, average viscosity and geometric permeability parameters within each voxel. S105. Dynamically update the remaining permeability of each voxel based on particle density; S106. The preset security key nodes are used as observation points of downstream voxels. Based on the observation points of downstream voxels, the upstream voxels are traversed in reverse along the three-dimensional directional guidance diagram. The back pressure transmission value is calculated based on the remaining permeability of each voxel. S107. Based on the back pressure transmission value, the back pressure generated by the downstream voxel is superimposed on the potential energy field of the upstream voxel, and the calculation is iterated until the back pressure decays to zero. S108. If the total potential energy of the upstream voxel after the superimposed backtracking pressure exceeds the safety threshold, it is determined that the corresponding area has a risk of future congestion overflow. S109. Identify high-potential-energy clusters and low-potential-energy cavities in three-dimensional space, and determine the evacuation path with the least resistance based on the high-potential-energy clusters and low-potential-energy cavities. S110: Generate and output control commands based on the evacuation path of least resistance.
[0024] In practice, the first step is to acquire the CIM basic geographic data and BIM building model of the event venue. The CIM basic geographic data includes macro-spatial information such as the geographic coordinates, topography, and road network of the event venue, while the BIM building model contains micro-architectural information such as the detailed geometric structure of the building, floor layout, wall locations, and door and window distribution. By spatially registering and fusing these two types of data, a complete three-dimensional spatial model can be constructed.
[0025] Specifically, the CIM data is first transformed to conform to the same coordinate system as the BIM model. Then, a feature point matching algorithm is used to accurately place the BIM model in the correct position within the CIM geospatial space. The resulting fused 3D spatial model contains both macroscopic geographical information and detailed building internal structures, laying the foundation for subsequent voxelization. After generating the 3D space, it needs to be discretized using voxels. Voxelization is the process of discretizing a continuous 3D space into regular 3D mesh units, each called a voxel. In practice, the geometric topology of the building in the 3D space is first extracted, identifying different types of spatial areas such as staircases, corridors, lobbies, and grandstands. Then, based on the geometric topology, the 3D space is recursively segmented, using an octree segmentation algorithm to subdivide the space layer by layer into multiple voxels. To adapt to the varying spatial complexity of different areas, the voxel density needs to be adaptively adjusted. For example, a higher voxel density is used for structurally complex stairwells and narrow passages to capture detailed spatial features, while a lower voxel density is used for open plazas and lobbies to improve computational efficiency. In practice, the spatial complexity index for each region can be calculated. This index comprehensively considers factors such as spatial curvature, obstacle density, and the rate of change of channel width. Then, the side length of the voxels is dynamically adjusted based on the spatial complexity. The resulting spatial voxel mesh can accurately represent complex three-dimensional spatial structures while maintaining a reasonable computational scale, providing a refined spatial foundation for subsequent personnel flow analysis.
[0026] After obtaining the spatial voxel mesh, it is necessary to calculate the geometric permeability parameter for each voxel. Geometric permeability is a key parameter describing the traversability of the voxel space; it reflects the physical traversability characteristics of the voxel space itself without considering personnel density.
[0027] During implementation, the physical attribute data for each voxel is first acquired, including the width, slope, and obstacle occupancy ratio of the physical space containing that voxel. Width directly affects the number of people passing simultaneously; a wider width results in stronger basic passage capacity. Slope affects the speed of movement; going uphill reduces passage efficiency. Obstacles such as pillars and facilities reduce the effective passage area. Specifically, the basic passage capacity coefficient is calculated based on the width, typically using a linear or piecewise linear function. For example, the coefficient is 0.3 when the width is less than 1 meter, linearly increasing to 0.8 when the width is between 1 and 3 meters, and reaching 1.0 when the width is greater than 3 meters. A slope attenuation factor is calculated based on the slope; the factor is 1.0 when the slope is 0 on flat ground, gradually decreasing as the slope increases (e.g., a decrease of 0.1 for every 5-degree increase in slope). An obstacle blockage coefficient is calculated based on the obstacle occupancy ratio; the coefficient is 1.0 when the obstacle occupancy ratio is 0%, decreasing to 0.5 when the ratio reaches 50%. Finally, these three coefficients are weighted and summed to obtain the geometric permeability parameter.
[0028] After calculating the geometric permeability, an adjacency matrix between voxels needs to be constructed. All voxels in the spatial voxel grid are traversed, and for each voxel, its 26 possible neighboring voxels in 3D space are identified (including face adjacency, edge adjacency, and corner adjacency). Then, it is determined whether there is physical connectivity between adjacent voxels, i.e., whether there are physical obstacles such as walls or railings. If connectivity exists, the direction and orientation of the connection are further determined. For example, a staircase going downhill is a one-way connection, while a flat corridor is a two-way connection. Based on this information, an adjacency matrix is constructed. The elements in the matrix represent the flow weights between voxels, and the weights comprehensively consider factors such as geometric permeability and the ease of connection direction. A 3D directed flow graph is generated based on this adjacency matrix. In the graph, nodes represent voxels, directed edges represent possible flow directions of people, and the edge weights reflect the ease of flow. This flow graph provides the topological foundation for subsequent personnel flow simulation and path planning.
[0029] During real-time monitoring, numerous cameras deployed within the event area continuously collect video data and perform target recognition. Once a camera identifies a person, it transmits information about the identified target, including its position, size, and confidence level within the video frame. In response to receiving these identified targets, two-dimensional dynamic data needs to be acquired. This data includes the target's pixel coordinates, movement speed, and direction of movement within the camera's field of view. To map this two-dimensional data into three-dimensional voxel space, coordinate transformation is first required. Using the camera's intrinsic and extrinsic parameter matrices, combined with the camera's installation position and orientation information, the two-dimensional pixel coordinates can be back-projected to three-dimensional spatial coordinates. Specifically, for ground-based cameras, the target can be assumed to be on the ground, and back-projection can be performed using ground constraints; for high-angle, top-down cameras, three-dimensional positioning can be performed using the target's height information.
[0030] After obtaining the target's three-dimensional spatial coordinates, the voxel to which those coordinates belong is quickly located using a spatial index. The identified target is then mapped to the particle increment within the corresponding voxel. In the fluid dynamics analogy model, each person is abstracted as a particle, and the particle increment represents the number of people added to that voxel at the current moment. If a camera identifies 5 newly appearing people in a frame, and these people are all located within the same voxel, then the particle increment of that voxel is 5. For people spanning multiple voxels, their voxel is determined based on their body center position. By continuously receiving and mapping the identified targets from each camera, the particle increment of each voxel can be updated in real time, thereby dynamically tracking changes in the distribution of people throughout the three-dimensional space. This mapping mechanism from two-dimensional visual data to three-dimensional voxel particles achieves effective fusion of perceptual data and spatial models, providing real-time input on the distribution of people for subsequent flow analysis.
[0031] Based on the particle increment of each voxel, the particle density within each voxel can be determined in real time. The particle density is calculated by dividing the current total number of particles within the voxel by its spatial capacity, yielding the number of particles per unit volume. For example, if a voxel has a spatial capacity of 8 cubic meters and currently contains 16 particles, the particle density is 2 people / cubic meter. Particle density directly reflects the crowding level of the voxel's space. In addition to particle density, average viscosity also needs to be calculated. In fluid mechanics analogy, viscosity represents the frictional resistance within a fluid. In crowd flow, average viscosity reflects the degree of mutual interference between people. When the population density is low, people can move freely, resulting in low viscosity; as the density increases, people need to avoid each other and wait in queues, leading to a significant increase in viscosity.
[0032] In specific calculations, the average viscosity exhibits a non-linear positive correlation with particle density. This relationship can be described using an exponential or piecewise function. For example, when the density is below 0.5 people / cubic meter, the viscosity remains at a low level; when the density is between 0.5 and 2 people / cubic meter, the viscosity increases linearly with density; and when the density exceeds 2 people / cubic meter, the viscosity increases exponentially, reflecting the sharp increase in the difficulty of personnel movement at high densities. After determining the particle density and average viscosity, the flow resistance of the voxel can be calculated by combining it with the geometric permeability parameter of the voxel. Flow resistance comprehensively reflects the difficulty of personnel movement within the voxel, and it is influenced by both spatial physical characteristics and the degree of crowding. In the calculation, the flow resistance is directly proportional to the particle density and average viscosity, and inversely proportional to the geometric permeability. That is, the more people, the greater the mutual interference, and the worse the spatial mobility, the greater the flow resistance. Through this calculation, the real-time flow state of each voxel can be quantified, providing basic data for subsequent pressure transmission and risk assessment.
[0033] Residual permeability is a dynamic parameter describing the remaining passage capacity of a voxel, updated in real time with changes in personnel density. In implementation, the ratio of the total volume of particles within a voxel to its spatial capacity is first calculated based on particle density; this is taken as the space occupancy rate. Assuming each person occupies an average volume of 0.2 cubic meters, and 16 people occupy an 8-cubic-meter voxel, the total particle volume is 3.2 cubic meters, resulting in a space occupancy rate of 40%. Then, it is determined whether the space occupancy rate is below a preset saturation density threshold. The saturation density threshold is typically set between 60% and 80%, indicating that when the space occupancy rate exceeds this threshold, the voxel space is close to saturation. When the space occupancy rate is below the saturation density threshold, the voxel still has some passage capacity. In this case, the product of the space occupancy rate and the geometric permeability parameter is calculated to obtain the occupied permeability portion. This occupied portion is then subtracted from the geometric permeability parameter to obtain the residual permeability.
[0034] For example, if a voxel has a geometric permeability of 0.8 and a space occupancy rate of 40%, then the occupied permeability is 0.32, and the remaining permeability is 0.48. When the space occupancy rate reaches or exceeds the saturation density threshold, it indicates that the voxel space has reached or exceeded its carrying capacity. At this point, the remaining permeability is directly set to zero, representing a complete blockage, and personnel can no longer flow into the voxel. This dynamic update mechanism ensures that the remaining permeability accurately reflects the real-time passage capacity of the voxel, providing a key parameter for subsequent pressure transmission calculations. The lower the remaining permeability, the closer the voxel is to saturation, and the more difficult it is for the downstream personnel flow pressure to be released through the voxel, thus transmitting stronger back pressure upstream.
[0035] Within event venues, certain locations are of particular importance for security management, such as main exits, security checkpoints, and stairwells; these locations are pre-designated as critical security nodes. The voxels corresponding to these critical nodes are used as observation points for downstream voxels, and back pressure transmission analysis is performed starting from these observation points. Back pressure transmission is a reverse analysis mechanism that simulates how pressure is transmitted upstream when congestion or obstruction occurs downstream.
[0036] In implementation, the flow resistance value of the downstream voxel observation point is first obtained; the greater the flow resistance, the more congested the location. Then, the initial back pressure intensity is calculated based on the flow resistance value, typically using a linear or nonlinear mapping relationship. The greater the flow resistance, the higher the initial back pressure intensity. For example, when the flow resistance at a certain outlet reaches a high threshold, the initial back pressure intensity can be set to twice that resistance value to emphasize its impact on the upstream. Starting from the downstream voxel observation point, the back pressure is transmitted upstream along the reverse edge of the three-dimensional directed flow diagram. The reverse edge refers to the edge opposite to the normal flow direction; by traversing in reverse, all possible upstream voxels flowing towards the observation point can be found. During the transmission process, the back pressure gradually attenuates, and the degree of attenuation depends on the residual permeability of each voxel. Voxels with high residual permeability can effectively absorb and buffer back pressure, causing the back pressure to significantly weaken after passing through that voxel; while voxels with low or zero residual permeability cannot buffer back pressure, and the back pressure continues to be transmitted upstream with a smaller attenuation. When specifically calculating the back pressure transmission value, an attenuation coefficient is used to quantify this attenuation effect. The attenuation coefficient is proportional to the remaining permeability and can be expressed as the remaining permeability multiplied by an attenuation factor. The back pressure transmitted to the adjacent upstream voxel is equal to the back pressure value of the current voxel multiplied by the attenuation coefficient. Through this stepwise transmission and attenuation, the back pressure impact from the downstream on each upstream voxel can be calculated, thereby assessing the potential impact of downstream congestion on the upstream region.
[0037] After calculating the back pressure conduction value for each voxel, the back pressure generated by the downstream voxel needs to be superimposed on the potential energy field of the upstream voxel. The potential energy field is a physical quantity that describes the spatial energy state of a voxel, and it comprehensively reflects the degree of crowding and the external pressure experienced by the voxel.
[0038] In implementation, for each upstream voxel, its initial potential energy is first calculated. This initial potential energy equals the product of the voxel's flow resistance and particle density, reflecting the energy generated by the voxel's own congestion. Then, the backflow pressure values from all downstream paths are summed to obtain the total backflow pressure. Finally, the initial potential energy is added to the total backflow pressure to obtain the superimposed total potential energy. This process requires iterative calculations because the transmission of backflow pressure is a multi-stage process.
[0039] In the first iteration, upstream voxels directly adjacent to the observation point receive the initial back pressure. In the second iteration, these voxels transmit the decayed back pressure to voxels further upstream. This process repeats until the backpressure decays to zero. The iteration terminates when the new backpressure received by all voxels is less than a minimum threshold, or when the preset maximum number of iterations is reached. In practice, convergence is typically achieved after 5-10 iterations. This iterative superposition mechanism accurately simulates the cascading effects of downstream congestion on the entire upstream region, ensuring that even voxels far from the observation point are significantly affected by backpressure if their path to the observation point has a low-permeability bottleneck. This mechanism effectively captures the complexity of pressure transmission in three-dimensional space, providing a theoretical basis for accurately predicting congestion risk.
[0040] After calculating the potential energy field and superimposing the backflow pressure, a risk assessment needs to be performed on each upstream voxel. The core indicator of the assessment is the total potential energy of the voxel, i.e., the potential energy field value after superimposing the backflow pressure. The total potential energy comprehensively reflects the voxel's own congestion level and the impact of downstream pressure, and is a key basis for determining whether there is a risk of congestion spillover in the area.
[0041] During implementation, a safety threshold is pre-set. This threshold, determined based on historical data, safety regulations, and expert experience, represents the maximum potential energy level that a voxel can safely withstand. For each upstream voxel, its total potential energy is compared to the safety threshold. If the total potential energy exceeds the safety threshold, the area corresponding to that voxel is deemed to have a future congestion overflow risk. Congestion overflow risk means that, given the current population flow trend, the area is likely to experience severe congestion in the near future, potentially leading to accidents such as people being stranded or stampedes. For example, if the initial potential energy value of a stairwell voxel is 50, the backflow pressure from the downstream exit is 80, and the total potential energy reaches 130, while the safety threshold is set at 100, then that stairwell is identified as a high-risk area. This assessment not only considers the current population density but also proactively considers the impact of downstream congestion on the upstream, enabling early warning of potential dangerous areas. Once a high-risk area is identified, an early warning mechanism can be immediately triggered, notifying security personnel to take intervention measures, such as guiding pedestrian flow to alternative routes and controlling the entry speed of upstream personnel, thereby effectively preventing congestion accidents.
[0042] In the potential energy field distribution in three-dimensional space, there exist two special regions: high potential energy clusters and low potential energy cavities, such as... Figure 2 As shown, high-potential-energy clusters refer to continuous regions where the total potential energy value is consistently higher than the high-potential-energy threshold. These regions typically correspond to locations that are severely congested or about to become congested, such as densely populated grandstand areas or narrow passageways. Low-potential-energy cavities, on the other hand, are continuous regions where the total potential energy value is consistently lower than the low-potential-energy threshold. These regions typically correspond to relatively open, sparsely populated locations, such as open plazas or empty evacuation routes. The method for identifying these two types of regions is to traverse and obtain the total potential energy value of each voxel, and then use region growing or clustering algorithms to group voxels with similar potential energy values and spatial continuity into the same region.
[0043] For high-potential energy clusters, starting from any high-potential-energy voxel, expansion extends to adjacent voxels. If the potential energy value of an adjacent voxel is also higher than the high-potential-energy threshold, it is incorporated into the same high-potential-energy cluster, until further expansion is impossible. The identification process for low-potential-energy cavities is similar. After identifying high-potential-energy clusters and low-potential-energy cavities, the evacuation path of least resistance can be determined based on this information. The goal of evacuation path planning is to quickly guide people from high-potential-energy clusters to low-potential-energy cavities, thereby alleviating congestion.
[0044] In practice, starting with a voxel in a high-potential-energy cluster, the potential energy gradient between it and all its neighboring voxels is calculated. The potential energy gradient represents the rate and direction of potential energy decrease. The direction with the fastest decreasing potential energy gradient is selected as the preferred flow direction. This direction points to a region with even lower potential energy, meaning that personnel experience less resistance when moving along this direction. The search iteratively continues along the preferred flow direction, selecting the neighboring voxel with the fastest decreasing potential energy gradient as the next step each time, until a low-potential-energy cavity is reached. The voxel sequence generated by this iterative process constitutes a search path. To ensure the feasibility and safety of the path, the physical connectivity and geometric permeability of all voxels on the path are checked, eliminating paths with physical obstacles or excessively low permeability. The final evacuation path with minimum resistance considers both the global optimization of potential energy distribution and ensures the physical accessibility of the path, providing scientific guidance for personnel evacuation.
[0045] After determining the evacuation route of least resistance, specific control commands need to be generated and output based on this route. Control commands are specific instructions that guide security personnel and intelligent devices to perform evacuation operations, including various types such as personnel guidance commands, equipment control commands, and information dissemination commands. Personnel guidance commands are used to direct on-site security personnel to guide the flow of people at key locations, such as placing guides at the entrance of high-potential energy clusters to dissuade people from entering, and placing directional signs at key nodes of the evacuation route to instruct people to evacuate according to the planned route. Equipment control commands are used to control intelligent devices to assist in evacuation, such as adjusting the electronic display screen to show the evacuation route map, opening or closing turnstiles in specific channels, and adjusting the lighting system to highlight the evacuation route. Information dissemination commands are used to disseminate evacuation information to on-site personnel through broadcasts, mobile phone push notifications, etc., informing them of evacuation directions and precautions.
[0046] When generating control commands, the priority and execution order of the commands must be considered. For high-risk areas, emergency evacuation commands are generated first; for lower-risk areas, preventative guidance commands are generated. Simultaneously, the control commands need to be dynamically adjustable, continuously updating evacuation routes and control strategies in response to real-time changes in personnel flow and potential energy fields. The generated control commands are output to various execution terminals through the command and dispatch system, including mobile terminals of security personnel, control interfaces of smart devices, and information dissemination platforms. This closed-loop control mechanism transforms analysis results into actual security actions, realizing a complete process from data perception, analysis and early warning to control execution, effectively improving the safety management level of large-scale event venues.
[0047] This embodiment effectively solves the problem that traditional two-dimensional analysis methods cannot accurately assess the risk of congestion in three-dimensional space. By integrating CIM basic geographic data and BIM building models, a complete three-dimensional spatial representation is constructed. Adaptive voxelization technology is used to ensure both detailed depiction of complex spatial structures and control computational complexity. By introducing geometric permeability parameters and three-dimensional guided traffic maps, the physical traffic characteristics and topological connectivity of three-dimensional space are accurately quantified, providing a solid spatial foundation for personnel flow analysis. By mapping visually perceived two-dimensional data to particle distribution in three-dimensional voxel space, the organic integration of real-time monitoring data and spatial models is achieved. By introducing back pressure conduction mechanisms and potential energy field superposition methods, a quantitative assessment of the impact of downstream congestion on upstream areas is achieved, enabling early warning of potential congestion spillover risks. By identifying high-potential-energy clusters and low-potential-energy cavities and planning optimal evacuation routes based on potential energy gradients, a scientific basis for emergency evacuation is provided. In summary, by fully considering the geometric constraints of three-dimensional space, the dynamic changes in personnel density, and the transmission effect of spatial pressure, this system enables accurate analysis and intelligent early warning of personnel flow patterns in complex three-dimensional scenarios. It significantly improves the safety management capabilities and emergency response efficiency of large-scale event venues, providing strong technical support for ensuring public safety.
[0048] In one embodiment of this invention, the three-dimensional space is discretized using voxelization to generate a spatial voxel mesh, including the following steps: S210. Extract the geometric topology of the building in three-dimensional space, and recursively segment the three-dimensional space based on the geometric topology to obtain multiple voxels. S220. Determine the spatial complexity of the three-dimensional space based on the geometric topology, and adaptively adjust the voxel density of each voxel according to the spatial complexity to generate a spatial voxel mesh.
[0049] In this embodiment, the three-dimensional space is recursively segmented based on the geometric topology to obtain multiple voxels, including: Determine the initial bounding box in 3D space as the root voxel; Detect whether there are building boundaries, walls, or floor partitions within the root node voxel; If building boundaries, walls, or floor partitions exist, the root node voxel is divided into multiple sub-voxels along the partitions of the geometric topology. For each sub-voxel, recursively perform detection and partitioning operations until the sub-voxel no longer contains building boundaries, walls, or floor partitions, or the sub-voxel size reaches the preset minimum voxel threshold. Output all the final sub-voxels obtained from the recursive segmentation as multiple voxels.
[0050] The spatial complexity of the three-dimensional space is determined based on the geometric topology, and the voxel density of each voxel is adaptively adjusted according to the spatial complexity to generate a spatial voxel mesh, including: Count the number of corners, branching passages, and floor connections in a three-dimensional space; The geometric complexity index is calculated based on the number of corners, the number of passage branches, and the number of floor connections. The geometric complexity index is compared with a preset complexity threshold to determine the space complexity level; The voxel density adjustment coefficient is determined based on the space complexity level, where the higher the space complexity level, the larger the voxel density adjustment coefficient. Multiply the initial voxel density by the voxel density adjustment factor to obtain the adaptively adjusted voxel density; Multiple voxels are subdivided or merged based on the adaptively adjusted voxel density to generate a spatial voxel mesh.
[0051] When discretizing a building in 3D space using voxelization, the first step is to extract its geometric topology. This topology contains key geometric features and spatial connections, such as wall locations, floor divisions, room partitions, and passageway connections. The extraction process reads geometric data from the BIM building model, identifying the spatial locations and dimensions of structural components like walls, floors, and columns. Simultaneously, it analyzes the topological relationships between these components, determining which walls enclose rooms, which floors separate different floors, and which openings form passageways. This geometric topology information provides a clear basis for subsequent recursive segmentation.
[0052] After extracting the geometric topology, the three-dimensional space is recursively segmented based on this structure. Recursive segmentation is a top-down spatial partitioning strategy, starting from the overall space and gradually subdividing it into smaller spatial units. In practice, an initial bounding box for the three-dimensional space is first determined. This bounding box is the smallest cuboid space that can completely contain the entire activity area, serving as the root voxel for recursive segmentation. Then, the presence of building boundaries, walls, or floor partitions within the root voxel is checked. Building boundaries refer to the outer contour of the building, walls refer to internal partition structures, and floor partitions refer to the floor slabs between different floors.
[0053] If these dividing structures are detected, the root node voxel is divided into multiple sub-voxels along the dividing planes of the geometric topology. For example, if there is a north-south wall within the root node voxel, the space is divided into two sub-voxels, east and west, along this wall. During division, it is necessary to ensure that the dividing planes are aligned with the voxel boundaries to avoid irregular voxel shapes. The same detection and division operation is recursively performed on each sub-voxel: checking whether dividing structures still exist within the sub-voxel; if so, division continues; otherwise, the sub-voxel is retained. There are two recursive termination conditions: first, the sub-voxel no longer contains any building boundaries, walls, or floor dividing planes, indicating that the voxel corresponds to a complete spatial unit; second, the sub-voxel size has reached a preset minimum voxel threshold, such as a side length less than 0.5 meters. At this point, even if there are still small internal structures, division stops to avoid excessive voxel subdivision leading to a surge in computation. Through this recursive division process, the three-dimensional space is decomposed layer by layer into multiple voxels, each corresponding to a relatively independent spatial region, laying the foundation for subsequent refined analysis.
[0054] The core of the recursive segmentation process lies in accurately identifying the segmentation structure and performing spatial partitioning. In practice, a geometric intersection algorithm is used to detect building boundaries, walls, or floor partitions. For the current voxel to be detected, the geometric models of all building components are traversed to determine whether the geometric surfaces of the components intersect with the voxel space. If the plane of a wall intersects with the interior of a voxel, then the wall constitutes a valid partition. The determination of the partition needs to consider its direction and position. Walls are usually vertical planes and can partition space along the X-axis or Y-axis; floor partitions are horizontal planes and partition space along the Z-axis.
[0055] After determining the dividing surface, the intersection line or plane between the dividing surface and the voxel is calculated, and the voxel is divided into two or more sub-voxels using this as the boundary. Boundary cases need to be handled during segmentation, such as when the dividing surface is exactly on the voxel boundary, or when multiple dividing surfaces exist within a single voxel. For cases with multiple dividing surfaces, segmentation is performed sequentially according to priority, typically processing floor dividing surfaces vertically first, followed by wall dividing surfaces horizontally. Each sub-voxel generated after segmentation needs to record its spatial extent, parent node information, and included building components for subsequent processing. The recursive process uses either a depth-first or breadth-first traversal strategy. The depth-first strategy processes all child nodes of a branch up to the leaf node, while the breadth-first strategy processes all sibling nodes layer by layer. In practical applications, the breadth-first strategy is more conducive to parallel processing, allowing simultaneous detection and segmentation of multiple voxels at the same level, improving processing efficiency. The termination of recursive segmentation depends not only on geometric conditions but also on semantic information. For example, some small decorative components, although geometrically constituting a dividing line, have little impact on pedestrian flow and can be ignored during segmentation. By combining geometric detection and semantic filtering, we ensure that the voxels generated by recursive segmentation accurately reflect the spatial structure while avoiding over-subdivision.
[0056] After the initial recursive segmentation, the resulting voxels may not be uniform in size and density, requiring adaptive adjustment based on spatial complexity. Spatial complexity reflects the degree of complexity of the spatial structure; more complex regions require higher voxel densities to accurately capture spatial features. The method for determining spatial complexity is based on statistical key feature indicators of geometric topology. First, the number of corners in 3D space is counted. Corners refer to locations where the direction of a passage or room boundary changes; more corners indicate a more tortuous and complex spatial layout. Next, the number of passage branches is counted. Passage branches refer to locations where a passage splits into multiple passages; more branches indicate a more complex spatial connection. Finally, the number of floor connections is counted, including the number of vertical transportation facilities such as stairs, elevators, and escalators; more floor connections indicate a stronger three-dimensional spatial character.
[0057] Based on these three statistical indicators, the geometric complexity index is calculated. The calculation method can employ weighted summation; for example, multiply the number of corners by a weighting factor of 0.3, the number of passageway branches by a weighting factor of 0.4, and the number of floor connections by a weighting factor of 0.3, then sum them to obtain the geometric complexity index. The weighting factors reflect the degree of contribution of different features to spatial complexity; passageway branches have the greatest impact on personnel flow and therefore have the highest weight. After calculating the geometric complexity index, it is compared with a preset complexity threshold to determine the spatial complexity level. Multiple thresholds can be set to classify complexity into low, medium, and high levels; for example, a geometric complexity index less than 10 indicates low complexity, 10 to 30 indicates medium complexity, and greater than 30 indicates high complexity.
[0058] The calculation of spatial complexity relies not only on statistical indicators but also on the distribution and combination of spatial features. When counting the number of corners, it's necessary to distinguish between different types of corners. Right-angle corners and acute-angle corners have different impacts on pedestrian flow; acute-angle corners cause more severe flow obstruction and therefore can be given higher weight in the calculation. In practice, corners are identified by analyzing the turning angle of the passage's centerline: angles less than 90 degrees are acute-angle corners, and angles equal to 90 degrees are right-angle corners. When counting the number of passage branches, it's necessary to identify the branch types, including T-shaped branches, cross-shaped branches, and multi-way branches. Cross-shaped branches and multi-way branches have higher complexity than T-shaped branches because they offer more path choices, increasing the uncertainty of pedestrian flow. By analyzing the topological connections of the passage, various types of branches can be identified and classified for statistical analysis.
[0059] When calculating the number of floor connections, it's crucial to consider not only the quantity of connecting facilities but also their type and capacity. Staircases have lower capacity than elevators and escalators, thus they can be assigned a higher contribution to complexity calculations. Furthermore, the spatial distribution of floor connections must be considered. If multiple connections are concentrated in the same area, their complexity contribution should be reduced; if they are dispersed across different areas, they should be calculated as a whole. In calculating the geometric complexity index, besides weighted summation, nonlinear combination methods can be used, such as introducing interaction terms to reflect the synergistic effect between different features. When an area has a large number of corners and branches, its complexity increase may exceed linear superposition. In this case, a term representing the product of the number of corners and branches can be added to the formula, with a smaller weighting coefficient. This refined complexity calculation allows for a more accurate quantification of the spatial structure's complexity, providing a reliable basis for adaptive adjustment of voxel density.
[0060] The voxel density adjustment factor is determined based on the spatial complexity level; the higher the spatial complexity level, the larger the voxel density adjustment factor. For example, the adjustment factor is 1.0 for low-complexity regions, maintaining the initial density; the adjustment factor is 1.5 for medium-complexity regions, increasing the density by 50%; and the adjustment factor is 2.0 for high-complexity regions, doubling the density. Multiplying the initial voxel density by the voxel density adjustment factor yields the adaptively adjusted voxel density. The initial voxel density is a baseline density value pre-set based on the overall spatial dimensions and computational resources. The adjusted voxel density determines the final voxel size for that region; a higher density results in smaller and denser voxels.
[0061] Finally, based on the adaptively adjusted voxel density, multiple voxels are subdivided or merged. For high-complexity regions requiring increased density, the original voxels are further subdivided into smaller sub-voxels. The subdivision method typically uses uniform octet, which involves dividing a voxel once along each of the three coordinate axes to obtain eight sub-voxels of equal size. For low-complexity regions with excessively high density, multiple adjacent small voxels can be merged into one large voxel to reduce redundant computation.
[0062] Adaptive adjustment of voxel density is a dynamic optimization process that requires finding a balance between computational accuracy and efficiency. After determining the adjustment coefficients, several constraints need to be considered when actually performing subdivision or merging operations. First, there are upper and lower limits on voxel size. Voxels cannot be subdivided or merged indefinitely; minimum and maximum voxel sizes need to be set. The minimum voxel size is typically set to 0.3-0.5 meters, corresponding to the basic human activity space; the maximum voxel size is typically set to 5-10 meters to avoid excessively large voxels that result in coarse spatial representation. Second, there are constraints on the regularity of voxel shape. Subdivided or merged voxels should maintain a cuboid shape as much as possible, with the length, width, and height ratios not too disparate to avoid producing overly flat or elongated voxels. In practice, if a certain dimension of a voxel is already very small, subdivision along that dimension is stopped, and subdivision is performed along other dimensions instead.
[0063] Secondly, there is the alignment constraint of voxel boundaries. Voxel boundaries should be aligned with the geometric boundaries of building components as much as possible to avoid a wall or floor being cut by multiple voxels, which simplifies subsequent geometric permeability calculations. When performing subdivision operations, a recursive octet method is used, but it needs to be flexibly adjusted according to actual needs. If the spatial dimension in a certain direction is already small enough, it can be subdivided into quarters or halves along other directions instead of being forced into octets. When performing merging operations, it is necessary to check whether adjacent voxels meet the merging conditions, including spatial continuity, similar complexity, and functional consistency. Only voxels that meet these conditions can be merged to ensure that the merged voxels still have clear spatial semantics. Through this refined adjustment strategy, the generated spatial voxel mesh can adapt to changes in the complexity of spatial structures while maintaining good geometric regularity and semantic consistency, providing a high-quality spatial discretization foundation for subsequent flow analysis.
[0064] Through this adaptive adjustment, the resulting spatial voxel mesh has a high density in complex regions to capture details and a low density in simple regions to improve efficiency, achieving a balance between computational accuracy and efficiency.
[0065] This implementation achieves accurate modeling and efficient representation of complex 3D spaces. A recursive segmentation strategy based on geometric topology accurately identifies the spatial partitioning features of buildings, decomposing continuous 3D space into discrete voxel units with clear boundaries and semantics, effectively solving the problem that traditional uniform mesh methods cannot adapt to complex building structures. By introducing a spatial complexity assessment mechanism, comprehensively considering multi-dimensional features such as corners, branches, and floor connections, a quantitative assessment of the complexity of the spatial structure is achieved, providing a scientific basis for adaptive adjustment of voxel density. The adaptive voxel density adjustment mechanism dynamically optimizes voxel distribution according to spatial complexity, providing high-density voxels in structurally complex key areas to capture detailed features, and using low-density voxels in structurally simple open areas to improve computational efficiency, thus achieving optimal allocation of computational resources. Through fine-grained control of subdivision and merging operations, the generated voxel mesh is ensured to meet both geometric regularity requirements and maintain good spatial semantic consistency. This method significantly improves the quality and efficiency of 3D spatial discretization, providing an accurate and reliable spatial foundation for subsequent personnel flow analysis, congestion prediction, and evacuation planning, and is a key technical support for realizing real-time analysis of activity status based on integrated 2D and 3D models.
[0066] In one embodiment of this invention, calculating the geometric permeability parameter includes the following steps: S310. Obtain the physical attribute data of each voxel in the spatial voxel grid, wherein the physical attribute data includes the width, slope and obstacle area ratio of the physical space corresponding to each voxel. S320. Calculate the basic traffic capacity coefficient based on the width, calculate the slope attenuation factor based on the slope, and calculate the obstacle blockage coefficient based on the proportion of area occupied by obstacles. S330. The geometric permeability parameter is obtained by weighted summation of the basic traffic capacity coefficient, slope attenuation factor and obstacle blockage coefficient.
[0067] After generating the spatial voxel mesh, it is necessary to obtain the physical property data of each voxel to calculate the geometric permeability parameter. The physical property data describes the objective characteristics of the physical space corresponding to the voxel and directly affects the mobility of personnel in that space.
[0068] In practical implementation, the width information of the physical space corresponding to the voxel is first obtained. Width refers to the effective width for passage within the voxel space. For corridor voxels, the width is the distance between the walls on both sides of the corridor; for room voxels, the width is the minimum cross-sectional dimension of the room. The width is obtained by analyzing the geometric data of the building components within the voxel, identifying boundary structures such as walls and railings, and calculating the shortest distance between these boundaries as the effective width. For example, if the distance between the walls on both sides of a corridor voxel is 3.5 meters, then the width of that voxel is 3.5 meters.
[0069] Next, slope information is obtained. Slope reflects the degree of inclination in the voxel space and has a significant impact on the speed of personnel movement. Slope is obtained by calculating the angle between the bottom surface of the voxel and the horizontal plane. For stair voxels, the slope is the inclination angle of the stairs, typically between 30-45 degrees; for ramp voxels, the slope is smaller, generally between 5-15 degrees; for flat ground voxels, the slope is close to zero. Slope data can be extracted directly from the BIM model or calculated through the elevation difference of voxel vertices.
[0070] The obstacle occupancy ratio is then obtained again. Obstacles include fixed or temporary structures such as pillars, equipment boxes, seats, and trash cans within the voxel, which reduce the effective passage area. The obstacle occupancy ratio is calculated by dividing the sum of the projected areas of all obstacles within the voxel by the voxel's base area. For example, a voxel with a base area of 20 square meters contains two pillars, each occupying 0.5 square meters, and an equipment box occupying 1 square meter; the total obstacle occupancy is 2 square meters, representing 10% of the total area. Systematically acquiring these three types of physical attribute data provides comprehensive foundational data support for subsequent geometric permeability calculations.
[0071] After acquiring the physical attribute data, this data needs to be converted into standardized coefficient parameters. First, a basic passage capacity coefficient is calculated based on the width, reflecting the impact of space width on passage capacity. A piecewise function mapping relationship is used in the calculation. When the width is less than 1 meter, the space is too narrow, allowing only one person to pass at a time, and the basic passage capacity coefficient is set to 0.2-0.3. When the width is between 1 and 2 meters, two people can pass side-by-side or pass each other, and the coefficient linearly increases to 0.5-0.6. When the width is between 2 and 4 meters, multiple people can pass side-by-side, and the coefficient continues to linearly increase to 0.8-0.9. When the width exceeds 4 meters, the space is open, and the passage capacity is close to optimal, with the coefficient reaching 1.0. For example, for a corridor voxel with a width of 3 meters, the basic passage capacity coefficient is calculated to be 0.75.
[0072] Secondly, the slope attenuation factor is calculated based on the slope gradient. This factor reflects the negative impact of slope on the speed of movement. When the slope is 0 degrees (flat ground), the attenuation factor is 1.0, indicating no attenuation. When the slope is between 0 and 10 degrees, it is a gentle slope, and the speed of movement decreases slightly, with an attenuation factor of 0.9-1.0. When the slope is between 10 and 30 degrees, it is a moderate slope, and the speed of movement decreases significantly, with an attenuation factor of 0.6-0.9. When the slope exceeds 30 degrees, it is a steep slope or stairs, and the speed of movement decreases drastically, with the attenuation factor dropping to 0.3-0.6. The slope attenuation factor can be calculated using an exponential attenuation function, for example, the attenuation factor equals 1.0 multiplied by 0.98 raised to the power of the slope. This more accurately reflects the characteristic of accelerated attenuation as the slope increases.
[0073] The obstacle blockage coefficient is calculated again based on the proportion of area occupied by obstacles. This coefficient reflects the reduction effect of obstacles on the effective passage area. When the obstacle occupancy rate is 0%, the blockage coefficient is 1.0; when the occupancy rate is 20%, the blockage coefficient drops to 0.8; when the occupancy rate is 50%, the blockage coefficient drops to 0.5; when the occupancy rate exceeds 70%, the space is almost completely blocked, and the blockage coefficient approaches 0. The obstacle blockage coefficient is usually calculated using a linear relationship, that is, the blockage coefficient equals 1.0 minus the proportion of area occupied by obstacles. Through the calculation of these three coefficients, the physical attribute data is transformed into standardized parameters that can be quantified and compared, laying the foundation for a comprehensive assessment of geometric permeability.
[0074] After obtaining the basic traffic capacity coefficient, slope attenuation factor, and obstacle blockage coefficient, these three coefficients need to be combined into a unified geometric permeability parameter. The geometric permeability parameter is a comprehensive index describing the inherent traffic capacity of a voxel; a higher value indicates stronger traffic capacity. The synthesis method employs a weighted summation strategy, which involves multiplying each of the three coefficients by its corresponding weighting coefficient and then summing the results. The weighting coefficients need to be determined based on the degree of influence of each factor on traffic capacity.
[0075] In practice, the weight of the basic capacity coefficient is usually set to 0.5 because width is the most fundamental factor determining capacity; the weight of the slope attenuation factor is set to 0.3 because slope mainly affects movement speed rather than capacity; and the weight of the obstacle blockage coefficient is set to 0.2 because the impact of obstacles is relatively localized and can be mitigated by detours. The formula for calculating the geometric permeability parameter is: geometric permeability equals the basic capacity coefficient multiplied by 0.5, plus the slope attenuation factor multiplied by 0.3, plus the obstacle blockage coefficient multiplied by 0.2. For example, if a voxel has a basic capacity coefficient of 0.75, a slope attenuation factor of 0.85, and an obstacle blockage coefficient of 0.90, then the geometric permeability parameter is calculated as follows: .
[0076] This value indicates that the voxel has good transit capability.
[0077] By using a weighted summation method, the geometric permeability parameter comprehensively reflects the combined impact of width, slope, and obstacles on traffic capacity. It considers both the independent effects of each factor and the relative importance of each factor through weight allocation, providing accurate spatial basis parameters for subsequent flow resistance calculations and personnel flow simulations.
[0078] This implementation method achieves a precise quantitative assessment of the inherent traffic capacity of voxel space. By systematically acquiring data on three key physical attributes—width, slope, and the proportion of area occupied by obstacles—it comprehensively characterizes the main spatial features affecting pedestrian traffic, ensuring the completeness and accuracy of the assessment. By converting the physical attribute data into standardized coefficient parameters and employing mathematical models such as piecewise functions and attenuation functions, it accurately reflects the nonlinear relationship between each physical factor and traffic capacity, avoiding assessment biases that may result from simple linear mapping. A weighted summation strategy is used to integrate multiple coefficients, considering both the independent influence of each factor and reflecting their relative importance through weight allocation, achieving effective fusion of multi-dimensional information. The geometric permeability parameter calculated by this method objectively reflects the inherent traffic characteristics of voxel space, unaffected by dynamic factors such as pedestrian density, providing a stable and reliable foundation for subsequent flow resistance calculations, residual permeability updates, and backpressure transmission analysis. Compared to traditional methods that only consider a single factor, this method comprehensively considers the multi-dimensional physical characteristics of space, significantly improving the scientific rigor and accuracy of traffic capacity assessment, and providing key technical support for accurate analysis of pedestrian flow patterns and congestion risk prediction.
[0079] In one embodiment of this invention, an adjacency matrix between voxels is constructed, and a three-dimensional directed pathway graph is generated based on the adjacency matrix, including the following steps: S410. Traverse all voxels in the spatial voxel grid and identify the adjacent voxels of each voxel. S420. Determine whether there is physical connectivity between adjacent voxels; S430. If physical connectivity exists, determine the connectivity direction and directionality, where directionality includes unidirectional or bidirectional. S440. Construct an adjacency matrix based on the connectivity direction and directionality, where the matrix elements in the adjacency matrix represent the flow weights between voxels; S450. Generate a 3D guided graph based on the adjacency matrix.
[0080] After generating the voxel mesh and calculating the geometric permeability parameters, it is necessary to construct the topological connections between voxels. First, all voxels in the spatial voxel mesh are traversed, and each voxel's neighboring voxels are identified. In 3D space, a voxel can have a maximum of 26 neighboring voxels, including 6 face-adjacent voxels, 12 edge-adjacent voxels, and 8 corner-adjacent voxels. Face adjacency means that two voxels share a complete face, such as adjacency in the six directions of up / down, left / right, and front / back; edge adjacency means that two voxels share an edge but not a face; corner adjacency means that two voxels only touch at a single vertex.
[0081] In practice, the method for identifying adjacent voxels is based on geometric judgment using the voxel's spatial coordinates and dimensions. Assuming the voxels adopt a regular cuboid mesh structure, each voxel can be represented by its center point coordinates and the length of half its side in three directions. For the current voxel, the spatial relationship between its boundary and the boundaries of other voxels is calculated to determine whether an adjacency relationship exists. Specifically, if the boundaries of two voxels coincide in a certain direction or the distance between them is less than a preset threshold, and there is an overlapping area in other directions, they are determined to be adjacent voxels. For example, if the right boundary coordinate of voxel A is 5.0 meters, the left boundary coordinate of voxel B is 5.0 meters, and they overlap in the Y-axis and Z-axis directions, then voxel B is the right-side adjacent voxel of voxel A.
[0082] To improve recognition efficiency, spatial indexing structures such as octrees or KD-trees can be used to organize voxels according to their spatial location. This way, when searching for adjacent voxels, only voxels within a local region need to be retrieved, rather than traversing all voxels. By systematically identifying all adjacent voxels of each voxel, the basic topological structure of the voxel grid is established, laying the foundation for subsequent determination of physical connectivity and construction of conduction graphs.
[0083] After identifying adjacent voxels, it is necessary to further determine whether physical connectivity exists between them. Physical connectivity refers to whether a person can move directly from one voxel to an adjacent voxel, which depends on whether there are physical obstacles between the two voxels. In practice, physical obstacles mainly include building components such as walls, railings, and glass partitions. The method for determining physical connectivity is to detect whether there are obstructive components on the shared boundary of the two voxels.
[0084] In practice, the shared boundary region of two adjacent voxels is first determined. For face-adjacent voxels, the shared boundary is a rectangular face; for edge-adjacent voxels, the shared boundary is a line segment; and for corner-adjacent voxels, the shared boundary is a point. Then, the component data in the BIM building model is queried to check if the geometric surfaces of components such as walls, doors, and windows intersect with the shared boundary. If the shared boundary region is completely covered by a wall, it is considered disconnected; if the shared boundary region contains a door or opening, it is considered connected. For doors, the opening status and direction of passage must also be considered. Normally open doors are considered bidirectionally connected, one-way doors such as push-bar doors for emergency exits are considered unidirectionally connected, and normally closed or locked doors are considered disconnected. Windows are generally considered disconnected, unless they are passable floor-to-ceiling windows or emergency escape windows.
[0085] Furthermore, the impact of height differences must be considered. If there is a significant height difference between two adjacent voxels but no stairs or ramps connecting them, they should also be considered disconnected. For example, if two vertically adjacent voxels have the upper voxel's ground level 3 meters higher than the lower voxel's top level, and there are no stairs between them, they should be considered disconnected. By comprehensively considering the obstructive effects of building components and the geometric relationships of space, the physical connectivity between voxels can be accurately determined, ensuring that the constructed pathway map accurately reflects the possible movement paths of people.
[0086] For adjacent voxels determined to be physically connected, it is necessary to further determine the connection direction and directionality. The connection direction refers to the specific direction in which a person moves from one voxel to another, such as up, down, left, right, etc. Directionality describes whether the connection is unidirectional or bidirectional.
[0087] In practice, the direction of connection is determined based on the spatial relationship of voxels. For horizontally adjacent voxels, the connection direction is horizontal, such as east, west, south, or north; for vertically adjacent voxels, the connection direction is upward or downward. Determining directionality requires considering multiple factors. First, gravity and terrain factors are considered. For stairs and ramps, downward movement is generally easier than upward movement, but both directions are feasible, therefore it is determined to be bidirectional connection, only the flow weights in the two directions are different. For slides or one-way escalators, movement is only possible in one direction, therefore it is determined to be unidirectional connection.
[0088] Secondly, access control and management factors must be considered. Some passageways are equipped with one-way turnstiles or one-way doors, allowing only one-way passage. For example, subway station entrance turnstiles only allow passage from the outside to the inside, thus classifying them as one-way connections. Thirdly, safety regulations must be considered. Emergency evacuation routes are typically designed for one-way flow, from inside the building to the outside. While normally bidirectional, they become one-way in emergencies. When determining directionality, the actual habits and rules of pedestrian flow must also be considered. For instance, some corridors, although physically bidirectional, should be marked as one-way connections due to pedestrian management regulations.
[0089] In practice, each pair of connected voxels can be labeled with connectivity attributes in both directions. For example, voxel A to voxel B is connected with a weight of 0.8, while voxel B to voxel A is also connected with a weight of 0.6. This accurately describes the differences between the two directions in bidirectional connectivity. By meticulously determining the connectivity directions and directionality, complete topological information is provided for constructing accurate guided connected graphs.
[0090] After determining the connectivity, direction, and directionality between voxels, an adjacency matrix needs to be constructed to systematically represent this information. The adjacency matrix is a classic method for representing graph structures in graph theory. For a mesh containing N voxels, the adjacency matrix is an N×N square matrix. The elements in the matrix represent the flow weights between voxels. If there is a connection between voxel i and voxel j, the matrix element M(i, j) is non-zero, representing the flow weight from voxel i to voxel j; if there is no connection, M(i, j) is zero.
[0091] The calculation of flow weights considers multiple factors. First, the geometric permeability parameters of the two voxels are considered, and the smaller value is taken as the base weight, as flow capacity is limited by the weaker one. Second, the influence of the connection direction is considered; horizontal movement typically has a higher weight than vertical movement, and downward movement has a higher weight than upward movement. Directional correction coefficients can be introduced: 1.0 for horizontal movement, 0.9 for downward movement, and 0.6 for upward movement. Third, the characteristics of the connection interface are considered; a wide opening has a higher weight, while a narrow opening has a lower weight. The opening coefficient can be calculated based on the ratio of the opening width to the voxel width; a larger ratio results in a higher opening coefficient.
[0092] The formula for calculating the flow weight is: Flow weight equals the smaller geometric permeability multiplied by the direction correction factor multiplied by the opening factor. For example, if voxel A has a geometric permeability of 0.8 and voxel B has a geometric permeability of 0.7, and the movement from A to B is horizontal, with the opening width occupying 80% of the voxel width, then the flow weight is calculated as follows: For unidirectional connectivity, a non-zero weight is set only in one direction, while the matrix elements in the opposite direction are zero. For bidirectional connectivity with different weights in the two directions, the weights in both directions are calculated separately and filled into the corresponding matrix elements. The adjacency matrix constructed in this way not only expresses the connectivity topology between voxels but also quantifies the strength and directional characteristics of connectivity, providing a complete data foundation for generating guided connected graphs.
[0093] Based on the constructed adjacency matrix, a 3D guided graph can be generated. A guided graph is a directed weighted graph where nodes represent voxels, directed edges represent connectivity between voxels, and edge weights represent flow weights. The generation process involves converting the adjacency matrix into a graph data structure.
[0094] In practice, the connected graph is stored in the form of an adjacency list or an edge list. For each voxel node, an outgoing edge list is maintained, where each element contains the index of the target voxel and the flow weight. The adjacency matrix is traversed, and for each non-zero element M(i, j), an edge pointing to voxel j is added to the outgoing edge list of voxel i, with the edge weight M(i, j). This representation is more efficient than a matrix when dealing with sparse graphs because most voxels are only connected to a few neighboring voxels, and most elements in the adjacency matrix are zero.
[0095] The generated 3D guided connectivity map comprehensively describes the spatial connectivity structure of the entire event venue and the possible flow paths of personnel. This map supports the application of various graph algorithms, such as the shortest path algorithm for evacuation route planning, graph traversal algorithms for back pressure conduction calculations, and connectivity analysis for identifying isolated areas or bottleneck locations. Furthermore, the guided connectivity map can be visualized, using 3D rendering technology to draw nodes and edges in 3D space, intuitively showing the spatial connectivity relationships and helping security personnel understand the venue's topology. In practical applications, the connectivity map can be dynamically updated according to real-time conditions; for example, if a passage is closed for any reason, the corresponding edge is deleted; if an exit is temporarily opened, a new edge is added. By maintaining a dynamic 3D guided connectivity map, the system can adapt to changes in the venue's status in real time, providing an accurate topological basis for situational analysis.
[0096] This implementation achieves accurate modeling and efficient representation of complex three-dimensional spatial topological connections. By systematically identifying the adjacent voxels of each voxel, a complete spatial adjacency relationship is established, providing a comprehensive candidate set for subsequent connectivity assessment. Physical connectivity is determined by comprehensively considering various factors such as the obstructive effect of building components, height differences, and the status of doors and windows, ensuring the accuracy and realism of connectivity relationships and avoiding marking physically inaccessible voxel pairs as connected. By meticulously determining the connection direction and directionality, the directional characteristics and one-way / bidirectional attributes of personnel flow are accurately reflected, providing crucial information for the construction of directed graphs. By constructing an adjacency matrix containing flow weights, not only are topological connections expressed, but the strength of connectivity is also quantified. Multi-dimensional factors such as geometric permeability, movement direction, and opening characteristics are comprehensively considered, ensuring that the weights accurately reflect the ease or difficulty of personnel flow along different paths. By converting the adjacency matrix into a three-dimensional directed connectivity graph, an efficient graph data structure is provided, supporting the application of various graph algorithms and providing a solid topological foundation for subsequent complex calculations such as back pressure conduction, path planning, and connectivity analysis. The connectivity diagram generated by this method accurately reflects the real connectivity characteristics of three-dimensional space, significantly improving the accuracy of personnel flow simulation and situation analysis. It is a core technical link for realizing real-time analysis of activity situation based on two-dimensional and three-dimensional integrated systems.
[0097] In one embodiment of this example, dynamically updating the remaining permeability of each voxel based on particle density includes the following steps: S510. Calculate the ratio of the total volume of particles within a voxel to the voxel space capacity based on the particle density, and use it as the space occupancy rate. S520. When the space occupancy rate is lower than the preset saturation density threshold, calculate the product of the space occupancy rate and the geometric permeability parameter to obtain the target value. S530. Subtract the target value from the geometric permeability parameter to obtain the remaining permeability; S540. When the space occupancy rate reaches or exceeds the saturation density threshold, the remaining permeability is set to zero, indicating a completely blocked state.
[0098] During real-time monitoring, the number of people within each voxel changes continuously with crowd movement, requiring dynamic updates to the remaining permeability based on particle density. Particle density refers to the number of people per unit volume, calculated by dividing the current total number of people within the voxel by the voxel's spatial capacity.
[0099] In practical implementation, the first step is to determine the number of particles within a voxel. This data comes from the process in step S103 where the camera-identified target is mapped to voxel particles. The system maintains the current particle count for each voxel in real time. Then, the spatial capacity of the voxel is calculated. Spatial capacity refers to the effective usable volume of the voxel, which is equal to the voxel's geometric volume minus the volume occupied by fixed obstacles. For example, a voxel 4 meters long, 3 meters wide, and 3 meters high has a geometric volume of 36 cubic meters. If there are two pillars inside, each occupying 0.6 cubic meters, then the spatial capacity is 34.8 cubic meters. Assuming there are currently 20 people in this voxel, the particle density is... Persons per cubic meter.
[0100] When calculating space occupancy, the average volume occupied by each person needs to be considered. According to ergonomic studies, a standing adult occupies approximately 0.2-0.3 cubic meters of effective space in a crowded environment, including body volume and necessary movement space. In practical implementation, a standard person volume can be set at 0.25 cubic meters. The total volume of particles within a voxel equals the number of particles multiplied by the standard person volume. For the example above, the total volume for 20 people is... cubic meters. Space occupancy rate is the ratio of the total particle volume to the voxel space capacity, calculated as... This is 14.4%. This ratio directly reflects the degree to which voxel space is occupied by people and is a key indicator for assessing voxel crowding. By calculating the space occupancy rate in real time, the system can dynamically monitor the population density of each voxel, providing accurate basic data for subsequent updates to the remaining penetration rate.
[0101] After obtaining the space occupancy rate, it is necessary to determine whether it is below the preset saturation density threshold. The saturation density threshold is a key parameter that represents the maximum occupancy rate at which the voxel space can maintain normal personnel flow. Exceeding this threshold will cause the space to become crowded or even blocked.
[0102] In practice, setting the saturation density threshold requires comprehensive consideration of space type, function, and safety standards. For open plazas or halls where people have greater freedom of movement, the saturation density threshold can be set at 60%-70%. For corridors or passageways where space is relatively limited, the saturation density threshold is typically set at 40%-50%. For critical evacuation routes such as staircases, to ensure safety, the saturation density threshold should be set even lower, approximately 30%-40%. Taking a corridor voxel as an example, assuming the saturation density threshold is set at 45%, and the current space occupancy rate is 14.4%, significantly lower than the threshold, it indicates that the voxel still has considerable passage capacity.
[0103] At this point, it is necessary to calculate the product of the space occupancy rate and the geometric permeability parameter to obtain the target value. The geometric permeability parameter represents the inherent passage capacity of a voxel; for example, the geometric permeability of a certain corridor voxel is 0.75. The target value is calculated as follows: This target value represents the share of penetration rate already occupied at the current population density. Physically, as the number of people within a voxel increases, mutual interference between people increases, and available passage capacity gradually decreases. By multiplying the space occupancy rate by the geometric penetration rate, a transformation from physical occupancy to passage capacity loss is achieved, establishing a quantitative relationship between population density and penetration rate. This linear relationship assumes that, under unsaturated conditions, the loss of penetration rate is proportional to population density, consistent with the general laws of population flow.
[0104] After calculating the target value, the residual permeability is obtained by subtracting the target value from the geometric permeability parameter. The residual permeability represents the remaining passage capacity of a voxel at the current population density. Continuing the example above, with a geometric permeability of 0.75 and a target value of 0.108, the residual permeability is calculated as follows: This figure indicates that although there are already a certain number of people inside the voxel, approximately 64.2% of the passage capacity is still retained, and people can pass through the voxel relatively smoothly.
[0105] Residual permeability is a dynamically changing parameter. As more people flow into the voxel, particle density increases, space occupancy rises, the target value increases, and the residual permeability decreases accordingly. For example, when the number of people in the voxel increases to 40, the particle density rises to 1.15 people / cubic meter, the total particle volume is 10 cubic meters, the space occupancy rises to 28.7%, and the target value becomes... The remaining penetration rate dropped to As can be seen, the residual permeability continuously decreases with the increase in personnel, reflecting a gradual weakening of passage capacity. Residual permeability plays a crucial role in subsequent back pressure transmission calculations, determining the voxel's ability to absorb and buffer downstream pressure. Voxels with high residual permeability can effectively mitigate pressure transmission, while voxels with low residual permeability allow pressure to diffuse upstream more quickly. By updating the residual permeability in real time, the system can accurately reflect the dynamic passage status of each voxel, providing precise parameter support for pressure transmission and risk warning.
[0106] When the space occupancy rate continues to increase and reaches or exceeds the saturation density threshold, the voxel enters a saturated or supersaturated state. At this point, the remaining permeability needs to be set to zero, indicating a completely blocked state. Continuing with the previous example of the corridor voxel, when the number of people inside the voxel increases to 63, the total particle volume is 15.75 cubic meters, and the space occupancy rate reaches... This represents 45.3%, exceeding the 45% saturation density threshold. At this point, the voxel space is extremely crowded, with almost no room for movement between people. Physical contact and pushing are severe, making normal walking and passage extremely difficult or even impossible. In this state, the voxel's passage capacity is effectively lost; it can no longer accept more people or allow existing people to flow out smoothly. Therefore, forcing the remaining permeability to zero indicates a state of complete blockage.
[0107] This setup has significant physical implications and practical value. First, it accurately reflects the traffic characteristics under extreme congestion conditions, avoiding potentially unreasonable predictions from linear models in high-density areas. Second, a zero residual permeability means that the voxel cannot buffer any back pressure from downstream; all pressure will be directly transmitted upstream, triggering a strong warning signal in back pressure transmission calculations. Third, voxels in a completely blocked state are marked as impassable during path planning, and evacuation algorithms automatically avoid these areas, finding alternative routes.
[0108] In practical implementation, a buffer zone can be set up. For example, when the space occupancy rate is between 40% and 45%, the remaining permeability decreases rapidly according to an accelerated decay function, rather than maintaining a linear relationship. This more realistically simulates the sharp decline in traffic capacity when approaching saturation. Once the occupancy rate exceeds 45%, the remaining permeability is directly set to zero. Through this threshold judgment and state switching mechanism, the system can accurately identify and mark completely blocked danger zones, providing timely early warning information for emergency response.
[0109] This implementation achieves real-time dynamic assessment of voxel traffic capacity. By calculating space occupancy rate, the abstract concept of personnel density is transformed into an intuitive percentage of space occupancy, accurately quantifying the congestion level of voxels and providing a clear basic indicator for subsequent judgment. By introducing a saturation density threshold, normal flow and congestion / blockage states are distinguished, enabling the system to identify when a voxel changes from passable to impassable—a crucial state identification for risk warning. By calculating the occupied permeability share by multiplying the space occupancy rate by the geometric permeability, a quantitative relationship between personnel density and traffic capacity loss is established, allowing the remaining permeability to accurately reflect dynamic changes in traffic capacity. By subtracting the occupied share from the geometric permeability to obtain the remaining permeability, the conversion from static spatial attributes to dynamic flow capacity is realized, ensuring that the traffic capacity assessment of each voxel considers not only inherent spatial characteristics but also the impact of personnel density in real time. By setting the remaining permeability to zero when the saturation threshold is exceeded, a complete blockage state is accurately identified, avoiding the failure of the mathematical model in extreme cases and ensuring the reliability of risk assessment. The dynamic update mechanism for residual permeability implemented by this method provides key dynamic parameters for subsequent back pressure transmission calculations, enabling the system to accurately simulate the propagation process of congestion pressure in three-dimensional space. This significantly improves the accuracy and timeliness of congestion risk prediction and is the core technical support for realizing real-time analysis of activity status.
[0110] In one embodiment of this example, the back pressure conduction value is calculated by traversing upstream voxels in reverse along a three-dimensional directional pathway based on the observation points of downstream voxels, and calculating the back pressure conduction value based on the residual permeability of each voxel, including the following steps: S610, Obtain the flow resistance value at the observation point of the downstream voxel; S620. Calculate the initial back pressure intensity based on the flow resistance value, where the greater the flow resistance, the higher the initial back pressure intensity. S630. Starting from the observation point of the downstream voxel, back pressure is transmitted to the adjacent upstream voxel along the reverse edge of the three-dimensional guided graph based on the initial back pressure intensity. S640. Calculate the attenuation coefficient of back pressure during conduction based on the residual permeability of each voxel, and calculate the back pressure conduction value based on the attenuation coefficient.
[0111] In this embodiment, the attenuation coefficient of back pressure during conduction is calculated based on the residual permeability of each voxel, and the back pressure conduction value is calculated based on the attenuation coefficient, including: Obtain the remaining permeability of the current upstream voxel; The remaining permeability is normalized to obtain the normalized permeability. Calculate the reciprocal of the normalized permeability as the impedance amplification factor; The attenuation coefficient is obtained by multiplying the preset reference attenuation rate by the impedance amplification factor. Obtain the back pressure value transferred from the downstream voxel to the current upstream voxel; Multiplying the back pressure value by the attenuation coefficient yields the back pressure conduction value of the current upstream voxel.
[0112] Based on the backpressure conduction value, the backpressure generated by the downstream voxel is superimposed on the potential energy field of the upstream voxel, and the calculation is iteratively performed until the backpressure decays to zero, including: Initialize the iteration counter and set the initial value of the back pressure to the back pressure transmission value of the downstream voxel; The back pressure conduction value of the current upstream voxel is accumulated into the potential energy field of that voxel, and the numerical distribution of the potential energy field is updated. The back pressure is transmitted to the upstream voxel along the three-dimensional guided pathway, and a new back pressure transmission value is calculated based on the remaining permeability of the upstream voxel. Determine whether the new back pressure conduction value is less than the preset back pressure attenuation threshold; If the new back pressure transmission value is less than the back pressure attenuation threshold, the back pressure attenuation is determined to be zero, and the iteration is terminated. If the new back pressure transmission value is greater than or equal to the back pressure attenuation threshold, the iteration counter is incremented by one, and the superposition and transmission steps are repeated until the back pressure attenuation is zero or the iteration counter reaches the maximum number of iterations.
[0113] When conducting back pressure transmission analysis, the first step is to obtain the flow resistance values at downstream voxel observation points. These observation points are typically located at key security nodes, such as main exits, security checkpoints, and stairwells—locations that significantly impact pedestrian flow. The flow resistance at these locations directly reflects the degree of congestion and the difficulty of passage.
[0114] In actual implementation, the flow resistance value has already been calculated in step S104. It is a result of a comprehensive calculation based on the particle density, average viscosity, and geometric permeability parameters of the voxel. Specifically, the flow resistance is directly proportional to the particle density and average viscosity, and inversely proportional to the geometric permeability. For example, if the current particle density of a major outlet voxel is 2.5 μg / m³, the average viscosity coefficient is 3.2, and the geometric permeability is 0.6, then the flow resistance can be calculated as follows: This value indicates high flow resistance at the exit, making it difficult for people to pass. The system monitors the flow resistance values at all observation points in real time. When the flow resistance at a certain observation point exceeds the warning threshold, back pressure transmission analysis needs to be initiated to assess the impact of the congestion point on the upstream area. Obtaining the flow resistance value is the starting point for back pressure transmission calculation; it quantifies the severity of the downstream bottleneck and provides a data basis for calculating the initial back pressure intensity. By acquiring and monitoring the flow resistance at observation points in real time, the system can promptly identify potential sources of congestion and activate corresponding analysis and early warning mechanisms.
[0115] After obtaining the flow resistance value, the initial back pressure intensity needs to be calculated based on this value. The initial back pressure intensity represents the pressure exerted upstream by the downstream congestion point. The greater the flow resistance, the more congested the downstream area, and the greater the pressure impact on the upstream area. Therefore, the initial back pressure intensity is higher.
[0116] In practice, a nonlinear mapping relationship is used between the initial back pressure and the flow resistance value to reflect the accelerated growth of pressure impact as congestion intensifies. This mapping relationship can be established using an exponential function or a piecewise linear function. For example, when the flow resistance value is between 0 and 5, it is considered light resistance, and the initial back pressure is set to 1.2 times the flow resistance value; when the flow resistance value is between 5 and 10, it is considered moderate resistance, and the initial back pressure is set to 1.5 times the flow resistance value; when the flow resistance value exceeds 10, it is considered high resistance, and the initial back pressure is set to 2.0 times the flow resistance value. For the outlet with a flow resistance of 13.3 in the aforementioned example, the initial back pressure is calculated as follows: This amplification mechanism reflects an important physical phenomenon: when severe congestion occurs downstream, not only does the location itself become difficult to pass through, but it also has a significant "blockage effect" upstream, causing people to linger and accumulate in the upstream area, creating a chain reaction. By amplifying the flow resistance to the initial back pressure intensity, the system can accurately assess the scope and intensity of the impact of the downstream bottleneck on the entire upstream area, providing reasonable initial conditions for subsequent pressure transmission calculations.
[0117] After determining the initial back pressure intensity, starting from the observation point of the downstream voxel, the back pressure is transmitted to the adjacent upstream voxel along the reverse edge of the three-dimensional directional flow diagram. The edges in the three-dimensional directional flow diagram represent the possible flow directions of personnel, while the reverse edge represents the direction opposite to the flow direction, i.e., from downstream to upstream.
[0118] In practice, for each observation point voxel, its set of incoming edges in the connectivity graph is first queried. The starting point of each incoming edge is the directly upstream voxel of that observation point. For example, an exit observation point has three incoming edges, originating from corridor A, corridor B, and staircase C respectively. These three voxels are the directly upstream voxels of that observation point. The backpressure transmission process involves distributing the initial backpressure intensity to these upstream voxels. The distribution method needs to consider the flow weight of each incoming edge; paths with higher flow weights carry more pedestrian traffic and therefore should bear greater backpressure.
[0119] In the specific calculation, the flow weights of all incoming edges are first normalized, and the weight percentage of each edge is calculated. For example, if the flow weight of corridor A is 0.7, corridor B is 0.5, staircase C is 0.4, and the total weight is 1.6, then the weight percentage of corridor A is... The back pressure for corridor B is 0.313, and for staircase C it is 0.25. Then, the initial back pressure intensity is allocated according to the weighted proportions, with corridor A receiving a back pressure of... Corridor B receives Staircase C receives This weighted allocation mechanism ensures that back pressure transmission conforms to the actual distribution of pedestrian flow, with the main flow paths bearing the main pressure. The back pressure value transmitted to the upstream voxel becomes the initial back pressure of that voxel, which will be further transmitted to more upstream areas in subsequent steps based on the remaining permeability of that voxel.
[0120] Back pressure gradually decreases as it is transmitted upstream, and the degree of decrease depends on the residual permeability of the voxel. Voxels with high residual permeability have a strong buffering capacity and can absorb part of the back pressure, thus reducing the pressure transmitted upstream; voxels with low residual permeability have a weak buffering capacity, and the back pressure will continue to be transmitted with a smaller decrease.
[0121] In practice, the remaining permeability of the current upstream voxel is first obtained, a value that has been dynamically updated in step S105. For example, the remaining permeability of corridor A voxel is 0.55. Then, the remaining permeability is normalized to ensure it is between 0 and 1. Since the remaining permeability is already a proportional value between 0 and 1, the normalization process mainly confirms the reasonableness of the numerical range. The normalized permeability is 0.55. Next, the reciprocal of the normalized permeability is calculated as the impedance amplification factor. The impedance amplification factor reflects the degree of resistance of the voxel to back pressure conduction; the lower the permeability, the greater the resistance, and the smaller the back pressure attenuation. The impedance amplification factor for corridor A is... .
[0122] Then, the preset reference attenuation rate is multiplied by the impedance amplification factor to obtain the attenuation coefficient. The reference attenuation rate is an empirical parameter, usually set to 0.3-0.5, representing the attenuation ratio after one stage of back pressure conduction under standard conditions. Assuming the reference attenuation rate is 0.4, the attenuation coefficient is calculated as follows: This attenuation coefficient is greater than the baseline attenuation rate, indicating that due to the low remaining permeability of this voxel, its buffering capacity is insufficient, resulting in a small back pressure attenuation, and most of the pressure will continue to be transmitted upstream. Finally, the back pressure value transmitted from the downstream voxel to the current upstream voxel, i.e., the previously calculated 11.65, is obtained. Multiplying this by the attenuation coefficient, the back pressure transmission value of the current upstream voxel is obtained: This back pressure transmission value indicates that after receiving a back pressure of 11.65, corridor A, through its own buffering and attenuation, will transmit a pressure of 8.47 upstream. Through this attenuation calculation based on residual permeability, the system can accurately simulate the propagation characteristics of back pressure in three-dimensional space, reflecting the different responses of different voxels to pressure.
[0123] The calculation of back pressure transmission value is a recursive process, requiring propagation upstream level by level. After calculating the back pressure transmission value of the first-level upstream voxels, these voxels become new pressure sources, continuing to transmit back pressure upstream. For voxel A in corridor, its back pressure transmission value is 8.47. This voxel may have multiple upstream connections, such as connections to hall D and passage E. Using the same flow weighting method, assuming the flow weight of hall D is 0.6, passage E is 0.4, and the total weight is 1.0, then the back pressure received by hall D is... Channel E receives .
[0124] Then, the remaining permeability of hall D and channel E are obtained separately, assuming the remaining permeability of hall D is 0.72 and that of channel E is 0.38. The impedance amplification factor of hall D is... The attenuation coefficient is Back pressure conduction value The impedance amplification factor of channel E is... The attenuation coefficient is Since the attenuation coefficient exceeds 1.0, it needs to be truncated to 1.0. This indicates that the voxel's remaining permeability is extremely low, making it almost unable to buffer back pressure. The back pressure conduction value is... As can be seen, due to the very low residual permeability of channel E, the back pressure is conducted with almost no attenuation. This voxel acts as a "pressure amplifier" in the conduction chain, causing the upstream region to experience greater pressure. Through this step-by-step conduction and attenuation calculation, the back pressure will continue to diffuse upstream along the reverse path of the conduction diagram until it attenuates to zero or reaches the spatial boundary.
[0125] After calculating the back pressure transmission values of each upstream voxel, these back pressures need to be superimposed onto the voxel's potential energy field. The potential energy field is a physical quantity that describes the energy state of a voxel, including the original potential energy generated by the voxel's own congestion state and the back pressure from downstream.
[0126] In practice, the iteration counter is first initialized to 0, and the initial value of the backpressure is set to the backpressure conduction value of the downstream voxel. For the first-stage upstream voxel, such as corridor A receiving a backpressure conduction value of 11.65, this is used as the initial value of its backpressure. Then, this backpressure is accumulated into the potential energy field of corridor A. Assuming the original potential energy value of corridor A is 8.5 (calculated from its own flow resistance and particle density), after adding the backpressure, the total potential energy becomes... This total potential energy is significantly higher than the original potential energy, indicating that downstream congestion has exerted a strong pressure effect on this voxel.
[0127] Next, the back pressure is transmitted upstream along the 3D guided pathway diagram to the next higher voxel, specifically to Hall D and Channel E. Based on the previous calculations, Hall D receives a back pressure of 5.08, and Channel E receives 3.39. New back pressure transmission values are calculated based on their remaining permeability: 2.82 for Hall D and 3.39 for Channel E. Then, it is determined whether these new back pressure transmission values are less than a preset back pressure attenuation threshold. The back pressure attenuation threshold is typically set between 0.5 and 1.0, indicating that when the back pressure attenuates below this value, its impact is negligible. Assuming a threshold of 0.8, the back pressure transmission values of 2.82 for Hall D and 3.39 for Channel E are both greater than the threshold, therefore, further iterations are required.
[0128] The iteration counter is incremented to 1, and the superposition and propagation steps are repeated. The backpressure conduction value of 2.82 from hall D is added to its potential energy field, and the backpressure conduction value of 3.39 from channel E is added to its potential energy field, and then the propagation continues upstream. This process continues until all backpressure conduction values at a certain level are less than the attenuation threshold, or the iteration counter reaches the preset maximum number of iterations, such as 10. The maximum number of iterations is set to prevent infinite loops in certain special topologies (such as loops). Through this iterative mechanism, the backpressure diffuses upstream layer by layer, gradually expanding its influence range, but gradually weakening in intensity, eventually attenuating to zero in areas far from the observation point.
[0129] There are two termination conditions for iterative calculations: first, all newly calculated backpressure conduction values are less than the backpressure decay threshold; second, the maximum number of iterations is reached. In practice, after each iteration, the backpressure conduction values of all voxels at the current level need to be checked. Assume that after the third iteration, the current level includes 5 voxels with backpressure conduction values of 0.6, 0.9, 0.4, 0.7, and 0.5. Comparing these values with the threshold of 0.8, we find that one value, 0.9, is greater than the threshold, therefore, the iteration cannot terminate and needs to continue. After the fourth iteration, the current level includes 8 voxels with backpressure conduction values of 0.3, 0.5, 0.2, 0.6, 0.4, 0.7, 0.3, and 0.5. All values are less than 0.8, at which point it is determined that the backpressure has decayed to zero, and the iteration terminates.
[0130] At this point, the iteration counter is 4, far less than the maximum number of iterations of 10, indicating that the back pressure has completely decayed within a reasonable propagation range. If the back pressure transmission value still exceeds the threshold when the maximum number of iterations is reached, the system will forcibly terminate the iteration and record a warning message, indicating the possible existence of an abnormal pressure transmission path or topological loop. Throughout the iteration process, the system maintains a potential energy field update record, recording the back pressure received by each voxel in each iteration and the accumulated total potential energy. This data is used not only for current risk assessment but also for post-event analysis and model optimization. Through complete iterative calculations, the system can accurately simulate the impact of downstream congestion on the entire upstream area, identify all affected voxels and their degree of impact, and provide comprehensive data support for global situation analysis and risk warning.
[0131] This implementation achieves accurate simulation and quantitative assessment of the congestion pressure propagation process in three-dimensional space. By acquiring the flow resistance value of downstream observation points and calculating the initial back pressure intensity, the pressure magnitude at the congestion source is accurately quantified. A nonlinear amplification mechanism is used to reflect the chain effect of severe congestion, providing reasonable initial conditions for pressure transmission. By transmitting back pressure along the reverse edge of the three-dimensional directional flow diagram and employing a flow weighted allocation mechanism, the back pressure transmission is ensured to conform to the actual pedestrian flow distribution and spatial topology, avoiding assessment biases that may be caused by uniform distribution. By calculating the attenuation coefficient based on residual permeability, a quantitative relationship between voxel buffering capacity and back pressure attenuation is established, accurately reflecting the different response characteristics of different voxels to pressure transmission. This allows voxels with high residual permeability to effectively alleviate pressure diffusion, while voxels with low residual permeability become fast channels for pressure transmission. Through an iterative calculation mechanism, the layer-by-layer propagation of back pressure and dynamic updating of the potential energy field are realized, enabling the tracking of the complete path and range of pressure influence and identifying all upstream areas affected by downstream congestion. By setting a back pressure attenuation threshold and a maximum number of iterations, the convergence and computational efficiency of the iterative process are ensured, avoiding infinite loops and overcomputation. This method breaks through the limitations of traditional two-dimensional analysis that only considers local density. It introduces the pressure transmission mechanism in three-dimensional space, which can predict the impact of downstream bottlenecks on upstream areas, identify potential congestion spillover risks in advance, provide security personnel with valuable early warning time and decision-making basis, and significantly improve the initiative and effectiveness of security management in large event venues.
[0132] In one embodiment of this invention, if the total potential energy of the upstream voxel's potential field after superimposed backtracking pressure exceeds a safety threshold, it is determined that the corresponding region has a risk of future congestion overflow, including the following steps: S710. Calculate the initial potential energy of the upstream voxel. The initial potential energy is equal to the product of the flow resistance and the particle density. S720. Add the original potential energy value to the superimposed back pressure value to obtain the total potential energy of the potential energy field. S730. If the total potential energy exceeds the safety threshold, it is determined that the area corresponding to the upstream voxel has a risk of future congestion overflow.
[0133] After completing the back pressure conduction and potential field superposition, a risk assessment needs to be performed on each upstream voxel. First, the original potential energy value of the upstream voxel is calculated. The original potential energy value reflects the energy level generated by the voxel's own congestion state and does not include the pressure influence from downstream.
[0134] In practice, the initial potential energy value is calculated by multiplying the flow resistance and particle density. The flow resistance, already calculated in step S104, comprehensively reflects the difficulty of personnel movement within the voxel and is influenced by particle density, average viscosity, and geometric permeability. Particle density represents the number of personnel per unit volume and is updated in real-time in step S105. Multiplying these two parameters yields the initial potential energy value. For example, if the flow resistance of a voxel at a stairwell is 9.5 and the particle density is 1.8 people / cubic meter, then the initial potential energy value is calculated as follows: The physical meaning of this value is that the voxel has accumulated a considerable amount of "congestion energy" due to its high population density and limited space. The higher the initial potential energy value, the more severe the congestion of the voxel, and even without considering downstream pressure, there may be safety hazards. Calculating the potential energy by multiplying flow resistance and particle density reflects the synergistic effect of these two factors: the more people there are and the more difficult their movement, the faster the potential energy accumulates. This calculation method ensures that the initial potential energy accurately reflects the real-time congestion state of the voxel, providing basic data for subsequent total potential energy calculation and risk assessment.
[0135] After obtaining the original potential energy value, it needs to be added to the superimposed backpressure value to obtain the total potential energy of the potential energy field. The backpressure value is accumulated during the iterative calculation in step S107, and it represents the sum of the pressure effects from the downstream congestion point on the voxel.
[0136] In practice, a voxel may be affected by downstream pressure through multiple paths. For example, a hall voxel may be connected to two different exits simultaneously. If both exits are congested, they will transmit back pressure to the hall. During the iteration process, the system accumulates all back pressure transmitted to the voxel to obtain the total back pressure value of the voxel. Continuing with the example of the stairwell voxel, assuming that the voxel receives a back pressure of 15.3 from the downstream exit during the iterative calculation, the original potential energy value of 17.1 is added to the back pressure value of 15.3 to obtain the total potential energy. This total potential energy is significantly higher than the original potential energy, indicating that downstream congestion has exerted a strong pressure superposition effect on this voxel.
[0137] The physical meaning of total potential energy is the comprehensive energy state of a voxel. It not only reflects the current level of congestion but also proactively considers the impact of downstream bottlenecks on the future state of that location. Even if the current population density of a voxel has not yet reached a dangerous level, if there is severe congestion downstream, a large number of people will be forced to remain in that voxel, causing the density to rise rapidly and resulting in congestion overflow. By adding the initial potential energy to the retrospective pressure to calculate the total potential energy, the system can comprehensively assess the current state and future trends of voxels, realizing the transformation from static assessment to dynamic prediction.
[0138] After calculating the total potential energy, it needs to be compared with a preset safety threshold to determine whether there is a risk of future congestion overflow. The safety threshold is a key risk assessment criterion; it represents the maximum potential energy level that a voxel can safely withstand. Exceeding this threshold means that the voxel has entered a dangerous state.
[0139] In practice, setting safety thresholds requires comprehensive consideration of multiple factors. First, the type of space must be considered, as different types of spaces have different safety requirements. For evacuation routes such as staircases and corridors, the safety threshold should be set lower, for example, 20-25, to ensure unobstructed evacuation paths. For temporary waiting spaces such as halls and plazas, the safety threshold can be appropriately increased, for example, 30-35. For fixed activity areas such as auditoriums and stands, the threshold can be even higher, for example, 40-45. Second, historical data and accident cases should be considered. By analyzing the potential energy levels during past congestion incidents, an empirical danger threshold can be determined. Third, safety regulations and standards should be considered. Referring to building design codes, fire safety codes, and other regulations regarding personnel density and evacuation capacity, these requirements should be translated into potential energy thresholds.
[0140] For the aforementioned stairwell voxel, assuming a safety threshold of 25, the calculated total potential energy is 32.4, significantly exceeding the safety threshold. Therefore, it is determined that the area corresponding to this stairwell has a risk of future congestion overflow. This determination means that although the stairwell may not be completely blocked at present, due to congestion at the downstream exit, a large number of people will accumulate here, quickly leading to a dangerous state of overcrowding and posing a risk of stampedes and other safety accidents. The system will immediately generate a warning message, marking the voxel as a high-risk area and highlighting it in red on the visual interface to remind security personnel to pay close attention. Simultaneously, the emergency response mechanism will be triggered, recommending intervention measures such as crowd control and path guidance to prevent the risk from escalating into an actual accident.
[0141] This implementation method achieves accurate prediction and timely early warning of congestion overflow risks in three-dimensional space. By calculating the original potential energy value, the congestion state of the voxel itself is accurately quantified. The product of flow resistance and particle density is used to reflect the synergistic effect of personnel density and movement difficulty, ensuring the scientific nature of the potential energy assessment. By adding the original potential energy to the backflow pressure to obtain the total potential energy, a fusion assessment of local state and global impact is innovatively achieved. It not only considers the current congestion level of the voxel but also proactively considers the impact of downstream congestion on the future state of the location, breaking through the limitations of traditional methods that only assess risk based on current density. By setting safety thresholds and making comparative judgments, a clear risk identification standard is established, which can automatically identify dangerous areas with future congestion overflow risks, realizing the transformation from passive response to proactive early warning. The core value of this method lies in its predictive ability, which can identify potential dangerous areas before congestion actually occurs, providing security personnel with a valuable early warning window, enabling them to take intervention measures in advance, such as controlling the entry speed of upstream personnel, guiding the flow of people to detour, and increasing on-site management personnel, effectively preventing congestion accidents. Compared with traditional early warning methods based on current density thresholds, this method can capture complex pressure propagation effects in three-dimensional space through potential energy fields and back pressure transmission mechanisms, accurately assess the chain reaction of downstream bottlenecks on upstream areas, significantly improve the accuracy and timeliness of risk prediction, and provide scientific and reliable technical support for the safety management of large-scale event venues.
[0142] In one embodiment of this invention, identifying high-potential-energy clusters and low-potential-energy cavities in three-dimensional space, and determining the evacuation path with least resistance based on the high-potential-energy clusters and low-potential-energy cavities, includes the following steps: S810. Iterate through each voxel to obtain the total potential energy value, and mark the continuous regions with total potential energy values higher than the high potential energy threshold as high potential energy clusters. S820. Mark continuous regions with total potential energy values below the low potential energy threshold as low potential energy cavities. S830. Starting from the voxels in the high potential energy cluster, calculate the potential energy gradient with the adjacent voxels, and take the direction with the fastest decrease in potential energy gradient as the preferred flow direction. S840. Iteratively search along the preferred flow direction until a low potential energy cavity is reached, generating a search path; S850: Generate the evacuation path with the least resistance based on all voxels on the search path.
[0143] After calculating the potential energy field and identifying risk areas, it is necessary to further identify high potential energy clusters in three-dimensional space to provide starting point information for evacuation route planning. High potential energy clusters refer to continuous spatial regions where the total potential energy value is consistently higher than the high potential energy threshold. These regions typically correspond to locations with severe or impending congestion.
[0144] In practice, the process first iterates through all voxels in the spatial voxel grid, obtaining the total potential energy value for each voxel calculated in step S720. The total potential energy value comprehensively reflects the current congestion state of the voxel and the impact of downstream pressure. Then, the total potential energy value of each voxel is compared with a preset high potential energy threshold. The high potential energy threshold is typically set to 1.2-1.5 times the safety threshold; for example, if the safety threshold is 25, the high potential energy threshold can be set to 30-35 to identify dangerous areas that significantly exceed the safety level. Voxels with total potential energy values higher than the high potential energy threshold are marked as high-potential-energy voxels.
[0145] Next, continuous regions need to be identified using region growing or connected component analysis algorithms. Starting from any high-potential-energy voxel, its neighboring voxels in the 3D guided connected graph are examined. If a neighboring voxel is also a high-potential-energy voxel, it is included in the same region, and the process continues to expand to the neighboring voxels of that voxel until no more high-potential-energy neighboring voxels can be found. In this way, spatially continuous high-potential-energy voxels can be aggregated into a high-potential-energy cluster. For example, in the stands of a stadium, due to the high density of people and congestion at the downstream exit, the total potential energy of multiple voxels in this area exceeds 35. These voxels are spatially adjacent and continuous, and are identified as a high-potential-energy cluster. There may be multiple high-potential-energy clusters in a 3D space, each corresponding to a different congested area. The system assigns a unique identifier to each high-potential-energy cluster and records its voxel list, total volume, average potential energy, and other attribute information, providing detailed starting point data for subsequent evacuation path planning.
[0146] In contrast to high-potential-energy clusters, low-potential-energy cavities refer to continuous spatial regions where the total potential energy value is consistently below the low-potential-energy threshold. These regions typically correspond to relatively open, sparsely populated, and easily passable locations, such as open squares, vacant evacuation routes, and unsaturated exits.
[0147] In practical implementation, the setting of the low potential energy threshold needs to consider the normal operating status of voxels. For evacuation routes and exits, the low potential energy threshold can be set to 8-12, indicating smooth personnel flow; for activity areas, the threshold can be set to 10-15. All voxels are traversed, and voxels with a total potential energy value below the low potential energy threshold are marked as low potential energy voxels. Then, using the same region growing algorithm as for identifying high potential energy clusters, spatially continuous low potential energy voxels are aggregated into low potential energy cavities. For example, in the eastern exit area of an activity venue, due to the high passage capacity and low number of people at this exit, the total potential energy of multiple voxels in this area is below 10, and these voxels are identified as a low potential energy cavity.
[0148] Low-potential-energy cavities represent target evacuation areas, spaces where people can safely transfer. In evacuation route planning, low-potential-energy cavities serve as the endpoints of the routes, with the goal of guiding people from high-potential-energy clusters to these safe areas. The system also assigns a unique identifier to each low-potential-energy cavity, recording its spatial location, capacity, and current number of people. By simultaneously identifying both high-potential-energy clusters and low-potential-energy cavities, the system establishes a set of starting and ending points for evacuation route planning, providing clear target guidance for subsequent route searches. This starting and ending point identification method based on potential energy field distribution can automatically adapt to dynamically changing personnel distribution and spatial conditions, eliminating the need for manual specification of evacuation starting and ending points, thus improving the system's intelligence level.
[0149] After identifying high-potential energy clusters and low-potential energy cavities, it is necessary to determine the preferred flow direction for evacuation from the high-potential energy clusters to the low-potential energy cavities. In practice, starting with a voxel in a high-potential energy cluster, the potential energy gradient between that voxel and all its neighboring voxels is calculated. The potential energy gradient represents the rate and direction of potential energy change and is mathematically defined as the spatial derivative of the potential energy value. For a discrete voxel grid, the potential energy gradient can be approximated by the potential energy difference between adjacent voxels.
[0150] Specifically, for the current voxel i, its total potential energy is The total potential energy of adjacent voxel j is The potential energy gradient between the two voxels is calculated as follows: ,in This is the distance between the centers of two voxels. A positive potential energy gradient indicates a decrease in potential energy from voxel i to voxel j; a larger gradient value indicates a faster decrease. For example, voxel A in a high-potential-energy cluster has a total potential energy of 38 and three adjacent voxels: voxel B has a total potential energy of 32 and is 2 meters away; voxel C has a total potential energy of 35 and is 2 meters away; and voxel D has a total potential energy of 28 and is 3 meters away. The potential energy gradients are calculated as follows: , , Comparing the three gradient values, the gradient in the direction of voxel D is the largest, therefore the direction pointing to voxel D is selected as the preferred flow direction.
[0151] The preferred flow direction points towards the region of fastest potential energy decrease. This means that when people move in this direction, they can quickly move from a high-potential-energy region to a low-potential-energy region, experiencing minimal flow resistance and maximizing evacuation efficiency. By calculating the potential energy gradient to determine the flow direction, path optimization based on physical field theory is achieved. This method better reflects the actual laws of crowd flow than traditional shortest path algorithms because people tend to move towards directions with less resistance and more open space, rather than simply the shortest distance.
[0152] After determining the preferred flow direction, an iterative search is needed along that direction to generate a complete path from the high-potential energy cluster to the low-potential energy cavity. In practice, starting from the initial voxel in the high-potential energy cluster, the flow is moved to the next adjacent voxel according to the preferred flow direction calculated in step S830, and this voxel is added to the search path. Then, with the newly arrived voxel as the current position, the potential energy gradient between it and its adjacent voxels is repeatedly calculated, the preferred flow direction is determined again, and the flow is moved to the next voxel. This process continues to iterate, each time choosing the direction with the fastest decrease in potential energy gradient. The iteration terminates when a low-potential energy cavity is reached, meaning the current voxel belongs to a low-potential energy cavity region identified in step S820.
[0153] For example, starting from voxel A, the preferred direction is voxel D. After moving to D, the total potential energy of D is 28, the total potential energy of its neighboring voxel E is 22, and the total potential energy of voxel F is 25. After calculating the gradient, E is selected as the next step. After moving to E, the total potential energy of E's neighboring voxel G is 15, and the total potential energy of voxel H is 18. G is selected. After moving to G, it is found that G belongs to a low potential cavity, and the iteration terminates. The voxel sequence A, D, E, and G generated by the entire search process constitutes the search path.
[0154] In practical implementation, several special cases need to be addressed. First, there's the local minimum problem, where the potential energy of all adjacent voxels is no lower than the current voxel's, making it impossible to find a descent direction. In this case, a backtracking strategy can be used, returning to the previous voxel and choosing a suboptimal direction to continue the search, or allowing a short-distance potential energy rise can be allowed to escape the local minimum. Second, there's the loop problem, where the search process may return to previously visited voxels, forming a loop. Maintaining a list of visited voxels is necessary to avoid duplicate visits. Third, there's the inaccessibility problem, where some high-potential clusters may be physically inaccessible to any low-potential cavities, causing the search to fail. In this case, the high-potential cluster needs to be marked as an isolated region, and other contingency measures such as on-site evacuation or the creation of temporary passages should be taken.
[0155] After generating the search path, the final evacuation path with minimum resistance needs to be generated based on all voxels along the search path. The search path is a sequence of voxels, while the evacuation path needs to be converted into an executable spatial path and operational instructions.
[0156] In practice, the spatial location information of all voxels along the search path is first extracted, including the center coordinates of each voxel. Then, these discrete voxel center points are connected to form a continuous spatial curve, which can be achieved using straight lines or spline curve fitting to generate a smooth path trajectory. Next, the spatial path needs to be mapped onto the actual building space, identifying the specific locations the path passes through, such as corridors, staircases, and exits. Based on this information, detailed evacuation guidance is generated, including the starting point of the path, key nodes along the way, turning points, and the final exit.
[0157] For example, for the aforementioned generated paths A, D, E, and G, if voxel A is located in the grandstand area, voxel D is located in the connecting passage, voxel E is located on the stairs, and voxel G is located on the east exit plaza, then the evacuation path is described as "from the grandstand area, via the connecting passage to the stairs, downstairs to the east exit plaza." The system also calculates key parameters of the path, such as total path length, estimated evacuation time, and path capacity, to assess the feasibility of the evacuation plan. Path capacity depends on the minimum geometric permeability and residual permeability of all voxels on the path, representing the maximum number of people that can pass through the path per unit time. If the capacity of a certain path is insufficient to evacuate the entire high-potential energy cluster, multiple parallel evacuation paths need to be generated.
[0158] The generated evacuation routes are output to a visualization interface, displayed as 3D animations or 2D maps, with key information annotated. Control commands are also generated, including setting up guidance signs at the route's starting point, deploying guidance personnel at key turns, activating lighting and signage systems along the route, and preparing for reception at the target exit, ensuring the effective execution of the evacuation routes.
[0159] This implementation achieves intelligent evacuation path optimization in complex 3D spaces. By traversing the total potential energy of voxels and employing a region growing algorithm to identify high-potential-energy clusters and low-potential-energy cavities, it accurately locates hazardous areas requiring evacuation and safe areas suitable for accommodating personnel. This provides clear starting and ending points for path planning, avoiding the limitation of traditional methods that require manual specification of evacuation targets. By calculating the potential energy gradient to determine the optimal flow direction, it innovatively applies physical field theory to path planning, ensuring that the planned path considers not only spatial distance but, more importantly, flow resistance and traffic capacity, guaranteeing that the evacuation path is the one with the least resistance and highest efficiency. Through an iterative search mechanism, it achieves automatic path generation from high-potential-energy regions to low-potential-energy regions, adapting to complex 3D spatial topologies and handling complex scenarios such as multi-story buildings and multi-level transportation. By converting voxel paths into actual spatial paths and operational instructions, it achieves a complete closed loop from algorithm results to actual execution, resulting in evacuation paths with strong operability and practicality. Compared to traditional methods based on shortest paths or fixed evacuation plans, this method offers significant advantages: it can dynamically optimize evacuation routes based on real-time personnel distribution and spatial conditions, avoiding congested areas and high-risk routes, making full use of vacant passages and exits, and maximizing evacuation efficiency; it can simultaneously generate multiple parallel routes to achieve the diversion of personnel and avoid overloading of a single route; and it can proactively consider the impact of downstream pressure to avoid guiding personnel to areas that are about to become congested. This technology provides scientific and intelligent decision support for emergency evacuation of large event venues, significantly improving the safety and efficiency of evacuation.
[0160] This application also provides an electronic device, including: The memory is configured to store instructions; and The processor is configured to retrieve the instructions from the memory and, when executing the instructions, to implement the aforementioned real-time activity situation analysis method based on two-dimensional and three-dimensional integration.
[0161] In this embodiment, the electronic device can be a tablet computer, desktop computer, laptop computer, handheld computer, wearable device, laptop computer, ultra-mobile personal computer (UMPC), netbook, or other device with a processor. Of course, the electronic device can also be a server. This application embodiment does not impose any special limitations on the specific form of the electronic device.
[0162] This application embodiment also provides a machine-readable storage medium storing instructions that cause a machine to execute the above-described real-time activity situation analysis method based on two-dimensional and three-dimensional integration.
[0163] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this application can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0164] This application is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this application. It will be understood that each block of the flowchart illustrations and / or block diagrams, as well as combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create a machine for implementing the flowchart illustrations. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0165] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0166] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0167] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.
[0168] Memory may include non-persistent memory in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. Memory is an example of computer-readable media.
[0169] Computer-readable media includes both permanent and non-permanent, removable and non-removable media that can store information using any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.
[0170] It should also be noted that the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article, or apparatus. Unless otherwise specified, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element.
[0171] The above are merely embodiments of this application and are not intended to limit the scope of this application. Various modifications and variations can be made to this application by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the scope of the claims of this application.
Claims
1. A real-time activity situation analysis method based on two-dimensional and three-dimensional integrated analysis, characterized in that, include: Acquire the CIM basic geographic data and BIM building model of the event venue, generate a three-dimensional space of the event venue based on the CIM basic geographic data and BIM building model, and perform voxel discretization processing on the three-dimensional space to generate a spatial voxel mesh. Traverse each voxel in the spatial voxel grid, calculate the geometric permeability parameter, construct the adjacency matrix between voxels, and generate a three-dimensional guided graph based on the adjacency matrix. In response to receiving the target transmitted from the camera, two-dimensional dynamic data is acquired, and the target is mapped to the particle increment within the corresponding voxel based on the two-dimensional dynamic data; The particle density and average viscosity within each voxel are determined in real time based on the particle increment of each voxel, and the flow resistance of each voxel is calculated based on the particle density, average viscosity and geometric permeability parameters within each voxel. The remaining permeability of each voxel is dynamically updated based on particle density; The preset security key nodes are used as observation points of downstream voxels. Based on the observation points of downstream voxels, the upstream voxels are traversed in reverse along the three-dimensional directional pathway diagram. The back pressure transmission value is calculated based on the remaining permeability of each voxel. Based on the back pressure transmission value, the back pressure generated by the downstream voxel is superimposed on the potential energy field of the upstream voxel, and the calculation is iterated until the back pressure decays to zero. If the total potential energy of the upstream voxel after superimposed backtracking pressure exceeds the safety threshold, it is determined that the corresponding area has a risk of future congestion overflow. Identify high-potential-energy clusters and low-potential-energy cavities in three-dimensional space, and determine the evacuation path with the least resistance based on the high-potential-energy clusters and low-potential-energy cavities. Control commands are generated and output based on the evacuation path of least resistance.
2. The method according to claim 1, characterized in that, The three-dimensional space is discretized using voxelization to generate a spatial voxel mesh, including: Extract the geometric topology of the building in three-dimensional space, and recursively segment the three-dimensional space based on the geometric topology to obtain multiple voxels; The spatial complexity of the three-dimensional space is determined based on the geometric topology, and the voxel density of each voxel is adaptively adjusted according to the spatial complexity to generate a spatial voxel mesh.
3. The method according to claim 1, characterized in that, Calculate the geometric permeability parameters, including: Obtain the physical attribute data of each voxel in the spatial voxel grid, where the physical attribute data includes the width, slope and area occupied by obstacles in the physical space corresponding to each voxel; The basic traffic capacity coefficient is calculated based on the width, the slope attenuation factor is calculated based on the slope, and the obstacle blockage coefficient is calculated based on the proportion of area occupied by the obstacle. The geometric permeability parameter is obtained by weighted summation of the basic traffic capacity coefficient, slope attenuation factor, and obstacle blockage coefficient.
4. The method according to claim 1, characterized in that, Construct an adjacency matrix between voxels, and generate a 3D guided graph based on the adjacency matrix, including: Traverse all voxels in the spatial voxel grid and identify the neighboring voxels of each voxel; Determine whether there is physical connectivity between adjacent voxels; If physical connectivity exists, determine the direction of connectivity and directionality, where directionality includes unidirectional or bidirectional; An adjacency matrix is constructed based on the connectivity direction and directionality, where the matrix elements in the adjacency matrix represent the flow weights between voxels; Generate a 3D guided graph based on the adjacency matrix.
5. The method according to claim 1, characterized in that, The remaining permeability of each voxel is dynamically updated based on particle density, including: The ratio of the total volume of particles within a voxel to the voxel's spatial capacity is calculated based on particle density, and this ratio is used as the space occupancy rate. When the space occupancy rate is lower than the preset saturation density threshold, the product of the space occupancy rate and the geometric permeability parameter is calculated to obtain the target value; Subtract the target value from the geometric permeability parameter to obtain the remaining permeability; When the space occupancy rate reaches or exceeds the saturation density threshold, the remaining permeability is set to zero, indicating a completely blocked state.
6. The method according to claim 1, characterized in that, Based on the observation points of downstream voxels, the upstream voxels are traversed in reverse along the three-dimensional directed pathway diagram. The back pressure conduction value is calculated based on the residual permeability of each voxel, including: Obtain the flow resistance value at the observation point of the downstream voxel; The initial back pressure intensity is calculated based on the flow resistance value, where the greater the flow resistance, the higher the initial back pressure intensity. Starting from the observation point of the downstream voxel, back pressure is transmitted to the adjacent upstream voxel based on the initial back pressure intensity along the reverse edge of the three-dimensional guided graph. The attenuation coefficient of back pressure during conduction is calculated based on the residual permeability of each voxel, and the back pressure conduction value is calculated based on the attenuation coefficient.
7. The method according to claim 1, characterized in that, If the total potential energy of the upstream voxel's potential field after superimposed backtracking pressure exceeds the safety threshold, then the corresponding area is determined to have a risk of future congestion overflow, including: Calculate the initial potential energy of the upstream voxel, which is equal to the product of the flow resistance and the particle density. The total potential energy of the potential field is obtained by adding the original potential energy value to the superimposed back pressure value. If the total potential energy exceeds the safety threshold, it is determined that the region corresponding to the upstream voxel has a risk of future congestion overflow.
8. The method according to claim 1, characterized in that, Identify high-potential-energy clusters and low-potential-energy cavities in three-dimensional space, and determine the evacuation path with minimum resistance based on these clusters and cavities, including: Iterate through each voxel to obtain the total potential energy value, and mark the continuous regions with total potential energy values higher than the high potential energy threshold as high potential energy clusters; Continuous regions with total potential energy values below the low potential energy threshold are marked as low potential energy voids. Starting with voxels in high potential energy clusters, calculate the potential energy gradient with adjacent voxels, and select the direction with the fastest decrease in potential energy gradient as the preferred flow direction. Iteratively search along the preferred flow direction until a low-potential-energy cavity is reached, generating a search path; Generate the evacuation path with the least resistance based on all voxels along the search path.
9. An electronic device, used in the method according to any one of claims 1-8, characterized in that, include: The memory is configured to store instructions; as well as The processor is configured to retrieve the instructions from the memory and, when executing the instructions, to implement the real-time activity situation analysis method based on any one of claims 1 to 8.
10. A machine-readable storage medium, characterized in that, The machine-readable storage medium stores instructions for causing the machine to execute the real-time activity situation analysis method based on two-dimensional and three-dimensional integration as described in any one of claims 1 to 8.