Image processing method and device, computer equipment and storage medium

By calculating and writing the initial exposure and gain values ​​before image sensor initialization, and combining this with brightness analysis from the automatic exposure control module, the problem of delayed effect of image sensor parameter configuration is solved, enabling fast and stable image output.

CN121531238APending Publication Date: 2026-02-13SHENZHEN SIYUAN ELECTRONICS TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511389324.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-09-26
Publication Date
2026-02-13

AI Technical Summary

Technical Problem

In existing technologies, parameter configuration during image sensor initialization is delayed, resulting in poor output image stability and failing to meet the requirements for efficient and stable imaging.

Method used

By acquiring the digital signal corresponding to the current ambient light intensity, the target light level is obtained, and the initial exposure value and gain value are calculated based on the preset strategy table. The settings of image output-related registers are skipped, and the data is directly written to the exposure control and gain control registers. The automatic exposure control module is used to perform brightness analysis and adjustment, thereby achieving rapid initialization of the image sensor.

Benefits of technology

By reducing the convergence time of automatic exposure adjustment, the image sensor can output clear and stable images during the startup phase, thus improving the stability and quality of the output images.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121531238A_ABST
    Figure CN121531238A_ABST
Patent Text Reader

Abstract

The invention relates to an image processing method, which comprises the steps of collecting a digital signal corresponding to the illumination intensity of a current environment, and obtaining a target illumination level corresponding to the digital signal; calculating the target illumination level to obtain an initial exposure value and an initial gain value; writing register configurations one by one according to an initial register configuration sequence of the image sensor, and skipping an operation of setting a specified register; writing the initial exposure value into an exposure control register of the image sensor, and writing the initial gain value into a gain control register of the image sensor; performing configuration processing on the specified register to obtain a target image sensor, and receiving image data output by the target image sensor; performing brightness statistics and analysis on the image data based on an automatic exposure control module, and generating adjustment exposure parameters; and based on the target image sensor, executing re-acquisition of the image data according to the adjusted exposure parameters to obtain target image data. The stability of the output image is improved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of image processing, and in particular to an image processing method and device, a computer device and a storage medium. BACKGROUND

[0002] In the field of image sensor applications, the initialization process of the image sensor is a key link to ensure its normal operation. At present, the initialization of the image sensor in the prior art usually follows the initialization sequence provided by the manufacturer. In this process, the first frame of image output uses the default exposure value and gain value, and the system needs to be adjusted through a round of automatic exposure (AE) to gradually converge to the appropriate exposure and gain parameters to achieve a more ideal imaging effect. As a result, there is a delay in the effectiveness of sensor parameter configuration, that is, the parameter configuration often needs to be delayed for several frames to take effect. This results in that in the initialization process, after the sensor outputs the first frame of image, even if the preset exposure and gain values are configured subsequently, several frames need to be waited to obtain the expected imaging effect.

[0003] This delay prolongs the time required for AE convergence and stabilization, and in application scenarios with strict requirements on startup speed and real-time imaging quality, this defect is more prominent, seriously affecting the stability of imaging, resulting in poor stability of the output image, and failing to meet the urgent needs of actual applications for efficient and stable imaging. SUMMARY

[0004] The purpose of the embodiments of the present application is to provide an image processing method and device, a computer device and a storage medium to solve the technical problem of the existing image sensor parameter configuration delay in effectiveness, resulting in poor stability of the output image.

[0005] In a first aspect, an image processing method is provided, comprising:

[0006] acquiring a digital signal corresponding to the light intensity of the current environment, and obtaining a target light level corresponding to the digital signal;

[0007] performing calculation and processing on the target light level based on a preset strategy table to obtain an initial exposure value and an initial gain value;

[0008] writing the initial exposure value into an exposure control register of the image sensor and writing the initial gain value into a gain control register of the image sensor according to the preset initialization register configuration sequence of the image sensor;

[0009] writing the initial exposure value into an exposure control register of the image sensor and writing the initial gain value into a gain control register of the image sensor according to the preset initialization register configuration sequence of the image sensor;

[0010] The configuration processing on the specified register obtains an initialized target image sensor, and image data output by the target image sensor is received;

[0011] The image data is subjected to brightness statistics and analysis based on a preset automatic exposure control module, and corresponding adjustment exposure parameters are generated;

[0012] Based on the target image sensor, reacquisition processing of image data is performed according to the adjustment exposure parameters, and corresponding target image data is obtained.

[0013] In a second aspect, an image processing apparatus is provided, comprising:

[0014] A first processing module is configured to acquire a digital signal corresponding to the light intensity of a current environment, and obtain a target light level corresponding to the digital signal;

[0015] A calculation module is configured to perform calculation processing on the target light level based on a preset strategy table, and obtain corresponding initial exposure values and initial gain values;

[0016] A second processing module is configured to write register configurations one by one according to a preset initialization register configuration sequence of an image sensor, and skip the operation of setting a specified register related to image output, so as to obtain an image sensor in a standby state;

[0017] A writing module is configured to write the initial exposure values into an exposure control register of the image sensor, and write the initial gain values into a gain control register of the image sensor;

[0018] A configuration module is configured to perform configuration processing on the specified register to obtain an initialized target image sensor, and receive image data output by the target image sensor;

[0019] A generation module is configured to perform brightness statistics and analysis on the image data based on a preset automatic exposure control module, and generate corresponding adjustment exposure parameters;

[0020] An acquisition module is configured to perform reacquisition processing of image data based on the target image sensor according to the adjustment exposure parameters, and obtain corresponding target image data.

[0021] In a third aspect, a computer device is provided, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, and the processor implements the steps of the above image processing method when executing the computer program.

[0022] In a fourth aspect, a computer-readable storage medium is provided, which stores a computer program. The computer program is executed by a processor to implement the steps of the image processing method.

[0023] In the scheme implemented by the image processing method, the image processing device, the computer device, and the storage medium, first, a digital signal corresponding to the light intensity of the current environment is collected, and a target light level corresponding to the digital signal is obtained. Then, the target light level is calculated and processed based on a preset strategy table to obtain a corresponding initial exposure value and an initial gain value. Subsequently, the register configuration is written into the register one by one according to a preset initialization register configuration sequence of the image sensor, and the operation of setting a specified register related to image output is skipped to obtain an image sensor in a standby state. Subsequently, the initial exposure value is written into an exposure control register of the image sensor, and the initial gain value is written into a gain control register of the image sensor. Further, the specified register is configured and processed to obtain a target image sensor with initialization completed, and image data output by the target image sensor is received. Furthermore, the image data is subjected to brightness statistics and analysis based on a preset automatic exposure control module to generate a corresponding adjustment exposure parameter. Finally, based on the target image sensor, the image data is subjected to reacquisition processing according to the adjustment exposure parameter to obtain corresponding target image data. Based on the above processing procedure, the initial exposure value and the initial gain value generated by calculating the target light level based on the strategy table are written into the image sensor before initialization, which avoids the defect that in the traditional method, the first frame uses the default exposure value and gain value and needs to wait for multiple frames to achieve a relatively accurate exposure, reduces the convergence time of automatic exposure adjustment, greatly improves the response speed, and enables the image sensor to output clear and stable images in the startup stage, thereby effectively improving the stability and quality of the output images. BRIEF DESCRIPTION OF DRAWINGS

