Method, device and electronic equipment for predicting maintenance net energy requirement

Predicting pigs' maintenance net energy requirements through a neural network model based on heart rate data solves the problems of poor reproducibility and applicability caused by complex measurement methods in the existing technology, achieves fast and accurate predictions, and reduces costs.

CN114795161BActive Publication Date: 2024-10-25CHINA AGRI UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210388905.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-04-13
Publication Date
2024-10-25
Estimated Expiration
2042-04-13

AI Technical Summary

Technical Problem

The existing method for measuring the net energy requirement for maintaining pigs is complex, resulting in poor reproducibility and applicability, making it difficult to popularize in actual production.

Method used

By obtaining the heart rate data of the target pigs and using a pre-trained neural network model based on production capacity parameters for prediction, the prediction process for maintaining net energy requirements is simplified and optimized.

Benefits of technology

It improves the applicability and replicability of the prediction process of pig maintenance net energy requirements, achieves fast and accurate real-time prediction, reduces dependence on expensive equipment, and saves costs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114795161B_ABST
    Figure CN114795161B_ABST
Patent Text Reader

Abstract

The present invention provides a method, device and electronic device for predicting maintenance net energy requirement, the method comprising: obtaining heart rate data of a target pig; obtaining the maintenance net energy requirement of the target pig based on the heart rate data and a pre-trained net energy requirement prediction model; wherein the net energy requirement prediction model is a neural network model obtained through training based on production capacity parameters. This method effectively introduces a processing idea of ​​predicting based on the heart rate data of the pig in the process of predicting the maintenance net energy requirement of the pig, and simplifies and optimizes the overall prediction process, so as to conveniently and quickly predict the maintenance net energy requirement of the pig in real time, and also improves the replicability and applicability of the prediction method.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of pig breeding and management, and in particular to a method, device and electronic equipment for predicting the maintenance net energy requirement. Background Art

[0002] The energy systems involved in the pig production and breeding industry generally include the total energy system, digestible energy system, metabolic energy system and net energy system. In the description of the available energy of pigs, the accuracy of the above four energy systems is increasing in sequence, that is, the net energy system is an accurate system for describing the available energy of pigs. In the net energy system, the net energy requirement usually includes the maintenance net energy requirement, the deposition net energy requirement, the protein deposition net energy requirement and the fat deposition net energy requirement. Under the state of maintaining net energy requirements, pigs need to maintain basal metabolism, and the energy flow in their bodies is in dynamic balance without energy deposition and energy decomposition. At this time, the net energy requirement only includes the maintenance net energy requirement. Maintaining net energy requirements is a prerequisite for ensuring the healthy growth and smooth production of pigs. Therefore, effectively measuring the maintenance net energy requirement of pigs is of great significance in the pig production and breeding industry. To determine the maintenance net energy requirement of pigs, it is necessary to estimate it based on the basal metabolic heat production of pigs, and the basal metabolic heat production of pigs is generally replaced by fasting metabolic heat production.

[0003] Indirect respiratory calorimetry is the traditional mainstream method for determining the net energy requirement for pig maintenance. This method requires the use of a dedicated respiratory calorimetry device to analyze the gas composition of the gas ingested and excreted by the pig each time the net energy requirement for pig maintenance is measured, and the fasting metabolic heat production of the pig per unit time is calculated based on the difference in gas composition, and then the net energy requirement for pig maintenance is calculated based on the obtained fasting metabolic heat production.

[0004] However, the traditional method of determining the net energy requirement for maintenance of pigs based on indirect respiratory calorimetry has a complex overall process, resulting in poor replicability and difficulty in promotion and application in actual production. Summary of the invention

[0005] The present invention provides a method, device and electronic device for predicting the net energy requirement for maintenance, which are used to solve the defects of the traditional measurement method in the prior art that the process is complicated and leads to poor reproducibility and poor applicability, thereby optimizing the prediction process of the net energy requirement for maintenance of pigs and improving the applicability of the prediction process.

[0006] The present invention provides a method for predicting maintenance net energy requirement, comprising:

[0007] Obtain the heart rate data of the target pig;

[0008] Based on the heart rate data and a pre-trained net energy requirement prediction model, obtaining the maintenance net energy requirement of the target pig;

[0009] Wherein, the net energy requirement prediction model is a neural network model obtained through training based on production capacity parameters.

[0010] According to the method for predicting maintenance net energy requirement provided by the present invention, the training process of the net energy requirement prediction model includes:

[0011] Acquire heart rate data of a number of sample pigs to form a first data set, wherein the heart rate data includes time information;

[0012] Obtaining the maintenance net energy requirement data of each sample pig at the corresponding time information to form a second data set;

[0013] constructing a training data set based on the first data set and the second data set;

[0014] Based on the training data set, a preset data curve fitting method and a preset parameter estimation algorithm, obtaining the production capacity parameter;

[0015] Training the production capacity parameter based on the training data set to obtain the net energy requirement prediction model;

[0016] Wherein, the data curve fitting method is to perform curve fitting on the training data set based on a nonlinear logistic regression function.

[0017] According to the method for predicting the maintenance net energy requirement provided by the present invention, the production capacity parameter is obtained based on the training data set, a preset data curve fitting method and a preset parameter estimation algorithm, including:

[0018] Using the heart rate data in the training data set as input, using the maintenance net energy requirement data corresponding to the heart rate data in the training data set as output, performing curve fitting based on a nonlinear logistic regression function to obtain a curve fitting function;

[0019] The production capacity parameters are obtained by performing parameter inverse estimation based on a preset parameter estimation algorithm and the curve fitting function.

[0020] According to the method for predicting the maintenance net energy requirement provided by the present invention, the expression of the curve fitting function is:

