WO2020113833A1 - Image exposure and gain adjusting method, imaging apparatus and vehicle - Google Patents

Image exposure and gain adjusting method, imaging apparatus and vehicle Download PDF

Info

Publication number
WO2020113833A1
WO2020113833A1 PCT/CN2019/077118 CN2019077118W WO2020113833A1 WO 2020113833 A1 WO2020113833 A1 WO 2020113833A1 CN 2019077118 W CN2019077118 W CN 2019077118W WO 2020113833 A1 WO2020113833 A1 WO 2020113833A1
Authority
WO
WIPO (PCT)
Prior art keywords
interest
image
region
current frame
frame image
Prior art date
Application number
PCT/CN2019/077118
Other languages
French (fr)
Chinese (zh)
Inventor
张瑜
Original Assignee
北京图森未来科技有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 北京图森未来科技有限公司 filed Critical 北京图森未来科技有限公司
Publication of WO2020113833A1 publication Critical patent/WO2020113833A1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/70Circuitry for compensating brightness variation in the scene
    • H04N23/73Circuitry for compensating brightness variation in the scene by influencing the exposure time
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/70Circuitry for compensating brightness variation in the scene
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/70Circuitry for compensating brightness variation in the scene
    • H04N23/76Circuitry for compensating brightness variation in the scene by influencing the image signals

Definitions

  • the present application relates to the field of image processing technology, and in particular, to an image exposure and gain adjustment method, an imaging device, and a vehicle.
  • the basis for adjusting the exposure duration and gain value is the brightness value of the current image acquired by the imaging device.
  • the imaging equipment may not pay attention to the green belts, buildings and other elements beside the road, but focus on the vehicles and pedestrians in front of them. Therefore, the imaging device can set these positions of interest as regions of interest (ROI, Region Of Interest).
  • ROI regions of interest
  • the region of interest may be different for each frame of image, which requires the imaging device to expose the image to obtain higher image quality.
  • the imaging device In the practical application of images, it is not only necessary for the imaging device to obtain higher quality images, but also for the imaging device to be able to quickly respond to the setting of the region of interest, and to quickly calculate the brightness value of the region of interest, so as to quickly reach the exposure time of the imaging device
  • the purpose of the gain value At present, how to quickly adjust the image exposure and gain value has become an urgent problem to be solved.
  • the embodiments of the present application provide an image exposure and gain adjustment method, imaging device, and vehicle that overcome the above problems or at least partially solve the above problems.
  • a method for adjusting image exposure and gain including:
  • the collection of the next frame image is adjusted.
  • the non-critical transmission duration is the duration of the frame blanking area of the current frame image or the transmission duration of the last few lines of the current frame image.
  • the image exposure and gain adjustment method further includes:
  • the determination of the brightness value of the region of interest of the current frame image within the non-critical transmission duration of the current frame image where the exposure instruction is obtained includes:
  • the brightness value of the region of interest is calculated according to the range covered by the region of interest in the current frame image.
  • the image exposure and gain adjustment method further includes:
  • the determination of the brightness value of the region of interest of the current frame image within the non-critical transmission duration of the current frame image where the exposure instruction is obtained includes:
  • the exposure instruction of the region of interest of the image is obtained within the transmission duration of the last lines of the current frame image, then within the frame blanking time of the current frame image, according to the coverage of the region of interest in the current frame image
  • the range counts the brightness value of the region of interest.
  • the calculating the brightness value of the region of interest according to the range covered by the region of interest in the current frame image includes:
  • the range covered by the region of interest is within any image partition, it is determined that the brightness value of the region of interest is equal to the brightness value of the image partition corresponding to the region of interest.
  • the image exposure and gain adjustment method further includes:
  • the brightness value of the image partition that overlaps with the region of interest is counted.
  • the calculating the brightness value of the region of interest according to the range covered by the region of interest in the current frame image includes:
  • the region of interest spans multiple image partitions, determine the area of the region of interest, and calculate the weighted brightness value of the overlapping part of the region of interest and each image partition separately;
  • the sum of the products is divided by the area of the region of interest to obtain the brightness value of the region of interest.
  • the image exposure and gain adjustment method further includes:
  • the brightness value of the image partition that overlaps with the region of interest is counted.
  • the separately calculating the weighted brightness value of the overlapping part of the region of interest and each image partition includes:
  • an imaging device including: an image sensor and a processor
  • the image sensor is used for image acquisition to obtain the current frame image
  • the processor is used to obtain the exposure instruction of the region of interest of the image; determine the brightness value of the region of interest of the current frame image within the non-critical transmission duration of the current frame image where the exposure instruction is obtained; according to the The brightness value of the region of interest of the current frame image determines the exposure duration and gain value of the next frame image; according to the determined exposure duration and gain value of the next frame image, the image sensor is controlled to adjust the collection of the next frame image.
  • the non-critical transmission duration used in the processor is the duration of the frame blanking area of the current frame image or the transmission duration of the last few lines of the current frame image.
  • the processor is further used to: determine the time of obtaining the exposure instruction of the region of interest of the image; the processor is specifically used to: locate the time of obtaining the exposure instruction of the region of interest of the image Before the transmission duration of the last lines of the current frame image starts, within the duration of the frame blanking area of the current frame image or within the transmission duration of the last lines of the current frame image, according to the range covered by the region of interest in the current frame image The brightness value of the region of interest.
  • the processor is further used to: determine the time of obtaining the exposure instruction of the region of interest of the image; the processor is specifically used: if the time of obtaining the exposure instruction of the region of interest of the image is located at In the duration of the last lines of the current frame image, within the duration of the frame blanking area of the current frame image, the brightness value of the region of interest is counted according to the range covered by the region of interest in the current frame image.
  • the processor is further specifically configured to: partition the current frame image to form a multi-row and multi-column image partition; determine the range covered by the region of interest in the current frame image; When the range covered by the area is inside any image partition, it is determined that the brightness value of the region of interest is equal to the brightness value of the image partition corresponding to the region of interest.
  • the processor is further configured to: separately calculate the brightness value of each image partition; or according to the range covered by the region of interest in the current frame of the image, count the areas that overlap with the region of interest The brightness value of the image partition.
  • the processor is further specifically configured to: partition the current frame image to form a multi-row and multi-column image partition; determine the range covered by the region of interest in the current frame image; When the area covered by the area spans multiple image partitions, determine the area of the area of interest, and calculate the weighted brightness value of the overlapping part of the area of interest and each image partition; calculate the weighted brightness value of each overlapped part separately
  • the product of the area of the image partitions of and the sum of the products is obtained; the sum of the products is divided by the area of the region of interest to obtain the brightness value of the region of interest.
  • the processor is further configured to: separately calculate the brightness value of each image partition; or according to the range covered by the region of interest in the current frame of the image, count the areas that overlap with the region of interest The brightness value of the image partition.
  • the processor is further specifically used to: determine the overlapping area of the region of interest and each image partition; calculate the product of the brightness value of each image partition and the overlapping area of each image partition ; Divide each product by the corresponding image partition area to obtain the weighted brightness value of the overlapping part of the region of interest and each image partition.
  • the processor is a field programmable gate array.
  • the imaging device including: an image sensor and a processor;
  • the image sensor is used for image acquisition to obtain the current frame image
  • the processor is used to obtain the exposure instruction of the region of interest of the image; determine the brightness value of the region of interest of the current frame image within the non-critical transmission duration of the current frame image where the exposure instruction is obtained; according to the The brightness value of the region of interest of the current frame image determines the exposure duration and gain value of the next frame image; and controls the image sensor to adjust the acquisition of the next frame image according to the determined exposure duration and gain value of the next frame image .
  • the present application relates to a computer-readable storage medium on which computer instructions are stored.
  • a method for adjusting image exposure and gain is implemented. The method includes:
  • the collection of the next frame image is adjusted.
  • the above image exposure and gain adjustment method, imaging device, and vehicle provided by the embodiments of the present application first obtain the exposure command of the region of interest of the image, and then determine the current frame within the non-critical transmission time of the current frame image where the exposure command is located The brightness value of the region of interest of the image, and then determine the exposure duration and gain value of the next frame of the image.
  • the embodiment of the present application calculates the brightness The process of processing is placed within the non-critical transmission time of the current frame image, and the time length of the current frame image is more effectively used, so that the exposure and gain of the image are adjusted one frame earlier than the existing technology.
  • the technical fields that need to acquire high-quality images at the fastest speed such as the field of autonomous driving
  • its significance is very far-reaching.
  • FIG. 1 is a flowchart of a method for adjusting image exposure and gain provided by an embodiment of the present application
  • FIG. 2 is a schematic diagram of an example of a method for adjusting image exposure and gain provided by an embodiment of the present application
  • 3A is a flowchart of calculating a luminance value of a region of interest provided by an embodiment of the present application
  • FIG. 3B is a flowchart of calculating another region of interest brightness value provided by an embodiment of the present application.
  • FIG. 4 is a schematic diagram of image partitioning provided by an embodiment of the present application.
  • FIG. 5 is a schematic diagram of a region of interest provided by an embodiment of this application.
  • FIG. 6 is a schematic diagram of another region of interest provided by an embodiment of this application.
  • FIG. 7 is a schematic diagram of a discontinuous region of interest provided by an embodiment of this application.
  • FIG. 8 is a schematic diagram of another discontinuous region of interest provided by an embodiment of this application.
  • FIG. 9 is a schematic structural diagram of an imaging device provided by an embodiment of the present application.
  • F t0 , F t1 and F t2 are now defined as the video frames of the image at t 0 , t 1 and t 2 respectively.
  • the brightness statistics of the region of interest and the adjustment of exposure time and gain value are divided into the following steps:
  • the imaging device obtains the exposure instruction of the region of interest.
  • the imaging device starts to count the brightness of the region of interest, calculates the brightness value of the region of interest within the duration of the F t1 frame image, and determines the exposure duration and gain of the next frame image, that is, the F t2 frame image value.
  • the imaging device starts to adjust the exposure duration and gain value for the acquisition of the F t2 frame image.
  • the above steps often have the following problems: Since the image has been output before the F t0 frame, the F t0 frame image is not used for brightness statistics, only the brightness of the F t1 frame image duration Statistics, relatively speaking, imaging equipment can not obtain high-quality images at the fastest speed.
  • the method for adjusting the image exposure and gain provided by the embodiments of the present application, the flow of which is shown in FIG. 1 and includes the following steps:
  • S13 Determine the exposure duration and gain value of the next frame image according to the brightness value of the region of interest of the current frame image.
  • the non-critical transmission duration of the current frame image in step S12 may be, for example, the duration of the frame blanking area of the current frame image, or the transmission duration of the last several lines of the current frame image, or other non-critical transmission durations that may be utilized.
  • the specific duration of the non-critical transmission time should be further determined according to the timing of the exposure instruction of the region of interest to obtain the image.
  • the duration for each image frame, includes effective data duration and frame blanking area duration.
  • the effective data duration is used to carry the effective data of the image.
  • the content of the last few lines of data in an image usually has little effect on the overall image quality and display effect. Therefore, when calculating the brightness of the region of interest, the contents of these lines of data can be ignored, and then the brightness value of the region of interest can be calculated within the transmission duration of the last lines of the current frame image.
  • the duration of the frame blanking zone is after the duration of valid data, and does not carry any valid data. Among them, valid data is output from the upper left corner of the image, from left to right, until the entire line is transmitted, and then re-output from the leftmost end of the next line until the entire image is output.
  • the effective data of the image is output and the effective data of the next frame of the image has not been output, there is a time interval between two adjacent frame images. This time interval is usually referred to as the frame blanking zone duration and frame blanking zone duration. Is to prepare for the image output of the next frame.
  • the duration of the last few lines of the current frame image can be preset, and the duration of the last few lines can be set to 2 to 5 lines, for example.
  • the actual duration needs to be calculated according to the brightness value of the region of interest in the current frame To decide.
  • the calculation time of the luminance value of the region of interest in the current frame is about 200 clocks.
  • the specific length of the above clocks can be understood as: when receiving image pixels, each received pixel counts as one clock. Based on this, the duration of 200 clocks is the duration of receiving 200 image pixels.
  • the range of the region of interest may be set in advance (for example, setting a range that meets certain conditions as the region of interest, or directly setting a specific range), or it may be determined by obtaining an exposure instruction of the region of interest. No matter which way the range of the region of interest is determined, the size of the range of the region of interest for each frame of image may be different.
  • the embodiment of the present application determines the brightness value of the region of interest of the current frame image by using the non-critical transmission duration of the current frame image. Calculating the brightness value of the region of interest within the non-critical transmission time of the current frame image can not only not affect the transmission of the normal image frame, but also can effectively use the interval time in the image transmission process, responding to the upper system with a faster speed.
  • the exposure instruction of the region of interest is of great significance to the upper-level system (such as: automatic driving system).
  • the exposure instruction of the region of interest when the exposure instruction of the region of interest is acquired, before the transmission duration of the last lines of the current frame image begins, you can choose to be within the frame blanking period of the current frame image where the exposure instruction is acquired, or choose between Within the transmission duration of the last lines of the current frame image, the brightness value of the region of interest is counted according to the range covered by the region of interest in the current frame image.
  • the moment when the exposure instruction of the region of interest is obtained is located in the transmission time of the last lines of the current frame image, because the transmission time of the last lines of the current frame image cannot be used to calculate the luminance value of the region of interest. Therefore, the brightness value of the region of interest can be calculated according to the range covered by the region of interest in the current frame image within the duration of the frame blanking region of the current frame image where the exposure instruction is acquired.
  • F t0 and F t1 are the video frames of the image at t 0 and t 1 respectively.
  • the specific adjustment process is as follows:
  • the imaging device obtains the exposure instruction of the region of interest.
  • the luminance statistics start region of interest, calculates the luminance value of the region of interest, and determines the next frame, i.e., F t1 frame image exposure duration and gain value.
  • the imaging device starts to adjust the exposure duration and gain value for the collection of F t1 frame images.
  • the calculation method of the luminance value of the region of interest is also divided into the following two cases:
  • the first method includes the following steps:
  • S312 Determine the range covered by the region of interest in the current frame image.
  • the second method includes the following steps:
  • the 1920 ⁇ 1920 resolution image is divided into 16 ⁇ 16 image partitions.
  • the brightness value of each image partition Ni_j is counted in sequence, named Li_j , where i is the label in the horizontal direction of the image, j is the label in the vertical direction of the image; i, j are greater than or equal to 1 , Less than or equal to 16; the brightness value of the region of interest is L ROI .
  • the imaging device receives an exposure instruction to set the region of interest at this time, then according to the range covered by the region of interest, it can be divided into the following two situations.
  • the region of interest is a rectangular region:
  • the region of interest spans multiple image partitions (shown in FIG. 6 is only one of multiple cross-image partition scenarios, and the embodiments of the present application do not limit the image partitions The number of and the location of the partitions, etc., the calculation method is similar in other cases), the region of interest is a rectangular region spanning 9 image partitions.
  • the area of the overlapped portion 9 of the regions of interest between images and nine partitions are: M i-1_j-1, M i-1_j, M i-1_j + 1, M i_j-1, M i_j, M i_j + 1 , Mi +1_j-1 , Mi +1_j , Mi +1_j+1 ; in this example, the area of the 9 overlapping parts can be calculated by taking the product of the length and width of the occupied area in pixels.
  • the weighted brightness values of the above 9 overlapping parts are:
  • the brightness of each image section is: L i-1_j-1, L i-1_j, L i-1_j + 1, L i_j-1, L i_j, L i_j + 1, L i + 1_j-1, L i +1_j , Li +1_j+1
  • the area of each image partition is M n (M n is known when dividing the area, and its area is the product of the length and width in pixels of the image partition).
  • M ROI is known when dividing the area, and its area is the product of the length and width in pixels of the image partition).
  • the area of the area of interest is defined as M ROI
  • the brightness of the area of interest is defined as L ROI , then:
  • the brightness value of the region of interest can be calculated.
  • the embodiment of the present application uses area as the weight of the brightness value of each overlapping portion, but the present application is not limited to this method, and the weight value may also be determined by other methods, which is not limited in the embodiment of the present application.
  • the calculation method of the luminance value of the region of interest is described by taking the region of interest as a continuous region as an example. If the region of interest is discontinuous, the discontinuous parts are calculated according to the foregoing method respectively , And then calculate the weighted average as a whole. For the process of weighted average calculation, see the following methods:
  • the region of interest is composed of two discontinuous ROI1 regions and ROI2 regions, and the ROI1 region and ROI2 region are respectively located in any image partition.
  • the calculation method in the first case is used to obtain the brightness values L ROI1 and L ROI2 of the ROI1 and ROI2 areas, respectively.
  • the calculation steps please refer to the calculation process in the first case above, which will not be repeated here.
  • the weights m and n given in advance are obtained by weighting the brightness value of the area of interest
  • the weights m and n are preset, and may be, for example, the percentage probability that the ROI1 area and the ROI2 area receive attention. For ease of understanding, the following will illustrate with an example:
  • the region of interest is composed of two discrete ROI3 regions and ROI4 regions, and the ROI3 region and the ROI4 region respectively span different image partitions.
  • the calculation method in the second case is used to obtain the brightness values L ROI3 and L ROI4 of the ROI3 region and the ROI4 region, respectively. For the specific calculation steps, see the calculation in the second case above The process will not be repeated here.
  • the weights m and n given in advance are obtained by weighted calculation to obtain the brightness value of the area of interest
  • the weights m and n are preset, and may be, for example, the percentage probability that the ROI3 region and the ROI4 region receive attention. For ease of understanding, the following will illustrate with an example:
  • the region of interest is composed of two discontinuous regions as an example.
  • the region of interest may also be composed of any discontinuous regions.
  • the calculation process is the same as that in the above two cases. The calculation process is similar and will not be repeated here.
  • the brightness value of the image partition needs to be calculated, which can be processed in the following two ways:
  • the first method is to separately count the brightness value of each image partition.
  • the brightness value of each 16 ⁇ 16 image partition can be calculated in sequence through a preset computer program when the effective data transmission of the current frame is completed, and then the related brightness value can be calculated. If the brightness calculation is performed within the duration of the last few lines of the current frame image, the data of the last few lines is set as the default data, thereby calculating the brightness of the partition where the last few lines are located.
  • the second method is to calculate the brightness value of the image partition that overlaps with the region of interest according to the range covered by the region of interest in the current frame image.
  • the brightness value of the image partition involved in the region of interest may be calculated through a preset computer program.
  • the difference from the previous method is that only the brightness value of each image partition that overlaps with the region of interest is calculated.
  • the data of the last few rows is set as the default data, so as to complete the calculation of the brightness of the partition where the last few rows are located.
  • embodiments of the present application also provide an imaging device and a vehicle. Since the principles of the problems solved by these imaging devices and vehicles are similar to the aforementioned image exposure and gain adjustment methods, the implementation of the imaging devices and vehicles can be referred to the implementation of the aforementioned methods, and the repetitions will not be repeated.
  • an embodiment of the present application provides an imaging device, including: an image sensor 91 and a processor 92.
  • the image sensor 91 is used for image acquisition to obtain the current frame image.
  • the processor 92 is used to obtain the exposure instruction of the region of interest of the image; determine the brightness value of the region of interest of the current frame image within the non-critical transmission time of the current frame image where the exposure instruction is obtained; according to the sense of the current frame image The brightness value of the region of interest determines the exposure duration and gain value of the next frame image; according to the determined exposure duration and gain value of the next frame image, the image sensor is controlled to adjust the collection of the next frame image. .
  • the non-critical transmission duration adopted in the processor 92 is the duration of the frame blanking area of the current frame image or the transmission duration of the last few lines of the current frame image.
  • the processor 92 is further configured to: determine the time of the exposure instruction of the region of interest to obtain the image.
  • the processor 92 is specifically configured to: within the duration of the frame blanking area of the current frame image or the last number of the current frame image when the exposure instruction of the region of interest of the image is obtained before the start of the last line transmission duration of the current frame image Within the transmission time of the line, the brightness value of the region of interest is calculated according to the range covered by the region of interest in the current frame image.
  • the processor 92 is further configured to: determine the time of the exposure instruction of the region of interest to obtain the image.
  • the processor 92 is specifically configured to: if the time of obtaining the exposure instruction of the region of interest of the image is within the transmission duration of the last several lines of the current frame image, within the frame blanking time duration of the current frame image, according to the current frame image The area covered by the region of interest counts the brightness value of the region of interest.
  • the processor 92 is further specifically configured to: partition the current frame image to form a multi-row and multi-column image partition; determine the range covered by the region of interest in the current frame image; cover the region of interest When the range of is within any image partition, determine that the brightness value of the region of interest is equal to the brightness value of the image partition corresponding to the region of interest.
  • the processor 92 is further configured to: separately calculate the brightness value of each image partition; or according to the range covered by the region of interest in the image of the current frame, calculate the statistics of the image partition that overlaps with the region of interest Brightness value.
  • the processor 92 is further specifically configured to: partition the current frame image to form a multi-row and multi-column image partition; determine the range covered by the region of interest in the current frame image; cover the region of interest When the range of the image spans multiple image partitions, determine the area of the region of interest, and calculate the weighted brightness value of the overlapping part of the region of interest and each image partition; calculate the weighted brightness value of each overlapping part and the corresponding image partition Multiply the area and get the sum of the products; divide the sum of the products by the area of the area of interest to get the brightness value of the area of interest.
  • the processor 92 is further configured to: separately calculate the brightness value of each image partition; or according to the range covered by the region of interest in the current frame image, calculate the statistics of the image partitions that overlap with the region of interest Brightness value.
  • the processor 92 is further specifically configured to: determine the overlapping area of the region of interest and each image partition; calculate the product of the brightness value of each image partition and the overlapping area of each image partition; Divide each product by the corresponding image partition area to obtain the weighted brightness value of the overlapping part of the region of interest and each image partition.
  • the processor 92 is a field programmable gate array.
  • a vehicle provided by an embodiment of the present application, wherein the vehicle is provided with the imaging device corresponding to FIG. 9 described above.
  • Embodiments of the present application also provide a computer-readable storage medium on which computer instructions are stored, and when the instructions are executed by a processor, the above-mentioned image exposure and gain adjustment method is implemented.
  • the foregoing computer-readable storage media include various non-volatile storage media, including but not limited to optical disks, ROM, EEPROM, FLASH memories, various types of magnetic disks, and so on.
  • the above image exposure and gain adjustment method, imaging device, and vehicle provided by the embodiments of the present application first obtain the exposure command of the region of interest of the image, and then determine the current frame within the non-critical transmission time of the current frame image where the exposure command is located The brightness value of the region of interest of the image, and then determine the exposure duration and gain value of the next frame of the image.
  • the embodiment of the present application calculates the brightness The process of processing is placed within the non-critical transmission time of the current frame image, and the time length of the current frame image is more effectively used, so that the exposure and gain of the image are adjusted one frame earlier than the existing technology.
  • the technical fields that need to acquire high-quality images at the fastest speed such as the field of autonomous driving
  • its significance is very far-reaching.
  • each functional unit in each embodiment of the present application may be integrated into one processing module, or each unit may exist alone physically, or two or more units may be integrated into one module.
  • the above integrated modules may be implemented in the form of hardware or software function modules. If the integrated module is implemented in the form of a software functional module and sold or used as an independent product, it may also be stored in a computer-readable storage medium.
  • the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware. Moreover, the present application may take the form of a computer program product implemented on one or more computer usable storage media (including but not limited to disk storage and optical storage, etc.) containing computer usable program code.
  • a computer usable storage media including but not limited to disk storage and optical storage, etc.
  • These computer program instructions may also be stored in a computer-readable memory that can guide a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture including an instruction device, the instructions
  • the device implements the functions specified in one block or multiple blocks of the flowchart one flow or multiple flows and/or block diagrams.
  • These computer program instructions can also be loaded onto a computer or other programmable data processing device, so that a series of operating steps are performed on the computer or other programmable device to produce computer-implemented processing, which is executed on the computer or other programmable device
  • the instructions provide steps for implementing the functions specified in one block or multiple blocks of the flowchart one flow or multiple flows and/or block diagrams.

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Studio Devices (AREA)

