Infrared data processing method, device and equipment and storage medium

The infrared data processing method, which uses time window segmentation and integral averaging feature extraction, solves the problem of false triggering of infrared sensors in complex environments, improves the accuracy and robustness of infrared triggering logic, and is suitable for device control in smart home systems.

CN122223947APending Publication Date: 2026-06-16GUANGZHOU EZVALO TECH CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
GUANGZHOU EZVALO TECH CO LTD
Filing Date
2026-04-16
Publication Date
2026-06-16

Smart Images

  • Figure CN122223947A_ABST
    Figure CN122223947A_ABST
Patent Text Reader

Abstract

The application discloses an infrared data processing method, device, equipment and storage medium. The method comprises the following steps: acquiring infrared data collected by an infrared sensor, determining environment time window data and detection time window data according to the infrared data; calculating integral average values of the environment time window data and the detection time window data respectively to obtain an environment reference value and a detection activity value; determining a target activity judgment value according to the environment reference value and the detection activity value; determining an activity judgment value threshold according to the environment reference value, and controlling a home device corresponding to the infrared sensor to start in the case that the target activity judgment value is greater than the activity judgment value threshold. The scheme introduces an infrared signal feature extraction mechanism based on time window partitioning, suppresses the influence of light fluctuation, heat source drift and short-time noise on activity detection, and significantly improves the motion recognition accuracy, anti-interference ability and trigger response reliability of the infrared sensor in a complex home environment.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of smart home technology, and in particular to an infrared data processing method, apparatus, device and storage medium. Background Technology

[0002] With the rapid development of smart home, environmental sensing and human-computer interaction technologies, motion recognition and trigger control based on infrared sensors have become an important basic capability for the automated operation of smart devices.

[0003] Existing smart home systems typically determine user activity by reading the output electrical signals of infrared sensors and using methods such as single-point threshold triggering and fixed-time period sampling. This information is then used to control the start and stop of lights, security equipment, or other home terminals. However, in real-world applications, this infrared data processing method, based on direct level judgment or short-term change detection, still has significant limitations and struggles to meet the comprehensive requirements for action recognition accuracy, anti-interference capabilities, and device response stability in complex scenarios. Summary of the Invention

[0004] This application provides an infrared data processing method, apparatus, device, and storage medium, which solves the problems of existing technologies based on single-point threshold judgment and short-time level change detection being susceptible to environmental temperature fluctuations, background heat source disturbances, and signal noise, resulting in high false trigger rates, unstable action recognition, and difficulty in achieving reliable trigger control in complex home environments. This solution effectively suppresses false judgments caused by environmental thermal noise, light drift, and equipment interference, significantly improving the accuracy and robustness of infrared trigger logic, and is suitable for applications such as smart lighting, security linkage, and multi-scenario automated control.

[0005] In a first aspect, this application provides an infrared data processing method, including: Acquire infrared data collected by an infrared sensor, and determine environmental time window data and detection time window data based on the infrared data; The integral average of the environmental time window data and the detection time window data are calculated respectively to obtain the environmental baseline value and the detection activity value; The target activity determination value is determined based on the environmental baseline value and the detection activity value; Based on the environmental baseline value, an activity determination threshold is determined. If the target activity determination value is greater than the activity determination threshold, the home device corresponding to the infrared sensor is controlled to turn on.

[0006] Secondly, this application provides an infrared data processing device, comprising: The window data module is configured to acquire infrared data collected by the infrared sensor and determine environmental time window data and detection time window data based on the infrared data. The integral averaging module is configured to calculate the integral average of the environmental time window data and the detection time window data respectively, to obtain the environmental baseline value and the detection activity value. The activity determination module is configured to determine a target activity determination value based on the environmental baseline value and the detected activity value; The device control module is configured to determine an activity determination threshold based on the environmental reference value, and to control the home device corresponding to the infrared sensor to turn on when the target activity determination value is greater than the activity determination threshold value.

[0007] Thirdly, this application provides an infrared data processing device, comprising: One or more processors; A memory that stores one or more programs, which, when executed by one or more processors, cause the one or more processors to implement the infrared data processing method as described in the first aspect.

[0008] Fourthly, this application provides a storage medium containing computer-executable instructions, which, when executed by a computer processor, are used to perform the infrared data processing method as described in the first aspect.

[0009] This application constructs a processing mechanism based on infrared time window segmentation and integral averaging feature extraction to achieve rapid determination of environmental changes and activity behavior. After acquiring data from infrared sensors, an environmental time window and a detection time window are divided to characterize background stability and transient change features, respectively. Simultaneously, integral averaging is performed on the data from both time windows to generate an environmental baseline value and a detected activity value. The combined result of these two values ​​forms a target activity determination value, used to quantify the activity level in the current monitoring area. When the target activity determination value exceeds a threshold, control logic is triggered to activate the home appliances associated with the infrared sensors. This scheme achieves lightweight activity detection capabilities based on window features, improving the accuracy and reliability of automated triggering of home appliances. Attached Figure Description

