Image brightness intelligent optimization method and device for stone recognition

By calculating the average brightness and dividing the luminance of the stone images, identifying the characteristic areas of the stone and adjusting the exposure according to the lighting conditions, the problem of low accuracy in stone recognition in the existing technology under different lighting environments is solved, and high efficiency is achieved. Safe identification effect.

CN116012608BActive Publication Date: 2024-11-01EXWAY INTELLIGENT TECH (SUZHOU) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202211646799.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-12-21
Publication Date
2024-11-01
Estimated Expiration
2042-12-21

AI Technical Summary

Technical Problem

The existing stone recognition technology has low recognition accuracy in different lighting environments, and the fill light source has high power consumption and is unsafe, making it difficult to adapt to complex light field environments.

Method used

By calculating the average brightness and dividing the stone image, segmenting the image blocks and performing brightness recognition, calculating the target contrast, adjusting the exposure to achieve ideal contrast, and achieving accurate identification of the characteristic areas of the stone.

Benefits of technology

It improves the accuracy and accuracy of stone recognition, reduces the dependence on fill light sources, avoids the use of high-power light sources, and ensures the safety and efficiency of the identification process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116012608B_ABST
    Figure CN116012608B_ABST
Patent Text Reader

Abstract

The present invention provides an image brightness intelligent optimization method and device for stone recognition, including: average brightness calculation and brightness division of stone images, block segmentation, average brightness calculation and brightness division of stone images in response to the division results of weak light intervals or strong light intervals; brightness recognition of adjacent blocks according to the brightness division results of each block, and overall mapping of the stone image according to the brightness recognition results of the adjacent blocks to obtain each brightness area of ​​the stone image corresponding to the brightness recognition result; target contrast of the stone image is calculated according to the average brightness, weight coefficient, number of blocks corresponding to each brightness area, and the average brightness and number of blocks corresponding to the stone image; and exposure adjustment of the stone image to achieve the target contrast. The present invention can obtain an ideal and clear stone image for subsequent recognition algorithm implementation.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of stone image recognition, and in particular to an image brightness intelligent optimization method and device for stone recognition. Background Art

[0002] The structure of the stone is complex and diverse, and it is a polyhedron. Different surfaces receive different light intensities, which makes the grayscale distribution of the stone very complex, which increases the difficulty of identification. In addition, due to the reflection phenomenon of the measured object under different lighting environments, image recognition is even more difficult to be accurate.

[0003] For example, in the stone crushing operation, in order to realize the demand for automatic crushing of stones by the breaker, identifying the stones to be crushed is the most important link. Only by accurately identifying the stones to be crushed can the breaker be smoothly guided to crush the stones and complete the automated construction.

[0004] Currently, there is no mature algorithm for brightness adjustment in stone recognition. Generally speaking, the existing technical algorithms have the following disadvantages.

[0005] 1. Poor environmental adaptability

[0006] Most of the current algorithms used in flat camera image recognition rely on the mean algorithm, which makes the captured images very susceptible to interference from background light. For example, in the daytime when the background is very bright or in the dark when there is only fill light, the accuracy of the algorithm adjusted based on the mean algorithm is extremely low.

[0007] 2. High requirements for fill light source

[0008] The consequence of the first factor is that ordinary fill light sources cannot meet the recognition requirements of various light field environments. Therefore, extremely high-power fill light sources are needed to make adaptive compensation, but this kind of light source has high power and high brightness, which not only consumes electricity, but also has the potential risk of heat dissipation and damage to human eyes.

[0009] 3. Poor effect

[0010] Under different light field environments, even if the current common brightness adjustment algorithm can achieve the recognition function, there will be inaccurate recognition due to high local brightness. The recognition of stones is not just about recognition, but also requires relatively high-precision positioning. Therefore, accurate recognition of the edges of stones has become a top priority, and adjusting the brightness and contrast to the right level plays an immeasurable role. Summary of the invention

[0011] In order to overcome the defects of the prior art described in the above background technology and improve the accuracy of stone recognition, one aspect of the present invention provides an image brightness intelligent optimization method for stone recognition, including: calculating the average brightness of the stone image to be recognized and dividing the brightness according to the calculation result, wherein the brightness division result is at least one of a weak light interval, a normal interval and a strong light interval; in response to the division result of the weak light interval or the strong light interval, segmenting the stone image into blocks and calculating the average brightness of each segmented block and dividing the brightness according to the calculation result; and identifying the brightness of adjacent blocks according to the brightness division result of each block, wherein The brightness recognition result is at least one of continuous weak light, continuous strong light, continuous ordinary, weak-strong, strong-weak, weak-normal, normal-weak, strong-normal and normal-strong, wherein the adjacent blocks corresponding to weak-strong and strong-weak are regarded as the boundaries between the stone and the background; the stone image is mapped as a whole according to the brightness recognition results of the adjacent blocks to obtain the brightness areas of the stone image corresponding to the brightness recognition results; the target contrast of the stone image is calculated according to the average brightness corresponding to the brightness areas, the weight coefficient, the number of blocks and the average brightness and the number of blocks corresponding to the stone image; and the exposure of the stone image is adjusted to achieve the target contrast.

[0012] Preferably, the average brightness of the stone image to be identified is calculated and the brightness is divided according to the calculation result, including: using the formula L=0.299·R + 0.587·G + 0.114·B to calculate the average brightness of the stone image, and determining the average brightness in the intervals of [0, 84], [85,170], and [171,255] as weak light interval, normal interval, and strong light interval respectively.