Abstract

Disclosed in the present application are an image exposure and gain adjusting method, an imaging apparatus and a vehicle. The method comprises: acquiring an exposure command for a region of interest of an image; determining a brightness of the region of interest of the current image in a non-critical transmission period of the current image in which the exposure command is acquired; determining an exposure duration and a gain for the next image according to the brightness of the region of interest of the current image; adjusting the acquisition of the next image according to the determined exposure duration and the gain of the next image. The present application can quickly adjust the exposure and gain of an image.

Description

图像曝光和增益的调整方法、成像设备及车辆Image exposure and gain adjustment method, imaging equipment and vehicle
本申请要求在2018年12月5日提交中国专利局、申请号为201811481568.4、申请名称为“图像曝光和增益的调整方法、成像设备及车辆”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application requires the priority of the Chinese patent application filed on December 5, 2018 in the Chinese Patent Office with the application number 201811481568.4 and the application titled "Image Exposure and Gain Adjustment Methods, Imaging Equipment and Vehicles", the entire contents of which are cited by reference Incorporated in this application.
技术领域Technical field
本申请涉及图像处理技术领域,特别涉及一种图像曝光和增益的调整方法、成像设备及车辆。The present application relates to the field of image processing technology, and in particular, to an image exposure and gain adjustment method, an imaging device, and a vehicle.
背景技术Background technique
随着智能工业、机器人避障、即时定位与地图构建技术(SLAM,Simultaneous Localization And Mapping)和无人驾驶技术的发展,成像设备在这些领域内被广泛使用。With the development of smart industry, robot obstacle avoidance, real-time localization and map construction technology (SLAM, Simultaneous Localization And Mapping) and unmanned driving technology, imaging equipment is widely used in these fields.
为了使成像设备获取更高质量的图像,合理的设置曝光时长和增益值对成像设备来说非常重要。而调节曝光时长和增益值的依据,就是成像设备所获取的当前图像的亮度值。对于一幅完整的图像来说,它包含的信息量非常大,而实际需要关注的可能只是图像中的某一部分。比如:在汽车自动驾驶过程中,成像设备对公路旁边的绿化带、建筑物等元素可以不予关注,而对前方的车辆以及行人等元素重点关注。因此成像设备可以设置这些被关注的位置为感兴趣区域(ROI,Region Of Interest)。另外,每一帧图像的感兴趣区域可能都不相同,就需要成像设备对图像进行针对性的曝光,以获得更高的图像质量。In order for the imaging device to obtain a higher quality image, it is very important for the imaging device to set the exposure duration and the gain value reasonably. The basis for adjusting the exposure duration and gain value is the brightness value of the current image acquired by the imaging device. For a complete image, the amount of information it contains is very large, but the actual concern may only be a part of the image. For example, in the process of auto driving, the imaging equipment may not pay attention to the green belts, buildings and other elements beside the road, but focus on the vehicles and pedestrians in front of them. Therefore, the imaging device can set these positions of interest as regions of interest (ROI, Region Of Interest). In addition, the region of interest may be different for each frame of image, which requires the imaging device to expose the image to obtain higher image quality.
在图像的实际应用中,不仅需要成像设备获得更高质量的图像,还需要成像设备能够快速响应感兴趣区域设置,并快速统计感兴趣区域的亮度值,以便快速达到调节成像设备的曝光时长和增益值的目的。目前,如何快捷地进行图像曝光和增益值的调整,成为了一个亟待解决的问题。In the practical application of images, it is not only necessary for the imaging device to obtain higher quality images, but also for the imaging device to be able to quickly respond to the setting of the region of interest, and to quickly calculate the brightness value of the region of interest, so as to quickly reach the exposure time of the imaging device The purpose of the gain value. At present, how to quickly adjust the image exposure and gain value has become an urgent problem to be solved.
发明内容Summary of the invention
鉴于现有技术中存在的技术缺陷和技术弊端,本申请实施例提供克服上述问题或者至少部分地解决上述问题的一种图像曝光和增益的调整方法、成像设备及车辆。In view of the technical defects and technical drawbacks in the prior art, the embodiments of the present application provide an image exposure and gain adjustment method, imaging device, and vehicle that overcome the above problems or at least partially solve the above problems.
作为本申请实施例的一个方面,涉及一种图像曝光和增益的调整方法,包括:As an aspect of embodiments of the present application, it relates to a method for adjusting image exposure and gain, including:
获得图像的感兴趣区域的曝光指令;Get the exposure instruction of the region of interest in the image
在获得所述曝光指令所在的当前帧图像的非关键传输时长内,确定当前帧图像的感兴趣区域的亮度值;Determine the brightness value of the region of interest of the current frame image within the non-critical transmission duration of the current frame image where the exposure instruction is obtained;
根据所述当前帧图像的感兴趣区域的亮度值,确定下一帧图像的曝光时长及增益值;Determine the exposure duration and gain value of the next frame image according to the brightness value of the region of interest of the current frame image;
根据确定出的下一帧图像的曝光时长及增益值对下一帧图像的采集进行调整。According to the determined exposure duration and gain value of the next frame image, the collection of the next frame image is adjusted.
在一个实施例中,所述非关键传输时长为当前帧图像的帧消隐区时长或者当前帧图像最后若干行的传输时长。In one embodiment, the non-critical transmission duration is the duration of the frame blanking area of the current frame image or the transmission duration of the last few lines of the current frame image.
在一个实施例中,该图像曝光和增益的调整方法,还包括:In one embodiment, the image exposure and gain adjustment method further includes:
确定获得图像的感兴趣区域的曝光指令的时刻;Determine the time of exposure instruction of the region of interest to obtain the image;
所述在获得所述曝光指令所在的当前帧图像的非关键传输时长内,确定当前帧图像的感兴趣区域的亮度值,包括:The determination of the brightness value of the region of interest of the current frame image within the non-critical transmission duration of the current frame image where the exposure instruction is obtained includes:
若获得图像的感兴趣区域的曝光指令的时刻位于所述当前帧图像最后若干行传输时长开始之前,则在当前帧图像的帧消隐区时长内或者当前帧图像最后若干行的传输时长内,根据当前帧图像中感兴趣区域所覆盖的范围统计出所述感兴趣区域的亮度值。If the time of obtaining the exposure instruction of the region of interest of the image is before the start of the transmission duration of the last lines of the current frame image, within the frame blanking duration of the current frame image or the transmission duration of the last lines of the current frame image, The brightness value of the region of interest is calculated according to the range covered by the region of interest in the current frame image.
在一个实施例中,该图像曝光和增益的调整方法,还包括:In one embodiment, the image exposure and gain adjustment method further includes:
确定获得图像的感兴趣区域的曝光指令的时刻;Determine the time of exposure instruction of the region of interest to obtain the image;
所述在获得所述曝光指令所在的当前帧图像的非关键传输时长内,确定当前帧图像的感兴趣区域的亮度值,包括:The determination of the brightness value of the region of interest of the current frame image within the non-critical transmission duration of the current frame image where the exposure instruction is obtained includes:
若获得图像的感兴趣区域的曝光指令的时刻位于所述当前帧图像最后若干行传输时长之中,则在当前帧图像的帧消隐区时长内,根据当前帧图像中感兴趣区域所覆盖的范围统计出所述感兴趣区域的亮度值。If the exposure instruction of the region of interest of the image is obtained within the transmission duration of the last lines of the current frame image, then within the frame blanking time of the current frame image, according to the coverage of the region of interest in the current frame image The range counts the brightness value of the region of interest.
在一个实施例中,所述根据当前帧图像中感兴趣区域所覆盖的范围统计出所述感兴趣区域的亮度值,包括:In one embodiment, the calculating the brightness value of the region of interest according to the range covered by the region of interest in the current frame image includes:
对当前帧图像进行分区,形成多行多列的图像分区;Partition the current frame image to form an image partition with multiple rows and columns;
确定当前帧图像中感兴趣区域所覆盖的范围;Determine the area covered by the region of interest in the current frame image;
若所述感兴趣区域所覆盖的范围处于任一图像分区内部,确定感兴趣区域的亮度值等于所述感兴趣区域所对应的图像分区的亮度值。If the range covered by the region of interest is within any image partition, it is determined that the brightness value of the region of interest is equal to the brightness value of the image partition corresponding to the region of interest.
在一个实施例中,该图像曝光和增益的调整方法,还包括:In one embodiment, the image exposure and gain adjustment method further includes:
分别统计每个图像分区的亮度值;或者Count the brightness values of each image partition separately; or
根据当前帧图像中感兴趣区域所覆盖的范围,统计与所述感兴趣区域存在重叠部分的图像分区的亮度值。According to the range covered by the region of interest in the current frame image, the brightness value of the image partition that overlaps with the region of interest is counted.
在一个实施例中,所述根据当前帧图像中感兴趣区域所覆盖的范围统计出所述感兴趣区域的亮度值,包括:In one embodiment, the calculating the brightness value of the region of interest according to the range covered by the region of interest in the current frame image includes:
对当前帧图像进行分区,形成多行多列的图像分区;Partition the current frame image to form an image partition with multiple rows and columns;
确定当前帧图像中感兴趣区域所覆盖的范围;Determine the area covered by the region of interest in the current frame image;
若所述感兴趣区域所覆盖的范围跨多个图像分区,确定感兴趣区域的面积,并分别计算感兴趣区域与每个图像分区的重叠部分的加权亮度值;If the area covered by the region of interest spans multiple image partitions, determine the area of the region of interest, and calculate the weighted brightness value of the overlapping part of the region of interest and each image partition separately;
分别计算各重叠部分的加权亮度值与各自对应的图像分区面积的乘积,并得到所述乘积之和;Calculate the product of the weighted brightness value of each overlapping part and the area of the corresponding image partition, and obtain the sum of the products;
将所述乘积之和除以所述感兴趣区域的面积,得到所述感兴趣区域的亮度值。The sum of the products is divided by the area of the region of interest to obtain the brightness value of the region of interest.
在一个实施例中,该图像曝光和增益的调整方法,还包括:In one embodiment, the image exposure and gain adjustment method further includes:
分别统计每个图像分区的亮度值;或者Count the brightness values of each image partition separately; or
根据当前帧图像中感兴趣区域所覆盖的范围,统计与所述感兴趣区域存在重叠部分的图像分区的亮度值。According to the range covered by the region of interest in the current frame image, the brightness value of the image partition that overlaps with the region of interest is counted.
在一个实施例中,所述分别计算感兴趣区域与每个图像分区的重叠部分的加权亮度值,包括:In one embodiment, the separately calculating the weighted brightness value of the overlapping part of the region of interest and each image partition includes:
确定感兴趣区域与每个图像分区的重叠部分面积;Determine the area of overlap between the region of interest and each image partition;
分别计算各个图像分区的亮度值与各个图像分区各自对应的重叠部分面积的乘积;Calculate the product of the brightness value of each image partition and the area of the overlapping part corresponding to each image partition;
将各乘积分别除以各自对应的图像分区面积,得到感兴趣区域与每个图像分区的重叠部分的加权亮度值。Divide each product by the corresponding image partition area to obtain the weighted brightness value of the overlapping part of the region of interest and each image partition.
作为本申请实施例的另一个方面,涉及一种成像设备,包括:图像传感器和处理器;As another aspect of the embodiments of the present application, it relates to an imaging device, including: an image sensor and a processor;
所述图像传感器,用于进行图像采集,得到当前帧图像;The image sensor is used for image acquisition to obtain the current frame image;
所述处理器,用于获得图像的感兴趣区域的曝光指令;在获得所述曝光指令所在的当前帧图像的非关键传输时长内,确定当前帧图像的感兴趣区域的亮度值;根据所述当前帧图像的感兴趣区域的亮度值,确定下一帧图像的曝光时长及增益值;根据确定出的下一帧图像的曝光时长及增益值控制图像传感器对下一帧图像的采集进行调整。The processor is used to obtain the exposure instruction of the region of interest of the image; determine the brightness value of the region of interest of the current frame image within the non-critical transmission duration of the current frame image where the exposure instruction is obtained; according to the The brightness value of the region of interest of the current frame image determines the exposure duration and gain value of the next frame image; according to the determined exposure duration and gain value of the next frame image, the image sensor is controlled to adjust the collection of the next frame image.
在一个实施例中,所述处理器中所采用的非关键传输时长为当前帧图像的帧消隐区时长或者当前帧图像最后若干行的传输时长。In one embodiment, the non-critical transmission duration used in the processor is the duration of the frame blanking area of the current frame image or the transmission duration of the last few lines of the current frame image.
在一个实施例中,所述处理器,还用于:确定获得图像的感兴趣区域的曝光指令的时刻;所述处理器,具体用于:在获得图像的感兴趣区域的曝光指令的时刻位于所述当前帧图像最后若干行传输时长开始之前时,在当前帧图像的帧消隐区时长内或者当前帧图像最后若干行的传输时长内,根据当前帧图像中感兴趣区域所覆盖的范围统计出所述感兴趣区域的亮度值。In one embodiment, the processor is further used to: determine the time of obtaining the exposure instruction of the region of interest of the image; the processor is specifically used to: locate the time of obtaining the exposure instruction of the region of interest of the image Before the transmission duration of the last lines of the current frame image starts, within the duration of the frame blanking area of the current frame image or within the transmission duration of the last lines of the current frame image, according to the range covered by the region of interest in the current frame image The brightness value of the region of interest.
在一个实施例中,所述处理器,还用于:确定获得图像的感兴趣区域的曝光指令的时刻;所述处理器,具体用于:若获得图像的感兴趣区域的曝光指令的时刻位于所述当前帧图像最后若干行传输时长之中,则在当前帧图像的帧消隐区时长内,根据当前帧图像中感兴趣区域所覆盖的范围统计出所述感兴趣区域的亮度值。In one embodiment, the processor is further used to: determine the time of obtaining the exposure instruction of the region of interest of the image; the processor is specifically used: if the time of obtaining the exposure instruction of the region of interest of the image is located at In the duration of the last lines of the current frame image, within the duration of the frame blanking area of the current frame image, the brightness value of the region of interest is counted according to the range covered by the region of interest in the current frame image.
在一个实施例中,所述处理器,具体还用于:对当前帧图像进行分区,形成多行多列的图像分区;确定当前帧图像中感兴趣区域所覆盖的范围;在所述感兴趣区域所覆盖的范围处于任一图像分区内部时,确定感兴趣区域的亮度值等于所述感兴趣区域所对应的图像分区的亮度值。In one embodiment, the processor is further specifically configured to: partition the current frame image to form a multi-row and multi-column image partition; determine the range covered by the region of interest in the current frame image; When the range covered by the area is inside any image partition, it is determined that the brightness value of the region of interest is equal to the brightness value of the image partition corresponding to the region of interest.
在一个实施例中,所述处理器,还用于:分别统计每个图像分区的亮度值;或者根据当前帧图像中感兴趣区域所覆盖的范围,统计与所述感兴趣区域存在重叠部分的图像分区的亮度值。In one embodiment, the processor is further configured to: separately calculate the brightness value of each image partition; or according to the range covered by the region of interest in the current frame of the image, count the areas that overlap with the region of interest The brightness value of the image partition.
在一个实施例中,所述处理器,具体还用于:对当前帧图像进行分区,形成多行多列的图像分区;确定当前帧图像中感兴趣区域所覆盖的范围;在所述感兴趣区域所覆盖的范围跨多个图像分区时,确定感兴趣区域的面积,并分别计算感兴趣区域与每个图像分区的重叠部分的加权亮度值;分别计算各重叠部分的加权亮度值与各自对应的图像分区面积的乘积,并得到所述乘积之和;将所述乘积之和除以所述感兴趣区域的面积,得到所述感兴趣区域的亮度值。In one embodiment, the processor is further specifically configured to: partition the current frame image to form a multi-row and multi-column image partition; determine the range covered by the region of interest in the current frame image; When the area covered by the area spans multiple image partitions, determine the area of the area of interest, and calculate the weighted brightness value of the overlapping part of the area of interest and each image partition; calculate the weighted brightness value of each overlapped part separately The product of the area of the image partitions of and the sum of the products is obtained; the sum of the products is divided by the area of the region of interest to obtain the brightness value of the region of interest.
在一个实施例中,所述处理器,还用于:分别统计每个图像分区的亮度值;或者根据当前帧图像中感兴趣区域所覆盖的范围,统计与所述感兴趣区域存在重叠部分的图像分区的亮度值。In one embodiment, the processor is further configured to: separately calculate the brightness value of each image partition; or according to the range covered by the region of interest in the current frame of the image, count the areas that overlap with the region of interest The brightness value of the image partition.
在一个实施例中,所述处理器,具体还用于:确定感兴趣区域与每个图像分区的重叠部分面积;分别计算各个图像分区的亮度值与各个图像分区各自对应的重叠部分面积的乘积;将各乘积分别除以各自对应的图像分区面积,得到感兴趣区域与每个图像分区的重叠部分的加权亮度值。In one embodiment, the processor is further specifically used to: determine the overlapping area of the region of interest and each image partition; calculate the product of the brightness value of each image partition and the overlapping area of each image partition ; Divide each product by the corresponding image partition area to obtain the weighted brightness value of the overlapping part of the region of interest and each image partition.
在一个实施例中,所述处理器为现场可编程门阵列。In one embodiment, the processor is a field programmable gate array.
作为本申请实施例的又一个方面,涉及一种车辆,所述车辆设置有上述的成像设备,该成像设备包括:图像传感器和处理器;As still another aspect of the embodiments of the present application, it relates to a vehicle provided with the above imaging device, the imaging device including: an image sensor and a processor;
所述图像传感器,用于进行图像采集,得到当前帧图像;The image sensor is used for image acquisition to obtain the current frame image;
所述处理器,用于获得图像的感兴趣区域的曝光指令;在获得所述曝光指令所在的当前帧图像的非关键传输时长内,确定当前帧图像的感兴趣区域的亮度值;根据所述当前帧图像的感兴趣区域的亮度值,确定下一帧图像的曝光时长及增益值;并根据确定出的下一帧图像的曝光时长及增益值控制图像传感器对下一帧图像的采集进行调整。The processor is used to obtain the exposure instruction of the region of interest of the image; determine the brightness value of the region of interest of the current frame image within the non-critical transmission duration of the current frame image where the exposure instruction is obtained; according to the The brightness value of the region of interest of the current frame image determines the exposure duration and gain value of the next frame image; and controls the image sensor to adjust the acquisition of the next frame image according to the determined exposure duration and gain value of the next frame image .
作为本申请实施例的再一个方面,涉及一种计算机可读存储介质,其上存储有计算机指令,该指令被处理器执行时实现图像曝光和增益的调整方法,该方法包括:As still another aspect of the embodiments of the present application, it relates to a computer-readable storage medium on which computer instructions are stored. When the instructions are executed by a processor, a method for adjusting image exposure and gain is implemented. The method includes:
获得图像的感兴趣区域的曝光指令;Get the exposure instruction of the region of interest of the image;
在获得所述曝光指令所在的当前帧图像的非关键传输时长内,确定当前帧图像的感兴 趣区域的亮度值;Within the non-critical transmission duration of the current frame image where the exposure instruction is obtained, determine the brightness value of the interest area of the current frame image;
根据所述当前帧图像的感兴趣区域的亮度值,确定下一帧图像的曝光时长及增益值;Determine the exposure duration and gain value of the next frame image according to the brightness value of the region of interest of the current frame image;
根据确定出的下一帧图像的曝光时长及增益值对下一帧图像的采集进行调整。According to the determined exposure duration and gain value of the next frame image, the collection of the next frame image is adjusted.
本申请实施例提供的上述图像曝光和增益的调整方法、成像设备及车辆,首先获得图像的感兴趣区域的曝光指令,然后在曝光指令所在的当前帧图像的非关键传输时长内,确定当前帧图像的感兴趣区域的亮度值,进而确定出下一帧图像的曝光时长及增益值。相对于现有技术中只能利用获取到的感兴趣区域的曝光指令所在当前帧图像的下一帧图像的时长来统计当前帧图像的感兴趣区域亮度值的做法,本申请实施例将亮度计算的过程,放在当前帧图像的非关键传输时长内进行处理,更有效地利用了当前帧图像的时长,从而相对于现有技术,提前了一帧的时长对图像曝光和增益进行调整,这对需要以最快的速度获取高质量图像的技术领域(如:自动驾驶领域)而言,其意义是非常深远的。The above image exposure and gain adjustment method, imaging device, and vehicle provided by the embodiments of the present application first obtain the exposure command of the region of interest of the image, and then determine the current frame within the non-critical transmission time of the current frame image where the exposure command is located The brightness value of the region of interest of the image, and then determine the exposure duration and gain value of the next frame of the image. In contrast to the practice in the prior art that only the duration of the next frame image of the current frame image where the exposure instruction of the obtained interest area is located can be used to count the brightness value of the interest area of the current frame image, the embodiment of the present application calculates the brightness The process of processing is placed within the non-critical transmission time of the current frame image, and the time length of the current frame image is more effectively used, so that the exposure and gain of the image are adjusted one frame earlier than the existing technology. For the technical fields that need to acquire high-quality images at the fastest speed (such as the field of autonomous driving), its significance is very far-reaching.
本申请的其它特征和优点将在随后的说明书中阐述,并且,部分地从说明书中变得显而易见,或者通过实施本申请而了解。本申请的目的和其他优点可通过在所写的说明书、权利要求书、以及附图中所特别指出的结构来实现和获得。Other features and advantages of the present application will be explained in the subsequent description, and partly become obvious from the description, or be understood by implementing the present application. The purpose and other advantages of the present application can be realized and obtained by the structures particularly pointed out in the written description, claims, and drawings.
下面通过附图和实施例,对本申请的技术方案做进一步的详细描述。The technical solutions of the present application will be further described in detail below through the accompanying drawings and embodiments.
附图说明BRIEF DESCRIPTION
附图用来提供对本申请的进一步理解,并且构成说明书的一部分,与本申请的实施例一起用于解释本申请,并不构成对本申请的限制。显而易见地,下面描述中的附图仅仅是本申请一些实施例,对于本领域普通技术人员而言,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。在附图中:The drawings are used to provide a further understanding of the present application, and constitute a part of the specification. They are used to explain the present application together with the embodiments of the present application, and do not constitute a limitation on the present application. Obviously, the drawings in the following description are only some embodiments of the present application. For those of ordinary skill in the art, without paying any creative work, other drawings can be obtained based on these drawings. In the drawings:
图1为本申请实施例提供的图像曝光和增益的调整方法的流程图;1 is a flowchart of a method for adjusting image exposure and gain provided by an embodiment of the present application;
图2为本申请实施例提供的图像曝光和增益的调整方法实例示意图;2 is a schematic diagram of an example of a method for adjusting image exposure and gain provided by an embodiment of the present application;
图3A为本申请实施例提供的一种感兴趣区域亮度值计算的流程图;3A is a flowchart of calculating a luminance value of a region of interest provided by an embodiment of the present application;
图3B为本申请实施例提供的又一种感兴趣区域亮度值计算的流程图;FIG. 3B is a flowchart of calculating another region of interest brightness value provided by an embodiment of the present application;
图4为本申请实施例提供的图像分区示意图;4 is a schematic diagram of image partitioning provided by an embodiment of the present application;
图5为本申请实施例提供的一种感兴趣区域示意图;5 is a schematic diagram of a region of interest provided by an embodiment of this application;
图6为本申请实施例提供的又一种感兴趣区域示意图;6 is a schematic diagram of another region of interest provided by an embodiment of this application;
图7为本申请实施例提供的一种不连续的感兴趣区域示意图;7 is a schematic diagram of a discontinuous region of interest provided by an embodiment of this application;
图8为本申请实施例提供的又一种不连续的感兴趣区域示意图;8 is a schematic diagram of another discontinuous region of interest provided by an embodiment of this application;
图9为本申请实施例提供的成像设备结构示意图。9 is a schematic structural diagram of an imaging device provided by an embodiment of the present application.
具体实施方式detailed description
下面将参照附图更详细地描述本公开的示例性实施例。虽然附图中显示了本公开的示例性实施例,然而应当理解,可以以各种形式实现本公开而不应被这里阐述的实施例所限制。相反,提供这些实施例是为了能够更透彻地理解本公开,并且能够将本公开的范围完整的传达给本领域的技术人员。Hereinafter, exemplary embodiments of the present disclosure will be described in more detail with reference to the accompanying drawings. Although the exemplary embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure can be implemented in various forms and should not be limited by the embodiments set forth herein. Rather, these embodiments are provided to enable a more thorough understanding of the present disclosure and to fully convey the scope of the present disclosure to those skilled in the art.
在实现本申请实施例的过程中,申请人考虑到可以采用如下方式实现图像曝光和增益值的调整:In the process of implementing the embodiments of the present application, the applicant considered that the image exposure and gain values can be adjusted in the following ways:
为了便于说明成像设备中,图像的亮度统计和曝光时长及增益值调整的过程,现定义F t0、F t1和F t2分别为t 0、t 1和t 2时刻图像的视频帧。通常情况下的感兴趣区域的亮度统计和曝光时长及增益值调整分为如下几个步骤: In order to facilitate the explanation of the process of image brightness statistics, exposure duration and gain value adjustment in the imaging device, F t0 , F t1 and F t2 are now defined as the video frames of the image at t 0 , t 1 and t 2 respectively. In general, the brightness statistics of the region of interest and the adjustment of exposure time and gain value are divided into the following steps:
1、在t 0时刻,成像设备获取到感兴趣区域曝光指令。 1. At time t 0 , the imaging device obtains the exposure instruction of the region of interest.
2、在t 1时刻,成像设备开始进行感兴趣区域亮度统计,在F t1帧图像的时长内计算感兴趣区域的亮度值,并且确定下一帧图像,即F t2帧图像的曝光时长和增益值。 2. At time t 1 , the imaging device starts to count the brightness of the region of interest, calculates the brightness value of the region of interest within the duration of the F t1 frame image, and determines the exposure duration and gain of the next frame image, that is, the F t2 frame image value.
3、在t 2时刻,成像设备开始对F t2帧图像的采集进行曝光时长和增益值的调整。 3. At time t 2 , the imaging device starts to adjust the exposure duration and gain value for the acquisition of the F t2 frame image.
在实际应用过程中,上述步骤往往会出现下述问题:由于图像在F t0帧之前已经开始输出,因此F t0帧图像不用来进行亮度统计,只能在F t1帧图像的时长内来进行亮度统计,相对而言,成像设备不能以最快的速度获得高质量的图像。 In the actual application process, the above steps often have the following problems: Since the image has been output before the F t0 frame, the F t0 frame image is not used for brightness statistics, only the brightness of the F t1 frame image duration Statistics, relatively speaking, imaging equipment can not obtain high-quality images at the fastest speed.
下面分别对本申请实施例提供的图像曝光和增益的调整方法、成像设备及车辆的各种具体实施方式进行详细的说明。Various specific implementations of the image exposure and gain adjustment method, imaging device, and vehicle provided in the embodiments of the present application are described in detail below.
本申请实施例提供的图像曝光和增益的调整方法,其流程参照图1所示,包括下述步骤:The method for adjusting the image exposure and gain provided by the embodiments of the present application, the flow of which is shown in FIG. 1 and includes the following steps:
S11、获得图像的感兴趣区域的曝光指令。S11. Obtain the exposure instruction of the region of interest of the image.
S12、在获得曝光指令所在的当前帧图像的非关键传输时长内,确定当前帧图像的感兴趣区域的亮度值。S12. Determine the brightness value of the region of interest of the current frame image within the non-critical transmission duration of the current frame image where the exposure instruction is obtained.
S13、根据当前帧图像的感兴趣区域的亮度值,确定下一帧图像的曝光时长及增益值。S13: Determine the exposure duration and gain value of the next frame image according to the brightness value of the region of interest of the current frame image.
S14、根据确定出的下一帧图像的曝光时长及增益值对下一帧图像的采集进行调整。S14. Adjust the acquisition of the next frame image according to the determined exposure duration and gain value of the next frame image.
上述步骤S12中的当前帧图像的非关键传输时长,例如可以是当前帧图像的帧消隐区时长,也可以是当前帧图像最后若干行的传输时长,或者其他可以利用的非关键传输时长。非关键传输时长具体为何种时长,要根据获得图像的感兴趣区域的曝光指令的时刻进一步来确定。The non-critical transmission duration of the current frame image in step S12 may be, for example, the duration of the frame blanking area of the current frame image, or the transmission duration of the last several lines of the current frame image, or other non-critical transmission durations that may be utilized. The specific duration of the non-critical transmission time should be further determined according to the timing of the exposure instruction of the region of interest to obtain the image.
在本申请实施例中,通常对于每一个图像帧而言,其时长包括有效数据时长和帧消隐区时长,有效数据时长用来承载图像的有效数据,在图像有效数据传输的过程中,由于图 像最后若干行数据的内容通常对图像的整体质量和显示效果影响不大。因此可以在进行感兴趣区域亮度计算时,忽略这几行数据的内容,进而可以在当前帧图像最后若干行的传输时长内来计算感兴趣区域的亮度值。In the embodiments of the present application, for each image frame, the duration includes effective data duration and frame blanking area duration. The effective data duration is used to carry the effective data of the image. The content of the last few lines of data in an image usually has little effect on the overall image quality and display effect. Therefore, when calculating the brightness of the region of interest, the contents of these lines of data can be ignored, and then the brightness value of the region of interest can be calculated within the transmission duration of the last lines of the current frame image.
帧消隐区时长位于有效数据时长之后,不承载任何有效数据。其中,有效数据从图像的左上角开始输出,从左到右,直到整行传输完毕,再开始从下一行的最左端重新输出,直至整幅图像输出完毕。在图像的有效数据输出完毕而下一帧图像的有效数据尚未输出时,两相邻帧图像中存在一段时间间隔,通常把这种时间间隔称之为帧消隐区时长,帧消隐区时长的设置是为下一帧的图像输出做准备。The duration of the frame blanking zone is after the duration of valid data, and does not carry any valid data. Among them, valid data is output from the upper left corner of the image, from left to right, until the entire line is transmitted, and then re-output from the leftmost end of the next line until the entire image is output. When the effective data of the image is output and the effective data of the next frame of the image has not been output, there is a time interval between two adjacent frame images. This time interval is usually referred to as the frame blanking zone duration and frame blanking zone duration. Is to prepare for the image output of the next frame.
相对于在当前帧图像的帧消隐区时长内计算感兴趣区域的亮度值,在当前帧图像最后若干行的传输时长内计算感兴趣区域的亮度值要更早,因此,在当前帧图像最后若干行的传输时长内计算感兴趣区域的亮度值的方式对下一帧图像曝光和增益进行调整的时刻要更早、更快。Relative to the calculation of the brightness value of the region of interest within the frame blanking period of the current frame image, it is earlier to calculate the brightness value of the region of interest within the transmission duration of the last lines of the current frame image. Therefore, at the end of the current frame image The method of calculating the brightness value of the region of interest within the transmission duration of several lines to adjust the exposure and gain of the next frame image earlier and faster.
其中,当前帧图像最后若干行的时长可以是预先设定好的,最后若干行时长例如可以设置为2~5行的时长,实际的时长需要根据当前帧感兴趣区域的亮度值计算所需时长来决定。通常情况下,当前帧感兴趣区域的亮度值计算时长大约为200个时钟,上述时钟的具体长度可以理解为:在接收图像像素时,每接收一个像素计为一个时钟。基于此,200个时钟的时长为接收200个图像像素的时长。The duration of the last few lines of the current frame image can be preset, and the duration of the last few lines can be set to 2 to 5 lines, for example. The actual duration needs to be calculated according to the brightness value of the region of interest in the current frame To decide. Generally, the calculation time of the luminance value of the region of interest in the current frame is about 200 clocks. The specific length of the above clocks can be understood as: when receiving image pixels, each received pixel counts as one clock. Based on this, the duration of 200 clocks is the duration of receiving 200 image pixels.
此外,感兴趣区域的范围,可以预先设置(例如设置符合某种条件的范围为感兴趣区域,或者直接设置具体的范围),也可以通过获取感兴趣区域曝光指令的方式进行确定。无论是通过哪种方式确定的感兴趣区域的范围,其每帧图像的感兴趣区域范围的大小均可能不同。In addition, the range of the region of interest may be set in advance (for example, setting a range that meets certain conditions as the region of interest, or directly setting a specific range), or it may be determined by obtaining an exposure instruction of the region of interest. No matter which way the range of the region of interest is determined, the size of the range of the region of interest for each frame of image may be different.
本申请实施例通过利用当前帧图像的非关键传输时长,来确定当前帧图像的感兴趣区域的亮度值。在当前帧图像的非关键传输时长内计算感兴趣区域的亮度值,不仅能够不影响正常图像帧的传输,还可以有效地利用图像传输过程中的间隔时长,以更快的速度响应上层***发出的感兴趣区域曝光指令,对于上层***(如:自动驾驶***)来说,意义重大。The embodiment of the present application determines the brightness value of the region of interest of the current frame image by using the non-critical transmission duration of the current frame image. Calculating the brightness value of the region of interest within the non-critical transmission time of the current frame image can not only not affect the transmission of the normal image frame, but also can effectively use the interval time in the image transmission process, responding to the upper system with a faster speed. The exposure instruction of the region of interest is of great significance to the upper-level system (such as: automatic driving system).
本申请实施例中,由于获取到感兴趣区域曝光指令的时刻可能在图像帧的任意时刻,因此存在以下两种情况:In the embodiment of the present application, since the time when the exposure instruction of the region of interest is acquired may be at any time of the image frame, there are the following two cases:
第一种,获取到感兴趣区域的曝光指令的时刻,位于当前帧图像最后若干行传输时长开始之前,则可以选择在获取曝光指令所在的当前帧图像的帧消隐区时长内,或选择在当前帧图像最后若干行的传输时长内,根据当前帧图像中感兴趣区域所覆盖的范围统计出感兴趣区域的亮度值。First, when the exposure instruction of the region of interest is acquired, before the transmission duration of the last lines of the current frame image begins, you can choose to be within the frame blanking period of the current frame image where the exposure instruction is acquired, or choose between Within the transmission duration of the last lines of the current frame image, the brightness value of the region of interest is counted according to the range covered by the region of interest in the current frame image.
第二种,获取到感兴趣区域的曝光指令的时刻,位于当前帧图像最后若干行传输时长之中,由于无法利用当前帧图像最后若干行传输时长来进行感兴趣区域亮度值的计算。因此,可选择在获取曝光指令所在的当前帧图像的帧消隐区时长内,根据当前帧图像中感兴趣区域所覆盖的范围统计出感兴趣区域的亮度值。Secondly, the moment when the exposure instruction of the region of interest is obtained is located in the transmission time of the last lines of the current frame image, because the transmission time of the last lines of the current frame image cannot be used to calculate the luminance value of the region of interest. Therefore, the brightness value of the region of interest can be calculated according to the range covered by the region of interest in the current frame image within the duration of the frame blanking region of the current frame image where the exposure instruction is acquired.
下面将以一个实例来说明图像曝光和增益的调整方法,参照图2所示,F t0和F t1分别为t 0和t 1时刻图像的视频帧,其具体地调整过程如下: The following will explain the method of adjusting the image exposure and gain with an example. Referring to FIG. 2, F t0 and F t1 are the video frames of the image at t 0 and t 1 respectively. The specific adjustment process is as follows:
1、在t 0时刻,成像设备获取到感兴趣区域曝光指令。 1. At time t 0 , the imaging device obtains the exposure instruction of the region of interest.
2、在F t0帧图像的帧消隐区时长或F t0帧图像最后若干行的传输时长内,开始进行感兴趣区域亮度统计,计算感兴趣区域的亮度值,并且确定下一帧图像,即F t1帧图像的曝光时长和增益值。 2, when the frame blanking interval of the frame image F t0 transmission duration or length of the frame F t0 the last several lines of the image, the luminance statistics start region of interest, calculates the luminance value of the region of interest, and determines the next frame, i.e., F t1 frame image exposure duration and gain value.
3、在t 1时刻,成像设备开始对F t1帧图像的采集进行曝光时长和增益值的调整。 3. At time t 1 , the imaging device starts to adjust the exposure duration and gain value for the collection of F t1 frame images.
在一个实施例中,由于当前帧图像中感兴趣区域所覆盖的范围不同,因此感兴趣区域亮度值的计算方法也分为以下两种情况:In one embodiment, since the area covered by the region of interest in the current frame image is different, the calculation method of the luminance value of the region of interest is also divided into the following two cases:
第一种方式,参照图3A所示,包括下述步骤:The first method, as shown in FIG. 3A, includes the following steps:
S311、对当前帧图像进行分区,形成多行多列的图像分区。S311. Partition the current frame image to form an image partition with multiple rows and multiple columns.
S312、确定当前帧图像中感兴趣区域所覆盖的范围。S312: Determine the range covered by the region of interest in the current frame image.
S313、若感兴趣区域所覆盖的范围处于任一图像分区内部,确定感兴趣区域的亮度值等于感兴趣区域所对应的图像分区的亮度值。S313. If the range covered by the region of interest is within any image partition, determine that the brightness value of the region of interest is equal to the brightness value of the image partition corresponding to the region of interest.
第二种方式,参照图3B所示,包括下述步骤:The second method, as shown in FIG. 3B, includes the following steps:
S321、对当前帧图像进行分区,形成多行多列的图像分区。S321. Partition the current frame image to form an image partition with multiple rows and multiple columns.
S322、确定当前帧图像中感兴趣区域所覆盖的范围。S322. Determine the range covered by the region of interest in the current frame image.
S323、若感兴趣区域所覆盖的范围跨多个图像分区,确定感兴趣区域的面积,并分别计算感兴趣区域与每个图像分区的重叠部分的加权亮度值。S323. If the area covered by the region of interest spans multiple image partitions, determine the area of the region of interest, and calculate the weighted brightness value of the overlapping part of the region of interest and each image partition, respectively.
S324、分别计算各重叠部分的加权亮度值与各自对应的图像分区面积的乘积,并得到乘积之和。S324. Calculate the product of the weighted brightness value of each overlapping part and the area of the corresponding image partition, and obtain the product sum.
S325、将乘积之和除以感兴趣区域的面积,得到感兴趣区域的亮度值。S325. Divide the sum of the products by the area of the region of interest to obtain the brightness value of the region of interest.
下面将以1920×1920分辨率的图像为例,说明上述两种方式下感兴趣区域亮度值的计算方法:The following will take a 1920×1920 resolution image as an example to explain the calculation method of the brightness value of the region of interest under the above two methods:
参照图4所示,将1920×1920分辨率的图像,划分为16×16的图像分区。按照图像传感器图像数据输出的顺序依次统计出每个图像分区N i_j的亮度值,命名为L i_j,其中i为图像水平方向的标号,j为图像垂直方向的标号;i,j均大于等于1,小于等于16;感兴趣区域亮度值为L ROIReferring to FIG. 4, the 1920×1920 resolution image is divided into 16×16 image partitions. According to the order of image sensor image data output, the brightness value of each image partition Ni_j is counted in sequence, named Li_j , where i is the label in the horizontal direction of the image, j is the label in the vertical direction of the image; i, j are greater than or equal to 1 , Less than or equal to 16; the brightness value of the region of interest is L ROI .
假设此时成像设备收到了设置感兴趣区域的曝光指令,那么根据感兴趣区域所覆盖的范围,可以分为下述两种情形,在该两种情形中,感兴趣区域均为矩形区域:Assuming that the imaging device receives an exposure instruction to set the region of interest at this time, then according to the range covered by the region of interest, it can be divided into the following two situations. In both cases, the region of interest is a rectangular region:
第一种情形,参照图5所示,感兴趣区域处于图像256个图像分区中任意一个分区的内部,那么该感兴趣区域的亮度值L ROI=L i_jIn the first case, referring to FIG. 5, the region of interest is inside any one of the 256 image partitions of the image, then the brightness value of the region of interest L ROI =L i_j .
第二种情形,参照图6所示,感兴趣区域跨多个图像分区(图6所示的仅仅是多种跨图像分区情形中的一种情形,本申请实施例不限定其所跨图像分区的数量及所跨分区的位置等,其他情形下的计算方法与之类似),感兴趣区域为跨越9个图像分区的矩形区域。In the second case, referring to FIG. 6, the region of interest spans multiple image partitions (shown in FIG. 6 is only one of multiple cross-image partition scenarios, and the embodiments of the present application do not limit the image partitions The number of and the location of the partitions, etc., the calculation method is similar in other cases), the region of interest is a rectangular region spanning 9 image partitions.
感兴趣区域和9个图像分区之间的9个重叠部分的面积分别为:M i-1_j-1、M i-1_j、M i-1_j+1、M i_j-1、M i_j、M i_j+1、M i+1_j-1、M i+1_j、M i+1_j+1;在这个例子中,9个重叠部分的面积的计算可以采用所占区域以像素为单位的长和宽的乘积。 The area of the overlapped portion 9 of the regions of interest between images and nine partitions are: M i-1_j-1, M i-1_j, M i-1_j + 1, M i_j-1, M i_j, M i_j + 1 , Mi +1_j-1 , Mi +1_j , Mi +1_j+1 ; in this example, the area of the 9 overlapping parts can be calculated by taking the product of the length and width of the occupied area in pixels.
上述9个重叠部分的加权亮度值为:
Figure PCTCN2019077118-appb-000001
Figure PCTCN2019077118-appb-000002
每个图像分区的亮度值为:L i-1_j-1、L i-1_j、L i-1_j+1、L i_j-1、L i_j、L i_j+1、L i+1_j-1、L i+1_j、L i+1_j+1,每个图像分区的面积为M n(M n在划分区域时就是已知的,其面积为图像分区内以像素为单位的长和宽的乘积),感兴趣区域的面积定义为M ROI,感兴趣区域的亮度定义为L ROI,则:
The weighted brightness values of the above 9 overlapping parts are:
Figure PCTCN2019077118-appb-000001
Figure PCTCN2019077118-appb-000002
The brightness of each image section is: L i-1_j-1, L i-1_j, L i-1_j + 1, L i_j-1, L i_j, L i_j + 1, L i + 1_j-1, L i +1_j , Li +1_j+1 , the area of each image partition is M n (M n is known when dividing the area, and its area is the product of the length and width in pixels of the image partition). The area of the area of interest is defined as M ROI , and the brightness of the area of interest is defined as L ROI , then:
Figure PCTCN2019077118-appb-000003
Figure PCTCN2019077118-appb-000003
Figure PCTCN2019077118-appb-000004
Figure PCTCN2019077118-appb-000004
Figure PCTCN2019077118-appb-000005
Figure PCTCN2019077118-appb-000005
Figure PCTCN2019077118-appb-000006
Figure PCTCN2019077118-appb-000006
Figure PCTCN2019077118-appb-000007
Figure PCTCN2019077118-appb-000007
Figure PCTCN2019077118-appb-000008
Figure PCTCN2019077118-appb-000008
Figure PCTCN2019077118-appb-000009
Figure PCTCN2019077118-appb-000009
Figure PCTCN2019077118-appb-000010
Figure PCTCN2019077118-appb-000010
Figure PCTCN2019077118-appb-000011
Figure PCTCN2019077118-appb-000011
Figure PCTCN2019077118-appb-000012
Figure PCTCN2019077118-appb-000012
Figure PCTCN2019077118-appb-000013
Figure PCTCN2019077118-appb-000013
根据上述计算过程,便可计算出感兴趣区域的亮度值。According to the above calculation process, the brightness value of the region of interest can be calculated.
本申请实施例以面积作为每个重叠部分亮度值的权重,但本申请并不限于此种方法,亦可通过其他方式来确定该权重值,本申请实施例对此不做限定。The embodiment of the present application uses area as the weight of the brightness value of each overlapping portion, but the present application is not limited to this method, and the weight value may also be determined by other methods, which is not limited in the embodiment of the present application.
上述两种情况中感兴趣区域亮度值的计算方式均是以感兴趣区域为连续的区域为例进行说明的,若感兴趣区域不连续,则将不连续的各部分分别按照前述方式进行计算后,再整体进行加权平均计算。关于加权平均计算的过程,参见下述方式:In the above two cases, the calculation method of the luminance value of the region of interest is described by taking the region of interest as a continuous region as an example. If the region of interest is discontinuous, the discontinuous parts are calculated according to the foregoing method respectively , And then calculate the weighted average as a whole. For the process of weighted average calculation, see the following methods:
参照图7所示,对于感兴趣区域由两块不连续的ROI1区域和ROI2区域共同组成,且ROI1区域和ROI2区域分别处于任一图像分区内部时情况,此种情况下由于两块不连续的ROI1区域和ROI2区域均位于图像分区内部,因此在计算感兴趣区域亮度的过程中采用第一种情形下的计算方法,分别得到ROI1区域和ROI2区域的亮度值L ROI1和L ROI2,其具体地计算步骤参见上述第一种情形下的计算过程,此处不再赘述。 As shown in FIG. 7, the region of interest is composed of two discontinuous ROI1 regions and ROI2 regions, and the ROI1 region and ROI2 region are respectively located in any image partition. In this case, due to the two discontinuous Both the ROI1 area and the ROI2 area are located inside the image partition, so in the process of calculating the brightness of the area of interest, the calculation method in the first case is used to obtain the brightness values L ROI1 and L ROI2 of the ROI1 and ROI2 areas, respectively. For the calculation steps, please refer to the calculation process in the first case above, which will not be repeated here.
然后根据ROI1区域和ROI2区域的亮度值L ROI1和L ROI2预先赋予的权重m和n,通过加权计算得到感兴趣区域的亮度值
Figure PCTCN2019077118-appb-000014
此处权重m和n是预先设置好的,例如可以是ROI1区域和ROI2区域受到关注的百分比概率。为了便于理解,下面将以一个实例来进行说明:
Then according to the brightness values L ROI1 and L ROI2 of the ROI1 area and the ROI2 area, the weights m and n given in advance are obtained by weighting the brightness value of the area of interest
Figure PCTCN2019077118-appb-000014
Here, the weights m and n are preset, and may be, for example, the percentage probability that the ROI1 area and the ROI2 area receive attention. For ease of understanding, the following will illustrate with an example:
假设图7中ROI1区域和ROI2区域经计算得到的亮度值分别为L ROI1和L ROI2,且ROI1区域和ROI2区域预设的权重m=90%,n=60%;那么此时得到的感兴趣区域的亮度值:
Figure PCTCN2019077118-appb-000015
Assume that the calculated brightness values of the ROI1 area and the ROI2 area in FIG. 7 are L ROI1 and L ROI2 , respectively, and the preset weights m=90% and n=60% of the ROI1 area and the ROI2 area; then the interest obtained at this time Area brightness value:
Figure PCTCN2019077118-appb-000015
参照图8所示,感兴趣区域由两块不连续的ROI3区域和ROI4区域共同组成,且ROI3区域和ROI4区域分别跨越不同的图像分区,此种情况下由于感兴趣区域跨越多个图像分区,因此在计算感兴趣区域亮度的过程中采用第二种情形下的计算方法,分别得到ROI3区域和ROI4区域的亮度值L ROI3和L ROI4,其具体地计算步骤参见上述第二种情形下的计算过程,此处不再赘述。 Referring to FIG. 8, the region of interest is composed of two discrete ROI3 regions and ROI4 regions, and the ROI3 region and the ROI4 region respectively span different image partitions. In this case, since the region of interest spans multiple image partitions, Therefore, in the process of calculating the brightness of the region of interest, the calculation method in the second case is used to obtain the brightness values L ROI3 and L ROI4 of the ROI3 region and the ROI4 region, respectively. For the specific calculation steps, see the calculation in the second case above The process will not be repeated here.
然后根据ROI3区域和ROI4区域的亮度值L ROI1和L ROI2预先赋予的权重m和n,通过加权计算得到感兴趣区域的亮度值
Figure PCTCN2019077118-appb-000016
此处权重m和n是预先设置 好的,例如可以是ROI3区域和ROI4区域受到关注的百分比概率。为了便于理解,下面将以一个实例来进行说明:
Then according to the brightness values L ROI1 and L ROI2 of the ROI3 area and the ROI4 area, the weights m and n given in advance are obtained by weighted calculation to obtain the brightness value of the area of interest
Figure PCTCN2019077118-appb-000016
Here, the weights m and n are preset, and may be, for example, the percentage probability that the ROI3 region and the ROI4 region receive attention. For ease of understanding, the following will illustrate with an example:
假设图8中ROI3区域和ROI4区域经计算得到的亮度值分别为L ROI3和L ROI4,且ROI3区域和ROI4区域预设的权重m=70%,n=40%;那么此时得到的感兴趣区域的亮度值: Assume that the calculated brightness values of the ROI3 area and the ROI4 area in FIG. 8 are L ROI3 and L ROI4 , respectively, and the preset weights m=70% and n=40% of the ROI3 area and the ROI4 area; then the interest obtained at this time Area brightness value:
Figure PCTCN2019077118-appb-000017
Figure PCTCN2019077118-appb-000017
本申请实施例以感兴趣区域由两块不连续的区域共同组成为例进行的说明,当然感兴趣区域也可以为由任意不连续的若干区域共同组成,其计算过程与上述两种情况下的计算过程类似,此处不再赘述。In the embodiment of the present application, the region of interest is composed of two discontinuous regions as an example. Of course, the region of interest may also be composed of any discontinuous regions. The calculation process is the same as that in the above two cases. The calculation process is similar and will not be repeated here.
本申请实施例中,在步骤S311和S321对当前帧图像进行分区之后,需要计算图像分区的亮度值,可以采用下述两种方式处理:In the embodiment of the present application, after partitioning the current frame image in steps S311 and S321, the brightness value of the image partition needs to be calculated, which can be processed in the following two ways:
第1种、分别统计每个图像分区的亮度值。The first method is to separately count the brightness value of each image partition.
例如可以将上述16×16每个图像分区的亮度值,在当前帧的有效数据传输完成时,通过预先设定好的计算机程序依次计算出来,进而进行相关亮度值的计算。如果是在当前帧图像的最后若干行的时长内进行亮度计算的情况,则将最后若干行的数据设置为默认的数据,从而完成最后若干行所在分区的亮度的计算。For example, the brightness value of each 16×16 image partition can be calculated in sequence through a preset computer program when the effective data transmission of the current frame is completed, and then the related brightness value can be calculated. If the brightness calculation is performed within the duration of the last few lines of the current frame image, the data of the last few lines is set as the default data, thereby calculating the brightness of the partition where the last few lines are located.
第2种、根据当前帧图像中感兴趣区域所覆盖的范围,统计与感兴趣区域存在重叠部分的图像分区的亮度值。例如可以是通过预先设定好的计算机程序将感兴趣区域所涉及图像分区的亮度值计算出来。在此种方式中,与前面第1种方式的区别在于,仅计算与感兴趣区域有重叠的各图像分区的亮度值,类似地,如果是在当前帧图像的最后若干行的时长内进行亮度计算的情况,则将最后若干行的数据设置为默认的数据,从而完成最后若干行所在分区的亮度的计算。The second method is to calculate the brightness value of the image partition that overlaps with the region of interest according to the range covered by the region of interest in the current frame image. For example, the brightness value of the image partition involved in the region of interest may be calculated through a preset computer program. In this method, the difference from the previous method is that only the brightness value of each image partition that overlaps with the region of interest is calculated. Similarly, if the brightness is performed within the last several lines of the current frame image In the case of calculation, the data of the last few rows is set as the default data, so as to complete the calculation of the brightness of the partition where the last few rows are located.
基于同一申请构思,本申请实施例还提供了一种成像设备及车辆。由于这些成像设备及车辆等所解决问题的原理与前述图像曝光和增益的调整方法相似,因此该成像设备及车辆的实施可以参见前述方法的实施,重复之处不再赘述。Based on the same application concept, embodiments of the present application also provide an imaging device and a vehicle. Since the principles of the problems solved by these imaging devices and vehicles are similar to the aforementioned image exposure and gain adjustment methods, the implementation of the imaging devices and vehicles can be referred to the implementation of the aforementioned methods, and the repetitions will not be repeated.
参照图9所示,本申请实施例提供一种成像设备,包括:图像传感器91和处理器92。Referring to FIG. 9, an embodiment of the present application provides an imaging device, including: an image sensor 91 and a processor 92.
图像传感器91,用于进行图像采集,得到当前帧图像。The image sensor 91 is used for image acquisition to obtain the current frame image.
处理器92,用于获得图像的感兴趣区域的曝光指令;在获得曝光指令所在的当前帧图像的非关键传输时长内,确定当前帧图像的感兴趣区域的亮度值;根据当前帧图像的感兴趣区域的亮度值,确定下一帧图像的曝光时长及增益值;根据确定出的下一帧图像的曝光时长及增益值控制图像传感器对下一帧图像的采集进行调整。.The processor 92 is used to obtain the exposure instruction of the region of interest of the image; determine the brightness value of the region of interest of the current frame image within the non-critical transmission time of the current frame image where the exposure instruction is obtained; according to the sense of the current frame image The brightness value of the region of interest determines the exposure duration and gain value of the next frame image; according to the determined exposure duration and gain value of the next frame image, the image sensor is controlled to adjust the collection of the next frame image. .
在一个实施例中,处理器92中所采用的非关键传输时长为当前帧图像的帧消隐区时 长或者当前帧图像最后若干行的传输时长。In one embodiment, the non-critical transmission duration adopted in the processor 92 is the duration of the frame blanking area of the current frame image or the transmission duration of the last few lines of the current frame image.
在一个实施例中,处理器92,还用于:确定获得图像的感兴趣区域的曝光指令的时刻。In one embodiment, the processor 92 is further configured to: determine the time of the exposure instruction of the region of interest to obtain the image.
处理器92,具体用于:在获得图像的感兴趣区域的曝光指令的时刻位于当前帧图像最后若干行传输时长开始之前时,在当前帧图像的帧消隐区时长内或者当前帧图像最后若干行的传输时长内,根据当前帧图像中感兴趣区域所覆盖的范围统计出感兴趣区域的亮度值。The processor 92 is specifically configured to: within the duration of the frame blanking area of the current frame image or the last number of the current frame image when the exposure instruction of the region of interest of the image is obtained before the start of the last line transmission duration of the current frame image Within the transmission time of the line, the brightness value of the region of interest is calculated according to the range covered by the region of interest in the current frame image.
在一个实施例中,处理器92,还用于:确定获得图像的感兴趣区域的曝光指令的时刻。In one embodiment, the processor 92 is further configured to: determine the time of the exposure instruction of the region of interest to obtain the image.
处理器92,具体用于:若获得图像的感兴趣区域的曝光指令的时刻位于当前帧图像最后若干行传输时长之中,则在当前帧图像的帧消隐区时长内,根据当前帧图像中感兴趣区域所覆盖的范围统计出感兴趣区域的亮度值。The processor 92 is specifically configured to: if the time of obtaining the exposure instruction of the region of interest of the image is within the transmission duration of the last several lines of the current frame image, within the frame blanking time duration of the current frame image, according to the current frame image The area covered by the region of interest counts the brightness value of the region of interest.
在一个实施例中,处理器92,具体还用于:对当前帧图像进行分区,形成多行多列的图像分区;确定当前帧图像中感兴趣区域所覆盖的范围;在感兴趣区域所覆盖的范围处于任一图像分区内部时,确定感兴趣区域的亮度值等于感兴趣区域所对应的图像分区的亮度值。In one embodiment, the processor 92 is further specifically configured to: partition the current frame image to form a multi-row and multi-column image partition; determine the range covered by the region of interest in the current frame image; cover the region of interest When the range of is within any image partition, determine that the brightness value of the region of interest is equal to the brightness value of the image partition corresponding to the region of interest.
在一个实施例中,处理器92,还用于:分别统计每个图像分区的亮度值;或者根据当前帧图像中感兴趣区域所覆盖的范围,统计与感兴趣区域存在重叠部分的图像分区的亮度值。In one embodiment, the processor 92 is further configured to: separately calculate the brightness value of each image partition; or according to the range covered by the region of interest in the image of the current frame, calculate the statistics of the image partition that overlaps with the region of interest Brightness value.
在一个实施例中,处理器92,具体还用于:对当前帧图像进行分区,形成多行多列的图像分区;确定当前帧图像中感兴趣区域所覆盖的范围;在感兴趣区域所覆盖的范围跨多个图像分区时,确定感兴趣区域的面积,并分别计算感兴趣区域与每个图像分区的重叠部分的加权亮度值;分别计算各重叠部分的加权亮度值与各自对应的图像分区面积的乘积,并得到乘积之和;将乘积之和除以感兴趣区域的面积,得到感兴趣区域的亮度值。In one embodiment, the processor 92 is further specifically configured to: partition the current frame image to form a multi-row and multi-column image partition; determine the range covered by the region of interest in the current frame image; cover the region of interest When the range of the image spans multiple image partitions, determine the area of the region of interest, and calculate the weighted brightness value of the overlapping part of the region of interest and each image partition; calculate the weighted brightness value of each overlapping part and the corresponding image partition Multiply the area and get the sum of the products; divide the sum of the products by the area of the area of interest to get the brightness value of the area of interest.
在一个实施例中,处理器92,还用于:分别统计每个图像分区的亮度值;或者根据当前帧图像中感兴趣区域所覆盖的范围,统计与感兴趣区域存在重叠部分的图像分区的亮度值。In an embodiment, the processor 92 is further configured to: separately calculate the brightness value of each image partition; or according to the range covered by the region of interest in the current frame image, calculate the statistics of the image partitions that overlap with the region of interest Brightness value.
在一个实施例中,处理器92,具体还用于:确定感兴趣区域与每个图像分区的重叠部分面积;分别计算各个图像分区的亮度值与各个图像分区各自对应的重叠部分面积的乘积;将各乘积分别除以各自对应的图像分区面积,得到感兴趣区域与每个图像分区的重叠部分的加权亮度值。In one embodiment, the processor 92 is further specifically configured to: determine the overlapping area of the region of interest and each image partition; calculate the product of the brightness value of each image partition and the overlapping area of each image partition; Divide each product by the corresponding image partition area to obtain the weighted brightness value of the overlapping part of the region of interest and each image partition.
在一个实施例中,处理器92为现场可编程门阵列。In one embodiment, the processor 92 is a field programmable gate array.
本申请实施例提供的一种车辆,其中车辆设置有上述图9对应的成像设备。A vehicle provided by an embodiment of the present application, wherein the vehicle is provided with the imaging device corresponding to FIG. 9 described above.
本申请实施例还提供了一种计算机可读存储介质,其上存储有计算机指令,该指令被 处理器执行时实现上述的图像曝光和增益的调整方法。上述计算机可读存储介质包括各种非易失性的存储介质,包括但不限于光盘、ROM、EEPROM、FLASH memory、各类磁盘等等。Embodiments of the present application also provide a computer-readable storage medium on which computer instructions are stored, and when the instructions are executed by a processor, the above-mentioned image exposure and gain adjustment method is implemented. The foregoing computer-readable storage media include various non-volatile storage media, including but not limited to optical disks, ROM, EEPROM, FLASH memories, various types of magnetic disks, and so on.
本申请实施例提供的上述图像曝光和增益的调整方法、成像设备及车辆,首先获得图像的感兴趣区域的曝光指令,然后在曝光指令所在的当前帧图像的非关键传输时长内,确定当前帧图像的感兴趣区域的亮度值,进而确定出下一帧图像的曝光时长及增益值。相对于现有技术中只能利用获取到的感兴趣区域的曝光指令所在当前帧图像的下一帧图像的时长来统计当前帧图像的感兴趣区域亮度值的做法,本申请实施例将亮度计算的过程,放在当前帧图像的非关键传输时长内进行处理,更有效地利用了当前帧图像的时长,从而相对于现有技术,提前了一帧的时长对图像曝光和增益进行调整,这对需要以最快的速度获取高质量图像的技术领域(如:自动驾驶领域)而言,其意义是非常深远的。The above image exposure and gain adjustment method, imaging device, and vehicle provided by the embodiments of the present application first obtain the exposure command of the region of interest of the image, and then determine the current frame within the non-critical transmission time of the current frame image where the exposure command is located The brightness value of the region of interest of the image, and then determine the exposure duration and gain value of the next frame of the image. In contrast to the practice in the prior art that only the duration of the next frame image of the current frame image where the exposure instruction of the obtained interest area is located can be used to count the brightness value of the interest area of the current frame image, the embodiment of the present application calculates the brightness The process of processing is placed within the non-critical transmission time of the current frame image, and the time length of the current frame image is more effectively used, so that the exposure and gain of the image are adjusted one frame earlier than the existing technology. For the technical fields that need to acquire high-quality images at the fastest speed (such as the field of autonomous driving), its significance is very far-reaching.
以上结合具体实施例描述了本申请的基本原理,但是,需要指出的是,对本领域普通技术人员而言,能够理解本申请的方法和装置的全部或者任何步骤或者部件可以在任何计算装置(包括处理器、存储介质等)或者计算装置的网络中,以硬件固件、软件或者他们的组合加以实现,这是本领域普通技术人员在阅读了本申请的说明的情况下运用它们的基本编程技能就能实现的。The basic principles of the present application have been described above in conjunction with specific embodiments. However, it should be noted that those of ordinary skill in the art can understand that all or any steps or components of the methods and devices of the present application can be included in any computing device (including Processors, storage media, etc.) or computing device networks, implemented in hardware firmware, software, or a combination of these, this is the basic programming skills of those of ordinary skill in the art after reading the description of this application. Achievable.
本领域普通技术人员可以理解实现上述实施例方法携带的全部或部分步骤是可以通过程序来指令相关的硬件完成,所述的程序可以存储于一种计算机可读存储介质中,该程序在执行时,包括方法实施例的步骤之一或其组合。A person of ordinary skill in the art may understand that all or part of the steps carried in the method of the above embodiments may be completed by instructing relevant hardware through a program, and the program may be stored in a computer-readable storage medium. When the program is executed , Including one of the steps of the method embodiment or a combination thereof.
另外,在本申请各个实施例中的各功能单元可以集成在一个处理模块中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个模块中。上述集成的模块既可以采用硬件的形式实现,也可以采用软件功能模块的形式实现。所述集成的模块如果以软件功能模块的形式实现并作为独立的产品销售或使用时,也可以存储在一个计算机可读取存储介质中。In addition, each functional unit in each embodiment of the present application may be integrated into one processing module, or each unit may exist alone physically, or two or more units may be integrated into one module. The above integrated modules may be implemented in the form of hardware or software function modules. If the integrated module is implemented in the form of a software functional module and sold or used as an independent product, it may also be stored in a computer-readable storage medium.
本领域内的技术人员应明白,本申请的实施例可提供为方法、***、或计算机程序产品。因此,本申请可采用完全硬件实施例、完全软件实施例、或结合软件和硬件方面的实施例的形式。而且,本申请可采用在一个或多个其中包含有计算机可用程序代码的计算机可用存储介质(包括但不限于磁盘存储器和光学存储器等)上实施的计算机程序产品的形式。Those skilled in the art should understand that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware. Moreover, the present application may take the form of a computer program product implemented on one or more computer usable storage media (including but not limited to disk storage and optical storage, etc.) containing computer usable program code.
本申请是参照根据本申请实施例的方法、设备(***)、和计算机程序产品的流程图和/或方框图来描述的。应理解可由计算机程序指令实现流程图和/或方框图中的每一流程和/或方框、以及流程图和/或方框图中的流程和/或方框的结合。可提供这些计算机 程序指令到通用计算机、专用计算机、嵌入式处理机或其他可编程数据处理设备的处理器以产生一个机器,使得通过计算机或其他可编程数据处理设备的处理器执行的指令产生用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的装置。This application is described with reference to flowcharts and/or block diagrams of methods, devices (systems), and computer program products according to embodiments of the application. It should be understood that each flow and/or block in the flowchart and/or block diagram and a combination of the flow and/or block in the flowchart and/or block diagram may be implemented by computer program instructions. These computer program instructions can be provided to the processor of a general-purpose computer, special-purpose computer, embedded processing machine, or other programmable data processing device to produce a machine that enables the generation of instructions executed by the processor of the computer or other programmable data processing device An apparatus for realizing the functions specified in one block or multiple blocks of one flow or multiple flows of a flowchart and/or one block or multiple blocks of a block diagram.
这些计算机程序指令也可存储在能引导计算机或其他可编程数据处理设备以特定方式工作的计算机可读存储器中,使得存储在该计算机可读存储器中的指令产生包括指令装置的制造品,该指令装置实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能。These computer program instructions may also be stored in a computer-readable memory that can guide a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture including an instruction device, the instructions The device implements the functions specified in one block or multiple blocks of the flowchart one flow or multiple flows and/or block diagrams.
这些计算机程序指令也可装载到计算机或其他可编程数据处理设备上,使得在计算机或其他可编程设备上执行一系列操作步骤以产生计算机实现的处理,从而在计算机或其他可编程设备上执行的指令提供用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的步骤。These computer program instructions can also be loaded onto a computer or other programmable data processing device, so that a series of operating steps are performed on the computer or other programmable device to produce computer-implemented processing, which is executed on the computer or other programmable device The instructions provide steps for implementing the functions specified in one block or multiple blocks of the flowchart one flow or multiple flows and/or block diagrams.
尽管已描述了本申请的上述实施例,但本领域内的技术人员一旦得知了基本创造性概念,则可对这些实施例做出另外的变更和修改。所以,所附权利要求意欲解释为包括上述实施例以及落入本申请范围的所有变更和修改。Although the above-mentioned embodiments of the present application have been described, those skilled in the art can make additional changes and modifications to these embodiments once they learn the basic inventive concept. Therefore, the appended claims are intended to be construed as including the above embodiments and all changes and modifications falling within the scope of the present application.
显然,本领域的技术人员可以对本申请进行各种改动和变型而不脱离本申请的精神和范围。这样,倘若本申请的这些修改和变型属于本申请权利要求及其等同技术的范围之内,则本申请也意图包含这些改动和变型在内。Obviously, those skilled in the art can make various modifications and variations to this application without departing from the spirit and scope of this application. In this way, if these modifications and variations of the present application fall within the scope of the claims of the present application and their equivalent technologies, the present application is also intended to include these modifications and variations.

Claims (21)

  1. 一种图像曝光和增益的调整方法,其特征在于,包括:A method for adjusting image exposure and gain, characterized in that it includes:
    获得图像的感兴趣区域的曝光指令;Get the exposure instruction of the region of interest of the image;
    在获得所述曝光指令所在的当前帧图像的非关键传输时长内,确定当前帧图像的感兴趣区域的亮度值;Determine the brightness value of the region of interest of the current frame image within the non-critical transmission duration of the current frame image where the exposure instruction is obtained;
    根据所述当前帧图像的感兴趣区域的亮度值,确定下一帧图像的曝光时长及增益值;Determine the exposure duration and gain value of the next frame image according to the brightness value of the region of interest of the current frame image;
    根据确定出的下一帧图像的曝光时长及增益值对下一帧图像的采集进行调整。According to the determined exposure duration and gain value of the next frame image, the collection of the next frame image is adjusted.
  2. 根据权利要求1所述的方法,其特征在于,所述非关键传输时长为当前帧图像的帧消隐区时长或者当前帧图像最后若干行的传输时长。The method according to claim 1, wherein the non-critical transmission duration is the duration of the frame blanking area of the current frame image or the transmission duration of the last lines of the current frame image.
  3. 根据权利要求2所述的方法,其特征在于,还包括:The method of claim 2, further comprising:
    确定获得图像的感兴趣区域的曝光指令的时刻;Determine the time of exposure instruction of the region of interest to obtain the image;
    所述在获得所述曝光指令所在的当前帧图像的非关键传输时长内,确定当前帧图像的感兴趣区域的亮度值,包括:The determination of the brightness value of the region of interest of the current frame image within the non-critical transmission duration of the current frame image where the exposure instruction is obtained includes:
    若获得图像的感兴趣区域的曝光指令的时刻位于所述当前帧图像最后若干行传输时长开始之前,则在当前帧图像的帧消隐区时长内或者当前帧图像最后若干行的传输时长内,根据当前帧图像中感兴趣区域所覆盖的范围统计出所述感兴趣区域的亮度值。If the time of obtaining the exposure instruction of the region of interest of the image is before the start of the transmission duration of the last lines of the current frame image, within the frame blanking duration of the current frame image or the transmission duration of the last lines of the current frame image, The brightness value of the region of interest is calculated according to the range covered by the region of interest in the current frame image.
  4. 根据权利要求2所述的方法,其特征在于,还包括:The method of claim 2, further comprising:
    确定获得图像的感兴趣区域的曝光指令的时刻;Determine the time of exposure instruction of the region of interest to obtain the image;
    所述在获得所述曝光指令所在的当前帧图像的非关键传输时长内,确定当前帧图像的感兴趣区域的亮度值,包括:The determination of the brightness value of the region of interest of the current frame image within the non-critical transmission duration of the current frame image where the exposure instruction is obtained includes:
    若获得图像的感兴趣区域的曝光指令的时刻位于所述当前帧图像最后若干行传输时长之中,则在当前帧图像的帧消隐区时长内,根据当前帧图像中感兴趣区域所覆盖的范围统计出所述感兴趣区域的亮度值。If the exposure instruction of the region of interest of the image is obtained within the transmission duration of the last lines of the current frame image, then within the frame blanking time of the current frame image, according to the coverage of the region of interest in the current frame image The range counts the brightness value of the region of interest.
  5. 根据权利要求3或4所述的方法,其特征在于,所述根据当前帧图像中感兴趣区域所覆盖的范围统计出所述感兴趣区域的亮度值,包括:The method according to claim 3 or 4, wherein the calculating the brightness value of the region of interest according to the range covered by the region of interest in the current frame image includes:
    对当前帧图像进行分区,形成多行多列的图像分区;Partition the current frame image to form an image partition with multiple rows and columns;
    确定当前帧图像中感兴趣区域所覆盖的范围;Determine the area covered by the region of interest in the current frame image;
    若所述感兴趣区域所覆盖的范围处于任一图像分区内部,确定感兴趣区域的亮度值等于所述感兴趣区域所对应的图像分区的亮度值。If the range covered by the region of interest is within any image partition, it is determined that the brightness value of the region of interest is equal to the brightness value of the image partition corresponding to the region of interest.
  6. 根据权利要求5所述的方法,其特征在于,还包括:The method of claim 5, further comprising:
    分别统计每个图像分区的亮度值;或者Count the brightness values of each image partition separately; or
    根据当前帧图像中感兴趣区域所覆盖的范围,统计与所述感兴趣区域存在重叠部分的 图像分区的亮度值。According to the range covered by the region of interest in the current frame image, the brightness value of the image partition that overlaps with the region of interest is counted.
  7. 根据权利要求3或4所述的方法,其特征在于,所述根据当前帧图像中感兴趣区域所覆盖的范围统计出所述感兴趣区域的亮度值,包括:The method according to claim 3 or 4, wherein the calculating the brightness value of the region of interest according to the range covered by the region of interest in the current frame image includes:
    对当前帧图像进行分区,形成多行多列的图像分区;Partition the current frame image to form an image partition with multiple rows and columns;
    确定当前帧图像中感兴趣区域所覆盖的范围;Determine the area covered by the region of interest in the current frame image;
    若所述感兴趣区域所覆盖的范围跨多个图像分区,确定感兴趣区域的面积,并分别计算感兴趣区域与每个图像分区的重叠部分的加权亮度值;If the area covered by the region of interest spans multiple image partitions, determine the area of the region of interest, and calculate the weighted brightness value of the overlapping part of the region of interest and each image partition separately;
    分别计算各重叠部分的加权亮度值与各自对应的图像分区面积的乘积,并得到所述乘积之和;Calculate the product of the weighted brightness value of each overlapping part and the area of the corresponding image partition, and obtain the sum of the products;
    将所述乘积之和除以所述感兴趣区域的面积,得到所述感兴趣区域的亮度值。The sum of the products is divided by the area of the region of interest to obtain the brightness value of the region of interest.
  8. 根据权利要求7所述的方法,其特征在于,还包括:The method of claim 7, further comprising:
    分别统计每个图像分区的亮度值;或者Count the brightness values of each image partition separately; or
    根据当前帧图像中感兴趣区域所覆盖的范围,统计与所述感兴趣区域存在重叠部分的图像分区的亮度值。According to the range covered by the region of interest in the current frame image, the brightness value of the image partition that overlaps with the region of interest is counted.
  9. 根据权利要求8所述的方法,其特征在于,所述分别计算感兴趣区域与每个图像分区的重叠部分的加权亮度值,包括:The method according to claim 8, wherein the separately calculating the weighted brightness values of the overlapping parts of the region of interest and each image partition includes:
    确定感兴趣区域与每个图像分区的重叠部分面积;Determine the area of overlap between the region of interest and each image partition;
    分别计算各个图像分区的亮度值与各个图像分区各自对应的重叠部分面积的乘积;Calculate the product of the brightness value of each image partition and the area of the overlapping part corresponding to each image partition;
    将各乘积分别除以各自对应的图像分区面积,得到感兴趣区域与每个图像分区的重叠部分的加权亮度值。Divide each product by the corresponding image partition area to obtain the weighted brightness value of the overlapping part of the region of interest and each image partition.
  10. 一种成像设备,其特征在于,包括:图像传感器和处理器;An imaging device, characterized in that it includes: an image sensor and a processor;
    所述图像传感器,用于进行图像采集,得到当前帧图像;The image sensor is used for image acquisition to obtain the current frame image;
    所述处理器,用于获得图像的感兴趣区域的曝光指令;在获得所述曝光指令所在的当前帧图像的非关键传输时长内,确定当前帧图像的感兴趣区域的亮度值;根据所述当前帧图像的感兴趣区域的亮度值,确定下一帧图像的曝光时长及增益值;并根据确定出的下一帧图像的曝光时长及增益值控制图像传感器对下一帧图像的采集进行调整。The processor is used to obtain the exposure instruction of the region of interest of the image; determine the brightness value of the region of interest of the current frame image within the non-critical transmission duration of the current frame image where the exposure instruction is obtained; according to the The brightness value of the region of interest of the current frame image determines the exposure duration and gain value of the next frame image; and controls the image sensor to adjust the acquisition of the next frame image according to the determined exposure duration and gain value of the next frame image .
  11. 根据权利要求10所述的成像设备,其特征在于,所述处理器中所采用的非关键传输时长为当前帧图像的帧消隐区时长或者当前帧图像最后若干行的传输时长。The imaging device according to claim 10, characterized in that the non-critical transmission duration adopted in the processor is the duration of the frame blanking area of the current frame image or the transmission duration of the last several lines of the current frame image.
  12. 根据权利要求11所述的成像设备,其特征在于,所述处理器,还用于:The imaging device according to claim 11, wherein the processor is further configured to:
    确定获得图像的感兴趣区域的曝光指令的时刻;Determine the time of exposure instruction of the region of interest to obtain the image;
    所述处理器,具体用于:The processor is specifically used for:
    在获得图像的感兴趣区域的曝光指令的时刻位于所述当前帧图像最后若干行传输时长 开始之前时,在当前帧图像的帧消隐区时长内或者当前帧图像最后若干行的传输时长内,根据当前帧图像中感兴趣区域所覆盖的范围统计出所述感兴趣区域的亮度值。When the exposure instruction of the region of interest of the image is obtained before the transmission duration of the last lines of the current frame image starts, within the frame blanking time duration of the current frame image or the transmission duration of the last lines of the current frame image, The brightness value of the region of interest is calculated according to the range covered by the region of interest in the current frame image.
  13. 根据权利要求11所述的成像设备,其特征在于,所述处理器,还用于:The imaging device according to claim 11, wherein the processor is further configured to:
    确定获得图像的感兴趣区域的曝光指令的时刻;Determine the time of exposure instruction of the region of interest to obtain the image;
    所述处理器,具体用于:The processor is specifically used for:
    若获得图像的感兴趣区域的曝光指令的时刻位于所述当前帧图像最后若干行传输时长之中,则在当前帧图像的帧消隐区时长内,根据当前帧图像中感兴趣区域所覆盖的范围统计出所述感兴趣区域的亮度值。If the exposure instruction of the region of interest of the image is obtained within the transmission duration of the last lines of the current frame image, then within the frame blanking time of the current frame image, according to the coverage of the region of interest in the current frame image The range counts the brightness value of the region of interest.
  14. 根据权利要求12或13所述的成像设备,其特征在于,所述处理器,具体还用于:The imaging device according to claim 12 or 13, wherein the processor is further used to:
    对当前帧图像进行分区,形成多行多列的图像分区;Partition the current frame image to form an image partition with multiple rows and columns;
    确定当前帧图像中感兴趣区域所覆盖的范围;Determine the area covered by the region of interest in the current frame image;
    在所述感兴趣区域所覆盖的范围处于任一图像分区内部时,确定感兴趣区域的亮度值等于所述感兴趣区域所对应的图像分区的亮度值。When the range covered by the region of interest is inside any image partition, it is determined that the brightness value of the region of interest is equal to the brightness value of the image partition corresponding to the region of interest.
  15. 根据权利要求14所述的成像设备,其特征在于,所述处理器,还用于:The imaging device according to claim 14, wherein the processor is further configured to:
    分别统计每个图像分区的亮度值;或者Count the brightness values of each image partition separately; or
    根据当前帧图像中感兴趣区域所覆盖的范围,统计与所述感兴趣区域存在重叠部分的图像分区的亮度值。According to the range covered by the region of interest in the current frame image, the brightness value of the image partition that overlaps with the region of interest is counted.
  16. 根据权利要求12或13所述的成像设备,其特征在于,所述处理器,具体还用于:The imaging device according to claim 12 or 13, wherein the processor is further used to:
    对当前帧图像进行分区,形成多行多列的图像分区;Partition the current frame image to form an image partition with multiple rows and columns;
    确定当前帧图像中感兴趣区域所覆盖的范围;Determine the area covered by the region of interest in the current frame image;
    在所述感兴趣区域所覆盖的范围跨多个图像分区时,确定感兴趣区域的面积,并分别计算感兴趣区域与每个图像分区的重叠部分的加权亮度值;When the range covered by the region of interest spans multiple image partitions, determine the area of the region of interest, and calculate the weighted brightness value of the overlapping part of the region of interest and each image partition respectively;
    分别计算各重叠部分的加权亮度值与各自对应的图像分区面积的乘积,并得到所述乘积之和;Calculate the product of the weighted brightness value of each overlapping part and the area of the corresponding image partition, and obtain the sum of the products;
    将所述乘积之和除以所述感兴趣区域的面积,得到所述感兴趣区域的亮度值。The sum of the products is divided by the area of the region of interest to obtain the brightness value of the region of interest.
  17. 根据权利要求16所述的成像设备,其特征在于,所述处理器,还用于:The imaging device according to claim 16, wherein the processor is further configured to:
    分别统计每个图像分区的亮度值;或者Count the brightness values of each image partition separately; or
    根据当前帧图像中感兴趣区域所覆盖的范围,统计与所述感兴趣区域存在重叠部分的图像分区的亮度值。According to the range covered by the region of interest in the current frame image, the brightness value of the image partition that overlaps with the region of interest is counted.
  18. 根据权利要求17所述的成像设备,其特征在于,所述处理器,具体还用于:The imaging device according to claim 17, wherein the processor is further used to:
    确定感兴趣区域与每个图像分区的重叠部分面积;Determine the area of overlap between the region of interest and each image partition;
    分别计算各个图像分区的亮度值与各个图像分区各自对应的重叠部分面积的乘积;Calculate the product of the brightness value of each image partition and the area of the overlapping part corresponding to each image partition;
    将各乘积分别除以各自对应的图像分区面积,得到感兴趣区域与每个图像分区的重叠部分的加权亮度值。Divide each product by the corresponding image partition area to obtain the weighted brightness value of the overlapping part of the region of interest and each image partition.
  19. 根据权利要求10所述的成像设备,其特征在于,所述处理器为现场可编程门阵列。The imaging device according to claim 10, wherein the processor is a field programmable gate array.
  20. 一种车辆,其特征在于,所述车辆设置有成像设备,该成像设备包括:图像传感器和处理器;A vehicle, characterized in that the vehicle is provided with an imaging device, and the imaging device includes: an image sensor and a processor;
    所述图像传感器,用于进行图像采集,得到当前帧图像;The image sensor is used for image acquisition to obtain the current frame image;
    所述处理器,用于获得图像的感兴趣区域的曝光指令;在获得所述曝光指令所在的当前帧图像的非关键传输时长内,确定当前帧图像的感兴趣区域的亮度值;根据所述当前帧图像的感兴趣区域的亮度值,确定下一帧图像的曝光时长及增益值;并根据确定出的下一帧图像的曝光时长及增益值控制图像传感器对下一帧图像的采集进行调整。The processor is used to obtain the exposure instruction of the region of interest of the image; determine the brightness value of the region of interest of the current frame image within the non-critical transmission duration of the current frame image where the exposure instruction is obtained; according to the The brightness value of the region of interest of the current frame image determines the exposure duration and gain value of the next frame image; and controls the image sensor to adjust the acquisition of the next frame image according to the determined exposure duration and gain value of the next frame image .
  21. 一种计算机可读存储介质,其上存储有计算机指令,其特征在于,该指令被处理器执行时实现图像曝光和增益的调整方法,该方法包括:A computer-readable storage medium on which computer instructions are stored, characterized in that, when the instructions are executed by a processor, a method for adjusting image exposure and gain is implemented. The method includes:
    获得图像的感兴趣区域的曝光指令;Get the exposure instruction of the region of interest of the image;
    在获得所述曝光指令所在的当前帧图像的非关键传输时长内,确定当前帧图像的感兴趣区域的亮度值;Determine the brightness value of the region of interest of the current frame image within the non-critical transmission duration of the current frame image where the exposure instruction is obtained;
    根据所述当前帧图像的感兴趣区域的亮度值,确定下一帧图像的曝光时长及增益值;Determine the exposure duration and gain value of the next frame image according to the brightness value of the region of interest of the current frame image;
    根据确定出的下一帧图像的曝光时长及增益值对下一帧图像的采集进行调整。According to the determined exposure duration and gain value of the next frame image, the collection of the next frame image is adjusted.
