A Method for Identifying Anomalies in Livestock and Poultry Behavioral Patterns Based on Distribution Estimation Algorithms and Residual Networks
By combining the distribution estimation algorithm with the residual network, the robustness and dynamic adaptability problems of multimodal data fusion and behavioral anomaly identification in the existing technology are solved, and efficient and precise anomaly identification and early warning of livestock and poultry behavior are realized.
Patent Information
- Application Number
- CN202510550794.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-29
- Publication Date
- 2025-10-28
- Estimated Expiration
- 2045-04-29
AI Technical Summary
Existing livestock and poultry behavior recognition technologies suffer from insufficient robustness and poor dynamic adaptability when faced with complex behavioral patterns, environmental noise interference, multimodal data fusion, and precise identification of behavioral anomalies. They are unable to effectively identify low-frequency, sudden abnormal behaviors and lack timely and continuous analysis of multimodal data.
A method based on distribution estimation algorithm and residual network is adopted to construct a probability distribution model of livestock and poultry behavior by fusing multi-source data. The residual neural network is then used for multi-layer operation to extract deep anomaly features, perform behavior classification and trajectory aggregation, and realize anomaly level classification.
It improves the ability to capture the collaborative change patterns of multimodal data, has the ability to predict anomalies, enhances the accuracy and response speed of low-frequency abnormal behavior identification, and strengthens the ability to identify rare anomalies.
Smart Images