[0024] In order to more clearly illustrate the schemes in the present application, the drawings needed in the embodiments of the present application will be briefly introduced as follows. Obviously, the drawings in the following description are some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creative labor.

[0025] Figure 1 is an exemplary system architecture diagram to which the present application can be applied;

[0026] Figure 2 is a flowchart of one embodiment of the image processing method according to the present application;

[0027] Figure 3is a structural schematic diagram of one embodiment of the image processing apparatus according to the present application;

[0028] Figure 4 is a structural schematic diagram of one embodiment of the computer device according to the present application. DETAILED DESCRIPTION

[0029] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs; the terminology used in the description herein is for describing particular embodiments only and is not intended to be limiting of the application; the use herein of terms such as "comprise" and "have" and any variations thereof are intended to cover a non-exclusive inclusion; the use herein of terms such as "first", "second" and the like are used for distinguishing between similar objects and not necessarily for describing a particular sequential or chronological order.

[0030] Reference herein to "embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment can be included in at least one embodiment of the application. The appearances of the phrase that the phrase in the specification in various places does not necessarily all refer to the same embodiment, nor are they necessarily mutually exclusive or alternative embodiments. It is explicitly and implicitly understood that the embodiments described herein can be combined.

[0031] In order to make the technical personnel in the art better understand the scheme of the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings.

[0032] As shown in Figure 1 The system architecture 100 can include a terminal device 101, a network 102 and a server 103, and the terminal device 101 can be a notebook computer 1011, a tablet computer 1012 or a mobile phone 1013. The network 102 is a medium for providing a communication link between the terminal device 101 and the server 103. The network 102 can include various connection types, such as wired, wireless communication links or optical fiber cables, etc.

[0033] A user can use the terminal device 101 to interact with the server 103 through the network 102 to receive or send messages, etc. Various communication client applications can be installed on the terminal device 101, such as web browser applications, shopping applications, search applications, instant messaging tools, email clients, social platform software, etc.

[0034] The terminal device 101 can be various electronic devices with a display screen and supporting web browsing, in addition to the notebook computer 1011, the tablet computer 1012 or the mobile phone 1013, the terminal device 101 can also be an electronic book reader, an MP3 player (Moving Picture Experts Group Audio Layer III), an MP4 player (Moving Picture Experts Group Audio Layer IV), a laptop computer and a desktop computer, etc.

[0035] The server 103 can be a server providing various services, for example, a background server providing support for a page displayed on the terminal device 101.

[0036] It should be noted that the image processing method provided by the embodiments of the present application is generally executed by a server / terminal device, and correspondingly, the image processing apparatus is generally arranged in a server / terminal device.

[0037] It should be understood that, Figure 1 The number of terminal devices, networks and servers in

[0038] With reference to Figure 2 , a flow chart of one embodiment of the image processing method according to the present application is shown. The order of the steps in the flow chart can be changed according to different requirements, and some steps can be omitted. The image processing method provided by the embodiments of the present application can be applied to any scenario requiring image processing, and then the image processing method can be applied to products in these scenarios. The image processing method comprises the following steps:

[0039] In step S201, a digital signal corresponding to the light intensity of the current environment is collected, and a target light level corresponding to the digital signal is obtained.

[0040] In the present embodiment, the electronic device (for example Figure 1The server / terminal device shown) can obtain a digital signal corresponding to the light intensity of the current environment through a wired connection or a wireless connection. It should be noted that the wireless connection can include but is not limited to 3G / 4G / 5G connection, WiFi connection, Bluetooth connection, WiMAX connection, Zigbee connection, UWB (ultra wide band) connection, and other now known or future developed wireless connection. The execution subject of the present application is an image processing system, which can be referred to as a system. The system includes an image sensor and a master chip. The present application can be applied to various cameras, vehicle-mounted image systems and intelligent monitoring devices, has good universality and scalability, can shorten the startup waiting time of the camera device, and enables users to quickly obtain stable images in complex lighting environments. Among them, the specific implementation process of collecting the digital signal corresponding to the light intensity of the current environment and obtaining the target light level corresponding to the digital signal will be further described in detail in the subsequent specific embodiments, and will not be described here.

[0041] Step S202, based on the preset strategy table, the target light level is calculated and processed to obtain the corresponding initial exposure value and initial gain value.

[0042] In this embodiment, the specific implementation process of calculating and processing the target light level based on the preset strategy table to obtain the corresponding initial exposure value and initial gain value will be further described in detail in the subsequent specific embodiments, and will not be described here.

[0043] Step S203, according to the preset image sensor initialization register configuration sequence, write the register configuration one by one, and skip the operation of setting the specified register related to image output, to obtain the image sensor in standby state.

[0044] In the embodiment, the initialization register configuration sequence of the image sensor can be obtained by referring to the specification book or development manual (specification information) provided by the original manufacturer of the image sensor. The initialization register configuration sequence generally includes clock configuration, interface mode setting, PLL configuration, image format setting, black level correction parameter, gain / exposure default value, and output control register, etc. Then, in the initialization register configuration sequence, the register (designated register) related to image output (stream on / off) is located. Generally, the register is located at the end of the initialization sequence, and its function is to control whether the sensor starts to output image data. Further, the register configuration is written one by one according to the initialization register configuration sequence to ensure that the functions of the internal clock, analog-to-digital conversion module, image processing unit, etc. of the sensor are started correctly. However, during the execution process, the operation of setting the "stream on" register (designated register) is skipped or shielded to avoid premature output of images before the AE (automatic exposure) parameter is completed. After all configurations except the "stream on" register are completed, the image sensor is in a standby state of initialization completion but no stream output. At this time, the internal circuit of the image sensor has stabilized, and the normal stream output mode can be entered by configuring the "stream on" register after writing the exposure value and gain value.

[0045] In step S204, the initial exposure value is written into the exposure control register of the image sensor, and the initial gain value is written into the gain control register of the image sensor.

[0046] In the embodiment, the specific implementation process of writing the initial exposure value into the exposure control register of the image sensor and writing the initial gain value into the gain control register of the image sensor will be further described in detail in subsequent specific embodiments, and will not be described here.

[0047] After the parameter writing of the initial exposure value and the initial gain value is completed, the internal register of the image sensor has loaded the corresponding initial values. At this time, although the image sensor has not started image output (stream on is not configured), it has entered a standby state with preset AE parameters.

