CN111669519B - Multi-channel CCD image non-uniformity correction method and device and storage medium - Google Patents
Multi-channel CCD image non-uniformity correction method and device and storage medium Download PDFInfo
- Publication number
- CN111669519B CN111669519B CN202010392137.1A CN202010392137A CN111669519B CN 111669519 B CN111669519 B CN 111669519B CN 202010392137 A CN202010392137 A CN 202010392137A CN 111669519 B CN111669519 B CN 111669519B
- Authority
- CN
- China
- Prior art keywords
- channel
- component
- calculating
- accumulated value
- gain
- 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.)
- Active
Links
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N5/00—Details of television systems
- H04N5/222—Studio circuitry; Studio devices; Studio equipment
- H04N5/262—Studio circuits, e.g. for mixing, switching-over, change of character of image, other special effects ; Cameras specially adapted for the electronic generation of special effects
- H04N5/268—Signal distribution or switching
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N9/00—Details of colour television systems
- H04N9/64—Circuits for processing colour signals
- H04N9/646—Circuits for processing colour signals for image enhancement, e.g. vertical detail restoration, cross-colour elimination, contour correction, chrominance trapping filters
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N9/00—Details of colour television systems
- H04N9/64—Circuits for processing colour signals
- H04N9/73—Colour balance circuits, e.g. white balance circuits or colour temperature control
Landscapes
- Engineering & Computer Science (AREA)
- Multimedia (AREA)
- Signal Processing (AREA)
- Transforming Light Signals Into Electric Signals (AREA)
Abstract
The invention discloses a multichannel CCD image non-uniformity correction method, a multichannel CCD image non-uniformity correction device and a storage medium, and can solve the technical problem that the existing method is complex. The method is based on a CCD sensor, and takes any channel of four channels of A, B, C and D as a reference, calculates G component accumulated values of adjacent rows and columns of the channels of A, B, C and D, calculates a gain coefficient of each channel according to the deviation of the G component accumulated values of the adjacent channels and the G component accumulated value of the reference channel, wherein R, G and B components of each channel correspond to one gain coefficient, and finally, the R, G and B components of each channel to be corrected are multiplied by the gain coefficient of the corresponding channel to finish the non-uniformity correction of the image. Compared with the traditional factory calibration algorithm, the method can better adapt to the change of the external environment, and can adjust the gain coefficient in real time according to the change of the environment to realize the automatic correction of the image nonuniformity.
Description
Technical Field
The invention relates to the technical field of digital images, in particular to a method and a device for correcting the nonuniformity of a multichannel CCD image.
Background
In the field of digital image processing, a CCD image sensor usually adopts 2 channels or 4 channels to output image data in order to realize higher frame rate output, an analog image signal of each channel is converted into a digital image signal by an analog-to-digital converter, and in the implementation process, due to differences of circuit routing of each channel and an AD converter, images among the channels have deviations in brightness and chromaticity, which causes seams to appear after image splicing.
The prior art mainly has two kinds: the first method is to calibrate parameters before the equipment leaves the factory, and the defect is that slight deviation may occur again along with the change of the use environment scene or the change of the temperature of the equipment. The second is an automatic correction method, which can well adapt to the change of the using environment of the device to correct the difference of each channel in real time, thereby realizing the non-uniformity correction of the image of each channel of the CCD and having the defect of more complex algorithm.
In the prior art, the non-uniformity correction of each channel is realized by adjusting the difference of each channel by adjusting the parameters of an AD converter and the driving timing sequence of a CCD, and then the parameters are fixed. However, since these parameters are calibrated under specific circumstances and the actual use environment is complicated, the deviation of each channel of the CCD may occur again, so that the automatic correction is required. In the prior art, some methods for automatically correcting the nonuniformity of the CCD channel exist, but the realization mode is more complex.
The most similar implementation scheme is patent CN 103997633B, and the method is complex in adjustment mode, and can well implement automatic correction of brightness difference of each channel, but the method may cause occurrence of color difference of each channel.
Disclosure of Invention
The invention provides a multi-channel CCD image non-uniformity correction method and device, which can solve the technical problem of complexity of the existing method.
In order to achieve the purpose, the invention adopts the following technical scheme:
a multi-channel CCD image non-uniformity correction method comprises the following steps:
the method comprises the following steps:
s100, driving the CCD to output four paths of analog image signals of A, B, C and D, converting the analog image signals into Bayer array images through an AD converter, and completing image splicing;
s200, taking any one of the channels A, B, C and D as a reference, calculating G component accumulated values of adjacent rows and columns of the channels A, B, C and D, calculating a gain coefficient of each channel according to the deviation of the G component accumulated values of the adjacent channels and the G component accumulated value of the reference channel, wherein the R, G and B components of each channel correspond to one gain coefficient, and finally multiplying the R, G and B components of each channel to be corrected by the gain coefficient of the corresponding channel to finish the image non-uniformity correction.
According to the technical scheme, the multichannel CCD image non-uniformity correction method has the following beneficial effects:
1. the method is automatic correction, can better adapt to external environment change compared with the traditional factory calibration algorithm, adjusts the gain coefficient in real time according to the environment change, and realizes automatic correction of image nonuniformity.
2. Compared with other automatic correction methods, on one hand, the method is simple in implementation mode, and can complete gain coefficient determination by only calculating one frame of image, so that non-uniformity correction of the image is realized; on the other hand, the method only counts the G component with the largest occupation proportion to determine the gain coefficient of the whole channel, and the color difference caused by the imbalance of the proportions of the R component, the G component and the B component cannot be caused.
Drawings
FIG. 1 is a schematic diagram of the present invention;
fig. 2 is a flow chart of the method of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, but not all embodiments of the present invention.
As shown in fig. 1, the analog image signal output by the CCD image sensor is converted into an image array in the raw Bayer format by an AD converter, and then the image is spliced, and the non-uniformity of the channel is corrected after the splicing. Because human eyes are sensitive to green, G components account for 1/2, R components and B components account for 1/4 respectively in a Bayer image array, and because G components account for a large specific gravity, the actual difference of each channel can be represented by counting the difference of the G components, so that the embodiment of the invention calculates the gain of each channel by counting the difference of the G components of each channel, and then adjusts the image of each channel through the calculated gain value to realize the non-uniformity correction of each channel.
Specifically, as shown in fig. 2, the multi-channel CCD image non-uniformity correction method according to this embodiment is implemented by the following steps:
s100, driving the CCD to output four paths of analog image signals of A, B, C and D, converting the analog image signals into Bayer array images through an AD converter and completing image splicing;
s200, taking any one of the channels A, B, C and D as a reference, calculating G component accumulated values of adjacent rows and columns of the channels A, B, C and D, calculating a gain coefficient of each channel according to the deviation of the G component accumulated values of the adjacent channels and the G component accumulated value of the reference channel, wherein the R, G and B components of each channel correspond to one gain coefficient, and finally multiplying the R, G and B components of each channel to be corrected by the gain coefficient of the corresponding channel to finish the image nonuniformity correction.
Wherein the step S200 is specifically as follows:
s201, taking an A channel as a reference, calculating an accumulated value Gra and a last column G component accumulated value Gca of a first row G component of the A channel, calculating an accumulated value Grb and a first column G component accumulated value Gcb of a first row G component of a B channel, calculating an accumulated value Grc and a last column G component accumulated value Gcc of a last row G component of a C channel, and calculating a last row G component accumulated value Grd and a first column G component accumulated value Gcd of a D channel;
s202, calculating C channel gain Cgain, wherein Cgain is = Gra/Grc; and calculating the gain Bgain of the B channel, wherein Bgain = Gca/Gcb.
And S203, calculating a D channel gain Dgain, and if the gain of the C channel is already calculated by taking the C channel as a reference, then Dgain = (Gcc) × Cgain)/Gcd. If the B channel is taken as a reference, since the B channel gain is already calculated, dgain = (Grb × Bgain)/Grd.
And S204, taking the channel A as a reference, and multiplying each pixel output by the channels B, C and D by the gain value of the corresponding channel to finish the non-uniformity correction of the image of each channel.
In summary, the method of the embodiment of the invention is simple in implementation, and the gain coefficient determination can be completed only by calculating one frame of image, so that the non-uniformity correction of the image is realized; on the other hand, the method only counts the G component with the largest occupation proportion to determine the gain coefficient of the whole channel, and the color difference caused by the imbalance of the proportions of the R component, the G component and the B component cannot be caused.
On the other hand, the embodiment of the invention also discloses a multichannel CCD image non-uniformity correction system, which comprises the following units:
the G component accumulated value calculating unit is used for calculating the accumulated value Gra of the G component in the first row of the A channel and the accumulated value Gca of the G component in the last column of the A channel by taking the A channel as a reference; calculating an accumulated value Grb of a first row G component and an accumulated value Gcb of a first column G component of the B channel; calculating an accumulated value Grc of the G component on the last row of the C channel and an accumulated value Gcc of the G component on the last column; calculating the accumulated value Grd of the G component in the last row and the accumulated value Gcd of the G component in the first column of the D channel;
a gain Cgain calculation unit for calculating the C-channel gain Cgain, cgain = Gra/Grc; calculating B channel gain Bgain, wherein Bgain = Gca/Gcb; calculating a D channel gain Dgain, if the C channel is taken as a reference, because the gain of the C channel is already calculated, the Dgain = (Gcc × Cgain)/Gcd; if the B channel is taken as a reference, since the B channel gain is already calculated, dgain = (Grb × Bgain)/Grd;
and the correcting unit is used for multiplying each pixel output by the channels B, C and D by the gain value of the corresponding channel by taking the channel A as a reference so as to finish the non-uniformity correction of the image of each channel.
It is understood that the system provided by the embodiment of the present invention corresponds to the method provided by the embodiment of the present invention, and the explanation, the example and the beneficial effects of the related contents can refer to the corresponding parts in the method.
The embodiment of the application also provides an electronic device, which comprises a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory complete mutual communication through the communication bus,
a memory for storing a computer program;
the processor is used for realizing the picture transmission method for the IM software platform when executing the program stored in the memory, and the method comprises the following steps:
s100, driving the CCD to output four paths of analog image signals of A, B, C and D, converting the analog image signals into Bayer array images through an AD converter and completing image splicing;
s200, taking any one of the channels A, B, C and D as a reference, calculating G component accumulated values of adjacent rows and columns of the channels A, B, C and D, calculating a gain coefficient of each channel according to the deviation of the G component accumulated values of the adjacent channels and the G component accumulated value of the reference channel, wherein the R, G and B components of each channel correspond to one gain coefficient, and finally multiplying the R, G and B components of each channel to be corrected by the gain coefficient of the corresponding channel to finish the image nonuniformity correction.
The communication bus mentioned in the electronic device may be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus. The communication bus may be divided into an address bus, a data bus, a control bus, etc. For ease of illustration, only one thick line is shown, but this does not mean that there is only one bus or one type of bus.
The communication interface is used for communication between the electronic equipment and other equipment.
The Memory may include a Random Access Memory (RAM) or a Non-Volatile Memory (NVM), for example, at least one disk Memory. Optionally, the memory may also be at least one memory device located remotely from the processor.
The Processor may be a general-purpose Processor, including a Central Processing Unit (CPU), a Network Processor (NP), and so on; the Integrated Circuit may also be a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field Programmable Gate Array (FPGA), or other Programmable logic devices, discrete Gate or transistor logic devices, or discrete hardware components.
In another embodiment provided by the present application, a computer-readable storage medium is further provided, in which a computer program is stored, and the computer program, when executed by a processor, implements the steps of any one of the above-mentioned multichannel CCD image non-uniformity correction methods.
In yet another embodiment provided by the present application, there is also provided a computer program product containing instructions which, when run on a computer, cause the computer to perform any of the above-described embodiments for multi-channel CCD image non-uniformity correction methods.
In the above embodiments, the implementation may be wholly or partially realized by software, hardware, firmware, or any combination thereof. When implemented in software, may be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When loaded and executed on a computer, cause the processes or functions described in accordance with the embodiments of the application to occur, in whole or in part. The computer may be a general purpose computer, a special purpose computer, a network of computers, or other programmable device. The computer instructions may be stored in a computer readable storage medium or transmitted from one computer readable storage medium to another, for example, from one website site, computer, server, or data center to another website site, computer, server, or data center via wired (e.g., coaxial cable, fiber optic, digital Subscriber Line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.). The computer-readable storage medium can be any available medium that can be accessed by a computer or a data storage device, such as a server, a data center, etc., that incorporates one or more of the available media. The usable medium may be a magnetic medium (e.g., floppy Disk, hard Disk, magnetic tape), an optical medium (e.g., DVD), or a semiconductor medium (e.g., solid State Disk (SSD)), among others.
It should be noted that, in this document, relational terms such as first and second, and the like are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrases "comprising a," "8230," "8230," or "comprising" does not exclude the presence of additional like elements in a process, method, article, or apparatus that comprises the element.
The above examples are only intended to illustrate the technical solution of the present invention, but not to limit it; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions of the embodiments of the present invention.
Claims (3)
1. A multichannel CCD image non-uniformity correction method is based on a CCD image sensor and is characterized in that:
the method comprises the following steps:
s100, driving the CCD to output four paths of analog image signals of A, B, C and D, converting the analog image signals into Bayer array images through an AD converter and completing image splicing;
s200, taking any one of the channels A, B, C and D as a reference, calculating G component accumulated values of adjacent rows and columns of the channels A, B, C and D, calculating a gain coefficient of each channel according to the deviation of the G component accumulated values of the adjacent channels and the G component accumulated value of the reference channel, wherein the R, G and B components of each channel correspond to one gain coefficient, and finally multiplying the R, G and B components of each channel to be corrected by the gain coefficient of the corresponding channel to finish the non-uniformity correction of the image;
the S200 specifically includes:
S201、
calculating an accumulated value Gra of a first row G component and an accumulated value Gca of a last column G component of the channel A by taking the channel A as a reference;
calculating an accumulated value Grb of a first row G component and an accumulated value Gcb of a first column G component of the B channel;
calculating an accumulated value Grc of the G component on the last row of the C channel and an accumulated value Gcc of the G component on the last column;
calculating a G component accumulated value Grd of the last row of the D channel and a G component accumulated value Gcd of a first column;
S202、
calculating the C channel gain Cgain, wherein Cgain = Gra/Grc;
calculating the gain Bgain of the B channel, wherein Bgain = Gca/Gcb;
S203、
calculating a D channel gain Dgain, if the gain of the C channel is already calculated by taking the C channel as a reference, then Dgain = (Gcc) < Cgain)/Gcd; if the B channel is taken as a reference, since the B channel gain is already calculated, dgain = (Grb × Bgain)/Grd;
S204、
and taking the channel A as a reference, and multiplying each pixel output by the channels B, C and D by the gain value of the corresponding channel to finish the non-uniformity correction of the image of each channel.
2. A multichannel CCD image nonuniformity correcting unit is characterized in that:
the device comprises the following units:
the G component accumulated value calculating unit is used for calculating the accumulated value Gra of the G component in the first row of the A channel and the accumulated value Gca of the G component in the last column of the A channel by taking the A channel as a reference; calculating an accumulated value Grb of a first row G component and an accumulated value Gcb of a first column G component of the B channel; calculating an accumulated value Grc of the G component on the last row of the C channel and an accumulated value Gcc of the G component on the last column; calculating a G component accumulated value Grd of the last row of the D channel and a G component accumulated value Gcd of a first column;
a gain Cgain computing unit for computing the C channel gain Cgain, cgain = Gra/Grc; calculating B channel gain Bgain, wherein Bgain = Gca/Gcb; calculating a D channel gain Dgain, if the C channel is taken as a reference, because the gain of the C channel is already calculated, the Dgain = (Gcc × Cgain)/Gcd; if the B channel is taken as a reference, since the B channel gain is already calculated, dgain = (Grb × Bgain)/Grd;
and the correcting unit is used for multiplying each pixel output by the channels B, C and D by the gain value of the corresponding channel by taking the channel A as a reference so as to finish the non-uniformity correction of the image of each channel.
3. A computer-readable storage medium characterized by: the computer-readable storage medium has stored therein a computer program which, when executed by a processor, implements the multi-channel CCD image non-uniformity correction method of claim 1.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202010392137.1A CN111669519B (en) | 2020-05-11 | 2020-05-11 | Multi-channel CCD image non-uniformity correction method and device and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202010392137.1A CN111669519B (en) | 2020-05-11 | 2020-05-11 | Multi-channel CCD image non-uniformity correction method and device and storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN111669519A CN111669519A (en) | 2020-09-15 |
CN111669519B true CN111669519B (en) | 2022-10-28 |
Family
ID=72383567
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202010392137.1A Active CN111669519B (en) | 2020-05-11 | 2020-05-11 | Multi-channel CCD image non-uniformity correction method and device and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN111669519B (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN117135477A (en) * | 2023-09-01 | 2023-11-28 | 脉冲视觉(北京)科技有限公司 | Data fusion method and device in sensor, electronic equipment and storage medium |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2013074187A1 (en) * | 2011-11-14 | 2013-05-23 | Analog Devices, Inc. | Method and device for reducing inter-channel coupling in interleaved and multi-channel adcs |
CN103997633A (en) * | 2014-06-04 | 2014-08-20 | 武汉烽火众智数字技术有限责任公司 | Automatic multi-channel CCD image splicing heterogeneity correction method |
CN105791792A (en) * | 2014-12-19 | 2016-07-20 | 西安恒川商贸有限公司 | Automatic white balance method for camera based on simulated annealing algorithm |
CN105894449A (en) * | 2015-11-11 | 2016-08-24 | 乐卡汽车智能科技(北京)有限公司 | Method and system for overcoming abrupt color change in image fusion processes |
-
2020
- 2020-05-11 CN CN202010392137.1A patent/CN111669519B/en active Active
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2013074187A1 (en) * | 2011-11-14 | 2013-05-23 | Analog Devices, Inc. | Method and device for reducing inter-channel coupling in interleaved and multi-channel adcs |
CN103997633A (en) * | 2014-06-04 | 2014-08-20 | 武汉烽火众智数字技术有限责任公司 | Automatic multi-channel CCD image splicing heterogeneity correction method |
CN105791792A (en) * | 2014-12-19 | 2016-07-20 | 西安恒川商贸有限公司 | Automatic white balance method for camera based on simulated annealing algorithm |
CN105894449A (en) * | 2015-11-11 | 2016-08-24 | 乐卡汽车智能科技(北京)有限公司 | Method and system for overcoming abrupt color change in image fusion processes |
Also Published As
Publication number | Publication date |
---|---|
CN111669519A (en) | 2020-09-15 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN112073703B (en) | Method and device for adjusting color correction matrix, terminal equipment and medium | |
KR101651620B1 (en) | Calibration method of display device using camera module and apparatus thereof | |
US20200137334A1 (en) | Image noise calibration method and apparatus, image noise reduction method and apparatus, and image processing apparatus | |
JP2008153768A (en) | Imaging apparatus, and white balance processor | |
CN104869380A (en) | Image processing apparatus and image processing method | |
CN111669519B (en) | Multi-channel CCD image non-uniformity correction method and device and storage medium | |
CN111669560A (en) | Real-time automatic white balance correction method and system based on FPGA and storage medium | |
KR101639664B1 (en) | Photographing apparatus and photographing method | |
CN113781958B (en) | Optical compensation method and device for display panel | |
TWI514876B (en) | Image sensor and compensation method thereof | |
WO2016206247A1 (en) | Method and drive circuit for correcting lcd display effect and liquid crystal display device | |
CN112468793B (en) | Color adjusting method and device of OLED screen and computer readable storage medium | |
JP2015231140A (en) | Image processing device, image processing method, and program | |
JP5631769B2 (en) | Image processing device | |
CN111669559A (en) | Multichannel CCD image brightness and chromaticity difference correction method and device and storage medium | |
CN116709036A (en) | Automatic exposure method, device and equipment based on screen gray scale and exposure time | |
US20140267838A1 (en) | Image Signal Processor Circuits and Methods for Correcting Crosstalk Artifacts | |
CN112243116B (en) | Method and device for adjusting multichannel lens shadow compensation LSC gain, storage medium and image processing equipment | |
WO2023010753A1 (en) | Color gamut mapping method and apparatus, terminal device, and storage medium | |
US8659700B2 (en) | Method for converting a video signal for flicker compensation, and associated conversion device | |
WO2020056629A1 (en) | Bayer image detection method and device and machine-readable storage medium | |
CN101330564A (en) | Method for correcting signal and circuit thereof as well as method for correcting image signal and circuit thereof | |
CN113542593B (en) | Image processing method and device and terminal equipment | |
TWI817610B (en) | White balance coefficient correction method and electronic device | |
CN114845094B (en) | Color correction method and device |
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 | ||
CB02 | Change of applicant information |
Address after: Room 707-710, 7th floor, building B3, innovation industrial park, No. 800, Wangjiang West Road, hi tech Zone, Hefei City, Anhui Province Applicant after: Anhui Baicheng Huitong Technology Co.,Ltd. Address before: Room 707-710, 7th floor, building B3, innovation industrial park, No. 800, Wangjiang West Road, hi tech Zone, Hefei City, Anhui Province Applicant before: ANHUI BAI CHENG HUI TONG TECHNOLOGY CO.,LTD. |
|
CB02 | Change of applicant information | ||
GR01 | Patent grant | ||
GR01 | Patent grant |