Cow chewing frequency monitoring method, device, equipment and medium
By calibrating the pressure value of the cow's nasal bridge and using a chewing behavior recognition model, the problem of low efficiency in monitoring the number of chewings in cattle was solved, and accurate monitoring was achieved under different ambient temperatures, thus improving the efficiency of identifying and counting the number of chewings.
Patent Information
- Application Number
- CN202410460626.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-04-17
- Publication Date
- 2025-12-09
- Estimated Expiration
- 2044-04-17
AI Technical Summary
Existing methods for monitoring the number of chewing cycles in cattle are inefficient, and the accuracy of pressure sensors is affected by ambient temperature, making it difficult to accurately identify and count various behavioral parameters.
By acquiring the initial pressure value and ambient temperature value of the cow's nose bridge, the initial pressure value is calibrated based on the ambient temperature value to construct a calibration pressure value. The chewing behavior recognition model is used to identify chewing behavior, and the number of chewing times is calculated by the peak and valley number monitoring method.
It enables accurate monitoring of the number of chewing cycles in cattle under different ambient temperatures, improving the efficiency and accuracy of chewing cycle monitoring and meeting the needs for quantitative index calculation of cattle chewing behavior.
Smart Images

Figure CN118318752B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of animal husbandry, and in particular to a method and device for monitoring chewing times of cattle, equipment and a medium. BACKGROUND
[0002] In agricultural production, the health and feeding conditions of cattle have a crucial influence on product quality and breeding benefits, and the number of chewing times is an important parameter for evaluating the health and feed intake of cattle. When cattle are feeding or ruminating, the number of chewing times has an important influence on the utilization of food in the digestive system, the promotion of food digestion, and the enhancement of the absorption rate of nutritional components in food. Therefore, the number of chewing times is an important indicator for quantifying the feeding and ruminating behavior of cattle, so as to improve the profitability of livestock on the grassland.
[0003] The commonly used method for monitoring the number of chewing times of cattle is intelligent device monitoring. The intelligent device currently applicable to chewing behavior is mainly a pressure sensor, which recognizes chewing behavior by monitoring the pressure signal characteristics of cattle during chewing. However, the current intelligent device monitoring method is applicable to different behavior recognition targets, and a simple threshold model cannot meet the efficient and synchronous monitoring of multiple behavior parameters. For example, the pressure sensor can only achieve primary behavior recognition such as ruminating and chewing, and it is difficult to further count through the chewing behavior recognition result. In addition, the pressure sensor used in the intelligent device monitoring method is affected by the environmental temperature, and the pressure value is prone to deviation, resulting in a decrease in accuracy. Therefore, the existing intelligent device monitoring method has difficulties in calculating the quantification index of cattle behavior, and the pressure value is prone to deviation, thereby resulting in low efficiency of the cattle chewing time monitoring method. SUMMARY
[0004] The present application provides a method and device for monitoring the number of chewing times of cattle, which solves the problem of low efficiency in monitoring the number of chewing times of cattle in the prior art.
[0005] In a first aspect, the present application provides a method for monitoring the number of chewing times of cattle, comprising:
[0006] obtaining a plurality of initial pressure values and an environmental temperature value of the bridge of the nose of the cattle within a first time sequence;
[0007] based on the environmental temperature value, respectively calibrating the plurality of initial pressure values to obtain a plurality of calibrated pressure values;
[0008] extracting a plurality of target pressure values from the plurality of calibrated pressure values according to a second time sequence; the second time sequence is the time sequence of the chewing behavior of the cattle within the first time sequence;
[0009] based on the plurality of target pressure values, converting the number of chewing times of cattle to obtain the number of chewing times of cattle.
[0010] In one embodiment, when calibrating the plurality of initial pressure values based on the ambient temperature value to obtain a plurality of calibrated pressure values, the following steps are performed for each initial pressure value:
[0011] If the ambient temperature value is less than or equal to the first threshold, then a calibration calculation is performed based on the first preset calibration value, the ambient temperature value, the initial pressure value, and the first threshold to obtain the calibration pressure value;
[0012] If the ambient temperature value is greater than the first threshold and less than the second threshold, then the initial pressure value is determined as the calibration pressure value.
[0013] If the ambient temperature value is greater than or equal to the second threshold, then a calibration calculation is performed based on the second preset calibration value, the ambient temperature value, the initial pressure value, and the second threshold to obtain the calibration pressure value.
[0014] In one embodiment, the calibration calculation based on the second preset calibration value, the ambient temperature value, the initial pressure value, and the second threshold to obtain the calibration pressure value includes:
[0015] Subtract the ambient temperature value from the first threshold to obtain the difference;
[0016] Multiply the difference by the first preset calibration value to obtain the product;
[0017] The product is added to the initial pressure value to obtain the calibration pressure value.
[0018] In one embodiment, the step of converting the number of chewing strokes of a cow based on the plurality of target pressure values to obtain the number of chewing strokes includes:
[0019] A pressure line graph is constructed based on the multiple target pressure values and the times corresponding to the multiple target pressure values;
[0020] Determine multiple peak values and multiple trough values in the pressure line graph;
[0021] First-order difference calculation is performed on the multiple peak values to obtain multiple peak difference values;
[0022] First-order difference calculation is performed on the multiple trough values to obtain multiple trough difference values;
[0023] If there is a target peak difference value among the plurality of peak differences that is greater than the third threshold, then the two peak values used to calculate the target peak difference value are determined as the target peak values.
[0024] If there is a target trough difference value greater than the third threshold value in the plurality of trough difference values, two trough values used to calculate the target trough difference value are determined as target trough values;
[0025] Converting the target peak values and the target trough values into the number of times of chewing by the cow based on the target peak values and the target trough values, to obtain the number of times of chewing by the cow.
[0026] In one embodiment, the converting the target peak values and the target trough values into the number of times of chewing by the cow based on the target peak values and the target trough values, to obtain the number of times of chewing by the cow, comprises:
[0027] The target peak values and the target trough values of the same period are divided into a group, and the number of peak-trough groups is determined;
[0028] The number of peak-trough groups is multiplied by a preset multiple to obtain the number of times of chewing by the cow in the second time sequence.
[0029] In one embodiment, the second time sequence is determined based on the following manner:
[0030] The plurality of calibrated pressure values are input into a chewing behavior recognition model to obtain a chewing behavior recognition result output by the chewing behavior recognition model; the chewing behavior recognition model is trained based on pressure value samples and chewing behavior labels corresponding to the pressure value samples;
[0031] The continuous time instants corresponding to the chewing behavior recognition result are determined as the second time sequence.
[0032] In one embodiment, the chewing behavior recognition model is trained by the following manner:
[0033] Pressure value samples, frame image samples and environmental temperature value samples of the bridge of the cow's nose in a third time sequence are obtained;
[0034] The pressure value samples are calibrated based on the environmental temperature value samples to obtain calibrated pressure value samples;
[0035] The calibrated pressure value samples at the same time instant are behavior-labeled based on the frame image samples to obtain chewing behavior labels;
[0036] The chewing behavior recognition model is obtained based on the calibrated pressure value samples and the chewing behavior labels.
[0037] In a second aspect, the present application further provides a device for monitoring the number of times of chewing by a cow, comprising:
[0038] An acquisition module is configured to acquire a plurality of initial pressure values and environmental temperature values of the bridge of the cow's nose in a first time sequence.
[0039] The calibration module is used to calibrate the plurality of initial pressure values based on the ambient temperature value, thereby obtaining a plurality of calibration pressure values.
[0040] An extraction module is used to extract multiple target pressure values from the plurality of calibration pressure values; the second time series is a time series of the chewing behavior of the cow within the first time series.
[0041] The chewing count conversion module is used to convert the number of chewing counts of cattle based on the multiple target pressure values to obtain the number of chewing counts of cattle.
[0042] Thirdly, the present invention provides an apparatus comprising an electronic device, the electronic device including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the steps of any of the above-described methods for monitoring the number of chewing cycles in cattle.
[0043] Fourthly, the present invention also provides a medium comprising a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of any of the above-described methods for monitoring the number of bovine chewing strokes.
[0044] The present invention provides a method, apparatus, device, and medium for monitoring the number of chewing actions in cattle. Based on the ambient temperature value, multiple initial pressure values of the cattle's nasal bridge are calibrated to ensure the accuracy of the initial pressure values. Therefore, the target pressure values extracted from the multiple calibrated initial pressure values under chewing behavior are also accurate. Furthermore, the number of chewing actions in cattle is converted based on multiple target pressure values to obtain a more accurate number of chewing actions in cattle. This realizes automated monitoring of the number of chewing actions in cattle, solves the difficulty in calculating quantitative indicators of cattle behavior, and thus improves the monitoring efficiency of the number of chewing actions in cattle. Attached Figure Description
[0045] To more clearly illustrate the technical solutions in this invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.
[0046] Figure 1 This is one of the flowcharts of the method for monitoring the number of chewing cycles in cattle provided by the present invention;
[0047] Figure 2 This is the second flowchart of the method for monitoring the number of chewing cycles in cattle provided by the present invention;
[0048] Figure 3 This is the pressure line graph provided by the present invention;
[0049] Figure 4 is a structural schematic diagram of a cow chewing frequency monitoring device provided by the present application.
[0050] Figure 5 is a structural schematic diagram of an electronic device provided by the present application. DETAILED DESCRIPTION
[0051] In order to make the objects, technical solutions and advantages of the present application clearer, the technical solutions in the present application will be described clearly and completely below in conjunction with the drawings in the present application. Obviously, the described embodiments are some of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative labor fall within the scope of protection of the present application.
[0052] It should be noted that, in the description of the present application, the term "comprising" or any other variant thereof is intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements not only includes those elements, but also includes other elements not explicitly listed or inherent to such a process, method, article or device. The terms "upper", "lower" and the like indicate the orientation or positional relationship shown in the drawings, and are only used to facilitate the description of the present application and simplify the description, and do not indicate or imply that the devices or elements referred to must have a particular orientation, be constructed and operated in a particular orientation, and therefore cannot be understood as a limitation on the present application. For those skilled in the art, the specific meaning of the above terms in the present application can be understood according to the specific circumstances.
[0053] The terms "first", "second" and the like in the present application are used to distinguish similar objects, and are not used to describe a particular order or sequence. It should be understood that the data thus used can be interchanged under appropriate circumstances, so that the embodiments of the present application can be implemented in an order other than that illustrated or described herein, and the objects distinguished by "first", "second" and the like are generally of a kind and do not limit the number of objects, for example, the first object can be one or more.
[0054] The cow chewing frequency monitoring method, device, equipment and medium provided by the present application will be described below in conjunction with Figures 1-5 The cow chewing frequency monitoring method, device, equipment and medium provided by the present application will be described below in conjunction with
[0055] Figure 1 is one of the flowcharts of the cow chewing frequency monitoring method provided by the present application, Figure 2 is another flowchart of the cow chewing frequency monitoring method provided by the present application.
[0056] As Figure 1As shown, the method for monitoring the number of chews in cattle provided by this invention includes, but is not limited to, the following steps:
[0057] Step 100: Obtain multiple initial pressure values and ambient temperature values of the cow's nasal bridge within the first time series;
[0058] Step 200: Based on the ambient temperature value, calibrate the plurality of initial pressure values respectively to obtain a plurality of calibrated pressure values;
[0059] Step 300: Extract multiple target pressure values from the plurality of calibration pressure values according to the second time series;
[0060] Step 400: Based on the multiple target pressure values, convert the number of chewing cycles of the cow to obtain the number of chewing cycles of the cow.
[0061] It should be noted that the cattle chewing frequency monitoring method provided in this embodiment of the invention is implemented based on a cattle chewing frequency monitoring device. This method identifies the behavior of cattle, specifically chewing behavior, including chewing behavior under feeding conditions and chewing behavior under rumination conditions. It calculates corresponding behavioral signal features using a peak-valley number monitoring method, and then obtains an automatic calculation method for cattle chewing behavior by analyzing the relationship between these behavioral signal features and actual behavior. Behavior recognition is fundamental, while counting behavioral signal features is crucial, depending on the amplitude and frequency of the cattle's movements. This cattle chewing frequency monitoring method can meet the needs of monitoring and identifying cattle chewing behavior, as well as the need to calculate quantitative indicators of this behavior. This helps farmers accurately assess cattle feed intake, feed digestibility, and gain a more accurate understanding of cattle activity levels and behavioral habits. Therefore, this embodiment of the invention uses a cattle chewing frequency monitoring device as the executing entity to describe the cattle chewing frequency monitoring method.
[0062] Specifically, such as Figure 2 As shown, the following description is the process of obtaining the initial pressure value and ambient temperature value of the cow's nose bridge. Therefore, it can be understood that the cow chewing frequency monitoring device obtains multiple initial pressure values and ambient temperature values of the cow in the first time series.
[0063] It should be noted that the cattle are wearing wearable behavior monitoring devices on their heads. The data collection frequency of these devices is around 5Hz. The devices contain built-in hydraulic and temperature sensors. The hydraulic sensors are used to collect the pressure values of the cattle when they are feeding or ruminating, while the temperature sensors are used to collect the ambient temperature values of the pasture or breeding area. The specific values need to be determined based on the actual location of the cattle.
[0064] Further, the cow chewing frequency monitoring device calibrates the plurality of initial pressure values based on the ambient temperature value to obtain a plurality of calibrated pressure values.
[0065] Further, as Figure 2 shown, the following description is the process of identifying the chewing behavior of the cow, so it can be understood that the cow chewing frequency monitoring device inputs the plurality of calibrated pressure values into the chewing behavior identification model to obtain the chewing behavior identification result output by the chewing behavior identification model.
[0066] It should be noted that the chewing behavior identification result includes the chewing behavior identification result of the cow under the condition of feeding and the chewing behavior identification result of the cow under the condition of rumination. In an embodiment, the two kinds of chewing behavior identification results can be distinguished, and then the chewing frequency under the condition of feeding and the chewing frequency under the condition of rumination can be calculated respectively. The embodiment of the present application takes the case where the two kinds of chewing behavior identification results are not distinguished as an example, and the chewing frequency of the cow under the chewing behavior is calculated as a whole.
[0067] Further, the cow chewing frequency monitoring device determines the continuous time corresponding to the chewing behavior identification result as a second time sequence.
[0068] It should be noted that when the cow performs the chewing behavior, the hydraulic sensor at the bridge of the nose will be continuously squeezed, and it is a continuous process throughout the process. Therefore, after identifying the chewing behavior identification result of the cow, the continuous time corresponding to the chewing behavior identification result is determined as the second time sequence, and the plurality of target pressure values in the second time sequence are further obtained for subsequent quantitative index calculation of the cow chewing frequency.
[0069] Further, as Figure 2 shown, the following description is the process of extracting the target pressure value when the chewing behavior is extracted, so it can be understood that the cow chewing frequency monitoring device extracts the plurality of target pressure values from the plurality of calibrated pressure values according to the second time sequence, that is, extracts the plurality of target pressure values of the cow when performing the chewing behavior.
[0070] It should be noted that when obtaining the plurality of target pressure values of the bridge of the nose of the cow in the second time sequence, the time, intensity, frequency and other information of each chewing behavior are recorded. When obtaining the plurality of target pressure values in the second time sequence, the accuracy and integrity of the data need to be ensured. For each chewing behavior, all related sensor data need to be recorded as much as possible to provide more accurate analysis and evaluation.
[0071] Further, the cow chewing frequency monitoring device converts the cow chewing frequency based on the plurality of calibrated pressure values to obtain the cow chewing frequency.
[0072] The method for monitoring the number of chewing actions in cattle provided by this invention calibrates multiple initial pressure values on the bridge of the cow's nose based on the ambient temperature value to ensure the accuracy of the initial pressure values. Therefore, the target pressure value extracted from the multiple calibrated initial pressure values under chewing behavior is also accurate. Furthermore, the number of chewing actions in cattle is converted based on multiple target pressure values to obtain a more accurate number of chewing actions in cattle, realizing automated monitoring of the number of chewing actions in cattle, solving the difficulty of calculating quantitative indicators of cattle behavior, and thus improving the monitoring efficiency of the number of chewing actions in cattle.
[0073] Further, based on step 200, when calibrating the plurality of initial pressure values based on the ambient temperature value to obtain a plurality of calibrated pressure values, the following steps are performed for each initial pressure value:
[0074] If the ambient temperature value is less than or equal to the first threshold, then a calibration calculation is performed based on the first preset calibration value, the ambient temperature value, the initial pressure value, and the first threshold to obtain the calibration pressure value;
[0075] If the ambient temperature value is greater than the first threshold and less than the second threshold, then the initial pressure value is determined as the calibration pressure value.
[0076] If the ambient temperature value is greater than or equal to the second threshold, then a calibration calculation is performed based on the second preset calibration value, the ambient temperature value, the initial pressure value, and the second threshold to obtain the calibration pressure value.
[0077] Specifically, such as Figure 2 As shown, the following description is based on the ambient temperature value to calibrate the initial pressure value. Therefore, it can be understood that the cow chewing number monitoring device compares the ambient temperature value with the first threshold and the second threshold respectively. The first threshold and the second threshold are set according to the actual situation. The second threshold is greater than the first threshold. In one embodiment, the first threshold is 0°C and the second threshold is 20°C.
[0078] Furthermore, if the ambient temperature value is less than or equal to the first threshold, i.e., the ambient temperature value ≤ the first threshold, the cow chewing frequency monitoring device performs calibration calculations based on the first preset calibration value, the ambient temperature value, the initial pressure value, and the first threshold to obtain the calibration pressure value.
[0079] Furthermore, if the ambient temperature value is greater than the first threshold and less than the second threshold, i.e., the first threshold < ambient temperature value < the second threshold, the cow chewing frequency monitoring device will determine the initial pressure value as the calibration pressure value. In other words, under the current ambient temperature value, the initial pressure value is not significantly affected and will not shift, so there is no need to calibrate the initial pressure value.
[0080] Further, if the environment temperature value is greater than or equal to the second threshold value, i.e., the environment temperature value ≥ the second threshold value, the cow chewing frequency monitoring device performs calibration calculation based on the second preset calibration value, the environment temperature value, the initial pressure value and the second threshold value to obtain a calibrated pressure value.
[0081] According to different environment temperature value ranges, the embodiment of the present application adopts different pressure value calibration methods to flexibly calibrate sensor data under different environment temperatures, so as to obtain more accurate pressure values, and then based on the accurate pressure values, the cow chewing frequency conversion is performed to obtain more accurate cow chewing frequency, so as to realize automatic monitoring of the cow chewing frequency under the chewing behavior of the cow, solve the difficulty in calculating the quantitative index of the cow behavior, and thus improve the monitoring efficiency of the cow chewing frequency under the chewing behavior of the cow.
[0082] Further, the calibration calculation based on the second preset calibration value, the environment temperature value, the initial pressure value and the second threshold value to obtain a calibrated pressure value comprises:
[0083] The environment temperature value is subtracted from the first threshold value to obtain a difference value;
[0084] The difference value is multiplied by the first preset calibration value to obtain a product;
[0085] The product is added to the initial pressure value to obtain a calibrated pressure value.
[0086] Specifically, when the environment temperature value is less than or equal to the first threshold value, the cow chewing frequency monitoring device subtracts the environment temperature value from the first threshold value to obtain a difference value between the environment temperature value and the first threshold value.
[0087] Further, the cow chewing frequency monitoring device multiplies the difference value by the first preset calibration value to obtain a product of the difference value and the first preset calibration value, wherein the first preset calibration value is set according to actual conditions.
[0088] Further, the cow chewing frequency monitoring device adds the product to the initial pressure value to obtain a calibrated pressure value.
[0089] Further, when the environment temperature value is greater than or equal to the second threshold value, the cow chewing frequency monitoring device subtracts the environment temperature value from the second threshold value to obtain a difference value between the environment temperature value and the second threshold value.
[0090] Further, the cow chewing frequency monitoring device multiplies the difference value by the second preset calibration value to obtain a product of the difference value and the second preset calibration value, wherein the second preset calibration value is set according to actual conditions.
[0091] Further, the cow chewing frequency monitoring device adds the product to the initial pressure value to obtain a calibrated pressure value.
[0092] In an embodiment, the first threshold value is 0 DEG C, the second threshold value is 20 DEG C, the initial pressure value obtained by the hydraulic sensor when the ambient temperature is T is P, the initial pressure value monitored by the hydraulic sensor is calibrated by temperature compensation to obtain the calibrated calibration pressure value P' when the ambient temperature is T, therefore, the calibration calculation method is as shown below:
[0093] When T≤0 DEG C, P'=A1 x (T-0)+P
[0094] When 0 DEG C
[0095] When T≥20 DEG C, P'=A2 x (T-20)+P
[0096] Wherein, A1 is a first preset calibration value, A2 is a second preset calibration value, A1 and A2 can be obtained by the following method: according to the hydraulic sensor data under different temperatures of the same external pressure, a preset relationship between the pressure value and the ambient temperature value is established. When a fixed pressure value P0 is applied, the pressure values detected at-20 DEG C, 0 DEG C, 20 DEG C and 40 DEG C are P1, P2, P3 and P4 respectively, then
[0097] According to different ambient temperature value ranges, the sensor data under different ambient temperatures is calibrated flexibly by the temperature compensation calculation method, so as to obtain a more accurate pressure value, and then the number of cattle chewing times can be converted based on the accurate pressure value, so as to obtain a more accurate number of cattle chewing times, realize automatic monitoring of the number of cattle chewing times under chewing behavior, solve the difficulty of calculating the cattle behavior quantization index, and improve the monitoring efficiency of the number of cattle chewing times under chewing behavior.
[0098] Further, the second time sequence is determined based on the following method:
[0099] The plurality of calibration pressure values are input into the chewing behavior recognition model to obtain a chewing behavior recognition result output by the chewing behavior recognition model; the chewing behavior recognition model is trained based on pressure value samples and chewing behavior labels corresponding to the pressure value samples;
[0100] The continuous time corresponding to the chewing behavior recognition result is determined as the second time sequence.
[0101] Specifically, the cattle chewing times monitoring device inputs the plurality of calibration pressure values into the chewing behavior recognition model to obtain a chewing behavior recognition result output by the chewing behavior recognition model.
[0102] It should be noted that before the plurality of initial pressure values are input into the model, preprocessing can be performed, which can include denoising processing, filtering processing, feature extraction, and data normalization, etc. Preprocessing methods, so as to facilitate the chewing behavior recognition model to calculate.
[0103] Further, the cow chewing frequency monitoring device determines the continuous time corresponding to the chewing behavior recognition result as the second time sequence.
[0104] The embodiment of the present application inputs a plurality of accurate calibration pressure values into the chewing behavior recognition model, accurately identifies the chewing behavior recognition result through the chewing behavior recognition model, further determines the second time sequence at the continuous time according to the chewing behavior recognition result, and then can obtain a plurality of target pressure values of the bridge of the cow's nose during chewing, which is used for subsequent quantitative index calculation of the cow's chewing frequency, so as to realize automatic monitoring of the cow's chewing frequency under the chewing behavior.
[0105] Further, the chewing behavior recognition model is obtained by the following method:
[0106] The bridge of the cow sample is obtained in the third time sequence, and the pressure value sample, the frame image sample and the environmental temperature value sample are obtained.
[0107] Based on the environmental temperature value sample, the pressure value sample is calibrated to obtain the calibration pressure value sample;
[0108] Based on the frame image sample, the calibration pressure value sample at the same time is behavior labeled to obtain the chewing behavior label;
[0109] Based on the calibration pressure value sample and the chewing behavior label, the model is trained to obtain the chewing behavior recognition model.
[0110] Specifically, the cow chewing frequency monitoring device obtains the pressure value sample, the frame image sample and the environmental temperature value sample of the bridge of the cow sample in the third time sequence.
[0111] It should be noted that the pressure value sample can be collected by a wearable behavior monitoring device, and the frame image sample can be obtained by frame image extraction from the video shot by the camera for the cow behavior. The selected camera needs to ensure that the chewing behavior of the cow in the shot video can be clearly visible.
[0112] Further, the cow chewing frequency monitoring device calibrates the pressure value sample based on the environmental temperature value sample to obtain the calibration pressure value sample. The above described pressure value calibration method is not repeated here.
[0113] Further, the cow chewing frequency monitoring device determines the behavior of the cow sample based on the frame image sample, and according to the behavior of the cow sample, behavior labels are marked on the pressure value samples at the same time, and the chewing behavior labels are obtained.
[0114] Further, the cow chewing frequency monitoring device performs model training based on the calibrated pressure value sample and the chewing behavior label, and obtains a chewing behavior recognition model.
[0115] The embodiment of the present application is based on frame image samples, and behavior labels are marked on pressure value samples at the same time, and chewing behavior labels of the calibrated pressure value sample when performing chewing behavior are obtained. Further, model training is performed based on the calibrated pressure value sample and the chewing behavior label, and a chewing behavior recognition model is obtained. The chewing behavior recognition model can be used to realize accurate chewing behavior recognition, meet the demand for monitoring and identifying the chewing behavior of the cow, and then the quantitative index of the chewing frequency of the cow can be calculated after the chewing behavior recognition result is known. The chewing frequency of the cow under the chewing behavior can be automatically monitored, the difficulty of calculating the quantitative index of the cow behavior is solved, and the chewing frequency monitoring efficiency of the cow under the chewing behavior is improved.
[0116] Further, based on step 300, the cow chewing frequency conversion based on the plurality of target pressure values is performed to obtain the cow chewing frequency, including:
[0117] Based on the plurality of target pressure values and the time corresponding to each target pressure value, a pressure fold line graph is constructed;
[0118] A plurality of peak values and a plurality of valley values in the pressure fold line graph are determined;
[0119] First-order difference calculation is performed on the plurality of peak values to obtain a plurality of peak difference values;
[0120] First-order difference calculation is performed on the plurality of valley values to obtain a plurality of valley difference values;
[0121] If there is a target peak difference value greater than a third threshold value in the plurality of peak difference values, the two peak values used to calculate the target peak difference value are determined as target peak values;
[0122] If there is a target valley difference value greater than the third threshold value in the plurality of valley difference values, the two valley values used to calculate the target valley difference value are determined as target valley values;
[0123] Based on each target peak value and each target valley value, the cow chewing frequency conversion is performed to obtain the cow chewing frequency.
[0124] Specifically, as Figure 2As shown, the following description illustrates the process of detecting the effective number of peak and trough groups. Therefore, it can be understood that the cattle chewing frequency monitoring device constructs a pressure line graph based on multiple target pressure values and the corresponding times for each target pressure value. It should be noted that during chewing, the hydraulic sensor at the bridge of the nose is subjected to continuous compression, thus forming a pressure line graph as shown below. Figure 3 As shown, Figure 3 This is the pressure line graph provided by the present invention.
[0125] Furthermore, the bovine chewing frequency monitoring device determines multiple peak values and multiple trough values in the pressure line graph.
[0126] It should be noted that multiple calibration pressure values can be imported into a programming language (such as Python). The `optimize` module in the programming language's database can be used to calculate the extreme points of a data set, with the maxima representing peaks and the minima representing troughs. Additionally, sometimes a signal may contain peaks and troughs with very small peak values. These peaks and troughs may be caused by noise or other interference. Therefore, these peaks and troughs with very small peak values can be considered noise, which does not represent the main characteristics of the signal and may even interfere with signal analysis and processing. Therefore, these noisy signals need to be discarded, and only the number of peaks and troughs with large peak values needs to be counted subsequently.
[0127] Furthermore, the cattle chewing frequency monitoring device performs first-order difference calculations on multiple peak values to obtain multiple peak difference values, and performs first-order difference calculations on multiple trough values to obtain multiple trough difference values.
[0128] It should be noted that the first difference refers to the difference between two adjacent observations in time series data. For a time series {x1, x2, x3, ..., x...}, ... n Its first-order difference can be expressed as {Δx1, Δx2, Δx3, ..., Δx}. n-1}, where Δx i =x i+1 -x i 1≤i≤n-1. First-order differences are commonly used in time series analysis to help extract trends and changes in data. By calculating the first-order differences, the rate of change or increase / decrease of the original data at adjacent time points can be obtained, which helps in analyzing the trend characteristics of the data.
[0129] Furthermore, the cow chewing frequency monitoring device compares the value of each peak value with the third threshold and compares the value of each trough value with the third threshold. The third threshold is set according to the actual situation. In one embodiment, the third threshold is 2.
[0130] Furthermore, if there is a peak difference among multiple peak differences that is less than or equal to the third threshold, the cattle chewing frequency monitoring device will discard the peak difference that is less than or equal to the third threshold. Similarly, if there is a trough difference among multiple trough differences that is less than or equal to the third threshold, the cattle chewing frequency monitoring device will discard the trough difference that is less than or equal to the third threshold.
[0131] Furthermore, if among the multiple peak differences there is a target peak difference greater than the third threshold, the cow chewing count monitoring device will determine the two peak values used to calculate the target peak value as the target peak value.
[0132] Furthermore, if among the multiple valley differences there is a target valley difference value greater than the third threshold, the cattle chewing frequency monitoring device will determine the two valley values used to calculate the target valley difference value as the target valley value.
[0133] Furthermore, the cattle chewing count monitoring device converts the number of cattle chewing counts based on the peak and trough values of each target wave to obtain the number of cattle chewing counts.
[0134] This invention constructs a pressure line graph based on multiple calibration pressure values. The pressure line graph reflects the chewing action in each cycle. The number of chewing actions is then calculated using peaks and troughs as indicators. Before calculating the number of chewing actions, a first-order difference calculation method is used to remove noise with small peak values and only calculate the effective peaks and troughs, which can improve the accuracy of the subsequent calculation of the number of chewing actions in cattle.
[0135] Furthermore, the conversion of the number of chewing strokes of the cow based on the peak and trough values of each target wave to obtain the number of chewing strokes includes:
[0136] The target peak and target trough values with the same period are grouped together, and the number of peak and trough groups is determined.
[0137] Multiply the number of peak and trough groups by a preset multiple to obtain the number of times the cow chews in the second time series.
[0138] Specifically, such as Figure 2 As shown, the following description is the process of determining the conversion relationship between the number of peak and trough groups and the number of chewing times. Therefore, it can be understood that the cow chewing time monitoring device divides the target peak value and target trough value of the same period into a group and determines the number of peak and trough groups, that is, the number of peaks and troughs.
[0139] It should be noted that the jaw movement during chewing is a reciprocating motion, with alternating peaks and troughs. A peak plus a trough is considered a complete and valid data set, recorded as a peak-trough group, or a peak-trough count. For example... Figure 3As shown, one cycle contains a maximum value and a minimum value, so one cycle contains a peak value and a trough value, which is divided into a group, denoted as an effective peak-trough group.
[0140] It needs to be further explained that, in an embodiment, since the target pressure value is continuous time series data, in order to construct the conversion relationship between the number of peak-trough groups and the number of chewing, first, the time is divided into 1 minute a group, and the number of peak-trough groups and the number of chewing in 2 hours are compared, and after analysis, the result shows that the number of chewing in each minute and the number of peak-trough groups are in a multiple relationship.
[0141] Further, the cattle chewing number monitoring device multiplies the number of peak-trough groups by a preset multiple to obtain the number of chewing of the cattle in the second time sequence.
[0142] In an embodiment, the number of chewing of the cattle in the second time sequence is calculated as follows:
[0143] P=k*N
[0144] Wherein, P is the number of chewing, k is the preset multiple, and N is the number of peak-trough groups.
[0145] The embodiment of the present application divides the effective peak and trough in the same cycle into a group to obtain the number of peak-trough groups, since the number of peak-trough groups can reflect the number of reciprocating actions when the mandible moves, the conversion relationship between the number of peak-trough groups and the number of chewing can be determined, based on the conversion relationship, the number of chewing can be measured and calculated, and the number of chewing of the cattle under the chewing behavior can be automatically monitored, the calculation difficulty of the cattle behavior quantitative index is solved, and the efficiency of monitoring the number of chewing of the cattle under the chewing behavior is improved.
[0146] Further, the present application also provides a cattle chewing number monitoring device.
[0147] Reference Figure 4 , Figure 4 It is a structural schematic diagram of the cattle chewing number monitoring device provided by the present application.
[0148] The cattle chewing number monitoring device comprises:
[0149] The acquisition module 410 is configured to acquire a plurality of initial pressure values and an ambient temperature value of the bridge of the nose of the cattle in a first time sequence.
[0150] The calibration module 420 is configured to calibrate the plurality of initial pressure values based on the ambient temperature value to obtain a plurality of calibrated pressure values.
[0151] The extraction module 430 is configured to extract a plurality of target pressure values from the plurality of calibration pressure values; and the second time sequence is a time sequence of the chewing behavior of the cow in the first time sequence.
[0152] The chewing frequency conversion module 440 is configured to convert the chewing frequency of the cow based on the plurality of target pressure values to obtain the chewing frequency of the cow.
[0153] The cow chewing frequency monitoring device provided by the present application can calibrate a plurality of initial pressure values of the bridge of the nose of the cow based on an environmental temperature value, ensure the accuracy of the initial pressure values, and thus ensure the accuracy of the target pressure values under the chewing behavior extracted from the plurality of calibrated initial pressure values. Furthermore, the cow chewing frequency monitoring device can convert the chewing frequency of the cow based on the plurality of target pressure values to obtain a more accurate chewing frequency of the cow, automatically monitor the chewing frequency of the cow under the chewing behavior, and solve the difficulty in calculating the quantitative index of the behavior of the cow, thereby improving the monitoring efficiency of the chewing frequency of the cow under the chewing behavior.
[0154] Further, the cow chewing frequency monitoring device is further configured to:
[0155] input the plurality of calibration pressure values into a chewing behavior recognition model to obtain a chewing behavior recognition result output by the chewing behavior recognition model; and the chewing behavior recognition model is trained based on pressure value samples and chewing behavior labels corresponding to the pressure value samples.
[0156] determine a continuous time corresponding to the chewing behavior recognition result as a second time sequence.
[0157] Further, the cow chewing frequency monitoring device is further configured to:
[0158] obtain pressure value samples, frame image samples, and environmental temperature value samples of the bridge of the nose of the cow sample in a third time sequence;
[0159] calibrate the pressure value samples based on the environmental temperature value samples to obtain calibration pressure value samples;
[0160] perform behavior labeling on the calibration pressure value samples at the same time based on the frame image samples to obtain chewing behavior labels;
[0161] perform model training based on the calibration pressure value samples and the chewing behavior labels to obtain the chewing behavior recognition model.
[0162] Further, the calibration module 420 is further configured to:
[0163] if the environmental temperature value is less than or equal to a first threshold value, perform calibration calculation based on a first preset calibration value, the environmental temperature value, the initial pressure value, and the first threshold value to obtain a calibration pressure value.
[0164] If the ambient temperature value is greater than the first threshold and less than the second threshold, then the initial pressure value is determined as the calibration pressure value.
[0165] If the ambient temperature value is greater than or equal to the second threshold, then a calibration calculation is performed based on the second preset calibration value, the ambient temperature value, the initial pressure value, and the second threshold to obtain the calibration pressure value.
[0166] Furthermore, the calibration module 420 is also used for:
[0167] Subtract the ambient temperature value from the first threshold to obtain the difference;
[0168] Multiply the difference by the first preset calibration value to obtain the product;
[0169] The product is added to the initial pressure value to obtain the calibration pressure value.
[0170] Furthermore, the chewing count conversion module 440 is also used for:
[0171] A pressure line graph is constructed based on the multiple target pressure values and the times corresponding to the multiple target pressure values;
[0172] Determine multiple peak values and multiple trough values in the pressure line graph;
[0173] First-order difference calculation is performed on the multiple peak values to obtain multiple peak difference values;
[0174] The first-order difference calculation is performed on the multiple trough values to obtain multiple trough difference values;
[0175] If there is a target peak difference value among the plurality of peak differences that is greater than the third threshold, then the two peak values used to calculate the target peak difference value are determined as the target peak values.
[0176] If there is a target valley difference value among the plurality of valley differences that is greater than the third threshold, then the two valley values used to calculate the target valley difference value are determined as target valley values.
[0177] The number of chewing cycles of a cow is obtained by converting the peak and trough values of each target wave.
[0178] Furthermore, the chewing count conversion module 440 is also used for:
[0179] The target peak and target trough values with the same period are grouped together, and the number of peak and trough groups is determined.
[0180] The peak-valley group number is multiplied by a preset multiple to obtain the number of times of chewing of the cow in the second time sequence.
[0181] It should be noted that the cow chewing frequency monitoring device provided by the present application can execute the cow chewing frequency monitoring method described in any of the above embodiments during actual operation, and this embodiment will not be described here.
[0182] Figure 5 is a structural schematic diagram of an electronic device provided by the present application, as Figure 5 shown, the electronic device can include a processor 510, a communications interface 520, a memory 530, and a communications bus 540, wherein the processor 510, the communications interface 520, and the memory 530 communicate with each other through the communications bus 540. The processor 510 can call the logic instructions in the memory 530 to execute the cow chewing frequency monitoring method, which includes: obtaining a plurality of initial pressure values and environmental temperature values of the bridge of the cow in a first time sequence; based on the environmental temperature values, calibrating the plurality of initial pressure values respectively to obtain a plurality of calibrated pressure values; extracting a plurality of target pressure values from the plurality of calibrated pressure values according to a second time sequence; the second time sequence is the time sequence of the cow's chewing behavior in the first time sequence; based on the plurality of target pressure values, the cow chewing frequency conversion is performed to obtain the number of times of chewing of the cow.
[0183] In addition, the logic instructions in the memory 530 described above can be implemented in the form of a software function unit and sold or used as an independent product, which can be stored in a computer readable storage medium. Based on such understanding, the technical solutions of the present application essentially or the part that contributes to the prior art or part of the technical solutions can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a plurality of instructions to make a computer device (which can be a personal computer, a server, or a network device, etc.) execute all or part of the steps of the method described in the various embodiments of the present application. The foregoing storage medium includes: a U disk, a mobile hard disk, a read-only memory (ROM, Read-Only Memory), a random access memory (RAM, Random Access Memory), a magnetic disk or an optical disk, and various program code storage media.
[0184] In another aspect, the present application also provides a computer program product comprising a computer program stored on a non-transitory computer-readable storage medium, the computer program comprising program instructions that, when executed by a computer, enable the computer to perform the method for monitoring the number of times of chewing of a cow provided by any of the above embodiments, the method comprising: obtaining a plurality of initial pressure values and an ambient temperature value of a bridge of a nose of the cow in a first time sequence; calibrating the plurality of initial pressure values respectively based on the ambient temperature value to obtain a plurality of calibrated pressure values; extracting a plurality of target pressure values from the plurality of calibrated pressure values in a second time sequence; the second time sequence is a time sequence of chewing behavior of the cow in the first time sequence; and performing cow chewing number conversion based on the plurality of target pressure values to obtain the number of times of chewing of the cow.
[0185] In yet another aspect, the present application also provides a non-transitory computer-readable storage medium having a computer program stored thereon, the computer program being executed by a processor to implement the method for monitoring the number of times of chewing of a cow provided by any of the above embodiments, the method comprising: obtaining a plurality of initial pressure values and an ambient temperature value of a bridge of a nose of the cow in a first time sequence; calibrating the plurality of initial pressure values respectively based on the ambient temperature value to obtain a plurality of calibrated pressure values; extracting a plurality of target pressure values from the plurality of calibrated pressure values in a second time sequence; the second time sequence is a time sequence of chewing behavior of the cow in the first time sequence; and performing cow chewing number conversion based on the plurality of target pressure values to obtain the number of times of chewing of the cow.
[0186] The device embodiments described above are merely illustrative, wherein the units described as separate components can or can not be physically separate, and the components shown as units can or can not be physical units, i.e., they can be located in one place, or distributed on multiple network units. Part or all of the modules can be selected to achieve the purpose of the embodiment according to actual needs. Those skilled in the art can understand and implement without creative labor.
[0187] From the above description of the embodiments, those skilled in the art can clearly understand that the embodiments can be implemented by means of software plus necessary general hardware platforms, and of course can also be implemented by hardware. Based on such understanding, the above technical solutions, essentially or in terms of the contribution to the prior art, can be embodied in the form of a software product. The computer software product can be stored in a computer readable storage medium, such as a ROM / RAM, a magnetic disk, an optical disk, etc., and includes a plurality of instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in the various embodiments or some parts of the embodiments.
[0188] It should be pointed out finally that the above embodiments are only used to illustrate the technical solutions of the present application, but not to limit the same; and although the present application has been described in detail with reference to the foregoing embodiments, it should be appreciated by those skilled in the art that the technical solutions recorded in the foregoing embodiments can be modified, or some technical features thereof can be replaced equivalently; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present application.
Claims
1. A method for monitoring the number of chewing cycles in cattle, characterized in that, include: Multiple initial pressure values and ambient temperature values of the nasal bridge of a cow were obtained within the first time series. Based on the ambient temperature value, the plurality of initial pressure values are calibrated respectively to obtain a plurality of calibrated pressure values; According to the second time series, multiple target pressure values are extracted from the plurality of calibration pressure values; the second time series is a time series of the chewing behavior of the cow within the first time series. Based on the multiple target pressure values, the number of chewing cycles of the cow is converted to obtain the number of chewing cycles of the cow; When calibrating the plurality of initial pressure values based on the ambient temperature value to obtain a plurality of calibrated pressure values, the following steps are performed for each initial pressure value: If the ambient temperature value is less than or equal to the first threshold, then a calibration calculation is performed based on the first preset calibration value, the ambient temperature value, the initial pressure value, and the first threshold to obtain the calibration pressure value; If the ambient temperature value is greater than the first threshold and less than the second threshold, then the initial pressure value is determined as the calibration pressure value. If the ambient temperature value is greater than or equal to the second threshold, then a calibration calculation is performed based on the second preset calibration value, the ambient temperature value, the initial pressure value, and the second threshold to obtain the calibration pressure value; The calibration calculation based on the first preset calibration value, the ambient temperature value, the initial pressure value, and the first threshold to obtain the calibration pressure value includes: Subtract the ambient temperature value from the first threshold to obtain the difference; Multiply the difference by the first preset calibration value to obtain the product; The product is added to the initial pressure value to obtain the calibration pressure value.
2. The method for monitoring the number of chewing strokes in cattle according to claim 1, characterized in that, The process of converting the number of chewing strokes of a cow based on the multiple target pressure values to obtain the number of chewing strokes includes: A pressure line graph is constructed based on the multiple target pressure values and the times corresponding to the multiple target pressure values; Determine multiple peak values and multiple trough values in the pressure line graph; First-order difference calculation is performed on the multiple peak values to obtain multiple peak difference values; First-order difference calculation is performed on the multiple trough values to obtain multiple trough difference values; If there is a target peak difference value among the plurality of peak differences that is greater than the third threshold, then the two peak values used to calculate the target peak difference value are determined as the target peak values. If there is a target valley difference value among the plurality of valley differences that is greater than the third threshold, then the two valley values used to calculate the target valley difference value are determined as target valley values. The number of chewing cycles of a cow is obtained by converting the peak and trough values of each target wave.
3. The method for monitoring the number of chewing strokes in cattle according to claim 2, characterized in that, The conversion of the number of chewing strokes in cattle based on the peak and trough values of each target wave to obtain the number of chewing strokes includes: The target peak and target trough values of the same period are grouped together, and the number of peak and trough groups is determined. Multiply the number of peak and trough groups by a preset multiple to obtain the number of times the cow chews in the second time series.
4. The method for monitoring the number of chewing cycles in cattle according to claim 1, characterized in that, The second time series was determined based on the following method: The multiple calibration pressure values are input into the chewing behavior recognition model to obtain the chewing behavior recognition result output by the chewing behavior recognition model; the chewing behavior recognition model is trained based on pressure value samples and the chewing behavior labels corresponding to the pressure value samples. The consecutive moments corresponding to the chewing behavior recognition results are determined as the second time series.
5. The method for monitoring the number of chewing strokes in cattle according to claim 4, characterized in that, The chewing behavior recognition model was trained in the following manner: Obtain pressure value samples, frame image samples, and ambient temperature value samples of the bridge of the nose of the cattle samples in the third time series; Based on the ambient temperature value sample, the pressure value sample is calibrated to obtain a calibrated pressure value sample; Based on the frame image samples, the calibration pressure value samples at the same time are labeled with behavior to obtain chewing behavior labels; The chewing behavior recognition model is obtained by training the model based on the calibration pressure value samples and the chewing behavior labels.
6. A device for monitoring the number of times a cow chews, characterized in that, The method for monitoring the number of chewing strokes in cattle as described in any one of claims 1 to 5, wherein the cattle chewing stroke monitoring device comprises: The acquisition module is used to acquire multiple initial pressure values and ambient temperature values of the cow's nasal bridge within a first time series. The calibration module is used to calibrate the plurality of initial pressure values based on the ambient temperature value to obtain a plurality of calibration pressure values; An extraction module is used to extract multiple target pressure values from the plurality of calibration pressure values; the second time series is a time series of the chewing behavior of the cow within the first time series. The chewing count conversion module is used to convert the number of chewing counts of cattle based on the multiple target pressure values to obtain the number of chewing counts of cattle.
7. An apparatus comprising an electronic device, the electronic device including a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the steps of the method for monitoring the number of chewing cycles of cattle as described in any one of claims 1 to 5.
8. A medium comprising a non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the steps of the method for monitoring the number of chewing cycles of cattle as described in any one of claims 1 to 5.
Citation Information
Patent Citations
Data calibration method and device for air pressure sensor
CN109781341A
Apparatus for examining mastication state for ruminant
JP2003219757A