Target motion detection method and device

By calculating the SAD and Census generation values ​​of the current frame and reference frame, judging the target motion with the threshold, and switching the image sensor mode when the motion is detected, the problem of energy consumption and storage waste in static scenes is solved, and efficient target motion detection is achieved.

CN118429381BActive Publication Date: 2025-08-22SHENZHEN XINTU INTELLIGENT SENSE TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202410243973.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-03-04
Publication Date
2025-08-22
Estimated Expiration
2044-03-04

AI Technical Summary

Technical Problem

In visual detection, the multi-frame image of the stationary scene does not change, resulting in energy consumption loss and waste of storage space, and the prior art cannot effectively identify the stationary scene to reduce the transmission and storage of invalid data.

Method used

By calculating the SAD and Census generation values ​​of the current frame and the reference frame, the threshold values ​​are used to determine whether the target is motionless, and switching the operating mode of the image sensor when the motion is detected to reduce energy consumption and reduce storage.

Benefits of technology

It improves the accuracy of target motion detection, reduces the transmission and storage of invalid data, and reduces energy consumption loss.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118429381B_ABST
    Figure CN118429381B_ABST
Patent Text Reader

Abstract

The present application relates to a target motion detection method, comprising: obtaining an image data stream, the image data stream including a current frame and a reference frame; calculating the SAD cost value and the Census cost value of the current frame and the reference frame; if the SAD cost value and the Census cost value meet the judgment condition, determining that the target is in motion. The judgment condition includes at least one of the following conditions: Condition 1: The SAD cost value is not less than a first threshold value and not greater than a second threshold value; Condition 2: The SAD cost value is greater than the second threshold value and the Census cost value is not less than a third threshold value. The target motion detection method proposed in the present application uses image matching SAD and Census cost values ​​for comprehensive judgment, thereby improving the accuracy of target motion detection. According to target motion detection, invalid data transmission and storage can be reduced, and energy loss can be reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application belongs to the field of image processing technology and relates to a target motion detection method and device. Background Art

[0002] In visual inspection applications, static scenes are often encountered. In these cases, the multiple frames received do not show any changes, making it difficult for inspectors to obtain more effective information from the video stream data. This is because moving objects in the scene are of greater concern during the inspection process. Static scenes only require one frame of data to convey all information, and subsequent frames are "invalid." The storage and transmission of multiple consecutive frames of invalid data results in energy consumption and waste of storage space.

[0003] The contents of the background technology section are merely publicly known technologies and do not necessarily represent the existing technologies in this field. Summary of the Invention

[0004] The purpose of the present application is to at least to some extent solve the deficiencies in the prior art. In a first aspect, the present application provides a target motion detection method, comprising: obtaining an image data stream, the image data stream including a current frame and a reference frame; calculating the SAD cost value and the Census cost value of the current frame and the reference frame; if the SAD cost value and the Census cost value meet the judgment conditions, it is determined that the target is in motion; wherein the judgment conditions include at least one of the following conditions: Condition 1: the SAD cost value is not less than a first threshold and not greater than a second threshold; Condition 2: the SAD cost value is greater than the second threshold and the Census cost value is not less than a third threshold.

[0005] In some embodiments, the reference frame and the current frame are adjacent frame images.

[0006] In some embodiments, the method further includes a misjudgment prevention step: obtaining SAD cost values ​​and Census cost values ​​calculated n times in succession; if there are m SAD cost values ​​and Census cost values ​​that meet the judgment condition, then determining that the target is moving, wherein, .

[0007] In some embodiments, three consecutive calculated SAD cost values ​​and Census cost values ​​are obtained, and if the three consecutive SAD cost values ​​and Census cost values ​​all meet the determination condition, it is determined that the target is moving.

[0008] In some embodiments, the threshold is determined by simulation fitting based on real data sets collected from user scenarios; user scenarios include static scenes, motion scenes, static scenes with changing ambient brightness, and darker environments with low signal-to-noise ratio scenes.

