Temperature acquisition method and device, electronic equipment and computer readable storage medium

Through multi-dimensional and infrared cameras combined with deep learning technology, the temperature curve and peak number of the target area during the wine fermentation process are obtained, and the temperature is determined by combining Gaussian mixed model. The existing temperature acquisition method is not scientific and accurate enough, and more efficient and accurate temperature control is achieved.

CN119810835APending Publication Date: 2025-04-11ZTE CORP
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311309199.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-10-10
Publication Date
2025-04-11

AI Technical Summary

Technical Problem

The existing temperature collection methods are not scientific and accurate enough in the fermentation process of winemaking, resulting in difficulty in temperature control and affecting the quality and yield of winemaking products.

Method used

Image and temperature data of the target area are obtained through multi-dimensional cameras and infrared cameras, and the temperature curve and number of peaks of the target area are extracted using deep learning technology, and the temperature of the target area is determined by combining Gaussian hybrid model.

Benefits of technology

It realizes more scientific and accurate collection of temperature data, reduces manual intervention, improves the accuracy and efficiency of winemaking operations, and has broad market applications.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119810835A_ABST
    Figure CN119810835A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides a temperature collection method and device, electronic equipment and a computer readable storage medium. The temperature collection method comprises the steps that a target area is determined; acquiring original temperature data of the target area; acquiring a temperature curve and the number of peak values in the temperature curve based on the original temperature data; and determining the temperature of the target area according to the number of the peak values and a preset Gaussian mixture model. According to the scheme of the embodiment, the temperature acquisition accuracy is improved, and manual intervention is reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of machine vision and deep learning technology, and in particular to a temperature acquisition method, device, electronic device and computer-readable storage medium. Background Art

[0002] As consumers have stricter requirements on wine quality, it is particularly important for wineries to have good winemaking technology. Among all the factors that affect winemaking, temperature is the most important factor. During the wine fermentation process, the temperature range must be controlled in time. If the temperature is too high, it needs to be cooled down. Since fermented microorganisms are sensitive to temperature, generally too high temperature will cause them to gradually lose their original vitality, causing sourness and instability. Therefore, real-time and accurate collection of lees temperature values ​​is of great significance. Summary of the invention

[0003] Embodiments of the present disclosure provide a temperature collection method, device, electronic device, and computer-readable storage medium.

[0004] In a first aspect, an embodiment of the present disclosure provides a temperature collection method, which may include:

[0005] Identify target areas;

[0006] Acquiring original temperature data of the target area;

[0007] Acquire a temperature curve and the number of peaks in the temperature curve based on the original temperature data; the temperature curve is used to reflect the number of acquisitions at different temperatures;

[0008] The temperature of the target area is determined according to the number of peaks and a preset Gaussian mixture model.

[0009] In a second aspect, an embodiment of the present disclosure provides a temperature collection device, comprising:

[0010] A first determination module is used to determine a target area;

[0011] A first acquisition module, used to acquire original temperature data of the target area;

[0012] A second acquisition module is used to acquire a temperature curve and the number of peaks in the temperature curve based on the original temperature data; the temperature curve is used to reflect the number of acquisitions at different temperatures;

[0013] The second determination module is used to determine the temperature of the target area according to the number of peak values ​​and a preset Gaussian mixture model.

[0014] In a third aspect, an embodiment of the present disclosure provides an electronic device, the electronic device comprising:

[0015] one or more processors;

[0016] A memory having one or more programs stored thereon, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement the temperature acquisition method;

[0017] One or more input / output I / O interfaces are connected between the processor and the memory and are configured to implement information interaction between the processor and the memory.

[0018] In a fourth aspect, an embodiment of the present disclosure provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the temperature acquisition method is implemented.

[0019] The disclosed embodiment obtains the temperature curve and the number of peaks in the temperature curve based on the original temperature data of the target area, and can obtain the most common temperature value of the target area and the number of the most common temperature values; the temperature of the target area is determined according to the number of peaks and the preset Gaussian mixture model, and the collected temperature data can be more scientific and accurate, thereby providing a more favorable reference value for the subsequent production operation of the product. In addition, in real-life scenarios such as industrial process production and daily life, the disclosed embodiment scheme can replace the traditional manual monitoring scheme, reduce manual intervention, have broad market applications, and can bring greater research and economic value to enterprises. BRIEF DESCRIPTION OF THE DRAWINGS

[0020] In the accompanying drawings of the embodiments of the present disclosure:

[0021] Figure 1 A flow chart of a temperature acquisition method provided in an embodiment of the present disclosure;

[0022] Figure 2 A flow chart of a method for obtaining a temperature curve and the number of peaks in the temperature curve based on original temperature data provided in an embodiment of the present disclosure;

[0023] Figure 3 A flow chart of a method for sampling effective temperature data from candidate effective temperature data based on a histogram equidistribution sampling method provided in an embodiment of the present disclosure;

[0024] FIG4( a) is a schematic diagram of a histogram of raw temperature data provided by an embodiment of the present disclosure;

[0025] FIG4( b ) is a schematic diagram of a histogram of 5000 sampled temperature data provided by an embodiment of the present disclosure;

[0026] FIG4( c ) is a schematic diagram of a histogram of 10,000 sampled temperature data provided by an embodiment of the present disclosure;

[0027] FIG4( d ) is a schematic diagram of a histogram of 100,000 sampled temperature data provided by an embodiment of the present disclosure;

[0028] FIG4( e ) is a schematic diagram of a histogram of 500,000 sampled temperature data provided by an embodiment of the present disclosure;

[0029] Figure 5 A flow chart of a method for obtaining a temperature curve of effective temperature data and the number of peaks in the temperature curve provided in an embodiment of the present disclosure;

