Sow feeding method and system based on big data analysis

By collecting sow data in real time and using big data analytics to generate individualized feeding instructions, the problem of the inability to dynamically adjust feeding strategies in existing technologies has been solved, enabling personalized feeding management for sows and improving feeding efficiency and accuracy.

CN120823648AInactive Publication Date: 2025-10-21SU ZHOU HUI MU WU LIAN WANG YOU XIAN GONG SI +2
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510978981.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-07-16
Publication Date
2025-10-21
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

Current sow feeding methods fail to accurately capture individual dynamic data, resulting in an inability to dynamically adjust feeding strategies, wasting resources, and impacting health and production performance.

Method used

By collecting real-time location information and behavioral data of sows, big data analysis technology is used to extract behavioral patterns related to physiological cycles, generate individualized feeding instructions, and use automated equipment to provide precise feeding at the optimal time and location.

Benefits of technology

It enables personalized feeding management for sows, improves feeding efficiency and precision, reduces resource waste, and ensures sow health and production performance.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120823648A_ABST
    Figure CN120823648A_ABST
Patent Text Reader

Abstract

The invention belongs to the field of animal production in animal husbandry, and discloses a sow feeding method and system based on big data analysis, and the method comprises the steps: collecting a data flow related to the position information and behavior state of each sow in real time, and obtaining a preliminary individual activity data set; according to the preliminary individual activity data set, analyzing the behavior state of each sow by adopting a data cleaning and feature extraction technology, separating out key behavior patterns related to physiological cycle changes, and determining activity feature sets of each sow in different time periods; performing comprehensive evaluation on behavior performance of each sow in a specific environment by deeply processing an activity feature set and combining external data input influenced by environmental factors to obtain an individualized feeding instruction; and according to the individualized feeding instruction, feeding the sow at the appointed position and in the time window. According to the invention, intelligent analysis and personalized feeding management of sow behaviors are realized, and the feeding efficiency and accuracy are effectively improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of animal production in animal husbandry, and in particular relates to a sow feeding method and system based on big data analysis. Background Art

[0002] In modern animal husbandry, sow feeding management is a crucial research area, directly linked to breeding efficiency and animal health, and crucial for ensuring food safety and improving economic returns. As breeding scale expands, the question of how to scientifically and rationally meet the individual needs of each sow has become a key direction for the industry's development.

[0003] However, current mainstream feeding methods often have significant limitations. These methods often rely on standardized feeding plans that ignore individual differences between sows. This makes it difficult to dynamically adjust strategies to the complex physiological cycles and environmental changes. This static, unified management not only wastes resources but can also affect sow health and production performance due to the inability to adapt to individual conditions, thereby increasing breeding risks.

[0004] Against this backdrop, the field faces significant technical challenges. The core issue lies in accurately capturing each sow's real-time status data, including location and behavioral information, and translating this data into effective feeding decisions. Due to a lack of in-depth analysis of individual dynamic data, existing systems often fail to accurately determine the specific needs of each sow at different times and locations. This underutilization of data further complicates the optimization of feeding locations and time windows, a pressing challenge. Only by providing the appropriate feed amount and nutrient ratio at the right time and place can truly personalized management be achieved.

[0005] Therefore, how to dynamically determine the optimal feeding position and time window for each sow through real-time data collection and analysis, and thereby achieve accurate personalized feeding management, becomes a key issue of the present invention. Summary of the Invention

[0006] To solve the problems existing in the prior art, the present invention provides a sow feeding method and system based on big data analysis, which realizes intelligent analysis of sow behavior and personalized feeding management, effectively improves feeding efficiency and accuracy, and provides advanced intelligent solutions for large-scale pig farms.

[0007] To achieve the above object, the present invention provides the following solutions:

[0008] A sow feeding method based on big data analysis, the method comprising:

[0009] Collect data streams related to each sow’s location information and behavioral status in real time to obtain a preliminary individual activity dataset;

[0010] Based on the preliminary individual activity data set, data cleaning and feature extraction techniques were used to analyze the behavioral state of each sow, isolate key behavioral patterns related to physiological cycle changes, and determine the activity feature sets of each sow in different time periods;

[0011] By deeply processing the activity feature set and combining it with external data inputs on environmental factors, we can comprehensively evaluate the behavior of each sow in a specific environment and obtain individualized feeding instructions.

[0012] Feed is delivered to sows within designated locations and time windows according to individual feeding instructions.

[0013] Preferably, the method for collecting data streams related to the location information and behavioral status of each sow in real time to obtain a preliminary individual activity data set includes:

[0014] The improved OpenPose algorithm is used to build a sow posture estimation model;

[0015] Based on the sow posture estimation model, the skeleton joints of each sow are extracted from the video stream image, and the behavioral characteristics of each sow are described by calculating the joint distance and skeleton joint angle;

[0016] The K-nearest neighbor algorithm was used to classify the behavior of each sow.

[0017] Preferably, based on the preliminary individual activity data set, data cleaning and feature extraction techniques are used to analyze the behavioral state of each sow, isolate key behavioral patterns related to physiological cycle changes, and determine the activity feature set of each sow in different time periods. The method includes:

