A pig breeding environment dynamic monitoring management method and system based on environmental epidemic prevention

By collecting pig behavior data in pig houses to construct an environmental correlation model, the high cost of environmental monitoring and the problem of identifying hidden risks in large-scale pig houses have been solved. This has enabled low-cost and highly reliable environmental disease prevention and control management, and improved the timeliness of early warning and the quantification of disease transmission risks.

CN123142145APending Publication Date: 2026-11-20成都市畜禽遗传资源保护中心(成华猪保护研究基地)
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202611194299.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-08-07
Publication Date
2026-11-20

AI Technical Summary

Technical Problem

Existing pig farming environment monitoring systems suffer from high hardware deployment costs, low reliability of monitoring data, inability to identify hidden environmental stresses, and difficulty in quantifying disease transmission risks in large-scale pig houses, resulting in wasted monitoring resources and poor timeliness of early warning.

Method used

By collecting pig herd behavior data through non-contact monitoring equipment, a behavioral characteristic-environment correlation model is constructed. Combined with the spatial layout information of pig houses, suspected areas of environmental abnormality are located and targeted monitoring is implemented to generate graded early warning information and biosecurity control strategies.

Benefits of technology

It has enabled refined and low-cost environmental epidemic prevention monitoring, improved the ability to identify hidden risks and quantify the risk of disease transmission, and enhanced the timeliness of early warning and the economic feasibility of the monitoring system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123142145A_ABST
    Figure CN123142145A_ABST
Patent Text Reader

Abstract

The application discloses a pig breeding environment dynamic monitoring management method and system based on environmental epidemic prevention, relates to the breeding epidemic prevention technical field, and first analyzes the multi-dimensional behavior characteristics of a pig group in a grid pig house, establishes a pig group behavior characteristic set taking a grid as a unit; further, based on historical supervision data, a behavior characteristic-environment correlation model is constructed, suspected environmental disturbance types of behavior abnormalities are traced back based on the pig group behavior characteristic set, corresponding grid risk areas are accurately positioned, and a hierarchical differentiated dynamic monitoring mechanism is established for monitoring, combined with the spatial layout of the pig house, the spatial propagation risk distribution of the pig house epidemic disease is analyzed, technical defects such as waste of monitoring resources, weak implicit risk identification ability, missing of cause-effect correlation and inability to quantitatively deduce the epidemic disease propagation risk in the prior art are effectively solved, and the needs of fine, low-cost and high-reliable environmental epidemic prevention monitoring management of large-scale pig farms are met.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of animal husbandry disease prevention technology, specifically to a method and system for dynamic monitoring and management of pig farming environment based on environmental disease prevention. Background Technology

[0002] With the rapid development of pig farming towards large-scale and intensive operations, environmental monitoring and disease control have become key factors restricting the healthy development of the pig industry. In recent years, the introduction of technologies such as the Internet of Things, artificial intelligence, and computer vision has provided new technical means for the intelligent monitoring of the pig farming environment.

[0003] Existing technologies, such as the pigsty environment control and optimization method and system disclosed in application CN120802638A, collect pigsty environmental parameters and pig physiological data through multimodal sensors, construct a behavior recognition model to divide abnormal areas, and output an environmental control plan. Another example is the IoT-based cold-region pig farming environment management method and system disclosed in application CN121481759A, which acquires real-time cold-region pig farming environment data and behavioral data, constructs an environmental spatial relationship graph based on graph neural networks to predict future environmental changes, and simultaneously combines behavioral data with capsule networks and long short-term memory networks to predict the health status of pigs.

[0004] While the aforementioned technical solutions achieve the assessment of pig health status based on environmental parameters and the joint analysis of environmental and behavioral data, large-scale pig farming requires monitoring a wide variety of environmental parameters with uneven spatial distribution. Sensors are susceptible to interference from harsh environments such as high humidity, high temperature, dust, and corrosive gases within the pigsty, leading to increased equipment failure rates, data drift, and high hardware deployment and maintenance costs. Limited by monitoring costs, existing solutions struggle to achieve high-density sensor coverage across the entire pigsty. Furthermore, adopting a continuous, indiscriminate, high-frequency monitoring mode further exacerbates the consumption of hardware power consumption, data transmission, and storage resources, limiting the economic feasibility and long-term stable operation of the monitoring system.

[0005] Meanwhile, the data extrapolation logic of the above schemes all derives the health status of pigs from environmental data. The effectiveness of monitoring is highly dependent on the density and reliability of the sensor network. When some sensors malfunction or drift, resulting in missing or distorted data, the accuracy of health assessment decreases accordingly. Existing technologies lack mechanisms to use abnormal pig behavior to trace the source of potential environmental disturbances. It is difficult to effectively identify latent environmental stresses that have not yet reached the sensor alarm threshold but have induced stress behaviors in pigs, or local environmental anomalies that have not been captured due to sparse sensor deployment, thus missing the window of opportunity for early warning and intervention.

[0006] Furthermore, the aforementioned scheme only achieved a correlation fitting between environmental parameters and pig health status, failing to establish a temporal causal transmission relationship of environmental disturbance → pig behavior characteristics → disease stress transmission. Changes in environmental factors such as temperature, humidity, and harmful gases do not immediately affect pig health; rather, there is a physiological lag effect—that is, environmental stress requires a certain period of cumulative exposure before observable abnormal responses in pig behavior and physiological indicators appear. Existing technologies do not consider this temporal delay, leading to timeliness deviations in monitoring, early warning, and control decisions. More critically, the monitoring spatial units in existing technologies are independent, with monitoring results from each grid or area output in isolation. This fails to incorporate spatial layout features such as pigpen partition structures and ventilation directions to quantify the risk of cross-regional disease transmission between grids. Consequently, environmental monitoring, pig health assessment, and disease spatial transmission analysis are disconnected, preventing the formation of a complete disease prevention decision support chain from environmental disturbance identification to health risk assessment and transmission prediction. Summary of the Invention

[0007] To address the aforementioned technical shortcomings, the present invention aims to provide a method and system for dynamic monitoring and management of pig farming environment based on environmental disease prevention.

[0008] To solve the above-mentioned technical problems, the present invention adopts the following technical solution: In the first aspect, the present invention provides a method for dynamic monitoring and management of pig farming environment based on environmental disease prevention, including: continuously collecting behavioral data of pigs in pigsty through non-contact monitoring equipment, and analyzing the behavioral characteristic set of pigs.

[0009] Based on historical monitoring records, a behavioral feature-environment association model is constructed. The behavioral feature set is matched with the behavioral feature-environment association model to determine the set of suspected environmental anomalies. Based on the spatial distribution information of pigs in the pigsty, the risk area corresponding to the set of suspected environmental anomalies is located.

[0010] In response to the model matching inference results, targeted environmental monitoring of the risk area and investigation and monitoring of non-risk areas are initiated to obtain environmental parameter data of the risk area and non-risk area.

[0011] Based on environmental parameter data of risk and non-risk areas, combined with information on the spatial layout of pig houses, the spatial transmission risk distribution of diseases within pig houses is calculated.

