Indoor environment temperature adjusting method and system for modern livestock breeding

By collecting and analyzing the indoor and outdoor temperature and humidity data of animal husbandry, combining prediction and historical data to correct the temperature prediction value, and using the PID control system to perform temperature regulation, the problem of hysteresis of indoor temperature regulation in animal husbandry is solved, and the accuracy and timeliness of temperature regulation are improved.

CN119668327AActive Publication Date: 2025-03-21SHENZHEN CHENGCHENG HIGH-TECH CO LTD

Patent Information

Application Number
CN202510199373.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-02-24
Publication Date
2025-03-21
Estimated Expiration
2045-02-24

AI Technical Summary

Technical Problem

The existing indoor temperature regulation process of animal husbandry breeding has serious lag, which affects the stable maintenance of environmental conditions and leads to problems with meat safety and quality.

Method used

Different types of sensors collect indoor and outdoor temperature and humidity data, combine prediction algorithms to obtain prediction values, correct prediction results, analyze historical data to obtain historical prediction values, and finally use the PID control system to adjust the temperature.

Benefits of technology

It improves the accuracy and timeliness of indoor temperature adjustment, ensures the suitability of the animal husbandry environment, reduces user costs, and avoids losses caused by temperature discomfort.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119668327A_ABST
    Figure CN119668327A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of intelligent breeding, in particular to an indoor environment temperature adjusting method and system for modern livestock breeding. The method comprises the steps that temperature data and humidity data of the livestock breeding indoor environment and outdoor temperature data are collected; the predicted value of the indoor temperature is corrected according to the correlation between the indoor temperature and the outdoor temperature and the indoor humidity, the difference between the numerical values and the predicted values of the outdoor temperature and the indoor humidity, and a predicted corrected value is obtained; acquiring a historical predicted value of the current moment according to comparison between the predicted values of the indoor temperature, the outdoor temperature and the indoor humidity in the history and the current moment; obtaining an indoor temperature prediction value according to the prediction correction value, the historical prediction value and the similarity among the three-dimensional data points; and PID control is carried out according to the indoor temperature predicted value so as to control the temperature. According to the invention, the finally obtained prediction result is closer to the real temperature change value.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of intelligent breeding technology, and specifically to a method and system for regulating the indoor environmental temperature of modern animal husbandry. Background Art

[0002] In the process of animal husbandry, due to the strong variability of the external environment and the increasing frequency of major animal infectious diseases, meat safety and quality issues have become the main problems faced by the animal husbandry industry. With the continuous maturity of the Internet of Things technology, it is possible to monitor the indoor environment of animal husbandry. However, maintaining a constant indoor temperature is conducive to the production of high-quality livestock meat products. However, the current temperature control process in animal husbandry has serious lag, which is not conducive to maintaining the stable state of the animal husbandry environment. Summary of the invention

[0003] In order to solve the technical problem of inaccurate existing prediction algorithms, this application provides a method and system for regulating the indoor temperature of modern animal husbandry. The technical solutions adopted are as follows: In the first aspect, the present application proposes a method for regulating the indoor temperature of a modern livestock breeding environment, the method comprising the following steps: Collect temperature and humidity data of the indoor environment of livestock breeding and outdoor temperature data through different types of sensors; The next moment after the current moment is recorded as the predicted moment, and for a preset number of moments before the current moment, the predicted values ​​of the indoor temperature data, the outdoor temperature data and the indoor humidity data at the predicted moment are obtained through a prediction algorithm; different indoor temperature prediction values ​​are obtained according to the ratio of the indoor temperature data to the outdoor temperature data, the ratio of the indoor temperature data to the indoor humidity data and the predicted values ​​of the outdoor temperature data and the indoor temperature data at the predicted moment, and the predicted value of the indoor temperature data at the predicted moment is corrected by combining the respective proportions of the correlation coefficients of the indoor temperature data and the outdoor temperature data and the correlation coefficients of the indoor temperature data and the indoor humidity data with different indoor temperature prediction values ​​to obtain a prediction correction value; The indoor temperature, outdoor temperature and indoor humidity at each moment are used to form three-dimensional data points, and all three-dimensional data points are clustered; for the cluster at the current moment, the three-dimensional data points are used to form different sequences according to the indoor temperature, outdoor temperature and indoor humidity, and the sequences of different lengths are analyzed to obtain the similarity between the three-dimensional data points under different sequence lengths, and then the weights are formed in combination with the actual temperature values ​​to obtain the historical prediction value of the indoor temperature data; The indoor temperature prediction value is obtained according to the prediction correction value, the historical prediction value and the similarity between the three-dimensional data points; the temperature is controlled by PID control according to the indoor temperature prediction value.

