CN111882493A - Image color adjustment method, device, equipment and computer readable storage medium - Google Patents

Image color adjustment method, device, equipment and computer readable storage medium Download PDF

Info

Publication number
CN111882493A
CN111882493A CN202010572484.2A CN202010572484A CN111882493A CN 111882493 A CN111882493 A CN 111882493A CN 202010572484 A CN202010572484 A CN 202010572484A CN 111882493 A CN111882493 A CN 111882493A
Authority
CN
China
Prior art keywords
image
color
adjustment
coefficient
brightness
Prior art date
Legal status (The legal status 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 status listed.)
Pending
Application number
CN202010572484.2A
Other languages
Chinese (zh)
Inventor
崔惠婷
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhejiang Dahua Technology Co Ltd
Original Assignee
Zhejiang Dahua Technology Co Ltd
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 Zhejiang Dahua Technology Co Ltd filed Critical Zhejiang Dahua Technology Co Ltd
Priority to CN202010572484.2A priority Critical patent/CN111882493A/en
Publication of CN111882493A publication Critical patent/CN111882493A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • G06T5/90
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/30Subject of image; Context of image processing
    • G06T2207/30232Surveillance
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/30Subject of image; Context of image processing
    • G06T2207/30236Traffic on road, railway or crossing

Abstract

The application relates to a color adjustment method, a device, equipment and a computer readable storage medium of an image. The image color adjusting method comprises the following steps: acquiring an image and identifying an object in the image; determining a first brightness coefficient of the object according to the brightness value of at least a partial image area of the object; determining a numerical value interval in which the brightness coefficient falls; and acquiring an adjustment rule corresponding to the numerical value interval, and adjusting the color of the object according to the adjustment rule. By the method and the device, the problem that in the related art, the color reduction degree of the image is reduced due to the fact that the camera shoots the image in a forward light state or a backward light state is solved, and the color reduction degree of the image is improved.

Description