[0048] In step S205, the designated register is configured to obtain an initialized target image sensor, and image data output by the target image sensor is received.

[0049] In the embodiment, the specific implementation process of the configuration of the specified register to obtain the initialized target image sensor is described in detail in the subsequent embodiments.

[0050] Wherein, after a series of related configuration work is completed, data is written to the "stream on" register (specified register) for configuration, which is like issuing a start instruction, so that the image sensor starts normal work and outputs image data stream, which is the starting action of generating an image, and the image sensor enters the working state to capture external information. That is, when the specified register can "stream on", the image sensor will directly collect the first frame with the initial exposure value and the initial gain value written, so as to ensure that the brightness of the first frame is close to the normal level, and to avoid overexposure or overexposure.

[0051] Step S206, based on the preset automatic exposure control module, the brightness of the image data is counted and analyzed, and the corresponding adjustment exposure parameter is generated.

[0052] In the embodiment, the specific implementation process of the configuration of the specified register to obtain the initialized target image sensor is described in detail in the subsequent embodiments.

[0053] Step S207, based on the target image sensor, the re-collection processing of the image data is performed according to the adjustment exposure parameter, and the corresponding target image data is obtained.

[0054] In the embodiment, after the brightness of the image data is counted and analyzed by the automatic exposure control module, the corresponding adjustment exposure parameter is generated, that is, the exposure parameter is adjusted, the image sensor re-collects the image data according to the new exposure parameter, and the corresponding target image data is obtained.

[0055] The application firstly collects a digital signal corresponding to the light intensity of the current environment, and obtains a target light level corresponding to the digital signal; then performs calculation and processing on the target light level based on a preset strategy table to obtain a corresponding initial exposure value and initial gain value; then writes register configurations one by one according to a preset initialization register configuration sequence of the image sensor, and skips the operation of setting a specified register related to image output to obtain an image sensor in a standby state; subsequently writes the initial exposure value into an exposure control register of the image sensor, and writes the initial gain value into a gain control register of the image sensor; further performs configuration processing on the specified register to obtain an initialized target image sensor, and receives image data output by the target image sensor; then performs brightness statistics and analysis on the image data based on a preset automatic exposure control module to generate a corresponding adjustment exposure parameter; finally, based on the target image sensor, performs reacquisition processing of image data according to the adjustment exposure parameter to obtain corresponding target image data. Based on the above processing procedure, the application writes the initial exposure value and the initial gain value generated by calculating the target light level based on the strategy table before the initialization of the image sensor, which avoids the defect that the first frame uses the default exposure value and gain value in the traditional method and needs to wait for multiple frames to achieve a more accurate exposure, reduces the convergence time of automatic exposure adjustment, greatly improves the response speed, and enables the image sensor to output clear and stable images in the startup stage, thereby effectively improving the stability and quality of the output image.

[0056] In some optional implementations, step S201 includes the following steps:

[0057] Collecting a digital signal corresponding to the light intensity of the current environment based on a preset photosensitive device.

[0058] In the embodiment, the above-mentioned photosensitive device can specifically adopt an analog photosensitive sensor or a digital photosensitive sensor to collect an ADC original value (digital signal) corresponding to the current ambient light intensity. The acquisition process of the ADC original value is described below by taking an analog photosensitive sensor as an example. Specifically, the photosensitive device has a light-sensitive element inside, such as a photoresistor, a photosensitive diode, or a photosensitive transistor. When the ambient light intensity changes, the physical properties (such as resistance value, current value, etc.) of these sensitive elements will change accordingly. For example, the resistance value of the photoresistor decreases with the increase of the light intensity. The signal output from the photosensitive element is usually a weak analog signal, which needs to be conditioned in order to be effectively processed by the subsequent circuit. This may include amplification, filtering, and other operations to enhance the signal strength and remove noise interference. Then, the conditioned analog signal is sent to an ADC (analog-to-digital converter). The role of the ADC is to convert the continuously changing analog signal into a discrete digital signal. In this process, the ADC samples and quantizes the analog signal. Sampling refers to taking values of the analog signal at certain time intervals, and quantization converts the continuous amplitude values obtained by sampling into a limited number of discrete digital values. Subsequently, the original value output by the ADC is a binary or decimal (depending on the design and reading method of the ADC) digital quantity, which represents the digital representation of the ambient light intensity sensed by the analog photosensitive sensor after sampling and quantization. The size of this value has a certain corresponding relationship with the light intensity, but this relationship may be nonlinear, depending on the characteristics of the photosensitive sensor and the design of the signal conditioning circuit. For example, within a certain range of light intensity, as the light intensity increases, the ADC original value may gradually increase, but the increasing amplitude may not be uniform.

[0059] The digital signal is converted into a corresponding target light intensity based on a preset calibration conversion strategy.

[0060] In the embodiment, the selection of the above-mentioned calibration conversion strategy is not specifically limited and can be determined according to actual business requirements. For example, a linear calibration formula lux = a x adc + b or a two-section calibration formula lux1 = a x adc1 + b; lux2 = a x adc2 + b can be used. The parameters a and b can be generated by calibrating a preset standard light source. Then, the above-mentioned digital signal (i.e., the ADC original value) can be substituted into the corresponding calibration formula to calculate the actual light intensity (lux), i.e., the target light intensity.

[0061] Obtain a preset light level division rule.

[0062] In the embodiment, the light level division rule is a division standard of different light levels determined according to the requirements of the actual application scene, which is used to divide the environment light into different level intervals (such as low illumination, medium illumination, and high illumination), for example, the rule content includes: 0-100 lux: low illumination scene, 100-1000 lux: medium illumination scene, and 1000 lux or more: high illumination scene.

[0063] The target light intensity is divided into levels based on the light level division rule to obtain a corresponding target light level.

[0064] In the embodiment, the light level interval set in the light level division rule can be compared by using the target light intensity to determine the target light level to which the current environment belongs. For example, if the converted light intensity is 80 lux, it belongs to a low illumination scene; if the light intensity is 500 lux, it belongs to a medium illumination scene; and if the light intensity is 1200 lux, it belongs to a high illumination scene.

[0065] The application collects a digital signal corresponding to the light intensity of the current environment based on the preset photosensitive device; then converts the digital signal into a corresponding target light intensity based on a preset calibration conversion strategy; then obtains a preset light level division rule; and subsequently divides the target light intensity into levels based on the light level division rule to obtain a corresponding target light level. Based on the above processing flow, the application collects a digital signal corresponding to the light intensity of the current environment based on the use of the preset photosensitive device, then converts the digital signal into a corresponding target light intensity based on the use of the calibration conversion strategy, and then divides the target light intensity into levels based on the use of the light level division rule, so that the target light level corresponding to the light intensity of the current environment can be efficiently and accurately obtained, the generation efficiency of the target light level is improved, and the accuracy of the obtained target light level is ensured.