[0018] Step 1: Obtain original records from individual activity data, use data cleaning methods to remove noise and outliers, and perform interpolation processing for missing data to obtain a cleaned activity dataset;

[0019] Step 2: Based on the cleaned activity data set, feature extraction technology is used to separate the behavioral state features related to individual sows. Activity data within different time periods are segmented and processed to determine the preliminary behavioral state set.

[0020] Step 3: Analyze the key behavioral features related to the physiological cycle through the preliminary behavioral state set. If the frequency or intensity of a behavioral state exceeds the preset threshold, it will be marked as a key behavior to obtain the key behavior data set;

[0021] Step 4: Based on the key behavior dataset and the activity characteristics within the time period, a behavior pattern classification model is constructed to classify the behavior patterns and determine the set of behavior patterns related to periodic changes.

[0022] Step 5: Based on the classified behavioral pattern set, extract activity features that are highly correlated with physiological cycle changes. If a feature shows consistent changes in multiple time periods, classify it into the core feature set and determine the core activity feature;

[0023] Step 6: Analyze the changing trends of individual sows' behavioral states over different time periods using core activity characteristics. Perform time series analysis on these changing trends to obtain a set of activity characteristics corresponding to physiological cycle changes.

[0024] Step 7: Based on the activity feature set, integrate key behavior and behavior pattern data to build a complete individual activity feature library. Standardize the feature library to determine whether the final feature set meets the expected classification criteria and obtain the final analysis results.

[0025] Preferably, for the key behavior data set, combining the activity characteristics within a time period, building a behavior pattern classification model, classifying the behavior patterns, and determining the behavior pattern set related to periodic changes include:

[0026] Input the input behavior sequence X into the CNN layer to extract local features;

[0027] Input local features into BiLSTM to obtain bidirectional hidden states;

[0028] The bidirectional hidden state is weighted by the attention mechanism and the final feature is output;

[0029] The final features are input into the fully connected layer for classification to obtain a set of behavioral patterns related to periodic changes.

[0030] Preferably, the method of obtaining individualized feeding instructions by comprehensively evaluating the behavior of each sow in a specific environment through in-depth processing of the activity feature set and combining it with external data input of environmental factors includes:

[0031] By deeply processing the activity feature set and combining it with external data inputs on environmental factors, we can comprehensively evaluate the behavior of each sow in a specific environment and determine its current priority needs.

[0032] If the demand priority ranking shows that a sow is in high demand, the location information acquisition module will track its specific location coordinates in the farm in real time to obtain a dynamic location distribution map;

[0033] Based on the dynamic position distribution map and the preset rules for time window optimization, the most suitable feeding time interval is calculated for each sow's current position and activity characteristics, and the optimal time window range is determined;

[0034] By outputting the optimal time window range and combining it with the goal of precise feeding management, the corresponding feed ratio and feeding amount plan are generated according to the personalized needs of each sow, and individualized feeding instructions are obtained.

[0035] Preferably, by deeply processing the activity feature set and combining it with external data input of environmental factors, a comprehensive evaluation is conducted on the behavior of each sow in a specific environment to determine its current demand priority. The method includes:

[0036] By collecting activity characteristics, sensor equipment is used to obtain daily activity data of each sow to form an initial activity data set;

[0037] Based on the initial activity data set, the environmental factor information in the external data is integrated and the pre-established feature extraction model is used to obtain the behavioral performance feature set of each sow in a specific environment.

[0038] Based on the behavioral performance feature set and the influence of a specific environment, if certain behavioral indicators in the feature set exceed the preset threshold, they will be marked as abnormal and the abnormal behavior pattern will be determined;

[0039] By comparing abnormal and normal behavior patterns, the random forest model in machine learning is used to determine the current demand category of each sow;

[0040] Based on the current demand category and combined with comprehensive evaluation logic, if the urgency of a demand category is higher than the preset standard, its priority will be increased to obtain the preliminary demand prioritization results;

[0041] Based on the preliminary demand prioritization results, the environmental factor adjustment coefficient after in-depth analysis is integrated to obtain the final demand priority list;

[0042] By continuously updating the final demand priority list and adopting a scheduled data refresh mechanism, we can determine whether the demand priority has changed and form a dynamically adjusted priority sequence.

[0043] Preferably, the position information acquisition module is a real-time computer vision tracking system for pigs in a piggery, which consists of a camera and a PC. The computer runs a tracking algorithm to estimate the position and identity of the pig. The tracking algorithm is divided into two steps: the first step is to establish a support map that points to the initial pig segment in each video frame; the second step is to use the support map segmentation to establish a 5D-Gaussian model of the pig, that is, the position and shape; the system has software to correct for fisheye distortion from the camera lens.

[0044] Preferably, based on the dynamic position distribution map and the preset rules for time window optimization, the most suitable feeding time interval is calculated for each sow's current position and activity characteristics. The method for determining the optimal time window range includes:

[0045] By obtaining the current location data of each sow from the dynamic location distribution map and combining it with the real-time recording of activity characteristics, an individualized location and behavior data set is formed, and preliminary activity pattern analysis results are obtained;

[0046] Based on the preliminary activity pattern analysis results, the activity characteristics of individual sows are classified using preset conditions, and the appropriate feeding time range for each individual is determined by combining the optimization rules of the time window;

[0047] For the determined suitable feeding time range, obtain the position change trend data in the distribution graph. If the position change trend shows that the individual is active during a specific time period, adjust the time interval to a period with lower activity and lock the adjusted time interval;

[0048] By performing a secondary verification on the adjusted time interval, the matching degree between the historical feeding data and the current activity characteristics is obtained. If the matching degree is lower than the preset threshold, the time interval is recalculated to obtain a feeding schedule that better meets individual needs;

[0049] Based on the recalculated feeding schedule and the constraints of the optimal window, a logistic regression model is used to evaluate the stability of the time interval to determine whether the final feeding time window meets the optimization rules;

[0050] Through the evaluated feeding time window, the behavioral feedback data of the individual sow in the current position is obtained. If the feedback data indicates abnormal behavior, the fine-tuning mechanism of the time interval is triggered to determine the final adaptive time range;

[0051] Based on the final adaptation time range, a personalized feeding plan is generated for each sow. Combined with the continuous update of dynamic position and activity characteristics, the real-time applicability of the plan is judged to form a closed-loop mechanism for dynamic adjustment.

[0052] Preferably, by outputting the optimal time window range and combining it with the goal of precise feeding management, a corresponding feed ratio and feeding amount plan is generated for each sow's individual needs, and a method for obtaining individualized feeding instructions includes:

[0053] By obtaining each sow's historical feeding records and health status data from the data storage and combining them with the time window constraints, a preliminary individualized demand range is determined;

[0054] Based on the preliminary individualized demand range, the pre-established nutritional demand model is used to calculate the basic feed ratio value for each sow in the current time window and obtain the corresponding nutrient composition combination;

[0055] Based on the nutritional composition, the current inventory of feed raw materials is obtained. If the inventory of a certain raw material is lower than the preset threshold, the raw material ratio in the ratio scheme is adjusted to determine the final feed ratio result;

[0056] Based on the final feed ratio results, combined with the sow's individual needs and the optimal range within the time window, the feeding plan for each sow is calculated to obtain specific feeding data;

[0057] Generate personalized feeding instructions for each sow based on feeding data, use an automated system to format the instructions, and determine the execution order and timing of the instructions;

[0058] Obtain the execution order and time points of the instructions, combine them with the management goal of precise feeding, and verify the instructions through preset logical rules. If it is found that the instructions do not meet the management goals, the feeding amount data will be readjusted to obtain the optimized feeding instructions;

[0059] The optimized feeding instructions are transmitted to the automated feeding equipment, and the sow feeding records in the data storage are updated synchronously, completing the closed-loop processing of the entire personalized feeding process.

[0060] The present invention also provides a sow feeding system based on big data analysis, the system is used to implement the above method, the system includes: a collection module, an analysis module, an evaluation module and a delivery module;

[0061] The acquisition module is used to collect data streams related to the location information and behavioral status of each sow in real time to obtain a preliminary individual activity data set;

[0062] The analysis module is used to analyze the behavioral state of each sow based on the preliminary individual activity data set, using data cleaning and feature extraction technology, to separate key behavioral patterns related to physiological cycle changes, and determine the activity feature set of each sow in different time periods;

[0063] The evaluation module is used to comprehensively evaluate the behavior of each sow in a specific environment by deeply processing the activity feature set and combining it with external data input of environmental factors to obtain individualized feeding instructions;

[0064] The delivery module is used to deliver feed to sows within a specified location and time window according to individualized feeding instructions.

[0065] Compared with the prior art, the present invention has the following beneficial effects:

[0066] The present invention discloses a sow feeding method and system based on big data analysis. The method collects sow activity data in real time, extracts key behavioral patterns, and evaluates demand priorities in combination with environmental factors. For sows in a high-demand state, the present invention tracks their location and generates a dynamic distribution map, and then calculates the optimal feeding time window. Based on individual needs, the present invention generates customized feed ratios and delivery plans, and uses automated equipment to perform precise feeding at designated times and locations. The present invention realizes intelligent analysis of sow behavior and personalized feeding management, effectively improves feeding efficiency and accuracy, and provides advanced intelligent solutions for large-scale pig farms. BRIEF DESCRIPTION OF THE DRAWINGS

[0067] In order to more clearly illustrate the technical solution of the present invention, the following briefly introduces the drawings required for use in the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.

[0068] Figure 1 This is a flow chart of a sow feeding method based on big data analysis according to an embodiment of the present invention;

[0069] Figure 2 Schematic diagram of the structure of the CSP module according to an embodiment of the present invention. DETAILED DESCRIPTION

[0070] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of the present invention.

[0071] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, the present invention is further described in detail below with reference to the accompanying drawings and specific embodiments.

[0072] Example 1