[0012] Based on the spatial propagation risk distribution, hierarchical early warning information and targeted biosafety control strategies are generated.

[0013] Secondly, the present invention provides a dynamic monitoring and management system for pig farming environment based on environmental disease prevention, comprising: a monitoring unit for continuously collecting behavioral data of pigs in pigsties through non-contact monitoring equipment.

[0014] The server includes a feature analysis unit, a risk location unit, a distribution analysis unit, and a security control unit.

[0015] The feature analysis unit is used to analyze the set of behavioral features of the pig herd using behavioral data of the pigs in the pigsty.

[0016] The risk location unit is used to construct a behavioral feature-environment association model based on historical regulatory records, match the behavioral feature set with the behavioral feature-environment association model to determine the set of suspected environmental anomalies, and locate the risk area corresponding to the set of suspected environmental anomalies based on the spatial distribution information of pigs in the pigsty.

[0017] The monitoring unit is also used to initiate targeted environmental monitoring of the risk area and investigation and monitoring of non-risk areas in response to the results of the model matching inference, and to obtain environmental parameter data of the risk area and non-risk area.

[0018] The distribution analysis unit is used to calculate the spatial transmission risk distribution of diseases within pigsties based on environmental parameter data of risk and non-risk areas, combined with information on the spatial layout of pigsties.

[0019] The safety control unit is used to generate graded early warning information and targeted biosafety control strategies based on the spatial propagation risk distribution.

[0020] The beneficial effects of this invention are as follows: This invention provides a method and system for dynamic monitoring and management of pig farming environment based on environmental disease prevention. First, it uses visual and acoustic multimodal perception technologies to finely analyze the multidimensional behavioral characteristics of pigs in gridded pig houses, establishing a set of pig behavior characteristics based on spatial grids. Further, based on historical monitoring data, it constructs a behavioral characteristic-environment correlation model. Based on the set of pig behavior characteristics, it traces back to the source of suspected environmental disturbances that induce abnormal behavior, accurately locating the corresponding gridded risk areas. For the risk and non-risk areas obtained from the source tracing, a hierarchical differentiated dynamic monitoring mechanism is established for monitoring. Combined with the spatial layout of the pig houses, it analyzes the spatial distribution of disease transmission risks in pig houses. This effectively solves the technical defects of existing technologies, such as wasted monitoring resources, weak ability to identify hidden risks, lack of causal correlation, and inability to quantify and extrapolate disease transmission risks. It meets the needs of large-scale pig farms for refined, low-cost, and highly reliable environmental disease prevention monitoring and management. Attached Figure Description

[0021] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0022] Figure 1 This is a schematic diagram of the implementation steps of the method of the present invention.

[0023] Figure 2 This is a schematic diagram of the system structure connection of the present invention. Detailed Implementation

[0024] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0025] Please see Figure 1 As shown, a dynamic monitoring and management method for pig farming environment based on environmental disease prevention includes: continuously collecting behavioral data of pigs in pig houses through non-contact monitoring equipment, and analyzing the behavioral characteristic set of pigs.

[0026] In a specific embodiment, the specific process of analyzing the behavioral feature set of the pig herd is as follows: the pigsty is divided into grids and the grids are numbered. Infrared high-definition cameras and depth vision cameras are deployed above and to the sides of each grid area to collect full-area video streams and depth image data, and the data collection time sequence is synchronized with the grid environment monitoring data of the pigsty.

[0027] Based on full-domain video streams and depth image data, individual pigs are identified through instance segmentation combined with multi-object tracking algorithms, and each pig is assigned a unique identifier ID. Visual behavioral features of each pig are extracted using a deep learning model. At the same time, sound processing technology is used to collect audio signals from the pigsty, and acoustic features are extracted from the audio signals. The acoustic features are then matched with the corresponding individual IDs based on the spatial coordinates of the pigs. The visual behavioral features and acoustic features are fused to obtain the quantitative behavioral features of a single pig. The individual behavioral features of all pigs in each grid are summarized to form a set of behavioral features of the corresponding pig herd.

[0028] The individual visual behavioral characteristics mentioned above include: movement characteristics such as instantaneous movement speed, movement acceleration, distance traveled per unit time, and percentage of time spent at rest; body posture characteristics such as duration of standing, lying down, feeding, and drinking postures and frequency of posture changes; group interaction characteristics such as frequency of close contact between pigs, fighting behavior, and time spent alone in groups; spatial distribution characteristics such as individual spatial dwelling preferences, frequency of movement across grids, and distance from facility boundaries; and stress-related abnormal behaviors such as restless pacing, leaving the group, and reduced feed intake.

[0029] The acoustic features include: time-domain features such as short-time energy, zero-crossing rate, duration of call, and call frequency; frequency-domain features such as Mel frequency cepstral coefficients, fundamental frequency, and spectral center; and event-related acoustic features such as feeding humming, agitated hissing, fighting screams, stress wailing, coughing, and wheezing.

[0030] It should be noted that the collected raw audio signals from the pigsty underwent preprocessing, including noise suppression and frame-by-frame windowing. Temporal and frequency-domain acoustic features were extracted from the framed audio sequences. These features were then input into a pre-trained audio event recognition model, which outputs acoustic event labels for various pigs. Finally, the temporal, frequency, and event labels were integrated to form a complete acoustic feature set. The preprocessing steps included using spectral subtraction to eliminate steady-state background noise from equipment such as pigsty fans and water curtains, and suppressing random noise from dust and airflow. Continuous audio was converted into short-time stationary signals through short-time framing and Hanning windowing.

[0031] The time-domain acoustic features are directly calculated from the framed audio waveforms and include short-time energy, short-time average amplitude, zero-crossing rate, duration of a single call, and call frequency per unit time. The frequency-domain acoustic features are calculated by performing a fast Fourier transform on the framed audio to obtain the spectrum and include the spectral center, spectral bandwidth, fundamental frequency, spectral flux, and Mel-frequency cepstral coefficients (MFCC).

[0032] The audio event recognition model takes time-domain and frequency-domain features as input, distinguishes different types of pig vocalization events such as feeding grunts, restless hissing, fighting screams, stress cries, coughing and wheezing, and outputs discrete acoustic event labels.

[0033] Based on historical monitoring records, a behavioral feature-environment association model is constructed. The behavioral feature set is matched with the behavioral feature-environment association model to determine the set of suspected environmental anomalies. Based on the spatial distribution information of pigs in the pigsty, the risk area corresponding to the set of suspected environmental anomalies is located.

[0034] In a specific embodiment, the construction of the behavioral feature-environment association model is carried out as follows: each historical monitoring record is bound to a spatial grid number and a unified timestamp, and includes grid environmental parameter data, the set of pig herd behavioral features of the corresponding grid, and historical disease and stress event tags.

[0035] It should be noted that the environmental parameter data includes basic environmental parameters and high-order environmental parameters. The basic environmental parameters include temperature, relative humidity, carbon dioxide concentration, ammonia concentration, hydrogen sulfide concentration, dust concentration, and average airflow velocity within the pigsty grid, which are collected by a fixed environmental sensor array deployed in each grid. The high-order environmental parameters include local airflow turbulence intensity, airflow direction, volatile organic compound concentration, and pathogen aerosol concentration, which are collected by a mobile inspection robot.