[0066] In some optional implementation manners of the embodiment, step S202 includes the following steps:

[0067] A preset strategy table is called.

[0068] In the embodiment, the strategy table refers to a pre-constructed AE (automatic exposure) strategy table, and the construction process of the strategy table includes: determining the adjustable range of exposure time according to the performance of the image sensor and the system, for example, from 1 / 1000 second to 1 / 30 second. Then, for different light levels, corresponding initial exposure value strategies are formulated, as shown in the following table (strategy table): low illumination: 1 / 60 second; medium illumination: 1 / 125 second; and high illumination: 1 / 500 second.

[0069] searching the policy table to find a first exposure time corresponding to the target illumination level.

[0070] In this embodiment, the first exposure time corresponding to the target illumination level can be found in the constructed policy table. For example, the exposure time corresponding to the low illumination level is 1 / 60 second, and this value is taken as the first exposure time.

[0071] The first exposure time is calculated based on a preset adjustment calculation policy to obtain a corresponding second exposure time, and the second exposure time is taken as the initial exposure value.

[0072] In this embodiment, the policy content of the adjustment calculation policy includes: 1. Analyzing the influence of additional factors on exposure time. Scene object movement: through image analysis or other sensors (such as motion sensors) to detect whether there are fast moving objects in the scene. If the object moving speed is detected to be fast, in order to avoid image blur, the exposure time is shortened. Determine the adjustment ratio: according to the speed of object movement, determine the adjustment ratio of exposure time. For example, if the object moving speed is fast, the exposure time is shortened to 80% of the original; if the object moving speed is extremely fast, the exposure time can be shortened to 50% of the original. 2. Calculate the adjusted exposure time. Calculate the adjustment value: multiply the basic exposure time by the adjustment ratio to obtain the adjusted exposure time. For example, the basic exposure time is 1 / 60 second, and the adjustment ratio is 80%, then the adjusted exposure time is 1 / 60 second x 80% = 1 / 75 second. Consider the boundary condition: when calculating the adjusted exposure time, the limitations of the sensor and the system need to be considered to ensure that the adjusted exposure time is within the adjustable range. If the adjusted exposure time is less than the minimum exposure time (such as 1 / 1000 second), it is set to the minimum exposure time; if the adjusted exposure time is greater than the maximum exposure time (such as 1 / 30 second), it is set to the maximum exposure time.

[0073] The first exposure time is calculated based on the policy content of the adjustment calculation policy, and the obtained second exposure time is taken as the required initial exposure value.

[0074] The initial exposure value is compared with a preset maximum exposure time to obtain a corresponding comparison result.

[0075] In the embodiment, the maximum exposure time allowed under the current lighting condition can be determined according to the performance of the image sensor and the entire imaging system. For example, in a video shooting scenario, if the frame rate requirement is 30 fps, the maximum exposure time cannot exceed 1 / 30 s to ensure that each frame can be collected within the specified time. Then, the calculated initial exposure value is compared with the maximum exposure time to obtain a corresponding comparison result. If the initial exposure value is less than the maximum exposure time, it indicates that the brightness requirement can be met by adjusting the exposure time; if the initial exposure value is equal to or greater than the maximum exposure time, it indicates that the brightness requirement cannot be met by adjusting the exposure time alone, and the gain value needs to be increased.

[0076] Based on the comparison result, an initial gain value corresponding to the initial exposure value is generated using a preset gain value adjustment strategy.

[0077] In the embodiment, the gain types supported by the image sensor generally include analog gain and digital gain. Analog gain amplifies the analog signal inside the sensor, which may introduce more noise; digital gain amplifies the signal in the digital signal processing stage, which has relatively small impact on noise. The strategy content of the gain value adjustment strategy includes: when the exposure time does not reach the limit, to reduce noise, a low gain value should be maintained. For example, the analog gain is set to 1 times, and the digital gain is also set to 1 times. When the exposure time reaches the limit, if the exposure time has reached the maximum exposure time limit, but the image brightness still does not meet the requirement, the gain value needs to be gradually increased. Generally, the analog gain is increased first because the amplification effect of the analog gain is relatively direct. For example, the analog gain is first increased to 2 times, and if the image brightness is still insufficient at this time, the digital gain is considered to be increased, such as increasing the digital gain to 1.5 times. Specifically, the comparison result can be analyzed based on the strategy content of the gain value adjustment strategy to generate an initial gain value corresponding to the initial exposure value.

[0078] In addition, the processing process for the case of sufficient ambient light can include: judging the degree of sufficient ambient light: a light intensity threshold is set, and when the light intensity exceeds the threshold, it is considered that the ambient light is sufficient. This threshold can be determined according to the actual application scenario and imaging requirements, for example, in some outdoor shooting scenarios, when the light intensity exceeds 500 lux, it can be determined that the ambient light is sufficient. Set a low gain value: when the light intensity exceeds the set threshold, to reduce the noise caused by signal amplification and improve the image quality, the analog gain and the digital gain are both set to a low value, such as the analog gain being 1 times and the digital gain being 1 times.

[0079] In addition, in practical applications, other factors such as the dynamic range of the image, the reflection characteristics of the target object, etc. can be further considered in addition to the exposure time and the ambient light condition. For example, if the reflectivity of the target object is low, even if the ambient light is sufficient, a little gain value may need to be appropriately increased to enhance the contrast of the image. After the gain value is preliminarily determined according to the above strategy, actual image acquisition and testing are performed. The brightness, noise level, color restoration degree, etc. of the observed image are observed, and if it is found that the image brightness is insufficient or the noise is too large, the gain value is fine-tuned according to the actual situation until a satisfactory image quality is obtained.

[0080] The preset strategy table is called, a first exposure time corresponding to the target illumination level is found from the strategy table, a second exposure time corresponding to the first exposure time is calculated based on a preset adjustment calculation strategy, and the second exposure time is taken as the initial exposure value. Then, the initial exposure value is compared with a preset maximum exposure time to obtain a corresponding comparison result. Subsequently, based on the comparison result, a preset gain value adjustment strategy is used to generate an initial gain value corresponding to the initial exposure value. Based on the above processing flow, the first exposure time corresponding to the target illumination level is found by using the strategy table, the first exposure time is calculated based on the use of the adjustment calculation strategy, the second exposure time is taken as the required exposure time, the initial exposure value is compared with the preset maximum exposure time, and based on the obtained comparison result, the initial gain value corresponding to the initial exposure value is generated by using the gain value adjustment strategy. Therefore, the initial exposure value and the initial gain value corresponding to the target illumination level can be automatically and accurately generated based on the combined use of the strategy table, the adjustment calculation strategy and the gain value adjustment strategy, which ensures the accuracy of the obtained initial exposure value and initial gain value and is beneficial to providing accurate basic configurations for subsequent image sensor startup.

[0081] In some optional implementations, step S204 includes the following steps:

[0082] Obtaining specification information of the image sensor.

[0083] In the embodiment, the specification information refers to the specification book or development manual of the image sensor.

[0084] Based on the specification information, a first register address and a first write mode of an exposure control register corresponding to the exposure value are determined, and a second register address and a second write mode of a gain control register corresponding to the gain value are determined.

[0085] In the embodiment, the exposure time (Integration Time) and the gain value (Analog Gain, Digital Gain) corresponding register address, register bit width and writing mode can be determined by content query of the specification or development manual of the image sensor. The exposure control register corresponding to the exposure time includes the first register address, the register bit width and the first writing mode. The gain control register corresponding to the gain value includes the second register address and the second writing mode.

[0086] The initial exposure value is written into the exposure control register of the image sensor by the first writing mode based on the first register address.

[0087] In the embodiment, the initial exposure value is written into the exposure control register of the image sensor by the first writing mode based on the obtained first register address. Specifically, the initial exposure value is usually represented by line, and the initial exposure value needs to be split according to the register bit width when written (such as high 8 bits and low 8 bits written separately). After the initial exposure value is written, the internal integration circuit of the image sensor will integrate according to the preset initial exposure value at the start.

[0088] The initial gain value is written into the gain control register of the image sensor by the second writing mode based on the second register address.

[0089] In the embodiment, the initial gain value is written into the gain control register of the image sensor by the second writing mode based on the obtained second register address. Specifically, the initial gain value includes analog gain (Analog Gain) and digital gain (Digital Gain), which can be written into the gain control register separately or combined according to the strategy. The analog gain can be increased preferentially in the low-illumination scene, and the low gain can be maintained in the high-illumination scene to reduce noise.

[0090] The present application obtains the specification information of the image sensor, and then determines the first register address and the first write mode of the exposure control register corresponding to the exposure value and the second register address and the second write mode of the gain control register corresponding to the gain value based on the specification information. Subsequently, the initial exposure value is written into the exposure control register of the image sensor by the first write mode based on the first register address, and the initial gain value is written into the gain control register of the image sensor by the second write mode based on the second register address. Based on the above processing flow, the present application obtains the specification information of the image sensor, and determines the first register address and the first write mode of the exposure control register corresponding to the exposure value and the second register address and the second write mode of the gain control register corresponding to the gain value based on the use of the specification information. Then, the initial exposure value is written into the exposure control register of the image sensor by the first write mode based on the use of the first register address, and the initial gain value is written into the gain control register of the image sensor by the second write mode based on the use of the second register address. Thus, the writing process of writing the initial exposure value and the initial gain value into the corresponding registers of the image sensor can be automatically and accurately completed, which is beneficial to the image sensor to use the preset initial exposure value and the initial gain value for image acquisition processing after being started.

[0091] In some optional implementations, step S205 includes the following steps:

[0092] The specification information of the image sensor is obtained.

[0093] In the embodiment, the specification information refers to the specification book or the development manual of the image sensor.

[0094] The third register address of the specified register is determined based on the specification information.

[0095] In the embodiment, the third register address of the specified register related to the image output (stream on / off) can be located from the specification information of the image sensor.

[0096] The register value of the specified register is set to the specified value corresponding to the on state based on the third register address, so as to obtain the target image sensor with initialization completed.

[0097] In the embodiment, the specified register is configured to be in a stream on state by setting the third register address of the specified register according to the third register address described above, which is achieved by writing the register value from 0x00 (off) to the specified value 0x01 (on) or setting a specific bit (different sensor configuration methods are different, and the configuration needs to be confirmed in the specification book before the configuration). Thus, the initialization processing of the image sensor is completed. When the "stream on" register is configured, the image sensor starts to output the image data stream. Since the initial exposure value and the initial gain value have been written before, the first frame of image will be directly collected by using the preset parameters (the initial exposure value and the initial gain value), so as to ensure that the initial image brightness is in a reasonable range. In addition, with the normal output of the image data, the initialization process of the image sensor is completed, and the system enters the normal working state.

[0098] The application obtains the specification information of the image sensor, determines the third register address of the specified register based on the specification information, and then sets the register value of the specified register to a specified value corresponding to the on state based on the third register address, so as to obtain the target image sensor with completed initialization. Based on the above processing flow, the application obtains the specification information of the image sensor, determines the third register address of the specified register based on the use of the specification information, and then sets the register value of the specified register to a specified value corresponding to the on state based on the use of the third register address, so as to obtain the target image sensor with completed initialization. Thus, the configuration processing of the specified register can be automatically and accurately completed, so that the system can enter the normal working state.

[0099] In some optional implementation manners of the embodiment, the step S206 includes the following steps:

[0100] The automatic exposure control module in the preset image signal processor is called.

[0101] In the embodiment, the image signal processor is an ISP. The automatic exposure control module is an AE module in the ISP. The AE module adjusts the exposure parameter automatically according to the brightness of the image, so as to make the image reach a proper brightness.

[0102] Based on the automatic exposure control module, the actual brightness of the image data is calculated and processed according to the preset exposure target, so as to obtain corresponding deviation data.

[0103] In the embodiment, the automatic exposure control module calculates the deviation between the actual brightness of the current frame (image data) and the exposure target according to the system preset exposure target (such as the median of the image gray histogram or the average brightness target) as a reference value, to obtain corresponding deviation data, or called brightness deviation.

[0104] Obtain a preset exposure parameter adjustment strategy.

[0105] In the embodiment, the strategy content of the exposure parameter adjustment strategy includes that the AE algorithm iteratively adjusts the exposure time and gain value according to the brightness deviation frame by frame or multi-frame, so that the image gradually approaches the target brightness. When the brightness is insufficient, the exposure time is preferentially extended or the gain is preferentially increased, and when the brightness is too high, the exposure time is shortened or the gain is reduced. The adjustment process can be realized in combination with algorithms of various ISP manufacturers, such as integral method, PID control or histogram equalization strategy.

[0106] Based on the deviation data, the exposure parameter adjustment strategy is used to perform adjustment processing on the exposure parameter, to obtain corresponding adjusted exposure parameter.

[0107] In the embodiment, the exposure parameter adjustment strategy can be used to perform adjustment processing on the exposure parameter by using the deviation data, to obtain corresponding adjusted exposure parameter (including adjusted exposure time and adjusted gain value).