[0030] Figure 6 A schematic diagram of a temperature curve provided in an embodiment of the present disclosure;

[0031] Figure 7 A flow chart of a method for obtaining the temperature of a target area according to the number of peak values ​​and a preset Gaussian mixture model provided in an embodiment of the present disclosure;

[0032] Figure 8 A schematic diagram of Gaussian distribution of related technologies;

[0033] Fig. 9 A block diagram of the temperature acquisition device provided in the embodiment of the present disclosure;

[0034] Fig.10 A block diagram of the electronic device provided in the embodiment of the present disclosure;

[0035] Fig.11 A block diagram of the computer-readable storage medium provided for an embodiment of the present disclosure. DETAILED DESCRIPTION

[0036] In order to enable those skilled in the art to better understand the technical solution of the present disclosure, the communication perception data processing method and computer-readable storage medium provided by the embodiments of the present disclosure are described in detail below in conjunction with the accompanying drawings.

[0037] The present disclosure will be described more fully below with reference to the accompanying drawings, but the embodiments shown may be embodied in different forms, and the present disclosure should not be construed as being limited to the embodiments set forth below. On the contrary, the purpose of providing these embodiments is to make the present disclosure thorough and complete, and will enable those skilled in the art to fully understand the scope of the present disclosure.

[0038] The accompanying drawings of the embodiments of the present disclosure are used to provide a further understanding of the embodiments of the present disclosure and constitute a part of the specification. Together with the detailed embodiments, they are used to explain the present disclosure and do not constitute a limitation of the present disclosure. By describing the detailed embodiments with reference to the accompanying drawings, the above and other features and advantages will become more apparent to those skilled in the art.

[0039] The present disclosure may be described with reference to plan views and / or cross-sectional views by means of ideal schematic views of the present disclosure. Therefore, the exemplary illustrations may be modified according to manufacturing techniques and / or tolerances.

[0040] In the absence of conflict, the various embodiments of the present disclosure and the various features therein may be combined with each other.

[0041] The terms used in the present disclosure are only used to describe specific embodiments and are not intended to limit the present disclosure. The term "and / or" as used in the present disclosure includes any and all combinations of one or more related enumerated items. The singular forms "one" and "the" as used in the present disclosure are also intended to include plural forms, unless the context clearly indicates otherwise. The terms "including", "made of..." as used in the present disclosure specify the presence of the features, wholes, steps, operations, elements and / or components, but do not exclude the presence or addition of one or more other features, wholes, steps, operations, elements, components and / or groups thereof.

[0042] Unless otherwise defined, all terms (including technical and scientific terms) used in this disclosure have the same meaning as commonly understood by those of ordinary skill in the art. It will also be understood that terms such as those defined in commonly used dictionaries should be interpreted as having a meaning consistent with their meaning in the context of the relevant art and this disclosure, and will not be interpreted as having an idealized or overly formal meaning unless explicitly defined in this disclosure.

[0043] The present disclosure is not limited to the embodiments shown in the drawings, but includes modifications of the configurations formed based on the manufacturing process. Therefore, the regions illustrated in the drawings have schematic properties, and the shapes of the regions shown in the drawings illustrate the specific shapes of the regions of the elements, but are not intended to be limiting.

[0044] As consumers have stricter requirements on the quality of products (e.g., wine, steel, etc.), it is particularly important for manufacturers to have good production technology. Among all the factors that affect these products, temperature is the most important factor. For example, the fermentation process of winemaking and the quenching process of steelmaking all need to control the temperature range in time. If the temperature is too high, it is necessary to cool down. For example, in the fermentation process of winemaking, since the fermented microorganisms are sensitive to temperature, generally too high a temperature will make them gradually lose their original vitality, causing sourness and instability. Therefore, the real-time and accurate collection of the temperature value of the lees is of great significance. However, the temperature collection method in the existing production technology is not scientific and accurate. For example, in some processes, temperature is collected based on temperature data lines, air flow, etc., and some processes even rely on artificial perception to collect temperature. For example, in the fermentation process of winemaking, the temperature collection method of the cooling area relies on artificial perception, that is, relying on the subjective judgment of the operator kicking the lees, so the temperature of the cooling area collected in this way is necessarily subjective and inaccurate.

[0045] The disclosed embodiment scheme realizes the fusion of the image and temperature data of the target area based on a multi-dimensional (e.g., two-dimensional, 2D) camera and an infrared camera. By processing the multi-dimensional panoramic image and the infrared panoramic image to obtain the temperature of the target area, the target area identification and temperature acquisition can be realized through offline video or online video stream, which has the characteristics of high accuracy, strong robustness and wide universality; in addition, since the temperature curve is used to reflect the number of acquisitions of different temperatures; the temperature curve and the number of peaks in the temperature curve are obtained based on the original temperature data of the target area, the most common temperature value of the target area and the number of the most common temperature values ​​can be obtained; the temperature of the target area is obtained according to the number of peaks and the preset Gaussian mixture model, and the collected temperature data can be more scientific and accurate, so as to provide a more favorable reference value for the subsequent production operation of the product. For example, for the brewing process, the collected temperature data can guide the brewing operation more scientifically and accurately, which is conducive to improving the quality and output of the base wine. In addition, in real scenes such as industrial process production and daily life, the disclosed embodiment scheme can replace the traditional manual monitoring scheme, reduce manual intervention, have a broad market application, and can bring greater research and economic value to enterprises.

