A Gear Dynamic Oil Immersion Depth Recognition Method and System Based on Image Processing
Through image processing technology, the gear splash lubrication model is established, the lubricating oil distribution is calculated and the image is processed, and the oil coverage area is accurately obtained, which solves the problem of large calculation errors in the dynamic oil immersion depth of the gear, and improves the prediction accuracy of oil stirring power loss.
Patent Information
- Application Number
- CN202410433024.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-04-11
- Publication Date
- 2025-06-10
- Estimated Expiration
- 2044-04-11
AI Technical Summary
In the prior art, there is a large error in calculating the dynamic oil immersion depth of the gear, resulting in inaccurate prediction of oil stirring power loss.
Using an image processing method, by establishing a gear splash lubrication model, calculating the lubricating oil distribution, obtaining the cloud map of the surface oil volume fraction distribution at the front and rear ends of the gear, performing image processing to obtain the number of white pixels, and then calculating the oil coverage area, and finally reverse-pulling the gear dynamic oil immersion depth.
The accuracy of the calculation of dynamic oil immersion depth of gears is improved, thereby improving the accuracy of predicting oil stirring power loss.
Smart Images

Figure CN118261086B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of gear transmission, and particularly relates to a method and system for identifying the dynamic oil immersion depth of gears based on image processing. Background Art
[0002] Gear transmission is an important power transmission method in the mechanical field. Splash lubrication, oil immersion lubrication, and oil bath lubrication are commonly used in low-speed working conditions of gear transmission to play the roles of lubrication and heat dissipation, prevent the failure of the gear transmission system, and extend the service life of the gear transmission system. When gear transmission adopts splash lubrication, in addition to frictional losses, the gear also has to do work to overcome the fluid resistance of the lubricating oil. At this time, the mechanical energy of the gear is converted into the kinetic energy and potential energy of the fluid. This part of the mechanical energy loss is called the oil churning power loss. Predicting the oil churning power loss plays an important role in the design and optimization of the transmission system.
[0003] In the related art, for the evaluation of the oil churning power loss, mainly the static oil immersion depth is adopted, or the dynamic oil immersion depth formula obtained by back-calculating the resistance torque obtained from experiments is used.
[0004] In view of the above related art, using the static oil immersion depth to evaluate the gear power loss has a large error, while using the existing dynamic oil immersion depth theoretical formula to estimate the oil churning power loss results vary, and accurate results cannot be obtained. Summary of the Invention
[0005] The technical problem to be solved by the present invention is to provide a method and system for identifying the dynamic oil immersion depth of gears based on image processing, which improves the accuracy of calculating the dynamic oil immersion depth of gears, thereby improving the prediction accuracy of the gear oil churning power loss.
[0006] A method for identifying the dynamic oil immersion depth of gears based on image processing includes:
[0007] Establish a gear splash lubrication model;
[0008] Based on the gear splash lubrication model, calculate the lubricating oil distribution;
[0009] According to the lubricating oil distribution, obtain the surface oil volume fraction distribution cloud maps of the front and rear ends of the gear, and background-remove the surface oil volume fraction distribution cloud maps to obtain a processed image;
[0010] Based on the optimal linear weighting method, gray-scale the processed image to obtain a number of alternative gray-scale images;
[0011] Based on the number of edge points in the alternative gray-scale images, obtain the optimal gray-scale image;
[0012] Binarize the optimal gray-scale image to obtain the number of white pixels;
[0013] Based on the number of white pixels and the total number of pixels, obtain the oil fluid coverage area;
[0014] Based on the oil fluid coverage area and a preset formula, obtain the dynamic oil immersion depth of the gear.
[0015] Optionally, the graying of the processed image based on the optimal linear weighting method to obtain a number of alternative gray images includes:
[0016] Obtain the three-channel values of the processed image at any point;
[0017] Discretize the weight space to obtain a number of projection vectors;
[0018] Based on the projection vectors, the optimal linear weighting method, and the three-channel values, obtain a number of alternative gray images.
[0019] Optionally, the obtaining of the optimal gray image based on the number of edge points in the alternative gray images includes:
[0020] Obtain a preset first threshold and a second threshold, where the first threshold is less than the second threshold;
[0021] Based on the alternative gray images, obtain a number of pixel points;
[0022] Calculate the pixel gradient value of the pixel points;
[0023] Determine whether the pixel gradient value is higher than the second threshold;
[0024] If the pixel gradient value is higher than the second threshold or the pixel gradient value is greater than the first threshold and less than the second threshold and is connected to the point of the second threshold, then use the pixel points with the pixel gradient value higher than the second threshold as edge points;
[0025] Count all the edge points in the alternative gray images to obtain the number of edge points;
[0026] Obtain the alternative gray image corresponding to the largest number of edge points as the optimal gray image.
[0027] Optionally, the binarization of the optimal gray image to obtain the number of white pixels includes:
[0028] Divide the gray image into multiple regions;
[0029] Set the sliding window size for each region;
[0030] Calculate the segmentation threshold between the central region of the sliding window and other adjacent regions and perform an arithmetic average to obtain the central region threshold;
[0031] Based on the algorithm, the local area threshold of each area is obtained;
[0032] Based on the central area threshold and the local area threshold, the optimal grayscale image is binarized to obtain the number of white pixels.
[0033] Optionally, the step of binarizing the optimal grayscale image based on the central area threshold and the local area threshold to obtain the number of white pixels includes:
[0034] Obtain a preset grayscale function;
[0035] Through a preset algorithm and the grayscale function, the local center point threshold of a single area is obtained;
[0036] The grayscale function is re-established through a Gaussian filter to obtain a perceived grayscale function;
[0037] Based on the perceived grayscale function, the image grayscale function threshold is obtained;
[0038] Based on the image grayscale function threshold and the weight coefficient, an improved threshold is obtained;
[0039] Based on the central area threshold, the local area threshold, and the improved threshold, the optimal grayscale image is binarized to obtain the number of white pixels.
[0040] Optionally, the step of binarizing the optimal grayscale image based on the central area threshold, the local area threshold, and the improved threshold to obtain the number of white pixels includes:
[0041] Based on the central area threshold, the local area threshold, and the binarization formula, the optimal grayscale image is binarized to obtain the number of white pixels;
[0042] The binarization formula is:
[0043]
[0044] If 0.75T 1 ≤f(x,y)≤1.25T 1 , then:
[0045]
[0046] where the pixel value 0 is black and the pixel value 255 is white, and white represents that the tooth surface is covered with lubricating oil.
[0047] Optionally, the step of obtaining the oil coverage area based on the number of white pixels and the total number of pixels includes:
[0048] Obtain the area of the gear outer contour;
[0049] Based on the number of white pixels and the total number of pixels, obtain the white proportion;
[0050] Based on the white proportion and the area of the outer contour of the gear, obtain the oil coverage area.
[0051] A gear dynamic oil immersion depth recognition system based on image processing, comprising:
[0052] A construction module, used to establish a gear splash lubrication model;
[0053] A first calculation module, used to calculate the lubricating oil distribution based on the gear splash lubrication model;
[0054] A first processing module, used to obtain a surface oil volume fraction distribution cloud map of the front end and the rear end of the gear according to the lubricating oil distribution, and background-remove the surface oil volume fraction distribution cloud map to obtain a processed image;
[0055] A second processing module, used to gray-scale the processed image based on the optimal linear weighting method to obtain a number of alternative gray-scale images;
[0056] A screening module, used to obtain the optimal gray-scale image based on the number of edge points in the alternative gray-scale images;
[0057] A third processing module, used to binarize the optimal gray-scale image to obtain the number of white pixels;
[0058] A second calculation module, used to obtain the oil coverage area based on the number of white pixels and the total number of pixels;
[0059] A third calculation module, used to obtain the gear dynamic oil immersion depth based on the oil coverage area and a preset formula.
[0060] A terminal device, comprising a memory and a processor, the memory stores a computer program capable of running on the processor, and when the processor loads and executes the computer program, a gear dynamic oil immersion depth recognition method based on image processing is adopted.
[0061] A computer-readable storage medium, in which a computer program is stored, and when the computer program is loaded and executed by a processor, a gear dynamic oil immersion depth recognition method based on image processing is adopted.
[0062] The beneficial effects of the present invention are as follows: By establishing a gear splash lubrication model, obtaining the contour maps of the surface oil volume fraction distribution at the front and rear ends of the gear, then processing the contour maps of the surface oil volume fraction distribution at the front and rear ends of the gear to obtain alternative grayscale graphics, then selecting the alternative grayscale graphic with the largest number of edge points from the alternative grayscale images as the optimal grayscale image, then performing binary processing on the image according to the central region threshold and the local region threshold to obtain the number of white pixels, obtaining the oil coverage area based on the number of white pixels and the total number of pixels, and inversely calculating the dynamic oil immersion depth of the gear based on the oil coverage area, improving the accuracy of calculating the dynamic oil immersion depth of the gear and enhancing the prediction accuracy of the gear oil stirring power loss. BRIEF DESCRIPTION OF THE DRAWINGS
[0063] Figure 1 FIG. is a schematic flow chart of a method for identifying the dynamic oil immersion depth of a gear based on image processing according to the present invention;
[0064] Figure 2 FIG. is a schematic diagram for calculating the dynamic oil immersion depth of a gear in a method for identifying the dynamic oil immersion depth of a gear based on image processing according to the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0065] A method for identifying the dynamic oil immersion depth of a gear based on image processing, as Figure 1 shown, includes:
[0066] S100. Establish a gear splash lubrication model.
[0067] Specifically, according to the actual gear structure parameters (parameters such as the geometric shape, number of teeth, and tooth surface curve of the gear), use the three-dimensional modeling software NX to establish a gear model, and establish the corresponding gear rotation domain and flow domain models, and export them in the *.x_t format.
[0068] Import the output *.x_t file into Ansys Designmodeler for Boolean operations, subtract the gear entity in the model, and name the entity surface, where the rotation domain surface is set to interface.
[0069] Use Meshing to perform mesh division on the model, set the whole model as a fluid, and refine the mesh of the tooth surface and the rotation domain.
[0070] Use Fluent software to perform transient simulation settings for gear splash lubrication. In the general settings, first set the unit in the mesh scaling to mm, set the angular unit to rev / min, and define the transient options and the gravity field.
[0071] Add lubricating oil to the fluid material and set the density and viscosity of the lubricating oil; in the two-phase flow setting, use the VOF model, select the implicit discretization format, and check the implicit body force; modify the phase names, with the primary phase being air and the secondary phase being oil; in the interphase interaction, check the surface tension model and modify the surface tension coefficient to 0.075; set the viscosity model to the RNG k-epsilon model.
[0072] In the cell zone conditions, set the rotating domain to mesh motion and modify the origin of the rotation axis, the direction of the rotation axis, and the rotational speed.
[0073] Select the SIMPLE algorithm for the solution method. The relaxation factor can be appropriately reduced to improve convergence, or the Coupled algorithm with better convergence can be used.
[0074] Use cell marking to set the initial oil height and initialize the secondary phase fraction ratio in the flow field.
[0075] Define the output parameters of the simulation calculation.
[0076] Define the time step and the number of calculation steps. The time step is generally between 10-6 and 10-5.
[0077] S110. Calculate the lubricating oil distribution based on the gear splash lubrication model.
[0078] S120. Obtain the surface oil volume fraction distribution cloud maps of the front and rear ends of the gear according to the lubricating oil distribution, and remove the background from the surface oil volume fraction distribution cloud maps to obtain the processed images.
[0079] Specifically, perform numerical calculations of the lubricating oil distribution in the flow field in Ansys Fluent, ensure that the model setting and mesh division of the gear splash lubrication are reasonable, and the boundary conditions and material properties are set correctly. After completing the numerical calculations, export the surface oil volume fraction distribution cloud maps of the front and rear ends of the gear through the post-processing function of Ansys Fluent.
[0080] The front and rear ends of the gear are the reference planes where the two circular surfaces of the spiral bevel gear are located. Since the lubricating oil is dynamic when the gear rotates, the oil surface is not on the same horizontal plane, and the immersion depth needs to be calculated based on the surface oil volume fraction distribution cloud maps of the front and rear ends.
[0081] Remove the background from the surface oil volume fraction distribution cloud map of the gear, and only retain the outer contour shape of the gear to obtain the processed image.
[0082] S130. Grayscale the processed image based on the optimal linear weighting method to obtain several alternative grayscale images.
[0083] Specifically, when graying the processed image by the optimal linear weighting method, by discretizing the weight space, a plurality of groups of weighted values with different combinations are obtained. The weighted values of different combinations are combined with the numerical values of the red, green, and blue channels to generate a number of alternative gray images.
[0084] S140. Obtain the optimal gray image based on the number of edge points in the alternative gray images.
[0085] Specifically, select the one with the largest number of edge points from the several alternative gray images to obtain the optimal gray image.
[0086] S150. Binarize the optimal gray image to obtain the number of white pixels.
[0087] Specifically, after binarizing the optimal gray image, there are only two colors, black and white. Among them, white is the color of the oil. By counting the number of white pixels, the area ratio of the oil can be known.
[0088] S160. Obtain the oil coverage area based on the number of white pixels and the total number of pixels.
[0089] Specifically, divide the number of white pixels by the total number of pixels to obtain the ratio, and then multiply by the area of the outer contour of the gear to obtain the oil coverage area.
[0090] S170. Obtain the dynamic oil immersion depth of the gear based on the oil coverage area and a preset formula.
[0091] Specifically, after obtaining the oil coverage area, based on the oil coverage area and the preset formula, the dynamic oil immersion depth of the gear is inversely deduced.
[0092]
[0093] As Figure 2 shown, the specific calculation of the preset formula is:
[0094] Among them, S is the oil area, S1 is the sector area, S2 is the isosceles triangle area, R is the outer diameter of the gear, α is the sector interior angle, h is the dynamic oil immersion depth of the gear. By averaging the dynamic oil immersion depths at the front end and the rear end of the gear, the equivalent dynamic oil immersion depth of the gear can be obtained. Specifically, the oil immersion depth at the front end is calculated according to the oil volume fraction distribution cloud map at the front end and the oil immersion depth at the rear end is calculated according to the oil volume fraction distribution cloud map at the rear end, and then the oil immersion depth at the front end and the oil immersion depth at the rear end are averaged to obtain the dynamic oil immersion depth of the gear.
[0095] In one implementation manner of this embodiment, step S130 gray-scales the processed image based on the optimal linear weighting method to obtain several alternative gray images, including:
[0096] S200. Obtain the values of the three channels at any point in the processed image.
[0097] S210. Discretize the weight space to obtain multiple projection vectors.
[0098] S220. Based on the projection vectors, the optimal linear weighting method, and the values of the three channels, obtain several candidate grayscale images.
[0099] Specifically, grayscale conversion of a color image is equivalent to projecting the RGB color space coordinates in a certain direction, and the principle is as follows:
[0100] Gray n = α r R n + α g G n + α b B n .
[0101] In the formula, Grayn represents the pixel value of the grayscale image at the nth point, Rn, Gn, and Bn respectively represent the red, green, and blue channel values of the color image at the nth point, and α r , α g and α b represent the weights of the red, green, and blue channel values, and satisfy
[0102] α r + α g + α b = 1.
[0103] Discretize the weight space α = {α r , α g , α b} to obtain projection vectors α in a finite number of directions.
[0104] Combine the projection vectors α in a finite number of directions with the values of the three channels to obtain several candidate grayscale images.
[0105] In one implementation manner of this embodiment, step S140 obtains the optimal grayscale image based on the number of edge points in the candidate grayscale images, including:
[0106] S300. Obtain a preset first threshold and a second threshold, where the first threshold is less than the second threshold.
[0107] S310. Based on the candidate grayscale images, obtain several pixel points.
[0108] S320. Calculate the pixel gradient values of the pixel points.
[0109] S330. Determine whether the pixel gradient value is higher than the second threshold, or the pixel gradient value is greater than the first threshold and less than the second threshold and is connected to the point of the second threshold.
[0110] S340. If the pixel gradient value is higher than the second threshold, or the pixel gradient value is greater than the first threshold and less than the second threshold and is connected to the point of the second threshold, then use the pixel points with pixel gradient values higher than the second threshold as edge points.
[0111] S350. Count all the edge points of the alternative grayscale image to obtain the number of edge points.
[0112] S360. Obtain the alternative grayscale image corresponding to the maximum number of edge points as the optimal grayscale image.
[0113] Specifically, a large change gradient of the grayscale value of the pixel points in the grayscale image indicates the existence of an edge. Therefore, a certain threshold can be set to detect the edge position of the image. Use the Canny operator to extract the edge of the grayscale image. A double threshold needs to be set. When the pixel point gradient value is lower than the low threshold (the first threshold), the pixel point is discarded. When the pixel point gradient value is higher than the high threshold (the second threshold), it is determined as an edge point. When it is between the two, it needs to be connected to the point higher than the high threshold to be determined as an edge point, and the number of edge points is counted.
[0114] For a number of pixel points obtained from the grayscale image, the gradient amplitude of the grayscale change is obtained through gradient calculation.
[0115] Specifically:
[0116] G x (i,j) = I(i - 1,j - 1) + 2I(i,j - 1) + I(i + 1,j - 1) - I(i - 1,j + 1) - 2I(i,j + 1) - I(i + 1,j + 1)
[0117] G y (i,j) = I(i - 1,j - 1) + 2I(i - 1,j) + I(i - 1,j + 1) - I(i + 1,j - 1) - 2I(i + 1,j) - I(i + 1,j + 1)
[0118] grad(I(i,j)) = |G x (i,j)| + |G y (i,j)|.
[0119] Among them, Gx(i, j) represents the gradient magnitude in the X direction of the pixel point with coordinates (i, j), Gy(i, j) represents the gradient magnitude in the y direction of the pixel point with coordinates (i, j), and grad(I(i, j)) represents the gradient magnitude of the gray-scale change of the pixel point with coordinates (i, j).
[0120] Compare each pixel point with the second threshold. If it is greater than the second threshold, or greater than the first threshold and less than the second threshold but connected to the second threshold, it is an edge point, and edge point statistics are performed.
[0121] Count the edge points of each alternative gray-scale image, and select the gray-scale image with the largest number of edge points as the optimal gray-scale image.
[0122] Compare the number of edge points of each alternative gray-scale image. The gray-scale image corresponding to the maximum number of edge points is the optimal gray-scale image.
[0123] In one implementation manner of this embodiment, step S150 binarizes the optimal gray-scale image, and the number of white pixels obtained includes:
[0124] S400: Divide the gray-scale image into multiple regions.
[0125] S410: Set the sliding window size of each region.
[0126] S420: Calculate the segmentation threshold between the central region of the sliding window and other adjacent regions and perform arithmetic averaging to obtain the central region threshold.
[0127] S430: Based on the threshold algorithm, obtain the local region threshold of each region.
[0128] S440: Based on the central region threshold and the local region threshold, binarize the optimal gray-scale image to obtain the number of white pixels.
[0129] Specifically, divide the gray-scale image into m×n regions, set the sliding window to 3×3 regions (the sliding window size of each region), calculate the OTSU threshold of the window central region and perform arithmetic averaging with the OTSU thresholds of the surrounding 8 adjacent regions to obtain the central region threshold T1(x, y) of the central region, where (x, y) is the region center coordinate. Calculating the local OTSU threshold after dividing the region can avoid the loss of a large amount of details caused by forced binarization to the greatest extent.
[0130] Specifically, the threshold algorithm can adopt the Bernsen algorithm, and the calculation principle is as follows:
[0131]
[0132] Among them, it is assumed that the window size is (2w + 1)×(2w + 1), f(x, y) is the grayscale function, the increment of the window in the x direction is l, the increment in its y direction is k, T2 is the Bernsen threshold, that is, the local region threshold, w represents the half-width of the window, and w in the window size can be used to control the window size and affect the size of the local region.
[0133] Combining the local region threshold and the global region threshold to binarize the optimal grayscale image can retain the image details to the greatest extent.
[0134] In one implementation manner of this embodiment, step S440 binarizes the optimal grayscale image based on the central region threshold and the local region threshold, and the number of white pixels obtained includes:
[0135] S500. Re-establish the grayscale function through a Gaussian filter to obtain the perceived grayscale function.
[0136] Specifically, the grayscale function is the function that converts a color image into a grayscale image, that is, the function used to grayscale the processed image by the optimal linear weighting method.
[0137] The perceived grayscale function is:
[0138] Among them, σ represents the standard deviation of the Gaussian distribution, f(x, y) is the grayscale function, and s is the domain of x and y.
[0139] S510. Obtain the threshold of the image grayscale function based on the perceived grayscale function.
[0140] Specifically, the threshold of the graphic grayscale function is:
[0141]
[0142] S520. Obtain the improved threshold based on the threshold of the image grayscale function and the weight coefficient.
[0143] Specifically, the improved threshold is:
[0144] T″ 2 (x,y)=(1 - β)T 2 (x,y)+βT′ 2 (x,y),β∈(0,1).
[0145] S530. Binarize the optimal grayscale image based on the central region threshold, the local region threshold, and the improved threshold to obtain the number of white pixels.
[0146] Specifically, the boundary of the figure is determined according to the figure grayscale function threshold and the improved threshold, and then the number of white pixels is determined according to the image grayscale function value calculated from the local grayscale threshold and the central region threshold.
[0147] The binarization calculation formula is used to obtain the number of white pixels, specifically:
[0148] The binarization formula is:
[0149]
[0150] If 0.75T 1 ≤f(x,y)≤1.25T 1 , then:
[0151]
[0152] where the pixel value 0 is black and the pixel value 255 is white, and white represents that the tooth surface is covered with lubricating oil.
[0153] In one implementation manner of this embodiment, step S160 obtains the oil coverage area based on the number of white pixels and the total number of pixels, including:
[0154] S600. Obtain the outer contour area of the gear.
[0155] S610. Based on the number of white pixels and the total number of pixels, obtain the white ratio.
[0156] S620. Based on the white ratio and the outer contour area of the gear, obtain the oil coverage area.
[0157] Specifically, by calculating the number of pixels in the white pixels in the image and combining the total number of pixels, the oil ratio on the gear surface can be estimated, and the area occupied by the oil can be obtained. The calculation principle is as follows:
[0158]
[0159] where S is the oil area, Sc is the outer contour area of the gear, i is the total number of white pixels, and j is the total number of black pixels.
[0160] The total number of pixels = the total number of white pixels + the total number of black pixels.
[0161] Since the white pixels represent the oil, therefore, the ratio of the number of white pixels to the total number of pixels multiplied by the outer contour area of the gear can obtain the oil coverage area, and the oil coverage area is the area where the gear is covered in the oil. The outer contour area of the gear is the area of the circle corresponding to the largest radius on the gear, that is, the area of the circle corresponding to the gear outer diameter R.
[0162] Such as Figure 2As shown, after obtaining the oil coverage area, the dynamic immersion depth of the gear is deduced by the oil coverage area. The specific formula is as follows:
[0163]
[0164]
[0165] Among them, S is the oil area, S1 is the sector area, S2 is the isosceles triangle area, R is the outer diameter of the gear, α is the sector inner angle, and h is the dynamic immersion depth of the gear.
[0166] By averaging the dynamic immersion depths at the front and rear ends of the gear, the equivalent dynamic immersion depth of the gear can be obtained.
[0167] Apply image processing technology to solve the dynamic immersion depth of the gear, and process the loss of image details during the image processing due to binarization, etc., to retain more complete image details, making the solved dynamic immersion depth of the gear more accurate and improving the prediction accuracy of the gear oil churning power loss.
[0168] A gear dynamic immersion depth recognition system based on image processing includes:
[0169] A construction module for establishing a gear splash lubrication model.
[0170] A first calculation module for calculating the lubricating oil distribution based on the gear splash lubrication model.
[0171] A first processing module for obtaining the surface oil volume fraction distribution cloud maps at the front and rear ends of the gear according to the lubricating oil distribution, and removing the background from the surface oil volume fraction distribution cloud maps to obtain a processed image.
[0172] A second processing module for graying the processed image based on the optimal linear weighting method to obtain a number of alternative gray images.
[0173] A screening module for obtaining the optimal gray image based on the number of edge points in the alternative gray images.
[0174] A third processing module for binarizing the optimal gray image to obtain the number of white pixels.
[0175] A second calculation module for obtaining the oil coverage area based on the number of white pixels and the total number of pixels.
[0176] A third calculation module for obtaining the dynamic immersion depth of the gear based on the oil coverage area and a preset formula.
[0177] An embodiment of the present application also discloses a terminal device, including a memory and a processor. The memory stores a computer program that can run on the processor. When the processor loads and executes the computer program, a method for identifying the dynamic oil immersion depth of gears based on image processing is adopted.
[0178] Among them, the terminal device can be a computer device such as a desktop computer, a laptop computer or a cloud server. And the terminal device includes but is not limited to a processor and a memory. For example, the terminal device may further include input / output devices, network access devices, and a bus, etc.
[0179] Among them, the processor can adopt a central processing unit (CPU). Of course, according to the actual usage situation, other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. can also be adopted. The general-purpose processor can adopt a microprocessor or any conventional processor, etc. The present application does not limit this.
[0180] Among them, the memory can be an internal storage unit of the terminal device. For example, the hard disk or memory of the terminal device. It can also be an external storage device of the terminal device. For example, a plug-in hard disk, a smart media card (SMC), a secure digital card (SD), or a flash card (FC) equipped on the terminal device, etc. And the memory can also be a combination of the internal storage unit and the external storage device of the terminal device. The memory is used to store the computer program and other programs and data required by the terminal device. The memory can also be used to temporarily store the data that has been output or will be output. The present application does not limit this.
[0181] Among them, through this terminal device, a method for identifying the dynamic oil immersion depth of gears based on image processing in the above embodiment is stored in the memory of the terminal device, and is loaded and executed on the processor of the terminal device, which is convenient to use.
[0182] An embodiment of the present application also discloses a computer-readable storage medium. And the computer-readable storage medium stores a computer program. Among them, when the computer program is executed by the processor, a method for identifying the dynamic oil immersion depth of gears in the above embodiment is adopted.
[0183] Among them, the computer program can be stored in a computer-readable medium. The computer program includes computer program code, and the computer program code can be in the form of source code, object code, executable file, or some middleware form, etc. The computer-readable medium includes any entity or device, recording medium, USB flash drive, mobile hard disk, magnetic disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), electrical carrier signal, telecommunication signal, and software distribution medium, etc. It should be noted that the computer-readable medium includes but is not limited to the above components.
[0184] Among them, through this computer-readable storage medium, a gear dynamic immersion depth recognition method based on image processing in the above embodiment is stored in the computer-readable storage medium, and is loaded and executed on a processor to facilitate the storage and application of the above method.
[0185] Those of ordinary skill in the art should understand that: the discussion of any of the above embodiments is only exemplary, and is not intended to imply that the protection scope of the present application is limited to these examples; under the idea of the present application, the technical features in the above embodiments or different embodiments can also be combined, and the steps can be implemented in any order, and there are many other variations in different aspects of one or more embodiments in the present application as described above, and they are not provided in detail for the sake of brevity.
[0186] One or more embodiments of the present application are intended to cover all such substitutions, modifications, and variations that fall within the broad scope of the present application. Therefore, any omission, modification, equivalent substitution, improvement, etc. made within the spirit and principle of one or more embodiments of the present application shall be included in the protection scope of the present application.
Claims
1. A method for identifying the dynamic oil immersion depth of gears based on image processing, characterized in that: include: Establish a gear splash lubrication model; Based on the gear splash lubrication model, the lubricating oil distribution is calculated; Obtaining surface oil liquid volume fraction distribution cloud maps of the front and rear ends of the gear according to the distribution of the lubricating oil, and removing the background of the surface oil liquid volume fraction distribution cloud maps to obtain a processed image; Gray-scaling the processed image based on an optimal linear weighted method to obtain a number of candidate gray-scale images; Obtaining an optimal grayscale image based on the number of edge points in the candidate grayscale image; Binarizing the optimal grayscale image to obtain the number of white pixels; Based on the number of white pixels and the total number of pixels, the oil coverage area is obtained; Based on the oil coverage area and a preset formula, the dynamic oil immersion depth of the gear is obtained; The preset formula is: Among them, S is the oil coverage area, S1 is the sector area, S2 is the isosceles triangle area, R is the outer diameter of the gear, α is the inner angle of the sector, and h is the dynamic oil immersion depth of the gear.
2. A gear dynamic oil immersion depth identification method based on image processing as claimed in claim 1, characterized in that: Gray-scaling the processed image based on the optimal linear weighted method to obtain several candidate gray-scale images includes: Obtaining three channel values of the processed image at any point; Discretize the weight space to obtain multiple projection vectors; Based on the projection vector, the optimal linear weighting method and the three channel values, several candidate grayscale images are obtained.
3. The method for identifying the dynamic oil immersion depth of a gear based on image processing as claimed in claim 1, characterized in that: The obtaining of the optimal grayscale image based on the number of edge points in the candidate grayscale image comprises: Obtaining a preset first threshold and a second threshold, wherein the first threshold is smaller than the second threshold; Based on the candidate grayscale image, obtain a number of pixel points; Calculating the pixel gradient value of the pixel point; Determine whether the pixel gradient value is higher than the second threshold or whether the pixel gradient value is greater than the first threshold and less than the second threshold and is connected to a point of the second threshold; If the pixel gradient value is higher than the second threshold or the pixel gradient value is greater than the first threshold and less than the second threshold and is connected to the point of the second threshold, the pixel point whose pixel gradient value is higher than the second threshold is regarded as an edge point; Counting all the edge points of the candidate grayscale image to obtain the number of edge points; The candidate grayscale image corresponding to the largest number of edge points is obtained as the optimal grayscale image.
4. The method for identifying the dynamic oil immersion depth of a gear based on image processing as claimed in claim 1, characterized in that: Binarizing the optimal grayscale image to obtain the number of white pixels includes: Dividing the grayscale image into a plurality of regions, dividing the grayscale image into m×n regions; Set the sliding window size for each region; Calculate the segmentation threshold of the central area of the sliding window and the surrounding adjacent areas and perform arithmetic averaging to obtain the central area threshold; Based on the threshold algorithm, the local area threshold of each area is obtained; Based on the central area threshold and the local area threshold, the optimal grayscale image is binarized to obtain the number of white pixels.
5. The method for identifying the dynamic oil immersion depth of a gear based on image processing as claimed in claim 4, characterized in that: Binarizing the optimal grayscale image based on the central area threshold and the local area threshold to obtain the number of white pixels includes: Get the preset grayscale function; Obtaining a local area threshold of a single area through a preset algorithm and the grayscale function; Re-establishing the grayscale function through a Gaussian filter to obtain a perceived grayscale function; Obtaining an image grayscale function threshold based on the perceived grayscale function; Based on the image grayscale function threshold and weight coefficient, an improved threshold is obtained; Binarize the optimal grayscale image based on the central area threshold, the local area threshold and the improved threshold to obtain the number of white pixels; The perceived grayscale function is: Among them, σ represents the standard deviation of the Gaussian distribution, f(x, y) is the grayscale function, s is the domain of x and y, and w represents the half-width of the window.
6. The method for identifying the dynamic oil immersion depth of a gear based on image processing as claimed in claim 5, characterized in that: Binarizing the optimal grayscale image based on the central area threshold, the local area threshold, and the improved threshold to obtain the number of white pixels includes: Based on the central area threshold, the local area threshold and the binarization formula, binarize the optimal grayscale image to obtain the number of white pixels; The binarization formula is: If 0.75T1≤f(x,y)≤1.25T1, then: Among them, the pixel value 0 is black, the pixel value 255 is white, and white means that the tooth surface is covered with lubricating oil. g(x, y) is the binarization result, f(x, y) is the grayscale function, T1 is the central area threshold, and T2" is the improved threshold.
7. The method for identifying the dynamic oil immersion depth of a gear based on image processing as claimed in claim 1, characterized in that: The oil coverage area obtained based on the number of white pixels and the total number of pixels includes: Get the outer contour area of the gear; Based on the number of white pixels and the total number of pixels, a white ratio is obtained; The oil coverage area is obtained based on the white ratio and the outer contour area of the gear.
8. A gear dynamic oil immersion depth recognition system based on image processing, characterized in that it includes: Building blocks for modeling gear splash lubrication; A first calculation module, used for calculating the lubricating oil distribution based on the gear splash lubrication model; The first processing module is used to obtain surface oil liquid volume fraction distribution cloud maps of the front end and rear end of the gear according to the lubricating oil distribution, and to remove the background of the surface oil liquid volume fraction distribution cloud map to obtain a processed image; A second processing module, configured to grayscale the processed image based on an optimal linear weighted method to obtain a plurality of candidate grayscale images; A screening module, used for obtaining an optimal grayscale image based on the number of edge points in the candidate grayscale image; A third processing module is used to binarize the optimal grayscale image to obtain the number of white pixels; A second calculation module is used to obtain the oil coverage area based on the number of white pixels and the total number of pixels; A third calculation module, used for obtaining the dynamic oil immersion depth of the gear based on the oil coverage area and a preset formula; The preset formula is: Among them, S is the oil coverage area, S1 is the sector area, S2 is the isosceles triangle area, R is the outer diameter of the gear, α is the inner angle of the sector, and h is the dynamic oil immersion depth of the gear.
9. A terminal device, comprising a memory and a processor, characterized in that: The memory stores a computer program that can be run on the processor, and when the processor loads and executes the computer program, the method according to any one of claims 1 to 7 is adopted.
10. A computer-readable storage medium having a computer program stored therein, characterized in that: When the computer program is loaded and executed by a processor, the method according to any one of claims 1 to 7 is adopted.
Citation Information
Patent Citations
Oil liquid level image identification method for high-voltage oil-immersed transformer
CN111950558A
Submerged plant coverage area intelligent monitoring method
CN116152186A