[0108] Since the initial exposure and gain parameters close to the target brightness are calculated and written by the photosensitive value, the brightness of the first frame of the sensor is in a reasonable range. In this way, the AE module has a small deviation when starting, and different manufacturer algorithms can all achieve a fast convergence state, significantly shortening the time required for AE stabilization. Moreover, as the environmental light conditions change, the AE module continuously analyzes and adjusts the image frames, ensuring that the output image brightness always remains in the target interval. At this point, the system formally enters the normal exposure control phase.

[0109] The application calls a preset image signal processor internal automatic exposure control module, then performs deviation calculation processing on the actual brightness of the image data according to a preset exposure target based on the automatic exposure control module, obtains corresponding deviation data, then acquires a preset exposure parameter adjustment strategy, and subsequently performs exposure parameter adjustment processing using the exposure parameter adjustment strategy based on the deviation data, to obtain corresponding adjusted exposure parameters. Based on the above processing procedure, the application uses the automatic exposure control module in the image signal processor, performs deviation calculation processing on the actual brightness of the image data according to a preset exposure target to obtain deviation data, and then performs exposure parameter adjustment processing using an exposure parameter adjustment strategy based on the deviation data to obtain corresponding adjusted exposure parameters, thereby ensuring the accuracy of the adjusted exposure parameters, and facilitating the use of the adjusted exposure parameters to quickly and stably stabilize the image brightness at a target value to adapt to a dynamic light environment, thereby improving the image quality and stability of the output target image data.

[0110] In some optional implementations of the embodiment, after step S207, the electronic device can further perform the following steps:

[0111] perform color correction processing on the target image data to obtain corresponding first image data.

[0112] In the embodiment, the image signal processor (ISP) is a complex system containing various algorithms and modules, which is used for comprehensive processing and optimization of original image data. The AE algorithm (automatic exposure control module) is an important module in the ISP, but it is not the only module. In addition to the AE algorithm, the ISP also includes an automatic white balance (AWB) algorithm, a noise reduction algorithm, a sharpening algorithm, and the like.

[0113] The target image data can be color corrected by using the automatic white balance (AWB) algorithm to conform to the color perception of the human eye to the true scene, thereby obtaining corresponding first image data.

[0114] perform noise reduction processing on the first image data to obtain corresponding second image data.

[0115] In the embodiment, the first image data can be noise reduced by using the noise reduction algorithm to reduce noise in the image and improve the clarity of the image, thereby obtaining second image data after noise reduction.

[0116] perform image enhancement processing on the second image data to obtain corresponding third image data.

[0117] In the embodiment, the second image data is subjected to image enhancement processing by using the sharpening algorithm to enhance the edges and details of the image, so that the image is clearer and sharper, thereby obtaining third image data after processing.

[0118] The third image data is subjected to output processing.

[0119] In the embodiment, the output processing of the third image data is completed by displaying the generated third image data or sending the generated third image data to a relevant user.

[0120] The application obtains corresponding first image data by performing color correction processing on the target image data, then obtains corresponding second image data by performing noise reduction processing on the first image data, then obtains corresponding third image data by performing image enhancement processing on the second image data, and finally performs output processing on the third image data. Based on the above processing procedure, the application can automatically and intelligently generate clear, appropriate brightness, and accurate color third image data by performing color correction processing, noise reduction processing, and image enhancement processing on the target image data, thereby improving the image quality of the generated third image data, and then performing output processing on the third image data, which can improve the output intelligence of the third image data.

[0121] In some optional implementations, the obtained user information is obtained with the consent of the user and in compliance with relevant laws and relevant policies.

[0122] In addition, the non-company software tools or components in the embodiments of the application are only examples and do not represent actual use.

[0123] It should be understood that the size of the serial number of each step in the above embodiments does not mean the order of execution, and the execution order of each process should be determined according to its function and inherent logic, and should not constitute any limitation on the implementation process of the embodiments of the application.

[0124] Those skilled in the art can understand that all or part of the processes in the above embodiments can be completed by computer readable instructions instructing related hardware, and the computer readable instructions can be stored in a computer readable storage medium. When the program is executed, it can include the processes of the above embodiments. The storage medium can be a non-volatile storage medium such as a magnetic disc, an optical disc, a read-only memory (ROM), or a random access memory (RAM).

[0125] It should be understood that although each step in the flowchart of the accompanying drawings is shown in sequence according to the direction of the arrow, these steps are not necessarily executed in sequence according to the direction of the arrow. Unless otherwise specified herein, the execution of these steps is not strictly limited in sequence, and they can be executed in other sequences. Moreover, at least part of the steps in the flowchart of the accompanying drawings can include multiple sub-steps or multiple stages, which are not necessarily executed at the same time, but can be executed at different times, and the execution sequence is not necessarily sequential, but can be alternately executed with at least part of other steps or sub-steps or stages of other steps.

[0126] Further referring to Figure 3 , as an implementation of the method shown in the above Figure 2 , the present application provides an embodiment of an image processing device, which corresponds to the method embodiment shown in Figure 2 , and the device can be specifically applied to various electronic devices.

[0127] As shown in Figure 3 , the image processing device 300 described in the embodiment includes a first processing module 301, a calculation module 302, a second processing module 303, a writing module 304, a configuration module 305, a generation module 306, and an acquisition module 307. Among them:

[0128] The first processing module 301 is configured to acquire a digital signal corresponding to the light intensity of the current environment, and obtain a target light level corresponding to the digital signal;

[0129] The calculation module 302 is configured to perform calculation processing on the target light level based on a preset strategy table to obtain an initial exposure value and an initial gain value corresponding thereto;

[0130] The second processing module 303 is configured to write register configurations one by one according to a preset initialization register configuration sequence of the image sensor, and skip the operation of setting a specified register related to image output, to obtain an image sensor in a standby state;

[0131] The writing module 304 is configured to write the initial exposure value into an exposure control register of the image sensor, and write the initial gain value into a gain control register of the image sensor;

[0132] The configuration module 305 is configured to perform configuration processing on the specified register to obtain an initialized target image sensor, and receive image data output by the target image sensor;

[0133] The generating module 306 is configured to perform brightness statistics and analysis on the image data based on the preset automatic exposure control module, and generate corresponding adjustment exposure parameters.

[0134] The collecting module 307 is configured to perform re-collection processing of image data according to the adjustment exposure parameters based on the target image sensor, and obtain corresponding target image data.

[0135] In the embodiment, the operations performed by the above modules or units correspond to the steps of the image processing method of the foregoing embodiments one by one, and will not be described here again.

[0136] In some optional implementations of the embodiment, the first processing module 301 includes:

[0137] The first collecting sub-module is configured to collect a digital signal corresponding to the light intensity of the current environment based on the preset photosensitive device.

[0138] The conversion sub-module is configured to convert the digital signal into a corresponding target light intensity based on a preset calibration conversion strategy.

[0139] The first obtaining sub-module is configured to obtain a preset light level division rule.

[0140] The division sub-module is configured to divide the target light intensity into a corresponding target light level based on the light level division rule.