[0009] In a second aspect, the present application provides a target motion detection device, comprising: an acquisition unit for acquiring an image data stream, the image data stream including a current frame and a reference frame; a calculation unit for calculating a SAD cost value and a Census cost value for the current frame and the reference frame; and a determination unit for determining whether the SAD cost value and the Census cost value meet a determination condition to determine whether the target is in motion. The determination condition includes at least one of the following conditions: Condition 1: The SAD cost value is not less than a first threshold and not greater than a second threshold; Condition 2: The SAD cost value is greater than the second threshold and the Census cost value is not less than a third threshold.

[0010] The third aspect of the present application provides an image sensor with multiple operating modes, including: a pixel array unit for outputting electrical signals; a processing circuit unit for processing the electrical signals to output image data; wherein the A / D conversion circuit is used to merge the electrical signals to output low-resolution image information; and an image signal processing unit for receiving the low-resolution image information and executing the aforementioned target motion detection method.

[0011] In some embodiments, when target motion is detected, the image sensor operates in full-resolution mode and outputs full-resolution image data.

[0012] The fourth aspect of the present application provides a system with automatic switching of working modes, including: the aforementioned image sensor and a host computer; when the image sensor outputs a low-resolution image, the host computer is in a standby state; when the image sensor outputs a full-resolution image, the host computer is in a working state.

[0013] In a fifth aspect, the present application provides a computer-readable storage medium, which stores a computer program. The computer program is executed by a processor to implement the above-mentioned target detection method.

[0014] It can be seen from the above-mentioned embodiments of the present application that the target motion detection method proposed in this application uses image matching SAD and Census cost value for comprehensive judgment, which improves the accuracy of target motion detection. According to target motion detection, invalid data transmission and storage can be reduced, and energy consumption loss can be reduced. BRIEF DESCRIPTION OF THE DRAWINGS

[0015] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are only some embodiments of the present application. For those skilled in the art, other drawings can be obtained based on these drawings without paying any creative work.

[0016] Figure 1A schematic diagram of an image sensor provided in an embodiment of the present application;

[0017] Figure 2 A flowchart of a target motion detection method provided in an embodiment of the present application;

[0018] Figure 3 A flowchart of another target motion detection method provided in an embodiment of the present application;

[0019] Figure 4 A schematic block diagram of an object motion detection device provided in an embodiment of the present application;

[0020] Figure 5 A schematic diagram of an image sensor with multiple operating modes provided in an embodiment of the present application;

[0021] Figure 6 A schematic block diagram of a system with automatic switching of working modes provided in an embodiment of the present application;

[0022] Figure 7 A schematic block diagram of a computer-readable storage medium provided in an embodiment of the present application. DETAILED DESCRIPTION

[0023] The embodiments of the present application are described in detail below. Examples of the embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are intended to be used to explain the present application, and should not be understood as limiting the present application. All other embodiments obtained by ordinary technicians in this field based on the embodiments in the present application without making any creative efforts shall fall within the scope of protection of the present application.

[0024] Figure 1 It is a schematic diagram of an image sensor 100 proposed in an embodiment of the present application. The image sensor 100 includes a pixel array unit 110 and a processing circuit unit 120. Among them, the pixel array unit 110 includes a pixel array composed of a plurality of CMOS pixel units, which is used to receive light signals and convert the light signals into corresponding electrical signals. The total number of pixels in the pixel array unit 110, that is, the resolution is determined by the actual application scenario. In the pixel array unit 110, each pixel unit is composed of a photosensitive device photodiode (photo-diode, PD) and one or more CMOS transistors (transistor). According to the number of transistors, it can be divided into 4T, 5T, 6T and other types to meet the application requirements of different scenarios. In the preferred embodiment of the present application, a 6T global exposure (global shutter) pixel structure is adopted.

[0025] The processing circuit unit 120 may include a control circuit, an A / D conversion circuit, an image signal processing circuit, and a storage circuit. The control circuit is used to control the operation of the pixel array; the A / D conversion circuit is used to convert the electrical signals output by the pixel array into digital form to obtain image information; the image signal processing circuit is used to process the image information; and the storage circuit is used to store the electrical signals generated by the pixel array and / or the image signal processing circuit.