Figure CN120472533B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of livestock and poultry technology, and in particular to a method for identifying abnormal behavior patterns in livestock and poultry based on a distribution estimation algorithm and a residual network. Background Technology
[0002] With the widespread application of IoT and AI technologies in agriculture, livestock and poultry behavior recognition, as an important component of smart farming, has become a crucial means to improve farming efficiency, provide early warning of disease transmission, and safeguard animal welfare. Currently, most mainstream livestock and poultry behavior recognition technologies rely on single-modal methods such as video image analysis, motion sensor data acquisition, or audio signal processing for behavior detection and analysis. Although they have initially achieved the recognition of some key behaviors, significant technical bottlenecks still exist when facing the complexity of behavioral patterns, environmental noise interference, multimodal data fusion, and the problem of fine-grained judgment of behavioral anomalies.
[0003] Existing technologies suffer from the following main shortcomings: First, most behavior recognition methods rely on single-source data such as images or acceleration, lacking the ability to jointly model auxiliary information from infrared thermal imaging or audio data. This results in recognition results being highly sensitive to the quality of individual modal data and lacking robustness. Second, in terms of abnormal behavior detection, a large number of studies still rely on static threshold judgment or simple classification based on fixed feature sets, which cannot dynamically adapt to statistical biases in the process of behavior evolution. This is especially true when identifying low-frequency, sudden abnormal behaviors in the early stages. Furthermore, the existing systems have limited means to handle the issues of time synchronization, scale differences, and information redundancy of multimodal data, which often prevents behavior modeling from truly reflecting spatiotemporal changes and results in behavior judgments that lack timeliness and continuity.
[0004] In terms of processing the recognition results, existing technologies mainly rely on binary label output, lacking a hierarchical classification mechanism for the degree of abnormal behavior, making it difficult to support subsequent graded response and intelligent intervention decisions. In terms of spatial information application, most current studies only use location labels for simple behavior clustering or heat map display, and have not yet formed the ability to reason about trajectories linked to time and behavior type, which limits the in-depth exploration of the mechanism of abnormal behavior.
[0005] In summary, current technologies for identifying abnormal behavior patterns in livestock and poultry have significant shortcomings in terms of modal fusion capabilities, accuracy in characterizing abnormal patterns, dynamic discrimination mechanisms, and trajectory analysis capabilities. There is an urgent need for a new identification method that can integrate multi-source data, model behavioral evolution probabilities, and possess dynamic discrimination and trajectory backtracking capabilities, in order to better adapt to the needs of refined monitoring of livestock and poultry health status and behavior patterns in modern intelligent farming environments. Summary of the Invention
[0006] One objective of this invention is to propose a method for identifying abnormal behavior patterns in livestock and poultry based on a distribution estimation algorithm and a residual network. This invention can capture the collaborative change patterns between multimodal data, enabling the model to detect significant probability deviations in the early stages of stress or the early stages of sudden anomalies, thereby providing a stronger forward-looking anomaly warning capability.
[0007] A method for identifying abnormal behavior patterns in livestock and poultry based on a distribution estimation algorithm and a residual network, according to an embodiment of the present invention, includes the following steps:
[0008] S1. In the livestock and poultry breeding environment, acquire multi-source raw datasets of livestock and poultry behavior covering individual and group behaviors in real time, and perform preprocessing to obtain a unified structured dataset of livestock and poultry behavior with consistent structure.
[0009] S2. Extract a set of statistical feature vectors based on a unified structure dataset of livestock and poultry behavior, and use a distribution estimation algorithm to train the set of statistical feature vectors to construct a probability distribution model of livestock and poultry behavior and save the model parameters;
[0010] S3. During the target monitoring period, input the real-time updated data of the unified structure dataset of livestock and poultry behavior into the probability distribution model of livestock and poultry behavior, calculate the probability difference score of each data point relative to the model, and generate a behavior probability difference score matrix.
[0011] S4. Construct a residual neural network model and complete the initialization of model parameters. Use the behavior probability difference scoring matrix as the input data of the residual neural network model and perform multi-layer residual operations to obtain deep anomaly feature vectors.
[0012] S5. Classify behavior based on deep anomaly feature vectors, output behavior anomaly judgment results, and label each livestock and poultry behavior data with normal behavior markers or abnormal behavior markers. Combine the behavior anomaly judgment results with the corresponding timestamp information, perform time series backtracking analysis and spatial location mapping, generate behavior trajectory aggregation results, and classify the anomaly level by combining the behavior anomaly judgment results and the behavior trajectory aggregation results according to preset rules.
[0013] Optionally, S1 includes the following steps:
[0014] S11. In the livestock and poultry farming environment, acquire multi-source raw data on livestock and poultry behavior, and construct a multi-source raw dataset of livestock and poultry behavior. Each data item in the multi-source raw dataset of livestock and poultry behavior consists of five parts, namely: collection timestamp t i Image frame data I i Infrared thermal imaging data M i Motion acceleration data A i and audio feature vector V i Image frame data I iThe infrared thermal imaging data M is a three-dimensional tensor structure, represented as an image consisting of height, width, and channel dimensions. i Record temperature distribution information; motion acceleration data A i The audio feature vector V represents the acceleration of an object along each axis. i The audio signal features are represented by frequency and amplitude. The multi-source raw dataset of livestock and poultry behavior contains N livestock and poultry behavior data items.
[0015] S12. Perform data defect removal processing on the multi-source raw dataset of livestock and poultry behavior, filtering out data items containing missing image frames, time discontinuities, missing values, or outliers, retaining only valid data items that meet the integrity and legality constraints, and standardizing the size of all image frame data to the specified standard size H0×W0, and standardizing the dimension of audio feature vectors to a fixed length L. v And the motion acceleration data are sampled at a uniform sampling rate f A Resampling is performed, and a baseline timeline T is established based on the acquisition timestamps. All modal data are aligned to a uniform time scale. The baseline timeline contains K time steps, and each time step corresponds to a timestamp t. k At each time step, data from different modalities are synchronously aggregated to generate a time-aligned multimodal data sequence set;
[0016] S13. Perform noise filtering on the time-aligned multimodal data sequence set, apply an edge enhancement algorithm to the image frame data to improve image clarity, apply a sliding window filter to the audio feature vector to eliminate high-frequency disturbances, and perform median filtering on the motion acceleration data to smooth abrupt signals, thereby obtaining the noise-suppressed image frame data I′. k Infrared thermal imaging data M′ k Motion acceleration data A′ k With audio feature vector V′ k We obtained a unified structured dataset D of livestock and poultry behavior with consistent structure. final .
[0017] Optionally, S2 includes the following steps:
[0018] S21. Based on the unified structure dataset of livestock and poultry behavior D final From image frame data I′ k Infrared thermal imaging data M′ k Motion acceleration data A′ k With audio feature vector V′ k Extract modal sensing statistical features and construct a modal sensing statistical feature vector f. k ;
[0019] S22. Set the modality-sensing statistical feature vectors The improved conditional distribution estimation algorithm module is input, and the coupling relationship between time context dependency and modal mutual information is introduced in the modeling process of the improved conditional distribution estimation algorithm module to construct a conditional probability density model P(f) oriented towards behavioral evolution. k |f k-1 ):
[0020]
[0021] Among them, f k-1 Let I(f) be the modal sensing statistical feature vector for continuous time steps k-1. k ) represents the information redundancy measure between different modalities, calculated based on the mutual information criterion, reflecting the degree of coordinated change between image, temperature, action and audio. α and β are control parameters that measure the importance of behavioral continuity and modal coupling, respectively, and Z is the normalization factor.
[0022] S23. By maximizing the training samples in the conditional probability density model P(f) k |f k-1 Log-likelihood under () is used to obtain the optimal parameter set Θ of the model. cde .
[0023] Optionally, the modality-sensing statistical feature vector f k Includes behavioral descriptions and trend measures for each modality at the current time step, including the average brightness μ of the image frames. I,k Image frame brightness standard deviation σ I,k The rate of change of brightness between image frames ΔI k ;
[0024] Brightness change rate ΔI k It indicates the degree of frame difference between the current frame and the previous frame, and is used to describe the intensity of behavior at the image level.
[0025] Features extracted from infrared thermal imaging data include the mean temperature μ M,k Temperature standard deviation σ M,k and the amplitude of sudden change in body temperature ΔM k Among them, the amplitude of body temperature change ΔM k It represents the absolute difference between the mean body temperature at the current time step and the mean body temperature at the previous time step, and is used to reflect abnormal behavioral signals such as stress, disease, or local overheating;
[0026] Features extracted from motion acceleration data include the mean acceleration μ A,k σ of acceleration A,k and motion variability ΔA k Among them, the motion variability ΔA kIt represents the Euclidean distance between the acceleration vector at the current time step and the acceleration vector at the previous time step, reflecting the degree of abrupt changes in livestock and poultry movement and gait instability.
[0027] The features extracted from the audio feature vector include the mean audio frequency μ. V,k Audio energy standard deviation σ V,k and the amplitude of sound change ΔV k The amplitude of sound change ΔV k It represents the absolute difference between the current average audio frequency and the average audio frequency at the previous time step, and is used to identify abnormal audio behaviors such as sudden changes in vocalizations, calls for help, and screams.
[0028] Optionally, S3 includes the following steps:
[0029] S31. During the target monitoring period, collect the current time step t. k Unified structure data item d of livestock and poultry behavior k Generate modal-aware statistical feature vector f k The modality-sensing statistical feature vector f k Modal sensing statistical feature vector f from the previous time step k-1 Input conditional probability density model P(f k |f k-1 ), calculate the log-likelihood score of the current behavior:
[0030]
[0031] in, The log-likelihood score represents the behavior, and α, β, and Z are the behavior continuity regulation parameter, modal coupling regulation parameter, and normalization factor determined during model training, respectively.
[0032] S32. Utilize the average of the behavioral log-likelihood scores obtained during the training phase. with standard deviation Using this as a baseline, calculate the current time step t. k Behavioral probability difference score S k Behavioral probability difference score S k The behavior probability difference score S indicates the degree of deviation of the current behavior from the distribution model. k It is obtained by dividing the difference between the current behavior log-likelihood score and the baseline mean by the score standard deviation, and is used to quantify the degree to which the current behavior deviates from the normal pattern;
[0033] S33. In the sliding window W containing the current time step k ={S k-w+1 ,...,S k On}, calculate the local average of the window rating sequence. Standard deviation σW skewness γ W With kurtosis κ W Define a dynamic behavior anomaly threshold, τ. k It is composed of a linear combination of local mean score, standard deviation, skewness and kurtosis;
[0034] S34. Set the current time step t k Behavioral probability difference score S k With dynamic behavior anomaly threshold τ k Comparison, if the behavioral probability difference score S k Exceeding the threshold τ k Then the current time step t k The behaviors are marked as anomalous behaviors, and the set of all time steps marked as anomalous behaviors constitutes the initial anomalous behavior mark set A. init ;
[0035] S35. Initial abnormal behavior label set A init Density clustering analysis is performed on the modal sensing statistical feature vectors corresponding to the abnormal behaviors. Based on the similarity of their modal sensing features, the abnormal behaviors are divided into multiple abnormal behavior clusters, forming a cluster set C. Each cluster c in the cluster set... j Characterizes an anomaly category with similar behavioral change patterns;
[0036] S36. If any anomalous behavior cluster c j The number of anomalous behaviors included exceeds the preset clustering threshold θ group If this occurs, the global scoring threshold reduction mechanism will be triggered, which will lower the current dynamic behavior anomaly threshold τ. k By comparing the weighted combination of local average scores and skewness, a new lower limit for the global score threshold is obtained.
[0037] S37. Output a behavior probability difference rating matrix S containing the following three pieces of information. final Score of behavioral probability difference at each time step k Global score threshold adjusted by clustering feedback And the ClusterID, the cluster identifier to which this time step belongs in the anomalous behavior clustering analysis. k .
[0038] Optionally, S4 further includes the following enhancement steps:
[0039] S41. Embed a multi-scale temporal perception module into the residual neural network model to evaluate the input behavior probability difference scoring matrix S. final Perform multi-scale convolution processing to construct a scale set. Scale set for each scale R (s) This represents the residual representation extracted under the condition that the receptive field of the convolution kernel is s;
[0040] S42. Express the residuals at each scale as R (s) The input behavior attention guidance module generates the corresponding behavior attention weight α. (s) :
[0041]
[0042] in, C represents the residual at time step k at scale s. k W is the original behavioral rating feature. r W c w and b are the training parameters in the attention mechanism. Let be the behavioral attention weights at the s-th scale and the k-th time step;
[0043] S43. Weighted fusion of residual representations across all scales with behavioral attention weights generates cross-scale residual fusion feature representations. Used to characterize the dynamic properties of abnormal livestock and poultry behavior at different granularities;
[0044] S44. Introduce an anomaly sparsity awareness module and introduce an anomaly reconstruction loss function during the training phase. Optimize the residual neural network model's ability to detect rare anomalies:
[0045]
[0046] Among them, z k Let be the depth anomaly feature vector at time step k. To reconstruct the target vector, Let z be a flag function indicating whether the k-th time step is an anomaly. k ||1 represents the sparsity regularization term for anomalous features, λ s This is the sparsity adjustment coefficient;
[0047] S45. The output of the residual network, which incorporates the behavioral attention guidance module, cross-scale residual fusion features, and anomaly sparse perception module, is used as the final anomaly discrimination input to form an enhanced deep anomaly feature sequence Z. enhanced .
[0048] Optionally, S5 includes the following steps:
[0049] S51. Enhanced deep anomaly feature sequence The input behavior classification and discrimination module uses a soft classification method to calculate the value of each time step t. k Corresponding probability of abnormal behavior
[0050]
[0051] in, W is the deep anomaly feature vector extracted by the residual neural network model at the k-th time step, containing a multimodal behavioral fusion representation of livestock and poultry at the current moment. o This is a classification weight vector used to classify deep anomaly feature vectors. Mapped to scalar space, b o The term is the bias term, and exp(·) is the natural exponential function. Together with 1+exp(·) in the denominator, they form a logical function.
[0052] S52. Set the classification threshold θ based on the probability of abnormal behavior. p When the probability of abnormal behavior At that time, the time step is marked as abnormal behavior, and an abnormal behavior mark set A is generated. flag All unmarked time steps will default to normal behavior.
[0053] S53. Combine each abnormal time step t k ∈A flag The data collection timestamps and original spatial location information of individual or group livestock and poultry are used to perform time series backtracking analysis, construct the behavioral evolution trajectory of individual or group livestock and poultry within a certain time window before and after the occurrence of an anomaly, and form a set of abnormal behavior trajectories.
[0054] S54. Based on the set of abnormal behavior trajectories and the spatial location data L corresponding to each abnormal behavior time step k We construct a spatial location mapping set and perform statistical analysis on the spatial density of anomalies to reveal the spatiotemporal clustering characteristics of anomalous behavior.
[0055] S55. Integrate the abnormal behavior determination results with the abnormal behavior trajectory set, and classify the abnormal behavior at each time step according to the preset abnormal level classification rules.
[0056] Optionally, the anomaly level classification rules refer to the following standards:
[0057] Level 1 anomaly: Probability of abnormal behavior The corresponding trajectory range shows ≥3 consecutive anomalies, and the anomaly points form a high-density cluster in space, with ≥5 anomaly points occurring in a local area within 5 minutes;
[0058] Level 2 anomaly: Probability of abnormal behavior There are 2 to 3 anomalies within the trajectory range, and their spatial distribution is either locally concentrated or appears periodically;
[0059] Level 3 Abnormality: Probability of Abnormal Behavior The trajectory shows a single outlier or a random distribution, without forming a clustered feature.
[0060] The beneficial effects of this invention are:
[0061] (1) This invention introduces an improved conditional distribution estimation algorithm that integrates temporal context and modal mutual information coupling mechanism to construct a conditional probability density model for behavioral evolution, which significantly enhances the model’s ability to characterize the continuity of behavioral evolution. By introducing behavioral continuity control parameters and modal coupling control parameters in conditional distribution modeling, it is possible to capture the collaborative change patterns between multimodal data, so that the model can detect significant probability deviations in the early stage of stress or in the early stage of sudden anomalies, thus having a stronger forward-looking anomaly warning capability.
[0062] (2) The present invention designs a multi-scale behavior perception residual neural network structure, embedding a multi-scale temporal perception module and a behavior attention guidance mechanism in the residual network, which can effectively model the performance differences of livestock and poultry behavior at different time granularities. The residual signals of behavior under different receptive fields are extracted by multi-scale convolution, and the weights of residual features at each scale are adaptively adjusted by the attention mechanism, so that the model can maintain high stability and sensitivity when facing behavior patterns that are frequently switched or superimposed with interference.
[0063] (3) This invention further proposes an abnormal sparsity perception enhancement mechanism. By introducing sparsity constraints and abnormal reconstruction loss functions during the training process, the model’s ability to identify rare abnormal behaviors of livestock and poultry is improved. Existing livestock and poultry behavior recognition models generally tend to learn high-frequency behavior patterns, resulting in low detection accuracy of low-frequency behaviors. Based on the residual feature sequence, a behavior abnormality probability output and behavior trajectory clustering feedback mechanism are constructed. Combined with the reconstruction error of abnormal behavior and sparsity adjustment, fine modeling of weak signals and highly variable behaviors is achieved, which effectively alleviates the problem of sample imbalance. Attached Figure Description
[0064] The accompanying drawings are used to provide a further understanding of the present invention and constitute a part of the specification. Together with the embodiments of the present invention, they are used to explain the present invention and do not constitute a limitation of the present invention. In the accompanying drawings:
[0065] Figure 1 This is a flowchart of a method for identifying abnormal behavior patterns in livestock and poultry based on a distribution estimation algorithm and a residual network, as proposed in this invention. Detailed Implementation
[0066] The present invention will now be described in further detail with reference to the accompanying drawings. These drawings are simplified schematic diagrams, illustrating only the basic structure of the invention, and therefore only show the components relevant to the invention.
[0067] refer to Figure 1 A method for identifying abnormal behavior patterns in livestock and poultry based on distribution estimation algorithms and residual networks includes the following steps:
[0068] S1. In the livestock and poultry breeding environment, acquire multi-source raw datasets of livestock and poultry behavior covering individual and group behaviors in real time, and perform preprocessing to obtain a unified structured dataset of livestock and poultry behavior with consistent structure.
[0069] S2. Extract a set of statistical feature vectors based on a unified structure dataset of livestock and poultry behavior, and use a distribution estimation algorithm to train the set of statistical feature vectors to construct a probability distribution model of livestock and poultry behavior and save the model parameters;
[0070] S3. During the target monitoring period, input the real-time updated data of the unified structure dataset of livestock and poultry behavior into the probability distribution model of livestock and poultry behavior, calculate the probability difference score of each data point relative to the model, and generate a behavior probability difference score matrix.
[0071] S4. Construct a residual neural network model and complete the initialization of model parameters. Use the behavior probability difference scoring matrix as the input data of the residual neural network model and perform multi-layer residual operations to obtain deep anomaly feature vectors.
[0072] S5. Classify behavior based on deep anomaly feature vectors, output behavior anomaly judgment results, and label each livestock and poultry behavior data with normal behavior markers or abnormal behavior markers. Combine the behavior anomaly judgment results with the corresponding timestamp information, perform time series backtracking analysis and spatial location mapping, generate behavior trajectory aggregation results, and classify the anomaly level by combining the behavior anomaly judgment results and the behavior trajectory aggregation results according to preset rules.
[0073] In this embodiment, S1 includes the following steps:
[0074] S11. In the livestock and poultry farming environment, acquire multi-source raw data on livestock and poultry behavior, and construct a multi-source raw dataset of livestock and poultry behavior. Each data item in the multi-source raw dataset of livestock and poultry behavior consists of five parts, namely: collection timestamp t i Image frame data I i Infrared thermal imaging data M i Motion acceleration data A i and audio feature vector V i Image frame data I i The infrared thermal imaging data M is a three-dimensional tensor structure, represented as an image consisting of height, width, and channel dimensions. i Record temperature distribution information; motion acceleration data A i The audio feature vector V represents the acceleration of an object along each axis. iThe audio signal features are represented by frequency and amplitude. The multi-source raw dataset of livestock and poultry behavior contains N livestock and poultry behavior data items.
[0075] S12. Perform data defect removal processing on the multi-source raw dataset of livestock and poultry behavior, filtering out data items containing missing image frames, time discontinuities, missing values, or outliers, retaining only valid data items that meet the integrity and legality constraints, and standardizing the size of all image frame data to the specified standard size H0×W0, and standardizing the dimension of audio feature vectors to a fixed length L. v And the motion acceleration data are sampled at a uniform sampling rate f A Resampling is performed, and a baseline timeline T is established based on the acquisition timestamps. All modal data are aligned to a uniform time scale. The baseline timeline contains K time steps, and each time step corresponds to a timestamp t. k At each time step, data from different modalities are synchronously aggregated to generate a time-aligned multimodal data sequence set;
[0076] S13. Perform noise filtering on the time-aligned multimodal data sequence set, apply an edge enhancement algorithm to the image frame data to improve image clarity, apply a sliding window filter to the audio feature vector to eliminate high-frequency disturbances, and perform median filtering on the motion acceleration data to smooth abrupt signals, thereby obtaining the noise-suppressed image frame data I′. k Infrared thermal imaging data M′ k Motion acceleration data A′ k With audio feature vector V′ k We obtained a unified structured dataset D of livestock and poultry behavior with consistent structure. final .
[0077] In this embodiment, S2 includes the following steps:
[0078] S21. Based on the unified structure dataset of livestock and poultry behavior D final From image frame data I′ k Infrared thermal imaging data M′ k Motion acceleration data A′ k With audio feature vector V′ k Extract modal sensing statistical features and construct a modal sensing statistical feature vector f. k ;
[0079] S22. Set the modality-sensing statistical feature vectors The improved conditional distribution estimation algorithm module is input, and the coupling relationship between time context dependency and modal mutual information is introduced in the modeling process of the improved conditional distribution estimation algorithm module to construct a conditional probability density model P(f) oriented towards behavioral evolution. k |f k-1 ):
[0080]
[0081] Among them, f k-1 Let I(f) be the modal sensing statistical feature vector for continuous time steps k-1. k ) represents the information redundancy measure between different modalities, calculated based on the mutual information criterion, reflecting the degree of coordinated change between image, temperature, action and audio. α and β are control parameters that measure the importance of behavioral continuity and modal coupling, respectively, and Z is the normalization factor.
[0082] S23. By maximizing the training samples in the conditional probability density model P(f) k |f k-1 Log-likelihood under () is used to obtain the optimal parameter set Θ of the model. cde .
[0083] In this embodiment, the modality-sensing statistical feature vector f k Includes behavioral descriptions and trend measures for each modality at the current time step, including the average brightness μ of the image frames. I,k Image frame brightness standard deviation σ I,k The rate of change of brightness between image frames ΔI k ;
[0084] Brightness change rate ΔI k It indicates the degree of frame difference between the current frame and the previous frame, and is used to describe the intensity of behavior at the image level.
[0085] Features extracted from infrared thermal imaging data include the mean temperature μ M,k Temperature standard deviation σ M,k and the amplitude of sudden change in body temperature ΔM k Among them, the amplitude of body temperature change ΔM k It represents the absolute difference between the mean body temperature at the current time step and the mean body temperature at the previous time step, and is used to reflect abnormal behavioral signals such as stress, disease, or local overheating;
[0086] Features extracted from motion acceleration data include the mean acceleration μ A,k σ of acceleration A,k and motion variability ΔA k Among them, the motion variability ΔA k It represents the Euclidean distance between the acceleration vector at the current time step and the acceleration vector at the previous time step, reflecting the degree of abrupt changes in livestock and poultry movement and gait instability.
[0087] The features extracted from the audio feature vector include the mean audio frequency μ. V,k Audio energy standard deviation σ V,kand the amplitude of sound change ΔV k The amplitude of sound change ΔV k It represents the absolute difference between the current average audio frequency and the average audio frequency at the previous time step, and is used to identify abnormal audio behaviors such as sudden changes in vocalizations, calls for help, and screams.
[0088] In this embodiment, S3 includes the following steps:
[0089] S31. During the target monitoring period, collect the current time step t. k Unified structure data item d of livestock and poultry behavior k Generate modal-aware statistical feature vector f k The modality-sensing statistical feature vector f k Modal sensing statistical feature vector f from the previous time step k-1 Input conditional probability density model P(f k |f k-1 ), calculate the log-likelihood score of the current behavior:
[0090]
[0091] in, The log-likelihood score represents the behavior, and α, β, and Z are the behavior continuity regulation parameter, modal coupling regulation parameter, and normalization factor determined during model training, respectively.
[0092] S32. Utilize the average of the behavioral log-likelihood scores obtained during the training phase. with standard deviation Using this as a baseline, calculate the current time step t. k Behavioral probability difference score S k Behavioral probability difference score S k The behavior probability difference score S indicates the degree of deviation of the current behavior from the distribution model. k It is obtained by dividing the difference between the current behavior log-likelihood score and the baseline mean by the score standard deviation, and is used to quantify the degree to which the current behavior deviates from the normal pattern;
[0093] S33. In the sliding window W containing the current time step k ={S k-w+1 ,...,S k On}, calculate the local average of the window rating sequence. Standard deviation σ W skewness γ W With kurtosis κ W Define a dynamic behavior anomaly threshold, τ. k It is composed of a linear combination of local mean score, standard deviation, skewness and kurtosis;
[0094] S34. Set the current time step t k Behavioral probability difference score S k With dynamic behavior anomaly threshold τ k Comparison, if the behavioral probability difference score S k Exceeding the threshold τ k Then the current time step t k The behaviors are marked as anomalous behaviors, and the set of all time steps marked as anomalous behaviors constitutes the initial anomalous behavior mark set A. init ;
[0095] S35. Initial abnormal behavior label set A init Density clustering analysis is performed on the modal sensing statistical feature vectors corresponding to the abnormal behaviors. Based on the similarity of their modal sensing features, the abnormal behaviors are divided into multiple abnormal behavior clusters, forming a cluster set C. Each cluster c in the cluster set... j Characterizes an anomaly category with similar behavioral change patterns;
[0096] S36. If any anomalous behavior cluster c j The number of anomalous behaviors included exceeds the preset clustering threshold θ group If this occurs, the global scoring threshold reduction mechanism will be triggered, which will lower the current dynamic behavior anomaly threshold τ. k By comparing the weighted combination of local average scores and skewness, a new lower limit for the global score threshold is obtained.
[0097] S37. Output a behavior probability difference rating matrix S containing the following three pieces of information. final Score of behavioral probability difference at each time step k Global score threshold adjusted by clustering feedback And the ClusterID, the cluster identifier to which this time step belongs in the anomalous behavior clustering analysis. k .
[0098] In this embodiment, S4 further includes the following enhancement steps:
[0099] S41. Embed a multi-scale temporal perception module into the residual neural network model to evaluate the input behavior probability difference scoring matrix S. final Perform multi-scale convolution processing to construct a scale set. Scale set for each scale R (s) This represents the residual representation extracted under the condition that the receptive field of the convolution kernel is s;
[0100] S42. Express the residuals at each scale as R (s) The input behavior attention guidance module generates the corresponding behavior attention weight α.(s) :
[0101]
[0102] in, C represents the residual at time step k at scale s. k W is the original behavioral rating feature. r W c w and b are the training parameters in the attention mechanism. Let be the behavioral attention weights at the s-th scale and the k-th time step;
[0103] S43. Weighted fusion of residual representations across all scales with behavioral attention weights generates cross-scale residual fusion feature representations. Used to characterize the dynamic properties of abnormal livestock and poultry behavior at different granularities;
[0104] S44. Introduce an anomaly sparsity awareness module and introduce an anomaly reconstruction loss function during the training phase. Optimize the residual neural network model's ability to detect rare anomalies:
[0105]
[0106] Among them, z k Let be the depth anomaly feature vector at time step k. To reconstruct the target vector, Let z be a flag function indicating whether the k-th time step is an anomaly. k ||1 represents the sparsity regularization term for anomalous features, λ s This is the sparsity adjustment coefficient;
[0107] S45. The output of the residual network, which incorporates the behavioral attention guidance module, cross-scale residual fusion features, and anomaly sparse perception module, is used as the final anomaly discrimination input to form an enhanced deep anomaly feature sequence Z. enhanced .
[0108] In this embodiment, S5 includes the following steps:
[0109] S51. Enhanced deep anomaly feature sequence The input behavior classification and discrimination module uses a soft classification method to calculate the value of each time step t. k Corresponding probability of abnormal behavior
[0110]
[0111] in, W is the deep anomaly feature vector extracted by the residual neural network model at the k-th time step, containing a multimodal behavioral fusion representation of livestock and poultry at the current moment. o This is a classification weight vector used to classify deep anomaly feature vectors. Mapped to scalar space, b o The term is the bias term, and exp(·) is the natural exponential function. Together with 1+exp(·) in the denominator, they form a logical function.
[0112] S52. Set the classification threshold θ based on the probability of abnormal behavior. p When the probability of abnormal behavior At that time, the time step is marked as abnormal behavior, and an abnormal behavior mark set A is generated. flag All unmarked time steps will default to normal behavior.
[0113] S53. Combine each abnormal time step t k ∈A flag The data collection timestamps and original spatial location information of individual or group livestock and poultry are used to perform time series backtracking analysis, construct the behavioral evolution trajectory of individual or group livestock and poultry within a certain time window before and after the occurrence of an anomaly, and form a set of abnormal behavior trajectories.
[0114] S54. Based on the set of abnormal behavior trajectories and the spatial location data L corresponding to each abnormal behavior time step k We construct a spatial location mapping set and perform statistical analysis on the spatial density of anomalies to reveal the spatiotemporal clustering characteristics of anomalous behavior.
[0115] S55. Integrate the abnormal behavior determination results with the abnormal behavior trajectory set, and classify the abnormal behavior at each time step according to the preset abnormal level classification rules.
[0116] In this implementation, the anomaly level classification rules refer to the following standards:
[0117] Level 1 anomaly: Probability of abnormal behavior The corresponding trajectory range shows ≥3 consecutive anomalies, and the anomaly points form a high-density cluster in space, with ≥5 anomaly points occurring in a local area within 5 minutes;
[0118] Level 2 anomaly: Probability of abnormal behavior There are 2 to 3 anomalies within the trajectory range, and their spatial distribution is either locally concentrated or appears periodically;
[0119] Level 3 Abnormality: Probability of Abnormal Behavior The trajectory shows a single outlier or a random distribution, without forming a clustered feature.
[0120] Example 1:
[0121] In November 2024, a large broiler chicken farm in City A began deploying an intelligent identification system based on this invention during the peak disease season of autumn. The farm raises more than 130,000 broilers daily and adopts a three-dimensional cage structure. 24-hour video monitoring and infrared thermal imaging equipment are already widely used. However, in daily operation and maintenance, the following problems are still frequently encountered: delayed response to abnormal behavior, missed detection of low-frequency events, and failure to effectively warn of the early stage of disease transmission. Traditional methods based on image processing and fixed threshold classification have an accuracy and recall rate of less than 65%, and the cost of manual intervention remains high.
[0122] The system described in this invention began a 14-day behavioral pattern monitoring experiment on the A3 incubation workshop on the day of deployment. A total of 12 multimodal acquisition nodes were deployed in the workshop. Each node collected image frames, infrared thermal imaging data, motion acceleration and audio features. About 430,000 complete data records were collected every day. After system preprocessing, a unified structure dataset was constructed and the time axis was synchronized to form a high-quality multimodal input sequence.
[0123] In the preliminary experimental phase, the research team introduced historical data from September (a total of approximately 240 hours of behavioral records) as training samples for the model. This included approximately 4,200 records of 93 categories of confirmed abnormal behaviors such as "anxious gathering," "movement shaking," and "continuous low-frequency barking." These records were used to jointly train the conditional probability density model and residual neural network model in this invention. During the modeling process, feature vectors were extracted from each time step of data using a distribution estimation algorithm. A behavioral evolution model based on temporal context and modal mutual information was constructed to fit the distribution of normal behavior. In the model evaluation phase, the recognition accuracy on the training set reached 94.8%, and the accuracy on the validation set reached 91.3%, significantly better than the baseline Gaussian mixture model's 87.2% and 85.6% under the same conditions.
[0124] At 3:26 AM on the fourth day of its official operation, the system automatically identified for the first time a group of broilers in the northeast area of Building A3 exhibiting sudden changes in vocalization frequency, localized temperature increases, and drastic changes in image frames within 6 minutes. Furthermore, the corresponding behavioral scores exceeded the dynamic threshold for 5 consecutive time steps. After cluster analysis, the system was classified as an "overheating stress" abnormal cluster. Following the system's issuance of a Level 3 abnormality alert, the farm staff conducted an on-site inspection and discovered that the waterers in the area were malfunctioning, the water pipes were blocked, and the flock was agitated and gathered together. In this incident, the system provided a total of 13 minutes of advance warning, successfully preventing large-scale deaths caused by heat stress.
[0125] To fully verify the practical value of the system of this invention, the research team selected another workshop, Building B1, in the same breeding farm as a control group for traditional methods, and adopted a behavior recognition system based on a threshold model and single-modal image processing. Statistical data shows that within 10 consecutive days:
[0126] Table 1 Comparison data between the method of this invention and the traditional method
[0127] index The method of this invention (Building A3) Traditional method (Building B1) Total number of anomaly detections 37 times 24 times Number of correct identifications 34 times 17 times False negative rate 8.1% 29.2% False alarm rate 5.4% 21.8% Average response time lead 11 minutes and 38 seconds 3 minutes 05 seconds Accuracy in identifying rare anomalies (such as trampling, shaking). 91.7% 63.4%
[0128] Furthermore, for low-frequency anomalous behavior categories, researchers recorded a total of 56 related events in the subsequent test sample set. The method of this invention correctly identified 51 of them, while the traditional method only identified 31, which clearly verifies the superiority of the sparse anomaly modeling mechanism in this invention.
[0129] Furthermore, on the morning of the 10th day after system deployment, monitoring in Building A3 revealed that a flock of chickens exhibited significant spatial clustering between 09:17 and 09:29, with movement acceleration exceeding 15% below the historical average and decreased sound energy. The abnormal behavior probability score was as high as 0.93, and the system marked it as a Level 1 anomaly. Tracking and analyzing the clustering heatmap revealed that a dead chicken had not been promptly disposed of, and the panic caused by the flock gathering together was the culprit. After the incident was addressed, the on-site hygiene issues were corrected, effectively preventing the subsequent spread of disease.
[0130] Through system deployment and comparative experiments in real breeding environments, the livestock and poultry behavior anomaly identification method proposed in this invention outperforms existing technologies in terms of identification accuracy, response speed, and rare anomaly detection capability. In particular, when faced with complex multimodal data and dynamic behavioral changes, it can significantly improve the intelligence level and early warning capability of livestock and poultry health management, providing solid algorithmic support for large-scale smart breeding scenarios.
[0131] This invention introduces an improved conditional distribution estimation algorithm that integrates temporal context and modal mutual information coupling mechanism to construct a conditional probability density model oriented towards behavioral evolution. This significantly enhances the model's ability to characterize the continuity of behavioral evolution. By introducing behavioral continuity control parameters and modal coupling control parameters into conditional distribution modeling, it is possible to capture the collaborative change patterns between multimodal data. This allows the model to detect significant probability deviations in the early stages of stress or sudden anomalies, thereby providing a stronger forward-looking anomaly warning capability.
[0132] This invention designs a multi-scale behavior perception residual neural network structure, embedding a multi-scale temporal perception module and a behavior attention guidance mechanism into the residual network. This enables effective modeling of the performance differences of livestock and poultry behavior at different time granularities. By extracting residual signals of behavior under different receptive fields through multi-scale convolution, and using the attention mechanism to adaptively adjust the weights of residual features at each scale, the model maintains high stability and sensitivity when facing behavior patterns that frequently switch or have superimposed interference.
[0133] This invention further proposes an anomaly sparsity perception enhancement mechanism. By introducing sparsity constraints and anomaly reconstruction loss functions during training, the model's ability to identify rare abnormal behaviors is improved. Existing livestock and poultry behavior recognition models generally favor learning high-frequency behavior patterns, resulting in low detection accuracy for low-frequency behaviors. Based on the residual feature sequence, an abnormal behavior probability output and behavior trajectory clustering feedback mechanism are constructed. Combined with the reconstruction error of abnormal behavior and sparsity adjustment, fine modeling of weak signals and highly variable behaviors is achieved, effectively alleviating the problem of imbalanced samples.
[0134] The above description is only a preferred embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any equivalent substitutions or modifications made by those skilled in the art within the scope of the technology disclosed in the present invention, based on the technical solution and inventive concept of the present invention, should be covered within the scope of protection of the present invention.
Claims
1. A method for identifying abnormal behavior patterns in livestock and poultry based on distribution estimation algorithms and residual networks, characterized in that, Includes the following steps: S1. In the livestock and poultry breeding environment, acquire multi-source raw datasets of livestock and poultry behavior covering individual and group behaviors in real time, and perform preprocessing to obtain a unified structured dataset of livestock and poultry behavior with consistent structure. S2. Extract a set of statistical feature vectors based on a unified structure dataset of livestock and poultry behavior, and use a distribution estimation algorithm to train the set of statistical feature vectors to construct a probability distribution model of livestock and poultry behavior and save the model parameters; S2 includes the following steps: S21. Based on the unified structure dataset of livestock and poultry behavior D final From image frame data I′ k Infrared thermal imaging data M′ k Motion acceleration data A′ k With audio feature vector V′ k Extract modal sensing statistical features and construct a modal sensing statistical feature vector f. k ; S22. Set the modality-sensing statistical feature vectors The improved conditional distribution estimation algorithm module is input, and the coupling relationship between time context dependency and modal mutual information is introduced in the modeling process of the improved conditional distribution estimation algorithm module to construct a conditional probability density model P(f) oriented towards behavioral evolution. k |f k-1 ): Among them, f k-1 Let I(f) be the modal sensing statistical feature vector for continuous time steps k-1. k ) represents the information redundancy measure between different modalities, calculated based on the mutual information criterion, reflecting the degree of coordinated change between image, temperature, action and audio. α and β are control parameters that measure the importance of behavioral continuity and modal coupling, respectively, and Z is the normalization factor. S23. By maximizing the training samples in the conditional probability density model P(f) k |f k-1 Log-likelihood under () is used to obtain the optimal parameter set Θ of the model. cde ; S3. During the target monitoring period, input the real-time updated data of the unified structure dataset of livestock and poultry behavior into the probability distribution model of livestock and poultry behavior, calculate the probability difference score of each data point relative to the model, and generate a behavior probability difference score matrix. S4. Construct a residual neural network model and complete the initialization of model parameters. Use the behavior probability difference scoring matrix as the input data of the residual neural network model and perform multi-layer residual operations to obtain deep anomaly feature vectors. S4 further includes the following enhancement steps: S41. Embed a multi-scale temporal perception module into the residual neural network model to evaluate the input behavior probability difference scoring matrix S. final Perform multi-scale convolution processing to construct a scale set. Scale set for each scale R (s) This represents the residual representation extracted under the condition that the receptive field of the convolution kernel is s; S42. Express the residuals at each scale as R (s) The input behavior attention guidance module generates the corresponding behavior attention weight α. (s) : in, C represents the residual at time step k at scale s. k W is the original behavioral rating feature. r W c w and b are the training parameters in the attention mechanism. Let be the behavioral attention weight at the s-th scale and the k-th time step, and tanh be the hyperbolic tangent function, representing the weight in the multi-scale temporal awareness module. Given a scale s at time step k ′ The residual characteristics represent, C k ′ represents time step k ′ Behavioral scoring features; S43. Weighted fusion of residual representations across all scales with behavioral attention weights generates cross-scale residual fusion feature representations. Used to characterize the dynamic properties of abnormal livestock and poultry behavior at different granularities; S44. Introduce an anomaly sparsity awareness module and introduce an anomaly reconstruction loss function during the training phase. Optimize the residual neural network model's ability to detect rare anomalies: Among them, z k Let be the depth anomaly feature vector at time step k. To reconstruct the target vector, Let z be a flag function indicating whether the k-th time step is an anomaly. k ||1 represents the sparsity regularization term for anomalous features, λ s This is the sparsity adjustment coefficient; S45. The output of the residual network, which incorporates the behavioral attention guidance module, cross-scale residual fusion features, and anomaly sparse perception module, is used as the final anomaly discrimination input to form an enhanced deep anomaly feature sequence Z. enhanced ; S5. Classify behavior based on deep anomaly feature vectors, output behavior anomaly judgment results, and label each livestock and poultry behavior data with normal behavior markers or abnormal behavior markers. Combine the behavior anomaly judgment results with the corresponding timestamp information, perform time series backtracking analysis and spatial location mapping, generate behavior trajectory aggregation results, and classify the anomaly level by combining the behavior anomaly judgment results and the behavior trajectory aggregation results according to preset rules.
2. The method for identifying abnormal behavior patterns in livestock and poultry based on distribution estimation algorithm and residual network according to claim 1, characterized in that, S1 includes the following steps: S11. In the livestock and poultry farming environment, acquire multi-source raw data on livestock and poultry behavior, and construct a multi-source raw dataset of livestock and poultry behavior. Each data item in the multi-source raw dataset of livestock and poultry behavior consists of five parts, namely: collection timestamp t i Image frame data I i Infrared thermal imaging data M i Motion acceleration data A i and audio feature vector V i Image frame data I i The infrared thermal imaging data M is a three-dimensional tensor structure, represented as an image consisting of height, width, and channel dimensions. i Record temperature distribution information; motion acceleration data A i The audio feature vector V represents the acceleration of an object along each axis. i The audio signal features are represented by frequency and amplitude. The multi-source raw dataset of livestock and poultry behavior contains N livestock and poultry behavior data items. S12. Perform data defect removal processing on the multi-source raw dataset of livestock and poultry behavior, filtering out data items containing missing image frames, time discontinuities, missing values, or outliers, retaining only valid data items that meet the integrity and legality constraints, and standardizing the size of all image frame data to the specified standard size, and standardizing the dimension of audio feature vectors to a fixed length L. v And the motion acceleration data are sampled at a uniform sampling rate f A Resampling is performed, and a baseline timeline T is established based on the acquisition timestamps. All modal data are aligned to a uniform time scale. The baseline timeline contains K time steps, and each time step corresponds to a timestamp t. k At each time step, data from different modalities are synchronously aggregated to generate a time-aligned multimodal data sequence set; S13. Perform noise filtering on the time-aligned multimodal data sequence set, apply an edge enhancement algorithm to the image frame data to improve image clarity, apply a sliding window filter to the audio feature vector to eliminate high-frequency disturbances, and perform median filtering on the motion acceleration data to smooth abrupt signals, thereby obtaining the noise-suppressed image frame data I′. k Infrared thermal imaging data M′ k Motion acceleration data A′ k With audio feature vector V′ k We obtained a unified structured dataset D of livestock and poultry behavior with consistent structure. final .
3. The method for identifying abnormal behavior patterns in livestock and poultry based on distribution estimation algorithm and residual network according to claim 1, characterized in that, The modality-sensing statistical feature vector f k Includes behavioral descriptions and trend measures for each modality at the current time step, including the average brightness μ of the image frames. I,k Image frame brightness standard deviation σ I,k The rate of change of brightness between image frames ΔI k ; Brightness change rate ΔI k It indicates the degree of frame difference between the current frame and the previous frame, used to characterize the intensity of behavior at the image level; Features extracted from infrared thermal imaging data include the mean temperature μ M,k Temperature standard deviation σ M,k and the amplitude of sudden change in body temperature ΔM k Among them, the amplitude of body temperature change ΔM k It represents the absolute difference between the mean body temperature at the current time step and the mean body temperature at the previous time step, and is used to reflect abnormal behavioral signals such as stress, disease, or local overheating; Features extracted from motion acceleration data include the mean acceleration μ A,k σ of acceleration A,k and motion variability ΔA k Among them, the motion variability ΔA k It represents the Euclidean distance between the acceleration vector at the current time step and the acceleration vector at the previous time step, reflecting the degree of abrupt changes in livestock and poultry movement and gait instability. The features extracted from the audio feature vector include the mean audio frequency μ. V,k Audio energy standard deviation σ V,k and the amplitude of sound change ΔV k The amplitude of sound change ΔV k It represents the absolute difference between the current average audio frequency and the average audio frequency at the previous time step, and is used to identify abnormal audio behaviors such as sudden changes in vocalizations, calls for help, and screams.
4. The method for identifying abnormal behavior patterns in livestock and poultry based on distribution estimation algorithm and residual network according to claim 1, characterized in that, S3 includes the following steps: S31. During the target monitoring period, collect the current time step t. k Unified structure data item d of livestock and poultry behavior k Generate modal-aware statistical feature vector f k The modality-sensing statistical feature vector f k Modal sensing statistical feature vector f from the previous time step k-1 Input conditional probability density model P(f k |f k-1 ), calculate the log-likelihood score of the current behavior: in, The log-likelihood score represents the behavior, and α, β, and Z are the behavior continuity regulation parameter, modal coupling regulation parameter, and normalization factor determined during model training, respectively. S32. Utilize the average of the behavioral log-likelihood scores obtained during the training phase. with standard deviation Using this as a baseline, calculate the current time step t. k Behavioral probability difference score S k Behavioral probability difference score S k The behavior probability difference score S indicates the degree of deviation of the current behavior from the distribution model. k It is obtained by dividing the difference between the current behavior log-likelihood score and the baseline mean by the score standard deviation, and is used to quantify the degree to which the current behavior deviates from the normal pattern; S33. In the sliding window W containing the current time step k ={S k-w+1 ,...,S k On}, calculate the local average of the window rating sequence. Standard deviation σ W skewness γ W With kurtosis κ W Define a dynamic behavior anomaly threshold, τ. k It is composed of a linear combination of local mean score, standard deviation, skewness and kurtosis; S34. Set the current time step t k Behavioral probability difference score S k With dynamic behavior anomaly threshold τ k Comparison, if the behavioral probability difference score S k Exceeding the threshold τ k Then the current time step t k The behaviors are marked as anomalous behaviors, and the set of all time steps marked as anomalous behaviors constitutes the initial anomalous behavior mark set A. init ; S35. Initial abnormal behavior label set A init Density clustering analysis is performed on the modal sensing statistical feature vectors corresponding to the abnormal behaviors. Based on the similarity of their modal sensing features, the abnormal behaviors are divided into multiple abnormal behavior clusters, forming a cluster set C. Each cluster c in the cluster set... j Characterizes an anomaly category with similar behavioral change patterns; S36. If any anomalous behavior cluster c j The number of anomalous behaviors included exceeds the preset clustering threshold θ group If this occurs, the global scoring threshold reduction mechanism will be triggered, which will lower the current dynamic behavior anomaly threshold τ. k By comparing the weighted combination of local average scores and skewness, a new lower limit for the global score threshold is obtained. S37. Output a behavior probability difference rating matrix S containing the following three pieces of information. final Score of behavioral probability difference at each time step k Global score threshold adjusted by clustering feedback And the ClusterID, the cluster identifier to which this time step belongs in the anomalous behavior clustering analysis. k .
5. The method for identifying abnormal behavior patterns in livestock and poultry based on distribution estimation algorithm and residual network according to claim 1, characterized in that, S5 includes the following steps: S51. Enhanced deep anomaly feature sequence The input behavior classification and discrimination module uses a soft classification method to calculate the value of each time step t. k Corresponding probability of abnormal behavior in, W is the deep anomaly feature vector extracted by the residual neural network model at the k-th time step, containing a multimodal behavioral fusion representation of livestock and poultry at the current moment. o This is a classification weight vector used to classify deep anomaly feature vectors. Mapped to scalar space, b o The term is the bias term, and exp(·) is the natural exponential function. Together with 1+exp(·) in the denominator, they form a logical function. S52. Set the classification threshold θ based on the probability of abnormal behavior. p When the probability of abnormal behavior At that time, the time step is marked as abnormal behavior, and an abnormal behavior mark set A is generated. flag All unmarked time steps will default to normal behavior. S53. Combine each abnormal time step t k ∈A flag The data collection timestamps and original spatial location information of individual or group livestock and poultry are used to perform time series backtracking analysis, construct the behavioral evolution trajectory of individual or group livestock and poultry within a certain time window before and after the occurrence of an anomaly, and form a set of abnormal behavior trajectories. S54. Based on the set of abnormal behavior trajectories and the spatial location data L corresponding to each abnormal behavior time step k We construct a spatial location mapping set and perform statistical analysis on the spatial density of anomalies to reveal the spatiotemporal clustering characteristics of anomalous behavior. S55. Integrate the abnormal behavior determination results with the abnormal behavior trajectory set, and classify the abnormal behavior at each time step according to the preset abnormal level classification rules.
6. The method for identifying abnormal behavior patterns in livestock and poultry based on distribution estimation algorithm and residual network according to claim 5, characterized in that, The anomaly level classification rules refer to the following standards: Level 1 anomaly: Probability of abnormal behavior The corresponding trajectory range shows ≥3 consecutive anomalies, and the anomaly points form a high-density cluster in space, with ≥5 anomaly points occurring in a local area within 5 minutes; Level 2 anomaly: Probability of abnormal behavior There are 2 to 3 anomalies within the trajectory range, and their spatial distribution is either locally concentrated or appears periodically; Level 3 Abnormality: Probability of Abnormal Behavior The trajectory shows a single outlier or a random distribution, without forming a clustered feature.
Citation Information
Patent Citations
Intelligent monitoring management method and system for cattle breeding
CN116597377A
Livestock behavior identification method and device based on global and local information co-enhancement
CN117523601A