Image color adjustment method, device, equipment and computer readable storage medium
Technical Field
The present application relates to the field of image processing, and in particular, to a method, an apparatus, a device, and a computer-readable storage medium for adjusting color of an image.
Background
Intelligent traffic management is a development trend of road traffic, and a snapshot surveillance camera used in an intelligent traffic scene plays an important role in maintaining urban traffic safety. The intelligent traffic camera can monitor the traffic condition of a road, automatically identify the vehicle type and the vehicle system of a license plate and the like, and provide effective vehicle information for public security and traffic police, wherein the vehicle body color and the license plate color are important information for confirming vehicles, so that the vehicle body color and the license plate color shot by the camera in a common scene need to be ensured to have better color reduction degree.
Therefore, in the related art, the spectral conversion relationship between the camera spectral sensitivity function and the CIE1931 color matching function is calculated, the camera original RGB response signal is converted into the device-independent CIE1931XYZ space, and the CAT02 color adaptive conversion model is used to calculate the corresponding color response value after color adaptation under the reference light source, thereby realizing the color correction process independent of the pre-calibrated parameters. However, in the above scheme, the CAT02 color adaptation transformation model is required to calculate the corresponding color response value after color adaptation under the reference light source, so as to implement the color correction process independent of the pre-calibrated parameters, and when the camera captures an image in a forward or backward light state, if the scheme is still used, the color reduction degree of the image will be reduced.
At present, no effective solution is provided for the problem of reduced color reduction of an image caused by the fact that a camera shoots the image in a forward light state or a backward light state in the related art.
Disclosure of Invention
The embodiment of the application provides a method, a device, equipment and a computer readable storage medium for adjusting the color of an image, which are used for at least solving the problem that the color reduction degree of the image is reduced because a camera shoots the image in a forward light state or a backward light state in the related art.
In a first aspect, an embodiment of the present application provides a method for adjusting color of an image, where the method includes:
acquiring an image and identifying an object in the image;
determining a first brightness coefficient of the object according to the brightness value of at least a partial image area of the object;
determining a numerical value interval in which the brightness coefficient falls;
and acquiring an adjustment rule corresponding to the numerical value interval, and adjusting the color of the object according to the adjustment rule.
In some of these embodiments, the range of values comprises a first range of values corresponding to an adjustment rule when the object is in a backlit state; acquiring an adjustment rule corresponding to the value interval includes:
determining the backlight intensity level of the backlight state according to the brightness coefficient under the condition that the numerical value interval in which the brightness coefficient falls is the first numerical value interval;
and acquiring an adjusting rule corresponding to the backlight intensity level.
In some of these embodiments, the interval of values comprises a second interval of values corresponding to an adjustment rule when the object is in a taillight state; acquiring an adjustment rule corresponding to the value interval includes:
determining the taillight intensity level of the taillight state according to the brightness coefficient under the condition that the numerical value interval in which the brightness coefficient falls is the second numerical value interval;
and acquiring an adjusting rule corresponding to the front light intensity level.
In some of these embodiments, the interval of values comprises a second interval of values corresponding to an adjustment rule when the object is in a taillight state, adjusting the color of the object according to the adjustment rule comprising:
determining a second brightness coefficient of the object according to the brightness value of the object;
determining a saturation adjustment coefficient of the object according to at least the second brightness coefficient;
and increasing the saturation of the color of the object according to the saturation adjustment coefficient.
In some of these embodiments, determining a saturation adjustment factor for the object based at least on the second luminance factor comprises:
equally dividing the object into a plurality of areas;
acquiring a brightness coefficient of each of the plurality of regions;
determining the number of first areas with brightness coefficients larger than a preset brightness value in each area;
and calculating a saturation adjustment coefficient of the object at least according to the number of the first areas.
In some embodiments, calculating the saturation adjustment factor of the object based on at least the first number of regions comprises:
judging whether the number of the first areas is smaller than the number of preset areas or not;
determining a saturation adjustment parameter of the object according to the ratio of the number of the first areas to the corresponding number of the plurality of areas under the condition that the number of the first areas is judged to be not less than the number of preset areas;
and under the condition that the number of the first areas is judged to be smaller than the number of the preset areas, the saturation adjusting parameter of the object is equal to the preset saturation adjusting parameter.
In some of these embodiments, after determining the saturation adjustment frame for the object based at least on the second luminance coefficient, the method further comprises:
acquiring a plurality of continuous images;
determining a luminance coefficient of the object in the consecutive plurality of images;
judging whether the brightness coefficients of the objects in the continuous multiple images are all larger than a preset coefficient or not;
if not, keeping the saturation of the colors of the continuous images unchanged.
In some of these embodiments, the at least partial image region comprises: an image region of interest.
In a second aspect, an embodiment of the present application provides an apparatus for adjusting color of an image, the apparatus including:
the first acquisition module is used for acquiring an image and identifying an object in the image;
a first determining module, configured to determine a brightness coefficient of the object according to a brightness value of at least a partial image region of the object;
the second determination module is used for determining a numerical value interval in which the brightness coefficient falls;
and the second acquisition module is used for acquiring an adjustment rule corresponding to the numerical value interval and adjusting the color of the object according to the adjustment rule.
In a third aspect, an embodiment of the present application provides an apparatus for adjusting color of an image, including a memory, a processor, and a computer program stored on the memory and executable on the processor, where the processor implements the method for adjusting color of an image according to the first aspect when executing the computer program.
In a fourth aspect, the present application provides a computer-readable storage medium, on which a computer program is stored, which when executed by a processor implements the method for adjusting color of an image according to the first aspect.
Compared with the related art, the color adjustment method, the color adjustment device, the color adjustment equipment and the computer-readable storage medium for the image provided by the embodiment of the application are used for acquiring the image and identifying the object in the image; determining a first brightness coefficient of the object according to the brightness value of at least a partial image area of the object; determining a numerical value interval in which the brightness coefficient falls; the method for acquiring the adjustment rule corresponding to the numerical value interval and adjusting the color of the object according to the adjustment rule solves the problem that the color reduction degree of the image is reduced due to the fact that the camera shoots the image in a forward light state or a backward light state, and improves the color reduction degree of the image.
The details of one or more embodiments of the application are set forth in the accompanying drawings and the description below to provide a more thorough understanding of the application.
Drawings
The accompanying drawings, which are included to provide a further understanding of the application and are incorporated in and constitute a part of this application, illustrate embodiment(s) of the application and together with the description serve to explain the application and not to limit the application. In the drawings:
fig. 1 is a flowchart of a color adjustment method of an image according to an embodiment of the present application;
FIG. 2 is a flow chart of a method of color adjustment of an image according to a preferred embodiment of the present application;
fig. 3 is a block diagram of a color adjustment apparatus for an image according to an embodiment of the present application;
fig. 4 is a hardware configuration diagram of a color adjustment apparatus of an image according to an embodiment of the present application.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application will be described and illustrated below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the present application and are not intended to limit the present application. All other embodiments obtained by a person of ordinary skill in the art based on the embodiments provided in the present application without any inventive step are within the scope of protection of the present application.
It is obvious that the drawings in the following description are only examples or embodiments of the present application, and that it is also possible for a person skilled in the art to apply the present application to other similar contexts on the basis of these drawings without inventive effort. Moreover, it should be appreciated that in the development of any such actual implementation, as in any engineering or design project, numerous implementation-specific decisions must be made to achieve the developers' specific goals, such as compliance with system-related and business-related constraints, which may vary from one implementation to another.
Reference in the specification to "an embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment can be included in at least one embodiment of the specification. The appearances of the phrase in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. Those of ordinary skill in the art will explicitly and implicitly appreciate that the embodiments described herein may be combined with other embodiments without conflict.
Unless defined otherwise, technical or scientific terms referred to herein shall have the ordinary meaning as understood by those of ordinary skill in the art to which this application belongs. Reference to "a," "an," "the," and similar words throughout this application are not to be construed as limiting in number, and may refer to the singular or the plural. The present application is directed to the use of the terms "including," "comprising," "having," and any variations thereof, which are intended to cover non-exclusive inclusions; for example, a process, method, system, article, or apparatus that comprises a list of steps or modules (elements) is not limited to the listed steps or elements, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus. Reference to "connected," "coupled," and the like in this application is not intended to be limited to physical or mechanical connections, but may include electrical connections, whether direct or indirect. The term "plurality" as referred to herein means two or more. "and/or" describes an association relationship of associated objects, meaning that three relationships may exist, for example, "A and/or B" may mean: a exists alone, A and B exist simultaneously, and B exists alone. The character "/" generally indicates that the former and latter associated objects are in an "or" relationship. Reference herein to the terms "first," "second," "third," and the like, are merely to distinguish similar objects and do not denote a particular ordering for the objects.
The method embodiment provided by the embodiment can be executed in a camera or a monitoring device. The method for adjusting the color of an image according to an embodiment of the present invention will be described and explained below by taking a camera as an example.
The embodiment also provides a color adjusting method of the image. Fig. 1 is a flowchart of a color adjustment method of an image according to an embodiment of the present application, and as shown in fig. 1, the flowchart includes the following steps:
in step S101, the camera acquires an image and identifies an object in the image.
In step S102, the camera determines a first luminance coefficient of the object according to the luminance value of at least a portion of the image area of the object.
In step S103, the camera determines a numerical range in which the luminance coefficient falls.
And step S104, the camera acquires an adjusting rule corresponding to the numerical value interval, and adjusts the color of the object according to the adjusting rule.
In this embodiment, the camera determines the first luminance coefficient of the object and the value range in which the first luminance coefficient falls according to the luminance value of at least a partial image region of the object, and then adjusts the color of the object according to the adjustment rule corresponding to the value range, so that the object has the adjustment rule corresponding to the shooting state in different shooting states, and further adjusts the color of the object according to the adjustment rule, thereby solving the problem of the reduction of the color reduction of the image caused by the camera shooting the image in the front light state or the back light state in the related art, and improving the color reduction of the image.
In this embodiment, the adjustment rule may be a color correction matrix preset by the user and corresponding to the value range.
In this embodiment, the value interval may be a collection of a plurality of intervals, each interval corresponds to one shooting status, and each shooting status has an adjustment rule corresponding to the shooting status. For example, the numerical range includes, but is not limited to: the first value interval may be an adjustment rule when the corresponding object is in a backlight state, and the second value interval may be an adjustment rule when the object is in a frontlight state.
Step S104 is described and illustrated below in a preferred embodiment.
For example, in some of these embodiments, the value interval includes a first value interval, which may be an adjustment rule corresponding to when the object is in a backlit state; the camera acquiring the adjustment rule corresponding to the value interval includes: determining the backlight intensity level of the backlight state according to the brightness coefficient under the condition that the numerical value interval in which the brightness coefficient falls is a first numerical value interval; and acquiring an adjusting rule corresponding to the backlight intensity level.
In this embodiment, the camera further determines the backlight intensity level of the backlight state through the luminance coefficient, then obtains the adjustment rule corresponding to the backlight intensity level, and finally adjusts the color of the object according to the adjustment rule corresponding to the backlight intensity level, so as to further accurately adjust the color reduction degree of the object in the backlight state.
For another example, in some of these embodiments, the value interval includes a second value interval, which may be an adjustment rule corresponding to when the object is in a taillight state; the camera acquires an adjustment rule corresponding to the numerical value interval, and the adjustment rule comprises the following steps: determining the grade of the front light intensity of the front light state according to the brightness coefficient under the condition that the numerical value interval in which the brightness coefficient falls is the second numerical value interval; and acquiring an adjusting rule corresponding to the front light intensity level.
In this embodiment, the camera further determines the front light intensity level of the front light state through the luminance coefficient, then obtains the adjustment rule corresponding to the front light intensity level, and finally adjusts the color of the object according to the adjustment rule corresponding to the front light intensity level, so as to further accurately adjust the color reduction degree of the object in the front light state.
For another example, in some embodiments, the value interval includes a second value interval, the second value interval corresponds to an adjustment rule when the object is in a frontlit state, and adjusting the color of the object according to the adjustment rule includes: determining a second brightness coefficient of the object according to the brightness value of the object; determining a saturation adjustment coefficient of the object according to at least the second brightness coefficient; and increasing the saturation of the color of the object according to the saturation adjustment coefficient.
In this embodiment, the camera determines a second brightness coefficient of the object according to the brightness value of the object, then determines a saturation adjustment coefficient of the object according to the second brightness coefficient, and finally increases the saturation of the object according to the saturation adjustment coefficient.
In some of these embodiments, calculating the saturation adjustment factor for the object based at least on the first number of regions comprises: judging whether the number of the first areas is smaller than the number of the preset areas or not; determining a saturation degree adjustment parameter of the object according to the ratio of the number of the first areas to the number corresponding to the plurality of areas under the condition that the number of the first areas is judged to be not less than the number of the preset areas; and under the condition that the number of the first areas is judged to be smaller than the number of the preset areas, the saturation adjusting parameter of the object is equal to the preset saturation adjusting parameter.
In this embodiment, a method for calculating a saturation adjustment coefficient of an object is provided by determining a saturation adjustment parameter of the object according to a ratio of the number of first regions to the number of corresponding regions.
In some of these embodiments, after determining the saturation adjustment frame for the object based at least on the second luminance coefficient, the method further comprises: acquiring a plurality of continuous images; determining a brightness coefficient of an object in a plurality of consecutive images; judging whether the brightness coefficients of the objects in the continuous multiple images are all larger than a preset coefficient or not; if not, the saturation of the colors of the continuous images is kept unchanged.
In this embodiment, the color saturation adjustment coefficient is determined by obtaining the plurality of images and further according to the brightness coefficients in the plurality of images, so that the stability of the adjustment of the saturation of the color of the vehicle body can be improved, and meanwhile, the saturation of the color of the vehicle body can be adjusted in real time according to whether the brightness coefficients of the objects in the plurality of continuous images are all larger than the preset coefficient.
In some of these embodiments, at least a portion of the image region comprises: an image region of interest. In this embodiment, the interested image area may be a license plate of a vehicle body, or other interested image areas such as a human face.
The embodiments of the present application are described and illustrated below by means of preferred embodiments.
In this embodiment, taking the method applied to the backlight and frontlight states commonly seen in intelligent transportation, taking dynamic adjustment of image colors by vehicle body brightness as an example, and taking a license plate as an interested image area, where the first brightness coefficient is plateY and the adjustment rule is a preset color correction matrix, the value intervals are blY1, blY2, olY1 and olY2, and blY1< blY2< olY1< olY2, the value intervals correspond to coefficients olk1, olk2, blk1 and blk2, and the relationship is blk1< blk2<1< olk1< olk2, where the coefficients olk1 and olk2 are multiplied by a value olY2 in the value interval to obtain a second value interval, and blk1 and blk2 are multiplied by a value blY1 in the value digital interval to obtain the first value interval as an example, the color adjustment method of the image includes the following steps:
step 1, firstly, judging the forward and backward light state of the vehicle body. For example, the camera may first obtain the license plate brightness plateau of the vehicle body, and preset the numerical ranges blY1, blY2, olY1, and olY2 for determining the forward and backward light states, where blY1< blY2< olY1< olY2, and the initial state of the default state is a normal state, i.e., a non-forward and non-backward light state. When in the normal state, if the place > olY2 is detected, it is determined that the current state is switched from the normal state to the taillight state, and step S202 is executed; if the place is detected to be < blY1, judging that the current state is switched from the normal state to the backlight state, and executing step S203; when the display is in a backlight state and when the display is detected to be blY2, judging that the current state is switched from the backlight state to a normal state; when in the fair state, when the place < olY1 is detected, it is judged that the current state is switched from the fair state to the normal state.
And 2, when the camera detects that the current state is the smooth state, the camera can further judge the level of the smooth intensity corresponding to the smooth state. It is assumed that coefficients of preset front light intensity levels are olk1 and olk2, wherein 1< olk1< olk2, and then the front light intensity level is judged according to the license plate brightness plateau, the brightness threshold olY2, the coefficient olk1 and the coefficient olk 2. The method for determining the grade of the front light intensity may be that when the camera detects olY2< place < olY2 × olk1, the current grade of the front light intensity is determined to be 1; when olY2 × olk1< place y < olY2 × olk2 is detected, it is determined that the current front light intensity level is 2; when olY2 × okl < place is detected, it is determined that the current front light intensity level is 3. In addition, each of the front light intensity levels in the above embodiments has a corresponding preset color correction matrix, and then the camera selects the corresponding preset color correction matrix for color adjustment according to the current front light intensity level.
And 3, when the camera detects that the current state is the backlight state, the camera can further judge the backlight intensity level corresponding to the backlight state. Assuming that coefficients of preset backlight intensity levels are blk1 and blk2, wherein blk1< blk2<1, the backlight intensity level is determined according to the license plate brightness plateau, the brightness threshold blY1, the coefficient blk1 and the coefficient blk 2. The backlight intensity level may be determined by determining that the current backlight intensity level is 1 when the camera detects blY1 xblk 2< place < blY 1; when blY1 xblk 1< place y < blY1 xblk 2 is detected, it is determined that the current backlight intensity level is 2; when the place y < blY1 × blk1 is detected, it is determined that the current backlight intensity level is 3. In addition, each backlight intensity level in the above embodiments has a corresponding preset color correction matrix, and then the camera selects the corresponding preset color correction matrix for color adjustment according to the current backlight intensity level.
And 4, when the vehicle body is in a front light state, the camera can also calculate a color saturation adjustment coefficient according to the brightness of the vehicle body, so as to adjust the color saturation of the picture. For example, the camera may divide the vehicle body image into N sub-regions, count the luminances Yi (i is 1 to N) of the N sub-regions, preset a luminance threshold Y, preset basic adjustment coefficients C1, C2, and preset a threshold N1 of the number of regions for starting calculation of the adjustment coefficients. When the luminance Yi > Y of the sub-region is detected, then cnt accumulates 1. When the cnt is detected to be larger than or equal to N1, the saturation adjustment coefficient K1 is 1+ cnt/NxC 1; when cnt < N1 is detected, K1 ═ 1. In order to further increase the stability of the adjustment, an adjustment coefficient for controlling the stability of the adjustment may be further added, and the calculation method is as follows: when the brightness of the vehicle bodies of N continuous vehicles meets cnt > N1, according to the adjustment coefficient formula: k2 is 1+ n/vecN × C2, where n is equal to or less than vecN, and vecN is a preset upper limit value; if n > vecN, the value of n is limited to vecN. Finally the saturation is adjusted according to the following formula: and K is K1 multiplied by K2, and the coefficient K is acted on the original saturation value to realize the dynamic adjustment of the color saturation.
The embodiments of the present application will now be described and illustrated by means of preferred embodiments and accompanying drawings.
Fig. 2 is a flowchart of an image color adjustment method according to a preferred embodiment of the present application, in this embodiment, taking an interested image area as a license plate, a first luminance coefficient as a place, and an adjustment rule as a preset color correction matrix as an example, the method includes the following steps:
in step S200, the camera starts to operate.
Step S201, a camera acquires the license plate brightness place and the brightness information of the vehicle body region blocks.
Step S202, the camera judges whether the current state is a forward/backward light state according to the place and the numerical interval, if so, the step S203 is executed; if not, step S209 is executed.
Step S203, the camera judges whether the current state is a smooth state, if yes, step S204 is executed; if not, go to step S207.
And step S204, the camera calculates the level of the direct light intensity according to the license plate brightness place and the second numerical interval.
In step S205, the camera selects a color correction matrix corresponding to the front light intensity level from a preset front light color correction matrix group according to the front light intensity level.
And step S206, the camera calculates a color saturation adjustment coefficient according to the regional brightness information of the vehicle body image and the number of the vehicle bodies continuously meeting the conditions, and adjusts the vehicle body color according to the color saturation adjustment coefficient.
Step S207, the camera calculates the backlight intensity level according to the license plate brightness place and the first numerical interval.
In step S208, the camera selects a color correction matrix corresponding to the backlight intensity level from a preset backlight color correction matrix group according to the backlight intensity level.
In step S209, the camera ends the operation.
The present embodiment further provides an image color adjusting apparatus, which is used to implement the foregoing embodiments and preferred embodiments, and the description of the apparatus is omitted here. As used hereinafter, the terms "module," "unit," "subunit," and the like may implement a combination of software and/or hardware for a predetermined function. Although the means described in the embodiments below are preferably implemented in software, an implementation in hardware, or a combination of software and hardware is also possible and contemplated.
Fig. 3 is a block diagram of a color adjustment apparatus for an image according to an embodiment of the present application, as shown in fig. 3, the apparatus including:
a first obtaining module 301, configured to obtain an image and identify an object in the image;
a first determining module 302, coupled to the first obtaining module 301, configured to determine a brightness coefficient of the object according to a brightness value of at least a partial image region of the object;
a second determining module 303, coupled to the first determining module 302, for determining a value interval into which the brightness coefficient falls;
a second obtaining module 304, coupled to the second determining module 303, configured to obtain an adjustment rule corresponding to the value interval, and adjust the color of the object according to the adjustment rule.
In some of these embodiments, the apparatus further comprises: the third determining module is used for determining the backlight intensity level of the backlight state according to the brightness coefficient under the condition that the numerical value interval in which the brightness coefficient falls is the first numerical value interval; and the third acquisition module is used for acquiring an adjustment rule corresponding to the backlight intensity level.
In some of these embodiments, the apparatus further comprises: the fourth determining module is used for determining the level of the taillight intensity of the taillight state according to the brightness coefficient under the condition that the numerical value interval in which the brightness coefficient falls is the second numerical value interval; and the fourth acquisition module is used for acquiring the adjustment rule corresponding to the front light intensity level.
In some of these embodiments, the apparatus further comprises: a fifth determining module, configured to determine a second brightness coefficient of the object according to the brightness value of the object; a sixth determining module, configured to determine a saturation adjustment coefficient of the object according to at least the second luminance coefficient; and the increasing module is used for increasing the saturation of the color of the object according to the saturation adjusting coefficient.
In some of these embodiments, the apparatus further comprises: the dividing module is used for equally dividing the object into a plurality of areas; a fifth obtaining module, configured to obtain a luminance coefficient of each of the plurality of regions; the seventh determining module is used for determining the number of the first areas with the brightness coefficients larger than the preset brightness value in each area; and the calculation module is used for calculating the saturation adjustment coefficient of the object at least according to the number of the first areas.
In some of these embodiments, the apparatus further comprises: the first judging module is used for judging whether the number of the first areas is smaller than the number of the preset areas; the eighth determining module is used for determining the saturation adjusting parameter of the object according to the ratio of the number of the first areas to the number corresponding to the plurality of areas under the condition that the number of the first areas is judged to be not less than the preset number of areas; and under the condition that the number of the first areas is judged to be smaller than the number of the preset areas, the saturation adjusting parameter of the object is equal to the preset saturation adjusting parameter.
In some of these embodiments, the apparatus further comprises: a fifth acquiring module, configured to acquire a plurality of consecutive images; the ninth determining module is used for determining the brightness coefficient of the object in a plurality of continuous images; the second judging module is used for judging whether the brightness coefficients of the objects in the plurality of continuous images are all larger than the preset coefficient; and the maintaining module is used for maintaining the saturation of the colors of the continuous images unchanged if the saturation of the colors of the continuous images is not changed.
In some of these embodiments, at least a portion of the image region comprises: an image region of interest.
The above modules may be functional modules or program modules, and may be implemented by software or hardware. For a module implemented by hardware, the modules may be located in the same processor; or the modules can be respectively positioned in different processors in any combination.
In addition, the color adjustment method of the image according to the embodiment of the present application described in conjunction with fig. 1 may be implemented by a color adjustment device of the image. Fig. 4 is a schematic hardware configuration diagram of an image color adjustment apparatus according to an embodiment of the present application.
The color adjustment device of the image may comprise a processor 41 and a memory 42 storing computer program instructions.
Specifically, the processor 41 may include a Central Processing Unit (CPU), or A Specific Integrated Circuit (ASIC), or may be configured to implement one or more Integrated circuits of the embodiments of the present Application.
Memory 45 may include, among other things, mass storage for data or instructions. By way of example, and not limitation, memory 45 may include a Hard Disk Drive (Hard Disk Drive, abbreviated HDD), a floppy Disk Drive, a Solid State Drive (SSD), flash memory, an optical Disk, a magneto-optical Disk, tape, or a Universal Serial Bus (USB) Drive or a combination of two or more of these. Memory 45 may include removable or non-removable (or fixed) media, where appropriate. The memory 45 may be internal or external to the data processing apparatus, where appropriate. In a particular embodiment, the memory 45 is a Non-Volatile (Non-Volatile) memory. In particular embodiments, Memory 45 includes Read-Only Memory (ROM) and Random Access Memory (RAM). The ROM may be mask-programmed ROM, Programmable ROM (PROM), Erasable PROM (EPROM), Electrically Erasable PROM (EEPROM), Electrically rewritable ROM (earrom) or FLASH Memory (FLASH), or a combination of two or more of these, where appropriate. The RAM may be a Static Random-Access Memory (SRAM) or a Dynamic Random-Access Memory (DRAM), where the DRAM may be a Fast Page Mode Dynamic Random-Access Memory (FPMDRAM), an Extended Data Output Dynamic Random Access Memory (EDODRAM), a Synchronous Dynamic Random Access Memory (SDRAM), and the like.
Memory 45 may be used to store or cache various data files for processing and/or communication use, as well as possibly computer program instructions for execution by processor 42.
The processor 41 realizes the color adjustment method of any one of the images in the above embodiments by reading and executing computer program instructions stored in the memory 42.
In some of these embodiments, the color adjustment device for the image may also include a communication interface 43 and a bus 40. As shown in fig. 4, the processor 41, the memory 42, and the communication interface 43 are connected via the bus 40 to complete mutual communication.
The communication interface 43 is used for implementing communication between modules, devices, units and/or apparatuses in the embodiments of the present application. The communication interface 43 may also be implemented with other components such as: the data communication is carried out among external equipment, image/data acquisition equipment, a database, external storage, an image/data processing workstation and the like.
The bus 40 includes hardware, software, or both to couple the components of the color adjustment device of the image to each other. Bus 40 includes, but is not limited to, at least one of the following: data Bus (Data Bus), Address Bus (Address Bus), Control Bus (Control Bus), Expansion Bus (Expansion Bus), and Local Bus (Local Bus). By way of example, and not limitation, Bus 40 may include an Accelerated Graphics Port (AGP) or other Graphics Bus, an Enhanced Industry Standard Architecture (EISA) Bus, a Front-Side Bus (FSB), a HyperTransport (HT) interconnect, an ISA (ISA) Bus, an InfiniBand (InfiniBand) interconnect, a Low Pin Count (LPC) Bus, a memory Bus, a Micro Channel Architecture (MCA) Bus, a Peripheral Component Interconnect (PCI) Bus, a PCI-Express (PCI-X) Bus, a Serial Advanced Technology Attachment (SATA) Bus, a Video electronics standards Association Local Bus (VLB) Bus, or other suitable Bus or a combination of two or more of these. Bus 40 may include one or more buses, where appropriate. Although specific buses are described and shown in the embodiments of the application, any suitable buses or interconnects are contemplated by the application.
The image color adjustment device may execute the image color adjustment method in the embodiment of the present application based on the acquired image, thereby implementing the image color adjustment method described in conjunction with fig. 1.
In addition, in combination with the color adjustment method for an image in the foregoing embodiments, the present application embodiment may provide a computer-readable storage medium to implement the method. The computer readable storage medium having stored thereon computer program instructions; the computer program instructions, when executed by a processor, implement a method of color adjustment of an image as in any of the above embodiments.
The technical features of the embodiments described above may be arbitrarily combined, and for the sake of brevity, all possible combinations of the technical features in the embodiments described above are not described, but should be considered as being within the scope of the present specification as long as there is no contradiction between the combinations of the technical features.
The above-mentioned embodiments only express several embodiments of the present application, and the description thereof is more specific and detailed, but not construed as limiting the scope of the invention. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the concept of the present application, which falls within the scope of protection of the present application. Therefore, the protection scope of the present patent shall be subject to the appended claims.

