A high-temperature measurement method based on image recognition
By analyzing the brightness shift and grayscale tension field in thermal images and combining them with time series analysis, the problem of inaccurate boundary identification in high-temperature measurements was solved, enabling continuous temperature identification and structural integrity in high-temperature scenarios, thus improving the accuracy and adaptability of temperature measurement.
Patent Information
- Application Number
- CN202511794776.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-02
- Publication Date
- 2026-04-24
- Estimated Expiration
- 2045-12-02
AI Technical Summary
Existing image recognition-based high-temperature measurement methods are unable to accurately reflect the continuity and evolution characteristics of the thermal field distribution in complex or rapidly changing high-temperature scenarios. They lack dynamic boundary adjustment and structural trend analysis, resulting in inaccurate temperature identification.
By acquiring the radiance values of pixels in a thermal image, detecting the radiance shift amplitude, generating a thermally focused pixel location distribution map, identifying the boundaries of thermal image partitions, extracting grayscale tension field spectra, and combining time series analysis to analyze the tension change trend of boundary segments, dynamic identification and reconstruction of boundaries are achieved.
It enhances the accuracy and structural integrity of temperature acquisition in high-temperature scenarios, enables continuous identification of the internal temperature structure of the target area and extraction of trends across multiple frames, and strengthens the spatial correlation expression capability of the temperature field in the image.
Smart Images