[0036] Historical disease and stress event labels include mass stress event labels and disease event labels; mass stress event labels include high temperature heat stress, low temperature cold stress, harmful gas stress, dust irritation stress, airflow turbulence stress, and temperature and humidity fluctuation stress, etc.; disease event labels include mass respiratory disease risk events, digestive disease risk events, aerosol-borne disease spread events, and skin contact disease risk events, etc.

[0037] Historical monitoring records were cleaned and normalized, environmental effect time lag windows were configured, and a paired sample set of environmental parameters and lagging pig herd behavior characteristics within the same grid was constructed.

[0038] Preferably, the specific process of constructing a paired sample set of environmental parameters and lagging pig herd behavioral characteristics within the same grid is as follows: A global time lag interval is preset based on the physiological stress patterns of pigs. And preset a fixed time step ; Traverse all discrete lag times within the interval .

[0039] Using grid number as the primary matching constraint, pairing of data within the same grid is only allowed. Environmental parameter data collected at time t within the same grid is matched with the pig herd behavior characteristics at time t+T of that grid to form time series sample pairs of preceding environmental parameters and lagging behavioral characteristics.

[0040] Further, event records within a preset observation window after t+T are retrieved from the grid and assigned corresponding historical disease and stress event labels. Only data combinations with complete time series and no missing data are retained, and a paired sample set of environmental parameter data and lagging pig herd behavioral characteristics carrying event labels is obtained.

[0041] It should be noted that changes in environmental parameters do not immediately cause changes in pig behavior; there is an objective physiological time lag between the two. This solution, developed by livestock disease control professionals, combines the physiological stress characteristics of pigs with long-term operational data from pig farms to pre-configure a global time lag interval and a fixed time step. This constrains the temporal extrapolation window of the dynamic Bayesian network, ensuring the rationality of the modeling of the temporal causal relationship between environmental disturbances, pig behavioral characteristics, and disease events.

[0042] A directed correlation network is constructed based on paired sample sets: environmental parameters are used as exogenous influence nodes, pig herd behavior characteristics are used as intermediate response nodes, and disease and stress labels are used as terminal result nodes. A one-way transmission path of multi-environment coupling effect → abnormal pig herd behavior deviation → group stress and disease is constructed. Directed causal edges between nodes are established and the dynamic weights of each causal edge are solved.

[0043] Preferably, the specific process of solving the dynamic weights of each causal edge is as follows: A dynamic Bayesian network is used to parameterize the directed correlation network; a static initial topology is learned using a hybrid algorithm of score search and constraint testing based on single-time-slice data, with the Bayesian information criterion as the score function; the learning is extended to the time-series dimension to learn cross-time transition edges, with the optimal lag step search range limited to a preset global environment effect lag interval; parameter learning is completed using maximum likelihood estimation or expectation maximization algorithms to obtain the conditional probability matrix of the same time slice and the cross-time-slice transition probability matrix, and the causal dependency strength represented by the probability is transformed into the dynamic weights corresponding to each causal edge.

[0044] The specific calculation process of the dynamic weights described above is as follows: For each directed causal edge within the same time slice that points to a stress or disease event based on environmental or behavioral factors, the conditional probability matrix is ​​traversed, and the average conditional probability of a stress or disease event occurring in the child node under both abnormal and normal conditions is calculated. The difference between the two probabilities is then taken as the instantaneous original causal influence strength of the causal edge. For cross-time-slice temporal causal edges, based on the cross-time-slice transition probability matrix, the average transition probability of the abnormal state of the parent node in the previous time slice propagating to the abnormal event of the child node in the next time slice is calculated, which is taken as the original causal influence strength of the temporal dimension. After obtaining the original influence strengths of all causal edges, the range normalization process is performed on the strengths of all input causal edges belonging to the same child node, mapping the values ​​uniformly to the interval between 0 and 1 to obtain the normalized causal strength. The normalized causal strength is then fine-tuned to obtain the dynamic weights corresponding to each causal edge. The larger the dynamic weight value, the higher the causal contribution and driving strength of the corresponding environmental parameter or behavioral characteristic to the occurrence of stress and disease in the pig herd.

[0045] Among them, the node status judgment is based on the industry's livestock and poultry breeding environment standards, equipment threshold specifications, and historical health sample distribution: (1) For environmental parameter nodes: the national standard environmental safety threshold for large-scale pig breeding is used as the benchmark. When the monitoring parameter exceeds the standard comfort range, it is judged as an abnormal state, and when it is within the standard range, it is judged as a normal state; (2) Based on the historical healthy pig herd behavior monitoring data of no less than 30 healthy production days, the mean and standard deviation of each behavior feature are calculated separately, and the normal distribution interval of the behavior feature is constructed. The preset standard deviation multiple is 2.5≤k≤3.5. The specific value is set according to the monitoring sensitivity requirements. The smaller the k value, the higher the sensitivity and the higher the false alarm rate. When the real-time value of the pig herd behavior feature in a certain grid deviates from the mean of the healthy sample by more than the preset standard deviation multiple, the behavior feature node is judged as an abnormal state, otherwise it is judged as a normal state. (3) The historical event samples marked by professionals with licensed veterinarian qualifications based on clinical diagnosis records are used as the benchmark true value. The marking accuracy is accurate to the specific grid and specific date. The state where no event has occurred is marked as normal no-event state, and the state where an event has occurred is marked as abnormal onset / stress state.

[0046] Determining Scene Correction Coefficients: Based on historical samples from the entire breeding cycle, with the optimization objectives of minimizing model causal inference error and maximizing event recognition hit rate, the initial optimal coefficients corresponding to each causal edge are solved through grid search. Combined with prior physiological constraints on pigs, the coefficients are limited to the range of 0.8–1.2. If the optimal solution obtained from the grid search exceeds this range, the boundary value of the range is taken. Larger coefficients are assigned to environmental stress factors, and smaller coefficients are assigned to behavioral random fluctuation factors, resulting in the final scene correction coefficients. The normalized causal strength is multiplied by the scene correction coefficient of the corresponding causal edge to obtain the initial weight. If the multiplication result is greater than 1, the weight is truncated to 1. The result is naturally greater than or equal to 0, requiring no lower limit truncation; the final output value serves as the dynamic weight of the causal edge. When the scene correction coefficient is greater than 1, the causal contribution intensity of the corresponding factor is amplified; when the scene correction coefficient is less than 1, the interference effect caused by random fluctuations is weakened.

[0047] Based on forward causal reasoning using dynamic Bayesian networks, the influence intensity and optimal lag time of single and multiple environmental parameters on abnormal behavioral characteristics of pig herds are quantified, and the contribution value of disease stress risk corresponding to each combination of environmental parameters is calculated along the transmission path.