[0141] In the embodiment, the operations performed by the above modules or units correspond to the steps of the image processing method of the foregoing embodiments one by one, and will not be described here again.

[0142] In some optional implementations of the embodiment, the calculating module 302 includes:

[0143] The first calling sub-module is configured to call a preset strategy table.

[0144] The searching sub-module is configured to search the strategy table to find a first exposure time corresponding to the target light level.

[0145] The first calculating sub-module is configured to calculate the first exposure time based on a preset adjustment calculation strategy to obtain a corresponding second exposure time, and use the second exposure time as the initial exposure value.

[0146] The comparing sub-module is configured to compare the initial exposure value with a preset maximum exposure time to obtain a corresponding comparison result.

[0147] The generating sub-module is configured to generate an initial gain value corresponding to the initial exposure value based on the comparison result and using a preset gain value adjustment strategy.

[0148] In the embodiment, the operations performed by the above modules or units respectively correspond to the steps of the image processing method of the foregoing embodiments, and thus are not described here.

[0149] In some optional implementations of the embodiment, the writing module 304 includes:

[0150] a second obtaining sub-module, configured to obtain specification information of the image sensor;

[0151] a first determining sub-module, configured to determine, based on the specification information, a first register address and a first writing mode of an exposure control register corresponding to the exposure value, and determine a second register address and a second writing mode of a gain control register corresponding to the gain value;

[0152] a first writing sub-module, configured to write, based on the first register address, the initial exposure value into the exposure control register of the image sensor by using the first writing mode;

[0153] a second writing sub-module, configured to write, based on the second register address, the initial gain value into the gain control register of the image sensor by using the second writing mode.

[0154] In the embodiment, the operations performed by the above modules or units respectively correspond to the steps of the image processing method of the foregoing embodiments, and thus are not described here.

[0155] In some optional implementations of the embodiment, the configuration module 305 includes:

[0156] a third obtaining sub-module, configured to obtain specification information of the image sensor;

[0157] a second determining sub-module, configured to determine, based on the specification information, a third register address of the specified register;

[0158] a setting sub-module, configured to set, based on the third register address, a register value of the specified register to a specified value corresponding to an enabled state, to obtain the initialized target image sensor.

[0159] In the embodiment, the operations performed by the above modules or units respectively correspond to the steps of the image processing method of the foregoing embodiments, and thus are not described here.

[0160] In some optional implementations of the embodiment, the generation module 306 includes:

[0161] a second calling sub-module, configured to call an automatic exposure control module inside a preset image signal processor.

[0162] The second calculation submodule is used to perform deviation calculation processing on the actual brightness of the image data based on the automatic exposure control module and according to the preset exposure target, so as to obtain the corresponding deviation data.

[0163] The fourth acquisition submodule is used to acquire preset exposure parameter adjustment strategies;

[0164] The adjustment submodule is used to adjust the exposure parameters based on the deviation data using the exposure parameter adjustment strategy, so as to obtain the corresponding adjusted exposure parameters.

[0165] In this embodiment, the operations performed by the above modules or units correspond one-to-one with the steps of the image processing method in the aforementioned embodiments, and will not be repeated here.

[0166] In some optional implementations of this embodiment, the image processing apparatus further includes:

[0167] The second processing module is used to perform color correction processing on the target image data to obtain the corresponding first image data;

[0168] The third processing module is used to perform noise reduction processing on the first image data to obtain the corresponding second image data;

[0169] The fourth processing module is used to perform image enhancement processing on the second image data to obtain the corresponding third image data;

[0170] The determination module is used to output the third image data.

[0171] In this embodiment, the operations performed by the above modules or units correspond one-to-one with the steps of the image processing method in the aforementioned embodiments, and will not be repeated here.

[0172] To address the aforementioned technical problems, embodiments of this application also provide a computer device. Please refer to [link / reference needed]. Figure 4 , Figure 4 This is a basic structural block diagram of the computer device in this embodiment.

[0173] The computer device 4 includes a memory 41, a processor 42, and a network interface 43, which are communicatively connected via a system bus. It should be noted that only the computer device 4 with components 41-43 is shown in the figure, but it should be understood that not all of the shown components are required to be implemented, and more or fewer components can be alternatively implemented. Among them, those skilled in the art can understand that the computer device herein is a device capable of automatically performing numerical calculation and / or information processing according to pre-set or stored instructions, and its hardware includes but is not limited to microprocessors, application specific integrated circuits (ASICs), field programmable gate arrays (FPGAs), digital signal processors (DSPs), embedded devices, etc.

[0174] The computer device can be a desktop computer, a notebook computer, a palm computer, a cloud server, and the like. The computer device can interact with the user through a keyboard, a mouse, a remote controller, a touchpad, a voice control device, and the like.

[0175] The memory 41 includes at least one type of readable storage medium, including a flash memory, a hard disk, a multimedia card, a card-type memory (e.g., an SD or DX memory, etc.), a random access memory (RAM), a static random access memory (SRAM), a read-only memory (ROM), an electrically erasable programmable read-only memory (EEPROM), a programmable read-only memory (PROM), a magnetic memory, a magnetic disk, an optical disk, and the like. In some embodiments, the memory 41 can be an internal storage unit of the computer device 4, such as a hard disk or a memory of the computer device 4. In other embodiments, the memory 41 can also be an external storage device of the computer device 4, such as a plug-in hard disk, a smart media card (SMC), a secure digital (SD) card, a flash card, and the like. Of course, the memory 41 can also include both the internal storage unit and the external storage device of the computer device 4. In the present embodiment, the memory 41 is generally used to store an operating system and various application software installed in the computer device 4, such as computer readable instructions of the image processing method, and the like. In addition, the memory 41 can also be used to temporarily store various data that have been output or will be output.

[0176] The processor 42 may, in some embodiments, be a Central Processing Unit (CPU), a controller, a microcontroller, a microprocessor, or other data processing chip. The processor 42 is generally used to control the overall operation of the computer device 4. In the present embodiment, the processor 42 is configured to execute computer program instructions stored in the memory 41 or to process data, such as computer program instructions to execute the image processing method.

[0177] The network interface 43 may include a wireless network interface or a wired network interface, and is generally used to establish a communication connection between the computer device 4 and other electronic devices.

[0178] Compared with the prior art, the present embodiment has the following beneficial effects:

[0179] In the present embodiment, the initial exposure value and the initial gain value calculated based on the target light level are written before the initialization of the image sensor, which avoids the defect that the first frame uses the default exposure value and gain value and needs to wait for multiple frames to achieve a more accurate exposure in the conventional method, reduces the convergence time of automatic exposure adjustment, greatly improves the response speed, and enables the image sensor to output clear and stable images during the startup stage, thereby effectively improving the stability and quality of the output images.

