Outside-hospital space doctor-seeing streamline quantitative analysis method based on depth image and point cloud data
Through depth images and point cloud data, the medical flowline in the outer space of the hospital was analyzed, and the ZED 2i camera and ST-GCN model were used to solve the problem of lack of quantitative analysis in the existing technology, and the scientific optimization of the medical flowline in the outer space of the hospital was achieved, and the medical efficiency was improved.
Patent Information
- Application Number
- CN202411689856.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-25
- Publication Date
- 2025-03-07
- Estimated Expiration
- 2044-11-25
AI Technical Summary
The existing technology lacks quantitative research on depth images and point cloud data, making it difficult to accurately analyze the medical flow lines in the outside hospital environment, resulting in the inability to effectively optimize the roads and distribution spaces within the hospital.
The quantitative analysis method of medical treatment in outer space based on depth images and point cloud data was adopted, and the three-dimensional spatial coordinates and human skeleton points were obtained through the ZED 2i depth camera, and the space-time characteristics were extracted in combination with the ST-GCN model, the activity density and congestion of the population were analyzed, and the flowline of medical treatment was optimized.
It realizes scientific quantitative analysis of medical treatment flow lines outside the hospital, provides more accurate data support, optimizes traffic organization within the hospital, and improves medical treatment efficiency and patient experience.
Smart Images

