Spherical tank weld TOFD image defect type identification method and system
By constructing a feature extraction model and a dynamic feature extraction module, combined with dynamic film review knowledge, weld defects in TOFD detection images are type identification, which solves the problems of low identification accuracy and poor credibility in the prior art, and improves the accuracy and reliability of defect recognition.
Patent Information
- Application Number
- CN202411654461.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-19
- Publication Date
- 2025-02-28
AI Technical Summary
When identifying defect types in TOFD detection images, existing intelligent recognition technology has low accuracy and poor credibility, and has failed to fully integrate domain knowledge, which cannot meet the actual needs of large-scale spherical tank detection fields.
By constructing a feature extraction model, we capture the change information of defects in dynamic reviews, and use dynamic features to type the defects. The specific methods include continuously preprocessing a single TOFD image, generating a gradient image set M, using an AI model to learn a gradient image set M, extracting static features, and obtaining dynamic features through a Linformer encoder, and finally performing defect type recognition.
The accuracy and reliability of defect recognition are improved, and the dynamic film review knowledge in the field of non-destructive testing is fully utilized, and the dynamic film review process of TOFD image weld defect type is realized, which enhances the model's understanding of defect characteristics.
Smart Images

Figure CN119540635A_ABST
Abstract
Description
Background Art
[0002] TOFD nondestructive testing technology is widely used in defect detection and type identification of large spherical tank welds. The number of TOFD inspection images of large spherical tanks is huge. Currently, they are mainly evaluated manually, which has a long working cycle and high labor intensity. The existing intelligent methods have low accuracy and poor credibility, which cannot meet the actual needs of enterprises and cannot bear quality responsibility. Therefore, it is the focus of research in the field of large spherical tank inspection to develop automatic weld defect identification technology based on TOFD inspection images and improve the accuracy and reliability of defect identification.
[0003] Existing intelligent recognition technologies often ignore the dynamic observation behavior of experts in the field of nondestructive testing during the film evaluation process, that is, by adjusting parameters such as image contrast and clarity, observing the detailed characteristics of defects as the parameters change. This "dynamic film evaluation" can provide more information about the defect type. In addition, existing methods generally use a single image for analysis and fail to fully integrate domain knowledge, making it impossible for AI technology to be deeply integrated with domain needs, making it difficult to ensure the accuracy and reliability of defect analysis results. Summary of the invention
[0004] The technical problem to be solved by the present invention is to provide a method and system for identifying the defect types of TOFD images of spherical tank welds in response to the above-mentioned deficiencies in the prior art. By constructing a feature extraction model, the changing information of defects in dynamic film evaluation is captured, and dynamic features are used to identify the types of defects, so as to solve the technical problems of low recognition, poor credibility, and failure to fully integrate domain knowledge in the existing methods.
[0005] The present invention adopts the following technical solutions: A method for identifying defect types of spherical tank weld TOFD images comprises the following steps: Continuously preprocess a single image to generate an image set M consisting of several gradient images, and use the AI model to learn the gradient image set M; Extract features from each image in the gradient image set M to obtain static features; The defect category corresponding to each image set M is represented as a category vector, and is input into the Linformer encoder together with the static features of each image in the gradient image set M to obtain dynamic features; The obtained dynamic features are used to identify the defect type.
[0006] Preferably, a single image is preprocessed continuously to generate an image set M consisting of a plurality of gradient images as follows: Based on the TOFD gain adjustment technology, the range of the decibel gain 𝛽 of the gain adjustment is determined, and the structural similarity between the original image and the generated image is calculated using the SSIM index to ensure the similarity of the generated image obtained by adjusting the decibel gain 𝛽; Determine the number 𝑛 of original TOFD images to be generated, set different numbers of images to be generated n for experiments, determine the optimal value of the number of images generated n according to the experimental results, and use the range of decibel gain 𝛽 to select n decibel gain values 𝛽 at equal intervals within the range. Each selected 𝛽 value generates a TOFD image, forming a continuous image set M.
[0007] Preferably, the processed TOFD image The pixel value corresponding to the pixel point for:
[0008] in, is the decibel gain of amplification or reduction, Original image The pixel value of the pixel in .
[0009] Preferably, the SSIM index is greater than 0.6.
[0010] Preferably, feature extraction is performed on each image in the gradient image set M to obtain static features as follows: Resnet50 and ViT-B / 16 are selected to respectively Perform feature extraction to obtain local features and global features ; Use global average pooling Features and Process and obtain features and ; Use direct splicing Perform feature fusion to obtain the final static feature .
[0011] Preferably, the static feature Specifically:
[0012] in, is the first images, It is the Resnet50 feature extraction function operation. It is the ViT-B / 16 feature extraction function operation. is the first images static characteristics.
[0013] Preferably, the defect category corresponding to each image set M is represented as a category vector, and together with the static features of each image in the gradient image set M, is input into the Linformer encoder to obtain the dynamic features, specifically: The defect category corresponding to each image set M is represented as a category vector, and together with the static features of each image in the image set M obtained by the multi-image generation module Input into the Linformer encoder together; In the encoder, after layer regularization , Multi-head linear self-attention mechanism , residual connection and multilayer perceptron Operation, obtain dynamic features ; By inputting dynamic features into the classifier In this way, it learns the ability to map dynamic features to different defect types and uses dynamic features to complete defect type identification.
[0014] Preferably, the dynamic feature The calculation is as follows:
[0015] in, The intermediate feature.
[0016] Preferably, the intermediate feature for:
[0017] in, is the defect category vector and the static features of each image in the image set M Together they form the input feature vector.
[0018] In a second aspect, an embodiment of the present invention provides a spherical tank weld TOFD image defect type recognition system, comprising: The preprocessing module continuously preprocesses a single image to generate an image set M consisting of several gradient images, and uses the AI model to learn the gradient image set M; The feature module extracts features from each image in the gradient image set M to obtain static features; The extraction module represents the defect category corresponding to each image set M as a category vector, and inputs it into the Linformer encoder together with the static features of each image in the gradient image set M to obtain dynamic features; The recognition module uses the obtained dynamic features to identify the defect type.
[0019] In a third aspect, a computer device includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the above-mentioned method for identifying defect types of spherical tank weld TOFD images when executing the computer program.
[0020] In a fourth aspect, an embodiment of the present invention provides a computer-readable storage medium, comprising a computer program, which, when executed by a processor, implements the steps of the above-mentioned method for identifying defect types of spherical tank weld TOFD images.
[0021] Compared with the prior art, the present invention has at least the following beneficial effects: A defect type recognition method for TOFD images of spherical tank welds is proposed. Combining the characteristics of the film evaluation process in which defects are highlighted by continuously adjusting the contrast and clarity of TOFD images during manual film evaluation, a multi-image generation module based on gain adjustment is constructed. In order to comprehensively consider the location information and morphological information of defects, a static feature extraction model based on global + local feature fusion is constructed. A dynamic feature extraction module based on linear self-attention is constructed to capture the change information of defects in dynamic film evaluation, and the obtained dynamic features are used to identify the types of defects.
[0022] Furthermore, a single image is preprocessed continuously to generate an image set M consisting of several gradient images, and the gradient image set M is learned using an AI model, thereby simulating the dynamic observation process of professional non-destructive testing personnel when evaluating films, and integrating non-destructive testing field knowledge such as "dynamic film evaluation" into the AI model.
[0023] Furthermore, for the defect type identification determined by the comprehensive position and morphological information, a feature extraction module that can fuse global and local features is constructed to better focus on important features in the image, capture useful information in the image, and reduce noise interference in the image.
[0024] Furthermore, SSIM is an indicator used to evaluate the similarity between two images. It measures the degree of distortion of the processed images by comprehensively comparing the brightness, contrast and structural similarity of the two images, and calculates the SSIM value of the processed image and the original image. When SSIM>0.6, the degree of distortion of the processed image relative to the original image is acceptable.
[0025] Furthermore, a static feature extraction module based on global + local feature fusion is designed to obtain the morphological information of defects through local detail features, obtain the location information of defects through global macro features, and comprehensively consider the two types of information through feature fusion strategy.
[0026] Furthermore, a dynamic feature extraction module is designed to capture the contextual relationship between static features, and the domain knowledge of "dynamic film evaluation" is integrated to provide comprehensive evaluation information for the final defect type identification.
[0027] It can be understood that the beneficial effects of the second aspect mentioned above can be found in the relevant description of the first aspect mentioned above, and will not be repeated here.
[0028] In summary, the method of the present invention integrates the knowledge of dynamic film evaluation in the field of non-destructive testing, realizes the dynamic film evaluation process of weld defect types in TOFD images, and improves the accuracy and reliability of defect analysis results.
[0029] The technical solution of the present invention is further described in detail below through the accompanying drawings and embodiments. BRIEF DESCRIPTION OF THE DRAWINGS
[0030] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings to be used in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0031] Figure 1 It is a framework diagram of the method in the present invention; Figure 2 It is the process of generating multiple graphs; Figure 3 It is a static feature extraction module; Figure 4 It is a dynamic feature extraction module; Figure 5 A schematic diagram of a computer device provided by an embodiment of the present invention; Figure 6 The present invention is a block diagram of an electronic device provided according to an embodiment. DETAILED DESCRIPTION
[0032] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0033] In the description of the present invention, it should be understood that the terms “include” and “comprises” indicate the presence of described features, wholes, steps, operations, elements and / or components, but do not exclude the presence or addition of one or more other features, wholes, steps, operations, elements, components and / or collections thereof.
[0034] It should also be understood that the terms used in the present specification are only for the purpose of describing specific embodiments and are not intended to limit the present invention. As used in the present specification and the appended claims, unless the context clearly indicates otherwise, the singular forms "a", "an" and "the" are intended to include plural forms.
[0035] It should be further understood that the term "and / or" used in the present specification and the appended claims refers to any combination of one or more of the associated listed items and all possible combinations, and includes these combinations. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " in the present invention generally indicates that the associated objects are in an "or" relationship.
[0036] It should be understood that, although the terms first, second, third, etc. may be used to describe preset ranges, etc. in the embodiments of the present invention, these preset ranges should not be limited to these terms. These terms are only used to distinguish preset ranges from each other. For example, without departing from the scope of the embodiments of the present invention, the first preset range may also be referred to as the second preset range, and similarly, the second preset range may also be referred to as the first preset range.
[0037] The word "if" as used herein may be interpreted as "at the time of" or "when" or "in response to determining" or "in response to detecting", depending on the context. Similarly, the phrases "if it is determined" or "if (stated condition or event) is detected" may be interpreted as "when it is determined" or "in response to determining" or "when detecting (stated condition or event)" or "in response to detecting (stated condition or event)", depending on the context.
[0038] Various structural schematic diagrams of the embodiments disclosed in the present invention are shown in the accompanying drawings. These figures are not drawn to scale, and some details are magnified and some details may be omitted for the purpose of clear expression. The shapes of various regions and layers shown in the figures and the relative sizes and positional relationships therebetween are only exemplary, and may deviate in practice due to manufacturing tolerances or technical limitations, and those skilled in the art may additionally design regions / layers with different shapes, sizes, and relative positions according to actual needs.
[0039] The present invention provides a method for identifying defect types in TOFD images of spherical tank welds. Firstly, in combination with the characteristics of the film evaluation process in which defects are highlighted by continuously adjusting the contrast and clarity of TOFD images in the manual film evaluation process, a multi-image generation module based on gain adjustment is constructed to obtain a gradient image set M, so as to realize the data basis required for the "dynamic" film evaluation process. Then, in order to comprehensively consider the position information and morphological information of the defects, a static feature extraction model based on global + local feature fusion is constructed to comprehensively consider the position information and morphological information of the defects. Finally, a dynamic feature extraction module based on linear self-attention is constructed to capture the change information of defects in dynamic film evaluation, and the obtained dynamic features are used to identify the types of defects. By constructing the multi-image generation module based on gain adjustment, a series of gradient image sets M can be obtained. It helps to observe defects from different angles and improve the accuracy of defect identification; comprehensively considers the location information and morphological information of the defects, and through the fusion of global and local features, it can more comprehensively describe the defect characteristics and improve the accuracy of identification; based on the linear self-attention mechanism, this module can effectively capture the changing information of defects in dynamic film evaluation, which helps to better understand the characteristics of defects and improve the reliability of defect identification; through the dynamic feature extraction module, it makes full use of the information revealed by the dynamic observation behavior of experts in the film evaluation process, which helps to improve the accuracy and reliability of defect identification; through the mutual cooperation of the multi-image generation module, the static feature extraction model and the dynamic feature extraction module, the effective integration of professional knowledge and experience in the field of non-destructive testing is realized, and the accuracy and reliability of defect analysis results are improved.
[0040] See also Figure 1 The present invention provides a method for identifying defect types of spherical tank weld TOFD images, comprising the following steps: S1. Based on the TOFD gain adjustment technology, determine the range of the decibel gain 𝛽 of the gain adjustment, and use the SSIM index to calculate the structural similarity between the original image and the generated image to ensure that the generated image obtained by adjusting the decibel gain 𝛽 has a good similarity; S2, determining the number 𝑛 of original TOFD images to be generated, setting different numbers n of images to be generated for experiments, determining the optimal value of the number n of images to be generated according to the experimental results, and using the range of the decibel gain 𝛽 obtained in step S1, selecting n decibel gain values 𝛽 at equal intervals within the range, and generating a TOFD image for each selected 𝛽 value, thereby forming a continuous gradient image set M; In order to integrate non-destructive testing knowledge such as "dynamic film evaluation" into the AI model, it is necessary to first pre-process a single image continuously to generate an image set M consisting of several gradient images, and use the AI model to learn the gradient image set M, thereby simulating the dynamic observation process of professional non-destructive testing personnel when evaluating films. This image set can reflect the changing process of defects and the changing laws of defect texture characteristics, providing more information for defect type identification; Gain adjustment technology is the most commonly used preprocessing algorithm in current TOFD software. It amplifies or reduces the amplitude value of the waveform signal corresponding to all columns in the TOFD image by several times, thereby completing the processing of the entire TOFD image and changing the display effect of the image. Its expression is as follows:
[0041] in, is the original image; is the image after gain adjustment.
[0042] The principle is as follows: Since only the pixel value of each pixel point can be obtained from the TOFD image, and the amplitude value of its ultrasonic signal cannot be directly obtained, the pixel value of each point in the image is used to approximately replace the waveform amplitude value of each point for processing, that is:
[0043] in, The decibel gain of amplification or reduction, less than 0 means reduction, greater than 0 means increase; For processed images The pixel value corresponding to the pixel point is Original image Considering that the pixel value of an image ranges from 0 to 255, when When it is less than 0, it is still 0. When it is greater than 255, it remains 255. Repeat the above transformation process for each pixel in the image, which is .
[0044] In order to apply the gain adjustment algorithm to the multi-image generation module, two parameters need to be determined: decibel gain And the number of images generated For decibel gain The present invention determines the range of values by using the image quality evaluation index structural similarity SSIM. The solution for selecting the value is to use different The method of the present invention is experimented with and the optimal value is determined through the defect type recognition accuracy results.
[0045] SSIM is an indicator used to evaluate the similarity between two images. It is often used to measure the degree of distortion of images after processing. SSIM measures the similarity between two images by comprehensively comparing their brightness, contrast and structure. is the original image, For the processed image, is the brightness comparison function, is the contrast comparison function, is the structural similarity comparison function, then: , ,
[0046] in, and Respectively represent images and The pixel mean, and Respectively represent images and The pixel variance is Representing images and The pixel covariance between , , are three constants to avoid the denominator being 0.
[0047] The final SSIM calculation formula is as follows:
[0048] in, , , is the weight value, which is used to adjust the weights of the three comparison functions.
[0049] Determine decibel gain for using SSIM The value range of The three TOFD images were preprocessed and the SSIM values of the processed images and the original images were calculated. When SSIM>0.6, the distortion of the processed images relative to the original images is considered acceptable. Experiments have shown that for different images, the decibel gain values that can meet the quality requirements after gain adjustment are different, but when the decibel gain When the gain is between -20 and 10 dB, the images obtained by processing the three TOFD images can meet the quality requirements. Therefore, the initial upper and lower limits of the decibel gain are Specifically, for each image, the initial upper and lower limits need to be fine-tuned according to the SSIM value. Determine the decibel gain After the range is reached, evenly select the value between the upper and lower limits. Finally, according to the decibel gain The value can be obtained images, Figure 2 The whole process of generating multiple images from a single image is demonstrated.
[0050] S3, in order to comprehensively consider the position information and morphological information of the defects, feature extraction is performed on the gradient image set M obtained in step S2, and a static feature extraction module based on global + local feature fusion is constructed; After obtaining the gradient image set M from a single TOFD image by using the multi-image generation module, in order to better focus on the important features in the image, capture the useful information in the image, and reduce the noise interference in the image, it is necessary to extract features from each image in the image set to obtain a more compact, meaningful, and robust feature representation to provide a data basis for subsequent work. Therefore, an effective feature extraction module is designed. The specific process is as follows: S301, select Resnet50 and ViT-B / 16, respectively, for the input image Perform feature extraction to obtain local features and global features ; S302, using global average pooling Features and Process and obtain features and ; S303, use direct splicing method Perform feature fusion to obtain the final static feature , whose expression is:
[0051] in, is the first images, It is the Resnet50 feature extraction function operation. It is the ViT-B / 16 feature extraction function operation. is the first images static characteristics.
[0052] S4. Integrate the domain knowledge of "dynamic film evaluation" and build a dynamic feature extraction module based on linear self-attention to capture the changing information of defects in dynamic film evaluation, and realize the recognition of TOFD image defect types through more representative and discriminative dynamic features.
[0053] By using the static feature extraction module to obtain the static features of each image in the image set M, it can only represent the morphological information and position information of the defects in each image. These are still static information. In order to truly integrate the domain knowledge of "dynamic film evaluation", it is also necessary to capture the changing rules of defects in the preprocessing process. Therefore, a dynamic feature extraction module is designed to capture the contextual relationship between the static features. Through more representative and discriminative dynamic features, TOFD image defect type recognition is realized.
[0054] S401, the defect category corresponding to each image set M is represented as a category vector, and the static features of each image in the image set M obtained by the multi-image generation module are combined. Input into the Linformer encoder together; S402, in the encoder, after layer regularization , Multi-head linear self-attention mechanism , residual connection and multilayer perceptron etc. to obtain dynamic features , where layer regularization helps stabilize the network training process, multi-head linear self-attention mechanism helps capture contextual information in image sequences, residual connection helps alleviate the gradient vanishing problem, and multi-layer perceptron helps learn higher-level representations from extracted dynamic features. Together, these operations enable the encoder to generate more representative and discriminative dynamic features. The calculation process is as follows:
[0055]
[0056]
[0057] in, is the defect category vector and the static features of each image in the image set M The input feature vector is composed of is the intermediate feature, The dynamic features extracted.
[0058] S403, by inputting the dynamic features into the classifier In this way, it learns the ability to map dynamic features to different defect types, thereby using dynamic features to complete defect type identification.
[0059] It will be appreciated by those skilled in the art that various aspects of the present invention may be implemented as systems, methods or program products. Therefore, various aspects of the present invention may be specifically implemented in the following forms, namely: complete hardware implementation, complete software implementation (including firmware, microcode, etc.), or a combination of hardware and software implementations, which may be collectively referred to herein as "circuits", "modules" or "platforms".
[0060] In another embodiment of the present invention, a spherical tank weld TOFD image defect type recognition system is provided, which can be used to implement the above-mentioned spherical tank weld TOFD image defect type recognition method. Specifically, the spherical tank weld TOFD image defect type recognition system includes a preprocessing module, a feature module, an extraction module and a recognition module.
[0061] Among them, the preprocessing module continuously preprocesses a single image to generate an image set M consisting of several gradient images, and uses the AI model to learn the gradient image set M; The feature module extracts features from each image in the gradient image set M to obtain static features; The extraction module represents the defect category corresponding to each image set M as a category vector, and inputs it into the Linformer encoder together with the static features of each image in the gradient image set M to obtain dynamic features; The recognition module uses the obtained dynamic features to identify the defect type.
[0062] In another embodiment of the present invention, a terminal device is provided, the terminal device includes a processor and a memory, the memory is used to store a computer program, the computer program includes program instructions, and the processor is used to execute the program instructions stored in the computer storage medium. The processor may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components, etc. It is the computing core and control core of the terminal, which is suitable for implementing one or more instructions, and is specifically suitable for loading and executing one or more instructions to implement the corresponding method flow or corresponding function; the processor described in the embodiment of the present invention can be used for the operation of the TOFD image defect type recognition method of the spherical tank weld, including: A single image is preprocessed continuously to generate an image set M consisting of several gradient images, and the gradient image set M is learned using an AI model; feature extraction is performed on each image in the gradient image set M to obtain static features; the defect category corresponding to each image set M is represented as a category vector, and is input into the Linformer encoder together with the static features of each image in the gradient image set M to obtain dynamic features; the obtained dynamic features are used to identify the type of defects.
[0063] In another embodiment of the present invention, the present invention also provides a storage medium, specifically a computer-readable storage medium (Memory), which is a memory device in a terminal device for storing programs and data. It is understandable that the computer-readable storage medium here can include both the built-in storage medium in the terminal device and the extended storage medium supported by the terminal device, and can be any tangible medium containing or storing a program, which can be used by an instruction execution system, device or device or used in combination with it. The computer-readable storage medium provides a storage space, which stores the operating system of the terminal. In addition, one or more instructions suitable for being loaded and executed by the processor are also stored in the storage space, and these instructions can be one or more computer programs (including program codes). It should be noted that more specific examples (non-exhaustive list) of the computer-readable storage medium here include: an electrical connection with one or more wires, a portable disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above.
[0064] Computer readable storage media also include data signals propagated in baseband or as part of a carrier wave, which carry readable program codes. Such propagated data signals can take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. The readable storage medium can also be any readable medium other than a readable storage medium, which can send, propagate, or transmit a program for use by or in conjunction with an instruction execution system, device, or device. The program code contained on the readable storage medium can be transmitted using any appropriate medium, including but not limited to wireless, wired, optical cable, RF, etc., or any suitable combination of the above.
[0065] Program code for performing the operations of the present invention may be written in any combination of one or more programming languages, including object-oriented programming languages such as Java, C++, etc., and conventional procedural programming languages such as "C" or similar programming languages. The program code may be executed entirely on the user computing device, partially on the user device, as a separate software package, partially on the user computing device and partially on a remote computing device, or entirely on a remote computing device or server. In the case of a remote computing device, the remote computing device may be connected to the user computing device through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computing device (e.g., through the Internet using an Internet service provider).
[0066] The processor may load and execute one or more instructions stored in a computer-readable storage medium to implement the corresponding steps of the method for identifying defect types of spherical tank weld TOFD images in the above-mentioned embodiment; the processor may load and execute the following steps of one or more instructions in the computer-readable storage medium: A single image is preprocessed continuously to generate an image set M consisting of several gradient images, and the gradient image set M is learned using an AI model; feature extraction is performed on each image in the gradient image set M to obtain static features; the defect category corresponding to each image set M is represented as a category vector, and is input into the Linformer encoder together with the static features of each image in the gradient image set M to obtain dynamic features; the obtained dynamic features are used to identify the type of defects.
[0067] See also Figure 5 , the terminal device is a computer device. The computer device 60 of this embodiment includes: a processor 61, a memory 62, and a computer program 63 stored in the memory 62 and executable on the processor 61. When the computer program 63 is executed by the processor 61, the method for identifying the type of defects in the TOFD image of the spherical tank weld in the embodiment is implemented. To avoid repetition, it is not described one by one here. Alternatively, when the computer program 63 is executed by the processor 61, the functions of each model / unit in the TOFD image defect type identification system for the spherical tank weld in the embodiment are implemented. To avoid repetition, it is not described one by one here.
[0068] The computer device 60 may be a computing device such as a desktop computer, a notebook, a PDA, or a cloud server. The computer device 60 may include, but is not limited to, a processor 61 and a memory 62. Those skilled in the art will appreciate that Figure 5This is only an example of the computer device 60 and does not constitute a limitation of the computer device 60. It may include more or fewer components than shown in the figure, or a combination of certain components, or different components. For example, the computer device may also include input and output devices, network access devices, buses, etc.
[0069] The processor 61 may be a central processing unit (CPU), or other general-purpose processors, central processing units, graphics processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, data processing logic based on quantum computing, discrete hardware components, etc. The general-purpose processor may be a microprocessor or the processor may be any conventional processor, etc.
[0070] The memory 62 may be an internal storage unit of the computer device 60, such as a hard disk or memory of the computer device 60. The memory 62 may also be an external storage device of the computer device 60, such as a plug-in hard disk, a smart media card (SMC), a secure digital (SD) card, a flash card, etc., equipped on the computer device 60.
[0071] Furthermore, the memory 62 may include both an internal storage unit of the computer device 60 and an external storage device. The memory 62 is used to store computer programs and other programs and data required by the computer device. The memory 62 may also be used to temporarily store data that has been output or is to be output.
[0072] Any reference to a memory, database or other medium used in the embodiments provided in the present application may include at least one of a non-volatile and a volatile memory. Non-volatile memory may include a read-only memory (ROM), a magnetic tape, a floppy disk, a flash memory, an optical memory, a high-density embedded non-volatile memory, a resistive random access memory (ReRAM), a magnetic random access memory (MRAM), a ferroelectric random access memory (FRAM), a phase change memory (PCM), a graphene memory, etc. Volatile memory may include a random access memory (RAM) or an external cache memory, etc. As an illustration and not limitation, RAM may be in various forms, such as a static random access memory (SRAM) or a dynamic random access memory (DRAM), etc.
[0073] The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. The non-relational database may include a distributed database based on blockchain, etc., but is not limited thereto. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., but is not limited thereto.
[0074] See also Figure 6 The terminal device is an electronic device 600, and the electronic device is in the form of a general-purpose computing device. The components of the electronic device may include, but are not limited to: at least one processing unit 610, at least one storage unit 620, a bus 630 connecting different platform components (including the storage unit 620 and the processing unit 610), a display unit 640, etc.
[0075] The storage unit stores program codes, which can be executed by the processing unit 610, so that the processing unit 610 performs the steps according to various exemplary embodiments of the present invention described in the above method section of this specification. For example, the processing unit 610 can perform the following steps: Figure 1 Follow the steps shown in .
[0076] The storage unit 620 may include a readable medium in the form of a volatile storage unit, such as a random access memory unit (RAM) 6201 and / or a cache memory unit 6202 , and may further include a read-only memory unit (ROM) 6203 .
[0077] The storage unit 620 may also include a program / utility 6204 having a set (at least one) of program modules 6205, such program modules 6205 including but not limited to: an operating system, one or more application programs, other program modules, and program data, each of which or some combination may include an implementation of a network environment.
[0078] Bus 630 may represent one or more of several types of bus structures, including a memory unit bus or memory unit controller, a peripheral bus, an accelerated graphics port, a processing unit, or a local bus using any of a variety of bus architectures.
[0079] The electronic device 600 may also communicate with one or more external devices 700 (e.g., keyboards, pointing devices, Bluetooth devices, etc.), may also communicate with one or more devices that enable a user to interact with the electronic device 600, and / or communicate with any device that enables the electronic device 600 to communicate with one or more other computing devices (e.g., routers, modems, etc.). Such communication may be performed via an input / output (I / O) interface 650. Furthermore, the electronic device 600 may also communicate with one or more networks (e.g., a local area network (LAN), a wide area network (WAN), and / or a public network, such as the Internet) via a network adapter 660. The network adapter 660 may communicate with other modules of the electronic device 600 via a bus 630. It should be understood that, although not shown in the figure, other hardware and / or software modules may be used in conjunction with the electronic device 600, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage platforms, etc.
[0080] In order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, rather than all of the embodiments. The components of the embodiments of the present invention described and shown in the drawings here can usually be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of the present invention provided in the drawings is not intended to limit the scope of the claimed invention, but merely represents selected embodiments of the present invention. Based on the embodiments in the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention.
[0081] Assume that there is a TOFD image dataset D containing multiple defect types. The dataset D contains defect images of different types (such as cracks, pores, slag inclusions, etc.), as well as the corresponding defect location, size, direction and other information. Next, the simulation experiment is carried out through the following steps: Using the multi-image generation module based on gain adjustment, each defect image in the data set D is processed to generate a series of gradient image sets M; by adjusting the gain, images with different contrast and clarity are obtained, which helps to observe defects from different angles.
[0082] Using the static feature extraction module based on global + local feature fusion, each image in the generated image set M is processed to extract static features. This model will comprehensively consider the location information and morphological information of the defect to provide a more comprehensive feature representation for subsequent defect type identification.
[0083] The dynamic feature extraction module based on linear self-attention is used to process the features output by the static feature extraction model to capture the dynamic change information. This module will better understand the characteristics of defects and improve the reliability of defect identification.
[0084] Finally, the dynamic features are used to identify the defect types, and the identification results are compared with the actual defect types in the data set D to evaluate the performance of the method of the present invention in defect type identification.
[0085] The following conclusions are obtained through simulation experiments: The multi-image generation module helps to observe defects from different angles and improve the accuracy of defect identification.
[0086] The static feature extraction model can describe the defect characteristics more comprehensively and improve the recognition accuracy by fusing global and local features.
[0087] The dynamic feature extraction module can effectively capture the change information of defects, which helps to better understand the characteristics of defects and improve the reliability of defect identification.
[0088] Experiments were conducted using TOFD image data of large pressure spherical tank welds and compared with classic classification networks. The results showed that by incorporating dynamic features, the model's accuracy in identifying defect types can be effectively improved. Compared with the Mobilenet_v2 method, the classification accuracy increased by 2.5%.
[0089] In addition, the recognition rate of the method of the present invention for five types of defects, namely cracks, lack of fusion, incomplete penetration, pores and slag inclusions, is improved. The accuracy of cracks and lack of fusion defects is greatly improved, and the accuracy of slag inclusion defects can reach 100%. For the two types of defects, lack of fusion and cracks, which are difficult to distinguish, the method of the present invention shows better recognition ability and reduces the false recognition rate. In summary, the TOFD image defect type recognition method and system of the spherical tank weld of the present invention improves the accuracy and reliability of defect recognition, while making full use of the dynamic observation behavior and domain knowledge of experts, realizing the deep integration of deep learning technology and professional knowledge, and has important practical application value.
[0090] The technicians in the relevant field can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example for illustration. In practical applications, the above-mentioned function allocation can be completed by different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiment can be integrated in a processing unit, or each unit can exist physically separately, or two or more units can be integrated in one unit. The above-mentioned integrated unit can be implemented in the form of hardware or in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of this application. The specific working process of the units and modules in the above-mentioned system can refer to the corresponding process in the aforementioned method embodiment, which will not be repeated here.
[0091] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0092] Those skilled in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed in the present invention can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present invention.
[0093] In the embodiments provided by the present invention, it should be understood that the disclosed devices / terminals and methods can be implemented in other ways. For example, the device / terminal embodiments described above are only schematic. For example, the division of the modules or units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0094] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0095] In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0096] If the integrated module / unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the present invention implements all or part of the processes in the above-mentioned embodiment method, and can also be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a computer-readable storage medium, and the computer program can implement the steps of the above-mentioned various method embodiments when executed by the processor. Among them, the computer program includes computer program code, and the computer program code can be in source code form, object code form, executable file or some intermediate form. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, U disk, mobile hard disk, disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), electric carrier signal, telecommunication signal and software distribution medium, etc. It should be noted that the content contained in the computer-readable medium can be appropriately increased or decreased according to the requirements of legislation and patent practice in the jurisdiction. For example, in some jurisdictions, according to legislation and patent practice, computer-readable media do not include electric carrier signals and telecommunication signals.
[0097] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0098] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0099] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process in the computer or other programmable device. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0100] The above contents are only for explaining the technical idea of the present invention and cannot be used to limit the protection scope of the present invention. Any changes made on the basis of the technical solution in accordance with the technical idea proposed by the present invention shall fall within the protection scope of the claims of the present invention.
Claims
1. A method for identifying defect types of spherical tank weld TOFD images, characterized in that: The following steps are involved: Continuously preprocess a single image to generate an image set M consisting of several gradient images, and use the AI model to learn the gradient image set M; Extract features from each image in the gradient image set M to obtain static features; The defect category corresponding to each image set M is represented as a category vector, and is input into the Linformer encoder together with the static features of each image in the gradient image set M to obtain dynamic features; The obtained dynamic features are used to identify the defect type.
2. The method for identifying defect types of spherical tank weld TOFD images according to claim 1 is characterized in that: The single image is preprocessed continuously to generate an image set M consisting of several gradient images: Based on the TOFD gain adjustment technology, the range of the decibel gain 𝛽 of the gain adjustment is determined, and the structural similarity between the original image and the generated image is calculated using the SSIM index to ensure the similarity of the generated image obtained by adjusting the decibel gain 𝛽; Determine the number 𝑛 of original TOFD images to be generated, set different numbers of images to be generated n for experiments, determine the optimal value of the number of images generated n according to the experimental results, and use the range of decibel gain 𝛽 to select n decibel gain values 𝛽 at equal intervals within the range. Each selected 𝛽 value generates a TOFD image, forming a continuous image set M.
3. The method for identifying defect types of spherical tank weld TOFD images according to claim 2 is characterized in that: Processed TOFD image The pixel value corresponding to the pixel point for: in, is the decibel gain of amplification or reduction, Original image The pixel value of the pixel in .
4. The method for identifying defect types of spherical tank weld TOFD images according to claim 2 is characterized in that: The SSIM index is greater than 0.
6.
5. The method for identifying defect types of spherical tank weld TOFD images according to claim 1 is characterized in that: Perform feature extraction on each image in the gradient image set M to obtain static features: Resnet50 and ViT-B / 16 are selected to respectively Perform feature extraction to obtain local features and global features ; Use global average pooling Features and Process and obtain features and ; Use direct splicing Perform feature fusion to obtain the final static feature .
6. The method for identifying defect types of spherical tank weld TOFD images according to claim 5 is characterized in that: Static Features Specifically: in, is the first images, It is the Resnet50 feature extraction function operation. It is the ViT-B / 16 feature extraction function operation. is the first images static characteristics.
7. The method for identifying defect types of spherical tank weld TOFD images according to claim 1 is characterized in that: The defect category corresponding to each image set M is represented as a category vector, and together with the static features of each image in the gradient image set M, the dynamic features are input into the Linformer encoder as follows: The defect category corresponding to each image set M is represented as a category vector, and together with the static features of each image in the image set M obtained by the multi-image generation module Input into the Linformer encoder together; In the encoder, after layer regularization , Multi-head linear self-attention mechanism , residual connection and multilayer perceptron Operation, obtain dynamic features ; By inputting dynamic features into the classifier In this way, it learns the ability to map dynamic features to different defect types and uses dynamic features to complete defect type identification.
8. The method for identifying defect types of spherical tank weld TOFD images according to claim 7 is characterized in that: Dynamic Features The calculation is as follows: in, An intermediate feature.
9. The method for identifying defect types of spherical tank weld TOFD images according to claim 8 is characterized in that: Intermediate Features for: in, is the defect category vector and the static features of each image in the image set M Together they form the input feature vector.
10. A spherical tank weld TOFD image defect type recognition system, characterized in that: include: The preprocessing module continuously preprocesses a single image to generate an image set M consisting of several gradient images, and uses the AI model to learn the gradient image set M; The feature module extracts features from each image in the gradient image set M to obtain static features; The extraction module represents the defect category corresponding to each image set M as a category vector, and inputs it into the Linformer encoder together with the static features of each image in the gradient image set M to obtain dynamic features; The recognition module uses the obtained dynamic features to identify the defect type.
Citation Information
Cited By
Casting defect target detection method based on ray image adaptive key frame feature fusion
CN120894289A