PCT/CN2019/077118 2018-12-05 2019-03-06 Image exposure and gain adjusting method, imaging apparatus and vehicle WO2020113833A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201811481568.4A CN111355895B (en) 2018-12-05 2018-12-05 Image exposure and gain adjustment method, imaging device and vehicle
CN201811481568.4 2018-12-05

Publications (1)

Publication Number Publication Date
WO2020113833A1 true WO2020113833A1 (en) 2020-06-11

Family

ID=70975260

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2019/077118 WO2020113833A1 (en) 2018-12-05 2019-03-06 Image exposure and gain adjusting method, imaging apparatus and vehicle

Country Status (2)

Country Link
CN (1) CN111355895B (en)
WO (1) WO2020113833A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114845062A (en) * 2022-04-29 2022-08-02 深圳市联洲国际技术有限公司 Image processing method, nonvolatile storage medium, processor and electronic device

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115379130B (en) * 2022-08-25 2024-03-29 上海联影医疗科技股份有限公司 Automatic exposure control system, method, device and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090003678A1 (en) * 2007-06-29 2009-01-01 Microsoft Corporation Automatic gain and exposure control using region of interest detection
CN103888680A (en) * 2014-03-28 2014-06-25 中国科学技术大学 Method for adjusting exposure time of camera
CN106385544A (en) * 2016-09-23 2017-02-08 浙江宇视科技有限公司 Camera exposure adjustment method and apparatus
CN106791476A (en) * 2017-01-25 2017-05-31 北京图森未来科技有限公司 A kind of image-pickup method and device

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4507855B2 (en) * 2004-11-25 2010-07-21 ソニー株式会社 Image capturing apparatus control method, control apparatus, and control program
CN101326814A (en) * 2005-11-15 2008-12-17 诺基亚公司 Imaging system with adjustable optical device
US8451372B2 (en) * 2007-07-26 2013-05-28 Panasonic Corporation Photographing apparatus that adjusts shooting settings during shooting
CN101359148B (en) * 2007-08-03 2011-04-06 深圳艾科创新微电子有限公司 Method for automatic exposure regulation and control system
JP5287598B2 (en) * 2009-08-20 2013-09-11 カシオ計算機株式会社 Imaging apparatus, exposure adjustment method, and program
CN106663193B (en) * 2014-05-14 2020-12-25 御眼视觉技术有限公司 System and method for curb detection and pedestrian hazard assessment
CN108419025B (en) * 2018-05-30 2020-01-07 北京图森未来科技有限公司 Exposure parameter adjusting method and device and readable medium

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090003678A1 (en) * 2007-06-29 2009-01-01 Microsoft Corporation Automatic gain and exposure control using region of interest detection
CN103888680A (en) * 2014-03-28 2014-06-25 中国科学技术大学 Method for adjusting exposure time of camera
CN106385544A (en) * 2016-09-23 2017-02-08 浙江宇视科技有限公司 Camera exposure adjustment method and apparatus
CN106791476A (en) * 2017-01-25 2017-05-31 北京图森未来科技有限公司 A kind of image-pickup method and device

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114845062A (en) * 2022-04-29 2022-08-02 深圳市联洲国际技术有限公司 Image processing method, nonvolatile storage medium, processor and electronic device
CN114845062B (en) * 2022-04-29 2024-04-02 深圳市联洲国际技术有限公司 Image processing method, nonvolatile storage medium, processor and electronic device