Figure CN119580972A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of current status assessment and optimization design of traffic flow lines in outdoor spaces of building complexes, and in particular to a quantitative analysis method of medical flow lines in outdoor spaces of hospitals based on depth images and point cloud data. Background Art
[0002] Large hospitals are large in scale and complex in degree. Their spatial layout, environmental factors, traffic flow lines, etc. will affect patients’ waiting time, medical efficiency, medical experience, etc. The depth image and point cloud data obtained by the ZED 2i depth camera can obtain the three-dimensional geometric information of objects, perform object detection, human body tracking, spatial mapping, and continuously scan the surrounding environment to create a 3D map.
[0003] At present, depth cameras are mainly used in machinery, computers, agriculture and other fields. Most of the research on the environment outside the hospital focuses on the traditional qualitative analysis level, but lacks the use of deep image point cloud data analysis methods to conduct quantitative research on the medical flow lines outside the hospital, obtain more accurate and scientific quantitative data, and more efficiently identify the crux of the problem, so as to improve and solve the above problems by optimizing the medical flow lines such as the roads and distribution spaces in the hospital. Summary of the invention
[0004] The purpose of the present invention is to provide a quantitative analysis method for medical streamlines outside hospital space based on depth images and point cloud data, aiming to solve the technical problems existing in the prior art identified in the background technology.
[0005] The present invention is implemented by a quantitative analysis method of medical streamlines outside a hospital based on depth images and point cloud data, the method comprising:
[0006] Step 1: Set up the ZED 2i camera operating environment and test it on the terminal to confirm the environment configuration status;
[0007] Step 2: Obtain real data on outpatients and inpatients, and collect and process the current status data of the hospital. Through quantitative data analysis and qualitative status research, obtain the patient flow in different time periods, the correlation between patient flow and time, and the high-frequency medical paths and gathering spaces of patients;
[0008] Step 3: Use the ZED 2i depth camera to detect the crowd in the high-frequency medical gathering space, obtain the three-dimensional spatial coordinates of each target object in each gathering space, and use the camera to perform plane detection on the space to obtain a grid plane map with coordinate values. Analyze and obtain the probability density distribution map of the crowd activities at different locations in the space to characterize the usage rate of different locations in the space, calculate the area occupied by pedestrians and combine different thresholds to characterize the congestion status of the gathering space;
[0009] Step 4: Use the ZED 2i depth camera to track the human body of people in the high-frequency medical gathering space, obtain 18 skeleton points of the human body, build a spatiotemporal graph and pass it to the ST-GCN model. Use the ST-GCN model to extract the spatiotemporal features of the skeleton sequence, determine the action category, and calculate the proportion of action types of people in the space;
[0010] Step 5: Use road static information to divide high-frequency medical treatment roads and select static nodes, where the static nodes include capacity nodes, road condition nodes, and roadside information nodes;
[0011] Step 6: Use the ZED 2i depth camera to detect people on the roads with high frequency of medical treatment, obtain the speed information of each object through each section of the path, and use the quantitative data combined with different thresholds to characterize the congestion conditions of each section of the road. Define the intersection of sections with different congestion conditions as dynamic nodes, and integrate the dynamic nodes with the static nodes to form different road units.
[0012] Step 7: Analyze the current status of the qualitative research and quantitative data of high-frequency medical gathering spaces and high-frequency medical roads, derive corresponding strategies for optimizing medical flow lines outside hospitals, and use intelligent algorithms to calculate medical navigation routes.
[0013] As a further solution of the present invention, step 2 specifically includes:
[0014] Step 2.1: Analyze the current situation of the hospital under study, analyze the traffic flow organization and medical environment, and conduct a qualitative analysis of the current problems;
[0015] Step 2.2: Divide the acquired data of tens of thousands of patients into different time units, and retrieve patient data of different months, weekdays and holidays, and different time periods of the day.
[0016] The correlation between the patient flow and different time units is calculated by using the corresponding patient flow and time values and their average values, and is used as the basis for setting the shooting period. The correlation calculation formula is:
[0017]
[0018] Among them, r is the correlation, f i and t i are the quantitative values of patient flow and time, and is the average of patient flow and time;
[0019] Step 2.3: Divide the patient data according to different treatment departments and inpatient wards, and replace the scattered departments and wards in the patient data with different numbers according to the hospital's department and inpatient building layout;
[0020] Step 2.4: Use the numbering frequency to determine the spaces and roads where patients frequently seek medical treatment in the hospital, and identify them as the points and routes for shooting and data analysis.
[0021] As a further solution of the present invention, step 3 specifically includes:
[0022] Step 3.1: Use the object detection function of the ZED 2i depth camera to select the corresponding date and several fixed time points as the starting point based on the correlation analysis results between the crowd and time, perform fixed-point recording of each gathering space for a fixed length of time, set people as detection objects, activate the location tracking module, and track the crowd;
[0023] Step 3.2, store and traverse the list of spatial coordinates of human objects, obtain continuous three-dimensional spatial coordinate points of all human objects, remove object data with a confidence level less than 10%, and retain the frame-by-frame continuous plane spatial coordinates (x, z) of the remaining objects;
[0024] Step 3.3: Read the plane coordinate data of the human object, use kernel density estimation to draw a density scatter plot, and use the ZED 2i depth camera to detect the plane of the gathering space, enable position tracking, obtain the plane data and convert it into a grid to obtain the plane information of the gathering space. The kernel density estimation formula is:
[0025]
[0026] in, is the estimated value of the unknown density function f at point x; n is the number of samples; x i is the observed value of the i-th sample; K is the kernel function, a non-decreasing symmetric distribution; h is the smoothing parameter, which is used to control the smoothness of the estimate;
[0027] Step 3.4, unify the coordinate systems of the gathering space plan and the scatter density map and superimpose them to obtain the crowd activity density distribution of the gathering space, and characterize the utilization rate of different locations of the gathering space according to the crowd activity density distribution map;
[0028] Step 3.5: Calculate the pedestrian occupied area of the gathering space based on the plane width of the space and the peak flow of people obtained in the target detection, make appropriate adjustments based on the structural characteristics of the special population in the hospital, calculate the congestion threshold based on the proportion of patients in wheelchairs and the proportion of patients who need to be pushed forward by beds, and use the k-means algorithm to find the cluster center through multiple iterations of the calculated multiple groups of pedestrian occupied area values to determine the congestion state of the gathering space. The pedestrian occupied area calculation formula is:
[0029]
[0030] Where S is the area occupied by pedestrians, in m 2 / person; M is the effective area of the gathering space, in m 2 ; Q is the flow of people during peak hours, in units of people;
[0031] The calculation formula for the congestion threshold is:
[0032] θ=1.04k1+10k2+(1-k1-k2)C;
[0033] Among them, θ is the threshold number, the unit is m 2 / person; k1 is the proportion of patients in wheelchairs in the hospital; k2 is the proportion of patients in the hospital who need beds to move forward; C is the threshold for evaluating the degree of crowding in general space, unit is m 2 / person; 1.04 and 10 are respectively the general floor space values of patients in wheelchairs and patients who need to be pushed forward by beds, in m 2 / people.
[0034] As a further solution of the present invention, step 4 specifically includes:
[0035] Step 4.1 Use the ZED 2i depth camera SDK depth module and position tracking module to select the corresponding date and several fixed time points as the starting point, perform fixed-point recording for a fixed length of time for each gathering space, extract the 3D position of the skeleton and key points of each object in the video, remove data with a confidence level of less than 10%, and save the 2D coordinate data of the human skeleton nodes in each frame;
[0036] Step 4.2, according to the human body joint connection information, the joint coordinates of each frame are constructed into a space-time graph G = (V, E), where V represents the joint point set, E represents the edge set, and in the space-time graph, the edges include spatial edges and temporal edges. The spatial edges represent the natural connections between joints, and the temporal edges represent the connections of the same joints in consecutive frames;
[0037] Step 4.3: Pass the human body joint coordinates as input to the ST-GCN model, use multiple graph convolution modules to automatically extract spatiotemporal features, and then send the extracted feature vectors to the SoftMax classifier to convert them into action probability distribution to determine the action category. The graph convolution formula of ST-GCN is:
[0038]
[0039] Among them, Z is the feature matrix after convolution; is the normalized adjacency matrix, I is the identity matrix; yes The degree matrix of X is the input feature matrix; Θ is the learnable convolution kernel parameter.
[0040] The formula for spatiotemporal convolution is:
[0041]
[0042] Among them, Z (t) is the output feature of time step t; N(i) is the set of adjacent nodes of node i; C i,k is the normalized coefficient between nodes i and k; X (t-1) is the input feature of time step t-1; Θ is the convolution kernel parameter.
[0043] As a further solution of the present invention, step 5 specifically includes:
[0044] Step 5.1, select the high-use roads in the hospital and draw a plan map, select static nodes from the perspective of road section traffic capacity, and mark them in the road plan map;
[0045] Step 5.2, identify three types of static nodes in the space outside the hospital: intersections, roadside entrance and exit nodes, and parking lot entrance and exit nodes, and mark them in the road plan;
[0046] Step 5.3: Identify four types of static nodes in the space outside the hospital: outpatient building, inpatient building, guide sign, and roadside parking lot, and mark them in the road plan.
[0047] As a further solution of the present invention, step 6 specifically includes:
[0048] Step 6.1: Determine the location of the fixed-point detection based on the maximum depth of field that the ZED 2i depth camera can measure and the length of the road to ensure that the entire road section can be effectively detected. Select the corresponding date and several fixed time points as the starting point, perform fixed-point recording of each gathering space for a fixed length of time, use people as the detection object, activate the location tracking module, and update the official open source algorithm to obtain real-time instantaneous speed data and store it;
[0049] Step 6.2: Calculate the congestion threshold using the proportion of frail patients and wheelchair patients. Use the k-means algorithm to find the cluster center through multiple iterations for the multiple sets of instantaneous speed values to determine the congestion status of the high-frequency medical treatment roads. The calculation formula for the congestion threshold is as follows:
[0050]
[0051] Where ω is the threshold number, in person / m / min; is the proportion of frail patients in the hospital; is the proportion of patients in wheelchairs in the hospital; K is the crowding threshold, in person / m / min; 48 and 33 are the general moving speeds of weak patients and patients in wheelchairs, in person / m / min respectively;
[0052] Step 6.3, when a static node is located in a congested road section, the static node is cancelled, and the static or dynamic node closest to the static node is used as the start and end point of the road unit to divide the road unit;
[0053] When a static node is located in a lightly congested road section, the static node is retained and used as the starting point or end point of the road unit according to the state.
[0054] As a further solution of the present invention, step 7 specifically includes:
[0055] Step 7.1: For the gathering spaces in the hospital, select the congested spaces and generate an expansion area strategy;
[0056] The utilization rate of different locations in the space can be obtained based on the crowd activity density distribution map of each gathering space. The traffic demand and temporary rest demand of people in different gathering spaces can be obtained based on the proportion of crowd activity types, and strategies for increasing relevant infrastructure in the space can be generated.
[0057] Step 7.2: For the high-frequency medical treatment roads within the hospital, generate a mitigation strategy for the congested sections according to the road units divided by dynamic and static nodes;
[0058] Step 7.3: Use the A* intelligent algorithm to obtain the optimal path-finding route, draw the planned traffic flow lines, buildings, and green spaces, define the starting and ending points according to the needs of different patients, and obtain the optimal path by calculating the f cost and g cost.
[0059] The beneficial effects of the present invention are:
[0060] (1) Based on the external space status of the research site and patient-related data, the congestion level, crowd speed information, crowd behavior activities, etc. of the established research site are measured with a functional orientation to provide a more scientific and reasonable basis for the optimization and transformation of the site's traffic organization.
[0061] (2) Relying on cutting-edge tools, deep images, point cloud data and intelligent algorithms, a method is proposed to quantitatively analyze the medical efficiency of the spatial streamline outside the hospital and provide the best medical navigation route for patients in the hospital, laying a quantitative data foundation for the precise optimization of the spatial traffic organization outside the hospital.
[0062] (3) Proposing a quantitative analysis and optimization method for the traffic organization outside the hospital for the research site will be beneficial to promoting the cross-development of planning and management of medium and large urban hospitals, and help related site research to effectively improve medical efficiency and achieve the goal of improving hospital service quality. BRIEF DESCRIPTION OF THE DRAWINGS
[0063] Figure 1 A flowchart of a method for quantitatively analyzing medical streamlines outside a hospital based on depth images and point cloud data provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0064] In order to make the purpose, technical solution and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not intended to limit the present invention.
[0065] It is understood that the terms "first", "second", etc. used in this application may be used herein to describe various elements, but unless otherwise specified, these elements are not limited by these terms. These terms are only used to distinguish a first element from another element. For example, without departing from the scope of this application, a first xx script may be referred to as a second xx script, and similarly, a second xx script may be referred to as a first xx script.
[0066] Figure 1 A flowchart of a method for quantitatively analyzing medical streamlines outside a hospital based on depth images and point cloud data provided by an embodiment of the present invention, such as Figure 1 As shown, the method includes:
[0067] Step 1: Set up the ZED 2i camera operating environment and test it on the terminal to confirm the environment configuration status;
[0068] Step 2: Obtain real data on outpatients and inpatients, and collect and process the current status data of the hospital. Through quantitative data analysis and qualitative status research, obtain the patient flow in different time periods, the correlation between patient flow and time, and the high-frequency medical paths and gathering spaces of patients;
[0069] Step 3: Use the ZED 2i depth camera to detect the crowd in the high-frequency medical gathering space, obtain the three-dimensional spatial coordinates of each target object in each gathering space, and use the camera to perform plane detection on the space to obtain a grid plane map with coordinate values. Analyze and obtain the probability density distribution map of the crowd activities at different locations in the space to characterize the usage rate of different locations in the space, calculate the area occupied by pedestrians and combine different thresholds to characterize the congestion status of the gathering space;
[0070] Step 4: Use the ZED 2i depth camera to track the human body of people in the high-frequency medical gathering space, obtain 18 skeleton points of the human body, build a spatiotemporal graph and pass it to the ST-GCN model. Use the ST-GCN model to extract the spatiotemporal features of the skeleton sequence, determine the action category, and calculate the proportion of action types of people in the space;
[0071] Step 5: Use road static information to divide high-frequency medical treatment roads and select static nodes, where the static nodes include capacity nodes, road condition nodes, and roadside information nodes;
[0072] Step 6: Use the ZED 2i depth camera to detect people on the roads with high frequency of medical treatment, obtain the speed information of each object through each section of the path, and use the quantitative data combined with different thresholds to characterize the congestion conditions of each section of the road. Define the intersection of sections with different congestion conditions as dynamic nodes, and integrate the dynamic nodes with the static nodes to form different road units.
[0073] Step 7: Analyze the current status of the qualitative research and quantitative data of high-frequency medical gathering spaces and high-frequency medical roads, derive corresponding strategies for optimizing medical flow lines outside hospitals, and use intelligent algorithms to calculate medical navigation routes.
[0074] Specifically, step 1 specifically includes:
[0075] Step 1.1: Install CUDA and cuDNN, add CUDA system variables, enter nvcc-V and nvcc--version in the run window of the computer to test whether the variables are added successfully.
[0076] Step 1.2: Install the SDK that corresponds to your computer performance and CUDA version, go to the tools subfolder in the ZED SDK, run ZED Explorer.exe and ZED DepthViewer.exe, and check whether the ZED camera can be enabled and work normally.
[0077] Step 1.3: Use Anaconda to install OpenCV. Enter the path where the file is downloaded and enter the installation command. Then install the adapted opencv-contrib-python and run the get_python_api.py file to complete the ZED_SDK environment.
[0078] Step 1.4: Test the installation environment. Create a new file test.py and run it in the terminal. If the terminal displays the camera serial number, it means that the ZED configuration is complete.
[0079] Specifically, step 2 specifically includes:
[0080] Step 2.1: Analyze the current situation of the hospital under study, analyze the traffic flow organization and medical environment, and conduct a qualitative analysis of the current problems;
[0081] Step 2.2: Divide the acquired data of tens of thousands of patients into different time units, and retrieve patient data of different months, weekdays and holidays, and different time periods of the day.
[0082] The correlation between the patient flow and different time units is calculated by using the corresponding patient flow and time values and their average values, and is used as the basis for setting the shooting period. The correlation calculation formula is:
[0083]
[0084] Among them, r is the correlation, f i and t i are the quantitative values of patient flow and time, and is the average of patient flow and time;
[0085] Step 2.3: Divide the patient data according to different treatment departments and inpatient wards, and replace the scattered departments and wards in the patient data with different numbers according to the hospital's department and inpatient building layout;
[0086] Step 2.4: Use the numbering frequency to determine the spaces and roads where patients frequently seek medical treatment in the hospital, and identify them as the points and routes for shooting and data analysis.
[0087] Specifically, step 3 specifically includes:
[0088] Step 3.1. Using the object detection function of the ZED 2i depth camera, based on the correlation analysis results between crowds and time, select six time points from Monday to Wednesday and holidays: 8:00, 10:00, 12:00, 14:00, 16:00 and 18:00 as the starting points, perform fixed-point recording for 30 minutes in each gathering space, set people as detection objects, activate the location tracking module, and track the crowd;
[0089] The main programming code for the camera to detect the target is as follows:
[0090]
[0091] Step 3.2, store and traverse the list of spatial coordinates of human objects, obtain continuous three-dimensional spatial coordinate points of all human objects, remove object data with a confidence level less than 10%, and retain the frame-by-frame continuous plane spatial coordinates (x, z) of the remaining objects;
[0092] The main programming code for obtaining relevant information of the detected object is as follows:
[0093] object_position=object.position
[0094] ifobject_tracking_state==sl.OBJECT_TRACKING_STATE.OK:
[0095] print("Object{0}is tracked\n".format(object_id))
[0096] Step 3.3: Use the Matplotlib drawing library to read the plane coordinate data of the human object, use the kernel density estimation to draw the density scatter plot, and use the ZED 2i depth camera to detect the aggregation space plane, enable position tracking, obtain the plane data and convert it into a grid to obtain the plane information of the aggregation space. The kernel density estimation formula is:
[0097]
[0098] in, is the estimated value of the unknown density function f at point x; n is the number of samples; x i is the observed value of the i-th sample; K is the kernel function, a non-decreasing symmetric distribution; h is the smoothing parameter, which is used to control the smoothness of the estimate;
[0099] The main programming code for the plane transformation grid is as follows:
[0100] find_plane_status=zed.find_plane_at_hit(coord,plane)
[0101] mesh = sl.Mesh()
[0102] mesh = plane.extract_mesh()
[0103] Step 3.4, unify the coordinate systems of the gathering space plan and the scatter density map and superimpose them to obtain the crowd activity density distribution of the gathering space, and characterize the utilization rate of different locations of the gathering space according to the crowd activity density distribution map;
[0104] Step 3.5: Calculate the pedestrian occupied area of the gathering space based on the plane width of the space and the peak flow of people obtained in the target detection. Based on the "Public Transportation Capacity and Service Quality Manual", make appropriate adjustments in combination with the structural characteristics of special populations in the hospital. Calculate the congestion threshold based on the proportion of patients in wheelchairs and the proportion of patients who need to be pushed forward by beds. Use the k-means algorithm to find the cluster center through multiple iterations of the calculated multiple groups of pedestrian occupied area values to determine the congestion state of the gathering space. The pedestrian occupied area calculation formula is:
[0105]
[0106] Where S is the area occupied by pedestrians, in m 2 / person; M is the effective area of the gathering space, in m 2 ; Q is the flow of people during peak hours, in units of people;
[0107] The calculation formula for the congestion threshold is:
[0108] θ=1.04k1+10k2+(1-k1-k2)C;
[0109] Among them, θ is the threshold number, the unit is m 2 / person; k1 is the proportion of patients in wheelchairs in the hospital; k2 is the proportion of patients in the hospital who need beds to move forward; C is the threshold for evaluating the degree of crowding in general space, unit is m 2 / person; 1.04 and 10 are respectively the general floor space values of patients in wheelchairs and patients who need to be pushed forward by beds, in m 2 / people.
[0110] Specifically, step 4 specifically includes:
[0111] Step 4.1 Use the depth module and position tracking module of the ZED 2i depth camera SDK to select six time points from Monday to Wednesday and holidays, namely 8:00, 10:00, 12:00, 14:00, 16:00 and 18:00 as the starting points, perform fixed-point recording for 30 minutes for each gathering space, extract the 3D positions of the skeleton and key points of each object in the video, remove data with a confidence level of less than 10%, and save the 2D coordinate data of the human skeleton nodes in each frame;
[0112] The main programming code to enable the camera's human tracking function is as follows:
[0113] zed_error=zed.enable_body_tracking(detection_parameters)
[0114] ifzed_error! =sl.ERROR_CODE.SUCCESS:
[0115] print("enable_body_tracking",zed_error,"\nExitprogram.")
[0116] Step 4.2, according to the human body joint connection information, the joint coordinates of each frame are constructed into a space-time graph G = (V, E), where V represents the joint point set, E represents the edge set, and in the space-time graph, the edges include spatial edges and temporal edges. The spatial edges represent the natural connections between joints, and the temporal edges represent the connections of the same joints in consecutive frames;
[0117] Step 4.3: Pass the human joint coordinates as input to the ST-GCN model, use multiple graph convolution modules to automatically extract spatiotemporal features, and then send the extracted feature vectors to the SoftMax classifier to convert them into action probability distributions to determine the action categories. For the medical gathering space, the action categories are mainly 'Standing' and 'Walking'. The graph convolution formula of ST-GCN is:
[0118]
[0119] Among them, Z is the feature matrix after convolution; is the normalized adjacency matrix, I is the identity matrix; yes The degree matrix of X is the input feature matrix; Θ is the learnable convolution kernel parameter.
[0120] The formula for spatiotemporal convolution is:
[0121]
[0122] Among them, Z (t) is the output feature of time step t; N(i) is the set of adjacent nodes of node i; C i,k is the normalized coefficient between nodes i and k; X (t-1) is the input feature of time step t-1; Θ is the convolution kernel parameter.
[0123] Specifically, step 5 specifically includes:
[0124] Step 5.1. Select the roads with high usage rate in the hospital and draw a plan map. Select static nodes from the perspective of road section capacity and mark them in the road plan map. On the roads in the hospital, the reason for the change in capacity is mostly the change in road width, and neck-down sections often cause congestion points. Therefore, static nodes are identified and marked in the road plan map.
[0125] Step 5.2, identify three types of static nodes in the space outside the hospital: intersections, roadside entrance and exit nodes, and parking lot entrance and exit nodes, and mark them in the road plan;
[0126] Step 5.3: Identify four types of static nodes in the space outside the hospital: outpatient building, inpatient building, guide sign, and roadside parking lot, and mark them in the road plan.
[0127] Specifically, step 6 specifically includes:
[0128] Step 6.1. Determine the location of the fixed-point detection based on the maximum depth of field that the ZED 2i depth camera can measure and the length of the road to ensure that the entire road section can be effectively detected. Select 8:00, 10:00, 12:00, 14:00, 16:00 and 18:00 from Monday to Wednesday and holidays as the starting points. Perform fixed-point recording for 30 minutes on each road section, use people as the detection object, activate the position tracking module, and update the official open source algorithm to obtain real-time instantaneous speed data and store it;
[0129] The main programming code for real-time speed measurement of the camera is as follows:
[0130]
[0131] Step 6.2: Based on the Public Transport Capacity and Service Quality Manual, appropriate adjustments are made in combination with the structural characteristics of special populations in hospitals. The proportion of frail patients and wheelchair patients is used to calculate the congestion threshold. The k-means algorithm is used to find the cluster center through multiple iterations for the multiple sets of instantaneous speed values obtained to determine the congestion status of high-frequency medical roads. The calculation formula for the congestion threshold is as follows:
[0132]
[0133] Where ω is the threshold number, in person / m / min; is the proportion of frail patients in the hospital; is the proportion of patients in wheelchairs in the hospital; K is the crowding threshold, in person / m / min; 48 and 33 are the general moving speeds of weak patients and patients in wheelchairs, in person / m / min respectively;
[0134] Step 6.3, when a static node is located in a congested road section, the static node is cancelled, and the static or dynamic node closest to the static node is used as the start and end point of the road unit to divide the road unit;
[0135] When a static node is located in a lightly congested section, the static node is retained and used as the starting point or end point of the road unit according to the state.
[0136] The road units are divided by integrating dynamic and static nodes, and problem analysis is carried out for different road states, nodes and current situations.
[0137] Specifically, step 7 specifically includes:
[0138] Step 7.1: For the gathering spaces in the hospital, select the congested spaces and generate an expansion area strategy;
[0139] According to the crowd activity density distribution map of each gathering space, the utilization rate of different locations in the space can be obtained, and landscape elements can be added to the high-density areas to divert the crowd and avoid the crowd from concentrating in certain areas of the space; the traffic demand and temporary rest demand of the crowd in different gathering spaces can be obtained from the proportion of crowd activity types, and the relevant infrastructure in the space can be increased based on this;
[0140] Step 7.2: For the high-frequency medical treatment roads within the hospital, generate a mitigation strategy for the congested sections according to the road units divided by dynamic and static nodes;
[0141] Congested sections of road will be widened, nodes on both sides will be locally transformed, routes will be adjusted and crowds will be diverted to increase the utilization rate of relatively unobstructed sections and reduce the pressure on congested sections. At the same time, public transportation such as shuttle buses can be added within the hospital, and reasonable schedules can be set up to alleviate road congestion.
[0142] Step 7.3: Use the A* intelligent algorithm to obtain the optimal path-finding route, draw the planned traffic flow lines, buildings, and green spaces, define the starting and ending points according to the needs of different patients, and obtain the optimal path by calculating the f cost and g cost.
[0143] The main formulas and programming codes are as follows:
[0144] f(n)=g(n)+h(n)
[0145] Among them, g(n) is the actual cost from the initial node to node n, and h(n) is the estimated cost from node n to the target node.
[0146]
[0147]
[0148] It should be understood that, although each step in the flow chart of each embodiment of the present invention is shown in sequence according to the indication of the arrow, these steps are not necessarily performed in sequence according to the order indicated by the arrow. Unless there is a clear explanation in this article, the execution of these steps does not have a strict order restriction, and these steps can be performed in other orders. Moreover, at least a portion of the steps in each embodiment may include a plurality of sub-steps or a plurality of stages, and these sub-steps or stages are not necessarily performed at the same time, but can be performed at different times, and the execution order of these sub-steps or stages is not necessarily performed in sequence, but can be performed in turn or alternately with at least a portion of other steps or sub-steps or stages of other steps.
[0149] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be implemented by instructing related hardware through a computer program. The program can be stored in a non-volatile computer-readable storage medium. When the program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in the present application may include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link
[0150] (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.
[0151] The technical features of the above-described embodiments may be arbitrarily combined. To make the description concise, not all possible combinations of the technical features in the above-described embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0152] The above-mentioned embodiments only express several implementation methods of the present invention, and the description thereof is relatively specific and detailed, but it cannot be understood as limiting the scope of the patent of the present invention. It should be pointed out that, for ordinary technicians in this field, several variations and improvements can be made without departing from the concept of the present invention, which all belong to the protection scope of the present invention. Therefore, the protection scope of the patent of the present invention shall be subject to the attached claims.
[0153] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the protection scope of the present invention.
Claims
1. A quantitative analysis method of medical streamlines outside hospital space based on depth images and point cloud data, characterized in that: The method comprises: Step 1: Set up the ZED 2i camera operating environment and test it on the terminal to confirm the environment configuration status; Step 2: Obtain real data on outpatients and inpatients, and collect and process the current status data of the hospital. Through quantitative data analysis and qualitative status research, obtain the patient flow in different time periods, the correlation between patient flow and time, and the high-frequency medical paths and gathering spaces of patients; Step 3: Use the ZED 2i depth camera to detect the crowd in the high-frequency medical gathering space, obtain the three-dimensional spatial coordinates of each target object in each gathering space, and use the camera to perform plane detection on the space to obtain a grid plane map with coordinate values. Analyze and obtain the probability density distribution map of the crowd activities at different locations in the space to characterize the usage rate of different locations in the space, calculate the area occupied by pedestrians and combine different thresholds to characterize the congestion status of the gathering space; Step 4: Use the ZED 2i depth camera to track the human body of people in the high-frequency medical gathering space, obtain 18 skeleton points of the human body, build a spatiotemporal graph and pass it to the ST-GCN model. Use the ST-GCN model to extract the spatiotemporal features of the skeleton sequence, determine the action category, and calculate the proportion of action types of people in the space; Step 5: Use road static information to divide high-frequency medical treatment roads and select static nodes, where the static nodes include capacity nodes, road condition nodes, and roadside information nodes; Step 6: Use the ZED 2i depth camera to detect people on the roads with high frequency of medical treatment, obtain the speed information of each object through each section of the path, and use the quantitative data combined with different thresholds to characterize the congestion conditions of each section of the road. Define the intersection of sections with different congestion conditions as dynamic nodes, and integrate the dynamic nodes with the static nodes to form different road units. Step 7: Analyze the current status of the qualitative research and quantitative data of high-frequency medical gathering spaces and high-frequency medical roads, derive the corresponding strategy for optimizing the medical flow lines outside the hospital, and calculate the medical navigation route.
2. The method according to claim 1, characterized in that Step 2 specifically includes: Step 2.1: Analyze the current situation of the hospital under study, analyze the traffic flow organization and medical environment, and conduct a qualitative analysis of the current problems; Step 2.2: Divide the acquired data of tens of thousands of patients into different time units, and retrieve patient data of different months, weekdays and holidays, and different time periods of the day. The correlation between the patient flow and different time units is calculated by using the corresponding patient flow and time values and their average values, and is used as the basis for setting the shooting period. The correlation calculation formula is: Among them, r is the correlation, f i and t i are the quantitative values of patient flow and time, respectively, and is the average value of patient flow and time; Step 2.3: Divide the patient data according to different treatment departments and inpatient wards, and replace the scattered departments and wards in the patient data with different numbers according to the hospital's department and inpatient building layout; Step 2.4: Use the numbering frequency to determine the spaces and roads where patients frequently seek medical treatment in the hospital, and identify them as the points and routes for shooting and data analysis.
3. The method according to claim 2, characterized in that Step 3 specifically includes: Step 3.1: Use the object detection function of the ZED 2i depth camera to select the corresponding date and several fixed time points as the starting point based on the correlation analysis results between the crowd and time, perform fixed-point recording of each gathering space for a fixed length of time, set people as detection objects, activate the location tracking module, and track the crowd; Step 3.2, store and traverse the list of spatial coordinates of human objects, obtain continuous three-dimensional spatial coordinate points of all human objects, remove object data with a confidence level less than 10%, and retain the frame-by-frame continuous plane spatial coordinates (x, z) of the remaining objects; Step 3.3, read the plane coordinate data of the human object, use kernel density estimation to draw a density scatter plot, and detect the gathering space plane through the ZED2i depth camera, enable position tracking, obtain the plane data and convert it into a grid to obtain the plane information of the gathering space. The kernel density estimation formula is: in, is the estimated value of the unknown density function f at point x; n is the number of samples; x i is the observed value of the i-th sample; K is the kernel function, a non-decreasing symmetric distribution; h is the smoothing parameter, which is used to control the smoothness of the estimate; Step 3.4, unify the coordinate systems of the gathering space plan and the scatter density map and superimpose them to obtain the crowd activity density distribution of the gathering space, and characterize the utilization rate of different locations of the gathering space according to the crowd activity density distribution map; Step 3.5: Calculate the pedestrian occupied area of the gathering space based on the plane width of the space and the peak flow of people obtained in the target detection, make appropriate adjustments based on the structural characteristics of the special population in the hospital, calculate the congestion threshold based on the proportion of patients in wheelchairs and the proportion of patients who need to be pushed forward by beds, find the cluster center through multiple iterations of the calculated multiple groups of pedestrian occupied area values, and determine the congestion state of the gathering space. The pedestrian occupied area calculation formula is: Where S is the area occupied by pedestrians, in m 2 / person; M is the effective area of the gathering space, in m 2 ; Q is the flow of people during peak hours, in units of people; The calculation formula for the congestion threshold is: θ=1.04k1+10k2+(1-k1-k2)C; Among them, θ is the threshold number, the unit is m 2 / person; k1 is the proportion of patients in wheelchairs in the hospital; k2 is the proportion of patients who need beds to move forward; C is the threshold for evaluating the degree of crowding in general space, unit is m 2 / person; 1.04 and 10 are respectively the general floor space values of patients in wheelchairs and patients who need to be pushed forward by beds, in m 2 / people.
4. The method according to claim 3, characterized in that Step 4 specifically includes: Step 4.1 Use the ZED 2i depth camera SDK depth module and position tracking module to select the corresponding date and several fixed time points as the starting point, perform fixed-point recording for a fixed length of time for each gathering space, extract the 3D position of the skeleton and key points of each object in the video, remove data with a confidence level of less than 10%, and save the 2D coordinate data of the human skeleton nodes in each frame; Step 4.2, according to the human body joint connection information, the joint coordinates of each frame are constructed into a space-time graph G = (V, E), where V represents the joint point set, E represents the edge set, and in the space-time graph, the edges include spatial edges and temporal edges. The spatial edges represent the natural connections between joints, and the temporal edges represent the connections of the same joints in consecutive frames; Step 4.3: Pass the human body joint coordinates as input to the ST-GCN model, use multiple graph convolution modules to automatically extract spatiotemporal features, and then send the extracted feature vectors to the SoftMax classifier to convert them into action probability distribution to determine the action category. The graph convolution formula of ST-GCN is: Among them, Z is the feature matrix after convolution; is the normalized adjacency matrix, I is the identity matrix; yes The degree matrix of X is the input feature matrix; Θ is the learnable convolution kernel parameter; The formula for spatiotemporal convolution is: Among them, Z (t) is the output feature of time step t; N(i) is the set of adjacent nodes of node i; C i,k is the normalized coefficient between nodes i and k; X (t-1) is the input feature of time step t-1; Θ is the convolution kernel parameter.
5. The method according to claim 4, characterized in that Step 5 specifically includes: Step 5.1, select the high-use roads in the hospital and draw a plan map, select static nodes from the perspective of road section traffic capacity, and mark them in the road plan map; Step 5.2, identify three types of static nodes in the space outside the hospital: intersections, roadside entrance and exit nodes, and parking lot entrance and exit nodes, and mark them in the road plan; Step 5.3: Identify four types of static nodes in the space outside the hospital: outpatient building, inpatient building, guide sign, and roadside parking lot, and mark them in the road plan.
6. The method according to claim 5, characterized in that Step 6 specifically includes: Step 6.1, determine the location of the fixed-point detection based on the maximum depth of field that the ZED 2i depth camera can measure and the length of the road, ensure that the entire road section can be effectively detected, select the corresponding date and several fixed time points as the starting point, perform fixed-point recording of each gathering space for a fixed length of time, use people as the detection object, and activate the position tracking module; Step 6.2: Calculate the congestion threshold using the proportion of frail patients and wheelchair patients. Find the cluster center through multiple iterations for the multiple sets of instantaneous speed values to determine the congestion status of the high-frequency medical treatment roads. The calculation formula for the congestion threshold is: Among them, ω is the threshold number, the unit is person / m / min; φ1 is the proportion of frail patients in the hospital; φ2 is the proportion of patients in wheelchairs in the hospital; K is the crowding threshold, the unit is person / m / min; 48 and 33 are the general moving speed values of frail patients and wheelchair patients, the unit is person / m / min respectively; Step 6.3, when a static node is located in a congested road section, the static node is cancelled, and the static and dynamic nodes closest to the static node are used as the start and end points of the road unit to divide the road unit; When a static node is located in a lightly congested road section, the static node is retained and used as the starting point or end point of the road unit according to the state.
7. The method according to claim 6, characterized in that Step 7 specifically includes: Step 7.1: For the gathering spaces in the hospital, select the congested spaces and generate an expansion area strategy; The utilization rate of different locations in the space can be obtained based on the crowd activity density distribution map of each gathering space. The traffic demand and temporary rest demand of people in different gathering spaces can be obtained based on the proportion of crowd activity types, and strategies for increasing relevant infrastructure in the space can be generated. Step 7.2: For the high-frequency medical treatment roads within the hospital, generate a mitigation strategy for the congested sections according to the road units divided by dynamic and static nodes; Step 7.3: Calculate the optimal path-finding route, draw the planned traffic flow lines, buildings, and green spaces, define the starting and ending points according to the needs of different patients, and obtain the optimal path by calculating the f cost and g cost.
Citation Information
Patent Citations
Method of processing tissue image and system for processing tissue image
CN117015796A
Outpatient service function layout optimization system and method based on patient real-time medical information big data
CN118070385A
Automated screening of medical data
US20210217166A1
Remote intelligent people flow statistics and control system based on internet of things
WO2024156221A1
Cited By
Intelligent outpatient service flow scheduling and resource optimization method and system
CN120875187A
An outpatient process intelligent scheduling and resource optimization method and system
CN120875187B