[0026] The image signal processing circuit (ISP) is used to process the raw data output by the pixel array unit, including functions such as automatic exposure control, automatic gain control, histogram statistics, mirroring, image correction, etc., and then output grayscale image data in RAW format. It is understandable that the processing of image data by the image signal processing circuit is a conventional technical means in this field and is not specifically limited in this application. The image signal processing circuit can be external as a separate processor or integrated into the sensor as part of the processing circuit. In the embodiment of the present application, the image signal processing circuit is integrated into the image sensor.

[0027] In some embodiments, the image sensor 100 is manufactured on a single wafer, which is divided into a pixel array unit and a processing circuit unit. In other embodiments, the image sensor 100 is formed by stacking two wafers, one above the other, so that the two wafers can completely overlap vertically during the stacking process. One of the wafers is provided with a pixel array unit, and the corresponding wafer can optionally be referred to as a pixel wafer; the other wafer is provided with a processing circuit unit, and the corresponding wafer can optionally be referred to as an image signal processing wafer (ISPWafer).

[0028] Optionally, the storage circuit may be a dynamic random access memory (DRAM) circuit. It should be understood that the storage circuit may also be other types of storage circuits, such as other random access memory (RAM) circuits or read-only memory (ROM) circuits, and the embodiments of the present application do not impose any limitation on this.

[0029] Figure 1The CMOS image sensor in the illustrated embodiment is a sensor chip that converts optical signals into digital signals and is widely used in various fields, including digital products, mobile terminals, security monitoring, scientific research, and industry. As a common application scenario, the image sensor provided in the embodiment of the present application can be used in the camera of electronic devices, such as surveillance equipment or barcode scanners.

[0030] During visual inspection, the image sensor continuously outputs image data of the scene. When there are no noticeable changes in the scene (no target motion), the image in the video typically remains unchanged. In this case, it's impossible to extract more useful information from the video stream. For inspection, moving targets in a scene are of greater interest, while static scenes only require a single frame of data to capture all information; subsequent frames are "invalid." Furthermore, because the camera constantly operates at full power, this results in energy loss and increased storage capacity due to the large amount of invalid data output. If the presence of target motion in the scene can be accurately and in real time identified, and the appropriate mode and valid data output can be selected based on the recognition result, both power consumption and data storage requirements can be reduced.

[0031] Based on the above-mentioned image sensor 100, an embodiment of the present application proposes a target motion detection method to solve the problems existing in the prior art regarding power consumption and data storage.

[0032] Figure 2 This is a flow chart of a target motion detection method provided by an embodiment of the present application. It specifically includes the following steps:

[0033] S210: Acquire an image data stream, where the image data stream includes a current frame and a reference frame.

[0034] In some embodiments, the currently detected data is considered to be the current frame, and the current frame and the reference frame are adjacent frame data. In one embodiment, the reference frame is configured as the frame image before the current frame; for example, if the current frame is the second frame image, the reference frame is the first frame image; if the current frame is the third frame image, the reference frame is the second frame image, and so on.

[0035] S220: Calculate the SAD cost value and the Census cost value of the current frame and the reference frame.

[0036] In the embodiments of this application, the object motion detection method is primarily based on the similarity between two adjacent image frames. When the similarity is high, it is considered that there is no significant difference between the two frames and the object is not moving. When the similarity is low, it is considered that there is a change between the two frames and motion occurs. Specifically, the similarity between the two frames is determined based on the SAD cost and Census cost calculated by matching the current frame with the reference frame.

[0037] In one embodiment, calculating the SAD cost of the current frame and the reference frame includes: obtaining the reference frame and the current frame, selecting an anchor point in the reference frame and performing a scan. Specifically, (1) constructing a small window with the anchor point as the center, and setting the horizontal and vertical movement distances of the window; (2) covering the reference frame with the window, and selecting all pixels in the window coverage area; (3) similarly covering the current frame with the window and selecting all pixels in the coverage area; (4) subtracting the current frame coverage area from the reference frame coverage area, and calculating the sum of the absolute values ​​of the grayscale differences of all pixels; (5) synchronously moving the reference frame and the current frame windows according to the step size set in (1), and repeating the processes (2)-(4); (6) accumulating the sum of the absolute differences calculated for all windows as the SAD cost value.