[0013] Preferably, performing block segmentation on the stone image includes: obtaining the minimum stone pixel area in the stone image, wherein the minimum stone pixel area is the minimum circumscribed rectangular area of ​​the minimum stone; determining the block pixel area according to the minimum stone pixel area, wherein the block pixel area is greater than the minimum stone pixel area; and segmenting the stone image into J×K blocks according to the block pixel area.

[0014] Preferably, the method further includes: marking the adjacent blocks corresponding to weak-normal and normal-strong as weak-strong blur, and marking the adjacent blocks corresponding to strong-normal and normal-weak as strong-weak blur; performing cyclic brightness recognition on at least the blocks marked as weak-strong blur and strong-weak blur and performing brightness confirmation on the marked blocks according to the recognition results, wherein the brightness confirmation includes: judging whether the brightness of the ordinary brightness blocks in weak-normal has increased, if so, confirming the weak-normal as weak-strong, otherwise confirming it as continuous weak light; judging whether the brightness of the ordinary brightness blocks in normal-strong has increased, if so, confirming the normal-strong as continuous strong light, otherwise confirming it as weak-strong; judging whether the brightness of the ordinary brightness blocks in strong-normal has increased, if so, confirming the strong-normal as continuous strong light, otherwise confirming it as strong-weak; and judging whether the brightness of the ordinary brightness blocks in normal-weak has increased, if so, confirming the normal-weak as strong-weak, otherwise confirming it as continuous weak light.

[0015] Preferably, the target contrast of the stone image is calculated using the following formula:

[0016]

[0017] Among them: Nson is the target contrast, Msum is the number of blocks corresponding to the stone image, and L is the average brightness corresponding to the stone image; S1-S7 are the numbers of blocks corresponding to the continuous weak light area, continuous strong light area, continuous ordinary light area, weak-strong light area, strong-weak light area, weak-strong blurred light area and strong-weak blurred light area respectively; N1-N7 are the average brightness corresponding to the continuous weak light area, continuous strong light area, continuous ordinary light area, weak-strong light area, strong-weak light area, weak-strong blurred light area and strong-weak blurred light area respectively; ω1 is the weight coefficient corresponding to the continuous weak light area, continuous strong light area and continuous ordinary light area, ω2 is the weight coefficient corresponding to the weak-strong light area and strong-weak light area, and ω3 is the weight coefficient corresponding to the weak-strong blurred light area and strong-weak blurred light area.

[0018] In order to overcome the defects of the prior art described in the above background technology and improve the accuracy of stone recognition, one aspect of the present invention provides an image brightness intelligent optimization device for stone recognition, including: a first brightness calculation module, configured to calculate the average brightness of the stone image to be recognized; a first brightness division module, configured to divide the brightness of the stone image according to the calculation result, wherein the brightness division result is at least one of a weak light interval, a normal interval and a strong light interval; an image segmentation module, configured to segment the stone image into blocks in response to the division result of the weak light interval or the strong light interval; a second brightness calculation module, configured to calculate the average brightness of each segmented block; a second brightness division module, configured to divide the brightness of each block according to the calculation result of the average brightness of each block; a brightness recognition module, configured to divide the stone image into blocks according to the calculation result of the average brightness of each block The brightness of adjacent blocks is identified based on the brightness division result of the blocks, wherein the brightness identification result is at least one of continuous weak light, continuous strong light, continuous ordinary, weak-strong, strong-weak, weak-ordinary, ordinary-weak, strong-ordinary and ordinary-strong, wherein the adjacent blocks corresponding to weak-strong and strong-weak are regarded as the boundaries between the stone and the background; a brightness area determination module is configured to perform overall mapping of the stone image according to the brightness identification results of the adjacent blocks to obtain each brightness area of ​​the stone image corresponding to the brightness identification results; a target contrast calculation module is configured to calculate the target contrast of the stone image according to the average brightness corresponding to each brightness area, a weight coefficient, the number of blocks, and the average brightness and the number of blocks corresponding to the stone image; and an exposure adjustment module is configured to perform exposure adjustment on the stone image to achieve the target contrast.

[0019] Preferably, the first brightness calculation module is further configured to calculate the average brightness of the stone image using the formula L=0.299·R + 0.587·G+ 0.114·B; the first brightness division module is further configured to determine the average brightness in the intervals of [0, 84], [85,170], and [171,255] as a weak light interval, a normal interval, and a strong light interval.

[0020] Preferably, the image segmentation module includes: a minimum stone pixel area acquisition module, configured to acquire the minimum stone pixel area in the stone image, wherein the minimum stone pixel area is the minimum circumscribed rectangular area of ​​the minimum stone; a block pixel area determination module, configured to determine the block pixel area according to the minimum stone pixel area, wherein the block pixel area is greater than the minimum stone pixel area; and a segmentation submodule, configured to segment the stone image into J×K blocks according to the block pixel area.

[0021] Preferably, the device further comprises: a block marking module, configured to mark adjacent blocks corresponding to weak-normal and normal-strong as weak-strong blurred, and mark adjacent blocks corresponding to strong-normal and normal-weak as strong-weak blurred; a cycle recognition module, configured to perform cycle brightness recognition on at least blocks marked as weak-strong blurred and strong-weak blurred and to confirm the brightness of the marked blocks according to the recognition results; wherein the cycle recognition module comprises: a first recognition module, configured to determine whether the brightness of the ordinary brightness blocks in the weak-normal has increased, if so, confirm the weak-normal as weak-strong, if not the first recognition module is configured to determine whether the brightness of the ordinary brightness block in the ordinary-strong image has increased, if so, the ordinary-strong image is confirmed as continuous strong light, otherwise it is confirmed as weak-strong; the second recognition module is configured to determine whether the brightness of the ordinary brightness block in the strong-ordinary image has increased, if so, the strong-ordinary image is confirmed as continuous strong light, otherwise it is confirmed as strong-weak; and the fourth recognition module is configured to determine whether the brightness of the ordinary brightness block in the ordinary-weak image has increased, if so, the ordinary-weak image is confirmed as strong-weak, otherwise it is confirmed as continuous weak light.