[0048] In the above, the contribution value of disease stress risk corresponding to each combination of environmental parameters is calculated along the transmission path. The specific calculation steps are as follows: Step 1: Fix the state of the environmental parameter to be analyzed as an abnormal state, and keep the other environmental parameters in a normal state; traverse all candidate time lag steps within the preset global time lag interval, and carry out temporal forward reasoning in sequence to solve the posterior probability of abnormal occurrence of pig herd behavior feature nodes under different lag durations.

[0049] Step 2: The number of lag steps corresponding to the maximum posterior probability of abnormal pig behavior is taken as the optimal lag time for the single environmental parameter to affect pig behavior; the difference between the posterior probability corresponding to the optimal lag time and the baseline probability (the probability of abnormal behavior when all environmental parameters are normal) is used to characterize the influence of the environmental parameter on abnormal pig behavior.

[0050] Step 3: For scenarios involving multiple coupled environmental parameters, set a selected set of environmental parameters to an abnormal state, while keeping the remaining environmental parameters normal; repeat steps 1 and 2 to solve for the optimal lag time and coupling influence strength of abnormal pig behavior under multiple coupled parameters.

[0051] Step 4: Following the unidirectional transmission path from environmental parameter nodes to pig herd behavior characteristic nodes to disease and stress label nodes, the temporal posterior probability is transmitted layer by layer based on the dynamic weights of all causal edges on the path; the comprehensive posterior probability of the occurrence of terminal stress events and disease events under the current combination of environmental parameters is obtained; if there are cross-layer causal edges where environmental parameters directly point to disease and stress label nodes, they are also included in the temporal probability transmission calculation.

[0052] Step 5: Decompose the contribution by combining the dynamic weights of each environmental parameter on the path: For any environmental parameter, calculate the cumulative weight of each independent transmission path leading to the terminal event node. Sum the cumulative weights of all transmission paths for the same environmental parameter to obtain the total path weight of the environmental parameter. Sum the total path weights of all environmental parameters and allocate the posterior probability of the comprehensive risk according to the proportion of each environmental parameter's path weight to the total weight to obtain the contribution value of the epidemic stress risk corresponding to each environmental parameter. The sum of the contribution values ​​of the epidemic stress risk of all environmental parameters is consistent with the posterior probability of the terminal comprehensive risk.

[0053] Baseline probability definition: The baseline posterior probability of abnormal pig behavior obtained by model inference when all environmental parameters are in a normal state.

[0054] By eliminating redundant causal edges in the network through saliency screening and retaining the salient causal transmission topology, a directed correlation model of behavioral features and environment is obtained.

[0055] The specific steps for significance screening described above are as follows: Step 1: For each candidate directed causal edge in the network, based on the historical paired sample set, the conditional independence significance test is used to test whether there is a real conditional dependency between the variables at both ends of the causal edge; Step 2: A preset significance level threshold is set, and the test p-value corresponding to each causal edge is calculated; if p > significance level threshold, it indicates that the association between variables is not statistically significant, and the causal edge is determined to be a redundant edge; otherwise, a significant causal association between variables is identified; Step 3: A secondary constraint on the dynamic weight of the causal edge is introduced: For causal edges that pass the test but whose dynamic weight is lower than the preset lower weight threshold (preferably 0.1), they are also determined to be weakly associated redundant edges and are removed; Step 4: All redundant causal edges are removed, and causal edges that simultaneously satisfy the statistical significance condition and the dynamic weight threshold condition are retained to form a simplified significant causal transmission topology, resulting in a behavioral feature-environment directed association model.

[0056] In another specific embodiment, the process of determining the set of suspected environmental anomalies is as follows: the set of pig herd behavioral features is standardized and transformed into a multi-dimensional behavioral feature vector with a unified dimension. Then, the vector is input into the behavioral feature-environment association model to initiate a multi-dimensional causal matching mechanism. The similarity between the multi-dimensional behavioral feature vector and each behavioral feature in the model is calculated one by one. Based on the causal mapping relationship of the model, the initial matching degree score of each environmental parameter disturbance corresponding to the multi-dimensional behavioral feature is solved.

[0057] The initial matching score is calculated as follows: The pig herd's behavioral features are standardized using range standardization, mapping each feature to the interval [0,1], and then concatenated to form a real-time multidimensional behavioral feature vector. , where m is the number of behavioral features.

[0058] Retrieve sample vectors of each behavioral feature stored in the behavioral feature-environment directed association model. The cosine similarity method is used to calculate the similarity between the real-time observation vector and the sample vectors of each behavioral feature. k represents the behavioral feature number, which takes the value of a positive integer.

[0059] The similarity value ranges from [-1, 1], with the effective interval being [0, 1]. A higher value indicates that the current pig herd behavior is closer to that behavior in the model.

[0060] Read the directed causal mapping relationship within the model to obtain The original matching score is obtained by summing the similarity of all behavioral feature sample vectors and the corresponding dynamic weights of all associated environmental parameters and their causal edges, for a given environmental parameter.

[0061] Range normalization is performed on the original matching scores corresponding to all environmental parameters, mapping them to the interval [0,1] to obtain the initial matching score. The higher the initial matching score, the more likely the observed abnormal behavior of the pig herd is to be induced by the disturbance of this environmental parameter. Environmental parameters with initial matching scores higher than a preset threshold are selected to form a candidate environmental type set.

[0062] After the initial matching score completes the coarse screening, the process enters the refined reverse tracing process: when any abnormal behavior feature is identified and activated, Bayesian posterior probability reverse inference is carried out based on the forward causal topology of the dynamic Bayesian network, traversing all environmental parameter transmission paths that can induce the shift of multidimensional behavior feature vectors.

[0063] In the above, the criteria for identifying and activating abnormal behavior features are as follows: for each quantified pig herd behavior feature within a single grid, the state is determined based on the preset abnormal behavior judgment threshold and the distribution range of healthy pig herd behavior features; when a certain behavior feature is not in the distribution range of healthy pig herd behavior features, or the feature offset exceeds the abnormal behavior judgment threshold, the behavior feature of that dimension is determined to be abnormal and activated; as long as any one-dimensional behavior feature within the grid meets the abnormal conditions, the multi-behavior joint reverse tracing reasoning mechanism is activated to avoid false triggering caused by a single slight behavioral disturbance, while ensuring that environmental stress induced by multi-dimensional weak abnormal coupling is not missed.

[0064] Unlike the independent judgment method based on a single behavioral feature, this method treats all pig herd behavioral features within the same grid as a set of overall observational evidence. Relying on the coupling weights of multiple environmental parameters and the dynamic weights of each causal edge in the dynamic Bayesian network, the method accumulates and calculates the joint probability of behavioral anomalies corresponding to all environmental parameter perturbations. Based on the mapping of environmental parameter perturbation states, the method obtains the corresponding candidate environmental anomaly types and acquires the comprehensive evidence weight of the pig herd behavioral feature set for each candidate environmental anomaly type.

[0065] The specific calculation process of the comprehensive evidence weight is as follows: s1: retrieve the real-time observation status of pig herd behavior characteristics of all dimensions in the current grid, and construct an overall observation evidence set that includes evidence of normal behavior and evidence of abnormal behavior, so as to avoid the problems of evidence loss and one-sided tracing caused by only using abnormal features.