[0180] The present application also provides another embodiment, i.e., a computer readable storage medium storing computer readable instructions, which can be executed by at least one processor to enable the at least one processor to perform the steps of the image processing method as described above.

[0181] Compared with the prior art, the present embodiment has the following beneficial effects:

[0182] In the present embodiment, the initial exposure value and the initial gain value calculated based on the target light level are written before the initialization of the image sensor, which avoids the defect that the first frame uses the default exposure value and gain value and needs to wait for multiple frames to achieve a more accurate exposure in the conventional method, reduces the convergence time of automatic exposure adjustment, greatly improves the response speed, and enables the image sensor to output clear and stable images during the startup stage, thereby effectively improving the stability and quality of the output images.

[0183] Those skilled in the art can clearly understand the above-mentioned embodiment method can be realized by means of software and the necessary general hardware platform, of course, it can also be realized by hardware, but in many cases, the former is a better embodiment. Based on such understanding, the technical solutions of the present application can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes a plurality of instructions for making a terminal device (which can be a mobile phone, computer, server, air conditioner, or network device, etc.) execute the method described in each embodiment of the present application.

[0184] Obviously, the above-described embodiments are only some of the embodiments of the present application, not all the embodiments, and the drawings show the preferred embodiments of the present application, but do not limit the patent scope of the present application. The present application can be implemented in many different forms, and conversely, the purpose of providing these embodiments is to make the disclosure of the present application more thorough and comprehensive. Although the present application has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions recorded in the foregoing specific embodiments, or make equivalent replacements to some of the technical features. Any equivalent structure made by using the content of the specification and drawings, directly or indirectly applied to other related technical fields, is also within the scope of the patent protection of the present application.

Claims

1. An image processing method, characterized in that, Includes the following steps: Collect the digital signal corresponding to the current ambient light intensity, and obtain the target light level corresponding to the digital signal; The target illumination level is calculated based on a preset strategy table to obtain the corresponding initial exposure value and initial gain value. Write the initialization register configuration of the image sensor one by one according to the preset sequence, and skip the operation of setting the specified registers related to image output to obtain the image sensor in standby state; The initial exposure value is written into the exposure control register of the image sensor, and the initial gain value is written into the gain control register of the image sensor; The specified register is configured to obtain the initialized target image sensor, and the image data output by the target image sensor is received. The image data is statistically analyzed and brightness statistics are performed based on the preset automatic exposure control module to generate corresponding exposure adjustment parameters. Based on the target image sensor, the image data is reacquired according to the adjusted exposure parameters to obtain the corresponding target image data.

2. The image processing method according to claim 1, characterized in that, The step of acquiring the digital signal corresponding to the current ambient light intensity and obtaining the target light level corresponding to the digital signal specifically includes: Digital signals corresponding to the current ambient light intensity are collected based on preset photosensitive devices; The digital signal is converted into the corresponding target light intensity based on a preset calibration conversion strategy; Obtain the preset lighting level classification rules; The target illumination intensity is classified into levels based on the illumination level classification rules to obtain the corresponding target illumination level.

3. The image processing method according to claim 1, characterized in that, The step of calculating the target illumination level based on a preset strategy table to obtain the corresponding initial exposure value and initial gain value specifically includes: Call the preset strategy table; Find the first exposure time corresponding to the target illumination level from the strategy table; The first exposure time is calculated based on a preset adjustment calculation strategy to obtain the corresponding second exposure time, and the second exposure time is used as the initial exposure value. The initial exposure value is compared with the preset maximum exposure time to obtain the corresponding comparison result; Based on the comparison results, an initial gain value corresponding to the initial exposure value is generated using a preset gain value adjustment strategy.

4. The image processing method according to claim 1, characterized in that, The steps of writing the initial exposure value into the exposure control register of the image sensor and writing the initial gain value into the gain control register of the image sensor specifically include: Obtain the specifications of the image sensor; Based on the specification information, the first register address and first write method of the exposure control register corresponding to the exposure value are determined, and the second register address and second write method of the gain control register corresponding to the gain value are determined. Based on the first register address, the initial exposure value is written into the exposure control register of the image sensor using the first write method; Based on the second register address, the initial gain value is written into the gain control register of the image sensor using the second write method.

5. The image processing method according to claim 1, characterized in that, The step of configuring the specified register to obtain the initialized target image sensor specifically includes: Obtain the specifications of the image sensor; The address of the third register of the specified register is determined based on the specification information; Based on the address of the third register, the register value of the specified register is set to the specified value corresponding to the on state, so as to obtain the target image sensor after initialization.

6. The image processing method according to claim 1, characterized in that, The step of the automatic exposure control module based on a preset value performing brightness statistics and analysis on the image data to generate corresponding exposure adjustment parameters specifically includes: Call the preset automatic exposure control module inside the image signal processor; Based on the automatic exposure control module, the actual brightness of the image data is calculated according to the preset exposure target to obtain the corresponding deviation data. Obtain the preset exposure parameter adjustment strategy; Based on the deviation data, the exposure parameters are adjusted using the exposure parameter adjustment strategy to obtain the corresponding adjusted exposure parameters.

7. The image processing method according to claim 1, characterized in that, After the step of re-acquiring image data based on the target image sensor and adjusting the exposure parameters to obtain the corresponding target image, the method further includes: The target image data is subjected to color correction processing to obtain the corresponding first image data; The first image data is subjected to noise reduction processing to obtain the corresponding second image data; The second image data is subjected to image enhancement processing to obtain the corresponding third image data; The third image data is then processed for output.

8. An image processing apparatus, characterized in that, include: The first processing module is used to collect the digital signal corresponding to the light intensity of the current environment and obtain the target light level corresponding to the digital signal; The calculation module is used to calculate the target illumination level based on a preset strategy table to obtain the corresponding initial exposure value and initial gain value. The second processing module is used to write the register configuration one by one according to the preset image sensor initialization register configuration sequence, and skip the operation of setting the specified registers related to image output, so as to obtain the image sensor in standby state; The writing module is used to write the initial exposure value into the exposure control register of the image sensor, and to write the initial gain value into the gain control register of the image sensor; The configuration module is used to configure the specified register to obtain the initialized target image sensor, and to receive the image data output by the target image sensor; The generation module is used to perform brightness statistics and analysis on the image data based on the preset automatic exposure control module, and generate corresponding exposure adjustment parameters; The acquisition module is used to perform image data reacquisition processing based on the target image sensor and according to the adjusted exposure parameters to obtain the corresponding target image data.

9. A computer device, characterized in that, The method includes a memory and a processor, wherein the memory stores computer-readable instructions, and the processor executes the computer-readable instructions to implement the steps of the image processing method as described in any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer-readable instructions, which, when executed by a processor, implement the steps of the image processing method as described in any one of claims 1 to 7.