[0038] In one embodiment, calculating the Census cost of the current frame and the reference frame includes: defining a rectangular window in the image area and traversing the entire image with this rectangular window. Selecting the center pixel as the reference pixel, comparing the grayscale value of each pixel in the rectangular window with the grayscale value of the reference pixel, marking pixels with grayscale values ​​greater than or equal to the reference value as 0, and pixels with grayscale values ​​less than the reference value as 1. Finally, these pixels are bitwise concatenated to obtain a transformed result, which is a binary code stream consisting of 0s and 1s. The Census transformation process can be expressed by the following formula:

[0039]

[0040] Where p is the center pixel of the window, q is the other pixels outside the center pixel of the window, and Np represents the neighborhood of the center pixel p. I(*) represents the grayscale value at pixel point *. It is a bit-by-bit concatenation operation. The ( ) operation is defined by the following formula:

[0041]

[0042] The above formula can be used to obtain a binary string of Census transforms. The matching cost calculation method based on Census transform is to calculate the Hamming distance of the Census transform values ​​of the two windows corresponding to the reference frame and the current frame. That is, the matching cost is:

[0043]

[0044] in, is the binary string generated by the reference frame, and T(q) is the binary string generated by the current frame. The Hamming distance is the number of differences between corresponding bits of two bit strings. It is calculated by performing an XOR operation on the two bit strings and then counting the number of 1s in the bits in the XOR result. This number of 1s is the desired matching cost.

[0045] The above describes how to calculate the Census result for a single window. Similarly, set the horizontal and vertical window movement steps. During each match, move the reference frame and current frame windows synchronously to ensure that both windows cover the same pixel image area (that is, the pixel coordinates of the boundaries of the coverage area of ​​each window remain consistent). The Census results calculated for all windows are accumulated to obtain the Census cost.

[0046] S230: If the SAD cost value and the Census cost value meet the determination conditions, it is determined that the target is moving. The determination conditions include at least one of the following conditions:

[0047] Condition 1: The SAD cost value is not less than the first threshold and not greater than the second threshold;

[0048] Condition 2: The SAD cost value is greater than the second threshold and the Census cost value is not less than the third threshold.

[0049] In an alternative embodiment, the following may be performed: Figure 3 The determination process shown is used to determine whether the target motion occurs. The process of calculating the SAD cost value and the Census cost value of the current frame and the reference frame is shown in step S220 and will not be repeated here. The specific determination process includes:

[0050] S310: Determine whether the SAD cost value is less than a first threshold.

[0051] If the SAD cost value is less than the first threshold, it is determined that the target is not moving; otherwise, step S320 is executed.

[0052] S320: Determine whether the SAD cost value is greater than a second threshold.

[0053] If the SAD cost value is not greater than the second threshold, it is determined that the target is moving; if so, step S330 is executed.

[0054] S330: Determine whether the Census cost value is less than a third threshold.

[0055] If so, it is determined that the target is not moving; if not, it is determined that the target is moving.

[0056] In some embodiments, the threshold is determined by simulation fitting based on a real data set collected from user scenarios. Specifically, the steps include: (1) collecting a real data set of user scenarios, which includes static scenes, motion scenes, static scenes with changing ambient brightness, dark environments with low signal-to-noise ratio, etc. (2) simulating and calculating the SAD cost value and Census cost value of adjacent frame image data under each data set. (3) performing nonlinear normalization on the calculation results, and the normalization formula is as follows:

[0057]

[0058]

[0059] Among them, SAD_cost and Census_cost represent the matching calculation results in the data set, n_windows represents the total number of windows for sliding window matching, and n_winpixels is the total number of pixels in a single window. and The adjustment parameters for normalizing the results can be adjusted according to specific circumstances and are not specifically limited in the embodiments of this application. Normalization allows for more intuitive threshold setting, and the processed results can effectively distinguish the cost values ​​calculated in different scenarios, allowing for flexible adjustment of the thresholds based on different scenarios.