[0010] Figure 1 This is a flowchart of an infrared data processing method provided in an embodiment of this application; Figure 2 This is a flowchart of a time window data extraction method provided in an embodiment of this application; Figure 3 This is a flowchart of a threshold control method provided in an embodiment of this application; Figure 4 This is a step diagram of an infrared data processing method provided in an embodiment of this application; Figure 5This is a structural block diagram of an infrared data processing device provided in an embodiment of this application; Figure 6 This is a schematic diagram of the structure of an infrared data processing device provided in an embodiment of this application. Detailed Implementation

[0011] To make the objectives, technical solutions, and advantages of this application clearer, specific embodiments of this application will be described in further detail below with reference to the accompanying drawings. It should be understood that the specific embodiments described herein are merely for explaining this application and not for limiting it. It should also be noted that, for ease of description, only the parts relevant to this application are shown in the drawings, not all of them. Before discussing exemplary embodiments in more detail, it should be mentioned that some exemplary embodiments are described as processes or methods depicted as flowcharts. Although the flowcharts describe operations (or steps) as being processed sequentially, many of these operations can be performed in parallel, concurrently, or simultaneously. Furthermore, the order of the operations can be rearranged. A process can be terminated when its operation is completed, but it may also have additional steps not included in the drawings. A process can correspond to a method, function, procedure, subroutine, subroutine, etc.

[0012] The terms "first," "second," etc., used in the specification and claims of this application are used to distinguish similar objects and not to describe a specific order or sequence. It should be understood that such use of data can be interchanged where appropriate so that embodiments of this application can be implemented in orders other than those illustrated or described herein, and the objects distinguished by "first," "second," etc., are generally of the same class and the number of objects is not limited; for example, a first object can be one or more. Furthermore, in the specification and claims, "and / or" indicates at least one of the connected objects, and the character " / " generally indicates that the preceding and following objects are in an "or" relationship.

[0013] Currently, with the popularization of smart home systems and the widespread deployment of sensing devices in home environment monitoring scenarios, infrared sensing-based automatic control capabilities have become an important basic function for improving user experience and energy efficiency. In typical applications such as lighting control, security monitoring, and environmental adaptive adjustment, it is necessary to accurately determine whether there is activity in the current environment based on the pyroelectric changes fed back by infrared sensors. However, in actual operating environments, infrared data is highly susceptible to interference from factors such as background temperature drift, random noise, and changes in device installation angle. If only simple thresholds or single-point data are relied upon for judgment, problems such as false triggering, missed triggering, or delayed response often occur, making it difficult to meet the stability and accuracy requirements of smart home devices.

[0014] In existing technologies, infrared detection relies heavily on instantaneous comparisons of raw sampled values, lacking structured processing of data in the time domain and failing to effectively distinguish between changes in the environmental baseline and actual changes in target activity. Furthermore, many implementations do not segmentally model pyroelectric changes at different time scales, making it difficult for the system to identify valid activity signals from continuous background changes, resulting in insufficient reliability in complex indoor environments.

[0015] To address the aforementioned technical problems, this application proposes an infrared data processing method based on time window segmentation and integral average feature extraction. This method acquires infrared data collected by infrared sensors and divides it into environmental time window data and detection time window data. It then calculates the integral average of the two time windows to generate an environmental baseline value and a detected activity value. Based on these two feature values, a target activity judgment value is constructed, thereby achieving a more robust assessment of the current activity level. When the target activity judgment value exceeds a threshold, the home appliances associated with the infrared sensors are automatically activated, achieving accurate perception and automatic response to actual activity behavior. This solution can significantly improve the triggering accuracy, anti-interference capability, and scene adaptability of infrared-sensing home appliances.

[0016] Figure 1 This is a flowchart of an infrared data processing method provided in an embodiment of this application. (Reference) Figure 1 The infrared data processing method specifically includes: S110. Acquire infrared data collected by the infrared sensor, and determine environmental time window data and detection time window data based on the infrared data.

[0017] In some embodiments, the infrared sensor may be a passive infrared sensing element used to sense changes in infrared radiation intensity within a target area, capable of detecting ambient background thermal radiation and dynamic infrared signals generated by a human body or object. Infrared data may be a sequence of digitized signals continuously acquired by the infrared sensor per unit time, used to describe the curve characteristics of thermal radiation intensity changing over time within the field of view.

[0018] In one embodiment, the infrared data collected by the infrared sensor can be obtained by driving the infrared sensor to output an electrical signal representing the intensity of thermal radiation in the current field of view, and then converting the electrical signal into infrared data through analog-to-digital conversion.

[0019] In one embodiment, the environmental time window data can be determined by extracting low-frequency stable variation segments from infrared data and constructing the environmental time window data from this time period.

[0020] In one embodiment, the detection time window data can be determined by extracting high-frequency abrupt change intervals from infrared data and constructing these intervals as the detection time window data.

