An underwater image correction method and system based on adaptive color enhancement

By using an adaptive color enhancement method, the mean values ​​of underwater image channels are analyzed and compensated separately. Combined with minimum color loss constraints and CIELAB adjustment, the problem of color distortion in underwater images is solved, and the image quality is improved.

CN118735829BActive Publication Date: 2025-11-11GUANGDONG MEDICAL UNIV
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202410834346.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-06-26
Publication Date
2025-11-11
Estimated Expiration
2044-06-26

AI Technical Summary

Technical Problem

Existing underwater image color restoration systems either undercompensate or overcompensate the red channel, resulting in images displaying a predominantly blue or green hue, thus affecting image quality.

Method used

An adaptive color enhancement method is adopted. By analyzing the mean values ​​of image channels in the RGB color space, images are divided into those with a greenish or blue tint. Color compensation is then performed separately for each image. Finally, color balance is achieved by utilizing minimum color loss constraints and adjustments to the CIELAB color space.

Benefits of technology

It improves the color restoration of underwater images and enhances the natural color representation of images, making it suitable for scientific research, marine surveys, and underwater construction.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118735829B_ABST
    Figure CN118735829B_ABST
Patent Text Reader

Abstract

This invention discloses an underwater image correction method and system based on adaptive color enhancement. The invention first performs preliminary color compensation processing on the acquired original underwater image to be corrected; then, it uses a minimum color loss constraint to perform equalization adjustment on the result of the preliminary compensation processing; finally, it performs color compensation processing on the result of the equalization adjustment to complete the image correction of the original underwater image to be corrected. This invention can improve the color restoration effect and can be widely applied in the field of image processing technology.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of image processing technology, and in particular to an underwater image correction method and system based on adaptive color enhancement. Background Technology

[0002] In recent years, underwater remote sensing analysis has become increasingly important due to advancements in remote sensing technology. However, interference factors such as light absorption and scattering during propagation affect the quality of captured underwater images, leading to color distortion, inappropriate contrast, and blurred details. Therefore, restoring the original colors of captured underwater images is crucial.

[0003] Existing underwater image color restoration systems do not achieve ideal results. The main reason is that the red channel in underwater images typically loses a significant amount of information, resulting in a predominantly blue or green hue. However, existing systems use a uniform restoration mode for both blue and green channels, leading to either overcompensation or undercompensation of the red channel. Summary of the Invention

[0004] In view of this, embodiments of the present invention provide an underwater image correction method and system based on adaptive color enhancement to improve the effect of color restoration.

[0005] One aspect of this invention provides an underwater image correction method based on adaptive color enhancement, comprising the following steps:

[0006] Preliminary color compensation processing is performed on the acquired original underwater images to be corrected;

[0007] The results of the preliminary compensation process are balanced and adjusted using a minimum color loss constraint.

[0008] The result of the equalization adjustment is subjected to color compensation processing to complete the image correction of the original underwater image to be corrected.

[0009] In some embodiments, the preliminary color compensation processing of the acquired original underwater image to be corrected includes the following steps:

[0010] Acquire the original underwater image to be corrected;

[0011] In the RGB color space, determine the color mean of each channel of the original underwater image to be corrected;

[0012] Based on the color mean values ​​of the original underwater image to be corrected in the green channel and the blue channel, it is determined whether the original underwater image to be corrected is a greenish image or a bluish image.

[0013] Perform color compensation on images that are too green or too blue;

[0014] The expression for the average color value is:

[0015]

[0016] in, The color mean of the c channel is represented by L; the length of the original underwater image to be corrected is represented by H; and the height of the original underwater image to be corrected is represented by I. i,j This represents the color value of the corresponding channel at length value i and height value j.

[0017] In some embodiments, color compensation for greenish or bluish images includes the following steps:

[0018] For the greenish image, the first compensation process formula is used to compensate for the loss in the red and blue channels by using the information contained in the green channel.