[0004] In the above scheme, the present application combines the indoor humidity information and outdoor temperature information that affect the indoor temperature change, combines the prediction results obtained by the prediction algorithm, and corrects the prediction results obtained by the same prediction algorithm according to the correlation between these parameters and the indoor temperature parameters, thereby increasing the accuracy of the prediction results; further, by analyzing the historical data, by calculating the data sequence curves that may be similar to the temperature change trend corresponding to the current acquisition moment in different periodic sequences, the temperature value corresponding to the next moment of these data sequence curves is obtained as the historical prediction value, and by analyzing based on the historical data, the temperature change in the same scene can be better analyzed and determined, so that the obtained temperature prediction value is more in line with the historical change law, and the accuracy of the prediction result is increased; finally, by determining the weight coefficient of the above-obtained prediction value based on historical similar data, the accuracy of the prediction result obtained by using the above-mentioned prediction method according to the historical data analysis, the weight is determined based on the accuracy and stability analysis, so that the final prediction result is closer to the real temperature change value. Finally, based on the real-time collected data and the predicted temperature data as the input of the PID control system, the hysteresis of the temperature control of the PID control system can be reduced, the suitability of the indoor environmental temperature of animal husbandry can be guaranteed, the user cost can be reduced, and the loss caused by temperature discomfort can be avoided.

[0005] In one embodiment, the method of collecting temperature data and humidity data of the livestock breeding indoor environment and outdoor temperature data by using different types of sensors is: A temperature sensor and a humidity sensor are set in the indoor environment of the livestock breeding farm, and a temperature sensor is set outdoors in the livestock breeding farm. Each sensor collects data once every preset time, and collects a certain amount of data. The latest collected data and the data at t-1 moments before the current moment are recorded as a sequence, and the indoor temperature sequence, outdoor temperature sequence and indoor humidity sequence are obtained respectively.

[0006] In one embodiment, the method for obtaining different indoor temperature prediction values ​​according to the ratio of indoor temperature data to outdoor temperature data, the ratio of indoor temperature data to indoor humidity data, and the prediction values ​​of outdoor temperature data and indoor temperature data at the prediction time is: Calculate the ratio of the sequence values ​​of the indoor temperature sequence and the outdoor temperature sequence at the same time, and form a sequence of the ratios of all time points as the indoor and outdoor temperature ratio sequence; calculate the ratio of the sequence values ​​of the indoor temperature sequence and the indoor humidity sequence at the same time, and form a sequence of the ratios of all time points as the temperature and humidity ratio sequence; The average value of all sequence values ​​in the internal and external temperature ratio sequence is recorded as the first temperature ratio, and the average value of all sequence values ​​in the temperature and humidity ratio sequence is recorded as the first temperature and humidity ratio; The second indoor temperature prediction value and the third indoor temperature prediction value are obtained according to the first temperature ratio, the first greenhouse ratio, and the prediction values ​​of the outdoor temperature sequence and the indoor humidity sequence at the prediction time.

[0007] In one embodiment, the method for obtaining the second indoor temperature prediction value and the third indoor temperature prediction value according to the first temperature ratio, the first greenhouse ratio, and the prediction values ​​of the outdoor temperature sequence and the indoor humidity sequence at the prediction time is: In the formula, represents the predicted value of the outdoor temperature series at the prediction time, represents the first temperature ratio, represents the second indoor temperature prediction value, represents the predicted value of the indoor humidity series at the prediction time, Indicates the first temperature and humidity ratio, Indicates the third indoor temperature prediction value.

[0008] In one embodiment, the method of correcting the predicted value of the indoor temperature data at the prediction time by combining the respective proportions of the correlation coefficients of the indoor temperature data and the outdoor temperature data and the correlation coefficients of the indoor temperature data and the indoor humidity data with different indoor temperature prediction values ​​to obtain the predicted correction value is: Calculate the standard deviation of all sequence values ​​in the indoor-outdoor temperature ratio sequence, and use the inverse of the standard deviation as the correlation coefficient between the outdoor temperature sequence and the indoor temperature sequence; Calculate the standard deviation of all sequence values ​​in the temperature-humidity ratio sequence, and use the reciprocal of the standard deviation as the correlation coefficient between the indoor temperature sequence and the indoor humidity sequence; The predicted value of the indoor temperature data obtained by the prediction algorithm at the prediction time is recorded as the first indoor predicted temperature; A weighted value is preset for the first indoor temperature prediction value, and a weighted value of the second indoor temperature prediction value and the third indoor temperature prediction value is obtained according to a ratio of correlation coefficients; in, represents the weighted value of the second indoor temperature prediction value, represents the weighted value of the third indoor temperature prediction value, represents the correlation coefficient between the indoor temperature series and the outdoor temperature series, represents the correlation coefficient between the indoor temperature series and the indoor humidity series, represents a weighted value of the first indoor temperature prediction value; The first indoor temperature prediction value, the second indoor temperature prediction value, the third indoor temperature prediction value and their corresponding weighted values ​​are weightedly added to obtain a prediction correction value.

[0009] In one embodiment, for the cluster at the current moment, the three-dimensional data points therein are formed into different sequences according to the indoor temperature, the outdoor temperature, and the indoor humidity, and the sequences of different lengths are analyzed to obtain the similarity between the three-dimensional data points under different sequence lengths, and then the weights are formed in combination with the actual temperature values ​​to obtain the historical prediction value of the indoor temperature data. The method is as follows: The three-dimensional data point corresponding to the current moment is recorded as the target data point, the cluster where the target data point is located is obtained, and all the data points in this cluster are recorded as class data points; The class data point selects the temperature and humidity at a preset time to obtain the indoor temperature sequence, outdoor temperature sequence and indoor humidity sequence corresponding to the class data point; The similarity between the three-dimensional data points is obtained according to the similarity of the corresponding sequences of the class data points and the target data points, and similar data points are determined; The historical prediction value of the indoor temperature sequence is obtained according to the temperature values ​​of similar pixels corresponding to different sequence lengths at the next moment.

[0010] In one embodiment, the method of obtaining the similarity between the three-dimensional data points based on the similarity of the corresponding sequences of the class data points and the target data points and determining the similar data points is: For each class data point, the similarity between its corresponding indoor temperature sequence, outdoor temperature sequence and indoor humidity sequence and the current indoor temperature sequence, outdoor temperature sequence and indoor humidity sequence is calculated respectively; The similarities between the three sequences of the class data point and the target data point are averaged and linearly normalized to obtain the similarity between the class data point and the target data point; The similarity between all class data points and the target data points is obtained, and all similarities are classified by the threshold segmentation algorithm. The mean similarity of each class after classification is obtained, and the class data points in the class with the largest similarity mean are recorded as similar data points.

[0011] In one embodiment, the method for obtaining the historical prediction value of the indoor temperature sequence according to the temperature value of the similar pixel points corresponding to different sequence lengths at the next moment is: For each sequence length, the mean of the temperature values ​​of all similar data points at the next adjacent moment is used as the prediction reference value at the prediction moment; under this sequence length, the variance of the temperature values ​​of all similar data points at the next moment is calculated; the inverse of the variance is used as the reliability parameter; the ratio of each reliability parameter to the sum of all reliability parameters is used as the period weight; The historical forecast value is obtained by weighting the forecast reference values ​​under all sequence lengths by the period weight.

[0012] In one embodiment, the method for obtaining the indoor temperature prediction value according to the similarity between the prediction correction value and the historical prediction value and the three-dimensional data point is: Obtain all similar data points when the length is t, and obtain the forecast correction value and historical forecast value of the similar data points; Differences are made between the predicted correction value and the historical prediction value of each similar data point and the actual temperature value at the next moment to form a correction difference sequence and a historical difference sequence; For each difference sequence, the product of the variance of the difference sequence and the average of all sequence values ​​in the difference sequence is used as the weight factor; The ratio of the weight factor corresponding to the revised difference sequence to the sum of the weight factors is used as the weight coefficient of the forecast revised value, and the ratio of the weight factor corresponding to the historical difference sequence to the sum of the weight factors is used as the weight coefficient of the historical forecast value; The indoor temperature prediction value is obtained by weighting the prediction correction value and the historical prediction value by their respective weight coefficients.

[0013] In the second aspect, an embodiment of the present application also provides an indoor environment temperature regulation system for modern animal husbandry, comprising a memory, a processor, and a computer program stored in the memory and running on the processor, wherein when the processor executes the computer program, the steps of any one of the above-mentioned methods for regulating the indoor environment temperature of modern animal husbandry are implemented.

[0014] The beneficial effects of this application are: The present application combines the indoor humidity information and outdoor temperature information that affect the indoor temperature change, and the prediction results obtained by the prediction algorithm, and corrects the prediction results obtained by the same prediction algorithm according to the correlation between these parameters and the indoor temperature parameters, and increases the accuracy of the prediction results by correction; further, by analyzing historical data, by calculating the data sequence curves that may be similar to the temperature change trend corresponding to the current acquisition time in different periodic sequences, the temperature value of the next moment corresponding to these data sequence curves is obtained as the historical prediction value, and by analyzing based on historical data, the temperature change in the same scene can be better analyzed and determined, so that the obtained temperature prediction value is more in line with the historical change law, and the accuracy of the prediction result is increased; finally, the weight coefficient of the above-obtained prediction value is determined based on historical similar data, and the accuracy of the prediction result obtained by using the above-mentioned prediction method is analyzed according to historical data, and the weight is determined based on accuracy and stability analysis, so that the final prediction result is closer to the real temperature change value. Finally, based on the real-time collected data and the predicted temperature data as the input of the PID control system, the hysteresis of the temperature control of the PID control system can be reduced, the suitability of the indoor environmental temperature of animal husbandry can be guaranteed, the user cost can be reduced, and the loss caused by temperature discomfort can be avoided. BRIEF DESCRIPTION OF THE DRAWINGS

[0015] In order to more clearly illustrate the technical solutions and advantages in the embodiments of the present application or the prior art, the drawings required for use in the embodiments or the prior art descriptions are briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0016] Figure 1 A flow chart of a method for regulating indoor environmental temperature of modern animal husbandry provided by one embodiment of the present application; Figure 2 Flowchart for obtaining historical forecast values. DETAILED DESCRIPTION

[0017] In order to further explain the technical means and effects adopted by the present application to achieve the predetermined invention purpose, the following is a detailed description of the indoor environment temperature adjustment method and system for modern animal husbandry proposed in accordance with the present application, its specific implementation method, structure, features and effects, in combination with the accompanying drawings and preferred embodiments. In the following description, different "one embodiment" or "another embodiment" does not necessarily refer to the same embodiment. In addition, specific features, structures or characteristics in one or more embodiments may be combined in any suitable form.

[0018] Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs.

[0019] An embodiment of a method for regulating indoor environmental temperature in modern animal husbandry: The specific scheme of the indoor environment temperature regulation method for modern animal husbandry provided by the present application is described in detail below with reference to the accompanying drawings.

[0020] See also Figure 1 , which shows a flow chart of a method for regulating the indoor environment temperature of modern animal husbandry provided by an embodiment of the present application, the method comprising the following steps: Step S001, collecting temperature data and humidity data of the livestock breeding indoor environment and outdoor temperature data through different types of sensors.

[0021] This application requires the indoor temperature to be regulated, so temperature collection is required. This application evenly places temperature sensors inside the livestock farm and collects temperature information in the greenhouse through the temperature sensors.

[0022] In this embodiment, the temperature sensor collects temperature every 10 minutes. For each temperature sensor, for the temperature collected at the current moment, the temperature at the moment t-1 before the corresponding moment and the temperature at the current moment form a time series and record it as the indoor temperature sequence. The length of the sequence is t, and in this embodiment, t is 144.

[0023] It should be noted that the implementer can adjust the time interval for the temperature sensor to collect temperature by himself, and the implementer can also adjust the time for forming the indoor temperature sequence by himself.

[0024] A temperature sensor is placed outdoors to collect the current temperature. The time series consisting of the current temperature and the temperature at the previous t-1 moment is recorded as the outdoor temperature sequence.

[0025] A humidity sensor is placed indoors to collect the humidity at the current moment. The time series consisting of the humidity at the current moment and the humidity at the previous moment t-1 is recorded as the indoor humidity sequence.

[0026] So far, the temperature inside and outside the livestock farm and the humidity inside the greenhouse have been collected.

[0027] Step S002, record the next moment after the current moment as the predicted moment, and for a preset number of moments before the current moment, obtain the predicted values ​​of the indoor temperature data, the outdoor temperature data and the indoor humidity data at the predicted moment through the prediction algorithm; obtain different indoor temperature prediction values ​​according to the ratio of the indoor temperature data to the outdoor temperature data, the ratio of the indoor temperature data to the indoor humidity data and the predicted values ​​of the outdoor temperature data and the indoor temperature data at the predicted moment, and correct the predicted value of the indoor temperature data at the predicted moment by combining the respective proportions of the correlation coefficients of the indoor temperature data and the outdoor temperature data and the correlation coefficients of the indoor temperature data and the indoor humidity data with different indoor temperature prediction values ​​to obtain a prediction correction value.

[0028] When using existing prediction algorithms to predict the temperature of livestock farms, the temperature information of livestock farms may be inaccurate because only the historical temperature information of livestock farms is considered. In fact, the temperature change of livestock farms is also related to the internal humidity and external temperature changes of livestock farms. Therefore, this application corrects the temperature prediction results obtained based on the prediction algorithm by combining other environmental information of livestock farms, so that it can predict more accurate temperature prediction results.

[0029] It should be noted that in this embodiment, all prediction algorithms are exponential smoothing algorithms, and the temperature value at the next moment of the current moment is obtained through the indoor temperature sequence; the implementer can also use other prediction algorithms for prediction, such as the moving average method. The temperature value at the next moment of the current moment of the indoor temperature sequence obtained by the prediction algorithm is recorded as the first indoor prediction value .

[0030] Since both outdoor temperature and indoor humidity may affect indoor temperature changes, this application analyzes and predicts the temperature value in the livestock farm through the correlation between outdoor temperature, indoor humidity and indoor temperature changes.

[0031] Therefore, it is preferred to obtain the correlation coefficient between outdoor temperature and indoor temperature and the correlation coefficient between indoor humidity and indoor temperature.

[0032] Calculate the ratio of the sequence values ​​of the indoor temperature sequence and the outdoor temperature sequence at the same time, and form a sequence of the ratios of all times recorded as the indoor-outdoor temperature ratio sequence; calculate the ratio of the sequence values ​​of the indoor temperature sequence and the indoor humidity sequence at the same time, and form a sequence of the ratios of all times recorded as the temperature-humidity ratio sequence.

[0033] Preferably, in one embodiment of the present application, the standard deviation of all sequence values ​​in the indoor-outdoor temperature ratio sequence is calculated. The smaller the standard deviation, the closer the ratio of the outdoor temperature sequence to the indoor temperature sequence, that is, the stronger the correlation between the outdoor temperature sequence and the indoor temperature sequence. Therefore, the inverse of the standard deviation is used as the correlation coefficient between the outdoor temperature sequence and the indoor temperature sequence. Similarly, the standard deviation of all sequence values ​​in the temperature-humidity ratio sequence is calculated, and the inverse of the standard deviation is used as the correlation coefficient between the indoor temperature sequence and the indoor humidity sequence.

[0034] Preferably, in one embodiment of the present application, the Pearson correlation coefficient of the indoor temperature sequence and the outdoor temperature sequence is calculated as the correlation coefficient of the outdoor temperature sequence and the indoor temperature sequence; similarly, the correlation coefficient of the indoor temperature sequence and the indoor humidity sequence is calculated as the correlation coefficient of the indoor temperature sequence and the indoor humidity sequence.

[0035] Furthermore, the next collection time after the current time is recorded as the prediction time, and the prediction values ​​of the outdoor temperature series and the indoor humidity series at the prediction time are obtained through the existing prediction algorithm.

[0036] The second indoor temperature prediction value and the third indoor temperature prediction value are obtained through all sequence values ​​in the indoor-outdoor temperature ratio sequence and the temperature-humidity ratio sequence and the predicted values ​​of the outdoor temperature sequence and the indoor humidity sequence at the prediction time.

[0037] The average value of all sequence values ​​in the indoor and outdoor temperature ratio sequence is obtained as the first temperature ratio, and the second indoor temperature prediction value is obtained according to the first temperature ratio and the predicted value of the outdoor temperature sequence at the prediction time. , represents the predicted value of the outdoor temperature series at the prediction time, represents the first temperature ratio, Indicates the second indoor temperature prediction value.

[0038] The average value of all sequence values ​​in the temperature-humidity ratio sequence is obtained as the first temperature-humidity ratio, and the third indoor temperature prediction value is obtained according to the first temperature-humidity ratio and the predicted value of the indoor humidity sequence at the prediction time. , represents the predicted value of the indoor humidity series at the prediction time, Indicates the first temperature and humidity ratio, Indicates the third indoor temperature prediction value.

[0039] The first indoor temperature prediction value is corrected according to the second indoor temperature prediction value and the third indoor temperature prediction value, and the correction is performed by weighted fusion of correlation coefficients of the indoor temperature sequence and the outdoor temperature sequence, and the indoor temperature sequence and the indoor humidity sequence.

[0040] The first indoor temperature prediction value, the second indoor temperature prediction value, and the third indoor temperature prediction value are weighted and fused. In this embodiment, since the first indoor temperature prediction value is directly obtained through indoor temperature value prediction, it is considered to be more referenceable, so its weighted value is Set to , the weighted sum of the second indoor temperature prediction value and the third indoor temperature prediction value is .

[0041] The weighted value of the second indoor temperature prediction value is The weighted value of the third indoor temperature prediction value is . represents the correlation coefficient between the indoor temperature series and the outdoor temperature series, represents the correlation coefficient between the indoor temperature series and the indoor humidity series, Represents the weighted value of the first indoor temperature prediction value.

[0042] Then, all indoor temperature prediction values ​​are weighted and added to their weighted values ​​to complete the correction of the first indoor temperature prediction value, and obtain the prediction correction value .

[0043] By analyzing the outdoor temperature information and indoor humidity information related to the indoor temperature information, the current predicted value of the indoor temperature is indirectly corrected by the predicted values ​​of these related information. That is, the stronger the correlation between the indoor temperature value and these two parameters, the greater the reference weight of the correction result, and the greater the possibility of obtaining a more accurate prediction value.

[0044] At this point, the predicted corrected value of the indoor temperature series is obtained.

[0045] Step S003, the indoor temperature, outdoor temperature, and indoor humidity at each moment are formed into three-dimensional data points, and all the three-dimensional data points are clustered; for the cluster at the current moment, the three-dimensional data points therein are formed into different sequences according to the indoor temperature, outdoor temperature, and indoor humidity, and the sequences of different lengths are analyzed to obtain the similarity between the three-dimensional data points under different sequence lengths, and then combined with the actual temperature value to form a weight to obtain the historical prediction value of the indoor temperature data.

[0046] Since the cultivation of individual poultry and livestock in the greenhouse is cyclical, historical data can be analyzed to make predictions about current data based on the historical data.

[0047] The indoor temperature value, outdoor temperature value, and indoor humidity value corresponding to each collection moment are taken as a data point, that is, each collection moment corresponds to a three-dimensional data point, and the three-dimensional data points corresponding to all collection moments are clustered by a clustering algorithm, where the clustering distance is the Euclidean distance between the three-dimensional data points; the clustering algorithm is DBSCAN clustering.

[0048] It should be noted that the clustering distance may be the modulus of a vector between two three-dimensional data points, and the clustering algorithm may be other clustering algorithms, for example, a hierarchical clustering algorithm.

[0049] The three-dimensional data point corresponding to the current moment is recorded as the target data point, the cluster where the target data point is located is obtained, and all data points in this cluster are recorded as class data points. For each class data point, in this embodiment, a sequence consisting of the indoor temperature, outdoor temperature, and indoor humidity at the previous t-1 moments is obtained, that is, the indoor temperature sequence, outdoor temperature sequence, and indoor humidity sequence are obtained for the collection moment corresponding to the class data point.

[0050] Compare it with the sequence corresponding to the current moment, calculate the similarity of the sequence, and select the indoor temperature value at the next moment of the sequence with large similarity as the predicted value.

[0051] For each class data point, the similarity between the corresponding indoor temperature sequence, outdoor temperature sequence and indoor humidity sequence and the indoor temperature sequence, outdoor temperature sequence and indoor humidity sequence at the current moment is calculated respectively. In this embodiment, the similarity is calculated by DTW.

[0052] It should be noted that the DTW algorithm at this time is only used to calculate the similarity between two sequences. The implementer can also calculate the similarity between two sequences by other methods, such as the minimum edit distance method.

[0053] The similarities between the three sequences of the class data point and the target data point are averaged and then linearly normalized as the similarity between the class data point and the target data point. It should be noted that linear normalization is a method of normalizing values, and the implementer can also use other methods, such as maximum and minimum value normalization.

[0054] The similarity between all class data points and the target data points is obtained, and all similarities are classified by the Otsu threshold algorithm. The mean similarity of each class after classification is obtained, and the class data points in the class with the larger similarity mean are recorded as similar data points.

