Image detection method for surgical wound care procedure compliance
Patent Information
- Application Number
- CN202611411207.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-09-11
- Publication Date
- 2026-10-13
AI Technical Summary
[0005]本发明的目的在于提供用于外科伤口护理操作合规性的图像检测方法,以解决对于一些形态高度不规则的伤口,基于中心点的方向判定偏离了临床规范,容易出现护理操作合规误判的问题
本发明通过对伤口闭合轮廓进行曲率分区并配置弧长采样步长,结合与曲率区域匹配的自适应邻域尺度拟合局部切线,经环绕方向初筛与空间区域校验双重判定,得到指向伤口外侧的法线向量,为形态高度不规则的创面构建了贴合临床消毒规范的局部方向基准,同时通过划分稳定接触、临界过渡与悬空三类接触状态对运动轨迹进行拆分,并通过正反向双夹角阈值判定、已消毒区域空间校验与累计弧长过滤,有效降低了回擦违规检测的假阳性率与误判率,在保障判定结果临床符合性与准确性的同时,兼顾运算效率,稳定实现外科伤口消毒操作合规性的自动化检测,为临床护理质控提供可靠的技术支撑。
Smart Images

Figure CN122906760A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of image processing technology, and in particular to an image detection method for ensuring compliance with surgical wound care procedures. Background Technology
[0002] In surgical wound care, compliance with aseptic disinfection procedures is crucial for reducing hospital-acquired infections and ensuring the quality of wound healing. Among these procedures, wiping from the inside out in a single direction and prohibiting wiping back into disinfected areas are mandatory guidelines for surgical disinfection.
[0003] In existing technologies for detecting compliance of surgical wound disinfection procedures using image detection methods, semantic segmentation is typically used to extract the wound area boundary. After capturing the movement trajectory of the disinfectant cotton or instrument tip, the change in the movement direction of the trajectory relative to the wound is used to determine whether there are violations such as back wiping. However, this method is based on the geometric center of the wound. For some wounds with highly irregular shapes, the direction determination based on the center point deviates from clinical norms, leading to misjudgments of compliance of nursing procedures.
[0004] Therefore, it is necessary to propose an image detection method for compliance of surgical wound care procedures to address the above problems. Summary of the Invention
[0005] The purpose of this invention is to provide an image detection method for ensuring compliance of surgical wound care procedures, in order to solve the problem that for some highly irregular wounds, the direction determination based on the center point deviates from clinical norms, which can easily lead to misjudgments of compliance of nursing procedures.
[0006] To achieve the above objectives, the present invention provides the following technical solution: An image detection method for ensuring compliance with surgical wound care procedures includes the following steps: S1: Acquire image sequences of the disinfection operation, process the image sequences, and obtain the closed contour of the target wound; S2: For the closed contour in the image, the closed contour is divided into high curvature region and low curvature region by calculating the curvature value of each pixel on the closed contour. The contour is sampled with different sampling step sizes to obtain the contour sampling points of each region. The local tangent is fitted to the contour sampling points to calculate the corresponding normal vector. The normal pointing to the outside of the wound is the positive direction of the disinfection operation. S3: Obtain the motion trajectory of the object being operated on based on the image sequence, and determine the contact state between the object being operated on and the skin frame by frame to break down the motion trajectory and obtain the contact segment trajectory; S4: Match the contact segment trajectory segment by segment to the nearest contour sampling point. Based on the angle between the trajectory movement direction and the normal vector of the contour sampling point, combined with the angle threshold and the disinfection area where the contact segment trajectory is located, perform back-wiping violation judgment to complete the image detection of wound care.
[0007] Preferably, the step of dividing the closed contour into high-curvature regions and low-curvature regions by calculating the curvature values of each pixel on the closed contour includes: The closed outline of the wound is converted into a sequence of outline pixels arranged along the boundary. For each contour pixel, a local arc is fitted by combining the symmetrical neighboring contour pixels before and after it, and the curvature value corresponding to that point is calculated. The weighted sum of the mean and standard deviation of the curvature values is used as the curvature determination threshold. Contour pixels with curvature values greater than or equal to the curvature determination threshold are marked as high curvature points, and contour pixels with curvature values less than the curvature determination threshold are marked as low curvature points. Based on the high curvature point and the low curvature point, the high curvature region and the low curvature region are obtained.
[0008] Preferably, the step of sampling high-curvature regions and low-curvature regions separately using different sampling step sizes to obtain contour sampling points includes: A first arc length sampling step size is configured for high curvature regions, and a second arc length sampling step size is configured for low curvature regions, wherein the first arc length sampling step size is smaller than the second arc length sampling step size; For high curvature regions, equidistant sampling is performed along the extension direction of the closed contour arc length with the first arc length sampling step to generate contour sampling points for the high curvature regions. For low curvature regions, equidistant sampling is performed along the extension direction of the closed contour arc length with a second arc length sampling step to generate contour sampling points for the low curvature regions.
[0009] Preferably, the step of fitting local tangents to the contour sampling points to calculate the corresponding normal vector includes: Determine the curvature region to which the contour sampling point belongs, configure the first neighborhood scale for the contour sampling point in the high curvature region, and configure the second neighborhood scale for the contour sampling point in the low curvature region; For the contour sampling points, within the corresponding neighborhood scale, select symmetrical neighborhood sampling points along the closed contour and fit them to obtain the local tangent. Calculate the candidate normal vectors perpendicular to the local tangent, and determine the direction based on the closed contour to obtain the normal vectors corresponding to the contour sampling points.
[0010] Preferably, the direction determination based on the closed contour includes: Based on the coordinates of the contour pixel sequence, the wrapping direction of the closed contour is calculated. Combined with the direction of the local tangent at the current contour sampling point, the candidate normal vectors are initially screened for inward and outward orientation to obtain the candidate outer normal vector. Along the direction of the candidate outer normal vector, take a test pixel at a preset offset distance, and determine whether the test pixel falls outside the wound area enclosed by the closed contour. If the test pixel is outside the wound area, the candidate outer normal vector is retained as the normal vector corresponding to the current contour sampling point. If the test pixel is within the wound area, and the candidate outer normal vector points to the inside of the wound, then another candidate normal vector with the opposite direction to the candidate outer normal vector is selected as the normal vector corresponding to the current contour sampling point.
[0011] Preferably, the contact state includes a stable contact state, a critical transition state, and a suspended state. The contact segment trajectory is obtained by merging the trajectory segments corresponding to the continuously distributed stable contact state frames and the critical transition state frames that are connected end to end.
[0012] Preferably, the step of determining the violation of back-wiping based on the angle between the trajectory movement direction and the normal vector of the contour sampling point, combined with the angle threshold and the disinfection area where the contact segment trajectory is located, includes: The contact segment trajectory is divided into several continuous trajectory sub-segments, and the motion direction vectors corresponding to the trajectory sub-segments are calculated. Take the midpoint of each trajectory segment to match the nearest contour sampling point, retrieve the normal vector corresponding to the contour sampling point, and calculate the angle between the motion direction vector and the normal vector; The included angle is compared with a preset reverse included angle threshold. If the included angle is greater than the reverse included angle threshold, the corresponding trajectory segment is determined to be a reverse motion segment. If the included angle is less than or equal to the preset positive included angle threshold, then the corresponding trajectory segment is determined to be a positive motion segment; If the spatial coverage of the reverse motion segment falls into the disinfected area, the disinfection operation corresponding to the trajectory segment is determined to be a non-compliant back-wiping operation. The arc length of each non-violation trajectory segment is accumulated. When the accumulated arc length exceeds the preset violation length threshold, it is marked as a valid non-violation event.
[0013] Preferably, the positive included angle threshold is the maximum included angle threshold for determining the trajectory segment moving in the positive direction of the disinfection operation, and the negative included angle threshold is the minimum included angle threshold for determining the trajectory segment moving in the negative direction of the disinfection operation.
[0014] The technical effects and advantages of the present invention in the above technical solution are as follows: This invention divides the wound closure contour into curvature zones and configures the arc length sampling step size. Combined with adaptive neighborhood scale fitting of local tangents that match the curvature region, and after initial screening in the circumferential direction and dual judgment of spatial region verification, a normal vector pointing to the outside of the wound is obtained. This constructs a local directional benchmark that conforms to clinical disinfection standards for wounds with highly irregular shapes. At the same time, by dividing the motion trajectory into three contact states—stable contact, critical transition, and suspension—and by using positive and negative double-angle threshold judgment, spatial verification of disinfected areas, and cumulative arc length filtering, the false positive rate and misjudgment rate of back-wiping violation detection are effectively reduced. While ensuring the clinical compliance and accuracy of the judgment results, it also takes into account the computational efficiency, stably realizes the automated detection of compliance of surgical wound disinfection operations, and provides reliable technical support for clinical nursing quality control. Attached Figure Description
[0015] Figure 1 This is a flowchart of the image detection method for ensuring compliance of surgical wound care procedures according to the present invention. Detailed Implementation
[0016] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0017] Currently, in surgical wound care, compliance with aseptic disinfection procedures is crucial for reducing hospital-acquired infections and ensuring wound healing quality. Unidirectional wiping from the inside out, and prohibiting back-wiping of disinfected areas, are mandatory standards for surgical disinfection. Existing computer vision-based automated detection solutions typically determine the direction of movement based on the wound's geometric center. However, for highly irregular wounds such as chronic ulcers and traumatic lacerations, this direction determination deviates from actual clinical practice and cannot distinguish between contact wiping and hovering adjustments. Furthermore, the false positive rate for back-wiping violations is high, failing to meet the quality control requirements of clinical nursing.
[0018] In view of this, such as Figure 1As shown, the purpose of this embodiment is to provide an image detection method for compliance of surgical wound care procedures. This embodiment takes a lower extremity venous ulcer disinfection scenario in a surgical outpatient dressing room as an example. Specifically, a binocular RGB-D depth camera is fixedly deployed at a height of 0.8m directly above the dressing table. The camera's color channel resolution is 1920×1080, and its depth channel resolution is 1280×720, with a frame rate of 25fps. This camera can simultaneously acquire color images and depth information of the operation scene. The acquired image data is transmitted in real-time to an edge computing terminal for processing via a USB 3.0 interface. The terminal is equipped with an embedded AI processor to perform the entire process of contour extraction, trajectory tracking, and violation judgment. Finally, it outputs the detection result of the wiping violation event and synchronizes it to the nursing quality control system. The implementation process of this invention is described in detail below with specific steps: In one embodiment of the present invention, the wound closure contour is the spatial basis for curvature partitioning calculation, normal direction construction, and operation trajectory matching. It is necessary to ensure that the boundary of the closure contour is consistent with the actual wound surface. Therefore, in step S1, an image sequence of the disinfection operation is acquired, and the image sequence is processed to obtain the closure contour of the target wound; specifically, this is achieved through the following method: Using a depth camera deployed above the dressing change station, color and depth images of the entire process of disinfection of lower extremity venous ulcers are simultaneously acquired. For the acquired color and depth frames, timestamp alignment is completed through a hardware synchronization clock, and pixel-level registration is completed based on camera intrinsic parameters to form a one-to-one disinfection operation image sequence. The image sequence is transmitted to the edge computing terminal in real time through a USB 3.0 interface. Upon receiving the image sequence, the edge computing terminal immediately extracts the wound closure contour. Specifically, for the pixel-level registered color frames, multi-class semantic segmentation is performed using a lightweight U-Net segmentation model optimized for clinical wound scenarios. Segmentation pixels with a confidence level below 0.7 are filtered out. This segmentation model is trained on tens of thousands of images of lower limb ulcer dressing scenes. The model simultaneously outputs an effective skin region mask and an initial wound pixel mask, automatically distinguishing between normal skin, ulcer wounds, and background areas. The effective skin region mask serves as a spatial constraint, and the initial wound pixel mask is used as the basis for the selection. The intersection with the effective skin region mask is used to remove mis-segmented pixels falling outside the skin region and eliminate false wound boundaries caused by clutter in the background region, resulting in a constrained wound mask. Based on the wound mask, a 3×3 circular structuring element is used to perform opening and closing operations. The opening operation is used to remove noise points and fine burrs at the edge of the mask, while the closing operation is used to fill in the tiny holes inside the wound caused by scabs or exudate reflection. After the operation, a complete wound region mask is obtained. The outer edge pixel set of the wound region mask is extracted, and the edge point sequence is smoothed to generate a single-pixel continuous target wound closed contour.
[0019] By using semantic segmentation and combining it with spatial constraints of the skin region, a standardized closed contour with boundaries that fit the real wound surface and is continuous without breaks is obtained, which effectively reduces the judgment error caused by contour deviation.
[0020] In one embodiment of the present invention, because the ulcer wound surface has an irregular shape and large differences in boundary curvature distribution, if a fixed step size sampling scheme is used, the sampling points in high curvature areas such as wound corners will be sparse, resulting in insufficient directional reference accuracy. Meanwhile, the sampling points in low curvature areas with gentle edges will be redundant, leading to low computational efficiency and failing to meet the accuracy requirements for back-wiping determination and the real-time requirements of embedded terminals. Therefore, in step S2, for the closed contour in the image, the curvature values of each pixel on the closed contour are calculated to divide the closed contour into high curvature regions and low curvature regions, and sampling is performed using different sampling step sizes to obtain the contour sampling points of each region. This is specifically implemented through the following method: The step of dividing the closed contour into high-curvature regions and low-curvature regions by calculating the curvature values of each pixel on the closed contour includes: S201: Convert the closed contour of the wound into a sequence of contour pixels arranged along the boundary; S202: For each contour pixel, fit a local arc by combining the symmetrical neighboring contour pixels before and after, and calculate the curvature value corresponding to that point. S203: Take the weighted sum of the mean and standard deviation of the curvature values as the curvature determination threshold. Mark the contour pixels with curvature values greater than or equal to the curvature determination threshold as high curvature points, and mark the contour pixels with curvature values less than the curvature determination threshold as low curvature points. S204: Based on the high curvature point and the low curvature point, the high curvature region and the low curvature region are obtained.
[0021] As shown in steps S201-S204 above, the closed contour of the wound obtained in step S1 is converted into a sequence of contour pixels arranged in topological order along the boundary. In this embodiment, the closed contour of the lower extremity venous ulcer contains approximately 1180 pixels. A neighbor index is established for each pixel to ensure that the neighboring pixels are symmetrically distributed along the contour arc length. For each contour pixel, five symmetrical neighboring contour pixels are selected before and after it, resulting in a local neighborhood set of 11 points. The least squares method is used to fit a local arc to the neighboring contour pixels, and the reciprocal of the fitted arc radius is used as the curvature value corresponding to that point. For example, if the radius of the fitted local arc obtained from a pixel at a smooth ulcer edge is 120px, then the corresponding curvature value k is: ; The local arc radius obtained by fitting a pixel at the corner of the ulcer depression is Then the corresponding curvature value k is: ; The mean curvature is calculated by statistically analyzing the curvature values of all contour pixels. Standard deviation of curvature The weighted sum of the mean and standard deviation is used as the curvature determination threshold, and the weighting coefficient is set to... The calculation process for the curvature determination threshold T is as follows: ; Based on the calculation results, curvature values greater than or equal to The outline pixels are marked as high curvature points, with curvature values less than 1. The outline pixels are marked as low curvature points. By aggregating the continuously distributed high curvature points, four independent high curvature regions are finally obtained, corresponding to the concave corners and protruding edges of the ulcer. The remaining continuously distributed low curvature points correspond to five low curvature regions.
[0022] After determining the high-curvature region and the low-curvature region, the steps of sampling the high-curvature region and the low-curvature region respectively using different sampling step sizes to obtain contour sampling points include: S205: Configure a first arc length sampling step for the high curvature region and a second arc length sampling step for the low curvature region, wherein the first arc length sampling step is smaller than the second arc length sampling step; S206: For high curvature regions, perform equidistant sampling along the extension direction of the closed contour arc length with the first arc length sampling step to generate contour sampling points for the high curvature regions. S207: For low curvature regions, perform equidistant sampling along the extension direction of the closed contour arc length with the second arc length sampling step to generate contour sampling points for the low curvature regions.
[0023] As shown in steps S205-S207 above, for the setting of the sampling step size, the first arc length sampling step size is configured for the high curvature region, with a value of 8px. It should be understood that the sampling interval is measured along the arc length of the contour, not the straight-line distance of pixels. The second arc length sampling step size is configured for the low curvature region, with a value of 25px. The first arc length sampling step size is smaller than the second arc length sampling step size, so as to realize the dense sampling in the high curvature region and the sparse sampling in the low curvature region. For high curvature regions, equidistant sampling is performed. Along the arc length extension direction of the closed contour, the starting endpoint of the region is used as the first sampling point. The arc length is accumulated segment by segment according to the first arc length sampling step. Taking a high curvature region corresponding to the concave corner of the ulcer in this embodiment as an example, the cumulative arc length along the contour of this segment is 192px. Starting from the starting point of the region, a sampling point is marked every 8px, while retaining the ending point of the region as a sampling point. The number of contour sampling points generated for this segment is calculated as follows: ; Combining the four high-curvature regions in the above embodiments, after sampling according to the same rules, they together constitute a subset of contour sampling points for the high-curvature regions. Similarly, for low-curvature regions, the starting endpoint of the region is taken as the first sampling point, and equidistant sampling is performed according to the second arc length sampling step. For example, taking a low-curvature region corresponding to the gentle edge of the ulcer's long axis in this embodiment as an example, the cumulative arc length along the contour of this segment is 475px. Equidistant sampling is performed at 25px steps while retaining the beginning and end endpoints. The number of sampling points generated for this segment is calculated as follows: ; Five low-curvature regions were sampled according to the same rules to form a subset of contour sampling points for the low-curvature regions.
[0024] All high-curvature region sampling point subsets and low-curvature region sampling point subsets are merged and arranged in the topological order of the closed contour, and the boundary endpoints of the high-curvature region and the low-curvature region are set as shared sampling points to avoid sampling gaps or duplicate sampling at the region junctions.
[0025] In step S2, local tangents are fitted to the contour sampling points to calculate the corresponding normal vectors, where the normal pointing outwards from the wound is the positive direction of the disinfection operation. Based on the contour sampling points, after fitting the local tangents, the normal vectors corresponding to the contour sampling points are obtained, specifically: S208: Determine the curvature region to which the contour sampling point belongs, configure the first neighborhood scale for the contour sampling point in the high curvature region, and configure the second neighborhood scale for the contour sampling point in the low curvature region. S209: For contour sampling points, within the corresponding neighborhood scale, select symmetrical neighborhood sampling points along the closed contour and fit to obtain the local tangent. S210: Calculate the candidate normal vectors perpendicular to the local tangent, combine them with the closed contour to determine the direction, and obtain the normal vectors corresponding to the contour sampling points.
[0026] As shown in steps S208-S210 above, determining the inside and outside of the normal solely through the geometric surrounding direction can easily lead to semantic misalignment in complex morphologies such as narrow ulcers and depressed wounds, making it impossible to guarantee that the normal always points to the outer normal skin. Therefore, the curvature region to which each contour sampling point belongs is determined. For contour sampling points in high curvature regions, a first neighborhood scale is configured, taking two neighboring sampling points before and after the current sampling point, for a total of five sampling points to participate in the fitting. For contour sampling points in low curvature regions, a second neighborhood scale is configured, taking five neighboring sampling points before and after the current sampling point, for a total of eleven sampling points to participate in the fitting. Setting the first neighborhood scale ensures that the small neighborhood in high curvature regions retains the edge shape, while setting the second neighborhood scale ensures that the large neighborhood in low curvature regions suppresses noise fluctuations. For each contour sampling point, along the topological order of the closed contour, within the corresponding neighborhood scale, select symmetrical neighboring sampling points. Use the least squares method to fit a straight line to the selected set of fitted points to obtain the local tangent line corresponding to the current sampling point. For example, taking a sampling point at a concave corner in a high curvature region as an example, the current point pixel coordinates are (620, 410). Select two neighboring sampling points before and after it, with coordinates of (612, 405), (616, 407), (624, 415), and (628, 410), respectively. 20) Perform least squares line fitting on 5 points to obtain the tangent slope k=1.22, then the corresponding tangent direction vector is (1,1.22), where 1 is the x-axis component of the tangent direction vector, representing the unit increment in the x-direction. The purpose of the direction vector is to indicate the direction. The length of the vector itself has no actual physical meaning. Furthermore, when calculating the angle between the trajectory and the normal, the vector will be normalized first (i.e., the magnitude is normalized to 1). Therefore, the x-component is set to 1 for the convenience of derivation and calculation, and will not affect the final angle determination result. Based on the tangent direction vector (1, 1.22), two candidate normal vectors that are mutually opposite and both perpendicular to the local tangent are calculated. Therefore, the direction vectors of these two candidate normal vectors are (-1.22, 1) and (1.22, -1), respectively. Specifically, each component of the candidate normal vector represents the trend of the corresponding pixel coordinate axis change when moving along this direction. Taking the image coordinate system (x-axis is positive to the right, y-axis is positive downward) as an example, the vector (-1.22, 1) indicates that when moving along this normal direction, since the negative sign indicates to the left, the x-coordinate decreases by 1.22 pixels and the y-coordinate increases downward by 1 pixel, corresponding to the direction of offset to the lower left from the tangent position. The vector (1.22, -1) indicates that when moving along this normal direction, the positive sign indicates to the right, the x-coordinate increases by 1.22 pixels and the y-coordinate decreases by 1 pixel, and the negative sign indicates upward, corresponding to the direction of offset to the upper right from the tangent position. These two directions correspond to the two sides of the local tangent, one side pointing to the inside of the wound surface and the other side pointing to the normal skin outside the wound.
[0027] Based on the candidate normal vectors generated by the above method, the normal direction is determined by combining them with the closed contour, thereby determining the normal vector corresponding to the contour sampling point. Specifically: S2101: Calculate the wrapping direction of the closed contour based on the coordinates of the contour pixel sequence, and combine the direction of the local tangent of the current contour sampling point to perform initial screening of the candidate normal vectors by their inner and outer orientations, thereby obtaining the candidate outer normal vectors. S2102: Along the direction of the candidate outer normal vector, take a test pixel at a preset offset distance, and determine whether the test pixel falls outside the wound area enclosed by the closed contour. S2103: If the test pixel is outside the wound area, the candidate outer normal vector is retained as the normal vector corresponding to the current contour sampling point. S2104: If the test pixel is within the wound area and the candidate outer normal vector points to the inside of the wound, then select another candidate normal vector with the opposite direction to the candidate outer normal vector as the normal vector corresponding to the current contour sampling point.
[0028] As shown in steps S2101-S2104 above, the directed area of the closed contour is calculated using the shoelace formula based on the coordinates of the contour pixel sequence. The direction of contour wrapping is determined based on the area sign. Specifically, the topologically ordered pixel sequence along the closed contour is obtained. Let the last point coincide with the first point. To ensure the contour is closed, the directional area of the contour is calculated using the shoelace formula. : ; The direction of wrapping is determined by the area sign. In the image coordinate system, x is positive to the right and y is positive downwards. like The closed contour is determined to be a counter-clockwise loop; like The closed contour is determined to be a clockwise loop.
[0029] In this embodiment, the closed contour is calculated to be a counterclockwise loop. Combined with the direction of the local tangent at the current sampling point, the normal direction pointing to the outside of the wound is derived. The candidate outer normal vector is initially screened from the two candidate normal vectors. According to the two candidate normal vectors obtained in the above embodiment, the candidate outer normal vector is (-1.22,1). Specifically, when the closed contour is a counterclockwise loop, the left side along the contour travel direction is the outside of the region, and the right side is the inside of the region. Combined with the direction of the tangent at this point sloping from the upper left to the lower right, it can be deduced that the direction offset to the lower left (-1.22,1) is the outer direction. Calculate the local contour width of the wound at the current contour sampling point, and take 20% of this width as the normal test offset distance. In this embodiment, the local contour width corresponding to this sampling point is 65px, so the corresponding test offset distance is calculated as follows: px; Based on the candidate outer normal vector (-1.22, 1), offsetting by 13px along the direction of the candidate outer normal vector, the coordinates of the test pixel are obtained. The integer value is approximately (604, 423), and it is determined whether the test pixel falls outside the mask of the wound area enclosed by the closed contour. If the test pixel is outside the wound area, the verification is successful, and the candidate outer normal vector is retained as the normal vector corresponding to the current sampling point. If the test pixel is inside the wound area, it indicates that the initial screening result is incorrect, and the candidate normal actually points to the inside of the wound. Then, another candidate normal vector with the opposite direction is selected as the final normal vector. In this embodiment, the test point (604, 423) falls in the normal skin area outside the wound area, so the normal vector of the sampling point is determined to be (-1.22, 1).
[0030] Furthermore, taking 20% of this width as the normal test offset distance, since the local contour width is the vertical distance between the contours on both sides of the wound in the direction of the normal of the current contour sampling point, that is, the thickness of the wound at this point, if the test offset distance is ≥ 50% of the local width, then the normal pointing to the inside of the wound will directly penetrate the entire wound and emerge from the opposite contour. In the end, the test points in both directions will fall outside the wound area. Therefore, the theoretical upper limit of the ratio is 50%. In engineering, in order to leave a safety margin, the value is usually less than or equal to 30%. Therefore, this embodiment selects 20% for calculation.
[0031] In one embodiment of the present invention, the prerequisite for a violation of the back-wiping rule is that the object being operated on comes into contact with the skin. Only reverse movement in contact will cause contamination of the disinfected area. However, actual clinical disinfection is a continuous and gradual process, involving a complete cycle of cotton ball falling, stable wiping, and lifting off the air. Existing methods do not distinguish between contact and air states, often misjudging normal air-loosening movements as back-wiping. Therefore, in step S3, the motion trajectory of the object being operated on is obtained based on the image sequence. By judging the contact state between the object and the skin frame by frame, the motion trajectory is broken down to obtain the contact segment trajectory. This is specifically implemented through the following method: In this embodiment, the object of operation is an iodine-soaked cotton ball held by sterile dressing forceps. Based on the lower tip of the cotton ball in contact with the skin, a lightweight target detection model is used to identify the area between the dressing forceps and the cotton ball in real time. The pixel coordinates of the tip of the cotton ball are located by corner detection. Combined with the depth map mapping of the binocular RGB-D depth camera, the three-dimensional spatial coordinates (x, y, z) of the point are obtained. The tip coordinates are recorded frame by frame at a frame rate of 25fps and concatenated in chronological order to form a complete motion trajectory of the disinfection operation. The motion trajectory is transmitted to the edge computing terminal for status determination through the USB 3.0 interface. The edge computing terminal performs contact state determination, which includes stable contact state, critical transition state, and suspended state. This determination is based on a combination of three features: depth difference, contact deformation rate, and motion stability. Specifically: For depth feature calculation, the depth value of the normal skin area surrounding the wound is used as the baseline depth, and the vertical depth difference between the tip of the cotton ball and the skin surface in the current frame is calculated. Set the first depth threshold Second depth threshold ; For contact deformation features, the reference pixel area when the cotton ball is suspended without compression is pre-calibrated. Real-time detection of the pixel area of the cotton ball in the current frame Calculate the deformation rate: ; When in stable contact, the cotton ball is compressed and deformed, increasing its area; when suspended, there is no compression, and the area remains at the baseline value. For motion stability characteristics, calculate the average motion velocity of the cotton ball tip over 5 consecutive frames; The rules for determining the state include: For a stable contact state, the depth difference is satisfied. (2mm), deformation rate It is in a stable contact range of 15%-35%, and the average movement speed is in the wiping speed range of 10-40mm / s; For the critical transition state, depth difference In Deformation rate (between 2mm and 8mm) It falls within the range of 5%-15%; For a suspended state, depth difference (8mm), and deformation rate There was no obvious compression deformation.
[0032] After the state determination is completed, the trajectory segments corresponding to the continuously distributed stable contact state frames and the critical transition state frames that are connected end to end are merged to obtain a complete contact segment trajectory. The trajectory segments corresponding to the suspended state frames are divided into suspended segment trajectories, and no subsequent back-wiping violation determination is performed.
[0033] In one embodiment of the present invention, existing methods use the geometric center of the wound as a unified directional reference. For lower extremity venous ulcers with highly irregular shapes, the direction of the local edge of the wound deviates significantly from the radial direction of the center, causing the direction determination to be out of touch with clinical reality. Furthermore, the method only judges violations based on the reversal of the movement direction, without distinguishing whether it has invaded a disinfected area, resulting in a high false positive rate. Therefore, in step S4, the contact segment trajectory is matched segment by segment to the nearest contour sampling point. Based on the angle between the trajectory movement direction and the normal vector of the contour sampling point, combined with the angle threshold and the disinfected area where the contact segment trajectory is located, a violation judgment of back-wiping is performed to complete the image detection of wound care. This is specifically implemented through the following method: The step of determining a violation of the back-wiping procedure based on the angle between the trajectory movement direction and the normal vector of the contour sampling point, combined with the angle threshold and the disinfection area where the contact segment trajectory is located, includes: S41: Divide the contact segment trajectory into several continuous trajectory sub-segments and calculate the motion direction vectors corresponding to the trajectory sub-segments; S42: Take the midpoint of each trajectory segment to match the nearest contour sampling point, retrieve the normal vector corresponding to the contour sampling point, and calculate the angle between the motion direction vector and the normal vector; S43: Compare the included angle with a preset reverse included angle threshold. If the included angle is greater than the reverse included angle threshold, then determine that the corresponding trajectory segment is a reverse motion segment. S44: If the included angle is less than or equal to the preset positive included angle threshold, then the corresponding trajectory segment is determined to be a positive motion segment; S45: If the spatial coverage of the reverse motion segment falls into the disinfected area, the disinfection operation corresponding to the trajectory segment is determined to be a non-compliant back-wiping operation. S46: Accumulate the arc length of the scraping violation trajectory segment. When the accumulated arc length exceeds the preset violation length threshold, it is marked as a valid scraping violation event.
[0034] As shown in steps S41-S46 above, each contact segment trajectory is divided into several continuous trajectory sub-segments according to a time step of 3 consecutive frames (corresponding to a time granularity of 0.12s at a 25fps acquisition frame rate). One frame overlap is maintained between adjacent sub-segments to avoid missed boundary detection. The motion direction vector corresponding to each sub-segment is obtained by calculating the coordinate difference between the beginning and end points of each trajectory sub-segment. If the starting pixel coordinates of a trajectory sub-segment within a contact segment are (610, 408) and the ending pixel coordinates are (602, 421), then the motion direction vector is: ; Based on the midpoint of each trajectory segment, traverse all contour sampling points to calculate the Euclidean distance between them, match the nearest contour sampling point, retrieve the pre-calculated unit normal vector of that sampling point, and calculate the angle between the motion direction vector and the normal vector using the vector dot product formula: ; in, The normal vector of the contour sampling point. Let be the angle between the two vectors, and its range is . If the midpoint of the sub-segment is approximately The coordinates of the nearest contour sampling point obtained by matching are: Its unit normal vector is (Pointing to the outside of the wound), normalize the motion direction vector to obtain Substitute into the formula to calculate the dot product: ; The included angle is calculated from this. ; The preset positive angle threshold is 45°, which is the maximum angle threshold for determining the trajectory segment to move in the positive direction of the disinfection operation; the preset negative angle threshold is 135°, which is the minimum angle threshold for determining the trajectory segment to move in the negative direction of the disinfection operation. The interval between the two thresholds is a transitional judgment interval, which is neither determined as positive nor negative. If the included angle The positive angle threshold determines the corresponding trajectory segment as a positive motion segment, conforming to the disinfection standard from the inside out; if the angle... >The reverse angle threshold determines the corresponding trajectory segment as a reverse motion segment, with the motion direction opposite to the disinfection direction. This is based on the calculated angle. The angle is 19°, which is less than or equal to 45°. Therefore, it is determined to be a positive motion segment, and the disinfection operation complies with the disinfection specifications. For the cotton ball covering the area corresponding to the forward motion segment, extend the trajectory point outward by 15px to the equivalent radius of the cotton ball and mark it as the disinfected area. For the segment determined to be in reverse motion, extract its spatial coverage area from the equivalent radius of the forward motion segment and determine the overlap ratio between this area and the disinfected area. If the overlap ratio exceeds 80%, that is, the spatial coverage area of the reverse motion segment falls into the disinfected area, then the disinfection operation corresponding to the trajectory segment is determined to be a back-wiping violation operation. If there is only partial overlap or it does not fall into the disinfected area, it is not determined to be a violation. Based on the non-violation trajectory segments of the back-wipe operation, the total path length of the reverse motion is calculated by accumulating the arc lengths. According to the camera calibration parameters, the physical pixel size is approximately 0.375 mm / px, and the preset violation length threshold is 15 mm. Therefore, the judgment value of the image pixel scale is 40 px. When the accumulated arc length exceeds this value, it is marked as a valid back-wipe violation event, and the time, location, and complete trajectory information of the violation are recorded simultaneously. If the accumulated length is less than this value, it is regarded as an attitude adjustment during the operation process and is not counted as a valid violation.
[0035] The foregoing has shown and described the basic principles, main features, and advantages of the present invention. Those skilled in the art should understand that the present invention is not limited to the above embodiments. The embodiments and descriptions in the specification are merely principles of the invention. Various changes and modifications can be made to the invention without departing from its spirit and scope, and all such changes and modifications fall within the scope of the claimed invention.
Claims
1. An image detection method for ensuring compliance of surgical wound care procedures, characterized in that, Includes the following steps: S1: Acquire image sequences of the disinfection operation, process the image sequences, and obtain the closed contour of the target wound; S2: For the closed contour in the image, the closed contour is divided into high curvature region and low curvature region by calculating the curvature value of each pixel on the closed contour. The contour is sampled with different sampling step sizes to obtain the contour sampling points of each region. The local tangent is fitted to the contour sampling points to calculate the corresponding normal vector. The normal pointing to the outside of the wound is the positive direction of the disinfection operation. S3: Obtain the motion trajectory of the object being operated on based on the image sequence, and determine the contact state between the object being operated on and the skin frame by frame to break down the motion trajectory and obtain the contact segment trajectory; S4: Match the contact segment trajectory segment by segment to the nearest contour sampling point. Based on the angle between the trajectory movement direction and the normal vector of the contour sampling point, combined with the angle threshold and the disinfection area where the contact segment trajectory is located, perform back-wiping violation judgment to complete the image detection of wound care.
2. The image detection method for compliance of surgical wound care procedures according to claim 1, characterized in that, The step of dividing the closed contour into high-curvature regions and low-curvature regions by calculating the curvature values of each pixel on the closed contour includes: The closed outline of the wound is converted into a sequence of outline pixels arranged along the boundary. For each contour pixel, a local arc is fitted by combining the symmetrical neighboring contour pixels before and after it, and the curvature value corresponding to that point is calculated. The weighted sum of the mean and standard deviation of the curvature values is used as the curvature determination threshold. Contour pixels with curvature values greater than or equal to the curvature determination threshold are marked as high curvature points, and contour pixels with curvature values less than the curvature determination threshold are marked as low curvature points. Based on the high curvature point and the low curvature point, the high curvature region and the low curvature region are obtained.
3. The image detection method for compliance of surgical wound care procedures according to claim 1, characterized in that, The steps for obtaining contour sampling points by sampling high-curvature and low-curvature regions using different sampling step sizes include: A first arc length sampling step size is configured for high curvature regions, and a second arc length sampling step size is configured for low curvature regions, wherein the first arc length sampling step size is smaller than the second arc length sampling step size; For high curvature regions, equidistant sampling is performed along the extension direction of the closed contour arc length with the first arc length sampling step to generate contour sampling points for the high curvature regions. For low curvature regions, equidistant sampling is performed along the extension direction of the closed contour arc length with a second arc length sampling step to generate contour sampling points for the low curvature regions.
4. The image detection method for compliance of surgical wound care procedures according to claim 1, characterized in that, The step of fitting local tangents to contour sampling points to calculate the corresponding normal vector includes: Determine the curvature region to which the contour sampling point belongs, configure the first neighborhood scale for the contour sampling point in the high curvature region, and configure the second neighborhood scale for the contour sampling point in the low curvature region; For the contour sampling points, within the corresponding neighborhood scale, select symmetrical neighborhood sampling points along the closed contour and fit them to obtain the local tangent. Calculate the candidate normal vectors perpendicular to the local tangent, and determine the direction based on the closed contour to obtain the normal vectors corresponding to the contour sampling points.
5. The image detection method for compliance of surgical wound care procedures according to claim 4, characterized in that, The method of determining direction by combining closed contours includes: Based on the coordinates of the contour pixel sequence, the wrapping direction of the closed contour is calculated. Combined with the direction of the local tangent at the current contour sampling point, the candidate normal vectors are initially screened for inward and outward orientation to obtain the candidate outer normal vector. Along the direction of the candidate outer normal vector, take a test pixel at a preset offset distance, and determine whether the test pixel falls outside the wound area enclosed by the closed contour. If the test pixel is outside the wound area, the candidate outer normal vector is retained as the normal vector corresponding to the current contour sampling point. If the test pixel is within the wound area, and the candidate outer normal vector points to the inside of the wound, then another candidate normal vector with the opposite direction to the candidate outer normal vector is selected as the normal vector corresponding to the current contour sampling point.
6. The image detection method for compliance of surgical wound care procedures according to claim 1, characterized in that: The contact states include stable contact states, critical transition states, and suspended states. The contact segment trajectory is obtained by merging the trajectory segments corresponding to the continuously distributed stable contact state frames and the critical transition state frames that are connected end to end.
7. The image detection method for compliance of surgical wound care procedures according to claim 1, characterized in that, The step of determining a violation of the back-wiping procedure based on the angle between the trajectory movement direction and the normal vector of the contour sampling point, combined with the angle threshold and the disinfection area where the contact segment trajectory is located, includes: The contact segment trajectory is divided into several continuous trajectory sub-segments, and the motion direction vectors corresponding to the trajectory sub-segments are calculated. Take the midpoint of each trajectory segment to match the nearest contour sampling point, retrieve the normal vector corresponding to the contour sampling point, and calculate the angle between the motion direction vector and the normal vector; The included angle is compared with a preset reverse included angle threshold. If the included angle is greater than the reverse included angle threshold, the corresponding trajectory segment is determined to be a reverse motion segment. If the included angle is less than or equal to the preset positive included angle threshold, then the corresponding trajectory segment is determined to be a positive motion segment; If the spatial coverage of the reverse motion segment falls into the disinfected area, the disinfection operation corresponding to the trajectory segment is determined to be a non-compliant back-wiping operation. The arc length of each non-violation trajectory segment is accumulated. When the accumulated arc length exceeds the preset violation length threshold, it is marked as a valid non-violation event.
8. The image detection method for compliance of surgical wound care procedures according to claim 7, characterized in that: The positive included angle threshold is the maximum included angle threshold for determining the trajectory segment moving in the positive direction of the disinfection operation, and the negative included angle threshold is the minimum included angle threshold for determining the trajectory segment moving in the negative direction of the disinfection operation.