[0066] s2: For each perturbation of a candidate environmental parameter in the candidate set, traverse all causal transmission edges pointing to each behavioral feature from that candidate environmental parameter and retrieve the dynamic weight of the corresponding causal edge; if multiple candidate environmental parameters are simultaneously perturbed to form a parameter combination in subsequent evaluations, then introduce the weight of multi-environment coupling effect.

[0067] s3: Based on the time-series topology of the dynamic Bayesian network, the independent posterior probabilities of the shift of each behavioral feature under the perturbation of the single candidate environmental parameter are solved, and the corresponding dynamic weights are combined to perform weighted accumulation to obtain the weighted joint probability of the environmental parameter on multidimensional behavioral anomalies.

[0068] s4: When multiple candidate environmental parameters are synchronously disturbed to form a parameter combination, the coupling weights between multiple environmental parameters are integrated to correct the probability bias caused by the superposition, synergy, and inhibition of different environmental parameters. Specifically: the posterior probabilities of behavioral anomalies corresponding to individual anomalies of each environmental parameter within the combination are summarized and summed to obtain the linear superposition baseline probability, with the upper limit of the baseline probability truncated to 1; the coupling weights corresponding to the parameter combination are retrieved, and the linear superposition baseline probability is multiplied by the coupling weights to obtain the coupling-corrected joint probability, with the value range constrained to 0 to 1; then, based on the proportion of the total path dynamic weight of each environmental parameter to the total path weight, the coupling-corrected joint probability is allocated to obtain the matching probability of the overall behavioral evidence set corresponding to the disturbance of each environmental parameter within the combination; if only a single candidate environmental parameter is evaluated, the weighted joint probability obtained in s3 is directly used in subsequent calculations.

[0069] s5: Perform range normalization on the weighted joint probability or matching probability corresponding to each candidate environmental parameter, mapping it to the 0-1 interval to obtain the comprehensive evidence weight of the current pig herd behavior feature set for each candidate environmental anomaly type; the larger the comprehensive evidence weight, the stronger the credible cause of the environmental disturbance that induces the current overall behavior deviation of the pig herd.

[0070] The calculation method for the coupling effect weight of multiple environmental parameters is as follows: Select a set of environmental parameters, and set each environmental parameter to an abnormal state individually. Perform forward inference of the dynamic Bayesian network to obtain the posterior probability of a single environmental parameter inducing abnormal behavior in the pig herd. Sum these probabilities to obtain the linear superposition baseline probability, with the upper limit of the baseline probability truncated to 1. Then, set the set of environmental parameters to an abnormal state together and perform forward inference to obtain the measured posterior probability of abnormal behavior in the pig herd under multi-parameter coupling conditions. Divide the measured posterior probability of coupling by the linear superposition baseline probability to obtain the initial coupling weight. To avoid extreme values, the coupling weight is constrained to the range of 0.5 to 1.8. When it exceeds the range, the boundary value is taken. When the linear superposition baseline probability approaches 0, the coupling weight is directly set to 1. A coupling weight greater than 1 indicates a synergistic stress effect between environmental parameters, less than 1 indicates an antagonistic effect, and equal to 1 indicates no significant interaction.

[0071] Based on the comprehensive evidence weight, all candidate environmental anomaly types are sorted in descending order to obtain a set of suspected environmental anomaly types with confidence levels from high to low.

[0072] In the above process, the comprehensive evidence weights corresponding to each candidate environmental anomaly type are extracted and sorted in descending order; a primary warning threshold and an auxiliary reference threshold are preset, and types with comprehensive evidence weights higher than the primary warning threshold are defined as core suspected causes, while those with weights between the auxiliary reference threshold and the primary warning threshold are defined as secondary potential causes. Candidate types with weights lower than the auxiliary reference threshold are eliminated; the core suspected causes and secondary potential causes are integrated according to the sorting results to form a set of suspected environmental anomaly types with confidence levels from high to low.

[0073] In one specific embodiment, the process of locating the risk area corresponding to the set of suspected environmental anomalies is as follows: based on the unique identifier ID of each pig obtained by visual tracking and its real-time spatial coordinates, the grid number to which each pig belongs is matched.

[0074] The target grid corresponding to the set of suspected environmental anomalies obtained through reasoning, and the set of pig herd behavior characteristics generated, are used as the initial candidate risk grid.

[0075] Extract the location distribution of all pigs within the initial candidate risk grid, and simultaneously obtain the behavioral feature set of pigs in adjacent grids and the cross-grid activity trajectory of pigs. Combine the degree of behavioral offset between adjacent grids with the individual movement trajectory to calculate the correlation degree of behavioral anomalies between grids.

[0076] In the above process, for the initial candidate risk grid and any adjacent grid, the offset of each behavioral feature relative to the mean of healthy samples is calculated and spliced ​​to form a multidimensional behavioral offset vector of the grid; the cosine similarity is used to calculate the similarity of the behavioral offset vectors of the two grids; the number of pigs moving back and forth between the initial candidate risk grid and the adjacent grid within the preset time window is counted; the ratio of the number of pigs moving across grids to the total number of pigs in the initial candidate grid is used as the individual interaction weight, and a fixed weight coefficient is preset. The abnormal correlation degree between grids = offset vector similarity × fixed weight coefficient + (1 - fixed weight coefficient) × individual interaction weight.

[0077] Adjacent grids with a correlation degree greater than the preset correlation degree of behavioral anomalies are included in the risk region, which together with the initial candidate risk grids constitutes the risk region; the spatial range of the risk region is output, which is composed of grid number and spatial coordinate boundary.

[0078] In response to the model matching inference results, targeted environmental monitoring of the risk area and investigation and monitoring of non-risk areas are initiated to obtain environmental parameter data of the risk area and non-risk area.

[0079] In a specific embodiment, the specific process of targeted environmental monitoring of the risk area and investigation and monitoring of non-risk areas is as follows: Targeted environmental monitoring: Based on the set of suspected environmental anomalies, basic environmental parameters and high-order environmental parameters are obtained; Basic environmental parameters are collected intensively using an array of environmental sensors deployed in the risk area; For high-order environmental parameters, a patrol robot equipped with corresponding monitoring sensors is used to perform high-density multi-point patrol monitoring in the risk area.

[0080] Among them, the basic environmental parameters are indicators that can be continuously and routinely collected by fixed-point sensors; while the advanced environmental parameters are indicators that rely on inspection robots to move and sample at multiple points, which are more expensive and not suitable for long-term, high-frequency collection.

[0081] Screening and monitoring: Use an array of environmental sensors deployed in non-risk areas to collect basic environmental parameters at a regular sampling frequency.

[0082] It should be noted that the basic environmental parameters of non-risk areas are continuously monitored. When the difference between adjacent sampling times of the basic environmental parameters of non-risk areas exceeds the preset fluctuation threshold, it is judged as a monitoring anomaly. The inspection robot is dispatched to the non-risk area to carry out verification sampling, and high-order environmental parameters are collected in the non-risk area at the same time. High-order environmental parameters are also collected in the adjacent or nearest risk areas for cross-comparison analysis.