[0073] like Figure 1 As shown, the present invention provides a sow feeding method based on big data analysis, the method comprising:

[0074] Collect data streams related to each sow’s location information and behavioral status in real time to obtain a preliminary individual activity dataset;

[0075] Based on the preliminary individual activity data set, data cleaning and feature extraction techniques were used to analyze the behavioral state of each sow, isolate key behavioral patterns related to physiological cycle changes, and determine the activity feature sets of each sow in different time periods;

[0076] By deeply processing the activity feature set and combining it with external data inputs on environmental factors, we can comprehensively evaluate the behavior of each sow in a specific environment and obtain individualized feeding instructions.

[0077] Feed is delivered to sows within designated locations and time windows according to individual feeding instructions.

[0078] In this embodiment, the method for collecting data streams related to the location information and behavioral status of each sow in real time to obtain a preliminary individual activity data set includes:

[0079] The improved OpenPose algorithm is used to build a sow posture estimation model;

[0080] Based on the sow posture estimation model, the skeleton joints of each sow are extracted from the video stream image, and the behavioral characteristics of each sow are described by calculating the joint distance and skeleton joint angle;

[0081] The K-nearest neighbor algorithm was used to classify the behavior of each sow.

[0082] Among them, OpenPose network improvement: In the original OpenPose model, the modified CSP-Darknet is used as the feature extraction network of the model. CSPDarknet is mainly composed of several cross-stage partial modules (CSP). The structure of the CSP module is as follows Figure 2As shown. The CSP module uses several 1x1 convolution kernels for convolution, and adds a residual block, which effectively improves the nonlinearity of the model, alleviates the problems of gradient disappearance and gradient explosion, and allows the network to be built deeper. In addition, the CSP module fuses deep features and shallow features to improve the recognition ability of targets of different sizes. Through the above analysis, the present invention draws on the advantages of the CSPDarknet network structure, improves the original feature extraction network of OpenPose, and introduces spatial pyramid pooling (SPP) at the end of the feature extraction network to achieve the fusion of local features and global features and the unification of the output feature map size.

[0083] The present invention selects 15 groups of joint point spacings and 10 groups of skeletal joint angles as the characteristics of sow behavior. Taking two segments of bones AC and BC as an example, the corresponding key point coordinates are A(x1, y1), B(x2, y2) and C(x3, y3), respectively. The joint angle θ can be calculated by formula (1).

[0084]

[0085] The joint spacing can be calculated using formula (2).

[0086]

[0087] Where: Lk 表 shows the distance between joints numbered k, (x i ,y i ) and (x j ,y j ) represents the joint point coordinates. Since different body shapes have an impact on the joint spacing, the present invention normalizes all joint spacings. The normalized joint spacing L k-Norm It can be calculated by formula (3).

[0088]

[0089] Where: max(L) represents the maximum joint distance of the individual.

[0090] The present invention uses the Knn algorithm to classify sow behavior. The idea of ​​the Knn algorithm is simple. When an unknown sample is input, the category of the unknown sample is determined by the category with the larger proportion among the K samples closest to the unknown sample. The present invention uses the Euclidean distance to represent the distance between the unknown sample and the known sample. The distance between two points x1(x 11 , x 12 ,…,x 1n ) and x2(x 21 , x22 ,…x 2n ) is calculated as shown in formula (4).

[0091]

[0092] Different values ​​of K in the Knn algorithm can affect the final classification results for unknown samples. When K is too small, the neighborhood space is very small, the approximate error of learning decreases, and the estimation error increases. Larger values ​​of K have the opposite effect. During the experiment, the present invention normalized the values ​​of all sample features and determined the K value through cross-validation.

[0093] In this embodiment, based on a preliminary individual activity data set, data cleaning and feature extraction techniques are used to analyze the behavioral state of each sow, isolate key behavioral patterns related to physiological cycle changes, and determine the activity feature set of each sow in different time periods. The method includes:

[0094] Step 1: Obtain original records from individual activity data, use data cleaning methods to remove noise and outliers, and perform interpolation processing for missing data to obtain a cleaned activity dataset;

[0095] Step 2: Based on the cleaned activity data set, feature extraction technology is used to separate the behavioral state features related to individual sows. Activity data within different time periods are segmented and processed to determine the preliminary behavioral state set.

[0096] Step 3: Analyze the key behavioral features related to the physiological cycle through the preliminary behavioral state set. If the frequency or intensity of a behavioral state exceeds the preset threshold, it will be marked as a key behavior to obtain the key behavior data set;

[0097] Step 4: Based on the key behavior dataset and the activity characteristics within the time period, a behavior pattern classification model is constructed to classify the behavior patterns and determine the set of behavior patterns related to periodic changes.

[0098] Step 5: Based on the classified behavioral pattern set, extract activity features that are highly correlated with physiological cycle changes. If a feature shows consistent changes in multiple time periods, classify it into the core feature set and determine the core activity feature;

[0099] Step 6: Analyze the changing trends of individual sows' behavioral states over different time periods using core activity characteristics. Perform time series analysis on these changing trends to obtain a set of activity characteristics corresponding to physiological cycle changes.