Claims (11)

1. A method of color adjustment of an image, the method comprising:
acquiring an image and identifying an object in the image;
determining a first brightness coefficient of the object according to the brightness value of at least a partial image area of the object;
determining a numerical value interval in which the brightness coefficient falls;
and acquiring an adjustment rule corresponding to the numerical value interval, and adjusting the color of the object according to the adjustment rule.
2. The method according to claim 1, wherein the numerical value section includes a first numerical value section corresponding to an adjustment rule when the object is in a backlit state; acquiring an adjustment rule corresponding to the value interval includes:
determining the backlight intensity level of the backlight state according to the brightness coefficient under the condition that the numerical value interval in which the brightness coefficient falls is the first numerical value interval;
and acquiring an adjusting rule corresponding to the backlight intensity level.
3. The method according to claim 1, wherein the numerical value section includes a second numerical value section corresponding to an adjustment rule when the object is in a taillight state; acquiring an adjustment rule corresponding to the value interval includes:
determining the taillight intensity level of the taillight state according to the brightness coefficient under the condition that the numerical value interval in which the brightness coefficient falls is the second numerical value interval;
and acquiring an adjusting rule corresponding to the front light intensity level.
4. The method according to claim 1, wherein the numerical value section includes a second numerical value section corresponding to an adjustment rule when the object is in a taillight state, and adjusting the color of the object according to the adjustment rule includes:
determining a second brightness coefficient of the object according to the brightness value of the object;
determining a saturation adjustment coefficient of the object according to at least the second brightness coefficient;
and increasing the saturation of the color of the object according to the saturation adjustment coefficient.
5. The method of adjusting color of an image according to claim 4, wherein determining the saturation adjustment coefficient of the object based on at least the second luminance coefficient comprises:
equally dividing the object into a plurality of areas;
acquiring a brightness coefficient of each of the plurality of regions;
determining the number of first areas with brightness coefficients larger than a preset brightness value in each area;
and calculating a saturation adjustment coefficient of the object at least according to the number of the first areas.
6. The method of claim 5, wherein calculating a saturation adjustment coefficient for the object based on at least the first number of regions comprises:
judging whether the number of the first areas is smaller than the number of preset areas or not;
determining a saturation adjustment parameter of the object according to the ratio of the number of the first areas to the number corresponding to the plurality of areas under the condition that the number of the first areas is judged to be not less than the number of preset areas;
and under the condition that the number of the first areas is judged to be smaller than the number of the preset areas, the saturation adjusting parameter of the object is equal to the preset saturation adjusting parameter.
7. The method of adjusting color of an image according to claim 4, wherein after determining the saturation adjustment system of the object based on at least the second luminance coefficient, the method further comprises:
acquiring a plurality of continuous images;
determining a luminance coefficient of the object in the consecutive plurality of images;
judging whether the brightness coefficients of the objects in the continuous multiple images are all larger than a preset coefficient or not;
if not, keeping the saturation of the colors of the continuous images unchanged.
8. The method for adjusting color of an image according to claim 1, wherein the at least a portion of the image area comprises: an image region of interest.
9. An apparatus for adjusting color of an image, the apparatus comprising:
the first acquisition module is used for acquiring an image and identifying an object in the image;
a first determining module, configured to determine a brightness coefficient of the object according to a brightness value of at least a partial image region of the object;
the second determination module is used for determining a numerical value interval in which the brightness coefficient falls;
and the second acquisition module is used for acquiring an adjustment rule corresponding to the numerical value interval and adjusting the color of the object according to the adjustment rule.
10. An apparatus for color adjustment of an image, comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the processor implements a method for color adjustment of an image according to any one of claims 1 to 8 when executing the computer program.
11. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out a method of color adjustment of an image according to any one of claims 1 to 8.
CN202010572484.2A 2020-06-22 2020-06-22 Image color adjustment method, device, equipment and computer readable storage medium Pending CN111882493A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010572484.2A CN111882493A (en) 2020-06-22 2020-06-22 Image color adjustment method, device, equipment and computer readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010572484.2A CN111882493A (en) 2020-06-22 2020-06-22 Image color adjustment method, device, equipment and computer readable storage medium