[0060] (4) According to the normalization formula, the real cost is obtained by back-calculation to determine the final threshold. The back-calculation formula is as follows:

[0061]

[0062]

[0063] It is understandable that when setting the threshold, the scenes of the collected data set must be rich, including static scenes, motion scenes, static scenes with changing ambient brightness, darker environments with low signal-to-noise ratio, etc., and the results after normalization processing can effectively distinguish the cost values ​​calculated in different scenes. In actual applications, the threshold can be adjusted for different scenes, so that the target motion detection method covers a wide range of scenes and improves the accuracy of detection in different scenes.

[0064] In some embodiments, the vertical blanking (VB) of the sensor can also be configured to ensure that the interval between adjacent frames is not too small to prevent the target's motion amplitude in adjacent frames from being too small to be correctly detected.

[0065] In some embodiments, a method for detecting target motion to prevent misjudgment is also provided. Specifically, Figure 2 The method shown comprises the following steps

[0066] S221: Obtain the SAD cost value and Census cost value calculated for n consecutive times.

[0067] S231: If there are m times of SAD cost value and Census cost value that meet the judgment condition, then it is determined that the target is moving. .

[0068] Specifically, two adjacent frames are tested and tested n times continuously. For example, the first and second frames are tested as the first time, the first frame is discarded and the third frame is loaded. The cost value of the second and third frames is calculated as the second time, and so on, until the nth frame and the n+1th frame are tested to obtain the nth detection result. If the result of m detections is motion, it is determined that the target is moving. The process of adjacent frame detection can be seen in Figure 2 The embodiments of the present invention will not be repeated here. It is understood that the m detection results can be continuous or discontinuous, as long as the number of detections reaches m. If the condition is not satisfied, detection continues until the anti-false positive strategy is met, and the target is determined to be in motion. By adding the anti-false positive strategy, the robustness of the algorithm is improved, and the detection results are prevented from being affected by factors such as noise interference and motion rate, which may cause the confidence level of certain frame detection results to be low.

[0069] In some embodiments, another target motion detection method to prevent misjudgment is provided, specifically, comprising the following steps: obtaining three consecutive detection results and if all three detection results indicate motion, then it is determined that the target is in motion; otherwise, the next frame is used as a reference frame to continue the detection.

[0070] For example, after calculating the cost value of the first and second frames and saving the calculated cost, discard the first frame and load the third frame, and continue to calculate the cost value of the second and third frames, as well as the cost value of the third and fourth frames, thereby obtaining three consecutive cost values. If the calculation results of three consecutive times meet the judgment condition, that is, each time after the judgment, it is determined that the target is moving, then it is determined that the target is moving. If the judgment condition is not met in three consecutive detections, that is, after a certain judgment, it is determined that the target is not moving, for example, the first result is no motion, and the second and third judgment results are motion, then the fourth frame is used as the reference frame, and the matching calculation of the fifth frame and the fourth frame is performed. If the target is detected to be moving, it is determined to be moving. If no motion is detected, the detection step is continued until the target is judged to be moving for three consecutive times, then it is determined that the target is moving.

[0071] It can be understood that in the solution of the present application, the reference frame and the current frame are relative concepts, indicating that the objects matched in the embodiment of the present application are two adjacent frames of data, and any frame of data can be either a reference frame or a current frame.

[0072] Figure 4 The present application also provides a target motion detection device, comprising:

[0073] The acquisition unit 410 is configured to acquire an image data stream, where the image data stream includes a current frame and a reference frame.

[0074] The calculation unit 420 is configured to calculate the SAD cost and the Census cost of the current frame and the reference frame.

[0075] The determination unit 430 is configured to determine whether the SAD cost value and the Census cost value meet a determination condition to determine whether the target is moving. The determination condition includes at least one of the following conditions:

[0076] Condition 1: The SAD cost value is not less than the first threshold and not greater than the second threshold;

[0077] Condition 2: The SAD cost value is greater than the second threshold and the Census cost value is not less than the third threshold.

[0078] In some embodiments, the reference frame and the current frame are adjacent frame images. Preferably, the reference frame is the frame before the current frame.

[0079] In some embodiments, the threshold is determined by simulation fitting based on a real data set collected from user scenarios, and the user scenarios include static scenes, motion scenes, static scenes with changing ambient brightness, dark environments with low signal-to-noise ratio scenes, etc.

[0080] In some embodiments, the sensor's vertical blanking (VB) can also be configured to ensure that the interval between adjacent frames is not too small to prevent the target's motion amplitude in adjacent frames from being too small to be correctly detected. This also includes a target motion detection method to prevent false positives.

[0081] In some embodiments, a method for detecting target motion to prevent misjudgment is also provided, comprising the following steps: obtaining SAD cost values ​​and Census cost values ​​calculated n times in succession; if there are m times of SAD cost values ​​and Census cost values ​​that meet the judgment condition, then it is determined that the target is moving, .

[0082] In some embodiments, another target motion detection method to prevent misjudgment is also included, including the following steps: obtaining three consecutive detection results and if all three detection results show motion, then it is determined that the target is moving; otherwise, the next frame is used as a reference frame to continue the detection.

[0083] Figure 5 The image sensor with multiple working modes proposed in this application is shown. The image sensor is configured to work in a low-resolution mode, and when target motion is detected, it switches to a full-resolution mode to work.

[0084] In conjunction with the description of the aforementioned embodiments, specifically, the A / D conversion circuit is configured to integrate the electrical signals output by multiple pixels into a single electrical signal and perform analog-to-digital conversion to output image information, thereby merging multiple pixels into a single pixel. This allows the image sensor to operate in low-resolution mode. For example, if a pixel array unit includes 640*480 pixels and is configured in low-resolution mode to integrate every 20*20 pixels into a single pixel, the corresponding resolution of the pixel array unit is 32*24. The low-resolution image information generated by the A / D conversion circuit is input into the image signal processing circuit for target motion detection. When multiple consecutive frames of data detect no target motion, only one frame of data is stored to represent the scene information, and the remaining frames of data do not need to be stored. This reduces both the power consumption of the image sensor and the amount of data stored. When target motion is detected, the image sensor is configured to operate in full-resolution mode. Specifically, the A / D conversion circuit is configured to no longer integrate multiple pixels and only perform analog-to-digital conversion on each output electrical signal to obtain image information. The output image data is then processed by the image signal processing circuit and output as full-resolution image data.

[0085] Figure 6 The present application proposes a system 600 with automatic switching of working modes. For example, the system 600 can be a monitoring system or a code scanning system, wherein the system 600 includes an image sensor 500 and a host computer 610. The image sensor 500 has two working modes, namely low-resolution mode and full-resolution mode. Usually, the image sensor 500 is configured to operate in low-resolution mode. At this time, the image sensor power consumption is low, and the image signal processing circuit built into the image sensor 500 performs low-resolution image data of consecutive frames. Figure 2 The target motion detection function described in the embodiment. When no target motion is detected, only one frame of image is stored. Subsequent frames are invalid information and do not need to be stored and can be directly discarded. When target motion is successfully detected, the image sensor 500 automatically switches to full-resolution mode and outputs full-resolution image data to the host computer 610. After receiving the full-resolution image data, the host computer 610 performs a preset task, such as identifying the target.

[0086] It is understandable that when the target is identified as motionless, the host computer 610 in the system 600 is in standby mode and does not execute preset tasks. The image sensor 500 operates in low power mode, which can effectively reduce the entire system's requirements for power and storage space.

[0087] Figure 7 It is a schematic block diagram of a computer-readable storage medium 700 provided in an embodiment of the present application. Figure 7 The computer-readable storage medium 700 shown in FIG. 7 stores computer instructions 710. When the computer instructions 710 are executed by a processor, the method corresponding to the above embodiment can be implemented.

[0088] In some possible embodiments, computer-readable storage medium 700 may be any available medium that can be accessed by a computer, or a data storage device such as a server or data center that includes a collection of one or more available media. Available media may be magnetic media (e.g., floppy disks, hard disks, or magnetic tapes), optical media (e.g., DVDs), or semiconductor media. The semiconductor media may be a solid-state drive.

[0089] Those skilled in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0090] Those skilled in the art will clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.

[0091] In the several embodiments provided in this application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are merely schematic. For example, the division of the units is merely a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.

[0092] The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of these units may be selected to achieve the purpose of this embodiment according to actual needs.

[0093] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.

[0094] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, or the portion that contributes to the prior art, or the portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes a number of instructions for causing a computer device (which can be a personal computer, server, or network device, etc.) to execute all or part of the steps of the method described in each embodiment of this application.

[0095] The above description is merely a specific embodiment of the present application, but the scope of protection of the present application is not limited thereto. Any changes or substitutions that can be easily conceived by a person skilled in the art within the technical scope disclosed in this application should be included in the scope of protection of this application. Therefore, the scope of protection of this application should be based on the scope of protection of the claims.

Claims

1. A target motion detection method, characterized in that: include: Acquire an image data stream, wherein the image data stream includes a current frame and a reference frame; Calculating SAD cost values ​​and Census cost values ​​of the current frame and the reference frame; If the SAD cost value and the Census cost value meet the determination conditions, it is determined that the target is moving; The determination condition includes at least one of the following conditions: Condition 1: The SAD cost value is not less than the first threshold and not greater than the second threshold; Condition 2: The SAD cost value is greater than the second threshold and the Census cost value is not less than the third threshold; The method further comprises: Obtaining the SAD cost value and Census cost value calculated for n consecutive times; If there are m times of the SAD cost value and the Census cost value satisfying the judgment condition, it is determined that the target is moving, wherein, .

2. The method according to claim 1, characterized in that The reference frame and the current frame are adjacent frame images.

3. The method according to claim 1, characterized in that The SAD cost value and the Census cost value calculated three times in succession are obtained, and if the three consecutive SAD cost values ​​and the Census cost values ​​all meet the determination condition, it is determined that the target is moving.

4. The method according to claim 1, wherein The threshold is determined by performing simulation fitting based on a real data set collected according to user scenarios; the user scenarios include static scenes, motion scenes, static scenes with changing ambient brightness, and dark environments with low signal-to-noise ratio scenes.

5. A target motion detection device, characterized in that: include: an acquisition unit, configured to acquire an image data stream, wherein the image data stream includes a current frame and a reference frame; A calculation unit, configured to calculate a SAD cost value and a Census cost value of the current frame and the reference frame; a determination unit, configured to determine whether the SAD cost value and the Census cost value satisfy a determination condition, so as to determine whether the target is in motion; The determination condition includes at least one of the following conditions: Condition 1: The SAD cost value is not less than the first threshold and not greater than the second threshold; Condition 2: The SAD cost value is greater than the second threshold and the Census cost value is not less than the third threshold; Obtaining the SAD cost value and Census cost value calculated for n consecutive times; If there are m times of the SAD cost value and the Census cost value satisfying the judgment condition, it is determined that the target is moving, wherein, .

6. An image sensor with multiple operating modes, characterized in that: include: A pixel array unit, configured to output an electrical signal; a processing circuit unit, configured to process the electrical signals to output image data; wherein the A / D conversion circuit is configured to combine the electrical signals to output low-resolution image information; An image signal processing unit is configured to receive the low-resolution image information and execute the target motion detection method according to any one of claims 1 to 4.

7. The image sensor according to claim 6, wherein: When target motion is detected, the image sensor operates in a full-resolution mode and outputs full-resolution image data.

8. A system with automatic switching of working modes, characterized in that: include: comprising the image sensor and a host computer according to any one of claims 6 to 7; When the image sensor outputs a low-resolution image, the host computer is in a standby state; When the image sensor outputs a full-resolution image, the host computer is in a working state.

9. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a computer program, and the computer program is executed by a processor to implement the target detection method according to any one of claims 1 to 4.

Citation Information

Patent Citations

  • Matching cost calculation method and apparatus, and parallax value calculation method and equipment

    CN105335952A

  • Image processing device, image display device, scene change occurrence detection method, computer program, and recording medium

    JP2013225728A