A Visual Evaluation Method for Fracturing Stimulation Effects in Oil and Gas Wells
By analyzing the connected component features of downhole video frames, perforation confidence and cross-perforation matching risk values are constructed, and the HEVC algorithm parameters are dynamically adjusted. This solves the problem of inaccurate perforation area measurement in downhole video transmission and improves the evaluation accuracy and transmission stability of fracturing effects.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- DAQING YILAI TESTING TECH SERVICE CO LTD
- Filing Date
- 2026-04-24
- Publication Date
- 2026-05-26
AI Technical Summary
Existing technologies do not fully consider the movement characteristics and perforation similarity of downhole television in downhole video transmission, resulting in low accuracy of perforation area measurement and affecting the accuracy of fracturing effect evaluation.
By analyzing the connected component features in video frames, we construct the perforation confidence and cross-perforation matching risk value, dynamically adjust the merange parameter of the HEVC algorithm, optimize the encoding and transmission process, and ensure the integrity of the perforation boundary contour.
It improves the accuracy of perforation area measurement and fracturing effect evaluation, reduces errors in the encoding and transmission process, and enhances the stability and efficiency of video transmission.
Smart Images

Figure CN122093535A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of image transmission technology, specifically to a method for visually evaluating the fracturing effect of oil and gas wells. Background Technology
[0002] Shale oil and gas wells are mostly located in low-porosity, low-permeability reservoirs, where matrix permeability is typically extremely low, natural fractures are well-developed but poorly connected, making it difficult for fluids to form effective migration channels. High-resolution downhole visualization imaging and quantitative evaluation are core technologies for ensuring wellbore integrity, accurately characterizing reservoir structure, and optimizing fracturing effects. The evaluation of fracturing effects in oil and gas wells can be achieved through perforation area measurement; the more uniform the perforation area, the better the fracturing effect. During downhole measurement, video acquired by downhole television is transmitted in real-time via cable to a surface processing system for perforation area measurement and fracturing effect evaluation. However, due to limitations in cable transmission distance and speed, existing technologies typically employ the HEVC algorithm for video encoding and transmission to improve transmission stability.
[0003] However, the measurement of perforation area depends on the clarity of the boundary contour. Although inter-frame prediction in the HEVC algorithm reduces coding redundancy by searching for similar blocks in the reference frame through motion estimation, it uses a fixed motion estimation search range, which is difficult to adapt to dynamic downhole acquisition scenarios. Existing technologies do not fully consider that downhole television is acquired while moving when encoding using the HEVC algorithm. Therefore, the position of the same perforation may shift in adjacent frames. In addition, since the perforations within the same perforation cluster are affected by the same oil layer fracturing, there is also macroscopic similarity between the perforations, and they are relatively close to each other. This may lead to cross-perforation matching problems in the HEVC algorithm, resulting in distortion of the perforation boundary after compression, directly affecting the accuracy of perforation area measurement, and ultimately causing errors in the evaluation of fracturing effect. Summary of the Invention
[0004] To address the aforementioned technical problems, this application provides a method for visually evaluating the fracturing effect of oil and gas wells, thereby resolving existing issues.
[0005] The present application proposes a method for visually evaluating the fracturing effect of oil and gas wells, which adopts the following technical solution:
[0006] One embodiment of this application provides a method for visually evaluating the fracturing effect of oil and gas wells, the method comprising the following steps:
[0007] The system acquires video frames during the oil and gas well measurement process in real time, as well as the length of the cable inside the well at the time of each video frame; the video frames are divided into analysis intervals, and the analysis frames in each analysis interval are extracted.
[0008] Based on the number of connected components in each analysis frame, it is determined whether to use the default merange parameter for encoding and transmission. If not, the perforation confidence of each connected component is constructed based on the gradient magnitude of the edge points of each connected component in each analysis frame, the gray value of the pixels inside each connected component, and the probability that each connected component is circular, so as to determine whether each connected component is a perforated connected component.
[0009] Based on the number of perforation connected components in each analysis frame, it is determined again whether to use the default merange parameter for encoding and transmission. If not, based on the density of all perforation connected components in each analysis frame, the dispersion of all perforation confidences, and the displacement of each perforation connected component in each analysis frame relative to its next video frame, the cross-perforation matching risk value of each analysis frame is constructed, and combined with the cable length in the well at the time of each analysis frame, the motion adjustment factor of each analysis frame is obtained.
[0010] The default merange parameters of each analysis frame are optimized based on the motion adjustment factor. The optimized merange parameters are used to encode and transmit each analysis frame and all video frames in the analysis interval. The fracturing effect is evaluated based on the dispersion of the perforation area in each transmitted video frame.
[0011] Preferably, the analysis frame in each analysis interval refers to the first frame image in each analysis interval.
[0012] Preferably, the specific process of determining whether to use the default merange parameter for encoding and transmission based on the number of connected components in each analysis frame is as follows:
[0013] If the number of connected components in any analysis frame is less than 2, then the default merange parameter is used for encoding and transmission of that analysis frame and all video frames in the analysis interval; otherwise, it is not used.
[0014] Preferably, the method for constructing the perforation confidence of each connected domain is as follows:
[0015] Calculate the mean gradient magnitude of all edge points within each connected component;
[0016] Calculate the mean gray value a1 of all non-edge points in each connected component and the mean gray value a2 of all pixels in the analysis frame where each connected component is located. Record the ratio of a1 to a2 as the first ratio of each connected component.
[0017] Find the minimum bounding rectangle of each connected component, and record the ratio of the length to the width of the minimum bounding rectangle as the second ratio of each connected component.
[0018] Calculate the absolute difference between the second ratio and 1;
[0019] The perforation confidence of each connected region is positively correlated with the mean of the gradient magnitude, and negatively correlated with the first ratio and the absolute difference.
[0020] Preferably, the perforation connectivity refers to a connectivity where the perforation confidence is greater than or equal to a preset perforation threshold.
[0021] Preferably, the specific process of determining again whether to use the default merange parameter for encoding and transmission is as follows:
[0022] If the number of perforated connected components in any analysis frame is less than 2, then the default merange parameter is used for encoding and transmission of that analysis frame and all video frames in the analysis interval; otherwise, it is not used.
[0023] Preferably, the method for constructing the cross-aperture matching risk value of each analysis frame is as follows:
[0024] Calculate the Euclidean distance between the centroid coordinates of any two connected regions of perforations in each analysis frame, and find the minimum value among all Euclidean distances;
[0025] Calculate the variance among the perforation confidence scores of all perforation connected components within each analysis frame;
[0026] Each analysis frame and its next video frame are used as inputs to the optical flow method. The displacement vector of the centroid of the perforation in each perforation connected region in each analysis frame is obtained between adjacent frame images, and the magnitude of the displacement vector is recorded as the motion distance of each perforation connected region in each analysis frame.
[0027] The mean motion distance of all perforation connected components in each analysis frame is calculated.
[0028] The cross-hole matching risk value of each analysis frame is positively correlated with the mean value and negatively correlated with the minimum value and the variance.
[0029] Preferably, the motion adjustment factor of each analysis frame is positively correlated with the cross-hole matching risk value and negatively correlated with the cable length.
[0030] Preferably, the specific formula for optimizing the default merange parameter of each analysis frame is as follows: In the formula, The optimized merange parameter for the i-th analysis frame; This is the default merange value for the HEVC algorithm; Let i be the motion adjustment factor for the i-th analysis frame; These are preset parameter tuning coefficients; This is the normalization function; This is the floor function.
[0031] Preferably, the dispersion of the aperture area in each video frame refers to the variance between the areas of all connected regions of apertures in each transmitted video frame.
[0032] This application has at least the following beneficial effects:
[0033] This application addresses the problem that existing technologies fail to adequately consider the movement characteristics and perforation similarity of downhole television, employing a fixed motion estimation search range, which leads to low accuracy in perforation area measurement in transmitted video frames. By analyzing the perforation characteristics of connected components in video frames, a perforation confidence score is constructed, enabling accurate identification of perforation connected components within video frames and providing a reliable basis for subsequent coding parameter adjustments. Furthermore, by analyzing the perforation distribution characteristics within each analysis frame and the perforation position movement characteristics relative to the next video frame, a cross-perforation matching risk value is constructed. This quantifies the likelihood of cross-perforation matching occurring during inter-frame prediction. Combined with the downhole cable length at the time of each video frame, a motion adjustment factor is constructed. This comprehensively considers the relative relationship between the cross-perforation matching risk value and the transmission distance, dynamically adjusting the merange parameter. This ensures efficient coding transmission while effectively protecting the integrity of the perforation boundary contour, thereby improving the accuracy of perforation area measurement and the evaluation of fracturing effects. Attached Figure Description
[0034] To more clearly illustrate the technical solutions and advantages in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0035] Figure 1 A flowchart illustrating the steps of a method for visually evaluating the fracturing effect of oil and gas wells, as provided in this application.
[0036] Figure 2 A flowchart illustrating the acquisition of motion adjustment factors for each analysis frame provided in this application. Detailed Implementation
[0037] To further illustrate the technical means and effects adopted by this application to achieve the intended purpose of the invention, the following, in conjunction with the accompanying drawings and preferred embodiments, details the specific implementation, structure, features, and effects of a method for visually evaluating the fracturing effect of oil and gas wells proposed in this application. In the following description, different "one embodiment" or "another embodiment" do not necessarily refer to the same embodiment. Furthermore, specific features, structures, or characteristics in one or more embodiments can be combined in any suitable form.
[0038] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application pertains.
[0039] The following description, in conjunction with the accompanying drawings, details the specific scheme of the visualization evaluation method for fracturing stimulation of oil and gas wells provided in this application.
[0040] This application provides an embodiment of a method for visually evaluating the fracturing effect of oil and gas wells. Specifically, it provides the following method for visually evaluating the fracturing effect of oil and gas wells. Please refer to [link / reference]. Figure 1 The method includes the following steps:
[0041] Step 1: Real-time acquisition of video frames during the oil and gas well measurement process, as well as the length of the cable inside the well at the time of each video frame; dividing the video frames into analysis intervals, and extracting the analysis frames in each analysis interval.
[0042] This application uses the fracturing process of a certain oil and gas well as an example for analysis.
[0043] Because mud, proppant, and shale oil are mixed together in oil and gas wells, the wellbore must first be cleaned to ensure the quality of the logging video. The well cleaning process is as follows: 1. Connect the riveted connector, check valve, release handle, and flushing head into a tool string in top-to-bottom order; 2. Run coiled tubing into the well, then lower the tool string to 100m below the bottom of the measuring section, and mark the position on the coiled tubing; 3. Use 0.4... 7 displacement pumps inject 15% HCl acid solution After the pumping is completed, switch to clean water to replace the acid solution and remove all the acid solution from the wellbore; 4. Circulate clean water to flush the well until the turbidity of the liquid returning from the wellbore is ≤10 NTU, then start downhole television logging operations.
[0044] This application uses a continuous tube to transmit downhole television and uses an optical fiber composite cable for real-time measurement and transmission of downhole video. In this embodiment, the video frame rate captured by the downhole television is 30 frames per second.
[0045] However, considering the computing power limitations of downhole equipment, it is difficult to perform real-time analysis and calculation on all frames of images. Therefore, this application uses every n frames of all video frames as an analysis interval, and records the first frame in each analysis interval as the analysis frame. In this embodiment, n is taken as 10.
[0046] Furthermore, since the downhole television is lowered into the well along with the cable to capture video footage, the length of the cable is measured in real time, using the wellhead as a reference. Taking any analysis frame as an example, the cable length value corresponding to the acquisition of that frame is used as the numerator, and the pre-acquired design well depth of the oil and gas well is used as the denominator to normalize the cable length value. The normalization result is recorded as the relative depth value of that analysis frame, reflecting the relative position of the downhole television when that frame was acquired.
[0047] It should be noted that due to the limitations of resolution and computing power in downhole equipment, the perforation detection and analysis calculations performed in this application are only used for video encoding optimization and transmission. Afterwards, a surface processing system is needed to accurately calculate the area of the perforations in the transmitted video. The necessity of transmitting the video back to the surface lies in the fact that the surface not only needs to calculate high-precision areas but also needs to utilize high-definition video to observe multi-dimensional indicators such as the microscopic morphology of rock fractures and the proppant backflow status. These indicators cannot be automatically quantified downhole.
[0048] Step 2: Based on the number of connected components in each analysis frame, determine whether to use the default merange parameter for encoding and transmission; if not, construct the aperture confidence of each connected component based on the gradient magnitude of the edge points of each connected component in each analysis frame, the gray value of the pixels inside each connected component, and the probability that each connected component is circular, so as to determine whether each connected component is a aperture connected component.
[0049] When encoding and transmitting video captured by downhole television using the HEVC algorithm, the merange parameter defines the search range for motion estimation between frames. A larger value results in a wider search range, making it easier to find suitable matching blocks, thereby reducing prediction residuals and the number of bits required for encoding. This is more beneficial for real-time video transmission under limited bandwidth. However, downhole perforations are characterized by small diameters, large numbers, and clustered distribution. Furthermore, perforations within the same cluster are located in the same oil layer and experience similar stress conditions under fracturing, leading to strong morphological similarities. Additionally, the movement of the downhole television along the wellbore axis can cause positional shifts in the same perforation in adjacent frames. If a fixed merange parameter is used, the current matching block may be incorrectly matched to adjacent perforation regions during motion estimation, resulting in cross-perforation matching. This leads to blurred or distorted perforation boundaries in the compressed image, ultimately affecting the accuracy of perforation area measurement.
[0050] Furthermore, since the non-perforated areas of the wellbore inner wall are not included in the evaluation calculation of fracturing effect, there is no need to adjust the merange parameter to avoid affecting the overall compression and transmission performance due to frequent changes in compression parameters. Therefore, the first step is to analyze whether perforations exist in each frame image to assess whether the merange parameter in the HEVC algorithm needs to be adjusted.
[0051] Since the distance between perforations within the same perforation cluster is relatively short, and the number of perforations within the cluster is usually no less than two, this spatial feature can be used to initially screen the images.
[0052] Taking any analysis frame acquired when the underground television begins video acquisition as an example, the analysis frame is denoised and converted into a grayscale image. Then, all connected components within the analysis frame are obtained through a connected component generation algorithm, and the number of connected components is counted. Next, it is determined whether the number of connected components in the analysis frame is greater than or equal to 2. If the number of connected components in any analysis frame is less than 2, it indicates that the overall structure of the analysis frame is continuous and lacks obvious separation regions. It can be determined that there are no perforations in the analysis frame, and thus the analysis frame and all video frames in its analysis interval can be encoded and transmitted using the default merange parameter of the HEVC algorithm. If the number of connected components in any analysis frame is greater than or equal to 2, the analysis frame and all video frames in its analysis interval are not encoded and transmitted using the default merange parameter, and further analysis of the analysis frame is required. The image denoising algorithm is not limited to median filtering or Gaussian filtering; the connected component generation algorithm is not limited to seed filling or region growing algorithms; in this embodiment, Gaussian filtering and region growing algorithms are used for processing.
[0053] According to the temporal order of each image frame, the number of connected components is detected in each acquired analysis frame. Taking the i-th analysis frame with a connected component count greater than or equal to 2 as an example, further determination is made, as follows:
[0054] In the non-perforated areas of the wellbore's inner wall, the surface is usually relatively smooth due to long-term fluid erosion, with uniform texture distribution and slow, continuous grayscale changes. However, the perforated areas are formed by blasting, with obvious abrupt changes in grayscale at the boundaries. Furthermore, because the interior of the perforation is a hollow structure, it does not reflect light when illuminated by a light source, resulting in extremely low grayscale values inside the perforation.
[0055] Taking the u-th connected component in the i-th analysis frame as an example, we evaluate the probability that it is a perforation.
[0056] All edge points within the i-th analysis frame are obtained using an edge detection algorithm. The edge detection algorithm is not limited to the Canny algorithm or the Laplacian algorithm; this embodiment uses the Canny algorithm.
[0057] Since the boundary of a perforation exhibits abrupt changes, the gradient magnitudes at each edge point within the u-th connected domain are calculated using the Sobel operator, and the average of all gradient magnitudes is recorded as the first mean of the u-th connected domain. The first mean reflects the intensity of the abrupt change at the boundary of the u-th connected domain; a larger value indicates a more pronounced boundary abrupt change, which better matches the edge characteristics of a perforation.
[0058] Furthermore, the mean grayscale value a1 of all non-edge points in the u-th connected component of the i-th analysis frame and the mean grayscale value a2 of all pixels in the i-th analysis frame are calculated respectively, and the ratio of a1 to a2 is recorded as the first ratio of the u-th connected component of the i-th analysis frame. The first ratio reflects the relative grayscale level of the region inside the u-th connected component of the i-th analysis frame. The smaller the value, the darker the inside of the connected component, which is more consistent with the grayscale characteristics of the aperture as a cavity structure.
[0059] Furthermore, since perforations are approximately circular in their initial state, even under erosion, their overall shape will retain certain circular characteristics. Therefore, the circumscribed rectangles of the corresponding connected regions are usually quite similar in length and width. However, non-perforated connected regions formed by mud residue patches, crude oil corrosion contamination, etc., are usually irregular, which leads to significant differences in the length and width of their circumscribed rectangles.
[0060] Obtain the minimum bounding rectangle of the u-th connected component, and denote the ratio of the length to the width of the minimum bounding rectangle as the second ratio of the u-th connected component. The second ratio reflects the directional balance of the shape of the u-th connected component. The closer the value is to 1, the more the u-th connected component conforms to the approximately circular characteristics of a perforation; the more the value deviates from 1, the more the connected component exhibits a long and narrow shape.
[0061] To eliminate the influence of dimensions, the first mean and first ratio of each connected component in each analysis frame are normalized using the minimum-maximum normalization method. The minimum and maximum values are determined based on the corresponding parameter set of T video frames (T is a preset number, taken as 200 in this embodiment) in the historical video.
[0062] In a preferred embodiment, based on the gradient magnitude of the edge points of each connected region within each analysis frame, the grayscale value of the pixels inside each connected region, and the probability that each connected region is circular, a perforation confidence score is constructed for each connected region to characterize the probability that each connected region in each analysis frame is a perforation region. The method for constructing the perforation confidence score for each connected region is as follows: calculate the mean gradient magnitude of all edge points within each connected region; calculate the mean grayscale value a1 of all non-edge points in each connected region and the mean grayscale value a2 of all pixels in the analysis frame containing each connected region, and record the ratio of a1 to a2 as the first ratio for each connected region; obtain the minimum bounding rectangle of each connected region, and record the ratio of the length to the width of the minimum bounding rectangle as the second ratio for each connected region; calculate the absolute difference between the second ratio and 1; the perforation confidence score for each connected region is positively correlated with the mean gradient magnitude and negatively correlated with both the first ratio and the absolute difference. The positive correlation refers to the dependent variable increasing (decreasing) as the independent variable increases (decreases), while the negative correlation refers to the dependent variable decreasing (increasing) as the independent variable increases (decreases).
[0063] In this embodiment, the perforation confidence of the u-th connected component within the i-th analysis frame is denoted as . Its specific expression is: In the formula, Let be the perforation confidence of the u-th connected component within the i-th analysis frame; Let be the normalized value of the first mean of the u-th connected component within the i-th analysis frame; This is the normalized value of the first ratio of the u-th connected component within the i-th analysis frame; The second ratio of the u-th connected component within the i-th analysis frame; This is a preset constant. To avoid the denominator being 0, its value range is (0.05, 0.1). The value has little impact on the calculation result and can be ignored. In this embodiment, it is 0.08.
[0064] Perforation confidence is achieved through To reflect the strength of boundary abrupt changes in connected components; through To reflect the relative gray levels within connected components; through This reflects the degree to which the connected region is approximately circular; finally, the perforation confidence score is obtained through fusion processing, thereby comprehensively reflecting the possibility that the connected region is a perforation region. The larger the value, the greater the probability that the u-th connected component in the i-th analysis frame conforms to the perforation feature in terms of boundary features, internal features, and overall morphological features, and is a perforation region.
[0065] Furthermore, by combining images captured during historical well logging, perforations in the current frame image are identified, as follows:
[0066] From historical videos captured by downhole measurements, T images (T being a preset number, 200 in this embodiment) with a connected component count greater than or equal to 2 are acquired. Following the calculation steps and principles of perforation confidence, the perforation confidence of all connected components within the T images is calculated. All perforation confidence scores are used as input to the Otsu thresholding method, whose output is the segmentation threshold. In this embodiment, the segmentation threshold is denoted as the preset perforation threshold, used to distinguish between perforated and non-perforated connected components. It should be noted that the preset perforation threshold is calculated offline and not in real-time during the logging process.
[0067] Within the i-th analysis frame, the perforation confidence of all connected components is calculated, and all connected components that are greater than or equal to the preset perforation threshold are recorded as perforation connected components, thereby achieving the localization of perforation connected components.
[0068] Step 3: Based on the number of perforation connected components in each analysis frame, determine again whether to use the default merange parameter for encoding and transmission; if not, construct the cross-perforation matching risk value of each analysis frame based on the density of all perforation connected components in each analysis frame, the dispersion of all corresponding perforation confidence, and the displacement of each perforation connected component in each analysis frame relative to its next video frame, and obtain the motion adjustment factor of each analysis frame by combining the cable length in the well at the time of each analysis frame.
[0069] Furthermore, it is determined whether the number of connected components of the filtered perforations is greater than or equal to 2. If the number of connected components of the perforations in the i-th analysis frame is less than 2, then the analysis frame and all video frames in the analysis interval are encoded and transmitted using the default merange parameter of the HEVC algorithm. If the number of connected components of the perforations in the i-th analysis frame is greater than or equal to 2, then the following calculation is performed.
[0070] Within the i-th analysis frame, the centroid coordinates of each connected component of the apertures are obtained. Then, the Euclidean distance between the centroid coordinates of any two connected components of the apertures in the i-th analysis frame is calculated, and the minimum value among all Euclidean distances is denoted as the first distance of the i-th analysis frame. A smaller first distance indicates a denser spatial distribution of apertures within the i-th analysis frame. This makes it easier for the search range to cover adjacent apertures during inter-frame motion estimation, increasing the risk of cross-aperture matching. Therefore, it is more necessary to limit the spatial range of motion estimation.
[0071] Furthermore, cross-aperture matching is also closely related to the degree of morphological similarity between apertures. The higher the similarity between apertures within the same aperture cluster, the more likely the current frame image is to misidentify adjacent apertures as matching targets in the reference frame during the encoding process.
[0072] Therefore, the dispersion of the perforation confidence scores among all perforation connected components within the i-th analysis frame is calculated and denoted as the first discrete value of the i-th analysis frame. Since the perforation confidence score comprehensively reflects the characteristics of the perforation in three dimensions: boundary abruptness, internal grayscale, and overall morphology, a smaller first discrete value indicates smaller visual differences between perforations, closer morphological features, higher similarity, and a greater risk of cross-perforation matching. The calculation of dispersion is not limited to variance, standard deviation, and coefficient of variation; this embodiment uses variance calculation.
[0073] Furthermore, considering that the downhole television moves within the wellbore to collect video, when the movement speed is fast, the position of the same perforation in adjacent frames changes significantly, causing its predicted position in the reference frame to no longer be limited to a local area. If the distance between perforations is small at this time, it is easier to cross adjacent perforations and cause incorrect matching during motion estimation. Therefore, it is necessary to further analyze the movement speed of the downhole television.
[0074] Therefore, taking the v-th aperture connected component in the i-th analysis frame as an example, the i-th analysis frame and its next video frame are used as inputs to the optical flow method. This allows us to obtain the displacement vector of the centroid of the v-th aperture connected component in the i-th analysis frame between adjacent frames, and the magnitude of this displacement vector is denoted as the movement distance of the v-th aperture connected component in the i-th analysis frame. It should be noted that the i-th analysis frame and its next video frame are temporally adjacent frames.
[0075] The motion distances of all connected components of the perforations in the i-th analysis frame are obtained in the same way and averaged, denoted as the inter-frame displacement between the i-th analysis frame and its next video frame. The inter-frame displacement reflects the overall displacement amplitude of the perforations between adjacent frames, thus reflecting the motion speed of the downhole television in the well. The larger the value, the more obvious the position change of the centroid of each perforation in adjacent frames, which makes it easier for the predicted position offset range of the same perforation in the reference frame to increase.
[0076] As a preferred implementation, a cross-aperture matching risk value is constructed for each analysis frame based on the density of all connected components within each analysis frame, the dispersion of all corresponding perforation confidence levels, and the displacement of each connected component in each analysis frame relative to its next video frame. This risk value characterizes the probability of cross-aperture mismatches occurring during inter-frame prediction for each analysis frame. The method for constructing the cross-aperture matching risk value for each analysis frame is as follows: calculate the Euclidean distance between the centroid coordinates of any two connected components in each analysis frame, and calculate the minimum value among all Euclidean distances; calculate the variance between the perforation confidence levels of all connected components within each analysis frame; and calculate the inter-frame displacement between each analysis frame and its next video frame. The cross-aperture matching risk value for each analysis frame is positively correlated with the inter-frame displacement and negatively correlated with the minimum value and the variance.
[0077] To avoid the influence of inconsistent dimensions on subsequent calculation results, the first distance, first discrete value, and inter-frame displacement of each analysis frame are normalized. In this embodiment, the minimum-maximum normalization method is used for normalization processing, where the minimum and maximum values are determined based on the corresponding parameter set of T video frames in the historical video.
[0078] In this embodiment, the cross-aperture matching risk value of the i-th analysis frame is denoted as... Its specific expression is: In the formula, Let be the cross-aperture matching risk value of the i-th analysis frame; This is the normalized value of the first distance in the i-th analysis frame; This is the normalized value of the first discrete value of the i-th analysis frame; This is the normalized value of the inter-frame displacement between the i-th analysis frame and its next video frame. The value is set to a minimum positive number to prevent the denominator from being 0; in this embodiment, it is set to 0.01.
[0079] The cross-aperture matching risk value characterizes the probability of a cross-aperture mismatch occurring during inter-frame prediction in the i-th analysis frame. A larger value indicates a greater inter-frame displacement and a higher probability of closely spaced and similar apertures. A larger value indicates a faster movement speed of the downhole television, which makes it easier for the predicted position to deviate from its expected range. A smaller value makes it easier to generate cross-perforation matching, so the merange parameter should be reduced to limit the range of motion estimation, thereby ensuring the fidelity of the perforation boundary and improving the evaluation accuracy of subsequent fracturing effects.
[0080] Furthermore, the cross-aperture matching risk value is used to characterize the probability of mismatches occurring on the image side during inter-frame prediction, but it does not consider the constraints on the cable transmission side. Since downhole video relies on cable transmission, signal attenuation intensifies and the available bandwidth of the link decreases as the transmission distance increases. Therefore, to ensure stable and continuous transmission of video data to the ground processing system, the bitrate must be appropriately reduced to alleviate the transmission burden. Moreover, since expanding the search range by increasing the merange parameter can obtain more accurate matching blocks, thereby reducing prediction residuals and achieving a lower output bitrate under the same quantization parameters, further analysis is needed.
[0081] In a preferred embodiment, based on the cross-aperture matching risk value of each analysis frame and the cable length inside the well at the time of each analysis frame, a motion adjustment factor is obtained for each analysis frame to characterize the stability of the transmission conditions of each analysis frame. The motion adjustment factor of each analysis frame is positively correlated with the cross-aperture matching risk value and negatively correlated with the cable length. The flowchart for obtaining the motion adjustment factor of each analysis frame is shown below. Figure 2 As shown.
[0082] In this embodiment, the motion adjustment factor of the i-th analysis frame is denoted as... Its specific expression is: In the formula, Let i be the motion adjustment factor for the i-th analysis frame; Let be the cross-aperture matching risk value of the i-th analysis frame; Let be the relative depth value of the i-th analysis frame; It is an exponential function with the natural constant e as the base, and its purpose is to increase... The weight.
[0083] The motion adjustment factor takes into account the relative relationship between the cross-aperture matching risk value and the transmission distance. The larger the value, the more prominent the cross-aperture matching risk value of the i-th analysis frame is relative to the transmission distance. At this time, the downhole TV is located in the shallow well section, and the transmission conditions are good. There is no need to worry too much about the bit rate pressure. Therefore, the value of the merange parameter can be reduced significantly to prioritize the fidelity of the perforation boundary and avoid the contour distortion caused by cross-aperture matching.
[0084] When the motion adjustment factor is small, it indicates a long transmission distance, and bandwidth limitation becomes the main constraint. In this case, if the merange value is still significantly reduced, it may lead to high bitrate and transmission interruption. Therefore, the merange value should be appropriately relaxed to prioritize the stable transmission of video data.
[0085] Step 4: Optimize the default merange parameters of each analysis frame based on the motion adjustment factor, and encode and transmit each analysis frame and all video frames in the analysis interval with the optimized merange parameters; evaluate the fracturing effect based on the dispersion of the perforation area in each transmitted video frame.
[0086] Furthermore, for the special scenario where downhole perforations are similar in height and clustered together, when adjacent perforations are close together, have similar shapes, and the downhole television moves quickly, expanding the search range using conventional video coding strategies can easily lead to incorrect motion vector matching between adjacent perforations. This application employs a strategy of inversely limiting the search range, sacrificing some compression ratio to preserve the high-frequency fidelity of the perforation profile and prevent boundary aliasing.
[0087] Specifically, based on the motion adjustment factor of each analysis frame, the default merange parameter of each analysis frame is adjusted, and the specific adjustment formula is as follows: In the formula, The optimized merange parameter for the i-th analysis frame; This is the default merange value for the HEVC algorithm; in this embodiment, it is the default value of 57. Let i be the motion adjustment factor for the i-th analysis frame; This is a preset parameter tuning coefficient used to limit the range of parameter adjustment and avoid excessive changes in merange that could lead to instability in the encoding process. In this embodiment, it is set to 15. As a normalization function, this embodiment adopts the minimum-maximum normalization method. The minimum and maximum values are determined based on the motion adjustment factor of images with a preset number of perforation connectivity regions greater than or equal to 2 in the historical logging process. This is the floor function.
[0088] Since this embodiment divides the video into an analysis interval every 10 frames, the optimized version is used. The i-th analysis frame and all video frames within the same analysis interval are encoded and transmitted. Similarly, all analysis frames with a perforation connectivity of 2 or more, and all other frames within the same analysis interval, are encoded and transmitted using the optimized merange parameter.
[0089] By adaptively adjusting merange, when the motion adjustment factor is high, merange is appropriately reduced to narrow the search range of motion estimation and reduce the probability of cross-perforation mismatch, thereby ensuring the clarity of perforation boundaries; when the motion adjustment factor is low, merange is close to the default value to maintain coding efficiency. This allows the coding process to dynamically respond to changes in the downhole scene, improving the overall video transmission quality and the reliability of subsequent analysis.
[0090] The surface processing system receives video data transmitted from downhole in real time and sequentially performs image correction and enhancement processing on video frames containing perforation connectivity to eliminate shooting angle deviations and improve contrast. Subsequently, existing OpenCV image processing methods are used to extract the area of each perforation connectivity in each video frame, achieving quantitative measurement of the perforation area. Image correction, image enhancement, and contour calculation are all well-known techniques and will not be elaborated upon here.
[0091] Furthermore, the dispersion of the areas of all perforation connected regions in each video frame is calculated. In this embodiment, variance is still used to calculate the dispersion. The smaller the dispersion, the better the uniformity of the perforation fracturing effect at the time of each frame, and the more ideal the corresponding fracturing effect, thereby realizing a visual evaluation of the fracturing effect of oil and gas wells.
[0092] It should be noted that the order of the embodiments described above is merely for descriptive purposes and does not represent the superiority or inferiority of the embodiments. Furthermore, specific embodiments of this specification have been described above. Additionally, the processes depicted in the accompanying drawings do not necessarily require a specific or sequential order to achieve the desired results. In some implementations, multitasking and parallel processing are possible or may be advantageous.
[0093] The various embodiments in this specification are described in a progressive manner. The same or similar parts between the various embodiments can be referred to each other. Each embodiment focuses on describing the differences from other embodiments.
[0094] The above-described embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them; modifications to the technical solutions described in the foregoing embodiments, or equivalent substitutions of some of the technical features, do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of this application, and should all be included within the protection scope of this application.
Claims
1. A method for visually evaluating the fracturing effect of oil and gas wells, characterized in that, The method includes the following steps: The system acquires video frames during the oil and gas well measurement process in real time, as well as the length of the cable inside the well at the time of each video frame; the video frames are divided into analysis intervals, and the analysis frames in each analysis interval are extracted. Based on the number of connected components in each analysis frame, it is determined whether to use the default merange parameter for encoding and transmission. If not, the perforation confidence of each connected component is constructed based on the gradient magnitude of the edge points of each connected component in each analysis frame, the gray value of the pixels inside each connected component, and the probability that each connected component is circular, so as to determine whether each connected component is a perforated connected component. Based on the number of perforation connected components in each analysis frame, it is determined again whether to use the default merange parameter for encoding and transmission. If not, based on the density of all perforation connected components in each analysis frame, the dispersion of all perforation confidences, and the displacement of each perforation connected component in each analysis frame relative to its next video frame, the cross-perforation matching risk value of each analysis frame is constructed, and combined with the cable length in the well at the time of each analysis frame, the motion adjustment factor of each analysis frame is obtained. The default merange parameters of each analysis frame are optimized based on the motion adjustment factor. The optimized merange parameters are used to encode and transmit each analysis frame and all video frames in the analysis interval. The fracturing effect is evaluated based on the dispersion of the perforation area in each transmitted video frame.
2. The method for visually evaluating the fracturing effect of oil and gas wells as described in claim 1, characterized in that, The analysis frame in each analysis interval refers to the first frame image in each analysis interval.
3. The method for visually evaluating the fracturing effect of oil and gas wells as described in claim 1, characterized in that, The specific process of determining whether to use the default merange parameter for encoding and transmission based on the number of connected components in each analysis frame is as follows: If the number of connected components in any analysis frame is less than 2, then the default merange parameter is used for encoding and transmission of that analysis frame and all video frames in the analysis interval; otherwise, it is not used.
4. The method for visually evaluating the fracturing effect of oil and gas wells as described in claim 1, characterized in that, The method for constructing the perforation confidence of each connected component is as follows: Calculate the mean gradient magnitude of all edge points within each connected component; Calculate the mean gray value a1 of all non-edge points in each connected component and the mean gray value a2 of all pixels in the analysis frame where each connected component is located. Record the ratio of a1 to a2 as the first ratio of each connected component. Find the minimum bounding rectangle of each connected component, and record the ratio of the length to the width of the minimum bounding rectangle as the second ratio of each connected component. Calculate the absolute difference between the second ratio and 1; The perforation confidence of each connected region is positively correlated with the mean of the gradient magnitude, and negatively correlated with the first ratio and the absolute difference.
5. The method for visually evaluating the fracturing effect of oil and gas wells as described in claim 1, characterized in that, The perforation connectivity refers to the connectivity where the perforation confidence is greater than or equal to a preset perforation threshold.
6. The method for visually evaluating the fracturing effect of oil and gas wells as described in claim 1, characterized in that, The specific process of determining again whether to use the default merange parameter for encoding and transmission is as follows: If the number of perforated connected components in any analysis frame is less than 2, then the default merange parameter is used for encoding and transmission of that analysis frame and all video frames in the analysis interval; otherwise, it is not used.
7. The method for visually evaluating the fracturing effect of oil and gas wells as described in claim 1, characterized in that, The method for constructing the cross-aperture matching risk value for each analysis frame is as follows: Calculate the Euclidean distance between the centroid coordinates of any two connected regions of perforations in each analysis frame, and find the minimum value among all Euclidean distances; Calculate the variance among the perforation confidence scores of all perforation connected components within each analysis frame; Each analysis frame and its next video frame are used as inputs to the optical flow method. The displacement vector of the centroid of the perforation in each perforation connected region in each analysis frame is obtained between adjacent frame images, and the magnitude of the displacement vector is recorded as the motion distance of each perforation connected region in each analysis frame. The mean motion distance of all perforation connected components in each analysis frame is calculated. The cross-hole matching risk value of each analysis frame is positively correlated with the mean value and negatively correlated with the minimum value and the variance.
8. The method for visually evaluating the fracturing effect of oil and gas wells as described in claim 1, characterized in that, The motion adjustment factor of each analysis frame is positively correlated with the cross-hole matching risk value and negatively correlated with the cable length.
9. The method for visually evaluating the fracturing effect of oil and gas wells as described in claim 1, characterized in that, The specific formula for optimizing the default merange parameter of each analysis frame is as follows: In the formula, The optimized merange parameter for the i-th analysis frame; This is the default merange value for the HEVC algorithm; Let i be the motion adjustment factor for the i-th analysis frame; These are preset parameter tuning coefficients; This is the normalization function; This is the floor function.
10. The method for visually evaluating the fracturing effect of oil and gas wells as described in claim 1, characterized in that, The dispersion of the perforation area in each video frame refers to the variance between the areas of all connected regions of perforations in each transmitted video frame.