[0021] In one embodiment, the method for distinguishing between the environmental time window and the detection time window can be: performing background modeling and dynamic change separation on the infrared data, marking the stable background interval as the environmental time window, and marking the dynamic change interval as the detection time window.

[0022] Through the above steps, environmental time window data and detection time window data can be constructed based on the sensing capability of infrared sensors and the temporal characteristics of infrared data, thereby providing a stable and efficient basic data structure for subsequent trigger judgment.

[0023] Optionally, Figure 2 This is a flowchart illustrating a time window data extraction method provided in an embodiment of this application. (Reference) Figure 2 The specific methods for extracting data within this time window include: S1101. Write the infrared data into a circular queue with a preset time span.

[0024] For example, a circular queue can be a fixed-length buffer structure that stores infrared data in chronological order. It has the characteristic of automatically overwriting the oldest data when the queue is full, and is used to maintain continuous infrared sampling data within a preset time span. The preset time span can be a fixed time length determined according to the sampling frequency and window requirements, used to ensure that the time window data remains valid throughout the sliding process.

[0025] In one embodiment, the infrared data can be written in the following way: at the end of each sampling period, the infrared data output by the current infrared sensor is written to the tail position of the queue; when the queue is not full, it is filled in order; when the queue is full, the oldest data position is overwritten, so that the queue always maintains a fixed capacity.

[0026] Through the above steps, infrared data can be continuously written to a circular queue with a preset time span, enabling the system to maintain the latest infrared changes in real time within a fixed-length data window, supporting subsequent data processing and activity determination logic.

[0027] S1102. Extract environmental time window data and detection time window data from the circular queue.

[0028] For example, the environmental time window data can be a stable data segment selected from a circular queue to represent changes in background infrared intensity, while the detection time window data can be a sensitive data segment selected from a circular queue to represent changes in dynamic infrared intensity. The time span of both types of windows can be a fixed or configurable length set according to the system's requirements for background modeling and activity detection, respectively.

[0029] In one embodiment, the method for extracting environmental time window data can be: reading a corresponding number of continuous infrared data from a circular queue according to a preset environmental window length to form environmental time window data.

[0030] In one embodiment, the detection time window data can be extracted by reading continuous infrared data representing changes from a circular queue according to a preset detection window length.

[0031] In one embodiment, environmental time window data is extracted through an environmental time window, and detection time window data is extracted through a detection time window. An interval time window is set between the environmental time window and the detection time window. By setting the interval time window, the anti-interference capability and sensing distance of infrared detection can be effectively improved.

[0032] In one embodiment, the environment window length can be a time span longer than the detection window length to obtain stable background trends; the detection window length can be a shorter time span to capture rapidly changing activity information.

[0033] Through the above steps, environmental time window data and detection time window data can be extracted from the circular queue, enabling the system to simultaneously obtain background information and dynamic change information on a unified continuous data stream, providing an accurate data foundation for subsequent integral calculation and activity determination.

[0034] S120. Calculate the integral average of the environmental time window data and the detection time window data respectively to obtain the environmental baseline value and the detection activity value.

[0035] In some embodiments, the environmental time window data can be a time series of changes in the ambient background infrared intensity over a stable period, and the detection time window data can be a time series of infrared changes caused by dynamic targets. The integral average value can be a value obtained by integrating the window data and normalizing the integration result, used for subsequent activity analysis.

[0036] In one embodiment, the environmental baseline value can be calculated by performing integration on continuous data within an environmental time window to obtain a cumulative value, and then dividing the cumulative value by the time length or the number of sampling points within the window to obtain the result as the environmental baseline value.

[0037] In one embodiment, the detection activity value can be calculated by performing integration on continuous data within the detection time window to obtain a cumulative value, and then dividing the cumulative value by the window length or the number of sampling points to obtain the result as the detection activity value.

[0038] Through the above steps, environmental baseline values ​​and detection activity values ​​can be obtained based on environmental time window data and detection time window data, respectively, so that subsequent activity judgments have clear and quantifiable basic data, providing a stable data basis for dynamic event triggering.

[0039] Optionally, before determining the target activity determination value based on the environmental reference value and the detection activity value, the method further includes: If the environmental reference value is greater than a preset reference value threshold, the environmental reference value is set as the reference value threshold.

[0040] For example, the environmental baseline value can be a background infrared intensity index calculated by integrating and averaging environmental time window data, and the baseline threshold can be a preset value used to limit the upper limit of the environmental baseline value, so as to avoid the instability of activity judgment caused by excessively high background.

[0041] In one embodiment, after calculating the environmental baseline value, a threshold comparison is performed on the value; when the environmental baseline value exceeds the baseline threshold, the environmental baseline value is directly assigned to the baseline threshold to avoid misjudgment caused by excessive background.

[0042] By following the steps above, a threshold limit can be applied to the environmental baseline value when it increases abnormally, ensuring that the environmental baseline value remains within a stable range and providing a reliable data foundation for subsequent target activity determination.

[0043] S130. Determine the target activity judgment value based on the environmental benchmark value and the detection activity value.

[0044] In some embodiments, the environmental reference value may be a numerical value representing the background infrared intensity level, and the detected activity value may be a numerical value representing the amplitude of dynamic infrared changes. The target activity determination value may be a calculated result used to determine whether there is valid activity in the current scene.

[0045] In one embodiment, the target activity determination value can be determined by calculating the ratio between the detected activity value and the environmental baseline value, and using that ratio as the target activity determination value.

[0046] Through the above steps, the target activity judgment value can be obtained based on the environmental baseline value and the detected activity value, enabling the system to form an effective judgment basis between stable background and dynamic activity, thereby providing a clear judgment basis for subsequent trigger control.

[0047] Optionally, determining the target activity judgment value based on the environmental reference value and the detected activity value includes: The ratio of the detected activity value to the environmental baseline value is calculated to obtain the target activity determination value.

[0048] For example, the detected activity value can be a dynamic infrared intensity index obtained by integrating and averaging the detection time window data, the environmental reference value can be a background infrared intensity index obtained by integrating and averaging the environmental time window data, and the target activity determination value can be an activity intensity parameter calculated based on the ratio between the detected activity value and the environmental reference value.

[0049] In one embodiment, the target activity determination value can be calculated by performing a division operation with the detected activity value as the numerator and the environmental baseline value as the denominator, and the result of the division operation is used as the target activity determination value.

[0050] Through the above steps, the target activity judgment value can be obtained by calculating the ratio of the detected activity value to the environmental baseline value. This allows the activity judgment process to consider both the dynamic change range and the background level, thereby improving the detection stability and robustness under complex environmental conditions.

[0051] Optionally, determining the target activity judgment value based on the environmental reference value and the detected activity value includes: The difference between the environmental baseline value and the detected activity value is calculated to obtain the target activity determination value.

[0052] For example, the environmental reference value can be a numerical value representing the background infrared intensity level, the detected activity value can be a numerical value representing the dynamic infrared change amplitude, and the target activity determination value can be an activity parameter obtained from the difference between the environmental reference value and the detected activity value.

[0053] In one embodiment, the target activity determination value can be calculated by subtracting the environmental baseline value from the detected activity value and using the result as the target activity determination value.

[0054] Through the above steps, the target activity determination value can be calculated by the difference between the environmental baseline value and the detected activity value, enabling the system to make activity judgments based on the absolute change range. This is suitable for scenarios with high background stability or those that are sensitive to dynamic change range.

[0055] S140. Determine an activity determination threshold based on the environmental reference value. If the target activity determination value is greater than the activity determination threshold, control the home device corresponding to the infrared sensor to turn on.

[0056] In some embodiments, the target activity determination value can be an activity index of the current infrared change intensity, and the activity determination value threshold can be a threshold parameter used to distinguish between normal background fluctuations and valid activity events. Home appliances can be lighting devices, alarm devices, or other electrical devices capable of performing actions, controlled by infrared sensors.

[0057] In one embodiment, the activity determination threshold can be determined by: determining the activity determination threshold corresponding to the environmental baseline value based on the correspondence between a set baseline value and a threshold value. The environmental baseline value and the activity determination threshold value are positively correlated.

[0058] In one embodiment, the activity determination threshold can be determined by: obtaining a set scaling factor and multiplying the environmental baseline value by the scaling factor to obtain the activity determination threshold.

[0059] In one embodiment, the activity determination threshold can be determined by: obtaining a set offset correction amount, and adding the offset correction amount to the environmental baseline value to obtain the activity determination threshold.

[0060] In one embodiment, the method of controlling the opening of home appliances can be: when the target activity determination value is detected to exceed the threshold, an opening command is sent to the home appliances through the control circuit or communication interface to make the appliances enter the working state.

[0061] In one embodiment, the action of turning on a home appliance can be: turning on a lighting device, starting a drive load, activating an alarm module, or performing other actions corresponding to an infrared sensing event.

[0062] Through the above steps, when the target activity judgment value is greater than the threshold, home appliances can be turned on in a timely manner, so that the system can execute the corresponding trigger action when it detects real activity, thereby achieving effective response and automated control to environmental changes.

[0063] Optionally, controlling the home appliance corresponding to the infrared sensor to turn on includes: Turn on the home appliance corresponding to the infrared sensor, and maintain the home appliance on for a preset duration after it is turned on.

[0064] For example, home appliances can be lights, alarms, ventilation equipment, or other electrical devices that can perform the turning action, controlled by infrared sensors. The preset turning-on duration can be a fixed duration configured according to the usage scenario to ensure that the device maintains a stable working cycle after detecting activity.

[0065] In one embodiment, the home appliance can be turned on by switching it from a closed state to an open state via a drive circuit or control command when a trigger condition is met, so that the appliance immediately enters the working mode.

[0066] In one embodiment, the home appliance can maintain a preset on-time by starting a timer module when the appliance is turned on, and controlling the appliance to perform a subsequent shutdown operation or maintain standby logic after the timer reaches the preset on-time.