[0083] Based on environmental parameter data of risk and non-risk areas, combined with information on the spatial layout of pig houses, the spatial transmission risk distribution of diseases within pig houses is calculated.

[0084] The above information is obtained from the pigsty design drawings to determine the spatial layout of the pigsty.

[0085] In a specific embodiment, the process of calculating the spatial spread risk distribution of disease in pigsties is as follows: inputting environmental parameter data of each grid in the risk area and non-risk area into the behavioral feature-environment association model, and calculating the posterior probability of disease and mass stress events occurring in each grid.

[0086] The above process for calculating the posterior probability of disease outbreaks and mass stress events in each grid is as follows: input the environmental parameter data of each grid in the risk area and the non-risk area into the behavioral feature-environment association model, and calculate the posterior probability of disease outbreaks and mass stress events in each grid.

[0087] Preferably, the calculation process for the posterior probability of disease outbreaks and group stress events in each grid is as follows: Collect environmental parameter data and multidimensional behavioral characteristics of the pig herd within a single grid, and construct an observational evidence set after standardization; retrieve the behavioral characteristic-environment association model, the dynamic weights of each causal edge, and the coupling weights of multiple environmental parameters; when multiple environmental parameters in the same grid are synchronously abnormal, use the coupling weights of multiple environmental parameters to correct the probability of the joint effect of environmental parameters; solve for the posterior probability of disease outbreaks and group stress events in a single grid using the Bayesian conditional probability formula; constrain the calculation results to the interval between 0 and 1; traverse all grids in the pigsty to obtain the posterior probability of disease outbreaks and group stress events in all grids.

[0088] The posterior probability of disease outbreaks and mass stress events occurring in each grid is bound to the spatial coordinates of the corresponding grid.

[0089] Extract the partition structure and ventilation connectivity features of each grid from the spatial layout information of the pigsty, and calculate the probability of cross-grid disease transmission and transfer between grids; use the probability of disease occurrence and mass stress events in each grid as the initial endogenous risk value of the grid, and combine it with the probability of disease transmission and transfer between grids to carry out spatial diffusion extrapolation, and iteratively solve to obtain the steady-state disease risk values ​​of all grids.

[0090] The calculation process for all grid steady-state disease risk values ​​is as follows: the isolation structure and ventilation connectivity characteristics of each grid are compared with the preset barrier coefficient table and airflow diffusion coefficient table to obtain the barrier coefficient and airflow diffusion coefficient of each grid and its adjacent grids, and the average value is calculated to obtain the cross-grid transmission and transfer probability of disease between each grid and its adjacent grids.

[0091] Among them, physical partition features include solid partitions, low fences, passageway openings and other types of barriers; the preset barrier coefficient table contains the barrier coefficients corresponding to different barrier types, for example: the barrier coefficient of a solid partition is 0, and the maximum barrier coefficient of 1 is taken when there is no physical partition.

[0092] Ventilation connectivity features include airflow direction, ventilation window location, and ventilation exchange area between adjacent grids. The preset airflow diffusion coefficient table contains airflow diffusion coefficients corresponding to different ventilation connectivity features.

[0093] The posterior probabilities of disease and mass stress events in each grid are used as the initial intrinsic risk values ​​of the corresponding grids; the intrinsic retention coefficient is preset to characterize the degree of natural decay of the original risk of the grid with environmental regulation; the iteration termination condition is preset, including the maximum number of iterations and the change in global risk between two adjacent iterations being less than the convergence threshold; each iteration executes: (1) For each target grid, the risk diffusion of all adjacent grids is summarized: the risk value of the adjacent grid in the previous iteration × the disease transmission and transfer probability from the adjacent grid to the target grid; (2) The target grid update risk = intrinsic retention coefficient × the intrinsic risk value of the target grid in the previous iteration + the risk diffusion of all adjacent grids; (3) The updated grid risk value is subject to the range constraint [0,1] to avoid numerical overflow; the iteration continues until the iteration termination condition is met and the deduction is stopped; at this time, the risk value corresponding to each grid is the steady-state disease risk value.

[0094] By mapping the steady-state disease risk values ​​of each grid to the grid spatial coordinates, a spatial transmission risk distribution of diseases in pig houses is generated.

[0095] Based on the spatial propagation risk distribution, hierarchical early warning information and targeted biosafety control strategies are generated.

[0096] In a specific embodiment, a graded early warning information is generated: a multi-level threshold range of steady-state disease risk values ​​is preset, and low, medium, and high basic risk levels are divided according to the steady-state disease risk values ​​of each grid; the disease stress risk contribution values ​​corresponding to the combinations of environmental parameters within the same grid are retrieved, and environmental parameters with contribution values ​​greater than the preset contribution threshold are selected as the dominant environmental disturbance factors; the basic risk level and dominant environmental disturbance factors of each grid are integrated to construct graded early warning information.

[0097] Specifically, a pre-defined threshold range for grid-based steady-state disease risk values ​​is set for three basic risk levels: low, medium, and high. When the grid-based steady-state disease risk value is within the low-risk threshold range, it is determined to be at a low-risk level; when the grid-based steady-state disease risk value is within the medium-risk threshold range, it is determined to be at a medium-risk level; and when the grid-based steady-state disease risk value is within the high-risk threshold range, it is determined to be at a high-risk level.

[0098] Biosafety regulation strategy: Match the risk level and dominant environmental disturbance factor of each grid with the risk level and dominant environmental disturbance factor associated with each safety regulation strategy in the preset regulation strategy library. If the risk level and dominant environmental disturbance factor of a grid are completely consistent with the risk level and dominant environmental disturbance factor associated with a certain strategy in the regulation strategy library, then the matched preset biosafety regulation strategy is called as the targeted biosafety regulation strategy for that grid.

[0099] Among them, the biosafety control strategy library pre-stores special control measures corresponding to different risk levels and different environmental disturbance factors, including zoned ventilation control, environmental parameter correction, robot-intensified inspection, local disinfection, pig activity control, and cross-grid risk blocking, etc., to achieve precise biosafety control with one policy per grid and measures tailored to the specific circumstances.

[0100] Preferably, the graded early warning information and targeted biosafety control strategies are pushed to the execution terminal at the breeding site to implement environmental and disease prevention control. After the control measures are implemented, the sensor data of the pig house and the behavior data of the pig herd are collected again, and the steady-state disease risk value of each grid is calculated again to verify the control effect: if the steady-state disease risk value of the target grid falls back to the low-risk range, the control is deemed effective and the risk is eliminated; if the grid is still at the medium-risk or high-risk level, the control is deemed not to have effectively eliminated the risk, and the control strategy is automatically upgraded or the dominant environmental disturbance factor is re-identified to generate updated graded early warning information and biosafety control strategies. This process is repeated until the grid risk drops to the low-risk range.

[0101] Please see Figure 2 As shown, a dynamic monitoring and management system for pig farming environment based on environmental disease prevention includes: a monitoring unit for continuously collecting behavioral data of pigs in the pigsty through non-contact monitoring equipment.

[0102] The server includes a feature analysis unit, a risk location unit, a distribution analysis unit, and a security control unit.

[0103] The feature analysis unit is used to analyze the set of behavioral features of the pig herd using behavioral data of the pigs in the pigsty.

[0104] The risk location unit is used to construct a behavioral feature-environment association model based on historical regulatory records, match the behavioral feature set with the behavioral feature-environment association model to determine the set of suspected environmental anomalies, and locate the risk area corresponding to the set of suspected environmental anomalies based on the spatial distribution information of pigs in the pigsty.

[0105] The monitoring unit is also used to initiate targeted environmental monitoring of the risk area and investigation and monitoring of non-risk areas in response to the results of the model matching inference, and to obtain environmental parameter data of the risk area and non-risk area.

[0106] The distribution analysis unit is used to calculate the spatial transmission risk distribution of diseases within pigsties based on environmental parameter data of risk and non-risk areas, combined with information on the spatial layout of pigsties.

[0107] The safety control unit is used to generate graded early warning information and targeted biosafety control strategies based on the spatial propagation risk distribution.

[0108] The fundamental algorithmic architectures involved in this invention, such as dynamic Bayesian networks, Bayesian conditional probability formulas, maximum likelihood estimation, and expectation-maximization parameter learning, are all mature and conventional techniques in this field. Their general principles and standard implementation methods are well known to those skilled in the art, and this paper will not elaborate on the general internal computational processes of the fundamental algorithms. The core innovation of this invention is not the fundamental algorithms themselves, but rather, for the disease prevention scenario in pig farming environments, it constructs a temporal causal constraint mechanism of environment-pig behavior-disease, a dynamic weight quantification system, and a multimodal data closed-loop extrapolation link, taking into account the physiological time lag characteristics of the occurrence and spread of swine diseases, and realizing grid-based refined risk tracing and dynamic prediction of cross-spatial disease transmission.

[0109] The various preset values ​​and thresholds involved in this invention, including but not limited to various risk assessment thresholds, parameter fluctuation thresholds, contribution value thresholds, multi-level risk threshold ranges, and various coefficient comparison tables, are all pre-configured based on the range of pig house breeding environment parameters, pig behavior characteristics, disease transmission patterns, and on-site breeding conditions through historical sample training, experimental calibration, and empirical fitting. Various preset parameters can be adaptively fine-tuned according to different pig house structures, ventilation conditions, breeding breeds, breeding stages, and seasonal environmental changes. The aforementioned preset thresholds, ranges, and comparison tables are merely quantitative judgment benchmarks adapted to this technical solution and do not constitute a technical limitation of this invention. Those skilled in the art can reasonably assign and adapt values ​​according to actual application scenarios, and parameter adaptation can be completed without creative effort.

[0110] The examples described in this invention are not limited to the specific embodiments listed above. The examples are merely illustrative to facilitate understanding of the invention and do not constitute a limitation on the scope of protection of this invention. Any modifications, equivalent substitutions, etc., made within the spirit and principles of this invention should be included within the scope of protection.

[0111] The above description is merely an example and illustration of the concept of the present invention. Those skilled in the art can make various modifications or additions to the specific embodiments described or use similar methods to replace them, as long as they do not deviate from the concept of the invention or exceed the scope defined in this specification, they should all fall within the protection scope of the present invention.

Claims

1. A method for dynamic monitoring and management of pig farming environment based on environmental disease prevention, characterized in that, include: The behavioral data of pigs in the pigsty are continuously collected through non-contact monitoring equipment, and the behavioral characteristics of the pigs are analyzed. Based on historical monitoring records, a behavioral feature-environment association model is constructed. The behavioral feature set is matched with the behavioral feature-environment association model to determine the set of suspected environmental anomalies. Based on the spatial distribution information of pigs in the pigsty, the risk area corresponding to the set of suspected environmental anomalies is located. In response to the model matching inference results, targeted environmental monitoring of the risk area and investigation and monitoring of non-risk areas are initiated to obtain environmental parameter data of the risk area and non-risk area; Based on environmental parameter data of risk and non-risk areas, combined with information on the spatial layout of pig houses, the spatial transmission risk distribution of diseases within pig houses is calculated; Based on the spatial propagation risk distribution, hierarchical early warning information and targeted biosafety control strategies are generated.

2. The method for dynamic monitoring and management of pig farming environment based on environmental disease prevention according to claim 1, characterized in that, The specific process of analyzing the behavioral characteristic set of the pig herd is as follows: The pigsty is divided into grids and the grids are numbered. Infrared high-definition cameras and depth vision cameras are installed above and to the sides of each grid area to collect full-area video streams and depth image data. The data collection time sequence is synchronized with the pigsty grid environment monitoring data. Based on full-domain video streams and depth image data, individual pigs are identified through instance segmentation combined with multi-object tracking algorithms, and each pig is assigned a unique identifier ID. Visual behavioral features of each pig are extracted through a deep learning model. At the same time, sound processing technology is used to collect audio signals from the pigsty, and acoustic features are extracted from the audio signals. The acoustic features are associated and matched with the corresponding individual IDs based on the spatial coordinates of the pigs. The visual behavioral features and acoustic features are fused to obtain the quantitative behavioral features of a single pig. The individual behavioral characteristics of all pigs in each grid are summarized to form a set of behavioral characteristics of the corresponding pig herd.

3. The method for dynamic monitoring and management of pig farming environment based on environmental disease prevention according to claim 1, characterized in that, The specific process for constructing the behavioral feature-environment association model is as follows: Each historical monitoring record is bound to a spatial grid number and a unified timestamp, and includes grid environmental parameter data, the set of pig herd behavior characteristics for the corresponding grid, and historical disease and stress event tags; Historical monitoring records were cleaned and normalized, environmental effect time lag windows were configured, and a paired sample set of environmental parameters and lagging pig herd behavior characteristics within the same grid was constructed. A directed correlation network is constructed based on a paired sample set: environmental parameters are used as exogenous influence nodes, pig herd behavior characteristics are used as intermediate response nodes, and disease and stress labels are used as terminal result nodes. A one-way transmission path of multi-environment coupling effect → abnormal pig herd behavior deviation → group stress and disease is constructed. Directed causal edges between nodes are established and the dynamic weights of each causal edge are solved. By eliminating redundant causal edges in the network through saliency screening and retaining the salient causal transmission topology, a directed correlation model of behavioral features and environment is obtained.

4. The method for dynamic monitoring and management of pig farming environment based on environmental disease prevention according to claim 3, characterized in that, The specific process of constructing a paired sample set of environmental parameters and lagging pig herd behavioral characteristics within the same grid is as follows: The global time delay interval is preset based on the physiological stress patterns of pigs. And preset a fixed time step ; Traverse all discrete lag times within the interval ; Using grid number as the primary matching constraint, pairing of data within the same grid is only allowed; environmental parameter data collected at time t within the same grid is matched with the pig herd behavior characteristics at time t+T of that grid to form time series sample pairs of preceding environmental parameters and lagging behavior characteristics. Further search the event records of this grid within the preset observation window after t+T, and assign corresponding historical epidemic and stress event labels; Only data sets with complete and unmissing time series are retained, and these are aggregated to obtain a paired sample set of environmental parameter data with event labels and lagging pig herd behavioral characteristics.