[0022] Preferably, the target contrast calculation module calculates the target contrast of the stone image using the following formula:

[0023]

[0024] Among them: Nson is the target contrast, Msum is the number of blocks corresponding to the stone image, and L is the average brightness corresponding to the stone image; S1-S7 are the numbers of blocks corresponding to the continuous weak light area, continuous strong light area, continuous ordinary light area, weak-strong light area, strong-weak light area, weak-strong blurred light area and strong-weak blurred light area respectively; N1-N7 are the average brightness corresponding to the continuous weak light area, continuous strong light area, continuous ordinary light area, weak-strong light area, strong-weak light area, weak-strong blurred light area and strong-weak blurred light area respectively; ω1 is the weight coefficient corresponding to the continuous weak light area, continuous strong light area and continuous ordinary light area, ω2 is the weight coefficient corresponding to the weak-strong light area and strong-weak light area, and ω3 is the weight coefficient corresponding to the weak-strong blurred light area and strong-weak blurred light area.

[0025] The present invention calculates the average brightness and divides the brightness of the stone image to be identified. When the division result is in the weak light interval or the strong light interval, the stone image is segmented and the average brightness calculation and brightness division are performed on each segmented block, and the brightness of the adjacent blocks is identified according to the division result, thereby effectively identifying the stone feature area, and judging the illumination condition of the image according to the result of the above-mentioned stone identification process, and obtaining each brightness area of ​​the stone image corresponding to the above-mentioned brightness identification result. After determining the illumination condition and the crushed stone area of ​​the stone image, the target contrast for the stone image is calculated to control the exposure adjustment for the stone image so that it achieves the target contrast effect, thereby obtaining an ideal and clear stone image for subsequent recognition algorithm implementation, such as positioning and contour capture of the stone to control the crushing of the breaker. BRIEF DESCRIPTION OF THE DRAWINGS

[0026] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are merely embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without paying any creative work.

[0027] Figure 1 The figure shows a flow chart of an intelligent optimization method for image brightness provided by one embodiment of the present invention;

[0028] Figure 2 What is shown is a schematic diagram of an image segmentation process provided by one embodiment of the present invention;

[0029] Figure 3 What is shown is a schematic diagram of brightness recognition of adjacent blocks provided by one embodiment of the present invention;

[0030] Figure 4 The figure shows a schematic diagram of cyclic brightness recognition of a marked image block provided by one embodiment of the present invention;

[0031] Figure 5 What is shown is a schematic diagram of stone image segmentation provided by one embodiment of the present invention;

[0032] Figure 6 It shows a schematic diagram of obtaining the minimum pixel area of ​​a stone provided by one embodiment of the present invention;

[0033] Figure 7 What is shown is a schematic diagram of mapping results of various brightness areas of a stone image provided by one embodiment of the present invention;

[0034] Figure 8(a) is a schematic diagram showing a stone image provided by one embodiment of the present invention before exposure adjustment, (b) is a schematic diagram showing a stone image provided by one embodiment of the present invention after exposure adjustment, and (c) is a schematic diagram showing subsequent processing of the stone image provided by one embodiment of the present invention;

[0035] Fig. 9 It shows a schematic diagram of the structure of an intelligent optimization device for image brightness provided by one embodiment of the present invention;

[0036] Fig.10 What is shown is a structural schematic diagram of an image segmentation module provided by one embodiment of the present invention;

[0037] Fig.11 It shows a schematic diagram of the structure of an intelligent optimization device for image brightness provided by one embodiment of the present invention;

[0038] Fig.12 It shows a schematic diagram of the structure of an intelligent optimization device for image brightness provided by one embodiment of the present invention; and

[0039] Fig.13 Shown is a schematic diagram of the structure of a computer-readable storage medium provided by one embodiment of the present invention. DETAILED DESCRIPTION

[0040] Embodiments of the present invention are described in detail below, examples of which are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are intended to be used to explain the present invention, and should not be construed as limiting the present invention.

[0041] One aspect of the present invention provides an image brightness intelligent optimization method for stone identification, which is preferably used to identify stones to be broken in stone breaking operations, and can also be used to identify stones in other applications. The stone breaking operation described is, for example, an automated stone breaking operation performed by an excavator breaker, and of course, it can also be other engineering machinery, that is, in actual applications, the method can be applied to other engineering machinery that can also perform stone breaking operations, and should also fall within the scope of the present invention.

[0042] In some embodiments, the method at least consists of S11 to S16. Figure 1 Description A further exemplary description of the composition of S11 to S16 is given.

[0043] S11, calculating the average brightness of the stone image to be identified and dividing the brightness thereof according to the calculation result, wherein the brightness division result is at least one of a weak light interval, a normal interval and a strong light interval.

[0044] It should be understood that the described stone image does not mean that only stones exist in the image, but that the image contains stones, and the image elements are composed of the stone body and the background, and a stone image can contain several stones.

[0045] In some embodiments, the average brightness of the stone image is calculated using the following formula:

[0046] L=0.299·R + 0.587·G + 0.114·B;