[0067] In one embodiment, the preset activation duration can be a fixed duration or a configurable duration that is dynamically adjusted based on historical trigger records, ambient brightness, or user preferences, in order to adapt to the control needs of different usage scenarios.

[0068] By following the steps above, home appliances can be turned on immediately when an activity is triggered, and then run continuously for a preset duration after being turned on. This allows the system to respond to activities while maintaining a stable and controllable work cycle, thereby improving the user experience and energy efficiency of the devices.

[0069] Optionally, Figure 3 This is a flowchart of a threshold control method provided in an embodiment of this application. (Reference) Figure 3 The threshold control method specifically includes: S150. Determine sampling time window data including multiple consecutive samples based on the infrared data.

[0070] In some embodiments, the sampling time window data can be a time series extracted from infrared data in a continuous sampling order, used to represent the amplitude changes of several consecutive infrared samples. Multiple consecutive samples can be a fixed number set according to the sampling frequency, used to obtain a relatively complete infrared variation trend within a short period of time.

[0071] In one embodiment, the sampling time window data can be determined by extracting consecutive data points from the infrared data sequence according to a preset number of samples after each acquisition of a new infrared sample value, thereby forming the sampling time window data.

[0072] Through the above steps, sampling time window data containing multiple consecutive samples can be constructed based on infrared data, enabling the system to obtain continuous information on infrared changes on a short time scale, providing reliable data support for subsequent judgment of continuous activities or special triggering conditions.

[0073] S160. If all the data in the sampling time window are greater than the preset signal amplitude threshold, control the home device corresponding to the infrared sensor to turn on.

[0074] In some embodiments, the sampling time window data can be a time series composed of multiple consecutive infrared samples, used to determine whether the infrared signal remains at a high amplitude state for a short period of time. The signal amplitude threshold can be a preset limit value based on environmental noise, sensor sensitivity, or application scenario, used to distinguish between normal background fluctuations and significant infrared activity.

[0075] In one embodiment, the method of controlling the home device to turn on may be: performing threshold comparisons on the sampling time window data point by point, and when all sampled values ​​in the window are higher than the signal amplitude threshold, sending an turn-on command to the home device to make the home device enter the turn-on state.

[0076] In one embodiment, the method for determining the sampling time window data can be: traversing each sampling point within the window, and when there is no sampling point below the signal amplitude threshold, the window is considered to meet the condition of continuous high amplitude.

[0077] By following the steps above, home appliances can be automatically turned on when the data in the sampling time window is continuously higher than the signal amplitude threshold. This enables the system to identify high-intensity infrared signal events within a short period of time, improving the triggering reliability in special scenarios.

[0078] Optionally, Figure 4 This is a flowchart illustrating the steps of an infrared data processing method provided in an embodiment of this application. (Reference) Figure 4 The infrared data processing method specifically includes: S201. Periodically sample infrared data and use the infrared data to construct an 8-second circular queue.

[0079] For example, periodic sampling can involve acquiring infrared data from an infrared sensor according to a preset fixed sampling period, and sequentially writing the infrared data obtained from each sampling into a circular queue for storing the most recent 8 seconds of data. The circular queue can be a fixed-length data buffer structure, the capacity of which is calculated based on the sampling period and the 8-second time span, and is used to continuously maintain the continuous infrared data sequence of the most recent 8 seconds.

[0080] In one embodiment, the sampling period of the infrared sensor is set, such as 100ms, 50ms or other sampling intervals; when each sampling period arrives, the current infrared sampling value of the sensor is read and written into a circular queue.

[0081] In one embodiment, the number of sampling points required within 8 seconds is calculated based on the sampling period. For example, when the sampling period is 100ms, the length of the circular queue can be 80 sampling points. When new sampling data is written to the tail of the queue and the queue is full, the oldest data at the head of the queue is automatically overwritten, thereby realizing continuous sliding updates of the 8-second window.

[0082] In one embodiment, the data in the circular queue can be the underlying data subsequently used to construct an environmental time window, a detection time window, or a sampling time window, enabling subsequent activity identification logic to be executed based on a continuous and complete short-time infrared change sequence.

[0083] S202. Calculate the average integral value of the first 6 seconds in the circular queue to obtain the environmental baseline value.

[0084] For example, the environmental baseline value can be the background infrared intensity value calculated by integrating and averaging the data from the first 6 seconds in the circular queue, which can be used to reflect the stable trend of environmental infrared changes over a short period of time.

[0085] In one embodiment, the number of sampling points within 6 seconds is determined based on the sampling period. The corresponding number of continuous data points are read from the head of the circular queue, and an integral operation is performed on these data points. The integral result is then divided by the number of sampling points or the time length corresponding to 6 seconds to obtain the environmental baseline value.

[0086] In one embodiment, all sampled values ​​from the first 6 seconds are summed to obtain a cumulative value, which is then divided by the number of data points to obtain an environmental baseline value used to represent the current ambient background infrared intensity level.

[0087] In one embodiment, the data from the first 6 seconds can be the main data segment used to reflect the stability of environmental thermal radiation. By calculating the integral average of this data segment, a smoother background reference value can be obtained, reducing the impact of transient interference.

[0088] S203. Calculate the average integral of the last 2 seconds in the circular queue to obtain the detected activity value.

[0089] For example, the detected activity value can be a dynamic infrared change value calculated by integrating and averaging the data from the last 2 seconds in the circular queue, which can be used to reflect the changes in infrared intensity caused by human movement or other activities in a short period of time.

[0090] In one embodiment, the number of sampling points within 2 seconds is determined based on the sampling period. The corresponding number of continuous data points are read forward from the tail of the circular queue. An integral operation is performed on these data points, and the integral result is divided by the number of sampling points or the time length corresponding to 2 seconds, so that the result is used as the detection activity value.

[0091] In one embodiment, all sampled values ​​in the last 2 seconds are summed to obtain a cumulative value, which is then divided by the number of data points, so that the detection activity value can reflect the intensity of changes in the short-time infrared signal.

[0092] In one embodiment, the data from the last two seconds can be the main interval for capturing activity triggering information. By performing integral averaging on this interval, activity-related rapid infrared fluctuations can be effectively extracted, facilitating the system's activity determination.

[0093] S204. Calculate the ratio of the environmental baseline value to the detection activity value to obtain the target activity judgment value.

[0094] For example, the environmental reference value can be a numerical value representing the ambient background infrared intensity level, the detected activity value can be a numerical value representing the dynamic infrared change amplitude, and the target activity determination value can be an activity intensity parameter obtained based on the ratio of the two, used to reflect the relative degree of dynamic change with respect to the background level.

[0095] In one embodiment, a division operation is performed with the detected activity value as the numerator and the environmental baseline value as the denominator, and the calculated result is used as the target activity determination value.

[0096] In one embodiment, a threshold limit is imposed on the environmental reference value. When the environmental reference value is lower than a preset lower limit, the environmental reference value is raised to the lower limit threshold to avoid numerical anomalies caused by an excessively small divisor in the ratio calculation.

[0097] In one embodiment, the target activity determination value can be a key parameter used in the activity determination process. When the ratio is large, it indicates that the dynamic change is significantly higher than the background, and when the ratio is small, it indicates that the infrared change is at a normal background level.

[0098] S205. If the target activity judgment value is greater than the activity judgment value threshold, turn on the corresponding home device.

[0099] For example, the target activity determination value can be an activity value representing dynamic infrared changes relative to background intensity, and the activity determination value threshold can be a reference threshold used to distinguish valid activity from normal background fluctuations. Home appliances can be lights, alarms, or other devices that can perform an activation action, triggered by an infrared sensor.

[0100] In one embodiment, when the detected target activity value exceeds the threshold, the control module sends an activation command to the home appliance, causing the home appliance to switch from the off state to the on state.

[0101] In one embodiment, the activity determination threshold can be a value that varies according to different scenario requirements, such as different thresholds for low-light or high-light environments, so that the system can maintain stable trigger sensitivity under different background conditions.

[0102] In one embodiment, lighting equipment is turned on, motor load is started, alarm module is activated, or other actions related to infrared activity detection are performed, enabling the system to respond promptly when a valid infrared change is detected.

[0103] Based on the above embodiments, Figure 5 This is a structural block diagram of an infrared data processing device provided in an embodiment of this application. (Reference) Figure 5 The infrared data processing device provided in this embodiment specifically includes: a window data module 11, an integral averaging module 12, an activity determination module 13, and a device control module 14.

[0104] The window data module 11 is configured to acquire infrared data collected by the infrared sensor and determine environmental time window data and detection time window data based on the infrared data; the integral averaging module 12 is configured to calculate the integral average of the environmental time window data and the detection time window data respectively to obtain an environmental reference value and a detection activity value; the activity determination module 13 is configured to determine a target activity determination value based on the environmental reference value and the detection activity value; and the device control module 14 is configured to determine an activity determination value threshold based on the environmental reference value and control the home device corresponding to the infrared sensor to turn on when the target activity determination value is greater than the activity determination value threshold.

[0105] Based on the above embodiments, the window data module 11 includes: a circular queue unit configured to write the infrared data into a circular queue with a preset time span; and a window data unit configured to extract environmental time window data and detection time window data from the circular queue.

[0106] Based on the above embodiments, the activity determination module 13 includes: a ratio calculation unit, configured to calculate the ratio of the detected activity value to the environmental reference value to obtain the target activity determination value.

[0107] Based on the above embodiments, the activity determination module 13 further includes: a difference calculation unit, configured to calculate the difference between the environmental reference value and the detected activity value to obtain a target activity determination value.

[0108] Based on the above embodiments, the infrared data processing device further includes: a reference value limiting module, configured to set the environmental reference value as a reference value threshold when the environmental reference value is greater than a preset reference value threshold.

[0109] Based on the above embodiments, the infrared data processing device further includes: a sampling window module, configured to determine sampling time window data including multiple consecutive samplings based on the infrared data; and a threshold control module, configured to control the home appliances corresponding to the infrared sensor to turn on when all the sampling time window data are greater than a preset signal amplitude threshold.

[0110] Based on the above embodiments, the device control module 14 includes: a continuous on unit, configured to turn on the home device corresponding to the infrared sensor, and maintain the on for a preset on duration after the home device is turned on.

[0111] The infrared data processing device provided in this application embodiment, through the construction of a hierarchical processing architecture consisting of a window data module 11, an integral averaging module 12, an activity determination module 13, and a device control module 14, realizes an end-to-end perception and execution link from raw infrared data acquisition, time window construction, integral averaging calculation to activity intensity determination and device linkage control. This device can perform windowed segmentation and feature extraction on the continuous sampling data output by the infrared sensor, comprehensively considering the baseline energy level of the environmental reference interval and the transient energy changes of the target detection interval to complete indoor activity recognition, action triggering, and device drive control, thereby improving the accuracy, robustness, and real-time response capability of smart home interaction based on infrared sensing. Specifically, the window data module 11 has infrared data acquisition and time window segmentation capabilities, used to acquire the continuous sampling data stream output by the infrared sensor. It generates environmental time window data and detection time window data through a time series division strategy based on a preset sampling period, enabling the system to distinguish between background static energy distribution and foreground dynamic activity changes within the same observation period, providing a stable windowed data foundation for subsequent activity feature calculations. The integral averaging module 12 is responsible for energy feature extraction. It performs integral averaging calculations on environmental time window data and detection time window data respectively to generate environmental baseline values ​​and detected activity values, realizing quantifiable feature conversion based on window energy distribution. The environmental baseline value characterizes the steady-state level of infrared energy under environmental background, while the detected activity value reflects whether there are recent changes in heat sources or human activity, providing key input parameters for the activity determination process. The activity determination module 13 has the ability to quantify and determine activity intensity. It constructs a target activity determination value based on the environmental baseline value and the detected activity value. By comparing the energy difference or ratio change between the two time windows, it completes the judgment of the existence and intensity level of activity in the current monitoring area, providing a clear activity status indication for subsequent equipment control logic. The equipment control module 14 is used to trigger the opening action of home appliances associated with the infrared sensor when the target activity determination value exceeds a preset activity threshold, realizing automated equipment linkage control based on human activity detection; and can maintain the device for a preset duration after it is turned on, thereby avoiding energy waste or user experience degradation caused by frequent start-stop. Through the collaborative processing of the above modules, the infrared data processing device constructs a complete closed-loop process from data acquisition, window construction, energy feature extraction to activity determination and device linkage, which can realize real-time identification of indoor activities and intelligent control of corresponding home appliances, significantly enhancing the adaptability, stability and response speed of the environmental perception system.

[0112] Figure 6 This is a schematic diagram of the structure of an infrared data processing device provided in an embodiment of this application, with reference to... Figure 6The infrared data processing device includes a processor 21, a memory 22, a communication device 23, an input device 24, and an output device 25. The number of processors 21 and the number of memories 22 in the infrared data processing device can be one or more. The processor 21, memory 22, communication device 23, input device 24, and output device 25 of the infrared data processing device can be connected via a bus or other means.

[0113] The memory 22, as a computer-readable storage medium, can be used to store software programs, computer executable files, and modules, such as program instructions / modules corresponding to the infrared data processing method in any embodiment of this application (e.g., window data module 11, integral averaging module 12, activity determination module 13, and device control module 14 in the infrared data processing device). The memory 22 may primarily include a program storage area and a data storage area. The program storage area may store the operating system and at least one application program required for a function; the data storage area may store data created based on the use of the device, etc. Furthermore, the memory 22 may include high-speed random access memory and may also include non-volatile memory, such as at least one disk storage device, flash memory device, or other non-volatile solid-state storage device. In some instances, the memory may further include memory remotely located relative to the processor, and these remote memories can be connected to the device via a network. Examples of such networks include, but are not limited to, the Internet, corporate intranets, local area networks, mobile communication networks, and combinations thereof.

[0114] The communication device 23 is used for data transmission.

[0115] The processor 21 executes various functional applications and data processing of the device by running software programs, instructions and modules stored in the memory 22, thereby realizing the infrared data processing method described above.

[0116] Input device 24 can be used to receive input digital or character information, and to generate key signal inputs related to user settings and function control of the device. Output device 25 may include display devices such as a display screen.

[0117] The infrared data processing device provided above can be used to execute the infrared data processing method provided in the above embodiments, and has corresponding functions and beneficial effects.

[0118] This application embodiment also provides a storage medium containing computer-executable instructions. When executed by a computer processor, the computer-executable instructions are used to perform an infrared data processing method. The infrared data processing method includes: acquiring infrared data collected by an infrared sensor; determining environmental time window data and detection time window data based on the infrared data; calculating the integral average of the environmental time window data and the detection time window data respectively to obtain an environmental reference value and a detection activity value; determining a target activity determination value based on the environmental reference value and the detection activity value; determining an activity determination value threshold based on the environmental reference value; and controlling the home appliance corresponding to the infrared sensor to turn on when the target activity determination value is greater than the activity determination value threshold.