[0100] Step 7: Based on the activity feature set, integrate key behavior and behavior pattern data to build a complete individual activity feature library. Standardize the feature library to determine whether the final feature set meets the expected classification criteria and obtain the final analysis results.

[0101] When analyzing key behavioral characteristics related to the menstrual cycle, we can focus on changes in behavior frequency and intensity. For example, if a sow frequently engages in short, rapid movements within a specific time period, and the duration exceeds the threshold of the normal range, for example, such behavior occurs more than five times per day, each lasting more than 10 minutes, then this behavior can be marked as a key behavior. This marking helps identify important activity patterns related to the menstrual cycle.

[0102] Specifically, for key behavior data sets, combined with activity characteristics within a time period, a behavior pattern classification model is constructed to classify behavior patterns and determine the set of behavior patterns related to periodic changes. The methods include:

[0103] Input data representation: Assume that the input is a behavior sequence X = {x1, x2, ..., x T},in is the d-dimensional feature vector (such as location, timestamp, behavior type) of the t-th time step.

[0104] CNN layer: local feature extraction: convolution operation uses a one-dimensional convolution kernel (window size k) extract local pattern: h t =ReLU(W c ·x t:t+k-1 +b c ) where x t:t+k-1 is the feature slice of the t-th window, b c The pooling operation reduces the dimension by using the Max Pooling: p i =max(h i·s:i·s+m ), s is the step size, m is the pooling window size, and finally the local feature sequence P = {p1, p2, ..., p L}.

[0105] BiLSTM layer: long-term dependency modeling: forward LSTM calculates the forward hidden state

[0106] Backward LSTM similarly calculates the backward hidden state (Process sequence in reverse).

[0107] The final hidden state of bidirectional fusion is bidirectional splicing:

[0108] Period Sensitivity Module (Attention Mechanism): Attention Weight Calculation: To enhance period features (such as weekday / weekend differences), an attention mechanism is introduced:

[0109] Weighted feature representation:

[0110] Output layer: Behavior pattern classification: output classification probability through the fully connected layer The loss function uses cross entropy:

[0111] Among them, k is the convolution kernel size, d is the input feature dimension, L is the CNN output length, W a is the attention weight matrix, d h is the LSTM hidden layer dimension.

[0112] In this embodiment, the method for obtaining individualized feeding instructions by comprehensively evaluating the behavior of each sow in a specific environment through in-depth processing of the activity feature set and combining it with external data input of environmental factors includes:

[0113] By deeply processing the activity feature set and combining it with external data inputs on environmental factors, we can comprehensively evaluate the behavior of each sow in a specific environment and determine its current priority needs.

[0114] If the demand priority ranking shows that a sow is in high demand, the location information acquisition module will track its specific location coordinates in the farm in real time to obtain a dynamic location distribution map;

[0115] Based on the dynamic position distribution map and the preset rules for time window optimization, the most suitable feeding time interval is calculated for each sow's current position and activity characteristics, and the optimal time window range is determined;

[0116] By outputting the optimal time window range and combining it with the goal of precise feeding management, the corresponding feed ratio and feeding amount plan are generated according to the personalized needs of each sow, and individualized feeding instructions are obtained.

[0117] Among them, through in-depth processing of activity feature sets, combined with external data input of environmental factors, a comprehensive assessment of each sow's behavior in a specific environment is conducted to determine its current demand priority. The following methods are included:

[0118] By collecting activity characteristics, sensor equipment is used to obtain daily activity data of each sow to form an initial activity data set;

[0119] Based on the initial activity data set, the environmental factor information in the external data is integrated and the pre-established feature extraction model is used to obtain the behavioral performance feature set of each sow in a specific environment.

[0120] Based on the behavioral performance feature set and the influence of a specific environment, if certain behavioral indicators in the feature set exceed the preset threshold, they will be marked as abnormal and the abnormal behavior pattern will be determined;

[0121] By comparing abnormal and normal behavior patterns, the random forest model in machine learning is used to determine the current demand category of each sow;

[0122] Based on the current demand category and combined with comprehensive evaluation logic, if the urgency of a demand category is higher than the preset standard, its priority will be increased to obtain the preliminary demand prioritization results;

[0123] Based on the preliminary demand prioritization results, the environmental factor adjustment coefficient after in-depth analysis is integrated to obtain the final demand priority list;

[0124] By continuously updating the final demand priority list and adopting a scheduled data refresh mechanism, we can determine whether the demand priority has changed and form a dynamically adjusted priority sequence.

[0125] The location information acquisition module is a real-time computer vision tracking system for pigs in a piggery. This system will reduce the workload of farmers in identifying and locating individual sows. The system consists of a camera and a PC. The computer runs a tracking algorithm to estimate the position and identity of the pigs. The tracking algorithm is divided into two steps. The first step is to build a support map that points to the initial pig segment in each video frame. The second step is to use the support map segmentation to build a 5D-Gaussian model of the pig (i.e., position and shape). The system has software to correct for fisheye distortion from the camera lens. The fisheye lens allows the camera to monitor a larger area in the piggery. The algorithm was developed in MatLab, implemented in C language, and runs in real time. The system can track at least three pigs for a longer period of time (more than 8 minutes) without losing the trajectory and identity of individual pigs in real-world experiments.

[0126] For each support graph, it can be assumed that the xy coordinates and rgb space are unrelated, then the updated parameters of the 5D model are:

[0127]

[0128] To avoid this distortion, we use the correction algorithm described in Altera (2008). The basic idea is to map points from the fisheye projection (in this case, an isotropic projection) to a pinhole camera projection (a rectilinear projection). This amount replicates the RGB values ​​in the original fisheye image at the pixel position (xf ,y f ) to the pixel position (x) in the rectilinear (rectified) image p ,y p ). (x f ,y f ) and (x p ,y p ) is represented by:

[0129]

[0130] and

[0131]

[0132] where

[0133]

[0134] and f is the focal length in pixels which can be calculated as

[0135]

[0136] Among them, FOV horz is the field of view, and W is the pixel width of the image.

[0137] Among them, based on the dynamic position distribution map and the preset rules for time window optimization, the most suitable feeding time interval is calculated for each sow's current position and activity characteristics. The method for determining the optimal time window range includes:

[0138] By obtaining the current location data of each sow from the dynamic location distribution map and combining it with the real-time recording of activity characteristics, an individualized location and behavior data set is formed, and preliminary activity pattern analysis results are obtained;

[0139] Based on the preliminary activity pattern analysis results, the activity characteristics of individual sows are classified using preset conditions, and the appropriate feeding time range for each individual is determined by combining the optimization rules of the time window;

[0140] For the determined suitable feeding time range, obtain the position change trend data in the distribution graph. If the position change trend shows that the individual is active during a specific time period, adjust the time interval to a period with lower activity and lock the adjusted time interval;

[0141] By performing a secondary verification on the adjusted time interval, the matching degree between the historical feeding data and the current activity characteristics is obtained. If the matching degree is lower than the preset threshold, the time interval is recalculated to obtain a feeding schedule that better meets individual needs;

[0142] Based on the recalculated feeding schedule and the constraints of the optimal window, a logistic regression model is used to evaluate the stability of the time interval to determine whether the final feeding time window meets the optimization rules;

[0143] Through the evaluated feeding time window, the behavioral feedback data of the individual sow in the current position is obtained. If the feedback data indicates abnormal behavior, the fine-tuning mechanism of the time interval is triggered to determine the final adaptive time range;

[0144] Based on the final adaptation time range, a personalized feeding plan is generated for each sow. Combined with the continuous update of dynamic position and activity characteristics, the real-time applicability of the plan is judged to form a closed-loop mechanism for dynamic adjustment.

[0145] Among them, by outputting the optimal time window range and combining it with the goal of precise feeding management, the corresponding feed ratio and feeding amount plan is generated according to the individual needs of each sow. The method of obtaining individualized feeding instructions includes:

[0146] By obtaining each sow's historical feeding records and health status data from the data storage and combining them with the time window constraints, a preliminary individualized demand range is determined;

[0147] Based on the preliminary individualized demand range, the pre-established nutritional demand model is used to calculate the basic feed ratio value for each sow in the current time window and obtain the corresponding nutrient composition combination;

[0148] Based on the nutritional composition, the current inventory of feed raw materials is obtained. If the inventory of a certain raw material is lower than the preset threshold, the raw material ratio in the ratio scheme is adjusted to determine the final feed ratio result;

[0149] Based on the final feed ratio results, combined with the sow's individual needs and the optimal range within the time window, the feeding plan for each sow is calculated to obtain specific feeding data;

[0150] Generate personalized feeding instructions for each sow based on feeding data, use an automated system to format the instructions, and determine the execution order and timing of the instructions;

[0151] Obtain the execution order and time points of the instructions, combine them with the management goal of precise feeding, and verify the instructions through preset logical rules. If it is found that the instructions do not meet the management goals, the feeding amount data will be readjusted to obtain the optimized feeding instructions;

[0152] The optimized feeding instructions are transmitted to the automated feeding equipment, and the sow feeding records in the data storage are updated synchronously, completing the closed-loop processing of the entire personalized feeding process.

[0153] Example 2

[0154] The present invention also provides a sow feeding system based on big data analysis, the system is used to implement the method described in Example 1, the system includes: a collection module, an analysis module, an evaluation module and a delivery module;

[0155] The acquisition module is used to collect data streams related to the location information and behavioral status of each sow in real time to obtain a preliminary individual activity data set;

[0156] The analysis module is used to analyze the behavioral status of each sow based on the preliminary individual activity data set, using data cleaning and feature extraction techniques to isolate key behavioral patterns related to physiological cycle changes and determine the activity feature sets of each sow in different time periods;

[0157] The evaluation module is used to comprehensively evaluate the behavior of each sow in a specific environment by deeply processing the activity feature set and combining it with external data input of environmental factors to obtain individualized feeding instructions;

[0158] The delivery module is used to deliver feed to sows within the specified location and time window according to individualized feeding instructions.

[0159] The embodiments described above are merely descriptions of preferred embodiments of the present invention and are not intended to limit the scope of the present invention. Without departing from the spirit of the present invention, various modifications and improvements made to the technical solutions of the present invention by persons skilled in the art should fall within the scope of protection defined by the claims of the present invention.

Claims

1. A sow feeding method based on big data analysis, characterized in that: The method comprises: Collect data streams related to each sow’s location information and behavioral status in real time to obtain a preliminary individual activity dataset; Based on the preliminary individual activity data set, data cleaning and feature extraction techniques were used to analyze the behavioral state of each sow, isolate key behavioral patterns related to physiological cycle changes, and determine the activity feature sets of each sow in different time periods; By deeply processing the activity feature set and combining it with external data inputs on environmental factors, we can comprehensively evaluate the behavior of each sow in a specific environment and obtain individualized feeding instructions. Feed is delivered to sows within designated locations and time windows according to individual feeding instructions.

2. The method according to claim 1, characterized in that Methods for collecting data streams related to each sow's location information and behavioral status in real time to obtain a preliminary individual activity dataset include: The improved OpenPose algorithm is used to build a sow posture estimation model; Based on the sow posture estimation model, the skeleton joints of each sow are extracted from the video stream image, and the behavioral characteristics of each sow are described by calculating the joint distance and skeleton joint angle; The K-nearest neighbor algorithm was used to classify the behavior of each sow.

3. The method according to claim 1, characterized in that Based on the preliminary individual activity data set, data cleaning and feature extraction techniques were used to analyze the behavioral state of each sow, isolate key behavioral patterns related to physiological cycle changes, and determine the activity feature set of each sow in different time periods. The method includes: Step 1: Obtain original records from individual activity data, use data cleaning methods to remove noise and outliers, and perform interpolation processing for missing data to obtain a cleaned activity dataset; Step 2: Based on the cleaned activity data set, feature extraction technology is used to separate the behavioral state features related to individual sows. Activity data within different time periods are segmented and processed to determine the preliminary behavioral state set. Step 3: Analyze the key behavioral features related to the physiological cycle through the preliminary behavioral state set. If the frequency or intensity of a behavioral state exceeds the preset threshold, it will be marked as a key behavior to obtain the key behavior data set; Step 4: Based on the key behavior dataset and the activity characteristics within the time period, a behavior pattern classification model is constructed to classify the behavior patterns and determine the set of behavior patterns related to periodic changes. Step 5: Based on the classified behavioral pattern set, extract activity features that are highly correlated with physiological cycle changes. If a feature shows consistent changes in multiple time periods, classify it into the core feature set and determine the core activity feature; Step 6: Analyze the changing trends of individual sows' behavioral states over different time periods using core activity characteristics. Perform time series analysis on these changing trends to obtain a set of activity characteristics corresponding to physiological cycle changes. Step 7: Based on the activity feature set, integrate key behavior and behavior pattern data to build a complete individual activity feature library. Standardize the feature library to determine whether the final feature set meets the expected classification criteria and obtain the final analysis results.

4. The method according to claim 1, wherein For key behavior datasets, combined with activity characteristics within a time period, a behavior pattern classification model is constructed to classify behavior patterns. Methods for determining sets of behavior patterns related to periodic changes include: Input the input behavior sequence X into the CNN layer to extract local features; Input local features into BiLSTM to obtain bidirectional hidden states; The bidirectional hidden state is weighted by the attention mechanism and the final feature is output; The final features are input into the fully connected layer for classification to obtain a set of behavioral patterns related to periodic changes.

5. The method according to claim 1, wherein By deeply processing the activity feature set and combining it with external data inputs on environmental factors, a comprehensive assessment of each sow's behavior in a specific environment is conducted to obtain individualized feeding instructions. The methods include: By deeply processing the activity feature set and combining it with external data inputs on environmental factors, we can comprehensively evaluate the behavior of each sow in a specific environment and determine its current priority needs. If the demand priority ranking shows that a sow is in high demand, the location information acquisition module will track its specific location coordinates in the farm in real time to obtain a dynamic location distribution map; Based on the dynamic position distribution map and the preset rules for time window optimization, the most suitable feeding time interval is calculated for each sow's current position and activity characteristics, and the optimal time window range is determined; By outputting the optimal time window range and combining it with the goal of precise feeding management, the corresponding feed ratio and feeding amount plan are generated according to the personalized needs of each sow, and individualized feeding instructions are obtained.