[0021] NEM ij =g(Φ i ,HR ij )+ε ij

[0022] Among them, i represents the number of sample pigs, j represents the number of data, HR ij Represents the heart rate data of sample pigs, NEm ij represents the net energy requirement for maintaining the sample pigs at the corresponding time, Φ i represents the capacity parameter, ε ij represents the random effect error.

[0023] According to the method for predicting the maintenance net energy requirement provided by the present invention, the parameter estimation algorithm includes any one or more of an expected maximum algorithm, a Newton iteration algorithm and a gradient descent algorithm.

[0024] According to the method for predicting maintenance net energy requirement provided by the present invention, the training process of the net energy requirement prediction model further includes:

[0025] Building a test data set based on the first data set and the second data set, and recording the net energy requirement data in the test data set as the actual value of the net energy requirement;

[0026] Inputting the heart rate data in the test data set into the net energy requirement prediction model to obtain a predicted value of the maintenance net energy requirement;

[0027] Analyzing the correlation between the predicted value of the maintenance net energy requirement and the actual value of the maintenance net energy requirement;

[0028] The net energy requirement prediction model is verified based on the correlation relationship.

[0029] According to the method for predicting the maintenance net energy requirement provided by the present invention, the verification of the net energy requirement prediction model based on the correlation relationship includes:

[0030] Based on the correlation relationship, obtaining the distribution of the predicted weighted residuals;

[0031] The net energy requirement prediction model is verified based on the predicted weighted residual distribution.

[0032] The present invention also provides a prediction device for maintaining net energy requirement, comprising:

[0033] An acquisition module is used to acquire the heart rate data of the target pig;

[0034] A prediction module, used for obtaining the maintenance net energy requirement of the target pig based on the heart rate data and a pre-trained net energy requirement prediction model;

[0035] Wherein, the net energy requirement prediction model is a neural network model obtained through training based on production capacity parameters.

[0036] The present invention also provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, all or part of the steps of the method for maintaining prediction of net energy requirement as described in any one of the above items are implemented.

[0037] The present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, all or part of the steps of the method for maintaining prediction of net energy requirement as described in any of the above items are implemented.

[0038] The present invention provides a method, device and electronic device for predicting maintenance net energy requirement. The method obtains the heart rate data of a target pig, and obtains the maintenance net energy requirement of the target pig based on the heart rate data and a pre-trained net energy requirement prediction model, wherein the net energy requirement prediction model is a neural network model trained based on production capacity parameters. The method effectively introduces a processing idea of ​​predicting based on the heart rate data of the pig in the process of predicting the maintenance net energy requirement of the pig, and simplifies and optimizes the overall prediction process, so as to conveniently and quickly predict the maintenance net energy requirement of the pig in a maintenance state in real time, and also improves the replicability and applicability of the prediction method. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0040] Figure 1 It is one of the flow charts of the method for predicting the maintenance net energy requirement provided by the present invention;

[0041] Figure 2 It is one of the schematic diagrams of the training process of the net energy requirement prediction model in the method for predicting the maintenance net energy requirement provided by the present invention;

[0042] Figure 3 This is the second schematic diagram of the training process of the net energy requirement prediction model in the method for predicting the maintenance net energy requirement provided by the present invention;

[0043] Figure 4 This is the third schematic diagram of the training process of the net energy requirement prediction model in the method for predicting the maintenance net energy requirement provided by the present invention;

[0044] Figure 5 This is the fourth schematic diagram of the training process of the net energy requirement prediction model in the method for predicting the maintenance net energy requirement provided by the present invention;

[0045] Figure 6 It is a data curve fitting schematic diagram of the heart rate data and the maintenance net energy requirement data of any pregnant sow in the method for predicting the maintenance net energy requirement provided by the present invention;

[0046] Figure 7 It is a schematic diagram of the correlation relationship between the predicted value of the net energy requirement for maintenance and the actual value of the net energy requirement for maintenance in the method for predicting the net energy requirement for maintenance provided by the present invention;

[0047] Figure 8 It is a schematic diagram of the distribution of the prediction weighted residual of the net energy requirement prediction model in the method for predicting the maintenance net energy requirement provided by the present invention within different heart rate ranges;

[0048] Fig. 9 It is a schematic diagram of the distribution of the prediction weighted residual of the net energy requirement prediction model in the method for predicting the maintenance net energy requirement provided by the present invention within different maintenance net energy requirement ranges;

[0049] Fig.10 It is a schematic diagram of the structure of the prediction device for maintaining the net energy requirement provided by the present invention;

[0050] Fig.11 It is a structural schematic diagram of the electronic device provided by the present invention.

[0051] Reference numerals:

[0052] 101: acquisition module; 102: prediction module; 1110: processor; 1120: communication interface; 1130: memory; 1140: communication bus. DETAILED DESCRIPTION

[0053] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be clearly and completely described below in conjunction with the drawings of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0054] Combine the following Figure 1-Figure 11 The invention describes a method, a device and an electronic device for predicting the maintenance net energy requirement.

[0055] Almost all the oxygen required for energy metabolism and heat production in animals comes from their blood circulation, resulting in a very significant linear correlation between animal heart rate and animal oxygen consumption. When calculating animal heat production, animal oxygen consumption is usually the most important indicator parameter, and based on the above significant linear correlation, it can be concluded that animal heat production can be calculated based on animal heart rate. In other words, based on animal heart rate, animal oxygen consumption and animal heat production can be effectively predicted, and then the net energy requirement for animal maintenance can be predicted based on animal heat production. The method of predicting body energy consumption based on heart rate has been maturely applied in humans, but there is little research and application on pigs.