[0055] The average of the temperature values ​​of all similar data points at the next adjacent moment is used as the first prediction reference value at the prediction moment.

[0056] For each class data point, in this embodiment, its previous The indoor temperature, outdoor temperature and indoor humidity sequence at each moment are obtained to obtain the indoor temperature sequence, outdoor temperature sequence and indoor humidity sequence of the class data points.

[0057] The similarity between the indoor temperature sequence, outdoor temperature sequence and indoor humidity sequence of the class data point and the target data point is calculated. The similarity between the class data point and the three sequences of the target data point is averaged and linearly normalized as the similarity between the class data point and the target data point.

[0058] The similarity between the class data point and the target data point is classified to obtain similar data points, and the average of the temperature values ​​of all similar data points at the next adjacent moment is used as the second prediction reference value at the prediction moment.

[0059] For each class data point, in this embodiment, its previous The indoor temperature, outdoor temperature and indoor humidity sequence at each moment are obtained to obtain the indoor temperature sequence, outdoor temperature sequence and indoor humidity sequence of the class data points.

[0060] The similarity between the indoor temperature sequence, outdoor temperature sequence and indoor humidity sequence of the class data point and the target data point is calculated. The similarity between the class data point and the three sequences of the target data point is averaged and linearly normalized as the similarity between the class data point and the target data point.

[0061] The similarity between the class data point and the target data point is classified to obtain similar data points, and the average of the temperature values ​​of all similar data points at the next adjacent moment is used as the third prediction reference value at the prediction moment.

[0062] By analyzing the predicted values ​​in different periods and scale changes, the accuracy of the prediction results can be increased.

[0063] When obtaining the first prediction reference value, the variance of the temperature values ​​of all similar data points at the next moment is calculated and recorded as the first variance. The smaller the variance, the higher the accuracy and reliability of the prediction based on the sequence analysis obtained from these similar data points.

[0064] Similarly, when obtaining the second prediction reference value and the third prediction reference value, the variances of the temperature values ​​of all similar data points at the next moment are calculated and recorded as the second variance and the third variance respectively.

[0065] The variance is negatively correlated with the reliability parameter, and the reliability parameter is set to be the inverse of the variance.

[0066] It should be noted that negative correlation means that when one variable increases, the other variable decreases accordingly, and the two variables change in opposite directions. When one variable changes from large to small or from small to large, the other variable also changes from small to large or from large to small; it is determined by actual application and this application does not impose any special restrictions.

[0067] The sum of the first reliability parameter, the second reliability parameter and the third reliability parameter is recorded as the total parameter, and the ratio of each reliability parameter to the total parameter is respectively taken as the first cycle weight, the second cycle weight and the third cycle weight.

[0068] The period weights of different periods are weighted and summed with the corresponding prediction reference values, and the obtained prediction results are recorded as historical prediction values. The flowchart for obtaining historical prediction values ​​is as follows: Figure 2 shown.

[0069] At this point, the historical prediction values ​​of the indoor temperature series are obtained.

[0070] Step S004, obtaining the indoor temperature prediction value according to the prediction correction value and the historical prediction value and the similarity between the three-dimensional data points; and performing PID control to control the temperature according to the indoor temperature prediction value.

[0071] For all similar data points obtained at the t-1 moment before the class data point, obtain the predicted correction values ​​and historical prediction values ​​of all similar data points, and subtract the predicted correction value and historical prediction value of each similar data point from the actual temperature value at the next moment, respectively, and form two difference sequences of all similar data points, which are recorded as the corrected difference sequence and the historical difference sequence respectively.

[0072] For each difference sequence, the product of the variance of the difference sequence and the average of all sequence values ​​in the difference sequence is used as the weight factor.

[0073] The smaller the variance of the difference sequence between the predicted revised value and the actual value, and the smaller the average value of the difference sequence, the closer the predicted revised value is to the actual value. The smaller the variance of the difference sequence between the historical predicted value and the actual value, and the smaller the average value of the difference sequence, the closer the historical predicted value is to the actual value.

[0074] The ratio of the weight factor corresponding to the revised difference sequence to the sum of the weight factors is used as the weight coefficient of the predicted revised value, and the ratio of the weight factor corresponding to the historical difference sequence to the sum of the weight factors is used as the weight coefficient of the historical predicted value.

[0075] The indoor temperature prediction value is obtained by weighted addition of the prediction correction value and the historical prediction value.

[0076] in, represents the forecast revision value, represents the historical forecast value, represents the weight coefficient of the forecast correction value, Represents the correction factor of the historical forecast value, Indicates the predicted value of indoor temperature.

[0077] The indoor temperature prediction value and the indoor temperature measurement value are input into the PID control system, and the temperature of the livestock farm is adjusted by the PID control system so that the actual collected temperature is adjusted to the indoor temperature prediction value.

[0078] Based on the same inventive concept as the above method, an embodiment of the present invention also provides an indoor environment temperature regulation system for modern animal husbandry, comprising a memory, a processor, and a computer program stored in the memory and running on the processor, wherein the processor implements the steps of any one of the above-mentioned methods for regulating the indoor environment temperature of modern animal husbandry when executing the computer program.