6. The method according to claim 5, characterized in that By deeply processing the activity feature set and combining it with external data inputs on environmental factors, we can comprehensively evaluate each sow's behavior in a specific environment and determine its current needs priority. The methods include: By collecting activity characteristics, sensor equipment is used to obtain daily activity data of each sow to form an initial activity data set; Based on the initial activity data set, the environmental factor information in the external data is integrated and the pre-established feature extraction model is used to obtain the behavioral performance feature set of each sow in a specific environment. Based on the behavioral performance feature set and the influence of a specific environment, if certain behavioral indicators in the feature set exceed the preset threshold, they will be marked as abnormal and the abnormal behavior pattern will be determined; By comparing abnormal and normal behavior patterns, the random forest model in machine learning is used to determine the current demand category of each sow; Based on the current demand category and combined with comprehensive evaluation logic, if the urgency of a demand category is higher than the preset standard, its priority will be increased to obtain the preliminary demand prioritization results; Based on the preliminary demand prioritization results, the environmental factor adjustment coefficient after in-depth analysis is integrated to obtain the final demand priority list; By continuously updating the final demand priority list and adopting a scheduled data refresh mechanism, we can determine whether the demand priority has changed and form a dynamically adjusted priority sequence.

7. The method according to claim 5, characterized in that The position information acquisition module is a real-time computer vision tracking system for pigs in piggeries. The system consists of a camera and a PC. The computer runs a tracking algorithm to estimate the pig's position and identity. The tracking algorithm is divided into two steps: the first step is to establish a support map that points to the initial pig segment in each video frame; the second step is to use the support map segmentation to establish a 5D-Gaussian model of the pig, that is, its position and shape; the system has software to correct for fisheye distortion from the camera lens.

8. The method according to claim 5, characterized in that Based on the dynamic location distribution map and the preset rules for time window optimization, the most suitable feeding time interval is calculated for each sow's current location and activity characteristics. The methods for determining the optimal time window range include: By obtaining the current location data of each sow from the dynamic location distribution map and combining it with the real-time recording of activity characteristics, an individualized location and behavior data set is formed, and preliminary activity pattern analysis results are obtained; Based on the preliminary activity pattern analysis results, the activity characteristics of individual sows are classified using preset conditions, and the appropriate feeding time range for each individual is determined by combining the optimization rules of the time window; For the determined suitable feeding time range, obtain the position change trend data in the distribution graph. If the position change trend shows that the individual is active during a specific time period, adjust the time interval to a period with lower activity and lock the adjusted time interval; By performing a secondary verification on the adjusted time interval, the matching degree between the historical feeding data and the current activity characteristics is obtained. If the matching degree is lower than the preset threshold, the time interval is recalculated to obtain a feeding schedule that better meets individual needs; Based on the recalculated feeding schedule and the constraints of the optimal window, a logistic regression model is used to evaluate the stability of the time interval to determine whether the final feeding time window meets the optimization rules; Through the evaluated feeding time window, the behavioral feedback data of the individual sow in the current position is obtained. If the feedback data indicates abnormal behavior, the fine-tuning mechanism of the time interval is triggered to determine the final adaptive time range; Based on the final adaptation time range, a personalized feeding plan is generated for each sow. Combined with the continuous update of dynamic position and activity characteristics, the real-time applicability of the plan is judged to form a closed-loop mechanism for dynamic adjustment.

9. The method according to claim 5, characterized in that By outputting the optimal time window range and combining it with the goal of precise feeding management, we can generate a corresponding feed ratio and feeding amount plan based on the individual needs of each sow. The methods for obtaining individualized feeding instructions include: By obtaining each sow's historical feeding records and health status data from the data storage and combining them with the time window constraints, a preliminary individualized demand range is determined; Based on the preliminary individualized demand range, the pre-established nutritional demand model is used to calculate the basic feed ratio value for each sow in the current time window and obtain the corresponding nutrient composition combination; Based on the nutritional composition, the current inventory of feed raw materials is obtained. If the inventory of a certain raw material is lower than the preset threshold, the raw material ratio in the ratio scheme is adjusted to determine the final feed ratio result; Based on the final feed ratio results, combined with the sow's individual needs and the optimal range within the time window, the feeding plan for each sow is calculated to obtain specific feeding data; Generate personalized feeding instructions for each sow based on feeding data, use an automated system to format the instructions, and determine the execution order and timing of the instructions; Obtain the execution order and time points of the instructions, combine them with the management goal of precise feeding, and verify the instructions through preset logical rules. If it is found that the instructions do not meet the management goals, the feeding amount data will be readjusted to obtain the optimized feeding instructions; The optimized feeding instructions are transmitted to the automated feeding equipment, and the sow feeding records in the data storage are updated synchronously, completing the closed-loop processing of the entire personalized feeding process.

10. A sow feeding system based on big data analysis, the system being used to implement the method according to any one of claims 1 to 9, characterized in that: The system includes: a collection module, an analysis module, an evaluation module and a delivery module; The acquisition module is used to collect data streams related to the location information and behavioral status of each sow in real time to obtain a preliminary individual activity data set; The analysis module is used to analyze the behavioral state of each sow based on the preliminary individual activity data set, using data cleaning and feature extraction technology, to separate key behavioral patterns related to physiological cycle changes, and determine the activity feature set of each sow in different time periods; The evaluation module is used to comprehensively evaluate the behavior of each sow in a specific environment by deeply processing the activity feature set and combining it with external data input of environmental factors to obtain individualized feeding instructions; The delivery module is used to deliver feed to sows within a specified location and time window according to individualized feeding instructions.