[0119] Storage medium—any type of memory device or storage device. The term "storage medium" is intended to include: mounting media, such as CD-ROM, floppy disk, or magnetic tape devices; computer system memory or random access memory, such as DRAM, DDR RAM, SRAM, EDO RAM, etc.; non-volatile memory, such as flash memory, magnetic media (e.g., hard disk or optical storage); registers or other similar types of memory elements, etc. Storage medium may also include other types of memory or combinations thereof. Furthermore, storage medium may reside in a first computer system in which a program is executed, or it may reside in a different second computer system connected to the first computer system via a network (such as the Internet). The second computer system can provide program instructions to the first computer for execution. The term "storage medium" may include two or more storage media residing in different locations (e.g., in different computer systems connected via a network). Storage medium may store program instructions (e.g., specifically implemented as a computer program) executable by one or more processors.

[0120] Of course, the computer-executable instructions provided in the embodiments of this application are not limited to the infrared data processing method described above, but can also perform related operations in the infrared data processing method provided in any embodiment of this application.

[0121] The infrared data processing device, storage medium, and infrared data processing equipment provided in the above embodiments can execute the infrared data processing method provided in any embodiment of this application. For technical details not described in detail in the above embodiments, please refer to the infrared data processing method provided in any embodiment of this application.

[0122] The above description is merely a preferred embodiment and the technical principles employed in this application. This application is not limited to the specific embodiments described herein, and various obvious changes, readjustments, and substitutions that can be made by those skilled in the art will not depart from the scope of protection of this application. Therefore, although this application has been described in detail through the above embodiments, this application is not limited to the above embodiments, and may include many other equivalent embodiments without departing from the concept of this application. The scope of this application is determined by the scope of the claims.

Claims

1. An infrared data processing method, characterized in that, include: Acquire infrared data collected by an infrared sensor, and determine environmental time window data and detection time window data based on the infrared data; The integral average of the environmental time window data and the detection time window data are calculated respectively to obtain the environmental baseline value and the detection activity value; The target activity determination value is determined based on the environmental baseline value and the detection activity value; Based on the environmental baseline value, an activity determination threshold is determined. If the target activity determination value is greater than the activity determination threshold, the home device corresponding to the infrared sensor is controlled to turn on.

2. The infrared data processing method according to claim 1, characterized in that, The step of determining the environmental time window data and the detection time window data based on the infrared data includes: The infrared data is written into a circular queue with a preset time span; Extract environmental time window data and detection time window data from the circular queue.

3. The infrared data processing method according to claim 1, characterized in that, The step of determining the target activity judgment value based on the environmental benchmark value and the detected activity value includes: The ratio of the detected activity value to the environmental baseline value is calculated to obtain the target activity determination value.

4. The infrared data processing method according to claim 1, characterized in that, The step of determining the target activity judgment value based on the environmental benchmark value and the detected activity value includes: The difference between the environmental baseline value and the detected activity value is calculated to obtain the target activity determination value.

5. The infrared data processing method according to claim 1, characterized in that, Before determining the target activity judgment value based on the environmental reference value and the detection activity value, the method further includes: If the environmental reference value is greater than a preset reference value threshold, the environmental reference value is set as the reference value threshold.

6. The infrared data processing method according to claim 1, characterized in that, The infrared data processing method further includes: Based on the infrared data, a sampling time window data including multiple consecutive samples is determined; If all data within the sampling time window are greater than a preset signal amplitude threshold, the home appliance corresponding to the infrared sensor is turned on.

7. The infrared data processing method according to claim 1, characterized in that, The control of the home appliances corresponding to the infrared sensor to turn on includes: Turn on the home appliance corresponding to the infrared sensor, and maintain the home appliance on for a preset duration after it is turned on.

8. An infrared data processing device, characterized in that, include: The window data module is configured to acquire infrared data collected by the infrared sensor and determine environmental time window data and detection time window data based on the infrared data. The integral averaging module is configured to calculate the integral average of the environmental time window data and the detection time window data respectively, to obtain the environmental baseline value and the detection activity value. The activity determination module is configured to determine a target activity determination value based on the environmental baseline value and the detected activity value; The device control module is configured to determine an activity determination threshold based on the environmental reference value, and to control the home device corresponding to the infrared sensor to turn on when the target activity determination value is greater than the activity determination threshold value.

9. An infrared data processing device, characterized in that, include: One or more processors; A memory that stores one or more programs, which, when executed by one or more processors, cause the one or more processors to implement the infrared data processing method as described in any one of claims 1-7.

10. A storage medium containing computer-executable instructions, characterized in that, The computer-executable instructions, when executed by a computer processor, are used to perform the infrared data processing method as described in any one of claims 1-7.