[0047] Among them, R, G, B represent the three color channels of R (red), G (green), and B (blue) in the RGB image respectively, and L is the average brightness of the stone image. After calculating the average brightness of the stone image, the brightness of the stone image is divided according to the calculation result. Generally speaking, the overall brightness of the image is divided into 256 levels [0, 255]. The present invention divides the overall light environment into three brightness environments according to the average brightness calculation: weak light interval [0, 84], normal interval (optimal interval) [85, 170], and strong light interval [171, 255].

[0048] For the automatic stone crushing condition, the visual image is basically composed of stones and soil, so according to the previous brightness classification, when the image is in the normal range, it is in the basic brightness state, and it is considered that this is the exposure state suitable for using image algorithms to identify the image. When the brightness range is the normal light range, it is easier to identify stones, so we don’t need to discuss it in detail.

[0049] When the stone image is in a weak light or strong light range, it is necessary to visually detect the characteristic area of ​​the stone to be broken. The characteristic area of ​​the stone can be understood as the boundary between the stone and the background, or the outline of the stone. If such an area can be found in the image, then the special lighting conditions and their degree with a large dynamic range can be detected based on the brightness contrast between the main body of the stone and the background. Therefore, the subsequent execution of S12 and S13 will be introduced to realize the search of the characteristic area of ​​the stone.

[0050] S12, in response to the division result of the weak light interval or the strong light interval, segment the stone image into blocks, calculate the average brightness of each segmented block, and perform the brightness division according to the calculation result.

[0051] In S11, when the brightness division result of the stone image is a weak light interval or a strong light interval, the stone image is segmented. Figure 2As shown, the process of segmenting the stone image consists of S121~S123: S121, obtaining the minimum stone pixel area in the stone image; S122, determining the block pixel area according to the minimum stone pixel area, wherein the block pixel area is greater than the minimum stone pixel area; and S123, segmenting the stone image into J×K blocks according to the block pixel area.

[0052] refer to Figure 6 As shown, the minimum stone pixel area described is the minimum circumscribed rectangle area of ​​the minimum stone. In the segmentation process, the stone with the smallest area is first found in the stone image, and then the circumscribed rectangle of the stone is calibrated to use this as the minimum stone pixel area. After obtaining the minimum stone pixel area, the tile pixel area is determined in turn. In one embodiment, the tile pixel area is preferably set to 1.5 times the minimum stone pixel area. Of course, the multiple can also be adjusted according to actual calculation needs. The obtained tile pixel area is the area of ​​the tile after segmentation, and the stone image is segmented into J×K tiles according to the obtained tile pixel area, as shown in FIG. Figure 5 In the example shown, the stone image is divided into 8×5 blocks. It should be understood that a block is composed of a number of pixels.

[0053] After the segmentation is completed, the average brightness of each segmented image block is calculated and the brightness is divided according to the calculation result. The difference from S11 is that S11 calculates the average brightness of the entire stone image, while here the average brightness is calculated for each segmented image block. The similarity is that the average brightness calculation method used here and the brightness division method based on the calculation result are the same as those in S11.

[0054] S13, performing brightness recognition on adjacent blocks according to the brightness division results of each block, wherein the brightness recognition result is at least one of continuous weak light, continuous strong light, continuous ordinary, weak-strong, strong-weak, weak-ordinary, ordinary-weak, strong-ordinary and ordinary-strong, wherein the adjacent blocks corresponding to weak-strong and strong-weak are regarded as the boundaries between the stone and the background.

[0055] In the process of brightness recognition of adjacent blocks, if the brightness contrast of adjacent blocks is small, it is considered that the brightness of adjacent blocks is continuous and they are likely to belong to the same object in the image; if the brightness contrast is greater than a certain threshold, it is considered that there is a sudden change in the brightness of adjacent blocks and they are likely to be the characteristic area of ​​the stone to be recognized, that is, the boundary between the stone and the background. Figure 5As shown, different thresholds Lx and Ly are used to search in the horizontal and vertical directions respectively. By using the thresholds Lx and Ly to search the horizontal and vertical directions of the image, continuous brightness areas with strong contrast can be found. These areas are likely to be the main body of the stone and the background of the image. The search process is first performed in the horizontal direction, using Lx to search from left to right to find the brightness recognition results of adjacent blocks in the horizontal direction; then it is performed in the vertical direction, using Ly to search from top to bottom to find the brightness recognition results of adjacent blocks in the vertical direction.

[0056] like Figure 3 In one example shown, during the brightness recognition process of adjacent blocks, when the current block is searched, based on the aforementioned brightness recognition, it is determined whether the block is weak light (in the weak light interval), if so, it is divided into the weak light area, if not, it continues to determine whether the block is normal light (in the normal interval), if so, it is divided into the normal light area, if not, it continues to determine whether the block is strong light (in the strong light interval), if so, it is divided into the strong light area. Then, the next block is searched, that is, the block adjacent to the current block, and when the next block is searched, the light area to which the block belongs is determined based on the aforementioned brightness recognition.

[0057] When the first tile (current tile) is weak light, if the next tile is weak light, the adjacent tile (the combination of the current tile and the next tile) is regarded as continuous weak light, if it is normal light, the adjacent tile is regarded as weak-normal, if it is strong light, the adjacent tile is regarded as weak-strong. When the first tile is normal light, if the next tile is weak light, the adjacent tile is regarded as normal-weak, if it is normal light, the adjacent tile is regarded as continuous normal, if it is strong light, the adjacent tile is regarded as normal-strong. When the first tile is strong light, if the next tile is weak light, the adjacent tile is regarded as strong-weak, if it is normal light, the adjacent tile is regarded as strong-normal, if it is strong light, the adjacent tile is regarded as continuous strong light.

[0058] Among them, the adjacent blocks corresponding to weak-strong and strong-weak are obviously boundary areas due to their high contrast, and are regarded as the characteristic areas of the stone to be identified, that is, the boundary between the stone and the background.

[0059] In some embodiments, the adjacent image blocks corresponding to weak-normal and normal-strong are marked as weak-strong blur, and the adjacent image blocks corresponding to strong-normal and normal-weak are marked as strong-weak blur.

[0060] S14, mapping the stone image as a whole according to the brightness recognition results of the adjacent blocks to obtain brightness areas of the stone image corresponding to the brightness recognition results.

[0061] The present invention determines the illumination condition of the image according to the result of the above-mentioned stone identification process (i.e., the identification result of S13), and obtains the brightness areas of the stone image corresponding to the brightness identification result of S13. Specifically, seven areas are distinguished. They are: continuous weak light area, continuous strong light area, continuous normal light area, strong-weak area, weak-strong area, strong-weak fuzzy area, weak-strong fuzzy area, such as Figure 7 An example is shown.

[0062] After determining the lighting conditions (various brightness zones) and the gravel area (stone feature area) of the stone image, the brightness adjustment of the stone image, that is, the exposure time of the camera, is determined. The subsequent execution of S15 and S16 is introduced to realize the brightness adjustment of the stone image.

[0063] S15, calculating the target contrast of the stone image according to the average brightness, weight coefficient, and number of blocks corresponding to the brightness zones and the average brightness and number of blocks corresponding to the stone image.

[0064] The target contrast of the stone image is calculated using the following formula:

[0065]

[0066] Among them: Nson is the target contrast, Msum is the number of blocks corresponding to the stone image, and L is the average brightness corresponding to the stone image.

[0067] Among them, S1-S7 are the number of blocks corresponding to the continuous weak light area, continuous strong light area, continuous normal light area, weak-strong light area, strong-weak light area, weak-strong blurred light area and strong-weak blurred light area, and N1-N7 are the average brightness corresponding to the continuous weak light area, continuous strong light area, continuous normal light area, weak-strong light area, strong-weak light area, weak-strong blurred light area and strong-weak blurred light area.

[0068] Among them, ω1 is the weight coefficient corresponding to the continuous weak light area, continuous strong light area and continuous ordinary light area, ω2 is the weight coefficient corresponding to the weak-strong light area and strong-weak light area, and ω3 is the weight coefficient corresponding to the weak-strong blurred light area and strong-weak blurred light area.

[0069] In fact, for image recognition, the higher the contrast, the easier and more accurate it is to capture the contour. The target contrast is calculated based on this principle.

[0070] In one embodiment, according to the above theory, the contrast of continuous strong light, continuous weak light and continuous normal light areas is low, so the weight coefficient is set to 0.2 in the calculation of the weight coefficient. There are certain uncertainties in the strong-weak blurred light area and the weak-strong blurred light area, and the weight coefficient is set to 0.5, while the strong-weak and weak-strong light areas have strong contrast, and the weight coefficient is set to 0.8. Therefore, the above formula is transformed into:

[0071]

[0072] It should be understood that the numerical value of the above-mentioned weight coefficient is not a limiting value. In actual application, the specific numerical value of the weight coefficient can be adjusted in time according to the effect comparison.

[0073] S16, adjusting the exposure of the stone image so as to achieve the target contrast.

[0074] After the target contrast for the stone image is calculated, the exposure adjustment control is performed on the stone image. The exposure adjustment control is based on the target contrast. When it is identified that the target contrast of the stone image reaches the calculated value, the exposure is stopped.

[0075] Therefore, the present invention calculates the average brightness and divides the brightness of the stone image to be identified. When the division result is in the weak light interval or the strong light interval, the stone image is segmented and the average brightness calculation and brightness division are performed on each segmented block, and the brightness of the adjacent blocks is identified according to the division result, thereby effectively identifying the stone feature area, and judging the illumination condition of the image according to the result of the above-mentioned stone identification process, and obtaining each brightness area of ​​the stone image corresponding to the above-mentioned brightness identification result. After determining the illumination condition and the crushed stone area of ​​the stone image, the target contrast for the stone image is calculated to control the exposure adjustment for the stone image so that it achieves the target contrast effect, thereby obtaining an ideal and clear stone image for subsequent recognition algorithm implementation, such as positioning and contour capture of the stone to control the crushing process of the breaker.

[0076] refer to Figure 8 As shown, (a) is the stone image before exposure adjustment, (b) is the stone image after exposure adjustment, and (c) is the subsequent processing of the stone image. It can be seen that after the above-mentioned exposure adjustment of the present invention, an ideal and clear stone image can be obtained.

[0077] refer to Figure 3 As shown, in some embodiments, at least the image blocks marked as weak-strong blur and strong-weak blur are subjected to cyclic brightness recognition and the brightness of the marked image blocks is confirmed according to the recognition results.

[0078] like Figure 4In an example shown, in the brightness confirmation after cyclic brightness recognition, the following confirmation process will be specifically performed: determine whether the brightness of the ordinary brightness block in weak-ordinary has increased, if so, the weak-ordinary is confirmed as weak-strong, otherwise it is confirmed as continuous weak light; determine whether the brightness of the ordinary brightness block in ordinary-strong has increased, if so, the ordinary-strong is confirmed as continuous strong light, otherwise it is confirmed as weak-strong; determine whether the brightness of the ordinary brightness block in strong-ordinary has increased, if so, the strong-ordinary is confirmed as continuous strong light, otherwise it is confirmed as strong-weak; and determine whether the brightness of the ordinary brightness block in ordinary-weak has increased, if so, the ordinary-weak is confirmed as strong-weak, otherwise it is confirmed as continuous weak light.

[0079] refer to Fig. 9 As shown, one aspect of the present invention provides an image brightness intelligent optimization device for stone recognition, comprising:

[0080] The first brightness calculation module 21 is configured to calculate the average brightness of the stone image to be identified.

[0081] The first brightness division module 22 is configured to divide the brightness according to the calculation result, wherein the brightness division result is at least one of a weak light interval, a normal interval and a strong light interval.

[0082] The image segmentation module 23 is configured to segment the stone image into blocks in response to the division result of the weak light interval or the strong light interval.

[0083] The second brightness calculation module 24 is configured to calculate the average brightness of each segmented image block.

[0084] The second brightness division module 25 is configured to perform the brightness division on each block according to the calculation result of the average brightness of each block.

[0085] The brightness recognition module 26 is configured to perform brightness recognition on adjacent blocks according to the brightness division results of each block, wherein the brightness recognition result is at least one of continuous weak light, continuous strong light, continuous normal, weak-strong, strong-weak, weak-normal, normal-weak, strong-normal and normal-strong, wherein the adjacent blocks corresponding to weak-strong and strong-weak are regarded as the boundaries between the stone and the background.

[0086] The brightness region determination module 27 is configured to perform overall mapping on the stone image according to the brightness recognition results of the adjacent blocks to obtain brightness regions of the stone image corresponding to the brightness recognition results.

[0087] The target contrast calculation module 28 is configured to calculate the target contrast of the stone image according to the average brightness, weight coefficient, and number of blocks corresponding to the brightness zones and the average brightness and number of blocks corresponding to the stone image.

[0088] The exposure adjustment module 29 is configured to perform exposure adjustment on the stone image so as to achieve the target contrast.

[0089] In some embodiments, the first brightness calculation module 21 is further configured to calculate the average brightness of the stone image using the formula L=0.299·R +0.587·G + 0.114·B.

[0090] The first brightness division module 22 is further configured to determine the average brightness in the intervals [0, 84], [85, 170], and [171, 255] as a weak light interval, a normal interval, and a strong light interval respectively.

[0091] refer to Fig.10 As shown, in some embodiments, the image segmentation module 23 includes:

[0092] The minimum stone pixel area acquisition module 231 is configured to acquire the minimum stone pixel area in the stone image, wherein the minimum stone pixel area is the minimum circumscribed rectangular area of ​​the minimum stone.

[0093] The image block pixel area determination module 232 is configured to determine the image block pixel area according to the minimum stone pixel area, wherein the image block pixel area is greater than the minimum stone pixel area.

[0094] The segmentation submodule 233 is configured to segment the stone image into J×K blocks according to the pixel areas of the blocks.

[0095] refer to Fig.11 As shown, in some embodiments, the device further includes:

[0096] The block marking module 31 is configured to mark the adjacent blocks corresponding to weak-normal and normal-strong as weak-strong blurred, and mark the adjacent blocks corresponding to strong-normal and normal-weak as strong-weak blurred.

[0097] The cycle identification module 32 is configured to perform cycle brightness identification on at least the image blocks marked as weak-strong blur and strong-weak blur and confirm the brightness of the marked image blocks according to the identification results.

[0098] The cycle identification module 32 includes:

[0099] The first recognition module 321 is configured to determine whether the ordinary brightness block in the weak-normal image has a brightness increase. If so, the weak-normal image is confirmed as weak-strong. Otherwise, it is confirmed as continuous weak light.

[0100] The second identification module 322 is configured to determine whether the ordinary brightness block in the ordinary-strong light has a brightness rise, and if so, confirm the ordinary-strong light as continuous strong light, otherwise, confirm it as weak-strong light.

[0101] The third identification module 323 is configured to determine whether the ordinary brightness block in the strong-normal has a brightness increase. If so, the strong-normal is confirmed as continuous strong light, otherwise it is confirmed as strong-weak.

[0102] The fourth identification module 324 is configured to determine whether the ordinary brightness block in the ordinary-weak light has a brightness increase, and if so, confirm the ordinary-weak light as strong-weak light, and if not, confirm it as continuous weak light.

[0103] In some embodiments, the target contrast calculation module 28 calculates the target contrast of the stone image using the following formula:

[0104]

[0105] Among them: Nson is the target contrast, Msum is the number of blocks corresponding to the stone image, and L is the average brightness corresponding to the stone image.

[0106] S1-S7 are the numbers of blocks corresponding to continuous weak light area, continuous strong light area, continuous normal light area, weak-strong light area, strong-weak light area, weak-strong blurred light area and strong-weak blurred light area respectively, and N1-N7 are the average brightness corresponding to continuous weak light area, continuous strong light area, continuous normal light area, weak-strong light area, strong-weak light area, weak-strong blurred light area and strong-weak blurred light area respectively.

[0107] ω1 is the weight coefficient corresponding to the continuous weak light area, continuous strong light area and continuous ordinary light area, ω2 is the weight coefficient corresponding to the weak-strong light area and the strong-weak light area, and ω3 is the weight coefficient corresponding to the weak-strong blurred light area and the strong-weak blurred light area.

[0108] refer to Fig.12 As shown, one aspect of the present invention provides an image brightness intelligent optimization device for stone recognition, comprising: a memory 301 and a processor 302, wherein the memory 301 is used to store a computer program, and the processor 302 is used to call the computer program to execute corresponding steps of an image brightness intelligent optimization method for stone recognition provided in an embodiment of the present invention.

[0109] refer to Fig.13 As shown, one aspect of the present invention provides a computer-readable storage medium, in which a computer program is stored. When the computer program is run on a computer, the corresponding steps of the image brightness intelligent optimization method for stone identification provided by an embodiment of the present invention are executed.

[0110] The computer readable storage medium includes a computer program for executing a computer process on a computing device. In some embodiments, the computer readable storage medium is provided using a signal bearing medium 401. The signal bearing medium 401 may include one or more program instructions, which when executed by one or more processors may provide the above Figure 1-4 Thus, for example, one or more features of a method for intelligent optimization of image brightness for stone identification may be performed by one or more instructions associated with the signal-bearing medium 401. In addition, Fig.13 The program instructions in also describe example instructions. In some examples, the signal bearing medium 401 may include a computer readable medium 402, such as, but not limited to, a hard drive, a compact disk (CD), a digital video disk (DVD), a digital tape, a memory, a read-only memory (ROM) or a random access memory (RAM), and the like.

[0111] In some implementations, signal bearing medium 401 may include computer recordable medium 403 such as, but not limited to, memory, read / write (R / W) CD, R / W DVD, and the like.

[0112] In some implementations, signal bearing medium 401 may include communication medium 404 such as, but not limited to, digital and / or analog communication media (eg, fiber optic cables, waveguides, wired communication links, wireless communication links, etc.).

[0113] The signal bearing medium 401 may be communicated by a wireless form of communication medium 404 (eg, a wireless communication medium complying with the IEEE 802.11 standard or other transmission protocols). The one or more program instructions may be, for example, computer executable instructions or logic implemented instructions.

[0114] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples" etc. means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner. In addition, those skilled in the art may combine and combine the different embodiments or examples described in this specification and the features of the different embodiments or examples, without contradiction.

[0115] In the present invention, unless otherwise clearly specified and limited, a first feature being "above" or "below" a second feature may mean that the first and second features are in direct contact, or the first and second features are in indirect contact through an intermediate medium. Moreover, a first feature being "above", "above" or "above" a second feature may mean that the first feature is directly above or obliquely above the second feature, or simply means that the first feature is higher in level than the second feature. A first feature being "below", "below" or "below" a second feature may mean that the first feature is directly below or obliquely below the second feature, or simply means that the first feature is lower in level than the second feature.

[0116] Although the embodiments of the present invention have been shown and described above, it is to be understood that the above embodiments are exemplary and are not to be construed as limitations of the present invention. A person skilled in the art may change, modify, replace and vary the above embodiments within the scope of the present invention.

Claims

1. An intelligent optimization method for image brightness for stone recognition, characterized in that: include: Calculating the average brightness of the stone image to be identified and dividing the brightness thereof according to the calculation result, wherein the brightness division result is at least one of a weak light interval, a normal interval and a strong light interval; In response to the division result of the weak light interval or the strong light interval, the stone image is segmented to obtain blocks larger than the minimum stone pixel area, and average brightness is calculated for each segmented block and brightness division is performed on it according to the calculation result; According to the brightness division result of each block, brightness recognition is performed on the adjacent blocks, wherein the brightness recognition result is at least one of continuous weak light, continuous strong light, continuous normal light, weak-strong, strong-weak, weak-normal, normal-weak, strong-normal and normal-strong, wherein the adjacent blocks corresponding to weak-strong and strong-weak are regarded as the boundary between the stone and the background; Mapping the stone image as a whole according to the brightness recognition result of the adjacent image blocks to obtain each brightness area of ​​the stone image corresponding to the brightness recognition result; Calculating the target contrast of the stone image according to the average brightness, weight coefficient, and number of blocks corresponding to each brightness zone and the average brightness and number of blocks corresponding to the stone image; as well as Adjusting the exposure of the stone image to achieve the target contrast; The target contrast of the stone image is calculated using the following formula: , Where: Nson is the target contrast, Msum is the number of blocks corresponding to the stone image, and L is the average brightness corresponding to the stone image; S1-S7 are the numbers of blocks corresponding to the continuous weak light area, continuous strong light area, continuous normal light area, weak-strong light area, strong-weak light area, weak-strong blurred light area and strong-weak blurred light area, respectively; N1-N7 are the average brightness corresponding to the continuous weak light area, continuous strong light area, continuous normal light area, weak-strong light area, strong-weak light area, weak-strong blurred light area and strong-weak blurred light area, respectively; ω1 is the weight coefficient corresponding to the continuous weak light area, continuous strong light area and continuous ordinary light area, ω2 is the weight coefficient corresponding to the weak-strong light area and the strong-weak light area, and ω3 is the weight coefficient corresponding to the weak-strong blurred light area and the strong-weak blurred light area.

2. The method for intelligent optimization of image brightness according to claim 1, characterized in that: The average brightness of the stone image to be identified is calculated and the brightness is divided according to the calculation result, including: The average brightness of the stone image is calculated using the formula L=0.299·R + 0.587·G + 0.114·B, and the average brightness in the intervals of [0, 84], [85,170], and [171,255] are correspondingly determined as a weak light interval, a normal interval, and a strong light interval.

3. The method for intelligent optimization of image brightness according to claim 1, characterized in that: The stone image is segmented into blocks, including: Acquire the minimum stone pixel area in the stone image, wherein the minimum stone pixel area is the minimum circumscribed rectangular area of ​​the minimum stone; Determining a pixel area of ​​a picture block according to the minimum pixel area of ​​a stone, wherein the pixel area of ​​the picture block is greater than the minimum pixel area of ​​a stone; The stone image is divided into J×K blocks according to the pixel areas of the blocks.

4. The method for intelligent optimization of image brightness according to claim 1, characterized in that: The method further comprises: The adjacent blocks corresponding to weak-normal and normal-strong are marked as weak-strong blur, and the adjacent blocks corresponding to strong-normal and normal-weak are marked as strong-weak blur; At least the image blocks marked as weak-strong blur and strong-weak blur are subjected to cyclic brightness recognition and the brightness of the marked image blocks is confirmed according to the recognition results, wherein the brightness confirmation includes: Determine whether the brightness of the normal brightness block in the weak-normal image has increased. If so, confirm the weak-normal image as weak-strong. If not, confirm it as continuous weak light. Determine whether the brightness of the normal-strong image block increases. If so, confirm the normal-strong image block as continuous strong light. Otherwise, confirm it as weak-strong light. Determine whether the brightness of the normal brightness block in the strong-normal image has increased. If so, the strong-normal image is confirmed as continuous strong light. If not, it is confirmed as strong-weak; and Determine whether the brightness of the ordinary brightness block in the ordinary-weak light increases. If so, confirm the ordinary-weak light as strong-weak light. Otherwise, confirm it as continuous weak light.

5. An image brightness intelligent optimization device for stone identification, characterized in that: include: A first brightness calculation module is configured to calculate the average brightness of the stone image to be identified; A first brightness division module is configured to divide the brightness according to the calculation result, wherein the brightness division result is at least one of a weak light interval, a normal interval and a strong light interval; An image segmentation module is configured to segment the stone image into blocks in response to the division result of the weak light interval or the strong light interval to obtain blocks with an area larger than the minimum stone pixel area; A second brightness calculation module is configured to calculate the average brightness of each segmented image block; A second brightness division module is configured to perform the brightness division on each block according to the calculation result of the average brightness of each block; a brightness recognition module, configured to perform brightness recognition on adjacent blocks according to the brightness division result of each block, wherein the brightness recognition result is at least one of continuous weak light, continuous strong light, continuous normal, weak-strong, strong-weak, weak-normal, normal-weak, strong-normal and normal-strong, wherein the adjacent blocks corresponding to weak-strong and strong-weak are regarded as the boundary between the stone and the background; a brightness region determination module, configured to perform overall mapping of the stone image according to the brightness recognition results of the adjacent blocks to obtain brightness regions of the stone image corresponding to the brightness recognition results; a target contrast calculation module, configured to calculate the target contrast of the stone image according to the average brightness corresponding to each brightness zone, the weight coefficient, the number of blocks, and the average brightness and the number of blocks corresponding to the stone image; as well as An exposure adjustment module, configured to perform exposure adjustment on the stone image so as to achieve the target contrast; The target contrast calculation module calculates the target contrast of the stone image using the following formula: , Where: Nson is the target contrast, Msum is the number of blocks corresponding to the stone image, and L is the average brightness corresponding to the stone image; S1-S7 are the numbers of blocks corresponding to the continuous weak light area, continuous strong light area, continuous normal light area, weak-strong light area, strong-weak light area, weak-strong blurred light area and strong-weak blurred light area, respectively; N1-N7 are the average brightness corresponding to the continuous weak light area, continuous strong light area, continuous normal light area, weak-strong light area, strong-weak light area, weak-strong blurred light area and strong-weak blurred light area, respectively; ω1 is the weight coefficient corresponding to the continuous weak light area, continuous strong light area and continuous ordinary light area, ω2 is the weight coefficient corresponding to the weak-strong light area and the strong-weak light area, and ω3 is the weight coefficient corresponding to the weak-strong blurred light area and the strong-weak blurred light area.

6. The image brightness intelligent optimization device according to claim 5, characterized in that: The first brightness calculation module is further configured to calculate the average brightness of the stone image using the formula L=0.299·R+0.587·G+0.114·B; The first brightness division module is further configured to determine the average brightness in the intervals of [0, 84], [85, 170], and [171, 255] as a weak light interval, a normal interval, and a strong light interval respectively.

7. The image brightness intelligent optimization device according to claim 5, characterized in that: The image segmentation module comprises: A minimum stone pixel area acquisition module is configured to acquire the minimum stone pixel area in the stone image, wherein the minimum stone pixel area is the minimum circumscribed rectangular area of ​​the minimum stone; A block pixel area determination module configured to determine a block pixel area according to the minimum stone pixel area, wherein the block pixel area is larger than the minimum stone pixel area; and The segmentation submodule is configured to segment the stone image into J×K blocks according to the pixel areas of the blocks.

8. The image brightness intelligent optimization device according to claim 5, characterized in that: The device also includes: A block marking module is configured to mark adjacent blocks corresponding to weak-normal and normal-strong as weak-strong blurred, and mark adjacent blocks corresponding to strong-normal and normal-weak as strong-weak blurred; A cyclic identification module, configured to perform cyclic brightness identification on at least the image blocks marked as weak-strong blur and strong-weak blur and to confirm the brightness of the marked image blocks according to the identification results; The cycle identification module comprises: The first recognition module is configured to determine whether the normal brightness block in the weak-normal image has a brightness increase, and if so, confirm the weak-normal image as weak-strong, and if not, confirm it as continuous weak light; The second recognition module is configured to determine whether the ordinary brightness block in the ordinary-strong light has a brightness rise, and if so, confirm the ordinary-strong light as continuous strong light, otherwise confirm it as weak-strong light; A third identification module is configured to determine whether the normal brightness block in the strong-normal image has a brightness increase, and if so, to confirm the strong-normal image as continuous strong light, and if not, to confirm it as strong-weak; and The fourth identification module is configured to determine whether the ordinary brightness block in the ordinary-weak light has a brightness increase. If so, the ordinary-weak light is confirmed as strong-weak light, otherwise it is confirmed as continuous weak light.