5. A method for dynamic monitoring and management of pig farming environment based on environmental disease prevention according to claim 3, characterized in that, The specific process for solving the dynamic weights of each causal edge is as follows: A dynamic Bayesian network is used to parameterize the directed correlation network. A static initial topology is learned using a hybrid algorithm of score search and constraint testing based on single-time-slice data, with the Bayesian information criterion as the scoring function. This is extended to the temporal dimension to learn cross-time transition edges, with the optimal lag step search range limited to a preset global environment effect lag interval. Maximum likelihood estimation or expectation-maximization algorithms are used to complete parameter learning, obtaining the conditional probability matrix for the same time slice and the cross-time-slice transition probability matrix. The causal dependency strength represented by the probability is then transformed into dynamic weights corresponding to each causal edge. Based on forward causal reasoning using dynamic Bayesian networks, the influence intensity and optimal lag time of single and multiple environmental parameters on abnormal behavioral characteristics of pig herds are quantified, and the contribution value of disease stress risk corresponding to each combination of environmental parameters is calculated along the transmission path.

6. The method for dynamic monitoring and management of pig farming environment based on environmental disease prevention according to claim 1, characterized in that, The specific process for determining the set of suspected environmental anomaly types is as follows: The set of pig herd behavioral features is standardized and transformed into a multi-dimensional behavioral feature vector with a unified dimension. Then, it is input into the behavioral feature-environment association model to start the multi-dimensional causal matching mechanism. The similarity between the multi-dimensional behavioral feature vector and each behavioral feature in the model is calculated one by one. Combined with the causal mapping relationship of the model, the initial matching degree score of each environmental parameter perturbation corresponding to the multi-dimensional behavioral feature is solved. When any abnormal behavioral feature is identified and activated, Bayesian posterior probability backward inference is carried out based on the forward causal topology of the dynamic Bayesian network, traversing all environmental parameter transmission paths that can induce the shift of multidimensional behavioral feature vectors. Unlike the independent judgment method of a single behavioral feature, all pig herd behavioral features in the same grid are regarded as the overall observation evidence set. Relying on the coupling weight of multiple environmental parameters in the dynamic Bayesian network and the dynamic weight of each causal edge, the joint probability of behavioral anomalies corresponding to all environmental parameter perturbations is accumulated and calculated. Based on the environmental parameter perturbation state mapping, the corresponding candidate environmental anomaly types are obtained, and the comprehensive evidence weight of the pig herd behavioral feature set for each candidate environmental anomaly type is obtained. Based on the comprehensive evidence weight, all candidate environmental anomaly types are sorted in descending order to obtain a set of suspected environmental anomaly types with confidence levels from high to low.

7. A method for dynamic monitoring and management of pig farming environment based on environmental disease prevention according to claim 1, characterized in that, The specific process for locating the risk area corresponding to the set of suspected environmental anomalies is as follows: Based on the unique ID and real-time spatial coordinates of each pig obtained through visual tracking, the grid number to which each pig belongs is matched. The target grid corresponding to the set of suspected environmental anomalies obtained through reasoning, and the set of pig herd behavior characteristics generated, is used as the initial candidate risk grid. Extract the location distribution of all pigs within the initial candidate risk grid, and simultaneously obtain the behavioral feature set of pigs in adjacent grids and the cross-grid activity trajectory of pigs. Combine the degree of behavioral offset between adjacent grids with the individual movement trajectory to calculate the correlation degree of behavioral anomalies between grids. Adjacent grids with a correlation degree greater than a preset correlation degree of abnormal behavior are included in the risk region, and together with the initial candidate risk grids, they constitute the risk region. Output the spatial extent of the risk area, which is composed of grid number and spatial coordinate boundary.

8. The method for dynamic monitoring and management of pig farming environment based on environmental disease prevention according to claim 1, characterized in that, The specific process for targeted environmental monitoring of the risk areas and screening and monitoring of non-risk areas is as follows: Targeted environmental monitoring: Based on the set of suspected environmental anomalies, basic environmental parameters and high-order environmental parameters are obtained; basic environmental parameters are collected intensively using an array of environmental sensors deployed in the risk area; for high-order environmental parameters, inspection robots equipped with corresponding monitoring sensors are used to perform high-density multi-point patrol monitoring in the risk area. Screening and monitoring: Use an array of environmental sensors deployed in non-risk areas to collect basic environmental parameters at a regular sampling frequency.

9. A method for dynamic monitoring and management of pig farming environment based on environmental disease prevention according to claim 8, characterized in that, The specific process for calculating the spatial transmission risk distribution of the disease within the pigsty is as follows: Environmental parameter data for each grid in both risk and non-risk areas are input into the behavioral feature-environment association model to calculate the posterior probability of disease outbreaks and mass stress events occurring in each grid. The posterior probability of disease outbreaks and mass stress events occurring in each grid is bound to the spatial coordinates of the corresponding grid. Extract the partition structure and ventilation connectivity features of each grid from the spatial layout information of the pigsty, and calculate the probability of cross-grid disease transmission and transfer between grids; use the probability of disease and mass stress events in each grid as the initial endogenous risk value of the grid, and combine it with the probability of disease transmission and transfer between grids to carry out spatial diffusion extrapolation, and iteratively solve to obtain the steady-state disease risk values ​​of all grids; By mapping the steady-state disease risk values ​​of each grid to the grid spatial coordinates, a spatial transmission risk distribution of diseases in pig houses is generated.

10. A system for implementing the dynamic monitoring and management method for pig farming environment based on environmental disease prevention as described in any one of claims 1-9, characterized in that, include: The monitoring unit is used to continuously collect behavioral data of pigs in the pigsty through non-contact monitoring equipment; The server includes a feature analysis unit, a risk location unit, a distribution analysis unit, and a security control unit; The feature analysis unit is used to analyze the set of behavioral features of the pig herd using behavioral data of the pigs in the pigsty. The risk location unit is used to construct a behavioral feature-environment association model based on historical regulatory records, match the behavioral feature set with the behavioral feature-environment association model, determine the set of suspected environmental anomalies, and locate the risk area corresponding to the set of suspected environmental anomalies based on the spatial distribution information of pigs in the pigsty. The monitoring unit is also used to initiate targeted environmental monitoring of the risk area and investigation and monitoring of non-risk areas in response to the model matching inference results, and to obtain environmental parameter data of the risk area and non-risk area; The distribution analysis unit is used to calculate the spatial transmission risk distribution of diseases within pigsties based on environmental parameter data of risk and non-risk areas, combined with information on the spatial layout of pigsties. The safety control unit is used to generate graded early warning information and targeted biosafety control strategies based on the spatial propagation risk distribution.

Citation Information

Patent Citations

  • Pig house environment regulation and control optimization method and system

    CN120802638A

  • Cold region pig breeding environment management method and system based on Internet of Things

    CN121481759A