Urine collection information management method and system based on cloud computing
By using cloud-based image processing and data analysis, the system automatically identifies and verifies changes in the liquid level in urine containers, solving the problem of data inaccuracy caused by manual inspections and achieving real-time and accurate urine volume monitoring.
Patent Information
- Application Number
- CN202511950142.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-23
- Publication Date
- 2026-04-07
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
Current urine information management relies on manual inspection and visual observation, which makes it difficult to capture the dynamic process of urine production in real time, cannot distinguish between liquid surface sloshing and actual urination, and results in insufficient data accuracy and timeliness. In addition, manual entry is cumbersome.
A cloud computing-based approach is used to acquire image sequences of urine containers through image acquisition devices. The Canny edge detection algorithm is used to identify the positions of scale lines and liquid surfaces, construct a time-series volume dataset, calculate the rate of volume change and set a dynamic rate anomaly threshold, automatically identify abnormal events and trace back the amount of urine output, and generate a verification pass storage instruction by combining the last frame data verification logic.
It enables automated tracking of urine volume changes, accurately identifies non-physiological fluid level fluctuations, eliminates human reading errors, and ensures real-time, accurate, and traceable monitoring.
Smart Images

Figure CN121810609A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of data processing technology, and in particular to a method and system for managing urine collection information based on cloud computing. Background Technology
[0002] The field of data processing technology mainly encompasses the electronic technologies for collecting, encoding, storing, retrieving, and logically operating information data generated in various business scenarios. Traditional methods of managing urine collection information involve medical staff regularly visiting wards, visually observing the physical markings on urine collection bags to read urine volume values, and then manually recording the patient's urination time and corresponding volume using pen and paper forms. During shift changes, the paper data is manually entered into the nurses' station's local desktop computer or archived in the medical record folder.
[0003] Current urine information management relies on medical staff regularly patrolling and visually observing the scale of the urine collection bag. The discontinuous manual monitoring mode cannot capture the dynamic process of urine production in real time. It is difficult to distinguish between physical sloshing of the liquid surface caused by the patient turning over or accidentally touching the container and the actual accumulation of urine. It is easy to mistake unstable instantaneous liquid level height as valid data. Manual visual reading is easily affected by the observation angle and subjective judgment, resulting in parallax. The manual copying and entry process is cumbersome and has time lag. It cannot effectively trace abnormal events during urination, resulting in the lack of accuracy and timeliness of the final archived patient intake and output data. Summary of the Invention
[0004] To achieve the above objectives, the present invention adopts the following technical solution: a cloud computing-based method for managing urine collection information, comprising the following steps: S1: Obtain the image sequence of the urine container, use the Canny edge detection algorithm to identify the pixel positions of the scale lines and the liquid surface in the image sequence of the urine container, and generate a time series capacity dataset based on the pixel distance between the liquid surface pixel position and the scale line pixel position and the capacity reference table. S2: Traverse the time series capacity dataset to calculate the capacity difference, divide the capacity difference by the time interval to construct the capacity change rate sequence, calculate the arithmetic mean and standard deviation of the capacity change rate sequence, and determine the dynamic rate anomaly threshold by the weighted sum of the arithmetic mean and standard deviation. S3: Mark the time point when the rate of change of volume exceeds the abnormal threshold of the dynamic rate as an abnormal event breakpoint, and extract the volume value of the position before the earliest occurrence of the abnormal event breakpoint in the time series volume dataset as the urine volume to be verified. S4: Extract the last frame capacity value of the time series capacity dataset as the last frame reference reading, calculate the absolute difference between the urine output to be verified and the last frame reference reading, and if the absolute difference is less than the capacity error tolerance, generate a verification pass storage instruction.
[0005] As a further aspect of the present invention, step S1 specifically comprises: S11: The video stream frames containing the urine collection container are continuously acquired by the image acquisition device at a preset sampling frequency, converted into a single-channel grayscale image, and the grayscale image is smoothed and denoised using a Gaussian filter to generate a urine container image sequence. S12: Calculate the gradient intensity and gradient direction of each pixel in the urine container image sequence using the Canny edge detection algorithm, refine the edge lines by non-maximum suppression, and identify the pixel positions of the scale lines and the liquid surface using the double threshold detection method. S13: Calculate the vertical Euclidean distance between the liquid surface pixel position and the scale line pixel position. Based on the pre-calibrated mapping relationship between pixel distance and actual liquid volume, convert the vertical Euclidean distance of each frame into a liquid volume value through linear interpolation, and combine them in time order to generate the time series volume dataset.
[0006] As a further aspect of the present invention, step S2 specifically comprises: S21: Traverse adjacent data points in the time series capacity dataset in chronological order, calculate the difference between the capacity value at the current moment and the capacity value at the previous moment, and generate an instantaneous increment set; S22: Obtain the timestamp difference between adjacent data points as the sampling time interval, and divide each difference in the instantaneous increment set by the sampling time interval to generate a capacity change rate sequence. S23: Statistically analyze the numerical distribution characteristics of all rate points in the capacity change rate sequence, calculate the arithmetic mean of all rate points, and calculate the standard deviation of all rate points; S24: Set the abnormal fluctuation sensitivity weighting coefficient, sum the arithmetic mean and the standard deviation after being weighted by the abnormal fluctuation sensitivity weighting coefficient, and determine the dynamic rate abnormal threshold.
[0007] As a further aspect of the present invention, step S3 specifically comprises: S31: Sequentially traverse each rate value in the capacity change rate sequence, compare each of them with the calculated dynamic rate anomaly threshold, and filter out all rate points whose values are greater than the dynamic rate anomaly threshold. S32: Obtain the time index marker corresponding to the selected rate point in the capacity change rate sequence, generate abnormal event breakpoints, and identify the breakpoint with the earliest timestamp as the starting trigger point. S33: Locate the time sequence position corresponding to the starting trigger point in the time series capacity dataset, backtrack one sampling period, and extract the capacity value corresponding to that moment as the urine volume to be verified.
[0008] As a further aspect of the present invention, step S4 specifically comprises: S41: Locate the last frame of data with the latest timestamp in the time series capacity dataset, and extract the capacity value corresponding to that frame as the reference reading for the last frame. S42: Calculate the numerical difference between the urine volume to be verified and the reference reading of the last frame, and take the absolute value of the numerical difference as the verification deviation value; S43: Obtain the preset capacity error tolerance value. When the verification deviation value is strictly less than the capacity error tolerance value, determine that the current urination data record is valid and generate a verification pass storage instruction.
[0009] As a further aspect of the present invention, the linear interpolation operation process described in S13 specifically includes: Obtain the vertical Euclidean distance calculated in the current frame, and find the two calibration distance nodes adjacent to the vertical Euclidean distance value and their corresponding calibration capacity values in the capacity lookup table; Based on the relative position ratio of the vertical Euclidean distance between the two calibrated distance nodes, the corresponding capacity value is calculated using the linear weight formula to generate a time series capacity dataset.
[0010] As a further aspect of the present invention, the specific calculation process of the dynamic rate anomaly threshold in S24 follows the following formula: ; in, This represents the abnormal threshold of the dynamic rate. This represents the total number of elements in the sequence of rates of capacity change. Representing the first in the sequence of capacity change rates The velocity value at each position, Represents the arithmetic mean, This represents the weighted coefficient for sensitivity to abnormal fluctuations.
[0011] As a further aspect of the present invention, the extraction process described in S33 specifically includes: After the starting trigger point is detected, a time retrieval window is established in the time series capacity dataset, and the end position of the window is the starting trigger point; Within the time retrieval window, the data point with the largest index value is retrieved, the capacity value of that reference point is read, and it is marked as the urine output to be verified.
[0012] As a further aspect of the present invention, the specific generation process of the verification through the storage instruction in S43 includes: Construct a standardized data storage package, write the verified urine output to the data field of the data storage package, and write the time of the detected abnormal event breakpoint to the timestamp field; The keyframe images corresponding to the time points are extracted from the urine container image sequence and compressed and encoded. The encoded image data is embedded into the attachment area of the data storage package, a verification pass storage instruction is generated, and the data is sent to the cloud database.
[0013] A cloud-based urine collection information management system, the system being used to implement the aforementioned cloud-based urine collection information management method, the system comprising: The image acquisition and dataset generation module is used to acquire image sequences of urine containers, perform Canny edge detection to identify pixel positions, and construct a time-series capacity dataset based on the mapping relationship between pixel distance and capacity reference table. The rate analysis and threshold calculation module is used to calculate the capacity change rate sequence, calculate the mean and standard deviation of the sequence, and dynamically generate dynamic rate anomaly thresholds based on the weighted statistical results. The abnormal event identification and extraction module is used to monitor the rate sequence and mark the breakpoints of abnormal events, and extract the amount of urine to be verified before the occurrence of urination from the dataset through backtracking logic; The data verification and storage execution module is used to compare the difference between the urine volume to be verified and the reference reading of the last frame, and generate a verification pass storage instruction when the difference meets the capacity error tolerance requirement.
[0014] Compared with the prior art, the advantages and positive effects of the present invention are as follows: In this invention, by acquiring continuous image sequences and using edge detection algorithms to extract the temporal features of the liquid surface, the process of urine volume change is automatically tracked. A dynamic statistical threshold is constructed based on the rate of volume change to accurately identify and eliminate non-physiological liquid surface fluctuation interference caused by container shaking or tipping. An anomaly backtracking mechanism is used to lock the true reading at the effective urination time. Combined with the double difference verification logic of the last frame of the sequence data, erroneous records with excessive deviation are automatically eliminated. While eliminating subjective errors of manual reading, a closed-loop control of data quality is established to ensure the real-time, accuracy and traceability of fluid intake and output monitoring for critically ill patients. Attached Figure Description
[0015] Figure 1This is the main flowchart of the cloud computing-based urine collection information management method of the present invention; Figure 2 Flowchart for generating time series capacity datasets for this invention; Figure 3 Flowchart for determining the dynamic rate anomaly threshold in this invention; Figure 4 This is a flowchart illustrating the process of extracting the urine volume to be verified in this invention. Figure 5 A flowchart for generating verification and storage instructions for this invention is provided. Detailed Implementation
[0016] To make the objectives, technical solutions, and advantages of this invention clearer, the software-based technical solution is described in detail below with reference to system architecture diagrams and embodiments. It should be understood that the specific embodiments described herein are only for explaining the technical solutions of this invention and do not constitute a limitation on the scope of protection.
[0017] In the description of this invention, the system architecture relationships or data processing flows indicated by terms such as "layer," "module," "interface," "data flow," "client," and "server" are all defined based on the architecture diagram or flowchart corresponding to the embodiments. This way of describing is only used to clearly illustrate the logical relationships between the elements in the technical solution, and not to limit the physical deployment form. The term "multiple" includes two or more technical units, including but not limited to multiple data nodes, processing threads, service instances, or functional components and other scalable elements. The specific number is determined according to the actual business scenario and needs to be specifically specified.
[0018] Please see Figure 1 and Figure 2 This invention provides a technical solution: a cloud computing-based method for managing urine collection information, comprising the following steps: S1: Obtain the image sequence of urine containers, use the Canny edge detection algorithm to identify the pixel positions of the scale lines and the liquid surface in the image sequence of urine containers, and generate a time series capacity dataset based on the pixel distance between the liquid surface pixel position and the scale line pixel position and the capacity comparison table. The specific steps of S1 are as follows: S11: The video stream frames containing the urine collection container are continuously acquired by the image acquisition device at a preset sampling frequency, converted into a single-channel grayscale image, and the grayscale image is smoothed and denoised using a Gaussian filter to generate a urine container image sequence. S12: The gradient intensity and gradient direction of each pixel in the urine container image sequence are calculated using the Canny edge detection algorithm. The edge lines are thinned by non-maximum suppression, and the double threshold detection method is applied to identify the pixel positions of the scale lines and the liquid surface pixels. S13: Calculate the vertical Euclidean distance between the liquid surface pixel position and the scale line pixel position. Based on the pre-calibrated mapping relationship between pixel distance and actual liquid volume, convert the vertical Euclidean distance of each frame into a liquid volume value through linear interpolation, and combine them in time order to generate a time series volume dataset. The linear interpolation process of S13 specifically includes: Obtain the vertical Euclidean distance calculated in the current frame, and find the two calibration distance nodes adjacent to the vertical Euclidean distance value and their corresponding calibration capacity values in the capacity lookup table; Based on the relative position ratio of the current vertical Euclidean distance between the two calibrated distance nodes, the corresponding capacity value is calculated using the linear weight formula to generate a time series capacity dataset.
[0019] This step is performed in a real-world intensive care unit (ICU) urine output monitoring scenario. The system first performs continuous frame capture using a high-resolution CMOS image sensor (Sony IMX415, 3840×2160 resolution) mounted on the urine bag holder; the image acquisition device operates at a preset sampling frequency. fps (frames per second) continuously reads video stream data; for each frame of the original RGB image, the processor calls the weighted average formula. Convert it to a single-channel grayscale matrix, where Representing pixel coordinates; subsequently, a 5×5 Gaussian convolution kernel is used. Perform convolution operation on the grayscale image and set the standard deviation. This is to remove high-frequency thermal noise and ambient light spot interference from the image.
[0020] Next, the system calls the Canny edge detection operator to process the denoised image sequence; first, the Sobel operator is used to calculate the horizontal gradient. and vertical gradient And according to the formula Calculate the gradient intensity of each pixel, and simultaneously utilize The gradient direction is determined; the system performs a non-maximum suppression process, which compares the gradient intensity of the current pixel with that of its neighboring pixels along the gradient direction. If the current pixel is not a maximum, its grayscale value is set to 0, thus thinning wide edges into lines of single-pixel width; subsequently, a dual-threshold detection method is applied, setting a high threshold. With low threshold Gradient value is higher than Pixels are marked as strong edges (i.e., tick marks and liquid surface contours), with gradient values between and Pixels connected to strong edges are retained, while the rest are discarded; through morphological connectivity operations, the system identifies the set of horizontal pixels representing tick marks in the image coordinate system. and the set of horizontal pixels representing the liquid surface .
[0021] Finally, the system performs capacity mapping calculations; the origin of the image coordinate system is set at the upper left corner, and vertically downwards is... Positive axis direction; the system identifies the average pixel row coordinates of the liquid surface. And two adjacent baseline tick marks in the tick mark set: the pixel row coordinates corresponding to the upper tick mark. (corresponding to rated capacity) (and the pixel row coordinates corresponding to the tick marks below) (corresponding to rated capacity) The system calculates the vertical Euclidean distance between the liquid surface and the scale lines, which in this scenario is represented as the pixel row difference; based on the principle of linear interpolation, the liquid volume value of the current frame is... The following logic is used to determine the relative position ratio of the liquid level between the two calibration nodes: First, calculate the ratio of the liquid level's position between the two calibration nodes. Therefore, we can conclude that .
[0022] Practical example illustration: Assume at time point In the frame image, the system identifies the liquid surface located in the pixel row. In the capacity comparison table, the two calibration distance nodes adjacent to this position are found as follows: the 500ml graduation line is located at... The 250ml mark is located at (Note: Image coordinates) (Since the axis increases downwards, the pixel values of the lower scale lines are larger); substitute the values to calculate the relative position ratio: ; Calculate the current capacity value: The system will calculate 437.5ml and then match it with the timestamp. Link and store in a time series volume dataset .
[0023] Please see Figure 1 and Figure 3 S2: Traverse the time series capacity dataset to calculate the capacity difference, divide the capacity difference by the time interval to construct the capacity change rate sequence, calculate the arithmetic mean and standard deviation of the capacity change rate sequence, and determine the dynamic rate anomaly threshold by the weighted sum of the arithmetic mean and standard deviation. The specific steps of S2 are as follows: S21: Traverse adjacent data points in the time series capacity dataset in chronological order, calculate the difference between the capacity value at the current time and the capacity value at the previous time, and generate an instantaneous increment set; S22: Obtain the timestamp difference between adjacent data points as the sampling time interval, divide each difference in the instantaneous increment set by the sampling time interval, and generate a capacity change rate sequence. S23: Analyze the numerical distribution characteristics of all rate points in the statistical capacity change rate sequence, calculate the arithmetic mean of all rate points, and calculate the standard deviation of all rate points; S24: Set the abnormal fluctuation sensitivity weighting coefficient, sum the arithmetic mean and the standard deviation after weighting by the abnormal fluctuation sensitivity weighting coefficient, and determine the dynamic rate abnormality threshold. The specific calculation process for the dynamic rate anomaly threshold of S24 follows the formula below: ; in, Represents the dynamic rate anomaly threshold. This represents the total number of elements in the sequence of rates of change of capacity. The first in the sequence representing the rate of change of capacity The velocity value at each position, Represents the arithmetic mean. This represents the weighted coefficient for sensitivity to abnormal fluctuations.
[0024] This step aims to establish dynamic anomaly monitoring criteria through statistical analysis; the system first accesses the data generated by S1. Data set, extracting adjacent data point pairs in chronological order. and For each pair of data, the system first calculates the instantaneous capacity increment. And calculate the sampling time interval. Then, divide the increment by the time interval to obtain the first... Rate of change of capacity at time Thus, a capacity change rate sequence is constructed. .
[0025] After acquiring the rate sequence, the system processes all data in the sequence. Statistical distribution characteristics are calculated for each rate point; first, the arithmetic mean of the sequence is calculated. This value reflects the average urine production rate or background noise level within the current observation period; next, the system calculates the standard deviation of the sequence. This parameter quantifies the dispersion of the rate data, i.e., the severity of the fluctuations; to determine the boundary between normal inflow and abnormal events (such as dumping, squeezing, or sudden large amounts of urination), the system introduces an abnormal fluctuation sensitivity weighting coefficient. This coefficient is set based on clinical monitoring needs, and typically ranges from [2.0, 4.0]. A higher value indicates a stronger ability to suppress false alarms, while a lower value indicates greater sensitivity in detecting minor abnormalities. The system adds the arithmetic mean to the weighted standard deviation to obtain the dynamic rate abnormality threshold. .
[0026] Dynamic rate anomaly threshold The specific calculation formula is as follows: ; in, Represents the dynamic rate anomaly threshold; This represents the total number of elements in the capacity change rate sequence; The first in the sequence representing the rate of change of capacity The rate value at each position; Represents the arithmetic mean; Represents the weighted coefficient for sensitivity to abnormal fluctuations; The summation symbol indicates that all rate values from the 1st to the Nth in the sequence are accumulated; This indicates the degree to which each rate point deviates from the average value; For squaring operations; The coefficients are calculated for the variance of the unbiased estimate; This is for square root operations.
[0027] Table 1. Urine volume monitoring data and rate calculation: ; Practical example illustration: As shown in Table 1, a simplified time series data segment collected by the system and the calculated rate sequence are presented; based on the data in Table 1, the total number of sequence elements is... (Right now to ); Calculate the arithmetic mean : ; Procedure for calculating standard deviation: , , Set the weighting coefficient for sensitivity to abnormal fluctuations. (Experimental verification shows that this value is stable in distinguishing between a static state and a tilting disturbance); Calculate the dynamic rate anomaly threshold. : The results indicate that, under the current data distribution, any rate of change exceeding 5.865 ml / s will be considered an anomalous mutation event by the system, providing a quantitative criterion for subsequent S3 steps.
[0028] Please see Figure 1 and Figure 4S3: Mark the time points when the rate of change of volume exceeds the dynamic rate abnormal threshold as abnormal event breakpoints, and extract the volume value of the position before the earliest abnormal event breakpoint in the time series volume dataset as the urine volume to be verified. The specific steps for S3 are as follows: S31: Iterate through each rate value in the capacity change rate sequence in sequence, compare each value with the calculated dynamic rate anomaly threshold, and filter out all rate points whose values are greater than the dynamic rate anomaly threshold. S32: Obtain the time index marker corresponding to the selected rate point in the capacity change rate sequence, generate abnormal event breakpoints, and identify the breakpoint with the earliest timestamp as the starting trigger point. S33: Locate the time sequence position corresponding to the starting trigger point in the time series volume dataset, backtrack one sampling period, and extract the volume value corresponding to that moment as the urine volume to be verified; The extraction process of S33 specifically includes: After the starting trigger point is detected, a time retrieval window is established in the time series capacity dataset, and the end point of this window is the starting trigger point. Retrieve the data point with the largest index value within the time retrieval window, read the capacity value of that baseline point, and mark it as the urine output to be verified.
[0029] This step involves precise location of the abnormal event and extraction of preliminary data; the system sequentially reads the capacity change rate sequence using a loop traversal algorithm. Each element in During the traversal, The dynamic rate anomaly threshold calculated in step S2 Perform logical comparison operations; the system filters out all conditions that are met. Data point index set If the set is empty, it is determined that there are no abnormal events; if the set is not empty, the system sorts the timestamps in the set and identifies the breakpoint with the smallest timestamp (i.e., the earliest occurrence time) as the starting trigger point. This process ensures that the system captures the initial moment of the abnormal event, rather than the intermediate state during the event's duration.
[0030] Locate the starting trigger point Then, the system on the original time-series capacity dataset The system performs a backtracking operation; corresponding time point Based on this, a time retrieval window is constructed that covers... The system retrieves the data point with the largest time index value within the window, i.e., the stable data point immediately preceding the time of the anomaly; reads the corresponding volume value of this baseline point, and marks it as "urine volume to be verified". The logic behind this operation is that... The data at a given moment has been subject to abnormal disturbances (such as sudden liquid surface sloshing or rapid injection), and its value is unreliable. The data at the moment before that moment represents the last known capacity of the system when it is in a relatively stable state.
[0031] Practical example illustration: Continuing from the example data in S2, the dynamic rate anomaly threshold is known. ml / s; System traversal rate sequence The comparison process is as follows: (normal), (normal), (normal), (normal), (Abnormal); The system detected the index. (corresponding time) The interval () is the breakpoint for the abnormal event; since there is only one abnormal point in the sequence, this point is the starting trigger point; in the time series capacity dataset, the index The corresponding rate is determined by and The data was calculated to determine the end time corresponding to the system's location of the starting trigger point. Backtrack one data position, that is, locate the position. Data points at time points; in Table 1, The volume at that time was 101.6 ml; therefore, the system extracted... ml is the urine output to be verified; this value represents the stable reading of the system before the rate surge (6.7 ml / s) occurs.
[0032] Please see Figure 1 and Figure 5 S4: Extract the last frame capacity value of the time series capacity dataset as the last frame reference reading, calculate the absolute difference between the urine output to be verified and the last frame reference reading, and if the absolute difference is less than the capacity error tolerance, generate a verification pass storage instruction. The specific steps for S4 are as follows: S41: Locate the last frame of data with the latest timestamp in the time series capacity dataset and extract the capacity value corresponding to that frame as the reference reading for the last frame. S42: Calculate the numerical difference between the urine output to be verified and the reference reading of the last frame, and take the absolute value of the numerical difference as the verification deviation value; S43: Obtain the preset capacity error tolerance value. When the verification deviation value is strictly less than the capacity error tolerance value, determine that the current urination data record is valid and generate a verification pass storage instruction. S43's verification process, through the specific generation of storage instructions, includes: Construct a standardized data storage package, write the verified urine output to the data field of the data storage package, and write the time of the detected abnormal event breakpoint to the timestamp field; Keyframe images at corresponding moments are extracted from the urine container image sequence and compressed and encoded. The encoded image data is embedded into the attachment area of the data storage package, a verification pass storage instruction is generated, and the data is sent to the cloud database.
[0033] This step serves as a data integrity verification process, aiming to confirm the validity of the data after the abnormal event has ended and to perform storage; the system first locates the time-series capacity dataset. The last frame of data in the dataset, i.e., the data point with the latest timestamp. Its capacity value This serves as a reference reading for the final frame; this reading represents the final state after a period of time (i.e., the sequence acquisition duration described in S1); subsequently, the system performs an absolute difference calculation to determine the amount of urine to be verified. Reference reading from the last frame Deviation between: .
[0034] The system calls the preset capacity error tolerance value. This parameter is based on the physical characteristics of the urine bag (such as flexibility) and the accuracy setting of the measurement system, and is usually set to [value missing]. Absolute volume values within the ml range; if the calibration deviation value Strictly less than The system determined that this record passed verification; this indicates that although rate abnormalities were detected in the intermediate process (such as fluctuations identified by S2 and S3), the volume difference between the start and end times was within the allowable error range, ruling out fluid level rise caused by continuous infusion. It was confirmed that the event may be an invalid fluctuation (such as shaking caused by the patient turning over) or a completed and stable micro-detection. The system decided to seal it as a valid monitoring record.
[0035] When the verification passes the storage instruction, the system constructs a standard data storage package in JSON format; Write the verified_volume field and the anomaly detection time to the timestamp field; at the same time, the system accesses the image sequence generated by S1, extracts the keyframes at the corresponding time, encodes them using the JPEG compression algorithm, generates a binary stream and embeds it into the attachment field of the data packet; finally, the instruction is sent to the cloud database server via the HTTPS protocol.
[0036] Practical example illustration: Continuing from the previous example, the amount of urine to be verified is known. ml ( (Time); Assuming the image sequence acquired by S1 continues to be acquired until... And in At that moment, the liquid surface ripples subsided, and the system identified the last frame's capacity value. ml; Calculate the absolute difference between the urine output to be verified and the reference reading from the last frame: The system's preset capacity error tolerance value ml (Based on experimental measurements, the maximum instantaneous deviation in liquid level reading caused by slight shaking of the urine bag can reach 15-18 ml, therefore 20 ml is set as the safety tolerance); Logical judgment is performed: The result is True; this indicates that although there was an abnormal fluctuation in the rate as high as 6.7 ml / s, the final volume change (13.2 ml) did not exceed the upper limit of the error tolerance, which meets the specific event recording standard set by the system (such as recording a short disturbance or a small amount of urination event, rather than a continuous large amount of water injection); the system then generates a storage instruction: {"device_id":"ICU_001","timestamp":"2023-10-27T14:30:08Z","verified_volume":101.6,"status":"pass","delta_check":13.2}, and attaches a compressed keyframe image, which is then uploaded to the cloud.
[0037] A cloud-based urine collection information management system, used to execute the aforementioned cloud-based urine collection information management method, the system comprising: The image acquisition and dataset generation module is used to acquire image sequences of urine containers, perform Canny edge detection to identify pixel positions, and construct a time-series capacity dataset based on the mapping relationship between pixel distance and capacity reference table. The rate analysis and threshold calculation module is used to calculate the capacity change rate sequence, calculate the mean and standard deviation of the sequence, and dynamically generate dynamic rate anomaly thresholds based on the weighted statistical results. The abnormal event identification and extraction module is used to monitor the rate sequence and mark the breakpoints of abnormal events, and extract the amount of urine to be verified before the occurrence of urination from the dataset through backtracking logic; The data verification and storage execution module is used to compare the difference between the urine volume to be verified and the reference reading of the last frame, and generate a verification pass storage instruction when the difference meets the capacity error tolerance requirement.
[0038] The above embodiments illustrate preferred embodiments of the present invention. Any equivalent adjustments to the technical solution based on software engineering methods are within the scope of protection, including but not limited to: implementing algorithm logic using different programming languages, refactoring functional modules into services, adjusting data interaction protocols, and optimizing resource scheduling strategies. Any implementation scheme derived from reasonable modifications to the data processing flow, service call chain, or system architecture layer without departing from the core technology of the present invention should be considered within the scope of protection of the present invention.
Claims
1. A cloud computing-based method for managing urine collection information, characterized in that, Includes the following steps: S1: Obtain the image sequence of the urine container, use the Canny edge detection algorithm to identify the pixel positions of the scale lines and the liquid surface in the image sequence of the urine container, and generate a time series capacity dataset based on the pixel distance between the liquid surface pixel position and the scale line pixel position and the capacity reference table. S2: Traverse the time series capacity dataset to calculate the capacity difference, divide the capacity difference by the time interval to construct the capacity change rate sequence, calculate the arithmetic mean and standard deviation of the capacity change rate sequence, and determine the dynamic rate anomaly threshold by the weighted sum of the arithmetic mean and standard deviation. S3: Mark the time point when the rate of change of volume exceeds the abnormal threshold of the dynamic rate as an abnormal event breakpoint, and extract the volume value of the position before the earliest occurrence of the abnormal event breakpoint in the time series volume dataset as the urine volume to be verified. S4: Extract the last frame capacity value of the time series capacity dataset as the last frame reference reading, calculate the absolute difference between the urine output to be verified and the last frame reference reading, and if the absolute difference is less than the capacity error tolerance, generate a verification pass storage instruction.
2. The urine collection information management method based on cloud computing according to claim 1, characterized in that, The specific steps of S1 are as follows: S11: The video stream frames containing the urine collection container are continuously acquired by the image acquisition device at a preset sampling frequency, converted into a single-channel grayscale image, and the grayscale image is smoothed and denoised using a Gaussian filter to generate a urine container image sequence. S12: Calculate the gradient intensity and gradient direction of each pixel in the urine container image sequence using the Canny edge detection algorithm, refine the edge lines by non-maximum suppression, and identify the pixel positions of the scale lines and the liquid surface using the double threshold detection method. S13: Calculate the vertical Euclidean distance between the liquid surface pixel position and the scale line pixel position. Based on the pre-calibrated mapping relationship between pixel distance and actual liquid volume, convert the vertical Euclidean distance of each frame into a liquid volume value through linear interpolation, and combine them in time order to generate the time series volume dataset.
3. The urine collection information management method based on cloud computing according to claim 2, characterized in that, The specific steps of S2 are as follows: S21: Traverse adjacent data points in the time series capacity dataset in chronological order, calculate the difference between the capacity value at the current moment and the capacity value at the previous moment, and generate an instantaneous increment set; S22: Obtain the timestamp difference between adjacent data points as the sampling time interval, and divide each difference in the instantaneous increment set by the sampling time interval to generate a capacity change rate sequence. S23: Statistically analyze the numerical distribution characteristics of all rate points in the capacity change rate sequence, calculate the arithmetic mean of all rate points, and calculate the standard deviation of all rate points; S24: Set the abnormal fluctuation sensitivity weighting coefficient, sum the arithmetic mean and the standard deviation after being weighted by the abnormal fluctuation sensitivity weighting coefficient, and determine the dynamic rate abnormal threshold.
4. The urine collection information management method based on cloud computing according to claim 3, characterized in that, The specific steps of S3 are as follows: S31: Sequentially traverse each rate value in the capacity change rate sequence, compare each of them with the calculated dynamic rate anomaly threshold, and filter out all rate points whose values are greater than the dynamic rate anomaly threshold. S32: Obtain the time index marker corresponding to the selected rate point in the capacity change rate sequence, generate abnormal event breakpoints, and identify the breakpoint with the earliest timestamp as the starting trigger point. S33: Locate the time sequence position corresponding to the starting trigger point in the time series capacity dataset, backtrack one sampling period, and extract the capacity value corresponding to that moment as the urine volume to be verified.
5. The urine collection information management method based on cloud computing according to claim 4, characterized in that, The specific steps of S4 are as follows: S41: Locate the last frame of data with the latest timestamp in the time series capacity dataset, and extract the capacity value corresponding to that frame as the reference reading for the last frame. S42: Calculate the numerical difference between the urine volume to be verified and the reference reading of the last frame, and take the absolute value of the numerical difference as the verification deviation value; S43: Obtain the preset capacity error tolerance value. When the verification deviation value is strictly less than the capacity error tolerance value, determine that the current urination data record is valid and generate a verification pass storage instruction.
6. The urine collection information management method based on cloud computing according to claim 2, characterized in that, The linear interpolation operation process described in S13 specifically includes: Obtain the vertical Euclidean distance calculated in the current frame, and find two calibration distance nodes adjacent to the vertical Euclidean distance value and their corresponding calibration capacity values in the capacity lookup table; Based on the relative position ratio of the vertical Euclidean distance between the two calibrated distance nodes, the corresponding capacity value is calculated using the linear weight formula to generate a time series capacity dataset.
7. The urine collection information management method based on cloud computing according to claim 3, characterized in that, The specific calculation process for the dynamic rate anomaly threshold mentioned in S24 follows the following formula: ; in, This represents the abnormal threshold of the dynamic rate. This represents the total number of elements in the sequence of rates of capacity change. Representing the first in the sequence of capacity change rates The velocity value at each position, Represents the arithmetic mean, This represents the weighted coefficient for sensitivity to abnormal fluctuations.
8. The urine collection information management method based on cloud computing according to claim 4, characterized in that, The extraction process described in S33 specifically includes: After the starting trigger point is detected, a time retrieval window is established in the time series capacity dataset, and the end position of the window is the starting trigger point; Within the time retrieval window, the data point with the largest index value is retrieved, the capacity value of that reference point is read, and it is marked as the urine output to be verified.
9. The urine collection information management method based on cloud computing according to claim 5, characterized in that, The specific process of generating the verification through the storage instruction described in S43 includes: Construct a standardized data storage package, write the verified urine output to the data field of the data storage package, and write the time of the detected abnormal event breakpoint to the timestamp field; The keyframe images corresponding to the time points are extracted from the urine container image sequence and compressed and encoded. The encoded image data is embedded into the attachment area of the data storage package, a verification pass storage instruction is generated, and the data is sent to the cloud database.
10. A cloud-based urine collection information management system, characterized in that, The system is used to implement the cloud computing-based urine collection information management method according to any one of claims 1-9, the system comprising: The image acquisition and dataset generation module is used to acquire image sequences of urine containers, perform Canny edge detection to identify pixel positions, and construct a time-series capacity dataset based on the mapping relationship between pixel distance and capacity reference table. The rate analysis and threshold calculation module is used to calculate the capacity change rate sequence, calculate the mean and standard deviation of the sequence, and dynamically generate dynamic rate anomaly thresholds based on the weighted statistical results. The abnormal event identification and extraction module is used to monitor the rate sequence and mark the breakpoints of abnormal events, and extract the amount of urine to be verified before the occurrence of urination from the dataset through backtracking logic; The data verification and storage execution module is used to compare the difference between the urine volume to be verified and the reference reading of the last frame, and generate a verification pass storage instruction when the difference meets the capacity error tolerance requirement.