[0019] For the bluish image, the second compensation process formula is used to compensate the information contained in the red channel with the information contained in the green channel.

[0020] The formula for the first compensation process is as follows:

[0021]

[0022] The formula for the second compensation process is:

[0023]

[0024] Among them, I r (x),I g (x),I b (x) represents the information of the red, green, and blue channels in the underwater image, I′ r (x),I' g (x), I′ b (x) represents the compensated information for the red, green, and blue channels. This represents the average values ​​of the red, green, and blue channels of the original underwater image.

[0025] In some embodiments, the process of applying a minimum color loss constraint to balance the result of the preliminary compensation process includes the following steps:

[0026] Based on the results of the preliminary compensation process, the color mean of the original underwater image to be corrected in each channel is obtained;

[0027] Based on the preset minimum color loss formula and the color mean, the compensation formula in the preliminary compensation process is updated until the difference between the color mean of each channel is less than a fixed threshold.

[0028] In some embodiments, the expression for the minimum color loss formula is:

[0029]

[0030] Among them, L color Represents the minimum color loss; This represents the average values ​​of the red, green, and blue channels of the original underwater image.

[0031] In some embodiments, performing color compensation processing on the result of the equalization adjustment to complete the image correction of the original underwater image to be corrected includes the following steps:

[0032] The compensation of channels a and b in the CI ELAB color space of the original underwater image to be corrected is adjusted to convert the RGB color space to the CI ELAB color space.

[0033] In some embodiments, the compensation formula for converting the RGB color space to the CI ELAB color space is:

[0034]

[0035] Among them, the channel with the larger mean value between channel a and channel b is represented as I. max The channel with the smaller mean is represented as I. min γ is the adjustment parameter; Representing I max The average value; Representing I min The average value.

[0036] Another aspect of this invention provides an underwater image correction system based on adaptive color enhancement, comprising:

[0037] The first module is used to perform preliminary color compensation processing on the acquired original underwater image to be corrected;

[0038] The second module is used to balance and adjust the results of the preliminary compensation process using a minimum color loss constraint.

[0039] The third module is used to perform color compensation processing on the result of the equalization adjustment, thereby completing the image correction of the original underwater image to be corrected.

[0040] Another aspect of the present invention provides an electronic device, including a processor and a memory;

[0041] The memory is used to store programs;

[0042] The processor executes the program to implement the method described above.

[0043] Another aspect of this invention provides a computer-readable storage medium storing a program that is executed by a processor to implement the methods described above.

[0044] This invention also discloses a computer program product or computer program, which includes computer instructions stored in a computer-readable storage medium. A processor of a computer device can read the computer instructions from the computer-readable storage medium and execute the computer instructions, causing the computer device to perform the aforementioned method.

[0045] The embodiments of the present invention first perform preliminary color compensation processing on the acquired original underwater image to be corrected; then, a minimum color loss constraint is used to perform equalization adjustment on the result of the preliminary compensation processing; finally, color compensation processing is performed on the result of the equalization adjustment to complete the image correction of the original underwater image to be corrected. The present invention can improve the effect of color restoration. Attached Figure Description

[0046] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0047] Figure 1 This is a schematic diagram of the implementation environment provided for an embodiment of the present invention;

[0048] Figure 2 A flowchart of the overall steps provided in this embodiment of the invention;

[0049] Figure 3 A flowchart illustrating an implementation process provided in this embodiment of the invention;

[0050] Figure 4 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present invention. Detailed Implementation

[0051] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention. In the following description, when referring to the accompanying drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the embodiments of this invention; they are merely examples of apparatuses and methods consistent with some aspects of the embodiments of this invention as detailed in the appended claims.

[0052] It is understood that the terms “first,” “second,” etc., used in this invention may be used herein to describe various concepts, but unless specifically stated otherwise, these concepts are not limited by these terms. These terms are used only to distinguish one concept from another. For example, first information may also be referred to as second information without departing from the scope of embodiments of the invention, and similarly, second information may also be referred to as first information. Depending on the context, the words “if,” “when,” or “in response to determination” as used herein may be interpreted as “when…” or “when…” or “in response to determination.”

[0053] The terms “at least one,” “multiple,” “each,” “any,” etc., used in this invention, “at least one” includes one, two, or more than two; “multiple” includes two or more than two; “each” refers to each of the corresponding multiple; and “any” refers to any one of the multiple.

[0054] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention pertains. The terminology used herein is for the purpose of describing embodiments of the invention only and is not intended to limit the invention.

[0055] The underwater image correction method based on adaptive color enhancement provided in this invention relates to the field of image processing technology. This method can be applied to a terminal, a server, or software running on either a terminal or a server. In some embodiments, the terminal can be a smartphone, tablet, laptop, desktop computer, smart speaker, smartwatch, or vehicle-mounted terminal, but is not limited to these. The server can be configured as an independent physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, CDN, and big data and artificial intelligence platforms. The server can also be a node server in a blockchain network. The software can be an application implementing the underwater image correction method based on adaptive color enhancement, but is not limited to the above forms.

[0056] This invention can be used in a wide variety of general-purpose or special-purpose computer system environments or configurations. Examples include: personal computers, server computers, handheld or portable devices, tablet devices, multiprocessor systems, microprocessor-based systems, set-top boxes, programmable consumer electronics, network PCs, minicomputers, mainframe computers, and distributed computing environments including any of the above systems or devices. This invention can be described in the general context of computer-executable instructions, such as program modules, that are executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, etc., that perform specific tasks or implement specific abstract data types. This invention can also be practiced in distributed computing environments where tasks are performed by remote processing devices connected via a communication network. In distributed computing environments, program modules can reside in local and remote computer storage media, including storage devices.

[0057] like Figure 1 The diagram shown is a schematic representation of an implementation environment provided by an embodiment of the invention. (Refer to...) Figure 1 The implementation environment includes at least one terminal 102 and a server 101. The terminal 102 and the server 101 can be connected via a network, either wirelessly or via a wired connection, to complete data transmission and exchange.

[0058] Server 101 can be a standalone physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, CDN (Content Delivery Network), and big data and artificial intelligence platforms.

[0059] Additionally, server 101 can also be a node server in a blockchain network. Blockchain is a novel application model of computer technologies such as distributed data storage, peer-to-peer transmission, consensus mechanisms, and encryption algorithms.

[0060] Terminal 102 can be a smartphone, tablet, laptop, desktop computer, smart speaker, smartwatch, etc. It can also be a vehicle-mounted terminal of the various device types described above, but is not limited to these. Terminal 102 and server 101 can be directly or indirectly connected via wired or wireless communication, and this embodiment of the invention does not impose any limitations.

[0061] Exemplary based on Figure 1 The implementation environment shown in this embodiment of the invention provides an underwater image correction method based on adaptive color enhancement. The following description uses the application of this underwater image correction method based on adaptive color enhancement in server 101 as an example. It can be understood that this method can also be applied in terminal 102.

[0062] Reference Figure 2 , Figure 2 This is a flowchart illustrating an underwater image correction method based on adaptive color enhancement applied to a server, provided as an embodiment of the present invention. The execution subject of this method can be any of the aforementioned computer devices (including servers or terminals). (Refer to...) Figure 2 The method may include the following steps:

[0063] Preliminary color compensation processing is performed on the acquired original underwater images to be corrected;

[0064] The results of the preliminary compensation process are balanced and adjusted using a minimum color loss constraint.

[0065] The result of the equalization adjustment is subjected to color compensation processing to complete the image correction of the original underwater image to be corrected.

[0066] In some embodiments, the preliminary color compensation processing of the acquired original underwater image to be corrected includes the following steps:

[0067] Acquire the original underwater image to be corrected;

[0068] In the RGB color space, determine the color mean of each channel of the original underwater image to be corrected;

[0069] Based on the color mean values ​​of the original underwater image to be corrected in the green channel and the blue channel, it is determined whether the original underwater image to be corrected is a greenish image or a bluish image.

[0070] Perform color compensation on images that are too green or too blue;

[0071] The expression for the average color value is:

[0072]

[0073] in, The color mean of the c channel is represented by L; the length of the original underwater image to be corrected is represented by H; and the height of the original underwater image to be corrected is represented by I. i,j This represents the color value of the corresponding channel at length value i and height value j.

[0074] In some embodiments, color compensation for greenish or bluish images includes the following steps:

[0075] For the greenish image, the first compensation process formula is used to compensate for the loss in the red and blue channels by using the information contained in the green channel.

[0076] For the bluish image, the second compensation process formula is used to compensate the information contained in the red channel with the information contained in the green channel.

[0077] The formula for the first compensation process is as follows:

[0078]

[0079] The formula for the second compensation process is:

[0080]

[0081] Among them, I r (x),I g (x),I b (x) represents the information of the red, green, and blue channels in the underwater image, I′ r (x),I' g (x), I′ b (x) represents the compensated information for the red, green, and blue channels. This represents the average values ​​of the red, green, and blue channels of the original underwater image.

[0082] In some embodiments, the process of applying a minimum color loss constraint to balance the result of the preliminary compensation process includes the following steps:

[0083] Based on the results of the preliminary compensation process, the color mean of the original underwater image to be corrected in each channel is obtained;

[0084] Based on the preset minimum color loss formula and the color mean, the compensation formula in the preliminary compensation process is updated until the difference between the color mean of each channel is less than a fixed threshold.

[0085] In some embodiments, the expression for the minimum color loss formula is:

[0086]

[0087] Among them, L color Represents the minimum color loss; This represents the average values ​​of the red, green, and blue channels of the original underwater image.

[0088] In some embodiments, performing color compensation processing on the result of the equalization adjustment to complete the image correction of the original underwater image to be corrected includes the following steps:

[0089] The compensation of channels a and b in the CI ELAB color space of the original underwater image to be corrected is adjusted to convert the RGB color space to the CI ELAB color space.

[0090] In some embodiments, the compensation formula for converting the RGB color space to the CI ELAB color space is:

[0091]

[0092] Among them, the channel with the larger mean value between channel a and channel b is represented as I. max The channel with the smaller mean is represented as I. min γ is the adjustment parameter; Representing I max The average value; Representing I min The average value.

[0093] The specific implementation process of this invention will be described in detail below using a specific application scenario as an example:

[0094] To address the problems existing in the prior art, the technical problem to be solved by this invention is to classify underwater images into two main categories: greenish images and blueish images. Then, adaptive compensation processing is performed on the red channel in these two categories to improve the color restoration effect.

[0095] Specifically, due to the absorption of red light bands during underwater light propagation, underwater images suffer color distortion, resulting in images predominantly blue or green. This invention analyzes a large number of underwater images, calculating the average distribution of RGB channels in their blue-green biased images. The following conclusions are drawn: In blue images, red channel information loss is severe, while the loss of information in blue and green channels is comparable. However, in green images, not only is red channel information severely degraded, but blue channels are also significantly affected. In general, the degree of RGB channel loss differs between blue and green images. To better recover the lost information in underwater images, separate processing of blue and green images is crucial, and this is a core technical point of this invention. Therefore, this invention proposes an underwater image correction method and system based on adaptive color enhancement. Figure 3 As shown, it mainly includes the following three key steps.

[0096] Step 1: Perform preliminary color compensation on underwater images.

[0097] First, in this embodiment of the invention, the mean value of each channel of the red, green, and blue channels of the underwater image is calculated in the RGB color space, and the mean values ​​of the green and blue channels are compared. If the mean value of the green channel is greater than the mean value of the blue channel, the image is classified as a greenish image; if the mean value of the blue channel is greater than the mean value of the green channel, the image is classified as a bluish image.

[0098] Next, this embodiment of the invention performs color compensation on greenish and bluish images respectively. In green images, the red and blue channels suffer the most severe information loss, while the degradation of the green channel is relatively small. Therefore, the information contained in the green channel becomes the main part of compensating for the loss in the red and blue channels. Furthermore, the information within the green channel remains consistent. The compensation formula for green images is as follows:

[0099]

[0100] Among them, I r (x),I g (x),I b (x) represents information from the red, green, and blue channels in the underwater image, I′ r (x),I' g (x), I′ b (x) represents the information of the compensated red, green, and blue channels. This represents the average value of the red, green, and blue channels of the original underwater image.

[0101] In bluish images, the red channel suffers the greatest information loss, followed by the green channel, and finally the blue channel, which experiences the least information loss. Applying the same compensation principle to the red channel of a green image might lead to excessive red channel compensation, resulting in images with red artifacts. Therefore, for red channel compensation, the compensation channel value is not chosen from the blue channel (characterized by minimal information loss). Instead, this embodiment of the invention selects a value for the green channel, located at the center of the lost RGB color channel information. The green channel compensation is the same as for green image channels. The information in the blue channel remains unchanged, and the compensation for bluish images is as follows:

[0102]

[0103] The second step in this embodiment of the invention employs a minimum color loss constraint to adjust the balance of color compensation. After the first step of color compensation, underwater images often exhibit undercompensation in the red channel. To obtain more natural colors in the enhanced image, inspired by the gray-world hypothesis, which assumes that the color channels of natural images have similar histogram distributions and average values, a novel minimum color loss algorithm is designed:

[0104]

[0105] in, It is the average value after color compensation at formula (1) or (2). If the average value of the channel after color compensation at (1) or (2) does not conform to the minimum color loss formula L color In this embodiment of the invention, (1) or (2) is updated in each iteration until the difference between channels is less than a fixed value, thereby obtaining the average value and histogram distribution of each color channel. After minimizing color loss, when their color histogram distributions are in a relatively close state, the resulting enhanced image is closer to the color of the natural image.

[0106] Thirdly, to achieve better color balance in the enhanced underwater image, this embodiment of the invention designs fine-tuned color compensation on the a and b channels of the CIELAB color space. Although iteratively minimizing the compensation of the RGB channels using minimal color loss to make their grayscale mean closer, compensating the red channel, the compensation in the red channel for a specific individual image is still insufficient. Therefore, this embodiment of the invention fine-tunes the compensation of channels a and b on the CIELAB color space of the image. This embodiment of the invention converts the RGB color space to the CIELAB color space, and the specific compensation formula is as follows:

[0107]

[0108] Among them, the channel with the larger mean value between channel a and channel b is represented as I. max The other channel is represented as I. min γ is an adjustable parameter. After fine-tuning the color compensation, the color channels are transferred back to the RGB color space. Furthermore, the colors of the underwater image after fine-tuning are more consistent with the colors of the natural image.

[0109] In summary, this invention, through analysis of the color channel distribution in underwater images, found that processing images with a blue tint and those with a green tint separately yields better results. Based on this theory, this invention adaptively classifies underwater images and then applies different compensation methods to different categories of images. Furthermore, to better correct image color, this invention proposes a minimum color loss principle based on the gray world hypothesis to constrain the effectiveness of the initial color compensation. Finally, to further improve color correction, this invention performs color space compensation not only in the RGB color space but also in the CIELAB color space, thereby fully restoring the original color information of the underwater image.

[0110] This invention improves the quality of underwater images and restores lost color information, which is of great significance for scientific research, marine surveys, and archaeological work. In underwater construction and marine monitoring projects, the color correction system provides more accurate visual information, enabling underwater workers to make better decisions, thereby improving work efficiency and safety. Furthermore, for underwater photography and videography, the color correction system can significantly improve image quality, providing a better visual experience for diving enthusiasts, documentary filmmakers, and viewers.

[0111] Another aspect of this invention provides an underwater image correction system based on adaptive color enhancement, comprising:

[0112] The first module is used to perform preliminary color compensation processing on the acquired original underwater image to be corrected;

[0113] The second module is used to balance and adjust the results of the preliminary compensation process using a minimum color loss constraint.

[0114] The third module is used to perform color compensation processing on the result of the equalization adjustment, thereby completing the image correction of the original underwater image to be corrected.

[0115] It is understood that the content of the above method embodiments is applicable to this system embodiment. The specific functions implemented in this system embodiment are the same as those in the above method embodiments, and the beneficial effects achieved are also the same as those achieved in the above method embodiments.

[0116] This invention also provides an electronic device, which includes a memory and a processor. The memory stores a computer program, and the processor executes the computer program to implement the aforementioned underwater image correction method based on adaptive color enhancement. This electronic device can be any smart terminal, including tablet computers, in-vehicle computers, etc.

[0117] It is understood that the content of the above method embodiments is applicable to this device embodiment. The specific functions implemented by this device embodiment are the same as those of the above method embodiments, and the beneficial effects achieved are also the same as those achieved by the above method embodiments.

[0118] Please see Figure 4 , Figure 4 The hardware structure of an electronic device according to another embodiment is illustrated. The electronic device includes:

[0119] The processor 401 can be implemented using a general-purpose CPU (Central Processing Unit), microprocessor, application-specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of the present invention.

[0120] The memory 402 can be implemented as a read-only memory (ROM), static storage device, dynamic storage device, or random access memory (RAM). The memory 402 can store the operating system and other applications. When the technical solutions provided in the embodiments of this specification are implemented through software or firmware, the relevant program code is stored in the memory 402 and called by the processor 401 to execute the underwater image correction method based on adaptive color enhancement of the embodiments of this invention.

[0121] Input / output interface 403 is used to implement information input and output;

[0122] The communication interface 404 is used to enable communication and interaction between this device and other devices. Communication can be achieved through wired means (such as USB, network cable, etc.) or wireless means (such as mobile network, WIFI, Bluetooth, etc.).

[0123] Bus 405 transmits information between various components of the device (e.g., processor 401, memory 402, input / output interface 403, and communication interface 404);

[0124] The processor 401, memory 402, input / output interface 403 and communication interface 404 are connected to each other within the device via bus 405.

[0125] This invention also provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the above-described underwater image correction method based on adaptive color enhancement.

[0126] It is understood that the content of the above method embodiments is applicable to this storage medium embodiment. The specific functions implemented in this storage medium embodiment are the same as those in the above method embodiments, and the beneficial effects achieved are also the same as those achieved in the above method embodiments.

[0127] Memory, as a non-transitory computer-readable storage medium, can be used to store non-transitory software programs and non-transitory computer-executable programs. Furthermore, memory may include high-speed random access memory, and may also include non-transitory memory, such as at least one disk storage device, flash memory device, or other non-transitory solid-state storage device. In some embodiments, memory may optionally include memory remotely located relative to the processor, and these remote memories can be connected to the processor via a network. Examples of such networks include, but are not limited to, the Internet, intranets, local area networks, mobile communication networks, and combinations thereof.

[0128] In some alternative embodiments, the functions / operations mentioned in the block diagrams may not occur in the order shown in the operation diagrams. For example, depending on the functions / operations involved, two consecutively shown blocks may actually be executed substantially simultaneously, or the blocks may sometimes be executed in reverse order. Furthermore, the embodiments presented and described in the flowcharts of this invention are provided by way of example to provide a more comprehensive understanding of the technology. The disclosed methods are not limited to the operations and logic flows presented herein. Alternative embodiments are contemplated in which the order of various operations is altered and sub-operations described as part of a larger operation are executed independently.

[0129] Furthermore, although the invention has been described in the context of functional modules, it should be understood that, unless otherwise stated, one or more of the described functions and / or features may be integrated into a single physical device and / or software module, or one or more functions and / or features may be implemented in a separate physical device or software module. It is also understood that a detailed discussion of the actual implementation of each module is unnecessary for understanding the invention. Rather, given the properties, functions, and internal relationships of the various functional modules in the apparatus disclosed herein, the actual implementation of the module will be understood within the scope of conventional skill of an engineer. Therefore, those skilled in the art can implement the invention as set forth in the claims using ordinary techniques without excessive experimentation. It is also understood that the specific concepts disclosed are merely illustrative and not intended to limit the scope of the invention, which is determined by the full scope of the appended claims and their equivalents.

[0130] If the aforementioned functions are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this invention, essentially, or the part that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0131] The logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as a sequenced list of executable instructions for implementing logical functions, and can be embodied in any computer-readable medium for use by, or in conjunction with, an instruction execution system, apparatus, or device (such as a computer-based system, a processor-included system, or other system that can fetch and execute instructions from, an instruction execution system, apparatus, or device). For the purposes of this specification, "computer-readable medium" can be any means that can contain, store, communicate, propagate, or transmit programs for use by, or in conjunction with, an instruction execution system, apparatus, or device.

[0132] More specific examples of computer-readable media (a non-exhaustive list) include: electrical connections (electronic devices) having one or more wires, portable computer disk drives (magnetic devices), random access memory (RAM), read-only memory (ROM), erasable and editable read-only memory (EPROM or flash memory), fiber optic devices, and portable optical disc read-only memory (CDROM). Furthermore, computer-readable media can even be paper or other suitable media on which the program can be printed, because the program can be obtained electronically, for example, by optically scanning the paper or other medium, followed by editing, interpreting, or otherwise processing as necessary, and then stored in computer memory.

[0133] It should be understood that various parts of the present invention can be implemented in hardware, software, firmware, or a combination thereof. In the above embodiments, multiple steps or methods can be implemented in software or firmware stored in memory and executed by a suitable instruction execution system. For example, if implemented in hardware, as in another embodiment, it can be implemented using any one or a combination of the following techniques known in the art: discrete logic circuits having logic gates for implementing logical functions on data signals, application-specific integrated circuits (ASICs) having suitable combinational logic gates, programmable gate arrays (PGAs), field-programmable gate arrays (FPGAs), etc.

[0134] In the description of this specification, references to terms such as "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., indicate that a specific feature, structure, material, or characteristic described in connection with that embodiment or example is included in at least one embodiment or example of the invention. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples.

[0135] Although embodiments of the invention have been shown and described, those skilled in the art will understand that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the claims and their equivalents.

[0136] The above is a detailed description of the preferred embodiments of the present invention. However, the present invention is not limited to the embodiments described. Those skilled in the art can make various equivalent modifications or substitutions without departing from the spirit of the present invention. All such equivalent modifications or substitutions are included within the scope defined by the claims of the present invention.

Claims

1. An underwater image correction method based on adaptive color enhancement, characterized in that, Includes the following steps: Preliminary color compensation processing is performed on the acquired original underwater images to be corrected; The results of the preliminary compensation process are balanced and adjusted using a minimum color loss constraint. The result of the equalization adjustment is subjected to color compensation processing to complete the image correction of the original underwater image to be corrected. The preliminary color compensation processing of the acquired original underwater image to be corrected includes the following steps: Acquire the original underwater image to be corrected; In the RGB color space, determine the color mean of each channel of the original underwater image to be corrected; Based on the color mean values ​​of the original underwater image to be corrected in the green channel and the blue channel, it is determined whether the original underwater image to be corrected is a greenish image or a bluish image. For the greenish image, the first compensation process formula is used to compensate for the loss in the red and blue channels by using the information contained in the green channel. For the bluish image, the second compensation process formula is used to compensate the information contained in the red channel with the information contained in the green channel, and to compensate the information contained in the green channel with the information contained in the blue channel. The formula for the first compensation process is: The formula for the second compensation process is: in, This represents information about the red, green, and blue channels in an underwater image. This indicates the information for the compensated red, green, and blue channels. This represents the average value of the red, green, and blue channels of the original underwater image; The process of applying minimum color loss constraints to balance and adjust the results of the initial compensation process includes the following steps: Based on the results of the preliminary compensation process, the color mean of the original underwater image to be corrected in each channel is obtained; Based on the preset minimum color loss formula and the color mean, the compensation formula in the preliminary compensation process is updated until the difference between the color mean of each channel is less than a fixed threshold. The expression for the minimum color loss formula is: in, Represents the minimum color loss; This represents the average values ​​of the red, green, and blue channels of the original underwater image.

2. The underwater image correction method based on adaptive color enhancement according to claim 1, characterized in that, The expression for the color mean is: in, represent The average color value of the channel; This represents the length value of the original underwater image to be corrected; This represents the height value of the original underwater image to be corrected; Representative at Length value and The height value corresponds to the color value of the channel.

3. The underwater image correction method based on adaptive color enhancement according to claim 1, characterized in that, The process of performing color compensation processing on the result of the equalization adjustment to complete the image correction of the original underwater image to be corrected includes the following steps: The compensation of channels a and b in the CIELAB color space of the original underwater image to be corrected is adjusted to convert the RGB color space to the CIELAB color space.

4. The underwater image correction method based on adaptive color enhancement according to claim 3, characterized in that, The compensation formula for converting the RGB color space to the CIELAB color space is as follows: Among them, the channel with the larger mean values ​​for channel a and channel b is represented as follows: The channel with the smaller mean is represented as , To adjust the parameters; represent The average value; represent The average value.

5. An underwater image correction system based on adaptive color enhancement, characterized in that, include: The first module is used to perform preliminary color compensation processing on the acquired original underwater image to be corrected; The second module is used to balance and adjust the results of the preliminary compensation process using a minimum color loss constraint. The third module is used to perform color compensation processing on the result of the equalization adjustment, thereby completing the image correction of the original underwater image to be corrected. The first module is specifically used for: Acquire the original underwater image to be corrected; In the RGB color space, determine the color mean of each channel of the original underwater image to be corrected; Based on the color mean values ​​of the original underwater image to be corrected in the green channel and the blue channel, it is determined whether the original underwater image to be corrected is a greenish image or a bluish image. For the greenish image, the first compensation process formula is used to compensate for the loss in the red and blue channels by using the information contained in the green channel. For the bluish image, the second compensation process formula is used to compensate the information contained in the red channel with the information contained in the green channel, and to compensate the information contained in the green channel with the information contained in the blue channel. The formula for the first compensation process is: The formula for the second compensation process is: in, This represents information about the red, green, and blue channels in an underwater image. This indicates the information for the compensated red, green, and blue channels. This represents the average value of the red, green, and blue channels of the original underwater image; The second module is specifically used for: Based on the results of the preliminary compensation process, the color mean of the original underwater image to be corrected in each channel is obtained; Based on the preset minimum color loss formula and the color mean, the compensation formula in the preliminary compensation process is updated until the difference between the color mean of each channel is less than a fixed threshold. The expression for the minimum color loss formula is: in, Represents the minimum color loss; This represents the average values ​​of the red, green, and blue channels of the original underwater image.

6. An electronic device, characterized in that, Including the processor and memory; The memory is used to store programs; The processor executes the program to implement the method as described in any one of claims 1 to 4.

7. A computer-readable storage medium, characterized in that, The storage medium stores a program that is executed by a processor to implement the method as described in any one of claims 1 to 4.

Citation Information

Patent Citations

  • Local self-adaptive underwater image color correction method

    CN114820385A