[0056] The prediction method provided by the present invention can efficiently and real-time predict the net energy requirement for maintaining pigs in various physiological stages, such as pregnant sows, lactating sows, piglets, growing and fattening pigs, and boars. The embodiments of the present invention are described by taking pregnant sows as an example.

[0057] The present invention provides a method for predicting the maintenance net energy requirement. Figure 1 FIG. 1 is one of the flow charts of the method for predicting the maintenance net energy requirement provided by the present invention, such as Figure 1 As shown, the method includes:

[0058] 110. Obtain the heart rate data of the target pig.

[0059] The heart rate data of target pigs under normal feeding conditions are collected using heart rate sensors and other heart rate measuring devices.

[0060] 120. Based on the heart rate data and a pre-trained net energy requirement prediction model, obtain the maintenance net energy requirement of the target pig; wherein the net energy requirement prediction model is a neural network model trained based on production capacity parameters.

[0061] The heart rate data of the target pigs under normal feeding conditions collected in step 110 is input into a pre-trained net energy requirement prediction model to output the maintenance net energy requirement of the target pigs under normal feeding environment conditions, wherein the net energy requirement prediction model is a neural network model trained based on production capacity parameters.

[0062] The present invention provides a method for predicting maintenance net energy requirement, the method obtains the maintenance net energy requirement of the target pig based on the heart rate data and a pre-trained net energy requirement prediction model by acquiring heart rate data of the target pig, wherein the net energy requirement prediction model is a neural network model obtained through training based on production capacity parameters. The method effectively introduces a processing idea of ​​predicting based on the heart rate data of the pig in the process of predicting the maintenance net energy requirement of the pig, and simplifies and optimizes the overall prediction process, so as to conveniently and quickly predict the maintenance net energy requirement of the pig in a maintenance state in real time, and also improves the replicability and applicability of the prediction method, and also facilitates its use in the front line of pig breeding and management production.

[0063] According to the method for predicting the maintenance net energy requirement provided by the present invention, Figure 2 FIG. 1 is one of the schematic diagrams of the training process of the net energy requirement prediction model in the method for predicting the maintenance net energy requirement provided by the present invention, such as Figure 2 As shown, the net energy required to predict the model training process includes:

[0064] 210. Obtain heart rate data of a number of sample pigs to form a first data set, wherein the heart rate data includes time information.

[0065] The heart rate data of multiple sample pigs are collected using a heart rate collection device (such as a heart rate belt) to form a first data set, wherein the heart rate data includes time information, which refers to the time point information or time period information when the heart rate data is collected. The function of this information is to achieve a one-to-one correspondence between the heart rate data of the same sample pig and its maintenance net energy requirement through the correspondence of the time point or time period. When the time information is a time point (or timestamp), the collected heart rate data of the sample pig is a real-time heart rate value. When the time information is a time period, the collected heart rate data of the sample pig is the heart rate average value of the heart rate data within the period.

[0066] 220. Obtain the maintenance net energy requirement data of each of the sample pigs at the corresponding time information to form a second data set.

[0067] Based on the indirect respiratory calorimetry, the net energy requirement data of each sample pig was obtained by measuring the metabolic heat production during fasting. The net energy requirement data was obtained by measuring the O 2 Consumption and CO 2 and CH 4 The emissions were estimated by calculating the fasting heat production per unit metabolic weight of the sampled pigs, thus forming the second data set.

[0068] 230. Construct a training data set based on the first data set and the second data set.

[0069] A portion of data is selected from the first data set according to a preset ratio as training data, and correspondingly, a corresponding portion of data is selected from the second data set according to the same preset ratio as training data; thus, the training data of the first data set and the training data of the second training set together constitute a training data set.

[0070] 240. Based on the training data set, a preset data curve fitting method and a preset parameter estimation algorithm, obtain the production capacity parameter; wherein the data curve fitting method is to perform curve fitting on the training data set based on a nonlinear logistic regression function.

[0071] A preset data curve fitting method is used to perform data curve fitting processing on the input data and output data classified into the training data set, and the production capacity parameters are calculated based on the data curve fitting result and the preset parameter estimation algorithm.

[0072] It should be noted that, depending on different actual application scenarios, there may be multiple capacity parameters, and multiple capacity parameters need to be calculated.

[0073] 250. Train the production capacity parameter based on the training data set to obtain the net energy requirement prediction model.

[0074] Based on the one or more production capacity parameters obtained in step 240, it can also be understood that deep learning training is performed on the one or more production capacity parameters obtained using a training data set and a nonlinear logistic regression function, so as to construct and train the net energy requirement prediction model.

[0075] The trained net energy requirement model can be effectively applied to the prediction process of the maintenance net energy requirement of other target pigs.

[0076] According to the method for predicting the maintenance net energy requirement provided by the present invention, Figure 3 FIG. 2 is a second schematic diagram of the training process of the net energy requirement prediction model in the method for predicting the maintenance net energy requirement provided by the present invention. Figure 3 As shown, in Figure 2 On the basis of, the step 240, based on the training data set, the preset data curve fitting method and the preset parameter estimation algorithm, obtains the production capacity parameter, including:

[0077] 241. Using the heart rate data in the training data set as input, using the maintenance net energy requirement data corresponding to the heart rate data in the training data set as output, performing curve fitting based on a nonlinear logistic regression function to obtain a curve fitting function.

[0078] Taking the heart rate data in the training data set as input, and the maintenance net energy requirement data corresponding to the heart rate data in the training data set as output, curve fitting is performed on the heart rate data of the sample pigs in the training data set and the corresponding maintenance net energy requirement data based on the logistic regression function in the nonlinear mixed model, wherein the individual sample pigs are randomly selected from any sample pigs, and finally a curve fitting function is obtained.

[0079] 242. Perform parameter reverse estimation based on a preset parameter estimation algorithm and the curve fitting function to obtain the production capacity parameter.

[0080] The parameters of the curve fitting function are inversely estimated based on a preset parameter estimation algorithm, that is, the parameters in the curve fitting function, that is, the production capacity parameters, are calculated.

[0081] According to the method for predicting the maintenance net energy requirement provided by the present invention, the expression of the curve fitting function is:

[0082] NEM ij =g(Φ i ,HR ij )+ε ij

[0083] Among them, i represents the number of sample pigs, j represents the number of data, HR ij Represents the heart rate data of sample pigs, NEm ij represents the net energy requirement for maintaining the sample pigs at the corresponding time, Φ i represents the capacity parameter, ε ij represents the random effect error.

[0084] More specifically,

[0085]

[0086] Among them, Φ i =(φ 1i ,φ 2i ,φ 3i ), both represent capacity parameters, or model parameters. In this case, the model parameters are φ 1i ,φ 2i ,φ 3i There are 3 in total, which is a capacity parameter Φ i It includes three parameters.

[0087] According to the method for predicting the maintenance net energy requirement provided by the present invention, the parameter estimation algorithm includes any one or more of an expected maximum algorithm, a Newton iteration algorithm and a gradient descent algorithm.

[0088] The preset parameter estimation algorithm adopts any one or a combination of any of the expected maximum algorithm, Newton iteration algorithm and gradient descent algorithm. Among them, the expected maximum algorithm specifically refers to the Stochastic Approximation Expectation Maximization algorithm (SAEM algorithm for short). Performing parameter inverse estimation based on the above algorithm can significantly improve the accuracy of parameter estimation.

[0089] According to the method for predicting the maintenance net energy requirement provided by the present invention, Figure 4 FIG. 3 is a third schematic diagram of the training process of the net energy requirement prediction model in the method for predicting the maintenance net energy requirement provided by the present invention. Figure 4 As shown, in Figure 2 As shown, the training process of the net energy prediction model also includes:

[0090] 261. Construct a test data set based on the first data set and the second data set, and record the maintenance net energy requirement data in the test data set as the actual value of the maintenance net energy requirement.

[0091] The heart rate data other than the training data is selected from the first data set according to a preset ratio as the test data, and correspondingly, the maintenance net energy requirement data other than the training data is selected from the second data set according to the same preset ratio as the test data; thus, the training data of the first data set and the test data of the second training set together constitute the test data set. The maintenance net energy requirement data in the test data set is marked as the actual value of the maintenance net energy requirement.

[0092] 262. Input the heart rate data in the test data set into the net energy requirement prediction model to obtain a predicted value of the maintenance net energy requirement.

[0093] Through the above steps 210 to 250, a net energy requirement prediction model has been constructed and trained, but the prediction effect of the model is not fixed, which needs to be verified again. The heart rate data in the test data set is input into the net energy requirement prediction model to obtain the predicted value of the maintenance net energy requirement of the pig under the corresponding time information.

[0094] 263. Analyze the correlation between the predicted value of the maintenance net energy requirement and the actual value of the maintenance net energy requirement.

[0095] The correlation between the actual value of the net energy requirement for maintenance described in step 262 and the predicted value of the net energy requirement for maintenance described in step 263 is analyzed. The smaller the deviation between the two, the stronger the correlation, and vice versa.

[0096] 264. Verify the net energy requirement prediction model based on the correlation relationship.

[0097] The prediction effect of the net energy requirement prediction model is verified based on the strength of the correlation relationship. The stronger the correlation relationship is, the closer the predicted value of the net energy requirement in step 263 is to the actual value of the net energy requirement in step 262, the smaller the error is, and the better the prediction effect of the net energy requirement prediction model is. On the contrary, the prediction effect of the net energy requirement prediction model is worse. When the prediction effect of the net energy requirement prediction model is poor, the net energy requirement prediction model can be further optimized based on this verification result.

[0098] According to the method for predicting the maintenance net energy requirement provided by the present invention, Figure 5 FIG. 4 is a fourth schematic diagram of the training process of the net energy requirement prediction model in the method for predicting the maintenance net energy requirement provided by the present invention. Figure 5 As shown, in Figure 4 On the basis of, the step 264, verifying the net energy requirement prediction model based on the correlation relationship, includes:

[0099] 2641. Based on the correlation relationship, obtain the distribution of predicted weighted residuals.

[0100] It is also possible to obtain the predicted weighted residual distribution of the predicted results based on the correlation between the actual value of the net energy requirement to maintain described in step 262 and the predicted value of the net energy requirement to maintain described in step 263, which may specifically include the predicted weighted residual values ​​based on different heart rate data value ranges, and the predicted weighted residual values ​​based on different net energy requirement value ranges.

[0101] 2642. Verify the net energy requirement prediction model based on the predicted weighted residual distribution.

[0102] According to the situation that the predicted weighted residual value is based on different value ranges of heart rate data, or according to the situation that the predicted weighted residual value is based on different value ranges of net energy requirement for maintenance, the prediction effect of the net energy requirement prediction model is further analyzed accordingly.

[0103] Taking pregnant sows as an example, the specific implementation process is described as follows:

[0104] (1) Acquire heart rate data of a number of sample pigs (pregnant sows are used as samples) to form a first data set, wherein the heart rate data includes time information:

[0105] The heart rate data of the above-mentioned several pregnant sows were obtained by making the pregnant sows wear a special heart rate sensor that uses electrocardiogram (ECG) signals as the working principle.

[0106] The monitoring and prediction process is carried out in an animal testing center in Hebei to ensure the rigor of the process and data.

[0107] The monitored subjects were 6 pregnant sows of Chang×Da binary hybrid, with a gestation time of 69 days (d69) and an initial body weight of 232.5±12.5kg. Each pregnant sow was raised in a dedicated metabolic cage (1.70m×0.70m×1.40m). During the whole process, each pregnant sow was fed twice a day at a fixed time (8:30 and 15:30 every day) and was always free to drink water. The feeding diet used a corn-soybean meal standard diet to meet the nutritional requirements of pregnant sows, and the formula composition and nutritional level used the basic feeding formula and percentage.

[0108] An open circulation respiratory calorimetry device for pigs (referred to as respiratory calorimetry chamber) was set up, the temperature was controlled at 20±1℃, the humidity was controlled at about 70%, the wind speed in the space was controlled at about 1m / s, and fixed lighting conditions were set (the lighting time was set from 06:00 to 18:00). Except for feeding and collecting feces and urine, the whole process lasted for 9 days. All pregnant sows were controlled to adapt to their own metabolic cages for 5 days and then transferred to each respiratory calorimetry chamber (still a separate respiratory calorimetry chamber for each pregnant sow). At the same time, each pregnant sow was controlled to start fasting at 18:00 on the 8th day, and the heart rate value of the pregnant sow at a fixed time point within 24 hours after the fasting and the fasting heat production value at the corresponding time point (or the average heart rate of the pregnant sow in a fixed time period and the average fasting heat production in the corresponding time period) were counted.

[0109] Before being transferred to the respiratory thermometry chamber, each pregnant sow needs to wear a portable electronic heart rate monitor. The heart rate monitor uses a Polar H10 heart rate belt (including a heart rate sensor and an elastic electrode belt), which works on the electrocardiogram signal ECG. The heart rate sensor is connected via Bluetooth and ANT +TMThe technology transmits ECG signals and needs to be paired with a receiving device such as a smartphone. When in use, the electrode points on the elastic electrode belt need to be moistened, and then the heart rate belt is tied tightly to the chest of the pregnant sow and close to the inner side of the front leg to ensure that the electrode part is in full contact with the skin of the pregnant sow and the subcutaneous tissue with dense blood vessels. After the connection is completed, you can use the smartphone to create a Polar account and start measuring the heart rate values ​​of 6 pregnant sows at certain time points, or the average heart rate over a certain period of time. All the heart rate data obtained form the first data set. In addition, the heart rate data includes time information, and the time information refers to the time point information or time period information of collecting the heart rate.

[0110] The Polar H10 heart rate belt has a data storage function. After the measurement is completed, you can access your Polar account to synchronize the measured heart rate data on the Internet, and then download and save it in CSV / TCX file format for subsequent analysis.

[0111] (2) Obtaining the maintenance net energy requirement data of the above six pregnant sows at corresponding time information to form a second data set:

[0112] Based on indirect respiratory calorimetry, the net energy requirement data of each pregnant sow was obtained by measuring the metabolic heat production during fasting. The net energy requirement data of pregnant sows was obtained by measuring the O 2 Consumption and CO 2 and CH 4 The emissions are estimated by calculating the fasting heat production per unit metabolic weight of pregnant sows.

[0113] The fasting metabolic heat production data of each pregnant sow were collected using an open circulation respiration calorimetry chamber. The sows were adapted to the diet and the individual metabolic cage environment on days 1-4. On day 5, the respiration calorimetry chamber environment was set up and all pregnant sows were transferred to each respiration calorimetry chamber, and the heart rate belt was calibrated in the measurement state of the above step (1). After 18:00 on day 8, fasting for 24 hours was started, and the fasting metabolic heat production value at the time point corresponding to the measured heart rate data (or the average fasting metabolic heat production value of the corresponding time period) was formally measured.

[0114] The determination process of fasting metabolic calorific value data is as follows: O 2 The oxygen content of CO was measured by paramagnetic oxygen analyzer (Oxymat 6E, Siemens / Munich, Germany). 2 NH 3 and CH 4The infrared analyzer (Ultramat 6E, Siemens / Munich, Germany) was used for measurement, and the exhaust flow was measured by a gas mass flowmeter (Alicat / Tucson, USA). A total of 6 respiration calorimeters were used to measure the fasting metabolic heat production of the above 6 pregnant sows. Every 2 respiration calorimeters shared a gas analysis system, and each respiration calorimeter performed gas measurement every 5 minutes. The process of calculating the fasting metabolic heat production through gas analysis and then calculating the maintenance net energy requirement of pregnant sows is as follows:

[0115] (2-1) Convert the exhausted gas volume to standard conditions (0°C, 1013hPa):

[0116] The volume of gas discharged in each time period V = time (min) × gas flow rate (L / min);

[0117] Calculate the standard volume SV of the exhaust gas:

[0118] SV=V×(P–Pw) / 1013×273 / (273+T);

[0119] P w =RH / 100×(3.999+0.45547T+0.001708T 2 +0.000469T 3 );

[0120] Wherein, SV represents the standard volume of the exhaust gas (0°C, 1013hPa); V represents the actual volume of the exhaust gas; P represents the air pressure in the breath calorimeter chamber; P w represents water vapor pressure; T is the temperature in the breath calorimeter chamber; RH is the relative humidity in the breath calorimeter chamber.

[0121] (2-2) After conversion to the standard state, calculate the O intake of each pregnant sow during the trial period. 2 With the exhaust CO 2 :

[0122]

[0123]

[0124] and Represents the CO at the start and end of respiration, respectively 2 concentration(%); and Represents the start and end of breathing respectively. 2 Concentration(%); SV 呼吸室 Indicates the net standard volume of the breathing chamber; SV 排气Indicates the standard volume of exhaust gas.

[0125] (2-3) Calculate the net energy requirement for maintaining a pregnant sow, and the net energy requirement for maintaining a pregnant sow is equal to the fasting metabolic heat production of the pregnant sow by default:

[0126] Maintenance net energy requirement (kJ / d / BW 0.75 ) = Fasting metabolic heat production (kJ / d / BW) 0.75 );

[0127] And, fasting metabolic heat production (kJ) = 16.1753 × O 2 (L)+5.0208×CO 2 (L)-2.1673×CH 4 (L).

[0128] A second data set is formed based on which the net energy requirement data for maintenance of each gestating sow is obtained.

[0129] (3) Performing a data standardization preprocessing process on the data collected in step (1) and step (2) to obtain a more accurate and comprehensive first data set and second data set. Of course, the data standardization preprocessing process is optional and is only a preferred measure.

[0130] Specifically, the data collected in step (1) and step (2) are sorted, screened and cleaned respectively. Data sorting includes abnormal data removal, data completion and data value calculation. The heart rate data and the net energy requirement data for maintenance of pregnant sows collected in step (1) and step (2) are sorted and screened and cleaned. The heart rate data and the net energy requirement data for maintenance after data standardization preprocessing are data that correspond to each other in time information. It can be data that corresponds one to one at a time point. It can also be average data that corresponds one to one within a time period. For example, the average heart rate data of each pregnant sow per hour and its corresponding net energy requirement for maintenance per hour. The one-to-one correspondence of time information means that the time for collecting the net energy requirement data for maintenance of pregnant sows and the time for collecting the heart rate data are consistent, so as to form a one-to-one correspondence relationship between time information.

[0131] (4) constructing a training data set based on the first data set and the second data set, and constructing a test data set based on the first data set and the second data set.

[0132] The first data set is divided into training data and test data according to a preset ratio; correspondingly, the second data set is also divided into training data and test data according to the same preset ratio; then the training data of the first data set and the training data of the second training set together constitute the training data set; at the same time, the test data of the first data set and the test data of the second training set together constitute the test data set.

[0133] (5) using the heart rate data in the training data set as input and the net energy requirement data corresponding to the heart rate data in the training data set as output, performing curve fitting on the heart rate data of pregnant sows in the training data set and the corresponding net energy requirement data for maintenance based on a logistic regression function in a nonlinear mixed model, wherein the individual pig is any pregnant sow randomly selected, Figure 6 It is a data curve fitting schematic diagram of the heart rate data and the net energy requirement data of any pregnant sow in the method for predicting the net energy requirement for maintenance provided by the present invention, such as Figure 6 This is the result of the curve fitting of the heart rate data and the net energy requirement data of the third pregnant sow. Figure 6 As shown, the curve fitting function is obtained:

[0134] NEM ij =g(Φ i ,HR ij )+ε ij

[0135] Among them, i represents the number of sample pigs, j represents the number of data, HR ij Represents the heart rate data of sample pigs, NEm ij represents the net energy requirement for maintaining the sample pigs at the corresponding time, Φ i represents the capacity parameter, ε ij represents the random effect error.

[0136] And further,

[0137]

[0138] Among them, Φ i =(φ 1i ,φ 2i ,φ 3i ), both represent capacity parameters, or model parameters. In this case, the model parameters are φ 1i ,φ 2i ,φ 3i 3 in total.

[0139] (6) Perform parameter reverse estimation based on a preset parameter estimation algorithm and the curve fitting function to obtain the production capacity parameter:

[0140] The preset parameter estimation algorithm uses the stochastic asymptotic maximum expected value algorithm (SAEM algorithm for short) to estimate the Φ in the above curve fitting function. i =(φ 1i ,φ 2i ,φ 3i ) to perform inverse parameter estimation to obtain φ 1i ,φ 2i ,φ 3i There are estimated values ​​of 3 capacity parameters in total.

[0141] For example, the parameter estimation results can be shown in Table 1.

[0142] Table 1

[0143]

[0144] (7) Training the capacity parameter based on the training data set to obtain the net energy requirement prediction model:

[0145] Based on the estimated values ​​of each capacity parameter, the specific expression of the curve function is reversely determined, and the capacity parameters are trained based on the training data set, thereby obtaining the net energy requirement prediction model.

[0146] As above, the specific expression of the curve function is:

[0147]

[0148] Therefore, in the random effect error ε ij When it is ignored or a certain value is used, it is only necessary to measure the heart rate data of the target pigs under normal feeding conditions in advance and substitute it into the formula HR ij The net energy requirement NEm for the target pig can be quickly calculated. ij The numerical value of .

[0149] (8) Verifying the net energy requirement prediction model based on the correlation between the predicted value of the maintenance net energy requirement and the actual value of the maintenance net energy requirement:

[0150] The net energy requirement data in the test data set is recorded as the actual value of the net energy requirement; the heart rate data in the test data set is input into the net energy requirement prediction model to obtain the predicted value of the net energy requirement; the correlation between the predicted value of the net energy requirement and the actual value of the net energy requirement is analyzed to establish the following Figure 7The schematic diagram of the correlation between the predicted value of the net energy requirement and the actual value of the net energy requirement is shown; finally, the net energy requirement prediction model is verified based on the correlation relationship. Specifically, the predicted value and the actual value are used as the horizontal coordinate value and the vertical coordinate value of the coordinate point respectively, so that multiple pairs of predicted values ​​and actual values ​​form Figure 7 There are multiple coordinate points in Figure 7 The 45-degree dotted line in the figure represents the reference line. The closer the coordinate point is to the reference line, the closer the predicted value is to the actual value, or the stronger the correlation is. Figure 7 The displayed correlation relationship between the predicted value of the maintenance net energy requirement and the actual value of the maintenance net energy requirement enables verification of the net energy requirement prediction model.

[0151] When it is verified that the prediction effect of the net energy requirement prediction model is not ideal, the net energy requirement prediction model can be optimized based on the verification result and related data at this time to improve the prediction accuracy of the model.

[0152] (9) Based on the distribution of the predicted weighted residual, the net energy requirement prediction model is verified:

[0153] Based on the correlation between the predicted value of the net energy requirement and the actual value of the net energy requirement, the distribution of the predicted weighted residual is obtained. Figure 8 The distribution of the predicted weighted residual values ​​in different heart rate ranges is shown, and the Fig. 9 The distribution of the predicted weighted residual values ​​in different ranges of net energy requirement for maintenance is shown. Based on the distribution of the predicted weighted residuals in different heart rate ranges or in different ranges of net energy requirement for maintenance, the net energy requirement prediction model is further verified. Specifically, the closer the distribution of the predicted weighted residual values ​​is to the 0-value coordinate axis, or the smaller the fluctuation range around the 0-value coordinate axis, the better the prediction effect of the model. Otherwise, the worse.

[0154] When it is verified that the prediction effect of the net energy requirement prediction model is poor, the net energy requirement prediction model can be further optimized based on the verification results and related data at this time to further improve the prediction accuracy of the model.

[0155] All calculations in this example were performed using the saemix package in R 4.1.2 (R Core Team, 2022).

[0156] Compared with the traditional indirect respiratory calorimetry, the prediction method based on heart rate to maintain net energy requirement has little impact on the test subjects, and the process is simple and optimized, easy to monitor and predict. This method provides a new solution for the study of pig net energy system and energy requirement. Through this method, the energy metabolism state of pregnant sows can be monitored, and the maintenance net energy requirement of pregnant sows can be predicted quickly and conveniently, thereby providing a more accurate reference for the formulation / adjustment of feeding management strategies and feed formulas for pregnant sows. At the same time, it will provide basic theoretical support for the development of intelligent farming Internet of Things monitoring equipment and feeding equipment for pregnant sows. This method can also effectively avoid the expensive problem caused by the dependence of traditional sow net energy requirement estimation methods on large-scale respiratory calorimetry equipment, saving capital costs.

[0157] The present invention also provides a device for predicting the maintenance net energy requirement. The device for predicting the maintenance net energy requirement and the method for predicting the maintenance net energy requirement have the same technical principles and correspond to each other, and will not be described in detail here.

[0158] The present invention also provides a prediction device for maintaining net energy requirement. Fig.10 Schematic diagram of the structure of the prediction device for maintaining the net energy requirement provided by the present invention. Fig.10 As shown, the device includes an acquisition module 101 and a prediction module 102, wherein:

[0159] The acquisition module 101 is used to acquire the heart rate data of the target pig;

[0160] The prediction module 102 is used to obtain the maintenance net energy requirement of the target pig based on the heart rate data and a pre-trained net energy requirement prediction model; wherein the net energy requirement prediction model is a neural network model trained based on production capacity parameters.

[0161] The present invention provides a prediction device for maintenance net energy requirement, the device comprises an acquisition module 101 and a prediction module 102, the two modules work in cooperation with each other, so that the device obtains the heart rate data of the target pig, and obtains the maintenance net energy requirement of the target pig based on the heart rate data and a pre-trained net energy requirement prediction model, wherein the net energy requirement prediction model is a neural network model obtained through training based on production capacity parameters. The method effectively introduces a processing idea of ​​prediction based on the heart rate data of the pig in the process of predicting the maintenance net energy requirement of the pig, and can more conveniently and quickly predict the maintenance net energy requirement of the pig in a maintenance state in real time, and can also improve the replicability and applicability of the prediction device, and also facilitate its use in the front line of pig breeding and management production.

[0162] Fig.11 An example of a physical structure diagram of an electronic device is shown in FIG. Fig.11As shown, the electronic device may include: a processor 1110, a communication interface 1120, a memory 1130 and a communication bus 1140, wherein the processor 1110, the communication interface 1120 and the memory 1130 communicate with each other through the communication bus 1140. The processor 1110 may call the logic instructions in the memory 1130 to execute all or part of the steps of the method for maintaining the prediction of the net energy requirement, and the method includes:

[0163] Obtain the heart rate data of the target pig;

[0164] Based on the heart rate data and a pre-trained net energy requirement prediction model, obtaining the maintenance net energy requirement of the target pig;

[0165] Wherein, the net energy requirement prediction model is a neural network model obtained through training based on production capacity parameters.

[0166] In addition, the logic instructions in the above-mentioned memory 1130 can be implemented in the form of a software functional unit and can be stored in a computer-readable storage medium when it is sold or used as an independent product. Based on such an understanding, the technical solution of the present invention can be essentially or partly embodied in the form of a software product that contributes to the prior art. The computer software product is stored in a storage medium, including several instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method for maintaining the net energy requirement described in each embodiment of the present invention. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.

[0167] On the other hand, the present invention further provides a computer program product, the computer program product comprising a computer program, the computer program can be stored on a non-transitory computer-readable storage medium, when the computer program is executed by a processor, the computer can execute all or part of the steps of the method for predicting the maintenance net energy requirement provided by the above methods, the method comprising:

[0168] Obtain the heart rate data of the target pig;

[0169] Based on the heart rate data and a pre-trained net energy requirement prediction model, obtaining the maintenance net energy requirement of the target pig;

[0170] Wherein, the net energy requirement prediction model is a neural network model obtained through training based on production capacity parameters.

[0171] In another aspect, the present invention further provides a non-transitory computer-readable storage medium having a computer program stored thereon, which is implemented when the computer program is executed by a processor to execute all or part of the steps of the method for predicting the maintenance net energy requirement provided by the above methods, the method comprising:

[0172] Obtain the heart rate data of the target pig;

[0173] Based on the heart rate data and a pre-trained net energy requirement prediction model, obtaining the maintenance net energy requirement of the target pig;

[0174] Wherein, the net energy requirement prediction model is a neural network model obtained through training based on production capacity parameters.

[0175] Unless otherwise specified, the experimental methods used in the embodiments of the present invention are all conventional methods and can be carried out according to the techniques or conditions described in the literature in the field or the product manual. The instruments, materials, reagents, etc. used can be purchased through regular commercial channels unless otherwise specified. The device embodiments described above are merely schematic, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. A person of ordinary skill in the art can understand and implement it without paying creative labor.

[0176] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a necessary general hardware platform, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the method for predicting the maintenance net energy requirement described in each embodiment or some parts of the embodiment.

[0177] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A method for predicting net energy requirements for maintenance, It is characterized in that include: Obtain the heart rate data of the target pig; Based on the heart rate data and a pre-trained net energy requirement prediction model, obtaining the maintenance net energy requirement of the target pig; Wherein, the net energy requirement prediction model is a neural network model obtained by training based on production capacity parameters; The net energy required to predict the model training process includes: Acquire heart rate data of a number of sample pigs to form a first data set, wherein the heart rate data includes time information; Obtaining the maintenance net energy requirement data of each sample pig at the corresponding time information to form a second data set; constructing a training data set based on the first data set and the second data set; Based on the training data set, a preset data curve fitting method and a preset parameter estimation algorithm, obtaining the production capacity parameter; Training the production capacity parameter based on the training data set to obtain the net energy requirement prediction model; Wherein, the data curve fitting method is to perform curve fitting on the training data set based on a nonlinear logistic regression function; The training process of the net energy requirement prediction model also includes: Building a test data set based on the first data set and the second data set, and recording the net energy requirement data in the test data set as the actual value of the net energy requirement; Inputting the heart rate data in the test data set into the net energy requirement prediction model to obtain a predicted value of the maintenance net energy requirement; Analyzing the correlation between the predicted value of the maintenance net energy requirement and the actual value of the maintenance net energy requirement; Verifying the net energy requirement prediction model based on the correlation relationship; The obtaining of the production capacity parameter based on the training data set, a preset data curve fitting method and a preset parameter estimation algorithm includes: Using the heart rate data in the training data set as input, using the maintenance net energy requirement data corresponding to the heart rate data in the training data set as output, performing curve fitting based on a nonlinear logistic regression function to obtain a curve fitting function; The production capacity parameters are obtained by performing parameter inverse estimation based on a preset parameter estimation algorithm and the curve fitting function.

2. The method for predicting the maintenance net energy requirement according to claim 1, It is characterized in that The expression of the curve fitting function is: ; in, Indicates the number of sample pigs. Indicates the number of data. represents the heart rate data of the sample pigs, It represents the net energy requirement for maintaining the sample pigs at the corresponding time. Represents the capacity parameter, represents the random effect error.

3. The method for predicting the maintenance net energy requirement according to claim 1, It is characterized in that The parameter estimation algorithm includes any one or more of an expectation-maximization algorithm, a Newton iteration algorithm, and a gradient descent algorithm.

4. The method for predicting the maintenance net energy requirement according to claim 1, It is characterized in that The verifying the net energy requirement prediction model based on the correlation relationship includes: Based on the correlation relationship, obtaining the distribution of the predicted weighted residuals; The net energy requirement prediction model is verified based on the predicted weighted residual distribution.

5. A device for predicting the maintenance net energy requirement, It is characterized in that include: An acquisition module is used to acquire the heart rate data of the target pig; A prediction module, used for obtaining the maintenance net energy requirement of the target pig based on the heart rate data and a pre-trained net energy requirement prediction model; Wherein, the net energy requirement prediction model is a neural network model obtained by training based on production capacity parameters; The net energy required to predict the model training process includes: Acquire heart rate data of a number of sample pigs to form a first data set, wherein the heart rate data includes time information; Obtaining the maintenance net energy requirement data of each sample pig at the corresponding time information to form a second data set; constructing a training data set based on the first data set and the second data set; Based on the training data set, a preset data curve fitting method and a preset parameter estimation algorithm, obtaining the production capacity parameter; Training the production capacity parameter based on the training data set to obtain the net energy requirement prediction model; Wherein, the data curve fitting method is to perform curve fitting on the training data set based on a nonlinear logistic regression function; The training process of the net energy requirement prediction model also includes: Building a test data set based on the first data set and the second data set, and recording the net energy requirement data in the test data set as the actual value of the net energy requirement; Inputting the heart rate data in the test data set into the net energy requirement prediction model to obtain a predicted value of the maintenance net energy requirement; Analyzing the correlation between the predicted value of the maintenance net energy requirement and the actual value of the maintenance net energy requirement; Verifying the net energy requirement prediction model based on the correlation relationship; The obtaining of the production capacity parameter based on the training data set, a preset data curve fitting method and a preset parameter estimation algorithm includes: Using the heart rate data in the training data set as input, using the maintenance net energy requirement data corresponding to the heart rate data in the training data set as output, performing curve fitting based on a nonlinear logistic regression function to obtain a curve fitting function; The production capacity parameters are obtained by performing parameter inverse estimation based on a preset parameter estimation algorithm and the curve fitting function.

6. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, It is characterized in that When the processor executes the program, all or part of the steps of the method for predicting the maintenance net energy requirement as claimed in any one of claims 1 to 4 are implemented.

7. A non-transitory computer-readable storage medium having a computer program stored thereon, It is characterized in that When the computer program is executed by a processor, all or part of the steps of the method for predicting the maintenance net energy requirement as claimed in any one of claims 1 to 4 are implemented.