[0079] It should be noted that the above-described embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application 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. These modifications or replacements do not deviate the essence of the corresponding technical solutions from the scope of the technical solutions of the embodiments of the present application, and should all be included in the protection scope of the present application.

[0080] The various embodiments in this specification are described in a progressive manner, and the same or similar parts between the various embodiments can be referenced to each other, and each embodiment focuses on the differences from other embodiments.

Claims

1. A method for regulating indoor environmental temperature in modern animal husbandry, characterized in that: The method comprises the following steps: Collect temperature and humidity data of the indoor environment of livestock breeding and outdoor temperature data through different types of sensors; The next moment after the current moment is recorded as the predicted moment, and for a preset number of moments before the current moment, the predicted values ​​of the indoor temperature data, the outdoor temperature data and the indoor humidity data at the predicted moment are obtained through a prediction algorithm; different indoor temperature prediction values ​​are obtained according to the ratio of the indoor temperature data to the outdoor temperature data, the ratio of the indoor temperature data to the indoor humidity data and the predicted values ​​of the outdoor temperature data and the indoor temperature data at the predicted moment, and the predicted value of the indoor temperature data at the predicted moment is corrected by combining the respective proportions of the correlation coefficients of the indoor temperature data and the outdoor temperature data and the correlation coefficients of the indoor temperature data and the indoor humidity data with different indoor temperature prediction values ​​to obtain a prediction correction value; The indoor temperature, outdoor temperature and indoor humidity at each moment are used to form three-dimensional data points, and all three-dimensional data points are clustered; for the cluster at the current moment, the three-dimensional data points are used to form different sequences according to the indoor temperature, outdoor temperature and indoor humidity, and the sequences of different lengths are analyzed to obtain the similarity between the three-dimensional data points under different sequence lengths, and then the weights are formed in combination with the actual temperature values ​​to obtain the historical prediction value of the indoor temperature data; The indoor temperature prediction value is obtained according to the prediction correction value, the historical prediction value and the similarity between the three-dimensional data points; the temperature is controlled by PID control according to the indoor temperature prediction value.

2. A method for regulating indoor environment temperature of modern animal husbandry as claimed in claim 1, characterized in that: The method for collecting temperature data and humidity data of the livestock breeding indoor environment and outdoor temperature data by using different types of sensors is as follows: Temperature sensors and humidity sensors are set in the indoor environment of animal husbandry, and temperature sensors are set outdoors in the animal husbandry farm, wherein each sensor collects data once every preset time, and collects a certain amount of data; The latest collected data and the data at t-1 moments before the current moment are recorded as a sequence, and the indoor temperature sequence, outdoor temperature sequence and indoor humidity sequence are obtained respectively.

3. A method for regulating indoor environment temperature of modern animal husbandry as claimed in claim 2, characterized in that: The method for obtaining different indoor temperature prediction values ​​according to the ratio of indoor temperature data to outdoor temperature data, the ratio of indoor temperature data to indoor humidity data, and the prediction values ​​of outdoor temperature data and indoor temperature data at the prediction time is: Calculate the ratio of the sequence values ​​of the indoor temperature sequence and the outdoor temperature sequence at the same time, and form a sequence of the ratios of all time points as the indoor and outdoor temperature ratio sequence; calculate the ratio of the sequence values ​​of the indoor temperature sequence and the indoor humidity sequence at the same time, and form a sequence of the ratios of all time points as the temperature and humidity ratio sequence; The average value of all sequence values ​​in the internal and external temperature ratio sequence is recorded as the first temperature ratio, and the average value of all sequence values ​​in the temperature and humidity ratio sequence is recorded as the first temperature and humidity ratio; The second indoor temperature prediction value and the third indoor temperature prediction value are obtained according to the first temperature ratio, the first greenhouse ratio, and the prediction values ​​of the outdoor temperature sequence and the indoor humidity sequence at the prediction time.

4. A method for regulating indoor environment temperature of modern animal husbandry as claimed in claim 3, characterized in that: The method for obtaining the second indoor temperature prediction value and the third indoor temperature prediction value according to the first temperature ratio, the first greenhouse ratio, and the prediction values ​​of the outdoor temperature sequence and the indoor humidity sequence at the prediction time is: In the formula, represents the predicted value of the outdoor temperature series at the prediction time, represents the first temperature ratio, represents the second indoor temperature prediction value, represents the predicted value of the indoor humidity series at the prediction time, Indicates the first temperature and humidity ratio, Indicates the third indoor temperature prediction value.

