Livestock physiological behavior monitoring method and system
By collecting and analyzing the gait data of livestock, identifying abnormal thresholds and painful behavior characteristics, and evaluating limb function health index, the problems of lame detection lame detection in the prior art, and vague evaluation of subjective and vague etiology judgments are solved, achieving high-precision lame evaluation and early warning.
Patent Information
- Application Number
- CN202510590153.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-08
- Publication Date
- 2025-06-06
- Estimated Expiration
- 2045-05-08
AI Technical Summary
In the prior art, lagging detection lag, subjective assessment and vagueness of etiology judgment need to be solved urgently.
The three-zone pressure matrix is collected through the pressure sensing pad, dynamic path recognition and camera adjustment are performed, and the mechanical gait analysis data of livestock are obtained. Combining basic information and gait data, individualized abnormal thresholds are calculated, gait deviation index is identified, limb weight bearing characteristics and pain behavior characteristics are analyzed, and limb function health index is evaluated.
High-precision gait analysis is realized, the early recognition ability of abnormal gait is improved, and an objective and quantitative lame evaluation system is established, which solves the problems of difficulty in early detection of lame, subjective severity assessment and inaccurate etiology analysis in traditional technology.
Smart Images

Figure CN120093288A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of animal husbandry monitoring technology, and in particular to a livestock physiological behavior monitoring method and system. Background Art
[0002] Existing livestock lameness early identification technology has significant limitations, mainly manifested in insufficient detection sensitivity, which cannot capture subtle gait changes in the subclinical stage, resulting in missing the best time for intervention and causing mild lameness to develop into a serious problem. Secondly, the assessment of lameness severity is highly dependent on the experience and subjective judgment of the assessor. The difference in scores between different assessors can reach more than 30%. The lack of precise quantitative standards and objective evaluation systems makes it difficult to achieve standardized management and accurate comparison. In addition, traditional lameness etiology analysis methods have difficulty distinguishing different mechanisms of similar manifestations. For example, lameness caused by laminitis and arthritis are similar in appearance but have completely different causes and treatment plans. The lack of multi-dimensional parameter analysis leads to low judgment accuracy and insufficient targeted intervention.
[0003] In summary, the existing technologies generally have problems such as delayed lameness detection, subjective assessment and ambiguity in etiology judgment, which need to be urgently addressed. Summary of the invention
[0004] Based on this, it is necessary to provide a livestock physiological behavior monitoring method and system to solve at least one of the above technical problems.
[0005] To achieve the above purpose, a method for monitoring livestock physiological behavior comprises the following steps: Step S1: collecting a three-area pressure matrix through a pressure sensing pad; performing dynamic path recognition and camera adjustment according to the three-area pressure matrix to obtain dynamic path tracking data; performing livestock mechanical gait analysis according to the dynamic path tracking data to obtain a gait mechanical characteristic map; Step S2: acquiring basic livestock information; performing individual gait time-series segmentation according to the gait mechanics characteristic map to obtain segmented aligned gait data; performing adaptive gait threshold calculation according to the basic livestock information and the segmented aligned gait data to obtain an individualized abnormal threshold set; performing abnormal gait pattern recognition according to the individualized abnormal threshold set to obtain a gait deviation index matrix; Step S3: Perform limb weight-bearing ratio difference analysis based on the gait deviation index matrix and the gait mechanics characteristic map to obtain limb weight-bearing characteristics; identify weight-bearing transfer pattern characteristics based on the limb weight-bearing characteristics; identify pain behavior characteristics based on the weight-bearing transfer pattern characteristics to obtain pain characteristic associated data; perform limb health assessment based on the pain characteristic associated data to obtain a limb function health index; Step S4: Conducting time-series monitoring of behavior patterns based on the limb function health index to obtain a livestock health trend graph.
[0006] The present invention provides basic data that comprehensively and accurately reflects the physical characteristics of livestock gait by synchronously collecting the distribution of ground reaction forces and limb joint motion trajectories when livestock walk, and extracting and integrating preliminary mechanical and kinematic parameters. This fine capture and synchronous processing of multimodal data lays a solid foundation for the subsequent in-depth analysis of how livestock bear weight, how to coordinate movement, and the dynamic changes of gait, and significantly improves the accuracy and information content of gait analysis. By constructing and utilizing the historical gait records of individual livestock, a personalized gait baseline and adaptive abnormal threshold are established. This analysis method based on individual historical data can fully take into account the physiological differences and historical habits between individuals, so that the identification of abnormal gait no longer depends on the average level of the group, but is accurately targeted at the normal state of the livestock itself. The gait deviation index matrix calculated in this way can quantify the degree of deviation of the current gait of the livestock from its normal gait, significantly improving the specificity and early warning ability of abnormal detection. By deeply analyzing the key mechanical and kinematic characteristics of the livestock's limbs, such as weight distribution, symmetry, support time, and joint mobility, combined with the identified abnormal patterns, pain-related behavioral manifestations (such as load reduction and avoidance transfer) can be accurately identified. This analysis method can infer the pain status (location, intensity, acuteness and chronicity) of livestock from objective gait data and quantify the degree of limb dysfunction. The resulting limb function health index comprehensively reflects the limb's load-bearing capacity, movement coordination and potential pain impact, providing a direct and valuable basis for assessing livestock limb health and positioning issues. By constructing and monitoring the time series of livestock limb function health index and correlating it with environmental monitoring data and pasture management records, continuous tracking and comprehensive evaluation of livestock health status are achieved. This method can not only identify current anomalies in health index, but also calculate health fluctuation baselines based on historical data, predict future health trends and potential disease risks. By revealing the correlation between health changes and external factors, it provides early warning information and decision support for pasture managers, which helps to adjust feeding and management measures in a timely manner, prevent the occurrence or spread of diseases, and improve the overall health level of the herd. Therefore, the present invention provides a method for monitoring livestock physiological behavior, which realizes high-precision collection of gait mechanical characteristics by combining regional pressure sensing technology and biological tracking camera technology; introduces individualized baseline comparison and adaptive threshold algorithm, greatly improves the early recognition ability of abnormal gait; and establishes an objective and quantitative lameness assessment system through comprehensive analysis of joint angles, ground reaction forces and load-bearing patterns, effectively solving the core problems of difficulty in early detection of lameness, subjective severity assessment and inaccurate cause analysis in traditional technologies, and provides a scientific basis for livestock health management.
[0007] Preferably, the present invention further provides a livestock physiological behavior monitoring system for executing the livestock physiological behavior monitoring method as described above, the livestock physiological behavior monitoring system comprising: The gait data acquisition module is used to collect the three-area pressure matrix through the pressure sensing pad; perform dynamic path recognition and camera adjustment according to the three-area pressure matrix to obtain dynamic path tracking data; perform livestock mechanical gait analysis according to the dynamic path tracking data to obtain a gait mechanical characteristic map; The abnormal feature recognition module is used to obtain basic information of livestock; segment individual gait time series according to the gait mechanical feature map to obtain segmented aligned gait data; perform adaptive gait threshold calculation according to the basic information of livestock and the segmented aligned gait data to obtain an individualized abnormal threshold set; perform abnormal gait pattern recognition according to the individualized abnormal threshold set to obtain a gait deviation index matrix; The pain status assessment module is used to analyze the difference in limb weight-bearing ratios based on the gait deviation index matrix and the gait mechanics characteristic map to obtain limb weight-bearing characteristics; identify weight-bearing transfer pattern characteristics based on limb weight-bearing characteristics; identify pain behavior characteristics based on weight-bearing transfer pattern characteristics to obtain pain characteristic correlation data; and conduct limb health assessment based on pain characteristic correlation data to obtain a limb function health index; The health trend monitoring module is used to monitor the behavior patterns in time according to the limb function health index to obtain the livestock health trend map.
[0008] The livestock physiological behavior monitoring system integrates four core modules: gait data collection, abnormal feature recognition, pain status assessment, and health trend monitoring, to achieve comprehensive, objective, continuous monitoring and in-depth analysis of livestock physiological behavior. The system can capture the mechanical and kinematic details of livestock gait with high precision, establish an individualized health baseline, accurately identify and quantify subtle gait abnormalities, and then objectively assess limb function and pain levels, and predict health trends in combination with environmental and management information. This systematic monitoring and analysis capability significantly improves the ability to detect potential health problems early, prevent and intervene in advance, and provides scientific and reliable technical support for livestock management and animal husbandry production efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0009] Figure 1 The present invention is a schematic diagram of the steps of a livestock physiological behavior monitoring method.
[0010] The purpose, features and advantages of the present invention will be further described with reference to the accompanying drawings in conjunction with the embodiments. DETAILED DESCRIPTION
[0011] The technical method of the present invention is described clearly and completely below in conjunction with the accompanying drawings. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by technicians in this field without creative work are within the scope of protection of the present invention.
[0012] In the embodiment of the present invention, reference Figure 1 FIG. 1 is a schematic diagram of the steps of the livestock physiological behavior monitoring method of the present invention. In this example, the livestock physiological behavior monitoring method includes the following steps: Step S1: collecting a three-area pressure matrix through a pressure sensing pad; performing dynamic path recognition and camera adjustment according to the three-area pressure matrix to obtain dynamic path tracking data; performing livestock mechanical gait analysis according to the dynamic path tracking data to obtain a gait mechanical characteristic map; In the embodiment of the present invention, the focus is on collecting pressure and motion data when livestock walk, and conducting preliminary mechanical and kinematic analysis. The key points are to use a pressure sensing pad with three-region division and independent sensor array to collect a fine pressure matrix; use multiple high-speed cameras to synchronize joint markers to capture motion images; identify the dynamic path of hoof prints through pressure data, and adjust the camera in real time to maintain optimal tracking; extract ground reaction force from synchronously collected pressure data, and reconstruct the three-dimensional motion trajectory of joints from camera data; divide the gait cycle based on force and motion data; and finally integrate these data to generate a gait mechanics feature map containing mechanical, kinematic, time and space parameters.
[0013] Step S2: acquiring basic livestock information; performing individual gait time-series segmentation according to the gait mechanics characteristic map to obtain segmented aligned gait data; performing adaptive gait threshold calculation according to the basic livestock information and the segmented aligned gait data to obtain an individualized abnormal threshold set; performing abnormal gait pattern recognition according to the individualized abnormal threshold set to obtain a gait deviation index matrix; In the embodiment of the present invention, the focus is on establishing a personalized reference baseline based on the historical gait data of individual livestock, and on this basis, identifying the abnormal pattern of the current gait. The focus is on building and utilizing the individual historical gait database to calculate the individual baseline mean and variability of each gait parameter; standardizing and time-aligning the current gait parameters with the individual baseline (for example, using DTW); dynamically calculating the adaptive abnormal threshold set for the individual livestock based on the basic information of the livestock, historical variability and parameter importance; comparing the current gait parameters with the individualized thresholds to detect abnormal points in joint angles, ground reaction forces, lateral movement, etc.; analyzing the co-occurrence and temporal correlation of these abnormal points in the gait cycle; and finally generating a quantized gait deviation index matrix to reflect the degree of deviation of each gait parameter from the individual normal state.
[0014] Step S3: Perform limb weight-bearing ratio difference analysis based on the gait deviation index matrix and the gait mechanics characteristic map to obtain limb weight-bearing characteristics; identify weight-bearing transfer pattern characteristics based on the limb weight-bearing characteristics; identify pain behavior characteristics based on the weight-bearing transfer pattern characteristics to obtain pain characteristic associated data; perform limb health assessment based on the pain characteristic associated data to obtain a limb function health index; In the embodiment of the present invention, the main focus is on limb weight bearing and movement coordination, aiming to identify behavioral characteristics related to pain and evaluate the health status of limb function. The focus is on extracting limb weight bearing data from the gait mechanics characteristic map and the gait deviation index matrix, calculating the weight bearing ratio distribution and the ipsilateral weight bearing difference rate (symmetry index); analyzing the time parameters such as the duration of the support phase of each limb; comprehensively identifying abnormal weight transfer patterns (such as avoidance type) based on the weight bearing, symmetry and support time data; evaluating the range of motion of each joint and giving a score according to the gait deviation index matrix; matching the weight bearing distribution, symmetry, support time, weight transfer pattern and other characteristics with the preset pain behavior feature library, identifying the combination of pain-related features, locating the pain site, distinguishing the types of acute and chronic pain, and calculating the pain intensity score; finally integrating the pain intensity score, pain site location, and the limb function status score calculated based on weight bearing, symmetry, support time and joint activity, to generate a limb function health index reflecting the health level of each limb.
[0015] Step S4: Conducting time-series monitoring of behavior patterns based on the limb function health index to obtain a livestock health trend graph.
[0016] In the embodiment of the present invention, the limb function health index obtained in the above steps is integrated into the time series monitoring system, and is comprehensively analyzed in combination with environmental and management data to achieve disease risk warning and health trend prediction. The focus is on building a health index time series database with livestock individuals and time as dimensions; obtaining and associating environmental monitoring data and pasture management records with health index data according to timestamps to form a health-environment-management associated data set; analyzing historical data in the health index time series database to calculate the baseline of health fluctuations (mean, standard deviation, smooth curve, prediction range); using the health-environment-management associated data set, applying machine learning models to identify the association pattern between health anomalies and environmental / management factors, and predicting disease risks; and finally generating a visualized livestock health trend map to display historical health curves, current status, future predictions, and related risk warning information.
[0017] It is particularly important that step S4 is specifically: Construct a time series database of health index based on limb function health index and livestock individual identification information; Obtain environmental monitoring data and pasture management records and associate environmental and management data based on the health index time series database to obtain a health-environment-management association dataset; Calculate the health fluctuation baseline graph of the health index time series database; Disease risk warning and trend map generation are performed based on the health-environment-management correlation data set to obtain livestock health trend maps; In an embodiment of the present invention, the operation of constructing a health index time series database according to the limb function health index and the livestock individual identification information is: receiving the limb function health index of each limb (left front, right front, left rear, right rear) output in step S38 (for example, the left rear limb health index is 75, the right rear limb is 90, etc.), and the livestock individual identification information obtained in step S2 (for example, ear tag number AB123). Use the livestock individual identification information as the primary key to create a health index time series database. The database adopts a time series database (for example, InfluxDB or TimescaleDB) structure, which is dedicated to efficiently storing and querying data sequences with timestamps. A record entry is created for each livestock in the database, which contains the livestock's unique identifier (ear tag number) and health index data points arranged in chronological order. Each data point contains an accurate timestamp (for example, the time when the collection is completed, accurate to seconds) and the health index value of each limb. For example, the database can be stored as: [timestamp, ear tag number, left front health index, right front health index, left rear health index, right rear health index]. After each gait monitoring is completed and the limb function health index is calculated, the system writes these data together with the current timestamp and the livestock ear tag number as a new record into the time series database. As time goes by and the number of monitoring increases, the database will accumulate the historical time series data of the livestock's health index.
[0018] The operation of obtaining environmental monitoring data and pasture management records and associating environmental and management data according to the health index time series database to obtain the health-environment-management associated data set is as follows: the system obtains data from different data sources through interfaces. These data sources include environmental monitoring systems (for example, recording livestock house temperature, humidity, ammonia concentration, ventilation conditions, etc.) and pasture management systems (for example, recording feed batches, feeding amounts, drinking water conditions, vaccination records, veterinary treatment records, herd transfer information, birth dates, milking times and production, etc.). Environmental monitoring data are usually stored in the form of time series, including timestamps and various environmental parameter values. Pasture management records contain event type, occurrence time, livestock involved (associated by ear tag number) and related descriptive information. Access the constructed health index time series database, find the corresponding environmental parameter values in the same time period (for example, within 1 hour before and after) in the environmental monitoring data according to the timestamp of the health index data point, and associate the environmental parameters with the health index data point. At the same time, the pasture management records are searched for management events related to the livestock that occurred within a period of time before and after the health index collection time point (for example, within 24 hours before and after), and the management event information is associated with the health index data point. For example, if the left hind limb health index drops significantly at a certain point in time, the system will look for information such as the temperature and humidity of the barn at that time point, whether the feed batch has been changed, whether vaccination has been carried out, etc., and attach this information to the health index record. This association operation forms a comprehensive data set containing livestock identification, timestamps, limb health indexes, environmental parameters, and management events, namely the health-environment-management association data set.
[0019] The operation of calculating the health fluctuation baseline graph of the health index time series database is as follows: access the constructed health index time series database. For each livestock, extract its historical health index time series data (at least a certain length of historical data is required, such as the records of the past 30 days). Analyze the time series change pattern of the health index of each limb (left front, right front, left hind, right hind). Calculate the average and standard deviation of the health index of each limb in the historical records as the health baseline value and normal fluctuation range of the limb. At the same time, identify the intraday fluctuation pattern of the health index (for example, whether the health index decreases regularly during the peak activity period) and the weekly / monthly trend (for example, whether the health index shows specific changes as the lactation cycle progresses). Use a smoothing algorithm (for example, moving average or exponential smoothing) to remove short-term noise and generate a smooth health index history curve. Based on historical data, predict the normal fluctuation range of the health index for a period of time in the future (for example, the next 7 days), such as using a time series prediction model (for example, an ARIMA model or an LSTM network) to predict the mean and confidence interval. Visualize the historical average, standard deviation, smoothed curve, and predicted normal fluctuation range of each limb health index to form a health fluctuation baseline graph for the livestock. This baseline chart is an important reference for assessing whether the current health status is abnormal.
[0020] The operation of generating a trend map of livestock health based on the health-environment-management association dataset for disease risk warning and trend map is as follows: using the health-environment-management association dataset, analyze the statistical association between abnormal fluctuations in health index and environmental factors and management events. For example, if the hind limb health index of multiple livestock generally decreases after a certain feed batch is changed, the system will identify the association between "feed batch change" and "decline in hind limb health index" and mark it as a potential risk factor. If the temperature in the livestock house is continuously above 30°C and the health index of multiple livestock (especially the total health index or activity-related index) generally decreases, "high temperature" is identified as an environmental risk. Establish a disease risk prediction model that inputs the current livestock health index (the degree of deviation from the baseline), the identified abnormal gait pattern, as well as the current environmental parameters and recent management events. The model can use machine learning algorithms (e.g., decision trees, random forests, or neural networks) that are trained on historical health-environment-management association datasets to learn to identify patterns that are highly correlated with specific diseases (e.g., lameness, mastitis, respiratory diseases). For example, the model will learn that the combination of "left hind limb health index less than 60" and "hind limb weight difference rate greater than 20%" and "recent herd transfer" is highly correlated with lameness risk. The model outputs the risk probability of various potential diseases currently occurring in the livestock. At the same time, the livestock health trend map is generated by combining the historical trends in the health index time series database, the health fluctuation baseline map, and the risk probability output by the prediction model. The trend map visualizes the historical change curve of each limb health index, the degree of deviation of the current health status from the baseline, the predicted trend of the future health index (including the normal fluctuation range and the risk interval), and the environmental risk factors and management events associated with abnormal fluctuations in the health index. For example, the map can show that the left hind limb health index has continued to decline in the past 3 days, the current value is lower than the baseline normal range, and it is predicted that it will decline further in the next 7 days. At the same time, it marks that the decline is related to the recent high temperature environment or feed adjustment, and gives the warning level of lameness risk (for example, high risk). This trend map provides ranch managers with an overview of the health status of individual and group livestock, potential risk prompts, and decision support.
[0021] Preferably, step S1 comprises the following steps: Step S11: dividing the pressure sensing pad into three functional areas, namely, the front area, the middle area and the back area, according to the force characteristics of the livestock hoof, configuring each area with an independent pressure sensor array, and collecting the pressure matrix of the three areas through the pressure sensor array; Step S12: 6 high-speed cameras are set around the pressure sensing pad, and the spatial coordinates of the camera system are calibrated by a calibration plate to obtain a spatial coordinate mapping data set; Step S13: setting joint marking points of the livestock to be tested to obtain joint marking position data; Step S14: performing synchronous data acquisition triggering according to the three-region pressure matrix, the spatial coordinate mapping data set and the joint marker position data to obtain a synchronous triggering time series; Step S15: performing dynamic path identification and camera adjustment according to the three-region pressure matrix and the synchronous trigger time sequence to obtain dynamic path tracking data; Step S16: extracting ground reaction force data from the three-region pressure matrix according to the synchronous trigger time series and the dynamic path tracking data to obtain mechanical distribution time series data; Step S17: calculating a joint motion parameter set according to the spatial coordinate mapping data set, the joint marker position data and the synchronous triggering time series; Step S18: dividing the gait cycle according to the mechanical distribution time series data and the joint motion parameter set to obtain gait cycle segmentation data; Step S19: Generate a gait mechanics characteristic map based on the mechanical distribution time series data, the joint motion parameter set, the gait cycle segmentation data and the dynamic path tracking data.
[0022] In an embodiment of the present invention, the pressure sensing pad is divided into three functional areas, namely, the front area, the middle area and the back area, according to the force characteristics of the livestock's hooves. For example, a resistive pressure sensing pad with a size of 2 meters × 1 meters and a sensor density of 4 per square centimeter is used, and the first 0.5 meters along its length is divided into the front area, the middle 1 meter is divided into the middle area, and the back 0.5 meters is divided into the back area. Each area contains an independent pressure sensor array, for example, a grid composed of 200 × 100 independent pressure sensors, each sensor unit size is 0.5 cm × 0.5 cm, and the sensor sampling frequency is set to 200Hz. Through these sensor arrays, the instantaneous pressure distribution data applied by the three areas during the livestock walking process are collected simultaneously and independently to form a three-area pressure matrix, which is a three-dimensional array, and the dimensions are time, area index (front, middle, back), and sensor index (row, column) in the area.
[0023] Six high-speed cameras are set up around the pressure sensing pad. For example, a high-speed camera of model BasleracA2040-90uc with a resolution of 2048×1536 pixels and a frame rate of 120 frames / second is used, and it is arranged around the pressure pad, for example, two cameras are arranged on each side (long side) and one camera is arranged on each end (short side). The camera is set up at a height of 2 meters and 3 meters away from the edge of the pressure pad to ensure that the 360° field of view above the pressure pad can be covered. A standard chessboard calibration plate is used to take multiple images at different positions and angles above and around the pressure pad, and the Zhang Zhengyou calibration method is used to calculate the intrinsic and extrinsic parameters of each camera. Based on these parameters, a spatial coordinate mapping relationship between a global coordinate system (for example, with the center of the pressure pad as the origin) and each camera coordinate system is established to form a spatial coordinate mapping data set, which includes the distortion coefficient of each camera, the intrinsic parameter matrix, and the rotation and translation matrix from the global coordinate system to each camera coordinate system.
[0024] Marking points are set for the key joints of the livestock to be tested. For example, for a cow, passive reflective marking points with a diameter of 15 mm are used at the shoulder joint (highest point of the scapula), elbow joint (olecranon of the ulna), wrist joint (lateral radiocarpal joint), hip joint (greater trochanter of the femur), knee joint (lateral femoral condyle) and ankle joint (lateral malleolus of the fibula), and are firmly attached with non-irritating adhesives or elastic bands. Ensure that the marking points will not fall off or shift during the walking of the livestock, and can be clearly captured by at least two cameras from different angles. These preset joint point positions and their corresponding marking point numbers constitute the joint marking position data.
[0025] A pressure threshold trigger mechanism is set up to achieve synchronous data acquisition. For example, the pressure data of the front zone from the three-zone pressure matrix is monitored by a central control unit. When the total pressure of any sensor or sensor group in the front zone is detected to exceed the preset threshold (set to 50N), the central control unit immediately sends a synchronous trigger signal to the pressure data acquisition system and the high-speed camera system. After receiving the trigger signal, the pressure data acquisition system (operating at 200Hz) and the camera system (operating at 120Hz) start to synchronously record the data stream and attach a high-precision timestamp, such as a nanosecond timestamp, to each data record to ensure that the pressure data and the camera data are strictly aligned in time to form a synchronous trigger time series.
[0026] Dynamic path identification and camera adjustment are performed based on the three-region pressure matrix and the synchronous trigger time sequence. For example, during synchronous acquisition, the pressure data from the three-region pressure matrix is processed in real time, and the areas with pressure values greater than 50N are identified as hoof print points. The centroid coordinates of each detected hoof print point are calculated and their timestamps are recorded to form hoof print spatiotemporal sequence data. The nearest three consecutive hoof print points are taken, their centroid connection vectors are calculated, and the instantaneous walking direction vector of the current hoof print point sequence is calculated by vector average. Based on the hoof print point positions in the last 5 seconds, a livestock short-term walking trajectory prediction model is constructed using a second-order polynomial fitting method to predict the possible position of the livestock in the next 0.5 seconds. Based on the predicted future position and walking direction, the optimal camera angle that can maximize the capture of the joint point marks on the side and back of the livestock is calculated. By sending control instructions to the servo motor connected to the camera, the horizontal (Pan) and vertical (Tilt) angles of the camera are adjusted in real time to keep the livestock in the center of the camera's field of view and maintain the best observation angle, generating dynamic path tracking data.
[0027] Ground reaction force data are extracted from the three-region pressure matrix based on the synchronous trigger time series and dynamic path tracking data. For example, for the synchronously acquired three-region pressure matrix data stream, the pressure data is assigned to the corresponding limb based on the hoof print location and timestamp identified in the dynamic path tracking data. For each hoof strike event, the total vertical force (Fz, obtained by summing the pressures of all sensors in the hoof print area and multiplying by the sensor area) and the estimated anteroposterior (Fy) and lateral (Fx) shear forces (if the pressure mat sensor array includes shear force measurement capabilities or can be estimated from the pressure gradient of adjacent sensors) are extracted from the pressure mat sensor data. The time-varying curves of Fz, Fx, and Fy are calculated for each limb during the stance phase, and the time integral (impulse) and peak value of these force curves are calculated. These extracted data constitute the mechanical distribution time series data.
[0028] The joint motion parameter set is calculated based on the spatial coordinate mapping data set, the joint marker position data and the synchronous trigger time series. For example, the synchronous trigger time series is used to identify and extract the two-dimensional coordinates of the livestock joint marker points on each camera image plane from the image sequence captured by the high-speed camera using a marker tracking algorithm based on deep learning or traditional image processing. The two-dimensional image coordinates are reconstructed into the three-dimensional spatial coordinates of the marker points in the global coordinate system using the camera internal and external parameters in the spatial coordinate mapping data set through a multi-view three-dimensional reconstruction algorithm (such as direct linear transformation DLT or bundle adjustment BundleAdjustment). A fourth-order Butterworth low-pass filter with a cutoff frequency of 8Hz is applied to the reconstructed three-dimensional trajectory data for smoothing to eliminate noise. Based on the smoothed three-dimensional coordinates of the marker points, the livestock body segments (such as forearms, hind legs, etc.) are defined, and the posture (orientation) of each body segment is calculated. The relative angle between adjacent body segments is calculated as the joint angle (such as the flexion and extension angle, internal and external abduction angle, and internal and external rotation angle of the elbow joint and knee joint). The joint angle time series is numerically differentiated to calculate the joint angular velocity. These three-dimensional coordinates, body segment postures, joint angles and angular velocity data constitute the joint motion parameter set.
[0029] The gait cycle is divided according to the mechanical distribution time series data and the joint motion parameter set. For example, the change of the vertical ground reaction force (Fz) in the mechanical distribution time series data is used to identify the landing and departure moments of the limbs. The moment when Fz exceeds 50N is marked as landing (Initial Contact, IC), and the moment when Fz is continuously less than 10N is marked as departure (Toe Off, TO). A complete gait cycle (Gait Cycle, GC) is defined as the time period from the landing of a limb to the next landing of the same limb. The stance phase (Stance Phase, SP) is defined as the time period from IC to TO, and the swing phase (Swing Phase, SwP) is defined as the time period from TO to the next IC. The duration of each gait cycle, stance phase and swing phase is calculated, and the proportion of the stance phase and swing phase in the entire gait cycle is calculated. These timestamps, durations and proportions constitute the gait cycle segmentation data.
[0030] A gait mechanics feature map is generated based on the mechanical distribution time series data, joint motion parameter set, gait cycle segmentation data, and dynamic path tracking data. For example, for each identified gait cycle, the mechanical distribution time series data (Fz, Fx, Fy time series) and joint motion parameter set (joint angle, angular velocity time series) in the cycle are time-normalized, such as resampling to 100 data points, representing 0% to 100% of the gait cycle. Key scalar parameters are extracted, such as the peak value of each force component, impulse, stance phase duration, swing phase duration, step length (the distance between the center of mass of two consecutive ipsilateral footprints), step width (the distance between the center of mass of two consecutive contralateral footprints perpendicular to the forward direction), and step frequency (number of steps per minute). These normalized time series data and scalar parameters are integrated into a structured data set, such as using HDF5 format for storage. The data set contains all relevant mechanical, kinematic, temporal, and spatial parameters for each limb and each gait cycle to form a gait mechanics feature map.
[0031] Preferably, step S15 includes: Extract the spatiotemporal sequence data of hoof prints in the three-region pressure matrix according to the synchronous triggering time series; Calculate the path direction vector based on the time-space sequence data of hoof prints to obtain the livestock movement vector data; Calculate path prediction curve data based on livestock motion vector data and hoof print spatiotemporal sequence data; The turning point is identified based on the livestock motion vector data and the hoof print spatiotemporal sequence data to obtain the behavioral mutation mark data; The best observation angle is calculated based on the path prediction curve data and the behavior mutation mark data to obtain the camera angle optimization parameters; Collect dynamic path tracking data based on camera angle optimized parameters.
[0032] In an embodiment of the present invention, the spatiotemporal sequence data of hoof prints in the three-region pressure matrix is extracted according to the synchronous trigger time sequence. After the central control unit receives the synchronous trigger signal, the system starts to collect the three-region pressure matrix data of the pressure sensing pad at a frequency of 200 Hz. For each frame of pressure data, the sensor array is traversed to identify the sensor units with pressure values greater than 50N. Adjacent sensor units with pressure values exceeding the threshold are clustered to form an identified hoof print area. The pressure-weighted centroid coordinates (x, y) of each hoof print area are calculated, that is, the centroid coordinates = ∑ (sensor pressure × sensor coordinates) / ∑ (sensor pressure). Each calculated hoof print centroid coordinate (x, y) is associated with its corresponding acquisition timestamp and organized into sequence data arranged in time order to form hoof print spatiotemporal sequence data, for example, stored as a list containing [timestamp, x coordinate, y coordinate] tuples.
[0033] Calculate the path direction vector based on the hoof print spatiotemporal sequence data. Extract the three most recently detected consecutive hoof print points from the hoof print spatiotemporal sequence data. , and , whose coordinates are , and , the corresponding timestamp is . Calculate the displacement vector between adjacent points and . Through and Perform vector average calculation to get the current walking direction vector At the same time, calculate the time difference between the two most recent points The instantaneous walking speed is calculated as the vector The modulus of the ,Right now The calculated walking direction vector is associated with the instantaneous speed and the current timestamp to form the livestock motion vector data.
[0034] Calculate the path prediction curve data based on the livestock motion vector data and hoof print spatiotemporal sequence data. Use the hoof print spatiotemporal sequence data within the last 5 seconds to extract its (x, y) coordinates and corresponding timestamps. Normalize the timestamps relative to the current time. Use a second-order polynomial model to fit the livestock's walking trajectory, assuming that the x- and y-direction positions are quadratic functions of time: . Use the least squares method to solve the coefficients , so that the deviation between the fitting curve and the hoof print point data within the last 5 seconds is minimized. The fitted model is extrapolated to the time point of 0.5 seconds in the future, and the predicted (x, y) coordinate sequence is calculated to form the path prediction curve data. At the same time, the curvature of the prediction curve is calculated according to the prediction curve. , and predict the changing trend of the path direction.
[0035] Turning point identification is performed based on livestock motion vector data and hoof print spatiotemporal sequence data. A continuous sequence of walking direction vectors is extracted from livestock motion vector data. The angle θ between adjacent direction vectors is calculated. The instantaneous rate of change of the angle, i.e., Δθ / Δt, is calculated. When the rate of change of the angle continues to exceed 15° / second, it is determined that the livestock is turning at the current moment and is marked as a potential turning point. At the same time, the hoof print spatiotemporal sequence data is analyzed to calculate the time interval between consecutively detected hoof print points (without distinguishing between limbs). If a time interval exceeds 1.5 times the historical average gait cycle time of the livestock (for example, the mean of the gait cycle in the individual gait baseline parameter set), it is determined that the livestock has paused or hesitated and is marked as a potential pause point. These marks are associated with the corresponding timestamps to form behavioral mutation mark data.
[0036] Calculate the optimal observation angle based on the path prediction curve data and the behavior mutation marker data. Determine the predicted position and heading of the livestock in the next 0.5 seconds based on the path prediction curve data. Combine the livestock body shape information and joint marker position data to calculate the vector from each camera's current position to the predicted livestock position and the angle between the vector and the predicted heading. The goal is to calculate the angle that can maximize the exposure of the livestock's side or back (i.e., the main distribution area of the marker points) to the camera's field of view. For areas marked as potential turning points, calculate the composite angle that can capture the movement of the livestock's inner and outer limbs at the same time. For areas marked as potential pause points, calculate the angle that provides stable, multi-view observation (such as the front side and the back side). Considering all 6 cameras, a set of camera horizontal (Pan) and vertical (Tilt) angles that optimize the overall observation effect are calculated through an optimization algorithm to form camera angle optimization parameters, such as a list of target Pan and Tilt angles for each camera.
[0037] The dynamic path tracking data is collected according to the camera angle optimization parameters. The calculated camera angle optimization parameters are sent to the servo motor connected to the high-speed camera through the control interface. The servo motor adjusts the pan and tilt angles of the camera in real time according to the received parameters. The camera system continues to capture images at a frequency of 120 frames per second while adjusting the angle. By processing the captured images, for example, using a marker tracking algorithm, the position of the marker in the adjusted camera field of view is extracted in real time. Combined with the real-time internal and external parameters and posture of the camera (obtained by the servo motor angle feedback), the two-dimensional image coordinates of the marker are reconstructed into three-dimensional coordinates in the global coordinate system. These real-time updated three-dimensional coordinate sequences of the markers are the dynamic position and posture information of the livestock during walking, which constitute the dynamic path tracking data.
[0038] Preferably, the individual gait timing segmentation in step S2 includes: Obtain livestock individual identification information and construct and access a historical database based on gait mechanics characteristic maps to obtain an individual historical gait record set; Calculating an individual gait baseline parameter set from an individual historical gait record set; Standardizing the current gait parameters of various parameters in the gait mechanics characteristic map to obtain standardized gait parameters; The standardized gait parameters and individual gait baseline parameter sets are segmented and aligned in time series to obtain segmented aligned gait data.
[0039] In an embodiment of the present invention, individual identification information of livestock is obtained and a historical database is constructed and accessed according to the gait mechanics characteristic map. After the system collects the gait mechanics characteristic map, the individual identification information of livestock contained therein, such as a unique ear tag number, is read. The ear tag number is used as a search key to search for the historical gait record of the livestock in a structured database (for example, using a PostgreSQL database). If a record of the livestock already exists in the database, all gait mechanics characteristic map data of the livestock in the past 30 days are extracted to form an individual historical gait record set. If there is no record of the livestock in the database, the currently collected gait mechanics characteristic map is stored in the database as the first record of the livestock and marked as a basic record. The database is designed as a relational database, including a livestock information table (ear tag number, breed, age, weight, etc.) and a gait record table (ear tag number, acquisition timestamp, gait mechanics characteristic map data storage path or serialized data). After each livestock has accumulated at least 5 valid gait records (for example, collected on different dates and time periods), its historical record set is used for subsequent baseline calculations.
[0040] Calculate the individual gait baseline parameter set of the individual historical gait record set. Perform statistical analysis on all gait mechanical characteristic map data in the individual historical gait record set obtained from the historical database. For example, for key parameters such as gait cycle time, maximum flexion and extension angle of each joint, and peak vertical ground reaction force, calculate their mean (μ) and standard deviation (σ) in the historical records. Before calculating the mean and standard deviation, apply a robust statistical method, such as iteratively removing data points that are more than 3 standard deviations away from the mean, to eliminate the influence of outliers on the baseline calculation. The calculated historical mean and standard deviation of each gait parameter and the coefficient of variation (CV=σ / μ×100%) are stored to form the normal gait reference range of the livestock, that is, the individual gait baseline parameter set. This baseline parameter set is stored in a structured data format (such as JSON or XML) and is associated with the livestock individual identification information.
[0041] The current gait parameters are standardized for each parameter in the gait mechanics characteristic map. The scalar parameters (such as gait cycle time, joint angle peak, force peak, etc.) in the currently collected gait mechanics characteristic map are compared with the individual gait baseline parameter set of the livestock. For each parameter, the Z-score standardization method is used to calculate its standardized score, that is, standardized score = (current parameter value-baseline mean) / baseline standard deviation. If the baseline standard deviation is close to zero (indicating that the historical fluctuation is extremely small), the historical absolute deviation mean of the parameter is used as the denominator. For time series parameters (such as normalized joint angle curves and force curves), the root mean square error (RMSE) or correlation coefficient between it and the curve mean at the corresponding time point of the baseline is calculated as a standardized indicator. These calculated standardized values or indicators constitute standardized gait parameters.
[0042] The standardized gait parameters and individual gait baseline parameter sets were segmented and aligned in time series. According to the historical average gait cycle information of the livestock recorded in the individual gait baseline parameter set, the time series data (such as joint angle change curves and force curves) in the current standardized gait parameters were divided according to the gait cycle. A gait cycle is divided into four stages: landing period (Initial Contact to Loading Response), support period (Loading Response to Mid Stance), push-off period (Mid Stance to Terminal Stance) and swing period (Terminal Stance to Initial Contact). The division points of these stages are based on key events (such as landing and leaving the ground) in the segmented data of the gait cycle. In order to eliminate the difference between the current gait speed and the historical baseline speed, the time series data of each stage of the current gait were processed by the Dynamic Time Warping (DTW) algorithm to align its time axis with the time axis of the baseline gait. The DTW algorithm achieves nonlinear time alignment by finding the best matching path between two time series. After alignment, the standardized parameters of each phase of the current gait are compared point by point with the parameters of the corresponding phase of the baseline to form segmented aligned gait data. These data are stored in a structured format, containing the standardized values of each phase and each parameter at the time point after alignment.
[0043] Preferably, the adaptive gait threshold calculation in step S2 includes: Extract livestock characteristic standardized parameters based on livestock basic information and individual gait baseline parameter sets; The gait stability index is calculated based on the segmented aligned gait data to obtain the gait fluctuation characteristic spectrum; According to the gait fluctuation characteristic spectrum and the livestock characteristic standardized parameters, the parameter importance weights are allocated to obtain a parameter importance weight table; Identify individual-specific gait characteristics based on gait fluctuation characteristic spectrum; The threshold of abnormal joint angles was calculated based on the individual's unique gait characteristics; Calculate abnormal thresholds of mechanical parameters based on individual-specific gait characteristics; Calculate the abnormal threshold of time parameters according to the characteristic spectrum of gait fluctuation; The joint angle abnormal threshold, mechanical parameter abnormal threshold and time parameter abnormal threshold are integrated to obtain an individualized abnormal threshold set.
[0044] In an embodiment of the present invention, livestock characteristic standardized parameters are extracted based on livestock basic information and individual gait baseline parameter sets. From the livestock basic information database, static characteristics of the livestock to be monitored, such as weight (unit: kilogram), age (unit: month) and breed type (for example: Holstein cow, Simmental cow) are read. At the same time, the standard weight and life expectancy data of the breed of livestock are accessed. The body mass index is calculated, that is, body mass index = actual weight / breed standard weight. The age coefficient is calculated, that is, age coefficient = actual age / breed life expectancy. These calculated values, such as a body mass index of 1.05 (indicating 5% heavier than the standard weight) and an age coefficient of 0.6 (indicating 60% of the expected life span), constitute livestock characteristic standardized parameters, which are used as adjustment factors for subsequent threshold calculations.
[0045] The gait stability index was calculated based on the segmented aligned gait data. The variability index of each gait parameter was calculated using the individual historical gait record set (at least 5 records) in the historical database and the segmented aligned gait data currently collected and aligned with the baseline. For parameters such as gait cycle time, stance phase duration, swing phase duration, maximum / minimum angles of each joint during stance and swing phases, vertical ground reaction force peak, and anterior and posterior shear force peak, the coefficient of variation (CV) in all historical records was calculated. The coefficient of variation calculation formula is: CV=(standard deviation / mean)×100%, μ is the historical mean of the parameter, and σ is the historical standard deviation of the parameter. Parameters with low coefficients of variation indicate that the historical fluctuation of the parameter is small and the gait is stable; parameters with high coefficients of variation indicate large fluctuations and poor stability. The coefficients of variation of each parameter are combined to form a gait fluctuation characteristic spectrum, such as a list containing [parameter name, CV value] tuples.
[0046] Parameter importance weights are assigned based on the gait fluctuation characteristic spectrum and the livestock characteristic standardized parameters. Based on the breed type of livestock (obtained from the livestock characteristic standardized parameters), a preset parameter importance weight table is consulted. For example, for dairy cattle breeds, the weight-bearing parameters of the hind limbs (such as vertical force peak, weight-bearing time) and the mobility parameters of the hind limb joints (such as knee joints and ankle joints) are assigned higher importance weights (such as 0.8-1.0), while the weights of some parameters of the forelimbs are slightly lower (such as 0.6-0.8). For beef cattle breeds, more attention is paid to the overall movement coordination and balanced weight-bearing of the limbs. According to the CV value of each parameter in the gait fluctuation characteristic spectrum, the preset weights are fine-tuned: for key parameters with low CV values (high stability), their weights are further increased to emphasize their value as a stable baseline; for parameters with abnormally high CV values (poor stability), their weights are slightly reduced, indicating that the parameter itself is unstable and its changes do not completely represent abnormalities. These weight values constitute a parameter importance weight table, such as a dictionary containing [parameter name, importance weight] tuples.
[0047] Identify individual-specific gait characteristics based on the gait fluctuation characteristic spectrum. Analyze parameters with low CV values (e.g., CV < 10%) in the gait fluctuation characteristic spectrum. At the same time, compare the historical means of these parameters with the group averages of livestock of the same breed and age group. If the historical mean of a parameter is significantly different from the group average (e.g., the difference is more than 1.5 times the group standard deviation), but the parameter shows low variability in the historical records of the individual livestock, that is, it stably deviates from the group mean, then the deviation is determined to be a gait rhythm characteristic unique to the individual livestock, rather than an abnormality. For example, if the peak vertical force of the left hind limb of a certain cow is always 10% lower than the group average, but its CV value is only 5%, it will be marked as an individual-specific feature of low left hind limb weight bearing. These identified individual-specific gait characteristics and their degree of deviation are recorded to form an individual-specific gait characteristic record.
[0048] The threshold for abnormal joint angles is calculated based on the gait fluctuation characteristic spectrum, the parameter importance weight table, and the individual gait feature record. For each joint angle parameter in the segmented aligned gait data (such as the maximum angle of knee flexion and extension during the stance phase), the initial threshold is set based on its coefficient of variation (σ) in the gait fluctuation characteristic spectrum and the historical mean (μ) in the individual gait baseline parameter set. For example, a threshold based on the historical standard deviation is used: the upper threshold = μ + k × σ, and the lower threshold = μ - k × σ. The coefficient k is dynamically set based on the CV value of the parameter and its weight in the parameter importance weight table, for example, k = f (CV, ImportanceWeight), where f is a decreasing function (the higher the CV, the larger k, and the higher the weight, the smaller k). Then, the threshold is adjusted based on the individual gait feature record: if a joint angle parameter is identified as an individual-specific feature, its baseline mean is adjusted to the individual historical mean, and the threshold range is appropriately tightened (the k value is reduced) based on its individual stability (low CV). These calculated upper and lower limit values constitute the joint angle abnormality thresholds, such as a list containing tuples of [joint name, gait phase, parameter name, lower threshold, upper threshold].
[0049] Mechanical parameter abnormality thresholds are calculated based on the gait fluctuation characteristic spectrum, parameter importance weight table, and individual gait characteristic records. For mechanical parameters such as ground reaction force (such as vertical force peak and anterior-posterior shear force impulse), the initial threshold is also set based on its historical distribution characteristics (mean μ, standard deviation σ) in the gait fluctuation characteristic spectrum and the weight in the parameter importance weight table. A percentile-based method can be used: the lower threshold is set to the 5th percentile of the historical data, and the upper threshold is set to the 95th percentile of the historical data. According to the CV value and importance weight of the parameter, the percentile range is adjusted. For example, for parameters with high importance and good stability, the threshold range is tightened to the 2.5th percentile to the 97.5th percentile. If a mechanical parameter is identified as an individual gait characteristic, such as persistently low weight bearing, the threshold is calculated based on its individual historical mean and standard deviation, rather than the group mean, and the threshold range is adjusted according to its individual stability. These calculated values constitute the mechanical parameter abnormality threshold.
[0050] The abnormal threshold of time parameters is calculated based on the gait fluctuation characteristic spectrum and livestock characteristic standardized parameters. For time parameters such as gait cycle, stance phase duration, swing phase duration, etc., the initial threshold is set based on their historical distribution (mean μ, standard deviation σ) in the gait fluctuation characteristic spectrum. The threshold range is adjusted according to the age coefficient and body mass index in the livestock characteristic standardized parameters. For example, the gait cycle of older livestock will become longer and the diurnal fluctuation will increase, so the upper threshold limit and fluctuation range of the time parameters are appropriately relaxed. Livestock whose weight deviates significantly from the standard weight also have different gait rhythms. For example, the upper threshold limit = + + + , lower threshold = - - - ,in It is an adjustment factor set based on experience or historical group data. These calculated values constitute the abnormal threshold of the time parameter.
[0051] Combine the abnormal joint angle thresholds, mechanical parameter abnormal thresholds, and time parameter abnormal thresholds. Collect the calculated abnormal joint angle thresholds, mechanical parameter abnormal thresholds, time parameter abnormal thresholds, and lateral movement amplitude abnormal thresholds (if calculated). Organize all thresholds in a structured manner, such as by parameter type, limb, and gait phase. Store these values as a complete set of individualized abnormal thresholds, such as a dictionary or list containing all parameter names and their corresponding upper and lower thresholds. This set is the personalized criteria for determining whether the gait is abnormal for this particular livestock in the current state.
[0052] Preferably, the abnormal gait pattern recognition in step S2 includes: According to the individualized abnormal threshold set, the segmented aligned gait data is subjected to joint angle change abnormality detection to obtain joint angle abnormality labeling data; The ground reaction force anomaly detection is performed on the segmented aligned gait data according to the individualized anomaly threshold set to obtain the abnormal marking data of mechanical parameters; The lateral movement amplitude of the segmented aligned gait data is analyzed according to the individualized abnormal threshold set to obtain the lateral movement abnormality labeling data; Perform time correlation analysis on abnormal joint angle labeling data, abnormal mechanical parameter labeling data, and abnormal lateral movement labeling data to obtain abnormal pattern time series correlation data; A gait deviation index matrix is generated based on abnormal joint angle labeling data, abnormal mechanical parameter labeling data, abnormal lateral movement labeling data and abnormal pattern time series association data.
[0053] In an embodiment of the present invention, joint angle change abnormality detection is performed on the segmented aligned gait data according to the individualized abnormal threshold set. For the standardized angle change rate time series of each joint (e.g., knee joint) in the segmented aligned gait data in a specific gait phase (e.g., support phase), it is compared with the upper and lower thresholds corresponding to the parameter in the individualized abnormal threshold set. For example, if the standardized flexion and extension angle change rate of the knee joint at a certain time point in the support phase is higher than the upper limit of its individualized abnormal threshold or lower than the lower limit, it is marked as abnormal at that time point. Repeat this process for the joint angle change rate parameters of all joints and all gait phases. All time points that exceed the threshold range and the corresponding abnormal parameters and deviation degrees are recorded to form joint angle abnormality marking data, such as a list containing [limb, joint, gait phase, time point (gait cycle percentage), abnormal parameter name, deviation value, abnormal level] tuples.
[0054] Ground reaction force anomaly detection is performed on the segmented aligned gait data according to the individualized anomaly threshold set. For each limb in the segmented aligned gait data, the normalized vertical ground reaction force, anteroposterior shear force, and lateral shear force time series during the stance phase, as well as scalar parameters such as the peak value and impulse of these forces, are compared with the corresponding thresholds in the individualized anomaly threshold set. For example, if the vertical force peak of a limb in the stance phase is lower than its individualized anomaly threshold lower limit (indicating unloading), or the anteroposterior shear force impulse exceeds its upper limit (indicating abnormal push-off), it is marked as abnormal. This process is repeated for all limb mechanical parameters. All parameters that exceed the threshold range and the degree of deviation are recorded to form mechanical parameter abnormality marking data, such as a list of [limb, gait phase, parameter name, deviation value, abnormality level] tuples. The abnormality level can be divided according to the degree of deviation from the threshold, such as mild (deviation of 1-2 standard deviations), moderate (deviation of 2-3 standard deviations), and severe (deviation of more than 3 standard deviations).
[0055] The segmented aligned gait data is analyzed for lateral movement amplitude according to the individualized abnormal threshold set. The segmented aligned gait data contains the three-dimensional position information of the center of gravity of the livestock body during the gait cycle. The displacement time series of the center of gravity in the lateral direction (perpendicular to the forward direction) is extracted. The maximum lateral swing amplitude of the center of gravity during the gait cycle is calculated. The amplitude is compared with the upper and lower thresholds corresponding to the parameter in the individualized abnormal threshold set. For example, if the lateral swing amplitude exceeds the upper threshold (indicating gait instability or pain compensation), it is marked as lateral movement abnormality. At the same time, the symmetry of the lateral movement of the center of gravity is analyzed, and the difference rate of the left and right swing amplitudes is calculated. If the difference rate exceeds the threshold, it is also marked as abnormal. These lateral movement abnormalities are recorded to form lateral movement abnormality marking data, such as a list containing [parameter name (such as lateral swing amplitude, left and right symmetry), deviation value, abnormality level] tuples.
[0056] Perform temporal correlation analysis on abnormal joint angle labeling data, abnormal mechanical parameter labeling data, and abnormal lateral movement labeling data. Analyze the occurrence time and duration of the labeled joint angle abnormalities, mechanical parameter abnormalities, and lateral movement abnormalities in the gait cycle. For example, if the abnormal decrease in the vertical force peak of a limb and the abnormal increase in the flexion angle of the knee joint of the limb during the support period occur simultaneously or in a very short time interval, it is considered that there is a temporal correlation between them. Identify whether there are frequent co-occurrence patterns between different abnormal labeling data, such as "reduced weight bearing on a certain limb" is often accompanied by "excessive flexion of the ipsilateral wrist joint." Construct an abnormal pattern temporal correlation graph, where nodes represent different abnormal parameters, edges represent their co-occurrence or sequential relationship in the gait cycle, and the weight of the edge represents the strength or frequency of the association. These association information are recorded to form abnormal pattern temporal correlation data.
[0057] The gait deviation index matrix is generated based on the abnormal joint angle marker data, mechanical parameter abnormal marker data, lateral movement abnormal marker data and abnormal pattern time series association data. All abnormal marker data are integrated to calculate a quantitative gait deviation index for each key gait parameter (e.g., left forelimb vertical force peak, right hind limb knee maximum flexion angle, overall lateral swing amplitude). The calculation of the deviation index is based on the degree of deviation of the parameter from the threshold (e.g., the percentage of deviation from the upper / lower threshold) and its abnormal level. For example, the more deviations from the threshold, the higher the level, and the higher the deviation index. The value range of the deviation index is set to 0-10 points, where 0 means that the parameter is within the normal threshold range or has only a very slight deviation, and 10 means that the parameter seriously exceeds the threshold and has a high abnormal level. At the same time, the abnormal pattern time series association data is considered: if the abnormality of a parameter is strongly associated with the abnormalities of multiple other important parameters, its deviation index is appropriately increased. The deviation indices of all key gait parameters are summarized into a matrix, such as a two-dimensional matrix with rows representing parameters (such as the peak vertical force of the left forelimb) and columns representing different types of deviation indices (such as the degree of deviation from the threshold, the abnormal grade, and the final deviation index), to form a gait deviation index matrix. This matrix clearly quantifies the degree of deviation of each gait parameter from the individual's normal baseline.
[0058] Preferably, step S3 comprises: Step S31: extracting limb weight-bearing data from the gait deviation index matrix and the gait mechanics characteristic map to obtain original limb weight-bearing data; Step S32: Calculating a weight ratio distribution diagram based on the original limb weight data and the weight data in the livestock basic information; Step S33: Calculate the weight difference rate between the left forelimb and the right forelimb, and between the left hind limb and the right hind limb according to the weight ratio distribution diagram, mark the weight difference rate exceeding 15% as asymmetric weight, calculate the asymmetry degree index, and finally obtain the limb weight symmetry index; Step S34: performing load-bearing time analysis according to the gait mechanics characteristic map and the limb load-bearing symmetry index to obtain support time characteristic data; Step S35: identifying the characteristics of the weight transfer pattern according to the weight ratio distribution diagram, the limb weight symmetry index and the support time characteristic data; Step S36: evaluating the joint range of motion of the gait mechanics characteristic map according to the gait deviation index matrix to obtain a joint range of motion score; Step S37: performing pain behavior feature recognition according to the weight-bearing ratio distribution diagram, the limb weight-bearing symmetry index, the support time characteristic data, and the weight-bearing transfer pattern characteristics to obtain pain feature association data; Step S38: Perform limb health assessment based on pain feature association data to obtain a limb function health index.
[0059] In an embodiment of the present invention, limb load data is extracted from the gait deviation index matrix and the gait mechanics characteristic map. From the gait mechanics characteristic map, for each identified gait cycle and each limb (left front, right front, left rear, right rear), the vertical ground reaction force (Fz) time series data during the support phase is extracted. The maximum value of Fz (peak load) and the time integral of Fz (impulse, representing the force effect during the total load time) of each limb during the support phase are calculated. At the same time, the gait deviation index matrix is consulted to obtain the deviation index of the vertical ground reaction force parameters (peak value, impulse, curve shape) of each limb. These extracted values and deviation indices are associated to form the original limb load data, such as a structured data containing fields such as [limb, gait cycle ID, vertical force peak value, vertical force impulse, vertical force peak deviation index, vertical force impulse deviation index].
[0060] The weight ratio distribution diagram is calculated based on the limb weight raw data and the weight data in the livestock basic information. The weight data of the current livestock (for example: 600 kg) is obtained from the livestock basic information database. For each gait cycle in the limb weight raw data, the sum of the vertical force peaks of the four limbs is calculated, which represents the total instantaneous weight in the gait cycle. The vertical force peak of each limb is divided by the livestock weight to calculate the relative weight ratio of the limb. For example, the vertical force peak of the left forelimb is 3500N, and the livestock weight is 600kg (about 5880N), then the relative weight ratio of the left forelimb is 3500 / 5880≈0.595, which is about 59.5% of the body weight. Calculate the average weight ratio of each limb in multiple gait cycles. Visualize these average weight ratios, for example, using a four-quadrant diagram, each quadrant represents a limb, and the color depth or value size represents the weight ratio to form a weight ratio distribution diagram.
[0061] Calculate the weight-bearing difference rate between the left forelimb and the right forelimb, and between the left hindlimb and the right hindlimb according to the weight-bearing ratio distribution map. Extract the average weight-bearing ratio of the left forelimb, right forelimb, left hindlimb and right hindlimb from the weight-bearing ratio distribution map. Calculate the weight-bearing difference rate between the ipsilateral limbs (left and right forelimbs, left and right hindlimbs). For example, if the weight-bearing ratio of the left forelimb is P_LF and the weight-bearing ratio of the right forelimb is P_RF, then the weight-bearing difference rate of the forelimb = |P_LF-P_RF| / ((P_LF+P_RF) / 2)×100%. Calculate the weight-bearing difference rate of the hindlimb = |P_LH-P_RH| / ((P_LH+P_RH) / 2)×100%. If the weight-bearing difference rate of the forelimb or hindlimb exceeds 15%, it is marked as asymmetric weight-bearing. Calculate the asymmetry index, for example, map the difference rate to a score of 0-10, a difference rate of 15% corresponds to a score of 0, and a difference rate of 50% corresponds to a score of 10. These calculated difference ratios and asymmetry indexes constitute the limb weight-bearing symmetry index.
[0062] The weight-bearing time analysis was performed based on the gait mechanics characteristic map and the limb weight-bearing symmetry index. From the gait mechanics characteristic map, the duration of the stance phase of each limb in each gait cycle was extracted. The proportion of the stance phase duration of each limb to the total time of the gait cycle was calculated. The average stance phase duration and its proportion of each limb in multiple gait cycles were calculated. If the stance phase duration of a limb is significantly shortened (for example, more than 20% shorter than the individual baseline average) and the limb weight-bearing symmetry index shows that there is asymmetric weight-bearing on the ipsilateral limb, it indicates that the limb is painfully unloaded and the weight-bearing is reduced by shortening the stance time. These stance phase durations, proportions, and the degree of deviation from the baseline are recorded to form the support time characteristic data.
[0063] Identify the characteristics of the load transfer pattern based on the load ratio distribution diagram, limb load symmetry index and support time feature data. Analyze the dynamic process of the change of the load ratio of the four limbs over time during the gait cycle of livestock. Under normal circumstances, the load is transferred between the four limbs gradually and smoothly. Identify abnormal load transfer sequences, for example: if a limb (such as the left hind limb) reaches a peak and drops rapidly after landing, and the load on the contralateral limb (right hind limb or left forelimb) increases rapidly, this is an avoidance load transfer, indicating pain in the left hind limb. If the livestock has obvious "jumping" or "rushing" phenomena during walking, manifested as a very short support time of a limb and a rapid transfer of load to other limbs, this indicates acute pain. Based on the load ratio, symmetry and support time data, these abnormal load transfer patterns are identified by pattern matching algorithms to form load transfer pattern characteristics, such as a list containing [pattern type (such as avoidance, jumping), involved limbs, pattern intensity].
[0064] The gait mechanics characteristic map was used to evaluate the joint range of motion according to the gait deviation index matrix. From the gait mechanics characteristic map, the range of motion parameters such as the maximum flexion and extension angle, internal and external abduction angle, and internal and external rotation angle of each joint (such as shoulder, elbow, wrist, hip, knee, and ankle joint) during the stance phase and swing phase were extracted. The gait deviation index matrix was consulted to obtain the deviation index of these joint range of motion parameters. For example, if the maximum flexion angle of the left hind limb knee joint during the swing phase is significantly reduced compared with the individual baseline (high deviation index), it indicates that the joint range of motion is limited. According to the deviation index of each joint range of motion parameter, a joint range of motion score of 0-100 was calculated, where 100 indicates that the range of motion is completely normal (deviation index close to 0) and 0 indicates that the range of motion is severely limited (deviation index close to 10). The range of motion scores of the main joints of the limbs were summarized to form the joint range of motion score data.
[0065] Pain behavior characteristics are identified based on the weight-bearing ratio distribution diagram, limb weight-bearing symmetry index, support time characteristic data, and weight-bearing transfer pattern characteristics. Based on the known animal pain behavior characteristic library, the library contains pain-related gait performance characteristics as described in the "Laminess Scoring Standard", such as asymmetric weight-bearing, shortened step length, shortened support time, head nodding, back arching, etc. The weight-bearing ratio distribution diagram, limb weight-bearing symmetry index, support time characteristic data, and weight-bearing transfer pattern characteristics calculated in the previous step are matched with the pain behavior characteristic library. For example, if the limb weight-bearing symmetry index shows that the weight-bearing difference rate of the left hind limb exceeds 25%, the support time characteristic data shows that the duration of the support phase of the left hind limb is shortened by more than 30%, and the avoidance weight-bearing transfer pattern is identified to involve the left hind limb, then these feature combinations are highly associated with left hind limb pain. A pain relevance score is calculated for each identified pain-related feature, and a high score indicates that the feature is strongly associated with pain. These features, the involved limbs, and the pain relevance scores are recorded to form pain feature association data.
[0066] Limb health assessment is performed based on pain feature association data and joint range of motion scores. The health status of each limb (and the whole) is assessed by combining pain feature association data and joint range of motion scores. For example, for the left hind limb, if the pain feature association data shows multiple strongly associated pain features such as asymmetric weight bearing, shortened support time, and avoidance-style weight transfer, and the joint range of motion score shows that the knee and ankle joints are severely restricted in movement, then the left hind limb is judged to have a high degree of pain and dysfunction. A comprehensive 0-100 point limb function status score is calculated, where 100 indicates completely normal function and a lower score reflects the degree of dysfunction. At the same time, a 0-10 point pain probability rating is calculated based on the intensity and quantity of pain feature association data and the degree of joint range of motion restriction, for example, 0 indicates no signs of pain and 10 indicates extreme pain. The weight-bearing ratio values, functional status scores, and pain probability ratings of the four limbs are integrated to form a limb function health index, and the problematic limbs and their pathological manifestations are clearly marked (for example: the left hind limb function score is 60, the pain rating is 8, and it is manifested as insufficient weight bearing, short support time, and limited knee joint movement).
[0067] Preferably, step S37 includes: Standardized pain feature vectors were extracted based on the weight-bearing ratio distribution diagram, limb weight-bearing symmetry index, support time characteristic data, and weight-bearing transfer pattern characteristics; Obtain livestock breed reference data and determine feature thresholds based on standardized pain feature vectors to obtain a pain feature active state table; Perform feature co-occurrence pattern analysis based on the pain feature active state table to obtain feature co-occurrence pattern data; Perform pain location analysis based on feature co-occurrence pattern data to obtain a pain location map; Compensatory behavior identification is performed based on feature co-occurrence pattern data to obtain compensatory behavior pattern data; Differentiate acute and chronic pain patterns based on feature co-occurrence pattern data and compensatory behavior pattern data to obtain pain type determination data; The pain intensity score data were calculated based on the feature co-occurrence pattern data and pain location localization; Pain feature association data were calculated based on pain intensity score data and pain type determination data.
[0068] In the embodiment of the present invention, the operation of extracting the standardized pain feature vector according to the weight-bearing ratio distribution diagram, the limb weight-bearing symmetry index, the support time characteristic data and the weight-bearing transfer mode characteristics is: obtaining the average weight-bearing ratio of each limb from the weight-bearing ratio distribution diagram (for example, the weight-bearing ratio of the left hind limb is 40%), and calculating its deviation from the standard average weight-bearing ratio of the breed of livestock (for example, the standard average weight-bearing ratio of the hind limb is 55%) (40%-55%=-15%). Obtain the weight-bearing difference rate between the ipsilateral limbs (for example, the weight-bearing difference rate of the hind limbs is 25%) and the asymmetry index (for example, the corresponding score is 7) from the limb weight-bearing symmetry index. Obtain the proportion of the average support phase duration of each limb in the gait cycle from the support time characteristic data (for example, the support ratio of the left hind limb is 30%), and calculate its deviation from the average support ratio of the individual gait baseline (for example, the average support ratio of the left hind limb of the individual baseline is 45%) (30%-45%=-15%). The identified weight transfer pattern type (e.g., avoidance) and its intensity (e.g., intensity score of 8) are obtained from the weight transfer pattern feature. These raw values are standardized, for example, using the Min-Max standardization method to standardize the weight ratio deviation and support ratio deviation to the interval [-1,1], and the difference rate, asymmetry index, and transfer pattern intensity to the interval [0,1]. The standardization formula is (original value-minimum value) / (maximum value-minimum value). The standardized weight ratio deviation, standardized support ratio deviation, standardized weight difference rate, standardized asymmetry index, and standardized weight transfer pattern intensity values of all limbs are combined into a multidimensional vector to form a standardized pain feature vector. For example, the vector contains dimensions such as [left front weight deviation, right front weight deviation, left rear weight deviation, right rear weight deviation, forelimb difference rate, hindlimb difference rate, left front support deviation, right front support deviation, left rear support deviation, right rear support deviation, transfer pattern intensity].
[0069] The operation of obtaining the reference data of livestock breeds and determining the feature threshold according to the standardized pain feature vector to obtain the active state table of the pain feature is: accessing the pre-established pain feature threshold database, which stores the reference thresholds of different livestock breeds (e.g., Holstein cows and Simmental cows) for each dimension parameter in the standardized pain feature vector. These thresholds are obtained based on the statistical analysis of the group gait data of a large number of healthy livestock. For example, the normal upper limit threshold of the hind limb weight difference rate of Holstein cows corresponds to a standardized value of 0.2, and the normal lower limit threshold of the left hind limb support ratio deviation corresponds to a standardized value of -0.3. Compare each parameter value in the currently collected standardized pain feature vector with the reference threshold corresponding to the livestock breed. If a parameter value exceeds its normal range threshold (e.g., the standardized value of the left hind limb weight deviation is -0.5, which is less than the reference lower limit threshold of its breed -0.3), the feature is determined to be in an "active" state, indicating that the feature shows abnormal deviation. If the parameter value is within the threshold range, it is determined to be in an "inactive" state. Record all parameters in the standardized pain feature vector and their corresponding "active" or "inactive" states, for example, using a binary matrix or list, where the rows of the matrix represent different pain features and the columns represent their active states (1 for active and 0 for inactive), to form a pain feature active state table.
[0070] The operation of performing feature co-occurrence pattern analysis based on the pain feature active state table to obtain feature co-occurrence pattern data is: analyzing which features in the pain feature active state table are in the "active" state at the same time. Use an association rule mining algorithm (such as the Apriori algorithm) or a predefined pattern matching rule library. The predefined pattern matching rule library contains known feature combination patterns related to specific pain locations or types. For example, a pattern is defined as: if the "left hind limb weight bearing deviation" is active and negative (indicating reduced weight bearing), and the "left hind limb support ratio deviation" is active and negative (indicating shortened support time), and the "hind limb weight bearing difference rate" is active and positive (indicating that the left hind limb is less loaded than the right hind limb), then it is determined that there is a "left hind limb unloading pattern". Traverse the pain feature active state table to identify which predefined pattern feature combinations are active in the current observation, or identify which feature sets are frequently active together. The identified feature co-occurrence patterns and their matching degrees (for example, all features in the pattern are active for a complete match, and some features are active for a partial match) are recorded to form feature co-occurrence pattern data, such as a structured data containing [pattern name, involved limbs, matching degree, active feature list].
[0071] The operation of performing pain location analysis based on feature co-occurrence pattern data to obtain a pain location map is as follows: determine the body part where pain exists based on the pattern name identified in the feature co-occurrence pattern data and the limb information involved. Each predefined feature co-occurrence pattern is highly associated with one or more specific pain sites. For example, if the "left hind limb unloading pattern" is identified and the matching degree is high, the pain site is preferentially located to the left hind limb. If the "forelimb asymmetry pattern" is identified and involves the reduction of the right forelimb load, the pain site is preferentially located to the right forelimb. If the pattern involves multiple limbs, such as the "diagonal unloading pattern" (the left hind limb and the right forelimb are unloaded at the same time), it indicates a more complex cause or compensation of pain. The confidence score of each potential pain site is calculated based on the matching degree of the pattern and the strength of the pattern itself associated with the pain site (preset weight). Visualize the pain site location results, such as marking the most painful limb or area on a livestock body contour map, and use color depth or numerical value to indicate the confidence of the pain site to form a pain site location map.
[0072] The operation of compensatory behavior pattern data obtained by compensatory behavior pattern identification based on feature co-occurrence pattern data is as follows: in the feature co-occurrence pattern data, in addition to identifying the pattern pointing to the pain site, it is also necessary to identify the features that show abnormal increase in weight or change in movement pattern of other limbs. These are usually compensatory behaviors taken by livestock to reduce the burden on the painful limb. For example, if the main pattern points to pain in the left hind limb (reduced load on the left hind limb, short support time), and the feature co-occurrence pattern data shows that the "right hind limb weight-bearing deviation" is active and positive (indicating increased weight on the right hind limb), or the "left forelimb support time deviation" is active and positive (indicating prolonged support time on the left forelimb), then it is determined that the increased weight on the right hind limb and the prolonged support time on the left forelimb are compensatory behaviors for pain in the left hind limb. Identify these compensatory features and their activity levels, and associate them with the located pain site. The identified compensatory behavior type, involved limb, compensation degree, and targeted pain site are recorded to form compensatory behavior pattern data, such as a structured data including [compensatory limb, compensation type (e.g., increased weight bearing, prolonged support time), compensation degree score, targeted pain site].
[0073] The operation of distinguishing acute and chronic pain patterns according to feature co-occurrence pattern data and compensatory behavior pattern data to obtain pain type determination data is: combining the currently identified feature co-occurrence pattern data and compensatory behavior pattern data with the historical gait records of the livestock for comparative analysis. Access the historical feature co-occurrence pattern data and compensatory behavior pattern data records of the livestock. Analyze whether the currently identified pattern is the first time it appears, or whether its frequency and intensity have changed significantly compared with the historical records. If a pain pattern (such as a left hind limb unloading pattern) and the corresponding compensatory behavior (such as increased weight on the right hind limb) persist in the historical records and are relatively stable, for example, they are detected 80% of the time in the gait collection of the past 30 days, it is determined to be a chronic pain pattern. If a strong pain pattern suddenly appears and the compensatory behavior shows high variability or incoordination, for example, it has never appeared in the historical records, and a high-intensity left hind limb unloading and jumping transfer pattern is suddenly detected in this collection, it is determined to be an acute pain pattern. The pain type determination results (acute or chronic) and the basis for the determination (e.g., frequency of pattern occurrence, rate of change of intensity, and compensatory stability) are recorded to form pain type determination data.
[0074] The operation of calculating the pain intensity score data based on the feature co-occurrence pattern data and the location of the pain site is as follows: based on the pattern type, matching degree, and standardized values of the features involved in the feature co-occurrence pattern data, combined with the results of the location of the pain site, a quantitative pain intensity score is calculated. The basic pain intensity scores are set in advance for different feature co-occurrence patterns. For example, the basic score of "mild asymmetry pattern" is low, and the basic score of "severe load reduction with jump transfer pattern" is high. The higher the matching degree of the pattern (that is, the more active features in the pattern), the higher the final score. At the same time, the standardized deviation degree of the active features in the pattern is included in the calculation. For example, the standardized value of the left hind limb load deviation of -0.8 (severe deviation) will contribute more to the pain intensity score than the standardized value of -0.4 (moderate deviation). A weighted sum model or rule-based scoring system is used to combine the pattern basic score, pattern matching degree, active feature deviation degree, and the confidence of the location of the pain site to calculate a pain intensity score of 0-10 points, where 0 indicates no signs of pain and 10 indicates extreme pain. The calculated pain intensity score is recorded to form the pain intensity score data.
[0075] The operation of calculating pain feature association data based on pain intensity score data and pain type determination data is: integrating the pain intensity score data (e.g., pain intensity score is 8.5) and pain type determination data (e.g., pain type is chronic) calculated in the previous steps, as well as the pain site location results (e.g., pain site is left hind limb), the identified feature co-occurrence pattern (e.g., left hind limb load reduction pattern), and the compensatory behavior pattern (e.g., right hind limb load increase) and other information. Construct a structured data object that contains all key information related to pain. For example, it can be organized into a JSON object: {"pain site":"left hind limb","pain intensity":8.5,"pain type":"chronic","detection mode":"left hind limb load reduction pattern","compensatory behavior":{"limb":"right hind limb","type":"load increase"}}. This integrated data object fully describes the pain-related physiological and behavioral characteristics detected in this gait monitoring, that is, forming the final pain feature association data.
[0076] Preferably, step S38 includes: The pain status was assessed based on the pain characteristic correlation data and joint range of motion to obtain the limb function health index; Pain intensity scores were calculated based on pain feature association data and joint range of motion scores; Limb function was assessed based on the weight-bearing ratio distribution diagram, limb weight-bearing symmetry index, support time characteristic data, and joint range of motion score to obtain a limb function status score; The weight-bearing ratio distribution diagram, limb weight-bearing symmetry index, pain intensity score and limb function status score were integrated to generate the limb function health index.
[0077] In an embodiment of the present invention, the operation of evaluating the pain state according to the pain feature association data and the joint mobility score to obtain the limb function health index is: the pain feature association data (including the pain possibility rating of each limb, such as a 0-10 point system) and the joint mobility score (including the mobility score of the main joints of each limb, such as a 0-100 point system) are associated and analyzed. The pain feature association data indicates the degree and location of the pain-related gait characteristics of the livestock, and the joint mobility score directly reflects the degree of limitation of the limb's motor ability. If the pain possibility rating of a limb (such as the left hind limb) is very high (such as 8 points), and the mobility score of the joint related to the limb (such as the left hind knee joint, the left hind ankle joint) is very low (such as an average of 40 points), this strong pain sign and significant functional limitation are mutually confirmed, indicating that the degree of functional impairment caused by pain in the limb is very high. A pain impact function assessment model is constructed, which takes the pain possibility rating and the joint mobility score as input, and outputs a pain impact function score caused by pain in the limb (such as a 0-100 point system, the higher the score, the greater the impact of pain on function). The model can use a rule-based mapping table or a polynomial function: pain impact function score = f(pain likelihood rating, range of motion score). For example, the rule can be defined as: if the pain likelihood rating > 7 and the range of motion score < 50, then the pain impact function score is 80; if the pain likelihood rating < 3 and the range of motion score > 80, then the pain impact function score is 20. Applying this model to each limb, its pain impact function score is calculated, which constitutes the key indicator for assessing the pain status and serves as the input for calculating the limb functional health index in the subsequent step.
[0078] The operation of calculating the pain intensity score based on the pain feature association data and the joint range of motion score is to use the initial pain intensity score (e.g., 0-10 points) calculated from the pain feature association data as the basis, and adjust and refine it in combination with the joint range of motion score (0-100 points). The pain feature association data mainly relies on abnormal patterns of weight-bearing and time parameters, while the joint range of motion score provides evidence at the kinematic level. If the initial pain intensity score of a limb (e.g., the left hind limb) is high (e.g., 7 points), but the range of motion score of its related joint shows that the functional limitation is not severe (e.g., an average of 70 points), this suggests that the pain is not completely limiting movement or the source of pain is not the joint itself. Conversely, if the initial pain intensity score is moderate (e.g., 5 points), but the joint range of motion score is very low (e.g., an average of 30 points), this strongly suggests that there is significant functional impairment, the pain intensity is underestimated, or the nature of the pain is more focused on movement limitation. A pain intensity correction model is established, which receives the initial pain intensity score and the range of motion score of the related limb as input and outputs a corrected pain intensity score (still a 0-10 scale) that more accurately reflects the actual pain level. The model can use an adjustment factor: modified pain intensity score = initial pain intensity score × correction factor (joint range of motion score). The correction factor function can be designed as follows: when the joint range of motion score is very low, the correction factor is slightly greater than 1 (for example, 1.1), when the joint range of motion score is very high, the correction factor is slightly less than 1 (for example, 0.9), and when the joint range of motion score is moderate, the correction factor is equal to 1. The modified pain intensity score is calculated for each limb, and these scores are the pain intensity score data used for the final health assessment.
[0079] Limb function is assessed based on the weight-bearing ratio distribution diagram, limb weight-bearing symmetry index, support time characteristic data, and joint range of motion score. The operation to obtain the limb function status score is as follows: the weight-bearing ratio distribution diagram (including the average weight-bearing ratio of each limb), the limb weight-bearing symmetry index (including the weight-bearing difference rate and asymmetry index of the ipsilateral limb), the support time characteristic data (including the support time ratio of each limb and its deviation from the baseline), and the joint range of motion score. These data directly reflect the objective ability of the limb in support, movement, and load-bearing. For example, the weight-bearing ratio of the left hind limb is significantly lower than normal, the weight-bearing difference rate of the hind limb is high and the left hind limb is the unloaded side, the support time ratio of the left hind limb is significantly shortened, and the relevant joint range of motion score of the left hind limb is low, all of which point to impaired left hind limb function. A functional status score model is defined for each limb. The model is a multi-input, single-output evaluation function. The input includes the average weight-bearing ratio of the limb, the weight-bearing difference rate with the contralateral limb (if applicable), the support time ratio deviation, and the average range of motion score of the relevant joint. The model adopts a weighted summation method: limb function status score = + + + .in are preset weights that reflect the importance of each parameter to the function (e.g., joint range of motion and weight-bearing ratio have higher weights); It is a function that maps the original parameters to a 0-100 scoring range (for example, the lower the weight-bearing ratio, the lower the score; the higher the difference rate, the lower the score; the greater the deviation, the lower the score; the range of motion score is used directly). The functional status score of each limb is calculated (0-100 points, 100 is normal function), and these scores constitute the limb functional status score data.
[0080] The operation of integrating the weight-bearing ratio distribution map, the limb weight-bearing symmetry index, the pain intensity score and the limb function status score to generate the limb function health index is: the weight-bearing ratio distribution map, the limb weight-bearing symmetry index, the pain intensity score data and the limb function status score data are collected. The limb function health index aims to provide a single indicator for comprehensively measuring the health status of the limbs. It needs to consider both the objective functional status (load-bearing, exercise ability) and the subjective feeling (pain level) of the limbs. Construct a limb function health index calculation model, which takes the limb function status score and the pain intensity score as the main input, and fine-tunes the key original indicators such as weight-bearing ratio and symmetry. The model can adopt the following structure: limb function health index = g (limb function status score, pain intensity score, weight-bearing ratio, weight-bearing symmetry). The function g is designed as follows: the higher the functional status score, the higher the health index; the higher the pain intensity score, the lower the health index; a significant deviation in the weight-bearing ratio or poor symmetry will further reduce the health index. For example, the weighted combination and penalty term method is adopted: limb function health index = - - - . is the weight coefficient. The weight ratio deviation penalty can be calculated based on the deviation between the weight ratio and the normal range. The greater the deviation, the greater the penalty. The symmetry penalty can be calculated based on the weight difference rate. The higher the difference rate, the greater the penalty. Finally, the limb function health index (e.g. 0-100 points, 100 is completely healthy) of each limb (left front, right front, left back, right back) is calculated, and these indexes are combined to form the final limb function health index data. This index intuitively reflects the current health level of each limb and provides basic data for subsequent overall health trend monitoring.
[0081] Preferably, the present invention further provides a livestock physiological behavior monitoring system for executing the livestock physiological behavior monitoring method as described above, the livestock physiological behavior monitoring system comprising: The gait data acquisition module is used to collect the three-area pressure matrix through the pressure sensing pad; perform dynamic path recognition and camera adjustment according to the three-area pressure matrix to obtain dynamic path tracking data; perform livestock mechanical gait analysis according to the dynamic path tracking data to obtain a gait mechanical characteristic map; The abnormal feature recognition module is used to obtain basic information of livestock; segment individual gait time series according to the gait mechanical feature map to obtain segmented aligned gait data; perform adaptive gait threshold calculation according to the basic information of livestock and the segmented aligned gait data to obtain an individualized abnormal threshold set; perform abnormal gait pattern recognition according to the individualized abnormal threshold set to obtain a gait deviation index matrix; The pain status assessment module is used to analyze the difference in limb weight-bearing ratios based on the gait deviation index matrix and the gait mechanics characteristic map to obtain limb weight-bearing characteristics; identify weight-bearing transfer pattern characteristics based on limb weight-bearing characteristics; identify pain behavior characteristics based on weight-bearing transfer pattern characteristics to obtain pain characteristic correlation data; and conduct limb health assessment based on pain characteristic correlation data to obtain a limb function health index; The health trend monitoring module is used to monitor the behavior patterns in time according to the limb function health index to obtain the livestock health trend map.
[0082] Therefore, the embodiments should be regarded as illustrative and non-restrictive from all points, and the scope of the present invention is limited by the appended claims rather than the above description, and it is intended that all changes falling within the meaning and range of equivalent elements of the application documents are included in the present invention.
[0083] The above description is only a specific embodiment of the present invention, so that those skilled in the art can understand or implement the present invention. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present invention. Therefore, the present invention will not be limited to the embodiments shown herein, but should conform to the widest scope consistent with the principles and novel features invented herein.
Claims
1. A method for monitoring livestock physiological behavior, characterized in that: The following steps are involved: Step S1: collecting a three-area pressure matrix through a pressure sensing pad; performing dynamic path recognition and camera adjustment according to the three-area pressure matrix to obtain dynamic path tracking data; performing livestock mechanical gait analysis according to the dynamic path tracking data to obtain a gait mechanical characteristic map; Step S2: Obtaining basic livestock information; According to the gait mechanics characteristic map, the individual gait time sequence is segmented to obtain segmented aligned gait data; Adaptive gait threshold calculation is performed based on livestock basic information and segmented aligned gait data to obtain an individualized abnormal threshold set; Abnormal gait patterns are identified based on the individualized abnormal threshold set to obtain a gait deviation index matrix; Step S3: performing limb weight-bearing ratio difference analysis based on the gait deviation index matrix and the gait mechanics characteristic map to obtain limb weight-bearing characteristics; identifying weight-bearing transfer pattern characteristics based on the limb weight-bearing characteristics; and identifying pain behavior characteristics based on the weight-bearing transfer pattern characteristics to obtain pain characteristic association data; Limb health assessment is performed based on pain characteristic correlation data to obtain a limb function health index; Step S4: Conducting time-series monitoring of behavior patterns based on the limb function health index to obtain a livestock health trend graph.
2. The livestock physiological behavior monitoring method according to claim 1, characterized in that: Step S1 includes the following steps: Step S11: dividing the pressure sensing pad into three functional areas, namely, the front area, the middle area and the back area, according to the force characteristics of the livestock hoof, configuring each area with an independent pressure sensor array, and collecting the pressure matrix of the three areas through the pressure sensor array; Step S12: six high-speed cameras are set around the pressure sensing pad, and the spatial coordinates of the camera system are calibrated by a calibration plate to obtain a spatial coordinate mapping data set; Step S13: setting joint marking points of the livestock to be tested to obtain joint marking position data; Step S14: performing synchronous data acquisition triggering according to the three-region pressure matrix, the spatial coordinate mapping data set and the joint marker position data to obtain a synchronous triggering time series; Step S15: performing dynamic path identification and camera adjustment according to the three-region pressure matrix and the synchronous trigger time sequence to obtain dynamic path tracking data; Step S16: extracting ground reaction force data from the three-region pressure matrix according to the synchronous trigger time series and the dynamic path tracking data to obtain mechanical distribution time series data; Step S17: calculating a joint motion parameter set according to the spatial coordinate mapping data set, the joint marker position data and the synchronous triggering time series; Step S18: dividing the gait cycle according to the mechanical distribution time series data and the joint motion parameter set to obtain gait cycle segmentation data; Step S19: Generate a gait mechanics characteristic map based on the mechanical distribution time series data, the joint motion parameter set, the gait cycle segmentation data and the dynamic path tracking data.
3. The livestock physiological behavior monitoring method according to claim 2, characterized in that: Step S15 includes: Extract the spatiotemporal sequence data of hoof prints in the three-region pressure matrix according to the synchronous triggering time series; Calculate the path direction vector based on the time-space sequence data of hoof prints to obtain the livestock movement vector data; Calculate path prediction curve data based on livestock motion vector data and hoof print spatiotemporal sequence data; The turning point is identified based on the livestock motion vector data and the hoof print spatiotemporal sequence data to obtain the behavioral mutation mark data; The best observation angle is calculated based on the path prediction curve data and the behavior mutation mark data to obtain the camera angle optimization parameters; Collect dynamic path tracking data based on camera angle optimized parameters.
4. The livestock physiological behavior monitoring method according to claim 1, characterized in that: The individual gait timing segmentation in step S2 includes: Obtain livestock individual identification information and construct and access a historical database based on gait mechanics characteristic maps to obtain an individual historical gait record set; Calculating an individual gait baseline parameter set from an individual historical gait record set; Standardizing the current gait parameters of various parameters in the gait mechanics characteristic map to obtain standardized gait parameters; The standardized gait parameters and individual gait baseline parameter sets are segmented and aligned in time series to obtain segmented aligned gait data.
5. The livestock physiological behavior monitoring method according to claim 1, characterized in that: The adaptive gait threshold calculation in step S2 includes: Extract livestock characteristic standardized parameters based on livestock basic information and individual gait baseline parameter sets; The gait stability index is calculated based on the segmented aligned gait data to obtain the gait fluctuation characteristic spectrum; According to the gait fluctuation characteristic spectrum and the livestock characteristic standardized parameters, the parameter importance weights are allocated to obtain a parameter importance weight table; Identify individual-specific gait characteristics based on gait fluctuation characteristic spectrum; The threshold of abnormal joint angles was calculated based on the individual's unique gait characteristics; Calculate abnormal thresholds of mechanical parameters based on individual-specific gait characteristics; Calculate the abnormal threshold of time parameters according to the characteristic spectrum of gait fluctuation; The joint angle abnormal threshold, mechanical parameter abnormal threshold and time parameter abnormal threshold are integrated to obtain an individualized abnormal threshold set.
6. The livestock physiological behavior monitoring method according to claim 1, characterized in that: The abnormal gait pattern recognition in step S2 includes: According to the individualized abnormal threshold set, the segmented aligned gait data is subjected to joint angle change abnormality detection to obtain joint angle abnormality labeling data; The ground reaction force anomaly detection is performed on the segmented aligned gait data according to the individualized anomaly threshold set to obtain the abnormal marking data of mechanical parameters; The lateral movement amplitude of the segmented aligned gait data is analyzed according to the individualized abnormal threshold set to obtain the lateral movement abnormality labeling data; Perform time correlation analysis on abnormal joint angle labeling data, abnormal mechanical parameter labeling data, and abnormal lateral movement labeling data to obtain abnormal pattern time series correlation data; A gait deviation index matrix is generated based on abnormal joint angle labeling data, abnormal mechanical parameter labeling data, abnormal lateral movement labeling data and abnormal pattern time series association data.
7. The livestock physiological behavior monitoring method according to claim 1, characterized in that: Step S3 includes the following steps: Step S31: extracting limb weight-bearing data from the gait deviation index matrix and the gait mechanics characteristic map to obtain original limb weight-bearing data; Step S32: Calculating a weight ratio distribution diagram based on the original limb weight data and the weight data in the livestock basic information; Step S33: Calculate the weight difference rate between the left forelimb and the right forelimb, and between the left hind limb and the right hind limb according to the weight ratio distribution diagram, mark the weight difference rate exceeding 15% as asymmetric weight, calculate the asymmetry degree index, and finally obtain the limb weight symmetry index; Step S34: performing load-bearing time analysis according to the gait mechanics characteristic map and the limb load-bearing symmetry index to obtain support time characteristic data; Step S35: identifying the characteristics of the weight transfer pattern according to the weight ratio distribution diagram, the limb weight symmetry index and the support time characteristic data; Step S36: evaluating the joint range of motion of the gait mechanics characteristic map according to the gait deviation index matrix to obtain a joint range of motion score; Step S37: performing pain behavior feature recognition according to the weight-bearing ratio distribution diagram, the limb weight-bearing symmetry index, the support time characteristic data, and the weight-bearing transfer pattern characteristics to obtain pain feature association data; Step S38: Perform limb health assessment based on pain feature association data to obtain a limb function health index.
8. The livestock physiological behavior monitoring method according to claim 7, characterized in that: Step S37 includes: Standardized pain feature vectors were extracted based on the weight-bearing ratio distribution diagram, limb weight-bearing symmetry index, support time characteristic data, and weight-bearing transfer pattern characteristics; Obtain livestock breed reference data and determine feature thresholds based on standardized pain feature vectors to obtain a pain feature active state table; Perform feature co-occurrence pattern analysis based on the pain feature active state table to obtain feature co-occurrence pattern data; Perform pain location analysis based on feature co-occurrence pattern data to obtain a pain location map; Compensatory behavior identification is performed based on feature co-occurrence pattern data to obtain compensatory behavior pattern data; Differentiate acute and chronic pain patterns based on feature co-occurrence pattern data and compensatory behavior pattern data to obtain pain type determination data; The pain intensity score data were calculated based on the feature co-occurrence pattern data and pain location localization; Pain feature association data were calculated based on pain intensity score data and pain type determination data.
9. The livestock physiological behavior monitoring method according to claim 7, characterized in that: Step S38 includes: The pain status was assessed based on the pain characteristic correlation data and joint range of motion to obtain the limb function health index; Pain intensity scores were calculated based on pain feature association data and joint range of motion scores; Limb function was assessed based on the weight-bearing ratio distribution diagram, limb weight-bearing symmetry index, support time characteristic data, and joint range of motion score to obtain a limb function status score; The weight-bearing ratio distribution diagram, limb weight-bearing symmetry index, pain intensity score and limb function status score were integrated to generate the limb function health index.
10. A livestock physiological behavior monitoring system, characterized in that: Used to perform the livestock physiological behavior monitoring method as claimed in claim 1, the livestock physiological behavior monitoring system comprises: The gait data acquisition module is used to collect the three-area pressure matrix through the pressure sensing pad; perform dynamic path recognition and camera adjustment according to the three-area pressure matrix to obtain dynamic path tracking data; perform livestock mechanical gait analysis according to the dynamic path tracking data to obtain a gait mechanical characteristic map; The abnormal feature recognition module is used to obtain basic information of livestock; segment individual gait time series according to the gait mechanical feature map to obtain segmented aligned gait data; perform adaptive gait threshold calculation according to the basic information of livestock and the segmented aligned gait data to obtain an individualized abnormal threshold set; perform abnormal gait pattern recognition according to the individualized abnormal threshold set to obtain a gait deviation index matrix; The pain status assessment module is used to analyze the difference in limb weight-bearing ratios based on the gait deviation index matrix and the gait mechanics characteristic map to obtain limb weight-bearing characteristics; identify weight-bearing transfer pattern characteristics based on limb weight-bearing characteristics; identify pain behavior characteristics based on weight-bearing transfer pattern characteristics to obtain pain characteristic correlation data; and conduct limb health assessment based on pain characteristic correlation data to obtain a limb function health index; The health trend monitoring module is used to monitor the behavior patterns in time according to the limb function health index to obtain the livestock health trend map.
Citation Information
Patent Citations
Intelligent system for monitoring safety of children and gait health
CN108683724A
Rehabilitation stage all-weather monitoring equipment
CN114831598A
Livestock quarantine method based on dynamic traceability
CN118448062A
Animal husbandry statistical monitoring system
CN118627909A
Livestock disease prevention and control monitoring and early warning system based on Internet of Things
CN119905255A
Cited By
Biological sample image processing method and device based on image recognition model
CN121599969A
Image processing method and apparatus for biological samples based on image recognition model
CN121599969B