Publications (1)

Publication Number Publication Date
CN111882493A true CN111882493A (en) 2020-11-03

Family

ID=73158160

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010572484.2A Pending CN111882493A (en) 2020-06-22 2020-06-22 Image color adjustment method, device, equipment and computer readable storage medium

Country Status (1)

Country Link
CN (1) CN111882493A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116824906A (en) * 2023-08-29 2023-09-29 成都市巨多广告有限公司 Parking lot guiding method and system with identification function

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20110261261A1 (en) * 2008-12-22 2011-10-27 Rohm Co., Ltd. Image correction processing circuit, semiconductor device, and image correction processing device
CN105025283A (en) * 2015-08-07 2015-11-04 广东欧珀移动通信有限公司 Novel color saturation adjusting method and system and mobile terminal
CN108446705A (en) * 2017-02-16 2018-08-24 华为技术有限公司 The method and apparatus of image procossing
CN108734676A (en) * 2018-05-21 2018-11-02 Oppo广东移动通信有限公司 Image processing method and device, electronic equipment, computer readable storage medium
CN111311513A (en) * 2020-02-11 2020-06-19 浙江大华技术股份有限公司 Method and apparatus for unifying color styles of images and computer storage medium

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20110261261A1 (en) * 2008-12-22 2011-10-27 Rohm Co., Ltd. Image correction processing circuit, semiconductor device, and image correction processing device
CN105025283A (en) * 2015-08-07 2015-11-04 广东欧珀移动通信有限公司 Novel color saturation adjusting method and system and mobile terminal
CN108446705A (en) * 2017-02-16 2018-08-24 华为技术有限公司 The method and apparatus of image procossing
CN108734676A (en) * 2018-05-21 2018-11-02 Oppo广东移动通信有限公司 Image processing method and device, electronic equipment, computer readable storage medium
CN111311513A (en) * 2020-02-11 2020-06-19 浙江大华技术股份有限公司 Method and apparatus for unifying color styles of images and computer storage medium

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116824906A (en) * 2023-08-29 2023-09-29 成都市巨多广告有限公司 Parking lot guiding method and system with identification function
CN116824906B (en) * 2023-08-29 2023-11-17 成都市巨多广告有限公司 Parking lot guiding method and system with identification function