[0046] The temperature collection method of the embodiment of the present disclosure can be executed by any electronic device that needs temperature collection data, such as a terminal device or a server. The terminal device may include but is not limited to: vehicle-mounted equipment, user equipment (UE), mobile equipment, computing equipment, wearable equipment, etc., for example, including but not limited to cellular phones, cordless phones, personal digital assistants (PDA), portable computers, etc. The temperature collection method can be implemented by a processor calling a computer-readable program instruction stored in a memory, or it can be implemented by a server.

[0047] The embodiments of the present disclosure can be applied to any scenario that requires accurate measurement of regional temperature, including but not limited to brewing process scenarios, steelmaking process scenarios, etc.

[0048] The following is a detailed introduction to the embodiments of the present disclosure.

[0049] The present disclosure provides a temperature collection method. Figure 1 As shown, the method may include steps S11-S14:

[0050] S11, determining the target area;

[0051] S12, obtaining original temperature data of the target area;

[0052] S13, obtaining a temperature curve and the number of peaks in the temperature curve based on the original temperature data; the temperature curve is used to reflect the number of samples collected at different temperatures;

[0053] S14. Determine the temperature of the target area according to the number of peaks and a preset Gaussian mixture model.

[0054] In the embodiment of the present disclosure, obtaining the target area may include:

[0055] Acquire multi-dimensional panoramic images and infrared panoramic images of a preset area;

[0056] The multi-dimensional panoramic image and the infrared panoramic image are fused to obtain a fused panoramic image; the fused panoramic image is a multi-dimensional image with temperature data;

[0057] The fused panoramic image is input into a pre-trained image recognition model, and the image recognition model extracts the target area.

[0058] In the embodiment of the present disclosure, the preset area may include but is not limited to the area where the target area (the area where temperature collection is required, such as the cooling area in the fermentation plant) is located, such as a workshop, a factory building, etc.

[0059] In the embodiment of the present disclosure, obtaining a multi-dimensional panoramic image and an infrared panoramic image of a preset area may include:

[0060] Shooting multiple multi-dimensional images through multiple multi-dimensional cameras, and stitching the multiple multi-dimensional images to obtain a multi-dimensional panoramic image; and,

[0061] Multiple infrared images are taken by multiple infrared cameras, and the multiple infrared images are stitched together to obtain an infrared panoramic image.

[0062] In the embodiment of the present disclosure, the multi-dimensionality may include two-dimensionality and three-dimensionality. Accordingly, the camera may include but is not limited to: a multi-dimensional camera (such as a two-dimensional camera, a three-dimensional camera) and an infrared camera.

[0063] In the embodiments of the present disclosure, the current target area (such as the cooling area of ​​a brewing workshop, the quenching area of ​​a steelmaking workshop, etc.) is usually very large. Affected by the shooting range of the camera, usually only one camera cannot cover the entire target area, and thus the complete target area image cannot be captured. Therefore, multiple cameras can be used to capture images of a preset area including the target area (to ensure that the target area is fully captured in the image) to obtain a larger field of view.

[0064] In the embodiments of the present disclosure, multiple multidimensional images (such as two-dimensional images) collected by multiple multidimensional cameras (such as two-dimensional cameras) can be stitched together to obtain a multidimensional panoramic image (such as a two-dimensional panoramic image); multiple infrared images collected by multiple infrared cameras can be stitched together to obtain an infrared panoramic image;

[0065] In the embodiment of the present disclosure, the multi-dimensional panoramic image and the infrared panoramic image are fused to obtain a fused panoramic image, including:

[0066] According to the coordinates of the multi-dimensional panoramic image, the infrared panoramic image is perspective transformed to obtain a multi-dimensional image corresponding to the infrared panoramic image as a fused panoramic image.

[0067] The essence of perspective transformation is to project the image to a new viewing plane. The general transformation formula is:

[0068]

[0069] (u, v, w) are the coordinates of the original infrared panoramic image, (x=x' / w', y=y' / w') are the coordinates of the multi-dimensional image (here we take the two-dimensional image as an example) after the infrared panoramic image is transformed; the mathematical expression of perspective transformation is as follows:

[0070]

[0071]

[0072] Among them, a 11 、a 21 、a 31 、a 12 、a 22 、a 32 、a 13 、a 23 、a 33 They are all unknown coefficients, generally a 33 If the value is 1, then there are 8 unknown parameters to be solved for the perspective transformation matrix, so 4 pairs of 8 point coordinates can be found from the multidimensional panoramic image (here it can be a two-dimensional panoramic image) (the point on the original infrared panoramic image and its corresponding point in the multidimensional panoramic image after being mapped to the new viewing plane is 1 pair), so that the perspective transformation matrix can be obtained, so that the data fusion of the multidimensional panoramic image and the infrared panoramic image can be realized to obtain a fused panoramic image. The fused panoramic image contains the temperature data of each area of ​​the fused panoramic image.

[0073] In the embodiment of the present disclosure, in order to automatically and dynamically identify the target area (such as the cooling area) in the fused panoramic image, the embodiment of the present disclosure adopts a deep learning semantic segmentation network method to extract the target area from the fused panoramic image. The advantage of this method is that it can achieve accurate automatic recognition effects even in complex environments (such as worker occlusion, smoke occlusion, light changes, etc.).

[0074] In the embodiment of the present disclosure, extracting the target area from the fused panoramic image may include:

[0075] The fused panoramic image is input into a pre-trained image recognition model, and the image recognition model extracts the target area.

[0076] In an embodiment of the present disclosure, a method for acquiring an image recognition model may include:

[0077] Acquire training data; the training data includes annotated panoramic sample images; multiple regions in the panoramic sample images are annotated with whether the regions belong to the target region;

[0078] Input the training data into the preset semantic segmentation neural network, and use multiple loss functions in the semantic segmentation neural network to calculate the loss based on the training data to obtain the total loss; the multiple loss functions include: binary cross entropy loss function at pixel level, structural similarity loss at region level, and intersection-over-union loss function at image level;

[0079] When the loss value of the total loss is less than the preset loss threshold, the parameters of the semantic segmentation neural network are saved to obtain the image recognition model.

[0080] In the disclosed embodiment, the selected semantic segmentation neural network can be trained in advance to obtain the image recognition model. Semantic segmentation (SS) is a typical computer vision problem. Semantic segmentation involves taking some raw data (e.g., a plane image) as input and converting them into a mask with a highlighted region of interest.

[0081] In the embodiments of the present disclosure, there are many optional semantic segmentation neural networks, which may include but are not limited to: U2Net (UNet Cai Rong fully convolutional neural network, the main contribution is the U-shaped structure, the left network is the feature extraction network, the right network is the feature fusion network, U2Net is a large UNet embedded with many small UNets), SegNet (SegNet is a fully convolutional network for pixel-level image segmentation. The core component of segmentation is an encoder network and its corresponding decoder network, followed by a pixel-level classification network), etc. The embodiments of the present disclosure can choose to use the U2net network structure.

[0082] In an embodiment of the present disclosure, the training data may include a plurality of panoramic sample images, where the panoramic sample images may be two-dimensional images, and each region in at least a portion of the panoramic sample images is respectively annotated with temperature data of the region.

[0083] In the disclosed embodiment, semantic segmentation and annotation software can be used to annotate the target area (such as the cooling area and the quenching area of ​​steel), generate a label file (json format), and convert the json format file into a binary-coded mask map. The mask map has only two values ​​0 and 1, where 0 represents all areas except the target area, and 1 represents the target area. Then the image and the label can be used as paired data to make a data set, and finally the data set is divided into a training set and a test set according to a preset ratio, such as 9:1.

[0084] In an embodiment of the present disclosure, a data set for semantic segmentation network training may include 73,239 pairs of image and label combinations.

[0085] In the disclosed embodiment, the training data is input into the selected U2net network, and a GPU (graphics processing unit) can be used for offline training. A variety of loss functions (for example, three) can be used for iterative training, and the changes in the loss function during training and the indicators of the network model evaluated on the test set can be observed.

[0086] In the embodiments of the present disclosure, the various loss functions may include but are not limited to: a binary cross entropy loss function at a pixel level, a structural similarity loss at a region level, and an intersection-over-union loss function at an image level.

[0087] In the disclosed embodiment, the binary cross entropy loss function at the pixel level includes:

[0088] l bce =-Σ (r,c) [G(r,c)log(S(r,c))+(1-G(r,c))log(1-S(r,c))];

[0089] Among them, l bce is the function value of the binary cross entropy loss function at the pixel level, G(r,c)∈{0,1} represents the first true value of the pixel at the rth row and cth column in the panoramic sample image, S(r,c)∈(0,1) represents the first predicted value of the pixel at the rth row and cth column in the predicted image generated according to the panoramic sample image; r and c are both positive integers; the first true value is used to indicate whether the pixel belongs to the target area or not, and the first predicted value is used to predict whether the pixel belongs to the target area or not.

[0090] In the embodiment of the present disclosure, the region-level structural similarity loss function includes:

[0091]

[0092] Among them, l ssim is the function value of the structural similarity loss function at the regional level; X represents the second predicted value of any region in the fused panoramic sample image, Y represents the second true value of any region in the fused panoramic sample image, C1 and C2 are preset values; μ X ,μ Y represent the means of X and Y respectively, σ X ,σ Y Denote the variance of X and Y, σ XY represents the covariance of X and Y; the second true value is used to indicate whether any area belongs to the target area or not, and the second predicted value is used to predict whether any area belongs to the target area or not;

[0093] Analysis ssim It can be found that the loss generated by each pixel is related to its local area. Therefore, during the training process, the model will pay more attention to the edge information of the object.

[0094] In the embodiment of the present disclosure, the image-level intersection-over-union loss function includes:

[0095]

[0096] Among them, l iou is the function value of the image-level intersection-over-union loss function; where L refers to the length of the panoramic sample image, and W refers to the width of the panoramic sample image;

[0097] From the above image-level IoU loss function relationship, we can see that the image-level IoU loss function measures the intersection / union (IoU) value of the predicted value and the true value. IoU loss is an image-level metric, and a larger foreground area contributes more to the IoU loss, making the model pay more attention to the global shape features of the foreground area.

[0098] In the embodiment of the present disclosure, during the iterative training process, when the loss value of the total loss is less than the preset loss threshold, the parameters of the semantic segmentation neural network are saved, and the current semantic segmentation neural network can be tested based on a preset test set. The test set can include a two-dimensional panoramic image. The two-dimensional panoramic image is input into the trained semantic segmentation neural network for reasoning to obtain a binary image of the target area. For example, it can be expressed as the following relationship:

[0099]

[0100] Among them, J(k1, k2) is the binary output result, where 1 indicates that the output image belongs to the target area, 0 indicates that the output image does not belong to the target area, 0≤k1≤M1, 0≤k2≤N1, M1 and N1 represent the width and length of the image respectively.

[0101] In the embodiment of the present disclosure, for example, M1=1500, M2=7300.

[0102] In the disclosed embodiment, the test results may be verified using preset test indicators, network parameters with the best test indicators may be selected, and a U2net network based on the selected network parameters may be used as an image recognition model.

[0103] In the embodiments of the present disclosure, Figure 2 As shown, obtaining a temperature curve and the number of peaks in the temperature curve based on the original temperature data includes steps S21-S23:

[0104] In the embodiment of the present disclosure, the valid temperature data may include, but is not limited to: a plurality of temperature values ​​and the time at which the temperature values ​​are collected.

[0105] S21. Preliminarily screen all raw data collected at the same collection time according to a preset temperature range, and screen out candidate valid temperature data that meets the temperature range.

[0106] In the embodiment of the present disclosure, the valid temperature data may include, but is not limited to: a plurality of temperature values ​​and the time at which the temperature values ​​are collected.

[0107] In the embodiment of the present disclosure, the temperature of each point in the current fused panoramic image can be obtained by an infrared camera and saved as data in a temperature array format, denoted as A[i×j] representing a two-dimensional array of temperature, where 0≤i≤M2, 0≤j≤N2, M2 and N2 respectively represent the width and length of the image.

[0108] In the disclosed embodiment, for the convenience of calculation, the two-dimensional array A[i×j] is changed into a one-dimensional array, namely A[i×j]. Through the above extraction operation of the target area, only the temperature of the target area is selected. Assuming that the width and length of the target area are w and h respectively, A[i×j] becomes A[w×h], and then the candidate valid temperature data is screened out according to the empirical value of the target area. For example, the empirical value of the cooling area includes: the lees temperature is greater than 20 degrees Celsius, and the candidate valid temperature data can be screened out through this empirical value, which is recorded as A[(in)×(jn)], where n is the number of elements in the A array that are less than 20; the empirical value of the steel quenching area includes: the steel temperature is greater than 100 degrees Celsius. Since the temperature data also contains some ground temperature data, the candidate valid temperature data can be screened out through this empirical value, which is recorded as A[(in)×(jn)], where n is the number of elements in the A array that are less than 100.

[0109] S22. Sample valid temperature data from the candidate valid temperature data based on a histogram or other distribution sampling method.

[0110] In the embodiments of the present disclosure, Figure 3 As shown, sampling effective temperature data from candidate effective temperature data based on a histogram equidistribution sampling method includes steps S31-S33:

[0111] S31, using a histogram to perform statistics on the array corresponding to the candidate valid temperature data; wherein the abscissa in the histogram is the value in the array, and the abscissa is divided into m equal parts from the minimum value to the maximum value, where m is a positive integer; and the ordinate in the histogram is the preset probability corresponding to each value in the m equal parts;

[0112] S32, sampling the values ​​of the corresponding equal portions according to the preset probability corresponding to each equal portion of the values;

[0113] S33. Obtain sampling data of all equal parts of the array as effective temperature data.

[0114] In the embodiments of the present disclosure, in actual applications, the amount of temperature data collected is very large, and may reach a value of millions, which greatly affects the speed of subsequent Gaussian mixture calculations. Therefore, the temperature data needs to be sampled, and the histogram statistical distribution of the data remains unchanged after sampling.

[0115] In the disclosed embodiment, as shown in FIG. 4(a), FIG. 4(b), FIG. 4(c), FIG. 4(d), and FIG. 4(e), it is a schematic diagram of histogram equidistribution sampling. Among them, 20, 30, and 40 in the horizontal axis all represent temperature, and 0.1 / 0.20.30.40.6 in the vertical axis are all probability values. FIG. 4(a), FIG. 4(b), FIG. 4(c), FIG. 4(d), and FIG. 4(e) are respectively schematic diagrams of the histogram of the original temperature data, the histogram of 5,000 sampled temperature data, the histogram of 10,000 sampled temperature data, the histogram of 100,000 sampled temperature data, and the histogram of 500,000 sampled temperature data.

[0116] In the embodiment of the present disclosure, the histogram equal distribution sampling method is introduced in detail as follows: for a one-dimensional array, firstly, a histogram statistics is performed on the data distribution of the array, and the histogram statistics rule is that the horizontal axis is divided into m equal parts from the minimum value to the maximum value, and the horizontal axis is marked as T={t k3 |k3=1,2,...,m+1}, the ordinate is the probability corresponding to each equally divided interval, denoted as P={p k4 |k4=1,2,...,m}, since the horizontal axis has one more dimension than the vertical axis, and the horizontal axis is the candidate effective temperature data, it is necessary to reduce the dimension of the candidate effective temperature data of the horizontal axis, which can be expressed as t k3 =(t k3-1 +t k3+1 ) / 2, where 2≤k3≤m. Then according to p k4 The probability of k3 A sample array with the number B is randomly selected from the , so that the histogram statistical distribution of the sampled data can be kept unchanged. Assuming that the number of samples is B, where 1≤B≤(in)(jn), the final selected valid temperature data can be expressed as A[B].

[0117] S23, obtaining a temperature curve of effective temperature data and the number of peaks in the temperature curve.

[0118] In the embodiments of the present disclosure, Figure 5 As shown, obtaining a temperature curve of valid temperature data and the number of peaks in the temperature curve may include steps S41-S44:

[0119] S41. Smoothing the effective temperature data so that the effective temperature data conforms to Gaussian distribution.

[0120] In the disclosed embodiment, the above array A[B] can be subjected to histogram statistics, and then the temperature data of the histogram statistics can be subjected to Gaussian filtering operation to smooth the data and reduce the influence of noise data. Specifically, for the one-dimensional array A[B], the convolution kernel size of the Gaussian filter is m1, and the standard deviation is σ1, then the calculation process of the Gaussian filtering operation can be expressed as:

[0121]

[0122] Among them, y[k5] is the output array, k5 is the corresponding index of the element in the array, k6 is the index of the convolution kernel, e is the base of the natural logarithm, and π is the circumference of a circle.

[0123] In the embodiment of the present disclosure, a Gaussian smoothed array can be obtained through the above calculation, in which noise data is reduced or removed.

[0124] S42: Count the number of samples collected corresponding to multiple temperature values ​​in the valid temperature data.

[0125] In the embodiment of the present disclosure, for example, it is counted that 20 degrees Celsius contains 28,000, 21 degrees Celsius contains 35,000, 22 degrees Celsius contains 38,000, 23 degrees Celsius contains 34,000, 24 degrees Celsius contains 500, 25 degrees Celsius contains 600, 26 degrees Celsius contains 700, 27 degrees Celsius contains 1,000, 28 degrees Celsius contains 2,000, 30 degrees Celsius contains 5,000, 33 degrees Celsius contains 6,000, 35 degrees Celsius contains 4,000, 37 degrees Celsius contains 3,000, 40 degrees Celsius contains 300, 43 degrees Celsius contains 0, and 45 degrees Celsius contains 0.

[0126] S43. Create a temperature curve with temperature as the horizontal axis and the number of samples collected as the vertical axis.

[0127] In the embodiment of the present disclosure, based on the above temperature and collection quantity embodiment, the following can be obtained: Figure 6 The temperature curve diagram is shown.

[0128] S44. Detect the number of peaks in the temperature curve according to a preset slope threshold and / or a preset number of temperatures required to be spaced between any adjacent peaks.

[0129] In the disclosed embodiment, since the peaks and troughs in a curve are determined based on the set slope and / or the length between adjacent peaks and troughs (here, the number of temperatures of the interval), the slope threshold can be predetermined and used to determine the number of peaks in the acquired temperature curve; the number of temperatures required to be spaced between any adjacent peaks can also be predetermined and used to determine the number of peaks in the acquired temperature curve; the slope threshold and the number of temperatures required to be spaced between any adjacent peaks can also be predetermined and used to determine the number of peaks in the acquired temperature curve. The slope threshold and the number of temperatures required to be spaced between any adjacent peaks can be obtained based on empirical values.

[0130] In the embodiments of the present disclosure, Figure 6 The positions of 0 and 1 shown in FIG. 1 are the two peaks determined.

[0131] In the embodiments of the present disclosure, Figure 7 As shown, the temperature of the target area is obtained according to the number of peaks and a preset Gaussian mixture model, including steps S51-S54:

[0132] S51, using the number of peak values ​​as the number of solutions of a probability density function of a Gaussian mixture model; the probability density function is an occurrence probability function of the temperature at each coordinate in the target area, and the probability density function includes a first unknown number;

[0133] S52, solving the probability density function using the maximum likelihood estimation method to obtain q solutions for the first unknown number, where q is a positive integer and q is the number of peaks;

[0134] S53, obtaining a solution that meets the preset requirements from the q solutions;

[0135] S54. Determine the temperature of the target area according to the solution that meets the preset requirements.

[0136] Gaussian Mixture Model (GMM) uses Gaussian probability density function (normal distribution curve) to accurately quantify things. It is a model that decomposes things into multiple models based on Gaussian probability density function (normal distribution curve).

[0137] In the embodiment of the present disclosure, the number of Gaussians in the Gaussian mixture model can be determined according to the number of peak values ​​obtained, that is, the number of peak values ​​is used as the number of solutions of the probability density function of the Gaussian mixture model. Assuming that there are n1 temperature data in total, Represents the temperature data set, where A k7 represents the k7th temperature data. Since these data conform to the Gaussian distribution, the probability density function is A is the temperature set of each coordinate in the target area, where μ∈R is the mean of the function P(A), σ∈R is the variance of the function P(A), and based on the maximum likelihood estimation method, the number of peaks q is taken as the number of solutions of the function P(A), and is input into the number of solutions parameter option in the maximum likelihood estimation method. The unbiased estimates of μ and σ are:

[0138] In the embodiment of the present disclosure, the first unknown number includes: the mean μ of the temperature at multiple coordinates in the target area; the probability density function also includes a second unknown number, and the second unknown number includes: the variance σ of the temperature at multiple coordinates in the target area.

[0139] In the embodiment of the present disclosure, the solution of the probability density function is to find μ and σ 2 According to the Gaussian mixture model, μ and σ can be obtained 2 Since there are q Gaussians in a Gaussian mixture, the values ​​of μ and σ are 2 There are q groups of values ​​of .

[0140] In the embodiment of the present disclosure, determining the temperature of the target area according to the solution that meets the preset requirements includes:

[0141] The solution of the first unknown number that meets the preset requirements is used as the temperature of the target area; and / or,

[0142] A preset operation is performed on the solution of the first unknown number that meets the preset requirements and the corresponding solution of the second unknown number, and the calculated value is used as the temperature of the target area.

[0143] In the embodiment of the present disclosure, the preset requirement may include but is not limited to the maximum μ value. Therefore, the set of solutions with the largest μ value may be selected as the final μ and σ. 2 The value of .

[0144] In the embodiment of the present disclosure, the Gaussian distribution diagram is as follows: Figure 8 As shown in the diagram, it can be seen that μ belongs to the middle value in the Gaussian distribution. Based on this middle value, μ and σ 2 The calculation finds the minimum and maximum values ​​of a Gaussian distribution.

[0145] In the embodiment of the present disclosure, when determining the temperature of the target area, any one or more of the average temperature (ie, mean), the highest temperature, and the lowest temperature of the target area may be determined.

[0146] In the embodiment of the present disclosure, for Figure 8In the Gaussian distribution shown, the values ​​on each side of the expected middle value μ account for 50%, and it can be seen from the Gaussian distribution that 68% of the temperature values ​​of the target area are covered between μ-σ and μ+σ, and 95% of the temperature values ​​of the target area are covered between μ-2σ and μ+2σ. Therefore, μ-2σ is equivalent to the lowest temperature value of the target area, and μ+2σ is equivalent to the highest temperature value of the target area.

[0147] In the disclosed embodiment, the lowest temperature, average temperature and highest temperature points in the current target area (such as the cooling area) correspond to the left 2σ quantile (μ-2σ), mean quantile (μ) and right 2σ quantile (μ+2σ) of the Gaussian mixture distribution, respectively. Finally, any one or more of the lowest temperature, average temperature and highest temperature can be selected as the target area temperature at the current screen moment. That is, the temperature of the target area can be determined based on the calculated average temperature μ, the calculated minimum temperature μ-2σ, the calculated maximum temperature μ+2σ, or any multiple of the average temperature, minimum temperature and maximum temperature as the temperature of the target area.

[0148] In the embodiment of the present disclosure, the fusion of the multi-dimensional panoramic image and the infrared panoramic image can be achieved by calling the perspective transformation function of OpenCV, and any method for implementing the perspective transformation function can replace the function.

[0149] In the embodiment of the present disclosure, for the semantic segmentation network of deep learning, the embodiment of the present disclosure uses the U2net semantic segmentation network, and any deep learning network that implements semantic segmentation can replace this network.

[0150] In the embodiment of the present disclosure, the temperature data smoothing process may use the gaussian_filter1d function in the scipy algorithm package, and any function that implements Gaussian filtering may replace this function.

[0151] In the embodiment of the present disclosure, the number of peaks of the temperature curve can be obtained by using the find_peaks function in the scipy algorithm package, and any function for obtaining the peaks of a curve can replace this function.

[0152] In the embodiment of the present disclosure, the temperature is calculated according to the Gaussian mixture model, which can be implemented using the GaussianMixture function in the sklearn algorithm package. Any function that implements Gaussian mixture calculation can replace this function.

[0153] In the disclosed embodiment, in order to improve the calculation speed of the Gaussian mixture model, histogram equidistribution sampling is performed on the original large-scale data to ensure that the distribution of the sampled data remains consistent.

[0154] The present disclosure also provides a temperature collection device 100, such as Fig. 9 As shown, it may include:

[0155] A first determination module 101 is used to determine a target area;

[0156] The first acquisition module 102 is used to acquire the original temperature data of the target area; the temperature curve is used to reflect the number of acquisitions at different temperatures;

[0157] A second acquisition module 103 is used to acquire a temperature curve and the number of peaks in the temperature curve based on the original temperature data;

[0158] The second determination module 104 is used to determine the temperature of the target area according to the number of peak values ​​and a preset Gaussian mixture model.

[0159] The present disclosure also provides an electronic device 200, such as Fig.10 As shown, the electronic device 200 includes:

[0160] One or more processors 201;

[0161] A memory 202, on which one or more programs are stored, and when the one or more programs are executed by the one or more processors 201, the one or more processors 201 implement the temperature acquisition method;

[0162] One or more input / output I / O interfaces 203 are connected between the processor 201 and the memory 202 and are configured to implement information exchange between the processor 201 and the memory 202 .

[0163] Among them, the processor 201 is a device with data processing capabilities, including but not limited to a central processing unit (CPU) and the like; the memory 202 is a device with data storage capabilities, including but not limited to random access memory (RAM, more specifically SDRAM, DDR, etc.), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory (FLASH); the I / O interface (read-write interface) 203 is connected between the processor 201 and the memory 202, and can realize information interaction between the processor 201 and the memory 202, including but not limited to a data bus (Bus) and the like.

[0164] In some embodiments, the processor 201 , the memory 202 , and the I / O interface 203 are connected to each other via a bus 204 , and further connected to other components of the computing device.

[0165] The present disclosure also provides a computer-readable storage medium 300. Fig.11As shown, a computer program is stored on the computer-readable storage medium 300, and the temperature acquisition method is implemented when the computer program is executed by the processor.

[0166] Those skilled in the art will appreciate that all or some of the functional modules / units disclosed above may be implemented as software, firmware, hardware, or a suitable combination thereof.

[0167] In hardware implementations, the division between functional modules / units mentioned in the above description does not necessarily correspond to the division of physical components; for example, one physical component may have multiple functions, or one function or step may be performed by several physical components in cooperation.

[0168] Some physical components or all physical components may be implemented as software executed by a processor, such as a central processing unit (CPU), a digital signal processor or a microprocessor, or implemented as hardware, or implemented as an integrated circuit, such as an application-specific integrated circuit. Such software may be distributed on a computer-readable medium, which may include a computer storage medium (or non-temporary medium) and a communication medium (or temporary medium). As known to those of ordinary skill in the art, the term computer storage medium includes volatile and non-volatile, removable and non-removable media implemented in any method or technology for storing information (such as computer-readable instructions, data structures, program modules or other data). Computer storage media include, but are not limited to, random access memory (RAM, more specifically SDRAM, DDR, etc.), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory (FLASH) or other disk storage; read-only compact disk (CD-ROM), digital versatile disk (DVD) or other optical disk storage; magnetic cassettes, magnetic tapes, disk storage or other magnetic storage; any other medium that can be used to store desired information and can be accessed by a computer. Furthermore, it is well known to those skilled in the art that communication media typically embodies computer readable instructions, data structures, program modules, or other data in a modulated data signal such as a carrier wave or other transport mechanism, and may include any information delivery media.

[0169] The present disclosure has disclosed example embodiments, and although specific terms are employed, they are used and should be interpreted only in a general illustrative sense and not for limiting purposes. In some instances, it will be apparent to those skilled in the art that, unless otherwise expressly stated, features, characteristics, and / or elements described in conjunction with a particular embodiment may be used alone or in combination with features, characteristics, and / or elements described in conjunction with other embodiments. Therefore, those skilled in the art will appreciate that various changes in form and detail may be made without departing from the scope of the present disclosure as set forth in the appended claims.