Figure CN121230884B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of temperature measurement technology, and in particular to a high-temperature measurement method based on image recognition. Background Technology
[0002] Temperature measurement technology involves acquiring and assessing the temperature of objects or environments using physical, chemical, and electrical methods. It is a key supporting technology in multiple industries, including automation control, industrial manufacturing, and safety monitoring. Core aspects include non-contact temperature detection, thermal radiation measurement, infrared thermal imaging temperature measurement, thermocouple temperature measurement, and temperature sensor signal conversion and output, covering multiple measurement dimensions such as high temperature, low temperature, instantaneous temperature, and temperature distribution. In modern applications, non-contact temperature acquisition methods in high-temperature scenarios are particularly important to meet the temperature measurement needs in high-risk or extreme environments where direct contact is not possible. High-temperature measurement methods in this field estimate temperature by collecting radiant energy and converting it into an electrical signal, supplemented by physical components such as optical systems, filtering devices, and thermoelectric detectors to complete the data acquisition process. Traditional image recognition-based high-temperature measurement methods involve using image acquisition equipment to acquire images of high-temperature objects and then analyzing and identifying the infrared radiation images to determine the temperature. The technical issue addressed is the acquisition of temperature for a target area or object under high-temperature conditions. Traditional methods use infrared thermal imaging devices to acquire images of the target, utilize the infrared spectral radiation laws to identify brightness differences in different areas of the image, and compare the brightness distribution characteristics with a known blackbody radiation standard spectrum to calculate and determine the temperature range of the target area. This method, however, involves acquiring images with a thermal imager and then using a temperature conversion circuit to quantitatively analyze the brightness information in the image, thus completing a non-contact temperature measurement.
[0003] In image temperature measurement scenarios, existing technologies rely solely on static comparisons between thermal radiation brightness values and standard radiometric spectra. The measurement results are highly dependent on the consistency between the brightness of each region in the image and known samples. When the boundaries of the hot zone are blurred or there is strong interference noise, inaccurate identification problems are likely to occur. Especially under conditions where the hot zone structure is complex or changes drastically, the lack of dynamic boundary adjustment and structural trend analysis mechanisms makes it difficult to accurately reflect the continuity and evolution characteristics of the thermal field distribution. Existing methods fail to fully explore the spatial correlation and temporal trend of grayscale changes in the image, causing temperature recognition to remain only at the stage of local brightness judgment, which is insufficient to meet the temperature measurement needs of complex zones in high-temperature scenarios. Summary of the Invention
[0004] To address the technical problems existing in the prior art, this invention provides a high-temperature measurement method based on image recognition, comprising the following steps:
[0005] To achieve the above objectives, the present invention adopts the following technical solution: a high-temperature measurement method based on image recognition, comprising the following steps:
[0006] S1: Obtain the radiance value data of pixels in the thermal image, detect the radiance offset amplitude between each pixel and the first-order neighboring pixels in eight directions, determine whether the radiance offset amplitude constitutes a radiance peak point in the real-time third-order neighbor, filter the pixels that constitute the peak as heat focusing candidate points, and generate a heat focusing pixel location distribution map.
[0007] S2: Using the thermal focusing pixel positioning distribution map, call the pixel connection path between the focal points, detect the brightness change direction and spatial extension direction in the path pixel by pixel, determine whether there is a brightness direction offset area in the path, and generate a thermal image partition boundary composition map.
[0008] S3: Using the boundary map of the thermal image partition, extract the pixel grayscale trajectory along the row and column direction in the region inside the boundary, identify the grayscale increasing or decreasing extreme value pairs in the pixel grayscale trajectory, and generate the grayscale tension field map inside the thermal area.
[0009] S4: Based on the gray-scale tension field map inside the hot zone, extract the tension evolution trend of the boundary region in consecutive frames, determine whether there is a continuous change feature in the tension direction of the boundary segment, and redraw and replace the boundary segment in the tension stable change area to generate a time-series hot zone boundary update layer.
[0010] As a further aspect of the present invention, the thermal focusing pixel location distribution map includes the spatial distribution coordinates of thermal focusing candidate points, the pixel number of the brightness peak point, and the initial contour structure of the focusing area; the thermal image partition boundary composition map includes the spatial connection relationship of thermal boundary candidate nodes, the geometric topological information of the closed contour line, and the boundary classification label of the thermal partition area; the gray-level tension field spectrum inside the thermal area includes the intensity value of gray-level transition pairs, the tension span between pixels, and the distribution characteristics of the spatial coverage structure; and the temporal thermal area boundary update layer includes the continuity mark of the tension direction change of the boundary segment, the boundary redrawing result of the stable change area, and the boundary segment replacement information in the real-time boundary map.
[0011] As a further aspect of the present invention, the specific steps of S1 are as follows:
[0012] S101: Obtain the radiance value data of pixels in the thermal image, call the spatial position index of the pixel, detect the radiance value between the pixel and the first-order neighboring pixels in eight directions, calculate the radiance value difference amplitude between the pixel and each neighboring pixel respectively, classify and label the difference results, and generate a radiance offset amplitude matrix.
[0013] S102: Based on the brightness offset amplitude matrix, extract the eight-direction brightness offset amplitude value of each pixel, and call the third-order neighborhood brightness value set of the pixel to determine whether the real-time pixel constitutes a local brightness maximum in the third-order neighborhood. If the maximum point condition is met, mark the pixel index position and generate a brightness peak point index set.
[0014] S103: Call the brightness peak point index set, map the index position to the spatial coordinate system of the corresponding thermal image, integrate the pixel position information of the peak, and generate a thermal focus pixel positioning distribution map.
[0015] As a further aspect of the present invention, the specific steps of S2 are as follows:
[0016] S201: Call the thermal focus pixel location distribution map, extract the pixel connection path between the focus points, and combine the spatial position and brightness value of the pixels on the path to retrieve the brightness value and coordinate position of the adjacent pixels one by one, compare whether the brightness change direction is consistent with the spatial extension direction, and generate a set of path brightness change directions.
[0017] S202: Based on the comparison results of the brightness direction and spatial direction of the path segment in the path brightness change direction concentration, determine whether there is a brightness direction offset, identify the area where the brightness change trend deviates from the spatial extension direction, extract the pixel index position and mark it as a candidate node, and generate a thermal boundary candidate node index set.
[0018] S203: Call the thermal boundary candidate node index set, and search for whether there is a closable connection path between the nodes according to the position of the candidate nodes in the image coordinate system. If there is at least one closed structure, construct the spatial boundary graphic formed by the closed path and generate a thermal image partition boundary composition map.
[0019] As a further aspect of the present invention, the specific steps of S3 are as follows:
[0020] S301: Call the thermal image partition boundary composition map, retrieve the region inside the closed boundary, and continuously sample the pixel gray values along the row and column directions within the region, record the gray value sequence of pixels on each path, and generate a set of gray value trajectories in the row and column directions;
[0021] S302: Based on the grayscale trajectory set in the row and column directions, scan the grayscale value change trend along the path, determine whether there is an extreme value pair structure in the grayscale value sequence that continuously increases and then decreases or continuously decreases and then increases. If it exists, extract the grayscale difference between the extreme value pair and the spatial position spacing value between the corresponding pixel to generate a grayscale extreme value span and spacing pair set.
[0022] S303: Call the gray-level extreme value span and spacing pair, analyze the area covered by the spatial spacing corresponding to the gray-level span, use the gray-level change gradient in the area as a parameter, construct the tension distribution grid layer in the area, and generate the gray-level tension field map inside the hot zone.
[0023] As a further aspect of the present invention, in each set of gray-level difference values and corresponding spatial position spacing values included in the gray-level extreme value span and spacing pair set, when the gray-level difference value is greater than a preset gray-level jump threshold and the spatial position spacing value is less than a set peak adjacent pixel spacing threshold, the area covered by the spatial spacing corresponding to the gray-level span is determined to be a region of drastic gray-level change.
[0024] The calculation of the gray-level change gradient in the region of drastic gray-level change is based on the ratio of the difference between the gray-level values of continuous pixels in the gray-level trajectory set in the row and column directions to the coordinates of the corresponding pixel positions. Tension distribution grid layer nodes are established in each region of drastic gray-level change based on the distribution density of the gray-level change gradient.
[0025] The tension value at each node of the tension distribution grid layer is calculated based on the average gray-level gradient of multiple pixels around the node, thus constructing a gray-level tension field map inside the hot zone.
[0026] As a further aspect of the present invention, the specific steps of S4 are as follows:
[0027] S401: Call the gray-scale tension field map inside the hot zone, extract the tension distribution layer corresponding to the boundary region in the continuous time frame, retrieve the tension vector value of the boundary region in each frame in time order, align and compare the spatial position of the boundary segment, analyze the tension change amplitude and direction change state of the same boundary segment in the continuous frame, and generate a set of boundary segment tension evolution trend.
[0028] S402: Based on the set of boundary segment tension evolution trends, determine whether the tension direction change curve of each boundary segment satisfies the continuity characteristic of direction change. If the tension direction of the boundary segment continues to change in one direction in consecutive frames or the fluctuation amplitude is within the limited threshold range, mark the boundary segment as a stable segment, and extract the average position contour value in the frame to generate a set of tension stable boundary segment contours.
[0029] S403: Call the tension stable boundary segment contour set, replace the corresponding boundary segment in the original boundary map with the contour information corresponding to the stable boundary segment, do not adjust the original boundary structure of the unchanged area, recombine the boundary segments, and generate the time-series hot zone boundary update layer.
[0030] As a further aspect of the present invention, the determination of the direction change continuity feature is based on the consistency of the sign of the first derivative of the tension direction change curve of the boundary segment in a continuous time frame between adjacent frames. If the first derivative maintains the same sign in no less than three consecutive frames, or the change amplitude in the frame does not exceed the set tension direction change amplitude threshold, then the tension direction change curve is determined to satisfy the direction change continuity feature.
[0031] The threshold for the magnitude of tension direction change is obtained by calculating the standard deviation of tension direction change in the tension distribution layer of the boundary region.
[0032] After the boundary segment that satisfies the continuity of directional change is determined to be a stable segment, the average position contour value is obtained by weighted calculation of the spatial position coordinates of the boundary segment in the frame. The weight is determined based on the stability of the tension value of the boundary segment in each frame.
[0033] As a further aspect of the present invention, the method further includes step S5:
[0034] S5: Update the layer using the time-series hot zone boundary, extract the gray-level peak points and spatial positions within the hot zone to construct a set of brightness centroid points, identify the dominant direction between the centroid points, construct the temperature inversion main path line under the direction, extract the gray-level jump trend between pixels in the region and the path line, and combine the gray-level structure relationship in the path direction to generate a temperature measurement structure path map under thermal image recognition.
[0035] The temperature measurement structure path map under thermal image recognition includes the spatial configuration of the brightness centroid point set, the directional pattern of the temperature inversion main path line, and the gray-level jump features from the pixel to the path line.
[0036] As a further aspect of the present invention, the specific steps of S5 are as follows:
[0037] S501: Call the time-series hot zone boundary update layer, retrieve the gray-level peak points within the boundary, extract the corresponding gray-level values and spatial coordinates, calculate the gray-level weighted centroid position of each group of peak points, and integrate the gray-level centroid points to generate a set of brightness centroid points.
[0038] S502: Based on the multi-point coordinate relationship of the brightness centroid set, calculate the direction angle of the line connecting the centroids, identify the direction segment with priority in the direction angle distribution, determine the direction as the dominant direction, construct a continuous polyline structure that passes through all centroids under the dominant direction as the path skeleton, and generate the temperature inversion main path line.
[0039] S503: Call the temperature inversion main path line, retrieve the vertical projection distance and grayscale difference between the pixels on both sides of the path and the path, extract the grayscale change trend sequence between the pixels and the path line, and perform structural classification on the grayscale change curves along the path direction to generate a temperature measurement structure path map under thermal image recognition.
[0040] Compared with the prior art, the advantages and positive effects of the present invention are as follows:
[0041] In this invention, by acquiring temperature information and combining brightness peak and neighborhood offset features to determine the heat concentration area, image partitions with closed boundaries are generated by spatial connectivity judgment. Tension index is constructed based on gray-level extreme value distribution and spatial distance, and tension change trend in time series is introduced to achieve dynamic identification and real-time reconstruction of boundary stability. Temperature inversion main trajectory is constructed by integrating brightness centroid distribution and path directionality relationship to achieve continuous identification of temperature structure inside target area. This invention achieves evolution from single-frame brightness identification to multi-frame structural trend extraction at multiple levels, strengthens the spatial correlation expression ability of temperature field in image, enhances the adaptability and continuity of boundary identification, and effectively improves the accuracy and structural integrity of temperature acquisition under thermal field. Attached Figure Description
[0042] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0043] Figure 1 This is a schematic diagram of the steps of the present invention;
[0044] Figure 2 This is a detailed schematic diagram of S1 of the present invention;
[0045] Figure 3 This is a detailed schematic diagram of S2 of the present invention;
[0046] Figure 4 This is a detailed schematic diagram of S3 of the present invention;
[0047] Figure 5 This is a detailed schematic diagram of S4 of the present invention;
[0048] Figure 6 This is a detailed schematic diagram of S5 of the present invention. Detailed Implementation
[0049] The technical solution of the present invention will now be described with reference to the accompanying drawings.
[0050] In embodiments of the present invention, words such as "exemplarily," "for example," etc., are used to indicate that something is an example, illustration, or description. Any embodiment or design described as "exemplary" in the present invention should not be construed as being more preferred or advantageous than other embodiments or designs. Specifically, the use of the word "exemplary" is intended to present the concept in a concrete manner. Furthermore, in embodiments of the present invention, the meaning expressed by "and / or" can be both, or either one.
[0051] In the embodiments of this invention, the terms "image" and "picture" may sometimes be used interchangeably. It should be noted that, without emphasizing the distinction between them, they convey the same meaning. Similarly, the terms "of," "corresponding (relevant)," and "corresponding" may sometimes be used interchangeably. It should be noted that, without emphasizing the distinction between them, they convey the same meaning.
[0052] In this embodiment of the invention, sometimes a subscript such as W1 may be written in a non-subscript form such as W1. When the difference is not emphasized, the meaning they express is the same.
[0053] To make the technical problems, technical solutions and advantages of the present invention clearer, a detailed description will be given below in conjunction with the accompanying drawings and specific embodiments.
[0054] Please see Figure 1 This invention provides a high-temperature measurement method based on image recognition, comprising the following steps:
[0055] S1: Obtain the radiance value data of pixels in the thermal image, detect the radiance offset amplitude between each pixel and the first-order neighboring pixels in eight directions, determine whether the radiance offset amplitude constitutes a radiance peak point in the real-time third-order neighbor, filter the pixels that constitute the peak as heat focusing candidate points, and generate a heat focusing pixel location distribution map.
[0056] S2: Using the thermal focus pixel localization distribution map, calling the pixel connection path between the focus points, detecting the brightness change direction and spatial extension direction in the path pixel by pixel, determining whether there is a brightness direction offset area in the path, and using it as a thermal boundary candidate node, detecting whether the thermal boundary candidate nodes can form a closed contour line in the image, and generating a thermal image partition boundary composition map.
[0057] S3: Using the boundary map of the thermal image partition, extract the pixel gray-level trajectory along the row and column direction in the region inside the boundary, identify the gray-level increasing or decreasing extreme value pairs in the pixel gray-level trajectory, extract the gray-level span and pixel position spacing, identify the spatial distribution characteristics of the covered area, and generate the gray-level tension field map inside the thermal zone.
[0058] S4: Based on the gray-scale tension field map inside the hot zone, extract the tension evolution trend of the boundary region in consecutive frames, determine whether there is a continuous change feature in the tension direction of the boundary segment, and redraw and replace the boundary segment in the tension stable change area. Integrate the replaced boundary into the real-time boundary map to generate a time-series hot zone boundary update layer.
[0059] S5: Update the layer using the temporal hot zone boundary, extract the gray-level peak points and spatial positions within the hot zone to construct a set of brightness centroids, identify the dominant direction between the centroids, construct the temperature inversion main path line under the direction, extract the gray-level jump trend between pixels in the region and the path line, and combine the gray-level structure relationship in the path direction to generate a temperature measurement structure path map under thermal image recognition.
[0060] The thermal focusing pixel location distribution map includes the spatial distribution coordinates of thermal focusing candidate points, the pixel number of the brightness peak point, and the initial contour structure of the focusing area. The thermal image partition boundary composition map includes the spatial connection relationship of thermal boundary candidate nodes, the geometric topological information of the closed contour line, and the boundary classification label of the thermal partition area. The gray-level tension field map inside the thermal area includes the intensity value of gray-level transition pairs, the tension span between pixels, and the distribution characteristics of the spatial coverage structure. The time-series thermal area boundary update layer includes the continuity mark of the tension direction change of the boundary segment, the boundary redrawing result of the stable change area, and the boundary segment replacement information in the real-time boundary map. The temperature measurement structure path map under thermal image recognition includes the spatial configuration of the brightness centroid point set, the direction pattern of the temperature inversion main path line, and the gray-level jump characteristics from the pixel to the path line.
[0061] Please see Figure 2 The specific steps of S1 are as follows:
[0062] S101: Obtain the radiance value data of pixels in the thermal image, call the spatial position index of the pixel, detect the radiance value between the pixel and the first-order neighboring pixels in eight directions, calculate the radiance value difference amplitude between the pixel and each neighboring pixel respectively, classify and label the difference results, and generate a radiance offset amplitude matrix.
[0063] The target area needs to be scanned using a thermal infrared imaging device. The resulting image consists of several pixels, each containing a grayscale value representing temperature or radiation intensity. The grayscale values need to be converted to brightness using a calibration table built into the device. Based on the row and column coordinates of the image, the spatial position index of each pixel is obtained. For the pixel at row i and column j, the first-order neighboring pixels in eight directions surrounding that pixel are retrieved (including up, down, left, right, upper left, upper right, lower left, and lower right). The brightness value of each neighboring pixel is extracted and subtracted from the brightness value of the center pixel to obtain eight... The brightness value difference in each direction is then classified, and the differences are divided into different categories based on the preset range of brightness change. Low differences are classified as 0, medium differences as 1, and high differences as 2. The classification results are combined according to the spatial position consistent with the original image. Each pixel position corresponds to an offset classification value, which can be used to identify abnormal heat dissipation points on building surfaces or local heat generation locations of industrial equipment. In actual detection, if there are high brightness offset values in multiple directions in a certain area, the pixels in that area will be represented as clustered high classification labels in the matrix, generating a brightness offset amplitude matrix.
[0064] S102: Based on the brightness offset amplitude matrix, extract the brightness offset amplitude values of each pixel in eight directions, and call the brightness value set of the third-order neighborhood of the pixel to determine whether the real-time pixel constitutes a local maximum brightness point in the third-order neighborhood. If the maximum point condition is met, mark the pixel index position and generate a brightness peak point index set.
[0065] For each pixel, the corresponding eight-directional offset amplitude classification value is extracted. That is, the classification results of the eight surrounding positions are queried in the matrix. Then, the spatial index position of the pixel in the image is called to expand and construct a third-order neighborhood. This means that the range of three pixels in each direction is extended from the current pixel as the center, forming a seven-row, seven-column neighborhood area. The brightness value of the pixels in the area is extracted and processed. Including the current central pixel, the brightness values of 49 pixels are traversed and compared with the central pixel. If the brightness value of the central pixel is greater than the brightness value of any of the remaining pixels, the point is considered to constitute a local maximum. After the condition is met, the spatial index position of the pixel is recorded. In practical applications, in the thermal imaging monitoring of industrial equipment, if there is a significant brightness peak in the third-order neighborhood of the edge area of a component, the pixels in the area will be marked as local maxima to facilitate the identification of potential overheating areas. The whole process requires judging and marking each pixel in the entire image area to generate a brightness peak point index set.
[0066] S103: Call the brightness peak point index set, map the index position to the spatial coordinate system of the corresponding thermal image, integrate the pixel position information of the peak, and generate a thermal focus pixel location distribution map;
[0067] The index information needs to be mapped to the actual spatial coordinate system corresponding to the original thermal image. The size of the pixel in the actual space is determined according to the image resolution. The corresponding spatial coordinate position is calculated according to the row and column index of the pixel. Each pixel position in the index set is converted into an actual coordinate point, forming a dataset with spatial position as the core, representing the physical distribution of brightness peaks. The mapped spatial points are integrated and organized into a set of points to represent the spatial distribution of each brightness peak pixel in the thermal image. In actual detection applications, such as in infrared inspection of power equipment, when there is an abnormal thermal focusing phenomenon at the equipment connection, the pixel will be marked in the peak index set and displayed as a concentration point on the spatial distribution map. This makes it easier for staff to identify the location of the thermal anomaly by combining it with the actual equipment layout diagram, realizing the visual marking and subsequent tracking record of key hot spots, and generating a thermal focusing pixel location distribution map.
[0068] Please see Figure 3 The specific steps of S2 are as follows:
[0069] S201: Call the thermal focus pixel location distribution map, extract the pixel connection path between the focus points, and combine the spatial position and brightness value of the pixels on the path to retrieve the brightness value and coordinate position of the adjacent pixels one by one, compare whether the brightness change direction is consistent with the spatial extension direction, and generate a set of path brightness change directions.
[0070] The process involves reading the spatial coordinates of the focal points in the image and calculating the pixel connection paths between them. This can be done using common image path search algorithms, such as breadth-first search, to determine if there are valid connection channels between the focal points. Once a path is identified, the brightness value and spatial position of each pixel on the path are extracted sequentially. The path is set to consist of several consecutive pixels. The brightness value of each pixel is read sequentially, and its spatial index is recorded in the image. The current pixel on the path is compared with its neighboring pixels to extract the brightness data and coordinate information of the neighboring pixels. The direction of the brightness difference between two adjacent pixels is analyzed, and the spatial extension direction is extracted based on the trend of pixel coordinate changes. By comparing the relative relationship between the trend of brightness value changes and the direction of spatial position movement, it is determined whether the brightness change increases or decreases consistently along the spatial path. The analysis results are organized according to path segments, and the brightness change is recorded path by path to determine whether it is consistent with the spatial direction, generating a set of path brightness change directions.
[0071] S202: Based on the comparison between the brightness direction and spatial direction of the path segment in the path brightness change direction concentration, determine whether there is a brightness direction offset, identify the area where the brightness change trend deviates from the spatial extension direction, extract the pixel index position and mark it as a candidate node, and generate a thermal boundary candidate node index set.
[0072] The correspondence between the brightness direction and spatial direction in each path segment is judged. If the brightness change direction in a certain path segment is inconsistent with the spatial extension direction, it can be regarded as a brightness direction offset. The rising or falling trend of the brightness of adjacent pixels is compared with the spatial displacement direction of the pixels. The spatial direction is set to extend to the right. If the brightness value decreases, it constitutes a direction offset. If the brightness value increases in the same direction as the spatial extension, it is considered consistent and there is no offset. This comparison is performed on each path segment in the global image range to filter out the positions where the brightness change trend is inconsistent with the spatial extension direction. The pixel index position is recorded and the position is marked as a candidate node, including potential boundary pixels with brightness direction offset. In practical applications, such as in building heat leakage analysis, if the brightness of pixels along the wall direction in the path segment shows a decreasing trend but should show an increasing trend in the wall extension direction, the area can be marked as a boundary abnormal area, and a thermal boundary candidate node index set is generated.
[0073] S203: Call the thermal boundary candidate node index set, and search for whether there is a closable connection path between the nodes according to the position of the candidate nodes in the image coordinate system. If there is at least one closed structure, construct the spatial boundary graphic formed by the closed path and generate the thermal image partition boundary composition map.
[0074] The analysis method analyzes the relative positional relationships of nodes in the image coordinate system, searches for connection paths between candidate nodes that can form a closed structure, and traces paths between candidate nodes by constructing an adjacency graph or using graph connectivity analysis methods to find whether one or more groups of nodes form a closed loop structure. Once at least one closed path is identified, the area enclosed by the closed path can be regarded as a closed spatial contour, and the closed path can be converted into an actual boundary graphic in the image. By connecting the nodes on the closed path point by point, the boundary contour is drawn on the image, and a spatial boundary graphic is constructed. In practical application scenarios, such as thermal images of industrial equipment surfaces, when candidate nodes enclose a closed area, the area can be divided as an independent hot zone. In this way, spatial identification of hot spots, temperature anomaly areas, and blurred boundary areas in the image can be achieved, generating a thermal image partition boundary composition map.
[0075] Please see Figure 4 The specific steps of S3 are as follows:
[0076] S301: Call the thermal image partition boundary composition map, retrieve the region inside the closed boundary, and continuously sample the pixel gray values along the row and column directions within the region, record the gray value sequence of pixels on each path, and generate a set of gray value trajectories in the row and column directions.
[0077] By sequentially identifying closed boundary structures formed by closed paths in the image, image processing methods are used to extract pixels within the boundaries, locking down all internal pixel regions contained within the closed boundaries, and constructing corresponding row and column path sets for each region. The paths are then scanned row by row and column by column. On each row path, pixel grayscale values are extracted from left to right and recorded sequentially. Similarly, on each column path, grayscale values are extracted from top to bottom, forming complete grayscale value sequences. Each sequence represents a grayscale distribution trajectory in one direction. If the closed region is an ellipse, the extracted paths along the row direction form a symmetrical grayscale sequence in the middle of the region, while the column direction shows a trend of brightness variation from top to bottom. By traversing the row and column paths within the closed region, a grayscale trajectory set covering the entire region can be obtained. Each trajectory is represented by a linear sequence of pixel grayscale values along the path, preserving not only the spatial distribution characteristics of the region's grayscale but also providing a basic data structure for identifying thermal focusing change patterns, generating a set of grayscale trajectories in the row and column directions.
[0078] S302: Based on the grayscale trajectory set in the row and column directions, scan the grayscale value change trend along the path, determine whether there is an extreme value pair structure in the grayscale value sequence that continuously increases and then decreases or continuously decreases and then increases. If it exists, extract the grayscale difference between the extreme value pair and the spatial position spacing value between the corresponding pixels to generate a grayscale extreme value span and spacing pair set.
[0079] For each grayscale value sequence, a trend scanning analysis is performed. This involves comparing the changes in grayscale values pixel by pixel, starting from the beginning of the sequence, to determine if there are structural changes such as continuous increases followed by decreases or continuous decreases followed by increases in grayscale value. If such a reversal structure in grayscale value trends is found, the positions are considered to form an extreme value pair. After identifying the extreme value pair, the grayscale difference between the maximum and minimum grayscale values is recorded. Simultaneously, the relative positional distance between these two pixels in the image space coordinates is extracted, forming a paired record. This operation is repeated in each grayscale trajectory. The process is repeated, and several extreme value pairs are extracted from different paths within the region. The grayscale span and corresponding pixel spacing of each pair are used as a set of analysis data to form a grayscale extreme value span and spacing pair set. If the grayscale in a path first increases from 90 to 140 and then decreases to 100, the extreme value pair is (140, 100) and the grayscale difference is 40. If the spacing between two pixels is 8 pixel units, the pair is recorded as (40, 8). By identifying and pairing the trajectories in the region, the grayscale extreme value span and spacing pair set is obtained.
[0080] S303: Call the gray-level extreme value span and spacing pair set, analyze the area covered by the spatial spacing corresponding to the gray-level span, use the gray-level change gradient in the area as a parameter, construct the tension distribution grid layer in the area, and generate the gray-level tension field map inside the hot zone.
[0081] Based on each grayscale span and its corresponding spatial spacing, the region represented in the image is determined. This involves mapping the span and spacing data to thermal image coordinates, analyzing the affected spatial range, and statistically analyzing the grayscale change rate of pixels within this range. Using the grayscale change rate as a basic parameter, the gradient values between each location are calculated and organized into a grid, forming a tension distribution grid layer representing the intensity distribution of grayscale changes within the region. The layer divides the region into several small grids, each recording a tension value that reflects the intensity of grayscale changes at that location. This is visualized on the image as variations in color depth; for example, areas with large grayscale spans are displayed as dark colors, while areas with small spans are displayed as light colors. In practical applications, such as in thermal imaging inspection of welded areas, the uniformity of heat diffusion in the weld area can be observed. The tension field map can identify areas of localized abnormal aggregation, providing auxiliary information for defect identification and structural assessment, and generating a grayscale tension field map of the thermal zone.
[0082] Please see Figure 5 The specific steps of S4 are as follows:
[0083] S401: Call the gray-scale tension field map inside the hot zone, extract the tension distribution layer corresponding to the boundary region in the continuous time frame, retrieve the tension vector value of the boundary region in each frame in time order, align and compare the spatial position of the boundary segment, analyze the tension change amplitude and direction change state of the same boundary segment in the continuous frames, and generate a set of boundary segment tension evolution trend.
[0084] Extracting the tension distribution layer corresponding to the boundary region frame by frame from a multi-frame continuous thermal image sequence requires recording the spatial location of the identified boundary region in each frame, extracting the tension vector value at the location of the boundary segment (i.e., the gradient change direction and amplitude information of each boundary pixel), aligning the boundary segments at the same spatial location in each frame in chronological order, and comparing the tension vectors corresponding to the spatial locations in different frames longitudinally to analyze the trend of change over time, including the increase or decrease in tension value and the rotation change in direction. By comparing segment by segment, the tension change trajectory of the same boundary segment in each time frame is recorded. For example, if the tension direction of the boundary segment is upward to the right in the first frame, right in the second frame, and downward to the right in the third frame, it indicates a directional shift trend. At the same time, it is recorded whether the tension amplitude increases or decreases frame by frame. This operation is performed on the boundary region of the entire thermal zone to construct a dataset containing the tension change information of the boundary segment in the time series, generating a set of boundary segment tension evolution trends.
[0085] S402: Based on the set of tension evolution trends of boundary segments, determine whether the tension direction change curve of each boundary segment satisfies the characteristic of direction change continuity. If the tension direction of the boundary segment continues to change in one direction in consecutive frames or the fluctuation amplitude is within the limited threshold range, mark the boundary segment as a stable segment, extract the average position contour value in the frame, and generate a set of tension stable boundary segment contours.
[0086] The tension direction change curve of each boundary segment is judged one by one. The tension direction change data of each boundary segment in continuous frames is extracted and converted into a sequence information in the form of curves. It is judged whether the direction sequence has continuous fluctuation, drastic jump or relatively stable trend. If the tension direction of a boundary segment always maintains the same direction or only fluctuates within a small range in continuous frames, it is set to always maintain the upward direction or change back and forth within a certain angle range. That is, the direction change is judged to have a coherent feature, and the boundary segment is marked as a stable segment. At the same time, the average position coordinates of the stable segment appearing in multiple frames are extracted as the stable contour position value. The boundary segments that meet the direction coherence judgment condition are summarized to generate a tension stable boundary segment contour set. In actual thermal image applications, such as in the detection of thermal changes on the surface of pipes, if the crack boundary segment shows a continuous and stable tension direction with small amplitude fluctuations in several frames of images, a tension stable boundary segment contour set is generated.
[0087] S403: Call the tension stable boundary segment contour set, replace the corresponding boundary segment in the original boundary map with the contour information of the stable boundary segment, do not adjust the original boundary structure of the unchanged area, recombine the boundary segments, and generate the time-series hot zone boundary update layer.
[0088] Each boundary segment in the original boundary map undergoes structural replacement. Based on the position coordinates of stable boundary segments in the contour set, the corresponding boundary segment positions in the original boundary map are matched and replaced with the average extracted stable contour information. This process preserves the boundary segments in the original image that are not covered by stable contours, ensuring that only boundary structures with clear trends and consistent directions are updated in the hot zone, achieving selective optimization of boundary updates. The new stable boundary segments are structurally stitched together with the unchanged boundary segments in the original image to form a complete hot zone boundary image. The updated boundary segments are reconstructed into continuous boundary paths in spatial order. In practical analysis, this is used to reflect the real and stable boundary structure in the thermal image, helping to eliminate boundary disturbances caused by short-term noise. In scenarios such as high-temperature equipment monitoring and traffic road surface thermal attenuation analysis, it can provide the thermal boundary change trend over a continuous period, supporting the input requirements of subsequent prediction models or being used to identify continuous boundary evolution events, generating a time-series hot zone boundary update layer.
[0089] Please see Figure 6 The specific steps of S5 are as follows:
[0090] S501: Call the time-series hot zone boundary update layer, retrieve the gray-level peak points within the boundary, extract the corresponding gray-level values and spatial coordinates, calculate the gray-level weighted centroid position of each set of peak points, and integrate the gray-level centroid points to generate a set of brightness centroid points.
[0091] The grayscale peak points within the closed boundary structure of the location layer are identified. These peak points are the pixels with the highest grayscale value in the local area, corresponding to the high-temperature center in the actual thermal image. The grayscale value and spatial coordinate information of each peak point are extracted sequentially. After acquiring the peak point data, the grayscale value of each point is used as a weight to calculate the grayscale centroid position of the group of peak points. The weighting process assigns greater spatial influence to high grayscale values, so that the weighted centroid reflects the true distribution position of the entire local thermal intensity center. This process is repeated group by group to obtain the coordinates of multiple grayscale weighted centroid positions. The calculated weighted grayscale centroid points are then spatially integrated to express the multi-point aggregation of the hot spot spatial center within the thermal area. In practical thermal imaging applications, in the thermal analysis of electronic component layout, the brightness centroid can represent the concentration point of the main heat source, providing a basic positioning basis for extracting the direction of heat diffusion and the structural connection trend, thus forming a set of brightness centroid points.
[0092] S502: Based on the multi-point coordinate relationship of the brightness centroid set, calculate the direction angle of the line connecting the centroids and identify the direction segments with priority in the direction angle distribution. Determine the direction as the dominant direction and construct a continuous polyline structure that traverses all centroids under the dominant direction as the path skeleton to generate the temperature inversion main path line.
[0093] Establish connecting line segments between brightness centroids. After connecting each pair of centroids, calculate the spatial orientation angle of the line segments sequentially, i.e., the angle value of the connecting line formed by each pair of points in the two-dimensional image coordinate system. Statistically summarize the orientation angles and sort them according to frequency or weight distribution. Identify the orientation interval with the largest proportion in the orientation angles. The interval is the dominant direction of the thermal centroid distribution in the current hot zone. After determining the dominant direction, organize the centroids into a continuous broken line structure according to the orientation projection order, using the dominant direction as a reference. Establish connected paths between the centroids according to the orientation angle, and perform interpolation connection processing on discontinuous parts in the path to make the path present complete connectivity, forming a main path line that passes through the brightness centroids. This represents the main heat conduction trend from one hot spot center to another in the hot zone. The establishment of the path line provides a morphological guiding structural framework for subsequent temperature measurement analysis based on the orientation structure. It has important practical application significance in scenarios such as thermal design and debugging, and building energy-saving heat flow optimization, and obtains the temperature inversion main path line.
[0094] S503: Call the temperature inversion main path line, retrieve the vertical projection distance and grayscale difference between the pixels on both sides of the path and the path, extract the grayscale change trend sequence between the pixels and the path line, and perform structural classification on the grayscale change curve along the path direction to generate a temperature measurement structure path map under thermal image recognition.
[0095] Centered on the path line, image pixels on both sides are projected point by point. The vertical projection distance from each surrounding pixel to the path line is calculated. Simultaneously, the difference between the gray value of the pixel and the gray value of the corresponding projection point on the main path line is extracted to obtain the gray value change amplitude of the pixel relative to the path line. The gray value difference of multiple pixels and the corresponding distance are combined along the path line to form a gray value change trend sequence. Each sequence records the gray value distribution characteristics of heat diffusion on both sides of the path. After obtaining complete gray value change trend data, the change curves along the path line are classified and analyzed. The gray value curves are classified according to structural features such as gray value increase, decrease, symmetry, and interruption. The structural categories are mapped back to the path line coordinates, and the thermal structure types corresponding to different segments on the path are marked. The thermal change trend and spatial features along the path line are visualized and combined. In actual detection scenarios such as fire trace analysis, high-temperature pipeline anomaly identification, and photovoltaic module temperature difference layout, it can help identify heat conduction paths, determine temperature gradient distribution structures, lock potential hot spot sources and abnormal areas, and generate temperature measurement structure path maps under thermal image recognition.
[0096] The above are merely specific embodiments of the present invention, but the scope of protection of the present invention is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the technical scope disclosed in the present invention should be included within the scope of protection of the present invention. Therefore, the scope of protection of the present invention should be determined by the scope of the claims.
Claims
1. A high-temperature measurement method based on image recognition, characterized in that, Includes the following steps: S1: Obtain the radiance value data of pixels in the thermal image, detect the radiance offset amplitude between each pixel and the first-order neighboring pixels in eight directions, determine whether the radiance offset amplitude constitutes a radiance peak point in the real-time third-order neighbor, filter the pixels that constitute the peak as heat focusing candidate points, and generate a heat focusing pixel location distribution map. S2: Using the thermal focusing pixel positioning distribution map, call the pixel connection path between the focal points, detect the brightness change direction and spatial extension direction in the path pixel by pixel, determine whether there is a brightness direction offset area in the path, and generate a thermal image partition boundary composition map. S3: Using the boundary map of the thermal image partition, extract the pixel grayscale trajectory along the row and column direction in the region inside the boundary, identify the grayscale increasing or decreasing extreme value pairs in the pixel grayscale trajectory, and generate the grayscale tension field map inside the thermal area. S4: Based on the gray-scale tension field map inside the hot zone, extract the tension evolution trend of the boundary region in consecutive frames, determine whether there is a continuous change feature in the tension direction of the boundary segment, and redraw and replace the boundary segment in the tension stable change area to generate a time-series hot zone boundary update layer. S5: Update the layer using the time-series hot zone boundary, extract the gray-level peak points and spatial positions within the hot zone to construct a set of brightness centroid points, identify the dominant direction between the centroid points, construct the temperature inversion main path line under the direction, extract the gray-level jump trend between pixels in the region and the path line, and combine the gray-level structure relationship in the path direction to generate a temperature measurement structure path map under thermal image recognition. The temperature measurement structure path map under thermal image recognition includes the spatial configuration of the brightness centroid point set, the directional pattern of the temperature inversion main path line, and the gray-level jump features from the pixel to the path line. The thermal focusing pixel location distribution map includes the spatial distribution coordinates of thermal focusing candidate points, the pixel number of the brightness peak point, and the initial contour structure of the focusing area. The thermal image partition boundary composition map includes the spatial connection relationship of thermal boundary candidate nodes, the geometric topological information of the closed contour line, and the boundary classification label of the thermal partition area. The gray-level tension field map inside the thermal area includes the intensity value of gray-level transition pairs, the tension span between pixels, and the distribution characteristics of the spatial coverage structure. The temporal thermal area boundary update layer includes the continuity mark of the tension direction change of the boundary segment, the boundary redrawing result of the stable change area, and the boundary segment replacement information in the real-time boundary map.
2. The high-temperature measurement method based on image recognition according to claim 1, characterized in that, The specific steps of S1 are as follows: S101: Obtain the radiance value data of pixels in the thermal image, call the spatial position index of the pixel, detect the radiance value between the pixel and the first-order neighboring pixels in eight directions, calculate the radiance value difference amplitude between the pixel and each neighboring pixel respectively, classify and label the difference results, and generate a radiance offset amplitude matrix. S102: Based on the brightness offset amplitude matrix, extract the eight-direction brightness offset amplitude value of each pixel, and call the third-order neighborhood brightness value set of the pixel to determine whether the real-time pixel constitutes a local brightness maximum in the third-order neighborhood. If the maximum point condition is met, mark the pixel index position and generate a brightness peak point index set. S103: Call the brightness peak point index set, map the index position to the spatial coordinate system of the corresponding thermal image, integrate the pixel position information of the peak, and generate a thermal focus pixel positioning distribution map.
3. The high-temperature measurement method based on image recognition according to claim 2, characterized in that, The specific steps of S2 are as follows: S201: Call the thermal focus pixel location distribution map, extract the pixel connection path between the focus points, and combine the spatial position and brightness value of the pixels on the path to retrieve the brightness value and coordinate position of the adjacent pixels one by one, compare whether the brightness change direction is consistent with the spatial extension direction, and generate a set of path brightness change directions. S202: Based on the comparison results of the brightness direction and spatial direction of the path segment in the path brightness change direction concentration, determine whether there is a brightness direction offset, identify the area where the brightness change trend deviates from the spatial extension direction, extract the pixel index position and mark it as a candidate node, and generate a thermal boundary candidate node index set. S203: Call the thermal boundary candidate node index set, and search for whether there is a closable connection path between the nodes according to the position of the candidate nodes in the image coordinate system. If there is at least one closed structure, construct the spatial boundary graphic formed by the closed path and generate a thermal image partition boundary composition map.
4. The high-temperature measurement method based on image recognition according to claim 3, characterized in that, The specific steps for S3 are as follows: S301: Call the thermal image partition boundary composition map, retrieve the region inside the closed boundary, and continuously sample the pixel gray values along the row and column directions within the region, record the gray value sequence of pixels on each path, and generate a set of gray value trajectories in the row and column directions. S302: Based on the grayscale trajectory set in the row and column directions, scan the grayscale value change trend along the path, determine whether there is an extreme value pair structure in the grayscale value sequence that continuously increases and then decreases or continuously decreases and then increases. If it exists, extract the grayscale difference between the extreme value pair and the spatial position spacing value between the corresponding pixel to generate a grayscale extreme value span and spacing pair set. S303: Call the gray-level extreme value span and spacing pair, analyze the area covered by the spatial spacing corresponding to the gray-level span, use the gray-level change gradient in the area as a parameter, construct the tension distribution grid layer in the area, and generate the gray-level tension field map inside the hot zone.
5. The high-temperature measurement method based on image recognition according to claim 4, characterized in that, In the gray-scale extreme value span and spacing pair set, if the gray-scale difference is greater than the preset gray-scale jump threshold and the spatial spacing value is less than the set peak adjacent pixel spacing threshold, the area covered by the spatial spacing corresponding to the gray-scale span is determined to be a region of drastic gray-scale change. The calculation of the gray-level change gradient in the region of drastic gray-level change is based on the ratio of the difference between the gray-level values of continuous pixels in the gray-level trajectory set in the row and column directions to the coordinates of the corresponding pixel positions. Tension distribution grid layer nodes are established in each region of drastic gray-level change based on the distribution density of the gray-level change gradient. The tension value at each node of the tension distribution grid layer is calculated based on the average gray-level gradient of multiple pixels around the node, thus constructing a gray-level tension field map inside the hot zone.
6. The high-temperature measurement method based on image recognition according to claim 4, characterized in that, The specific steps of S4 are as follows: S401: Call the gray-scale tension field map inside the hot zone, extract the tension distribution layer corresponding to the boundary region in the continuous time frame, retrieve the tension vector value of the boundary region in each frame in time order, align and compare the spatial position of the boundary segment, analyze the tension change amplitude and direction change state of the same boundary segment in the continuous frame, and generate a set of boundary segment tension evolution trend. S402: Based on the set of boundary segment tension evolution trends, determine whether the tension direction change curve of each boundary segment satisfies the continuity characteristic of direction change. If the tension direction of the boundary segment continues to change in one direction in consecutive frames or the fluctuation amplitude is within the limited threshold range, mark the boundary segment as a stable segment, and extract the average position contour value in the frame to generate a set of tension stable boundary segment contours. S403: Call the tension stable boundary segment contour set, replace the corresponding boundary segment in the original boundary map with the contour information corresponding to the stable boundary segment, do not adjust the original boundary structure of the unchanged area, recombine the boundary segments, and generate the time-series hot zone boundary update layer.
7. The high-temperature measurement method based on image recognition according to claim 6, characterized in that, The determination of the direction change continuity feature is based on the consistency of the sign of the first derivative of the tension direction change curve of the boundary segment in a continuous time frame between adjacent frames. If the first derivative maintains the same sign in no less than three consecutive frames, or the change amplitude in the frame does not exceed the set tension direction change amplitude threshold, then the tension direction change curve is determined to satisfy the direction change continuity feature. The threshold for the magnitude of tension direction change is obtained by calculating the standard deviation of tension direction change in the tension distribution layer of the boundary region. After the boundary segment that satisfies the continuity of directional change is determined to be a stable segment, the average position contour value is obtained by weighted calculation of the spatial position coordinates of the boundary segment in the frame, and the weight is determined according to the stability of the tension value of the boundary segment in each frame.
8. The high-temperature measurement method based on image recognition according to claim 1, characterized in that, The specific steps of S5 are as follows: S501: Call the time-series hot zone boundary update layer, retrieve the gray-level peak points within the boundary, extract the corresponding gray-level values and spatial coordinates, calculate the gray-level weighted centroid position of each group of peak points, and integrate the gray-level centroid points to generate a set of brightness centroid points. S502: Based on the multi-point coordinate relationship of the brightness centroid set, calculate the direction angle of the line connecting the centroids, identify the direction segment with priority in the direction angle distribution, determine the direction as the dominant direction, construct a continuous polyline structure that passes through all centroids under the dominant direction as the path skeleton, and generate the temperature inversion main path line. S503: Call the temperature inversion main path line, retrieve the vertical projection distance and grayscale difference between the pixels on both sides of the path and the path, extract the grayscale change trend sequence between the pixels and the path line, and perform structural classification on the grayscale change curves along the path direction to generate a temperature measurement structure path map under thermal image recognition.
Citation Information
Patent Citations
Infrared chart digital signal processing system and method
CN102413283A
Power transmission and distribution line iron accessory temperature abnormity control method and system
CN120747152A