Similar Documents

Publication Publication Date Title
US20210168275A1 (en) Method for imaging controlling, electronic device, and non-transitory computer-readable storage medium
EP3565236B1 (en) Control method, control apparatus, mobile terminal and computer-readable storage medium
CN111614892B (en) Face image acquisition method, shooting device and computer-readable storage medium
US11490024B2 (en) Method for imaging controlling, electronic device, and non-transitory computer-readable storage medium
US20070047803A1 (en) Image processing device with automatic white balance
CN112565621B (en) Endoscope light source brightness and exposure adjusting method and device and readable storage medium
CN109040607B (en) Imaging control method, imaging control device, electronic device and computer-readable storage medium
CN110536172B (en) Video image display adjusting method, terminal and readable storage medium
US11601600B2 (en) Control method and electronic device
CN114143940B (en) Tunnel illumination control method, device, equipment and storage medium
JP4595569B2 (en) Imaging device
CN110809146A (en) Image contrast adjusting method and device, terminal equipment and storage medium
JP2013058859A (en) Image processor, image processing method, and program
KR20140071871A (en) Apparatus and method of calculating flicker-evaluation value
CN107454317B (en) Image processing method, image processing device, computer-readable storage medium and computer equipment
KR20210155743A (en) Method for image processing of high dynamic range sensors for handling white balance
CN112653845B (en) Exposure control method, exposure control device, electronic equipment and readable storage medium
CN111882493A (en) Image color adjustment method, device, equipment and computer readable storage medium
CN110891146B (en) Strong light inhibition method and device
JP2006333205A (en) Imaging apparatus, image processing method and image processing program
CN111435972B (en) Image processing method and device
US10122936B2 (en) Dynamic noise reduction for high dynamic range in digital imaging
CN115334250B (en) Image processing method and device and electronic equipment
CN109982012B (en) Image processing method and device, storage medium and terminal
JP2009063674A (en) Imaging apparatus and flash control method

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination