Image processing method of image acquisition device, electronic device and storage medium
By receiving image data in low-frequency mode in the image acquisition device and switching to high-frequency mode for image processing when specific conditions are met, the problem of high power consumption of the device when processing is not required is solved and more efficient battery usage is achieved. .
Patent Information
- Application Number
- CN202410632121.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-21
- Publication Date
- 2024-08-30
- Estimated Expiration
- 2044-05-21
AI Technical Summary
When existing image acquisition equipment does not require image processing, the functional modules are always awake, resulting in high power consumption and energy loss.
By receiving image data in low-frequency mode, only when the image data contains relevant information of the target object or reaches a preset quantity, adjust the processor to high-frequency mode to start the function module for image processing, and enter low power consumption after the processing is completed. model.
The wake-up time of the functional module in the image acquisition device is reduced, the battery power consumption is reduced, and the battery usage efficiency of the device is improved.
Smart Images

Figure CN118214946B
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer technology, and in particular to an image processing method of an image acquisition device, an electronic device, and a storage medium. Background Art
[0002] With the rapid development of image acquisition technology, image acquisition devices that can acquire images in real time are increasingly widely used. When the existing image acquisition devices are in use, the whole device is in a startup state so that each functional module can perform corresponding image processing after receiving the corresponding image data. However, each functional module is always in an awake state, which is essentially a high power consumption mode when the corresponding image processing is not needed, resulting in serious power consumption of the image acquisition device.
[0003] In view of the existing technical defects, how to provide an effective image processing solution for image acquisition equipment is a technical problem that needs to be solved urgently by those skilled in the art. Summary of the invention
[0004] The present application at least provides an image processing method of an image acquisition device, an electronic device and a storage medium.
[0005] The present application provides an image processing method for an image acquisition device, comprising: a processor receives image data from an image sensor in a low-frequency mode, wherein at least some functional modules in the low-frequency mode are in an unactivated state; in response to the received image data satisfying a first image processing condition, adjusting the processor to a high-frequency mode to activate each functional module, wherein the first image processing condition includes that the image data contains relevant information of a target object and / or the amount of image data reaches a preset amount; and controlling each functional module to perform image processing on the image data.
[0006] The present application provides an image processing device for an image acquisition device, comprising: a receiving module, an adjustment module and a control module; the receiving module is used for a processor to receive image data from an image sensor in a low-frequency mode, wherein at least some functional modules in the low-frequency mode are in an unactivated state; the adjustment module is used for adjusting the processor to a high-frequency mode to activate each functional module in response to the received image data satisfying a first image processing condition, wherein the first image processing condition includes that the image data contains relevant information of a target object and / or the amount of image data reaches a preset amount; the control module is used for controlling each functional module to perform image processing on the image data.
[0007] The present application provides an electronic device, including a memory and a processor, wherein the processor is used to execute program instructions stored in the memory to implement the image processing method of the above-mentioned image acquisition device.
[0008] The present application provides a computer-readable storage medium on which program instructions are stored. When the program instructions are executed by a processor, the image processing method of the above-mentioned image acquisition device is implemented.
[0009] In the above scheme, in response to image data received by the processor in the low-frequency mode satisfying the first image processing condition, the processor is adjusted to the high-frequency mode to start each functional module, the first image processing condition includes that the image data contains relevant information of the target object and / or the amount of image data reaches a preset amount, and each functional module is controlled to perform image processing on the image data. Compared with the prior art in which each functional module is always in an awake state waiting for image data to be sent and performing image processing, the present application can reduce the awakening time of each functional module during the image processing process of the image acquisition device, thereby reducing the battery power consumption of the image acquisition device.
[0010] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present application. BRIEF DESCRIPTION OF THE DRAWINGS
[0011] The drawings herein are incorporated into the specification and constitute a part of the specification. These drawings illustrate embodiments consistent with the present application and are used together with the specification to illustrate the technical solution of the present application.
[0012] Figure 1 It is a flowchart of an embodiment of an image processing method of an image acquisition device of the present application;
[0013] Figure 2 This is another flowchart of an embodiment of an image processing method of an image acquisition device of the present application;
[0014] Figure 3 It is another flowchart of an embodiment of an image processing method of an image acquisition device of the present application;
[0015] Figure 4 It is a structural schematic diagram of an embodiment of an image processing device of an image acquisition device of the present application;
[0016] Figure 5 It is a structural schematic diagram of an embodiment of the electronic device of the present application;
[0017] Figure 6 It is a structural diagram of an embodiment of a computer-readable storage medium of the present application. DETAILED DESCRIPTION
[0018] The scheme of the embodiment of the present application is described in detail below in conjunction with the drawings of the specification.
[0019] In the following description, for the purpose of explanation rather than limitation, specific details such as specific system structures, interfaces, and technologies are provided to facilitate a thorough understanding of the present application.
[0020] The term "and / or" in this article is only a description of the association relationship of associated objects, indicating that there may be three relationships. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " in this article generally indicates that the objects associated before and after are in an "or" relationship. In addition, "many" in this article means two or more than two. In addition, the term "at least one" in this article means any combination of at least two of any one or more of a plurality of, for example, including at least one of A, B, and C, can mean including any one or more elements selected from the set consisting of A, B, and C.
[0021] The present application provides some image processing methods for image acquisition devices and image processing devices for image acquisition devices. The application scenarios of the image processing method of the image acquisition device include but are not limited to the startup process of a multi-camera device. The execution subject of the image processing method of the image acquisition device may be the image processing device of the image acquisition device or the main control of the image acquisition device. For example, the image processing device of the image acquisition device may be arranged in a terminal device or a server or other processing device, wherein the terminal device may be a device for image processing of the image acquisition device, a user equipment (User Equipment, UE), a mobile device, a user terminal, a terminal, a cellular phone, a cordless phone, a personal digital assistant (Personal Digital Assistant, PDA), a handheld device, a computing device, a vehicle-mounted device, etc. In some possible implementations, the image processing method of the image acquisition device may be implemented by a processor calling a computer-readable instruction stored in a memory.
[0022] See also Figure 1 , Figure 1 1 is a flow chart of an embodiment of an image processing method of an image acquisition device of the present application. Specifically, the image acquisition device includes an image sensor, a processor, and several functional modules. The image processing method of the image acquisition device may include the following steps:
[0023] Step S11: the processor receives image data from the image sensor in the low frequency mode.
[0024] Among them, at least some functional modules in the low-frequency mode are in an inactive state.
[0025] The processor may be a central processing unit (CPU) of the image acquisition device, wherein the processor may be a processor with computing and control capabilities and may operate at different frequencies.
[0026] The processor may have a low frequency mode. The processing capability of the processor in the low frequency mode is weak, and the power consumption of the processor is low. In some application scenarios, the processor in the low frequency mode may have the ability to receive image data and send image data. In some application scenarios, when the processor processes the low frequency mode, at least some functional modules in the image acquisition device process the unstarted state. Each functional module in the image acquisition device may be a related module capable of performing image processing on the image data. In some application scenarios, each functional module in the image acquisition device may be a hardware encoder. The hardware encoder may encode the received data into video files of different formats for storage in the memory. Specifically, the hardware encoder may be a video encoder (Video Encoder, ENC). The video encoder may be a video encoder of different formats. Exemplarily, the video encoder may be a first encoder (Video Encoder H264). The video encoder may be a second encoder (Video Encoder H265). The video encoder may be a third encoder (Video Encoder Motion Jpeg). Each functional module in the image acquisition device may also be an image signal processor (Image Signal Processor, ISP). The image sensor may be an image sensor (Sensor). The image sensor may send image data to the processor. The image sensor may have a motion detection mode. Specifically, the motion detection mode may be a motion detection function of the image sensor. In some application scenarios, the motion detection function may be an image sensor adapted to a motion detection function, which outputs a control signal when the image changes. In some application scenarios, the processor may refer to a main control chip connected to the image sensor.
[0027] Step S12: In response to the received image data satisfying the first image processing condition, adjusting the processor to a high frequency mode to activate each functional module.
[0028] The first image processing condition includes that the image data contains relevant information of the target object and / or the amount of image data reaches a preset amount.
[0029] The processor may have a high-frequency mode. The processor in the high-frequency mode has strong processing capability and high power consumption. In some application scenarios, the processor in the high-frequency mode may have other processing capabilities in addition to the ability to receive and send image data. Other processing capabilities may be to send corresponding data to each functional module to start each functional module in order to complete image data encoding. In some application scenarios, when the processor is in the high-frequency mode, all functional module processing in the image acquisition device is in the start-up state. It can be understood that after determining that the received image data meets the first image processing condition, the processor in the low-frequency mode can be switched to adjust the processor in the low-frequency mode to a processor that processes the high-frequency mode. After the processor switches from the low-frequency mode to the high-frequency mode, the processor in the high-frequency mode can start each functional module. After the processor is in the high-frequency mode, the processor in the high-frequency mode can start each functional module. In some application scenarios, the main control chip enters the high-frequency mode and synchronously starts the target software operating system to realize the personalized setting requirements related to image processing. Specifically, the process of synchronously starting the target software operating system may be to restore the operating system from the power management mode. The power management mode may be the target power mode STR (Suspend to RAM or Sleep, STR). Among them, the target power mode STR is the permission management of the operating system. According to different demand stages, the target power mode STR manages the permissions of the operating system. In some application scenarios, the first demand stage can be that all operations of the operating system are stopped, but the memory still maintains power supply and maintains its content. In the first demand stage, the operating system saves energy when it is inactive, saving battery power consumption of the image acquisition device. In other application scenarios, the second demand stage can be an operation that allows the system to quickly return to full-power operation when the required conditions are met. The requirement condition can be the step in which the received image data meets the first image processing condition, or it can be the step in which the processor is adjusted to the high-frequency mode. Dividing the first demand stage and the second demand stage can improve the efficiency of battery power use.
[0030] In some application scenarios, it is determined whether the image data contains relevant information of the target object. The first image processing condition may be that the image data contains relevant information of the target object. The target object may be set according to demand. Specifically, the target object may be a predetermined type of organism, a predetermined type of object, or a predetermined type of vehicle. In some application scenarios, it is determined whether the number of images corresponding to the image data reaches a preset number. The preset number may be that the number of images corresponding to the image data is 10. The first image processing condition may be that the number of images corresponding to the image data reaches a preset number. The image corresponding to the image data may be an image obtained by an image acquisition device acquiring the target area. In other application scenarios, it is simultaneously determined whether the image data contains relevant information of the target object and whether the number of images corresponding to the image data reaches a preset number. The first image processing condition may be that the image data contains relevant information of the target object and the number of images corresponding to the target object in the image data reaches a preset number.
[0031] Step S13: Control each functional module to perform image processing on the image data.
[0032] After starting each functional module, control each functional module to perform image processing on the image data. In some application scenarios, the image processing method may be to send the image data to each functional module at one time to obtain video data. Exemplarily, the image data may be in the form of ImageRaw data. The image processing method may be to send the image data to a hardware encoder for processing at one time, and wait for encoding to be completed to obtain video data. Specifically, the image data is sent to an image signal processor and a video encoder for processing at one time, and wait for encoding to be completed to obtain video data. After obtaining the video data, the above video data is used as the first target storage data, and the first target storage data is stored. After the first target storage data is stored, the processor is controlled to power off. In some application scenarios, controlling the processor to power off may be controlling the main control chip to power off.
[0033] In some embodiments, the image acquisition device further includes a memory. In some application scenarios, the video data may be stored by writing the video data to a memory in a high power consumption mode. In response to the completion of the video data storage, the memory is adjusted to a low power consumption mode, and the image sensor is controlled to enter a sleep state. After the memory is in the low power consumption mode, the processor is controlled to power off. Controlling the image sensor to enter a sleep state may be that the processor notifies the image sensor to enter a sleep state.
[0034] In the above scheme, in response to image data received by the processor in the low-frequency mode satisfying the first image processing condition, the processor is adjusted to the high-frequency mode to start each functional module, the first image processing condition includes that the image data contains relevant information of the target object and / or the amount of image data reaches a preset amount, and each functional module is controlled to perform image processing on the image data. Compared with the prior art in which each functional module is always in an awake state waiting for image data to be sent and performing image processing, the present application can reduce the awakening time of each functional module during the image processing process of the image acquisition device, thereby reducing the battery power consumption of the image acquisition device.
[0035] In some embodiments, the image acquisition device further includes a memory, and the image processing method of the image acquisition device may further include the following steps: first, in response to the received image data satisfying the second image processing condition, the image data is written to the memory in the high power consumption mode. The second image processing condition includes that the image data does not contain relevant information of the target object and the amount of image data does not reach a preset amount. Subsequently, in response to the image data being stored, the memory is adjusted to a low power consumption mode, and the image sensor is controlled to enter a sleep state.
[0036] The memory in the image acquisition device may be a random access memory. Exemplarily, the memory may be a random access memory DDR (Double Data Rate, DDR). Specifically, the random access memory DDR may be a DDR SDRAM double data rate synchronous dynamic random access memory. The random access memory DDR may be a memory technology, mainly used for random access memory of a computer. The memory has a low power consumption mode and a high power consumption mode. In some application scenarios, the memory in the high power consumption mode may be a memory that will be executed immediately after receiving a read and write instruction, and the speed is relatively fast. Among them, the memory in the high power consumption mode has high power consumption. The memory in the high power consumption mode may be a memory in a working state or a normal mode, which can read and write relevant data that needs to be stored. In other application scenarios, the memory in the low power consumption mode may be a memory that automatically refreshes the relevant data that needs to be stored. In this mode, the speed is slow and it can work at a low voltage. The memory in the low power consumption mode has low power consumption. The memory in the low power consumption mode may be a memory in a self-refresh mode, which cannot read and write relevant data that needs to be stored. It can be understood that the memory in the low power consumption mode has the function of retaining historical storage data, but does not have the function of reading and writing relevant data that needs to be stored. The retained historical storage data may be video data stored in the memory in the high power consumption mode before the mode is adjusted or image data stored in the memory in the high power consumption mode before the mode is adjusted.
[0037] The second image processing condition includes that the image data does not contain relevant information of the target object and the amount of image data does not reach a preset amount. In response to the received image data satisfying the second image processing condition, the image data is written to a memory in a high power consumption mode. At this time, the image data may be original image data that is not processed by an image signal processor and a video encoder. In response to the received image data satisfying the second image processing condition, the image data is used as second target storage data, and the second target storage data is written to a memory in a high power consumption mode. After the second target storage data is stored, the memory is adjusted to a low power consumption mode, and the image sensor is controlled to enter a sleep state. After the memory is in a low power consumption mode, the processor is controlled to power off. Controlling the image sensor to enter a sleep state may be that the processor notifies the image sensor to enter a sleep state.
[0038] It can be considered that when the received image data meets the second image processing condition, the image data is written to the memory in high power consumption mode, and the memory is adjusted to low power consumption mode, and the image sensor is controlled to sleep and the processor is powered off. This allows the image data to be cached when the device is in motion and there are non-target objects, and the power consumption of each module in the image acquisition device can be saved, thereby improving the battery utilization efficiency of the image acquisition device.
[0039] In some embodiments, before the step of adjusting the processor to the high-frequency mode in response to the received image data satisfying the first image processing condition, the image processing method of the image acquisition device may further include the following steps: First, the image data is cropped to obtain the data to be processed. Subsequently, the data to be processed is subjected to object detection processing and / or quantity statistics processing to obtain a data processing result. The image processing result includes an object detection result and / or a quantity statistics result, wherein the object detection result includes relevant information of the target object contained in the data to be processed or relevant information of the target object not contained in the data to be processed, and the quantity statistics result includes the total number corresponding to each image in the data to be processed. Next, based on the data processing result, it is determined whether the received image data satisfies the first image processing condition.
[0040] The image acquisition device further includes a video cropping module, which may be a video cropping module VIF (Video Input Interface, VIF).
[0041] In some application scenarios, the video cropping module may transmit the received image data to the main control. Object detection processing and / or quantitative statistical processing are performed on the image data to obtain a data processing result. In some application scenarios, object detection processing is performed on the image data, and the data processing result obtained may be an object detection result. In some application scenarios, quantitative statistical processing is performed on the image data, and the data processing result obtained may be a quantitative statistical result. In other application scenarios, the above-mentioned steps of performing object detection processing on the image data and the above-mentioned steps of performing quantitative statistical processing on the image data are performed simultaneously, and the data processing results obtained may be an object detection result and a quantitative statistical result.
[0042] In other application scenarios, the video cropping module can crop the image data to obtain the data to be processed. The video cropping module can transmit the data to be processed to the main control. Object detection processing and / or quantity statistics processing are performed on the data to be processed to obtain a data processing result. In some application scenarios, object detection processing is performed on the data to be processed, and the data processing result obtained may be an object detection result. In some application scenarios, quantity statistics processing is performed on the data to be processed, and the data processing result obtained may be a quantity statistics result. In other application scenarios, the above-mentioned steps of performing object detection processing on the data to be processed and the above-mentioned steps of performing quantity statistics processing on the data to be processed are performed simultaneously, and the data processing results obtained may be an object detection result and a quantity statistics result. The relationship between the data to be processed and the image data may be that the data to be processed is the cropped image data, wherein the number of images in the data to be processed is the same as the number of images in the image data.
[0043] In some application scenarios, the step of performing quantitative statistical processing on the data to be processed or the step of performing quantitative statistical processing on the image data may be to count the frame rate in the data to be processed or the image data. The frame rate counting method may be to add the historical statistical number to the number of images in the image data to obtain the quantitative statistical result. Alternatively, the historical statistical number is added to the number of images in the data to be processed to obtain the quantitative statistical result.
[0044] Specifically, the frame rate counting process can refer to formula (1):
[0045] RawCount1=RawCount0+N formula (1);
[0046] Wherein, RawCount0 may represent the above-mentioned historical statistical quantity. The historical statistical quantity may be the number of images of the historical image data retained in the memory at the historical moment. N may represent the number of images in the data to be processed or the image data at the current moment. Exemplarily, N may be 1. RawCount1 may represent the result of the quantity statistics.
[0047] The image processing result includes an object detection result and / or a quantity counting result, wherein the object detection result includes relevant information that the data to be processed contains the target object or relevant information that the data to be processed does not contain the target object, and the quantity counting result includes the total number of images corresponding to the data to be processed. Based on the data processing result, it is determined whether the received image data meets the first image processing condition.
[0048] In some application scenarios, the above-mentioned step of performing object detection processing on the data to be processed is first performed, and the data processing result may be the object detection result. When the object detection result is that the data to be processed does not contain relevant information of the target object, the above-mentioned step of performing quantitative statistical processing on the image data is then performed. The quantitative statistical result is the total number of images corresponding to each image in the data to be processed. The total number of images corresponding to the data to be processed corresponding to the quantitative statistical result does not reach a preset number. Determine the image processing result to determine that the received image data meets the second image processing condition. The data to be processed is used as the second target storage data, and the second target storage data is written to the memory in the high power consumption mode. After the second target storage data is stored, adjust the memory to the low power consumption mode, and control the image sensor to enter the sleep state.
[0049] It can be understood that the above-mentioned step of performing object detection processing on the data to be processed and the above-mentioned step of performing quantitative statistical processing on the data to be processed can be performed in a serial manner or in a parallel manner. The above-mentioned step of performing object detection processing on the image data can refer to the above-mentioned step of performing object detection processing on the data to be processed, which will not be repeated here. The above-mentioned step of performing quantitative statistical processing on the image data can refer to the above-mentioned step of performing quantitative statistical processing on the data to be processed, which will not be repeated here.
[0050] In some application scenarios, in a serial execution mode, the above-mentioned step of performing object detection processing on the data to be processed is first performed, and the data processing result may be an object detection result. When the object detection result is that the data to be processed does not contain relevant information of the target object, the above-mentioned step of performing quantitative statistical processing on the data to be processed is then performed. The total number of images corresponding to the data to be processed corresponding to the quantitative statistical result reaches a preset number. The image processing result is determined to determine that the received data to be processed meets the first image processing condition.
[0051] In some application scenarios, in a serial execution mode, the above-mentioned step of performing object detection processing on the data to be processed is first performed, and the data processing result may be an object detection result. When the object detection result is that the data to be processed does not contain relevant information of the target object, the above-mentioned step of performing quantitative statistical processing on the data to be processed is then performed. The total number of images corresponding to the data to be processed corresponding to the quantitative statistical result does not reach a preset number. The image processing result is determined to determine that the received data to be processed meets the second image processing condition.
[0052] In some application scenarios, in a serial execution mode, the above-mentioned step of performing object detection processing on the data to be processed is first performed, and the data processing result may be an object detection result. When the object detection result is that the data to be processed contains relevant information of the target object, the above-mentioned step of performing quantitative statistical processing on the data to be processed is then performed. The total number of images corresponding to the data to be processed corresponding to the quantitative statistical result reaches a preset number. The image processing result is determined to determine that the received data to be processed meets the first image processing condition.
[0053] In some application scenarios, in a serial execution mode, the above step of performing object detection processing on the data to be processed is first performed, and the data processing result may be the object detection result. In the case where the object detection result is that the data to be processed contains relevant information of the target object, it is not necessary to perform the above step of performing quantitative statistical processing on the data to be processed. Determine the image processing result Determine that the received data to be processed meets the first image processing condition.
[0054] In other application scenarios, in a parallel execution mode, the above-mentioned step of performing object detection processing on the data to be processed and the above-mentioned step of performing quantity statistics processing on the data to be processed are performed in parallel. The obtained data processing results include object detection results and quantity statistics results. In response to the case where the object detection result is that the data to be processed does not contain relevant information of the target object, and the total number of images corresponding to the data to be processed corresponding to the quantity statistics result does not reach a preset number, it is determined that the data to be processed meets the second image processing condition. In response to the case where the object detection result is that the data to be processed does not contain relevant information of the target object, and the total number of images corresponding to the data to be processed corresponding to the quantity statistics result reaches a preset number, it is determined that the data to be processed meets the first image processing condition. In response to the case where the object detection result is that the data to be processed contains relevant information of the target object, and the total number of images corresponding to the data to be processed corresponding to the quantity statistics result reaches or does not reach the preset number, it is determined that the data to be processed meets the first image processing condition.
[0055] In some application scenarios, in response to the received data to be processed satisfying the first image processing condition, the processor is adjusted to the high frequency mode to start each functional module. Each functional module is controlled to perform image processing on the data to be processed to obtain video data. After obtaining the video data, the video data is used as the first target storage data, and the first target storage data is stored. After the first target storage data is stored, the memory is adjusted to the low power consumption mode, and the image sensor is controlled to enter the sleep state. After the first target storage data is stored, the processor is controlled to power off.
[0056] In some application scenarios, in response to the received data to be processed satisfying the second image processing condition, the data to be processed is used as the second target storage data, and the second target storage data is written to the memory in the high power consumption mode. After the second target storage data is stored, the memory is adjusted to the low power consumption mode, and the image sensor is controlled to enter the sleep state. After the memory is in the low power consumption mode, the processor is controlled to power off.
[0057] It can be considered that when the received image data meets the second image processing condition, the image data is written to the memory in high power consumption mode, and the memory is adjusted to low power consumption mode, and the image sensor is controlled to sleep and the processor is powered off. This allows the image data to be cached when the device is in motion and there are non-target objects, and the power consumption of each module in the image acquisition device can be saved, thereby improving the battery utilization efficiency of the image acquisition device.
[0058] It can be considered that, when the received image data satisfies the first image processing condition, the video data is written to the memory in the high power consumption mode, and the memory is adjusted to the low power consumption mode, and the image sensor is controlled to sleep and the processor is powered off. When the device is in motion and there are data to be processed that belong to the target object and / or the total number of images corresponding to the number of statistical results reaches a preset number, the video data can be stored and the power consumption of each module in the image acquisition device can be saved, thereby improving the battery utilization efficiency of the image acquisition device.
[0059] In some embodiments, the working state of the image sensor includes a motion detection mode and an image output mode. Before the above step S11, the image processing method of the image acquisition device may further include the following steps: first, the image sensor in the motion detection mode is controlled to detect the image data to obtain a motion detection result. The motion detection result includes a first motion detection result about the relevant information of the moving object contained in the image data. Then, in response to the motion detection result being the first motion detection result, the image sensor is adjusted to the image output mode so that the processor receives the image data from the image sensor in the low-frequency mode.
[0060] The image sensor has a working state and a dormant state. Among them, the image sensor in the working state can have a motion detection mode and an image output mode. Specifically, the motion detection mode can be a motion detection function of the image sensor. In some application scenarios, the motion detection function can be an image sensor adapted to a motion detection function, and a control signal is output when the picture changes. Exemplarily, the motion detection mode can be a motion detection function (MotionDetect, MD). Specifically, the image output mode can be that the image sensor can send the collected image data to the processor.
[0061] The moving object may be all objects to be confirmed including the target object. The object to be confirmed may be a predetermined type of organism, or a predetermined type of object, or a predetermined type of vehicle. Specifically, the object to be confirmed may be an object type that can cause the picture corresponding to the target area to change in the collected image data. The image sensor in the motion detection mode is controlled to detect the image data to obtain a motion detection result. The motion detection result is a first motion detection result about the relevant information of the moving object contained in the image data. When the motion detection result is the first motion detection result, the image sensor is adjusted to the image output mode so that the processor receives the image data from the image sensor in the low-frequency mode.
[0062] In some embodiments, the motion detection result includes a second motion detection result about the image data not containing relevant information of the moving object, and the image processing method of the image acquisition device may further include the following steps: in response to the motion detection result being the second motion detection result, controlling the image sensor to enter a sleep state.
[0063] The image sensor in the motion detection mode is controlled to detect the image data to obtain a motion detection result. The motion detection result is a first motion detection result about the relevant information of the moving object contained in the image data. When the motion detection result is a second motion detection result, the image sensor is controlled to enter a dormant state.
[0064] In some embodiments, the first motion detection result includes a number of current motion detection events, and the number of current motion detection events indicates that the objects to be confirmed are in motion. The above step of adjusting the image sensor to the image output mode in response to the motion detection result being the first motion detection result may include the following steps: in response to the first motion detection result satisfying a first preset condition, adjusting the image sensor to the image output mode, the first preset condition including that there is no historical motion detection event before the current timestamp corresponding to the current motion detection event in the first motion detection result. The historical motion detection event indicates that the object to be confirmed is in motion before the current timestamp. Or, in response to the first motion detection result satisfying a second preset condition, adjusting the image sensor to the image output mode, the second preset condition including that there is a historical motion detection event before the current timestamp corresponding to the current motion detection event in the first motion detection result, and the time interval between the current timestamps corresponding to at least one current motion detection event in the first motion detection result is greater than or equal to the second preset time.
[0065] The first motion detection result includes several current motion detection events. Several current motion detection events can be one current motion detection event or multiple current motion detection events. Several current motion detection events represent that several objects to be confirmed are in motion. The current motion detection event represents that one object to be confirmed is in motion. The objects to be confirmed between multiple current motion detection events can be different objects or the same object.
[0066] Exemplarily, after the image sensor is powered on, when the image sensor collects image data for the first time, it is determined that there is no historical motion detection event before the first image data is collected. Alternatively, when the image sensor collects image data multiple times, other image data before the last image data do not detect historical motion detection events, the last image data detects a motion detection event, and there is no historical motion detection event before the current motion detection event corresponding to the last image data. The absence of historical motion detection events may mean that there is no historical image data or no historical data to be processed in the memory.
[0067] The historical motion detection event indicates that the object to be confirmed was in motion before the current timestamp. Each current motion detection event or historical motion detection event corresponds to a timestamp. That is, the current timestamp may be the start time of the object to be confirmed in motion in the current motion detection event. The current timestamp may be the end time of the object to be confirmed in motion in the current motion detection event. The current timestamp may be the current time period of the object to be confirmed in motion in the current motion detection event. The current time period includes the start time and the end time of the object to be confirmed in motion. The historical timestamp may be the start time of the object to be confirmed in motion in the historical motion detection event. The historical timestamp may be the end time of the object to be confirmed in motion in the historical motion detection event. The historical timestamp may be the historical time period of the object to be confirmed in motion in the historical motion detection event. The historical time period includes the start time and the end time of the object to be confirmed in motion.
[0068] In some application scenarios, the first preset condition includes that there is no historical motion detection event before the current timestamp corresponding to the current motion detection event in the first motion detection result. It is understandable that when there is no historical motion detection event before the current timestamp of several current motion detection events corresponding to the image data collected by the image sensor, the image sensor is directly adjusted to the image output mode.
[0069] In other application scenarios, the second preset condition includes the case where there is a historical motion detection event before the current timestamp corresponding to the current motion detection event in the first motion detection result, and the interval between the current timestamps corresponding to at least one current motion detection event in the first motion detection result is greater than or equal to the second preset time. It can be understood that, in the case where there is a historical motion detection event before the current timestamps of several current motion detection events corresponding to the image data collected by the image sensor, the relationship between the current timestamps of several current motion detection events and the historical timestamps of the historical motion detection events is determined. In response to the relationship between the current timestamps of several current motion detection events and the historical timestamps of the historical motion detection events satisfying the second preset time, the image sensor is adjusted to the image output mode. In some application scenarios, in response to the interval between the current timestamp of at least one current motion detection event and the historical timestamp of the historical motion detection event is greater than or equal to the second preset time. In other application scenarios, in response to the interval between the current timestamp of the first current motion detection event and the historical timestamp of the historical motion detection event is greater than or equal to the second preset time. The current timestamp of the first current motion detection event can be the time of the first motion detection event among the current timestamps corresponding to the several current motion detection events. The historical motion detection event may be a motion detection event that is adjacent to the first current motion detection event among the plurality of historical motion detection events and is before the current timestamp corresponding to the first current motion detection event.
[0070] It can be understood that the first preset time and the second preset time can be the same time or different times.
[0071] It can be considered that when there is no current motion detection event in the image processing data, the image sensor directly enters a sleep state and waits for a timed wake-up to re-detect the motion detection event. This can reduce the wake-up time of the image sensor so that the image sensor is not always in an awake state, which can save power consumption of each module in the image acquisition device, thereby improving the battery utilization efficiency of the image acquisition device.
[0072] In some embodiments, the image processing method of the image acquisition device may further include the following steps: in response to the first motion detection result satisfying a third preset condition, controlling the image sensor to enter a sleep state, the third preset condition including that there is a historical motion detection event before the current timestamp corresponding to the current motion detection event in the first motion detection result, and the time interval between the current timestamp corresponding to all current motion detection events in the first motion detection result and the historical timestamps of the historical motion detection events is less than the third preset time.
[0073] In some application scenarios, the third preset condition includes the case where there is a historical motion detection event before the current timestamp corresponding to the current motion detection event in the first motion detection result, and the interval between the current timestamps corresponding to all current motion detection events in the first motion detection result and the historical timestamps of the historical motion detection events is less than the third preset time. It can be understood that, in the case where there is a historical motion detection event before the current timestamps of several current motion detection events corresponding to the image data collected by the image sensor, the relationship between the current timestamps of several current motion detection events and the historical timestamps of the historical motion detection events is determined. In response to the relationship between the current timestamps of several current motion detection events and the historical timestamps of the historical motion detection events satisfying the third preset time, the image sensor is controlled to enter a dormant state. In some application scenarios, in response to the interval between the current timestamp of each current motion detection event and the historical timestamp of the historical motion detection event is less than the third preset time. In other application scenarios, in response to the interval between the current timestamp of the last current motion detection event and the historical timestamp of the historical motion detection event is less than the third preset time. The current timestamp of the last current motion detection event may be the time of the last motion detection event among the current timestamps corresponding to the current motion detection events. The historical motion detection event may be a motion detection event that is adjacent to the first current motion detection event among the historical motion detection events and is before the current timestamp corresponding to the first current motion detection event.
[0074] It can be understood that the third preset time and the first preset time and the second preset time can be the same time or different times.
[0075] It can be considered that, when there is a current motion detection event in the image processing data, the relationship between several current motion detection events and historical motion detection events or the relationship between several current motion detection events is judged, so as to determine whether the image sensor is in an image output mode or a sleep state, so that the image sensor is not always in an awake state or in a motion detection mode, which can save the power consumption of each image sensor in the image acquisition device, thereby improving the battery utilization efficiency of the image acquisition device.
[0076] In some embodiments, before the above step S11, the image processing method of the image acquisition device may further include the following steps: first, in response to the image sensor being powered on, a wake-up condition is set for the image sensor. Subsequently, the image sensor is controlled to switch states at a predetermined frequency. The wake-up condition includes adjusting the image sensor in a dormant state to a working state after a target wake-up time has passed, wherein the image sensor in the working state can be used to collect image data.
[0077] In response to the image sensor being powered on, a wake-up condition is set for the image sensor. Subsequently, the image sensor is controlled to switch states at a predetermined frequency. Setting the wake-up condition for the image sensor may be that the image sensor switches from a dormant state to a working state within a target wake-up time. Specifically, after the image sensor switches from a dormant state to a working state within the target wake-up time, the image sensor enters a motion detection mode. The wake-up condition includes adjusting the image sensor in a dormant state to a working state after a first preset time, wherein the image sensor in the working state can be used to collect image data. The target wake-up time can be dynamically set according to image processing requirements.
[0078] It can be considered that after setting the wake-up condition, the image sensor can be woken up regularly so that the image sensor is not always in a dormant state, which can improve the efficiency of the image sensor in collecting image data and motion detection, thereby improving the efficiency of image processing of the image acquisition device.
[0079] In some embodiments, before the processor receives image data from the image sensor in the low-frequency mode, the image processing method of the image acquisition device may further include the following steps: adjusting the exposure parameters of the image acquisition device, and setting a wake-up condition to the adjusted image sensor so that the adjusted image sensor switches states at a predetermined frequency.
[0080] Exposure parameter adjustment can be exposure convergence FastAe (Fast Auto Exposure, FastAe) is a technology used in camera systems to quickly adjust exposure settings. The adjusted image sensor can find the best exposure setting as quickly as possible so that it can quickly adapt when the ambient light conditions change. Ensure that the exposure of the image captured by the image sensor can be stable in a short time.
[0081] It can be considered that the adjusted image sensor switches states at a predetermined frequency, and the collected image data is output stable data.
[0082] In the above scheme, in response to image data received by the processor in the low-frequency mode satisfying the first image processing condition, the processor is adjusted to the high-frequency mode to start each functional module, the first image processing condition includes that the image data contains relevant information of the target object and / or the amount of image data reaches a preset amount, and each functional module is controlled to perform image processing on the image data. Compared with the prior art in which each functional module is always in an awake state waiting for image data to be sent and performing image processing, the present application can reduce the awakening time of each functional module during the image processing process of the image acquisition device, thereby reducing the battery power consumption of the image acquisition device.
[0083] See also Figure 2 , Figure 2 It is another flowchart diagram of an embodiment of the image processing method of the image acquisition device of the present application.
[0084] Step S201, step S202, step S203 and step S204 are performed in sequence. Step S201: The image sensor is powered on. Step S202: The exposure parameters of the image acquisition device are adjusted. Step S203: The wake-up condition is set to the image sensor. Step S204: The image sensor enters the motion detection mode, detects the acquired image data, and obtains the motion detection result. It is determined whether the motion detection result is the first motion detection result or the second motion detection result. In the case where the motion detection result is the first motion detection result, step S205 is performed. Step S205: In response to the first motion detection result satisfying the first preset condition, the image sensor is adjusted to the image output mode. In the case where the motion detection result is the second motion detection result, steps S206, step S207 and step S208 are performed in sequence. Step S206: In response to the motion detection result being the second motion detection result, the image sensor is controlled to enter the sleep state. Step S207: It is determined whether the image sensor satisfies the wake-up condition. Step S208: The image sensor remains in sleep mode.
[0085] It can be considered that controlling the image sensor to enter the sleep state and the working state under different conditions can reduce the number of false awakenings of the image sensor, thereby improving the battery usage efficiency of the image acquisition device.
[0086] See also Figure 3 , Figure 3 FIG. 1 is another flow chart of an embodiment of an image processing method of an image acquisition device of the present application. Figure 3 As shown, the image processing process of the image acquisition device may include the following steps:
[0087] Step S301 and step S302 are performed in sequence. Step S301: The processor receives image data from the image sensor in the image output mode in the low-frequency mode. Step S302: The video cropping module crops the image data to obtain the data to be processed. It is determined whether the data to be processed meets the first image condition, and it is determined whether the data to be processed meets the second image processing condition. In the case where the data to be processed meets the first image processing condition, steps S303, step S304 and step S305 are performed in sequence. Step S303: In response to the received data to be processed meeting the first image processing condition, the processor is adjusted to the high-frequency mode. Step S304: Each functional module is controlled to perform image processing on the data to be processed to obtain video data. Step S305: In response to the completion of the storage of the video data, the memory is adjusted to the low-power consumption mode, and the image sensor is controlled to enter the sleep state. In the case where the data to be processed meets the second image processing condition, steps S306 and step S307 are performed in sequence. Step S306: In response to the received image data meeting the second image processing condition, the data to be processed is written to the memory in the high-power consumption mode. Step S307: in response to the completion of storage of the data to be processed, adjusting the memory to a low power consumption mode, and controlling the image sensor to enter a sleep state.
[0088] It can be considered that, under different image processing conditions, controlling the activation of each functional module in the image acquisition device can reduce the activation of each functional module by non-target objects, thereby improving the use efficiency of the battery of the image acquisition device. In addition, under different usage requirements, switching different power consumption modes of each module in the image acquisition device can improve the use efficiency of the battery of the image acquisition device.
[0089] In the above scheme, in response to image data received by the processor in the low-frequency mode satisfying the first image processing condition, the processor is adjusted to the high-frequency mode to start each functional module, the first image processing condition includes that the image data contains relevant information of the target object and / or the amount of image data reaches a preset amount, and each functional module is controlled to perform image processing on the image data. Compared with the prior art in which each functional module is always in an awake state waiting for image data to be sent and performing image processing, the present application can reduce the awakening time of each functional module during the image processing process of the image acquisition device, thereby reducing the battery power consumption of the image acquisition device.
[0090] See also Figure 4 , Figure 4 It is a structural schematic diagram of an embodiment of an image processing device of an image acquisition device of the present application. The image processing device 40 of the image acquisition device includes a receiving module 41, an adjustment module 42 and a control module 43. The receiving module 41 is used for the processor to receive image data from the image sensor in a low-frequency mode, wherein at least some functional modules in the low-frequency mode are in an unactivated state; the adjustment module 42 is used to adjust the processor to a high-frequency mode to activate each functional module in response to the received image data satisfying a first image processing condition, wherein the first image processing condition includes that the image data contains relevant information of the target object and / or the number of image data reaches a preset number; the control module 43 is used to control each functional module to perform image processing on the image data.
[0091] In the above scheme, in response to image data received by the processor in the low-frequency mode satisfying the first image processing condition, the processor is adjusted to the high-frequency mode to start each functional module, the first image processing condition includes that the image data contains relevant information of the target object and / or the amount of image data reaches a preset amount, and each functional module is controlled to perform image processing on the image data. Compared with the prior art in which each functional module is always in an awake state waiting for image data to be sent and performing image processing, the present application can reduce the awakening time of each functional module during the image processing process of the image acquisition device, thereby reducing the battery power consumption of the image acquisition device.
[0092] For the functions performed by each module, please refer to the image processing method of the image acquisition device, which will not be repeated here.
[0093] See also Figure 5 , Figure 5 1 is a schematic diagram of the structure of an embodiment of an electronic device of the present application. The electronic device 50 includes a memory 51 and a processor 52, and the processor 52 is used to execute program instructions stored in the memory 51 to implement the steps in the above-mentioned image processing method embodiment of the image acquisition device. In a specific implementation scenario, the electronic device 50 may include but is not limited to: a multi-camera device, a microcomputer, and a server. In addition, the electronic device 50 may also include a mobile device such as a laptop computer and a tablet computer, which is not limited here.
[0094] Specifically, the processor 52 is used to control itself and the memory 51 to implement the steps in the above-mentioned image processing method embodiment of the image acquisition device. The processor 52 can also be called a CPU (Central Processing Unit). The processor 52 may be an integrated circuit chip with signal processing capabilities. The processor 52 can also be a general-purpose processor, a digital signal processor (Digital Signal Processor, DSP), an application-specific integrated circuit (Application Specific Integrated Circuit, ASIC), a field-programmable gate array (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. The general-purpose processor can be a microprocessor or the processor can also be any conventional processor, etc. In addition, the processor 52 can be implemented by an integrated circuit chip.
[0095] In the above scheme, in response to image data received by the processor in the low-frequency mode satisfying the first image processing condition, the processor is adjusted to the high-frequency mode to start each functional module, the first image processing condition includes that the image data contains relevant information of the target object and / or the amount of image data reaches a preset amount, and each functional module is controlled to perform image processing on the image data. Compared with the prior art in which each functional module is always in an awake state waiting for image data to be sent and performing image processing, the present application can reduce the awakening time of each functional module during the image processing process of the image acquisition device, thereby reducing the battery power consumption of the image acquisition device.
[0096] See also Figure 6 , Figure 6 The computer-readable storage medium 60 stores program instructions 601, which, when executed by a processor, implement the steps in any of the above-mentioned image processing method embodiments of the image acquisition device.
[0097] In the above scheme, in response to image data received by the processor in the low-frequency mode satisfying the first image processing condition, the processor is adjusted to the high-frequency mode to start each functional module, the first image processing condition includes that the image data contains relevant information of the target object and / or the amount of image data reaches a preset amount, and each functional module is controlled to perform image processing on the image data. Compared with the prior art in which each functional module is always in an awake state waiting for image data to be sent and performing image processing, the present application can reduce the awakening time of each functional module during the image processing process of the image acquisition device, thereby reducing the battery power consumption of the image acquisition device.
[0098] In some embodiments, the functions or modules included in the device provided by the embodiments of the present disclosure can be used to execute the method described in the above method embodiments. The specific implementation can refer to the description of the above method embodiments, and for the sake of brevity, it will not be repeated here.
[0099] The above description of various embodiments tends to emphasize the differences between the various embodiments. The same or similar aspects can be referenced to each other, and for the sake of brevity, they will not be repeated herein.
[0100] In the several embodiments provided in the present application, it should be understood that the disclosed methods and devices can be implemented in other ways. For example, the device implementation described above is only schematic. For example, the division of modules or units is only a logical function division. There may be other division methods in actual implementation, such as 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, and the indirect coupling or communication connection of devices or units can be electrical, mechanical or other forms.
[0101] 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. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0102] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several instructions to enable a computer device (which can be a personal computer, server, or network device, etc.) or a processor to execute all or part of the steps of each implementation method of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk and other media that can store program code.
Claims
1. An image processing method for an image acquisition device, characterized in that: The image acquisition device includes an image sensor, a processor and several functional modules, and the method includes: The processor receives image data from the image sensor in a low-frequency mode, wherein at least some functional modules in the low-frequency mode are in an inactive state; In response to the received image data satisfying a first image processing condition, adjusting the processor to a high frequency mode to start each of the functional modules, the first image processing condition comprising that the image data contains relevant information of a target object and / or the amount of the image data reaches a preset amount; Controlling each of the functional modules to perform image processing on the image data; The image acquisition device also includes a memory, and the method also includes: in response to the received image data satisfying a second image processing condition, writing the image data to the memory in a high power consumption mode, the second image processing condition including that the image data does not contain relevant information of the target object and the amount of the image data does not reach the preset amount; in response to the image data being stored, adjusting the memory to a low power consumption mode, and controlling the image sensor to enter a sleep state.
2. The method according to claim 1, characterized in that Before adjusting the processor to the high frequency mode in response to the received image data satisfying the first image processing condition, the method further includes: Cropping the image data to obtain data to be processed; Performing object detection processing and / or quantity statistics processing on the data to be processed to obtain a data processing result, wherein the data processing result includes an object detection result and / or a quantity statistics result, wherein the object detection result includes detecting whether the image data contains relevant information of the target object or whether the image data does not contain relevant information of the target object, and the quantity statistics result includes a total number corresponding to each image in the data to be processed; It is determined whether the received image data satisfies the first image processing condition based on the data processing result.
3. The method according to any one of claims 1 to 2, characterized in that: The working state of the image sensor includes a motion detection mode and an image output mode. Before the processor receives image data from the image sensor in the low-frequency mode, the method further includes: Controlling the image sensor in the motion detection mode to detect the image data to obtain a motion detection result, wherein the motion detection result includes a first motion detection result regarding relevant information of a moving object contained in the image data; In response to the motion detection result being the first motion detection result, the image sensor is adjusted to the image output mode so that the processor receives image data from the image sensor in a low-frequency mode.
4. The method according to claim 3, characterized in that The first motion detection result includes a number of current motion detection events, the number of current motion detection events represent that a number of objects to be confirmed are in motion, and in response to the motion detection result being the first motion detection result, adjusting the image sensor to the image output mode includes: In response to the first motion detection result satisfying a first preset condition, adjusting the image sensor to the image output mode, the first preset condition including that there is no historical motion detection event before a current timestamp corresponding to the current motion detection event in the first motion detection result, the historical motion detection event indicating that the object to be confirmed is in motion before the current timestamp; or, In response to the first motion detection result satisfying a second preset condition, adjusting the image sensor to the image output mode, the second preset condition including the case where there is a historical motion detection event before the current timestamp corresponding to the current motion detection event in the first motion detection result, and the time interval between the current timestamps corresponding to at least one of the current motion detection events in the first motion detection result is greater than or equal to the second preset time.
5. The method according to claim 4, characterized in that The method further comprises: In response to the first motion detection result satisfying a third preset condition, the image sensor is controlled to enter a sleep state, wherein the third preset condition includes that there is a historical motion detection event before the current timestamp corresponding to the current motion detection event in the first motion detection result, and the time interval between the current timestamps corresponding to all the current motion detection events in the first motion detection result and the historical timestamps of the historical motion detection events is less than the third preset time.
6. The method according to claim 3, characterized in that The motion detection result includes a second motion detection result regarding the image data not containing relevant information of a moving object, and the method further includes: In response to the motion detection result being the second motion detection result, controlling the image sensor to enter the sleep state.
7. The method according to any one of claims 1 to 2, characterized in that: Before the processor receives the image data from the image sensor in the low frequency mode, the method further includes: In response to the image sensor being powered on, setting a wake-up condition for the image sensor; The image sensor is controlled to switch states at a predetermined frequency, and the wake-up condition includes adjusting the image sensor in a dormant state to a working state after a target wake-up time, wherein the image sensor in the working state can be used to collect the image data.
8. An electronic device, characterized in that: include: A memory and a processor, wherein the memory stores program instructions, and the processor retrieves the program instructions from the memory to execute the method according to any one of claims 1 to 7.
9. A computer-readable storage medium, characterized in that: include: A program file is stored, and when the program file is executed by a processor, it is used to implement the method according to any one of claims 1 to 7.
Citation Information
Patent Citations
Target tracking method in wireless multimedia sensor network
CN101489292A
Photographing method, device and equipment and medium
CN109873952A
Control method and device of intelligent camera device, computer equipment and storage medium
CN111327821A
Processor awakening method, device and system, storage medium and AR glasses
CN114785954A
Wake-up method and device
CN117992128A