Also Published As

Publication number Publication date
CN111355895A (en) 2020-06-30
CN111355895B (en) 2021-07-16

Similar Documents

Publication Publication Date Title
CN109062531B (en) Spliced screen, display method of spliced screen and display control device
CN112330601A (en) Parking detection method, device, equipment and medium based on fisheye camera
US20220180642A1 (en) Object detection for distorted images
US20190043178A1 (en) Low-light imaging using trained convolutional neural networks
EP3627821B1 (en) Focusing method and apparatus for realizing clear human face, and computer device
US11223810B2 (en) Color balance method and device, on-board equipment and storage medium
US20210256659A1 (en) Method and apparatus for restoring image
WO2020113833A1 (en) Image exposure and gain adjusting method, imaging apparatus and vehicle
CN110083157B (en) Obstacle avoidance method and device
US11206376B2 (en) Systems and methods for image processing
US11741571B2 (en) Voronoi cropping of images for post field generation
AU2018410435B2 (en) Port area monitoring method and system, and central control system
WO2021253186A1 (en) Information processing method and device, and imaging system
CN112927279A (en) Image depth information generation method, device and storage medium
US11132586B2 (en) Rolling shutter rectification in images/videos using convolutional neural networks with applications to SFM/SLAM with rolling shutter images/videos
KR20190105285A (en) Method and system for object detecting using image warping
EP3389256B1 (en) Method and device for processing image
US10223766B2 (en) Image processing including geometric distortion adjustment
US11871119B2 (en) Method for calculating exposure evaluation value and imaging device
EP3349201A1 (en) Parking assist method and vehicle parking assist system
US11902378B2 (en) Systems and methods for data synchronization
US20230186506A1 (en) Object Detection Device and Object Detection Method
CN113395434B (en) Preview image blurring method, storage medium and terminal equipment
JP2018067305A (en) Visual odometry method and device
CN110751618B (en) Floater detection method and device and electronic equipment

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 19893362

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 16.09.2021)

122 Ep: pct application non-entry in european phase

Ref document number: 19893362

Country of ref document: EP

Kind code of ref document: A1