Claims

1. A temperature collection method, characterized in that: The method comprises: Identify target areas; Acquiring original temperature data of the target area; Acquire a temperature curve and the number of peaks in the temperature curve based on the original temperature data; The temperature of the target area is determined according to the number of peaks and a preset Gaussian mixture model.

2. The temperature acquisition method according to claim 1, characterized in that: Determining the target area includes: Acquire multi-dimensional panoramic images and infrared panoramic images of a preset area; fusing the multi-dimensional panoramic image and the infrared panoramic image to obtain a fused panoramic image; the fused panoramic image is a multi-dimensional image with temperature data; The fused panoramic image is input into a pre-trained image recognition model, and the target area is extracted by the image recognition model.

3. The temperature acquisition method according to claim 2, characterized in that: The method for acquiring the image recognition model comprises: Acquire training data; the training data includes a panoramic sample image after annotation; a plurality of regions in the panoramic sample image are annotated with whether the regions belong to the target region; The training data is input into a preset semantic segmentation neural network, and a plurality of loss functions are used in the semantic segmentation neural network to calculate the loss based on the training data to obtain a total loss; the plurality of loss functions include: a binary cross entropy loss function at a pixel level, a structural similarity loss at a region level, and an intersection-over-union loss function at an image level; When the loss value of the total loss is less than a preset loss threshold, the parameters of the semantic segmentation neural network are saved to obtain the image recognition model.

4. The temperature acquisition method according to claim 1, characterized in that: The acquiring a temperature curve and the number of peaks in the temperature curve based on the original temperature data includes: Preliminarily screening all the original temperature data collected at the same collection time according to a preset temperature range, and screening out candidate valid temperature data that meets the temperature range; Sampling effective temperature data from the candidate effective temperature data based on a histogram equidistribution sampling method; A temperature curve of the effective temperature data and the number of peaks in the temperature curve are obtained.

5. The temperature acquisition method according to claim 4, characterized in that: The method of sampling the valid temperature data from the candidate valid temperature data based on the histogram equal distribution sampling method includes: The array corresponding to the candidate effective temperature data is counted using a histogram; wherein the abscissa in the histogram is the value in the array, and the abscissa is divided into m equal parts from the minimum value in the values ​​to the maximum value in the values, where m is a positive integer; and the ordinate in the histogram is the preset probability corresponding to each value in the m equal parts; Sampling the values ​​of the corresponding equal portions according to the preset probability corresponding to each equal portion of the values; The sampling data of all equal parts of the array are obtained as the effective temperature data.

6. The temperature acquisition method according to claim 4, characterized in that: The step of acquiring the temperature curve of the effective temperature data and the number of peaks in the temperature curve comprises: Smoothing the effective temperature data so that the effective temperature data conforms to Gaussian distribution; Counting the number of samples collected corresponding to multiple temperature values ​​in the valid temperature data; Create the temperature curve with the temperature as the abscissa and the number of samples collected as the ordinate; The number of peaks in the temperature curve is detected according to a preset slope threshold and / or a preset number of temperatures required to be spaced between any adjacent peaks.

7. The temperature collection method according to claim 1, characterized in that: The determining the temperature of the target area according to the number of peak values ​​and a preset Gaussian mixture model includes: The number of peaks is used as the number of solutions of the probability density function of the Gaussian mixture model; the probability density function is an occurrence probability function of the temperature of each coordinate in the target area, and the probability density function includes a first unknown number; Solving the probability density function using a maximum likelihood estimation method to obtain q solutions for the first unknown number, where q is a positive integer and q is the number of peaks; Obtaining a solution that meets preset requirements from the q solutions; The temperature of the target area is determined according to the solution that meets the preset requirements.

8. The temperature collection method according to claim 7, characterized in that: The first unknown number includes: the mean of the temperature at multiple coordinates in the target area; the probability density function also includes a second unknown number, and the second unknown number includes: the variance of the temperature at multiple coordinates in the target area; Determining the temperature of the target area according to the solution that meets the preset requirements includes: Using the solution of the first unknown number that meets the preset requirement as the temperature of the target area; and / or, A preset operation is performed on the solution of the first unknown number that meets the preset requirement and the corresponding solution of the second unknown number, and the operation value is used as the temperature of the target area.

9. The temperature acquisition method according to claim 2, characterized in that: The step of acquiring a multi-dimensional panoramic image and an infrared panoramic image of a preset area includes: Shooting multiple multi-dimensional images by multiple multi-dimensional cameras, and stitching the multiple multi-dimensional images to obtain the multi-dimensional panoramic image; and, A plurality of infrared images are captured by a plurality of infrared cameras, and the plurality of infrared images are stitched together to obtain the infrared panoramic image.

10. A temperature collection device, characterized in that: include: A first determination module is used to determine a target area; A first acquisition module, used to acquire original temperature data of the target area; A second acquisition module, configured to acquire a temperature curve and the number of peaks in the temperature curve based on the original temperature data; The second determination module is used to determine the temperature of the target area according to the number of peak values ​​and a preset Gaussian mixture model.

11. An electronic device, characterized in that: The electronic device comprises: one or more processors; A memory having one or more programs stored thereon, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement the temperature acquisition method according to any one of claims 1 to 9; One or more input / output I / O interfaces are connected between the processor and the memory and are configured to implement information interaction between the processor and the memory.

12. A computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the temperature acquisition method according to any one of claims 1 to 9.