5. A method for regulating indoor environment temperature of modern animal husbandry as claimed in claim 2, characterized in that: The method of correcting the predicted value of the indoor temperature data at the prediction time by combining the respective proportions of the correlation coefficients of the indoor temperature data and the outdoor temperature data and the correlation coefficients of the indoor temperature data and the indoor humidity data with different indoor temperature prediction values ​​to obtain the predicted correction value is: Calculate the standard deviation of all sequence values ​​in the indoor-outdoor temperature ratio sequence, and use the inverse of the standard deviation as the correlation coefficient between the outdoor temperature sequence and the indoor temperature sequence; Calculate the standard deviation of all sequence values ​​in the temperature-humidity ratio sequence, and use the reciprocal of the standard deviation as the correlation coefficient between the indoor temperature sequence and the indoor humidity sequence; The predicted value of the indoor temperature data obtained by the prediction algorithm at the prediction time is recorded as the first indoor predicted temperature; A weighted value is preset for the first indoor temperature prediction value, and a weighted value of the second indoor temperature prediction value and the third indoor temperature prediction value is obtained according to a ratio of correlation coefficients; in, represents the weighted value of the second indoor temperature prediction value, represents the weighted value of the third indoor temperature prediction value, represents the correlation coefficient between the indoor temperature series and the outdoor temperature series, represents the correlation coefficient between the indoor temperature series and the indoor humidity series, A weighted value representing the first indoor temperature prediction value; The first indoor temperature prediction value, the second indoor temperature prediction value, the third indoor temperature prediction value and their corresponding weighted values ​​are weightedly added to obtain a prediction correction value.

6. A method for regulating indoor environment temperature of modern animal husbandry as claimed in claim 2, characterized in that: The method for forming different sequences of the three-dimensional data points according to the indoor temperature, outdoor temperature, and indoor humidity for the cluster at the current moment, analyzing the sequences of different lengths to obtain the similarities between the three-dimensional data points under different sequence lengths, and then combining the actual temperature values ​​to form weights to obtain the historical prediction value of the indoor temperature data is as follows: The three-dimensional data point corresponding to the current moment is recorded as the target data point, the cluster where the target data point is located is obtained, and all the data points in this cluster are recorded as class data points; The class data point selects the temperature and humidity at a preset time to obtain the indoor temperature sequence, outdoor temperature sequence and indoor humidity sequence corresponding to the class data point; The similarity between the three-dimensional data points is obtained according to the similarity of the corresponding sequences of the class data points and the target data points, and similar data points are determined; The historical prediction value of the indoor temperature sequence is obtained according to the temperature values ​​of similar pixels corresponding to different sequence lengths at the next moment.

7. A method for regulating indoor environmental temperature of modern animal husbandry as claimed in claim 6, characterized in that: The method of obtaining the similarity between the three-dimensional data points according to the similarity of the corresponding sequences of the class data points and the target data points and determining the similar data points is as follows: For each class data point, the similarity between its corresponding indoor temperature sequence, outdoor temperature sequence and indoor humidity sequence and the current indoor temperature sequence, outdoor temperature sequence and indoor humidity sequence is calculated respectively; The similarities between the three sequences of the class data point and the target data point are averaged and linearly normalized to obtain the similarity between the class data point and the target data point; The similarity between all class data points and the target data points is obtained, and all similarities are classified by the threshold segmentation algorithm. The mean similarity of each class after classification is obtained, and the class data points in the class with the largest similarity mean are recorded as similar data points.

8. A method for regulating indoor environment temperature of modern animal husbandry as claimed in claim 6, characterized in that: The method for obtaining the historical prediction value of the indoor temperature sequence according to the temperature value of the similar pixel points corresponding to different sequence lengths at the next moment is: For each sequence length, the mean of the temperature values ​​of all similar data points at the next adjacent moment is used as the prediction reference value at the prediction moment; under this sequence length, the variance of the temperature values ​​of all similar data points at the next moment is calculated; the inverse of the variance is used as the reliability parameter; the ratio of each reliability parameter to the sum of all reliability parameters is used as the period weight; The historical forecast value is obtained by weighting the forecast reference values ​​under all sequence lengths by the period weight.

9. A method for regulating indoor environment temperature of modern animal husbandry as claimed in claim 2, characterized in that: The method for obtaining the indoor temperature prediction value according to the similarity between the prediction correction value and the historical prediction value and the three-dimensional data points is: Obtain all similar data points when the length is t, and obtain the forecast correction value and historical forecast value of the similar data points; Differences are made between the predicted correction value and the historical prediction value of each similar data point and the actual temperature value at the next moment to form a correction difference sequence and a historical difference sequence; For each difference sequence, the product of the variance of the difference sequence and the average of all sequence values ​​in the difference sequence is used as the weight factor; The ratio of the weight factor corresponding to the revised difference sequence to the sum of the weight factors is used as the weight coefficient of the forecast revised value, and the ratio of the weight factor corresponding to the historical difference sequence to the sum of the weight factors is used as the weight coefficient of the historical forecast value; The indoor temperature prediction value is obtained by weighting the prediction correction value and the historical prediction value by their respective weight coefficients.

10. A system for regulating the indoor environment temperature of modern animal husbandry, comprising a memory, a processor, and a computer program stored in the memory and running on the processor, characterized in that: When the processor executes the computer program, the steps of the method for regulating the indoor environment temperature of modern animal husbandry are implemented as described in any one of claims 1-9.

Citation Information

Patent Citations

  • Feature clustering comparison-based power prediction method and device for photovoltaic power station

    CN106650784A

  • Green pepper greenhouse environment intelligent monitoring system based on subtractive clustering classifier

    CN110083190A

  • Intelligent town intelligent greenhouse control method and system

    CN115328241A

  • Method and device for controlling dehumidification heat compensation of constant-temperature and constant-humidity air conditioning unit

    CN119268110A

  • Small-scale air quality index prediction method and system for city

    WO2018214060A1

Cited By

  • Automatic temperature control system based on PLC

    CN121115936A