Stone cultural relic disease detection method and device, storage medium and electronic equipment

The pre-trained disease detection model provides feature enhancement and normalization of the stone cultural relics images, and the U-net structure is used to identify the disease type, which solves the problem of low classification efficiency of traditional artificial markers and realizes efficient identification of stone cultural relics diseases and accurate classification.

CN119206681APending Publication Date: 2024-12-27NORTHWEST INST OF ECO ENVIRONMENT & RESOURCES CAS
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202410266108.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-03-08
Publication Date
2024-12-27

AI Technical Summary

Technical Problem

The traditional artificial marking classification method has low efficiency in identifying stone cultural relics diseases, and cannot effectively process large-scale cultural relics images, and requires a lot of manpower and material resources.

Method used

The pre-trained disease detection model is used to enhance and normalize the image to be detected by obtaining the stone cultural relics. The image is processed using the U-net structure model to identify and determine the type of disease.

Benefits of technology

It has achieved efficient identification of stone cultural relics diseases, improved work efficiency, and can accurately identify types such as crust diseases, agglomeration diseases, biological diseases and peeling diseases.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119206681A_ABST
    Figure CN119206681A_ABST
Patent Text Reader

Abstract

The invention provides a stone cultural relic disease detection method and device, a storage medium and electronic equipment. In the method, the electronic device obtains a to-be-detected image of the stone cultural relic; processing the to-be-detected image through a pre-trained disease detection model to obtain an identification result of the to-be-detected image; and determining the disease type of stone cultural relic infection according to the identification result. Therefore, the pre-trained disease detection model can be used for efficiently identifying the diseases of the stone cultural relics.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of image recognition, and more specifically, to a method, device, storage medium and electronic device for detecting defects in stone cultural relics. Background Art

[0002] There are many types of stone cultural relics in my country, which are widely distributed throughout the northern and southern borders. Among them, grottoes are typical representatives of stone cultural relics. They directly provide precious information on religious history, sculpture history, social history, etc. such as ancient Buddhism. They are non-renewable resources, and it is very urgent to carry out protection work. Due to the long history and changeable geological environment, the types of diseases involved in stone cultural relics are complex. The premise of carrying out protection work is to effectively identify and mark different types of diseases. Therefore, studying how to scientifically and efficiently extract disease information has practical value for carrying out relevant stone cultural relics protection work.

[0003] The extraction and drawing of stone cultural relics disease information needs to be based on the classification of disease information. The traditional manual marking and classification method is mainly based on the prior knowledge of cultural relics protection and computer drawing tools, but because it consumes a lot of manpower and material resources, and requires the staff to have rich experience in identification and marking, the work efficiency is low and it is not suitable for processing large quantities of cultural relics images. Summary of the invention

[0004] In order to overcome at least one of the deficiencies in the prior art, the present application provides a stone cultural relic disease detection method, device, storage medium and electronic device, specifically including:

[0005] In a first aspect, the present application provides a method for detecting stone cultural relics diseases, the method comprising:

[0006] Acquire the image of the stone cultural relic to be tested;

[0007] Processing the image to be detected by using a pre-trained disease detection model to obtain a recognition result of the image to be detected;

[0008] The type of disease that the stone cultural relic is infected with is determined based on the identification result.

[0009] In conjunction with the optional implementation manner of the first aspect, the disease detection model includes an encoder and a decoder;

[0010] The input image of each lower convolutional layer in the encoder has the same size as the output image;

[0011] The input image of each upper convolutional layer in the decoder has the same size as the output image.

[0012] In conjunction with the optional implementation manner of the first aspect, the step of obtaining the image of the stone cultural relic to be detected includes:

[0013] Acquiring an initial image of the stone cultural relic;

[0014] Performing feature enhancement processing on the initial image to obtain a preprocessed image;

[0015] The pre-processed image is normalized to obtain the image to be detected.

[0016] In combination with the optional implementation manner of the first aspect, the enhancement processing method includes at least one of color correction, hue correction, contrast correction and distortion correction.

[0017] In combination with the optional implementation manner of the first aspect, the pre-processed image is normalized to obtain the image to be detected, and the expression is:

[0018]

[0019] In the formula, x represents the original pixel value in the preprocessed image, x′ represents the normalized pixel value, min represents the minimum pixel value in the preprocessed image, and max represents the maximum pixel value in the preprocessed image.

[0020] In combination with the optional implementation manner of the first aspect, the disease detection model is obtained by training a model with a U-net structure.

[0021] In combination with the optional implementation manner of the first aspect, the disease type includes at least one of encrustation disease, accumulation disease, biological disease, peeling disease and normal.

[0022] In a second aspect, the present application provides a device for detecting stone cultural relics diseases, the device comprising:

[0023] An image acquisition module, used to acquire the image of the stone cultural relic to be detected;

[0024] An image recognition module is used to process the image to be detected by using a pre-trained disease detection model to obtain a recognition result of the image to be detected;

[0025] The disease judgment module is used to determine the type of disease infected by the stone cultural relic based on the identification result.

[0026] In conjunction with the optional implementation manner of the second aspect, the disease detection model includes an encoder and a decoder;

[0027] The input image of each lower convolutional layer in the encoder has the same size as the output image;

[0028] The input image of each upper convolutional layer in the decoder has the same size as the output image.

[0029] In conjunction with the optional implementation manner of the second aspect, the image acquisition module is further specifically used for:

[0030] Acquiring an initial image of the stone cultural relic;

[0031] Performing feature enhancement processing on the initial image to obtain a preprocessed image;

[0032] The pre-processed image is normalized to obtain the image to be detected.

[0033] In combination with the optional implementation manner of the second aspect, the enhancement processing method includes at least one of color correction, hue correction, contrast correction and distortion correction.

[0034] In combination with the optional implementation manner of the second aspect, the pre-processed image is normalized to obtain the image to be detected, and the expression is:

[0035]

[0036] In the formula, x represents the original pixel value in the preprocessed image, x′ represents the normalized pixel value, min represents the minimum pixel value in the preprocessed image, and max represents the maximum pixel value in the preprocessed image.

[0037] In combination with the optional implementation manner of the second aspect, the disease detection model is obtained by training a model with a U-net structure.

[0038] In combination with the optional implementation manner of the second aspect, the disease type includes at least one of encrustation disease, accumulation disease, biological disease, peeling disease and normal.

[0039] In a third aspect, the present application provides a storage medium storing a computer program, which, when executed by a processor, implements the stone cultural relic disease detection method.

[0040] In a fourth aspect, the present application provides an electronic device, comprising a processor and a memory, wherein the memory stores a computer program, and when the computer program is executed by the processor, the method for detecting stone cultural relics diseases is implemented.

[0041] Compared with the prior art, this application has the following beneficial effects:

[0042] The present application provides a method, device, storage medium and electronic device for detecting disease of stone cultural relics. In the method, the electronic device obtains an image of a stone cultural relic to be detected; processes the image to be detected by a pre-trained disease detection model to obtain a recognition result of the image to be detected; and determines the type of disease infected by the stone cultural relic based on the recognition result. In this way, the disease of the stone cultural relic can be efficiently identified by using the pre-trained disease detection model. BRIEF DESCRIPTION OF THE DRAWINGS

[0043] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the embodiments will be briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present application and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without paying creative work.

[0044] Figure 1 A flow chart of a method for detecting stone cultural relics diseases provided in an embodiment of the present application;

[0045] Figure 2 A schematic diagram of the structure of the model provided in the embodiment of the present application;

[0046] Figure 3 A schematic diagram of the structure of a stone cultural relic disease detection device provided in an embodiment of the present application;

[0047] Figure 4 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application.

[0048] Icon: 101 - image acquisition module; 102 - image recognition module; 103 - disease judgment module; 201 - memory; 202 - processor; 203 - communication unit; 204 - system bus. DETAILED DESCRIPTION

[0049] In order to make the purpose, technical solution and advantages of the embodiments of the present application clearer, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, rather than all the embodiments. The components of the embodiments of the present application described and shown in the drawings here can be arranged and designed in various different configurations.

[0050] Therefore, the following detailed description of the embodiments of the present application provided in the accompanying drawings is not intended to limit the scope of the present application for which protection is sought, but merely represents selected embodiments of the present application. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in the field without creative work are within the scope of protection of the present application.

[0051] It should be noted that similar reference numerals and letters denote similar items in the following drawings, and therefore, once an item is defined in one drawing, further definition and explanation thereof is not required in subsequent drawings.

[0052] In the description of the present application, it should be noted that the terms "first", "second", "third", etc. are only used to distinguish the description and cannot be understood as indicating or implying relative importance. In addition, the terms "comprise", "include" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "comprises a ..." does not exclude the presence of other identical elements in the process, method, article or device including the element.

[0053] Based on the above statement, as introduced in the background technology, the traditional manual marking and classification method is mainly based on prior knowledge of cultural relics protection and computer drawing tools. However, because it consumes a lot of manpower and material resources, and requires staff to have rich identification and marking experience, the work efficiency is low and it is not suitable for processing large quantities of cultural relics images.

[0054] Based on the discovery of the above technical problems, the inventors have proposed the following technical solutions to solve or improve the above problems through creative work. It should be noted that the defects in the solutions in the above prior art are the results obtained by the inventors after practice and careful research. Therefore, the discovery process of the above problems and the solutions proposed in the embodiments of the present application for the above problems below should all be the contributions made by the inventors to the present application in the process of invention and creation, and should not be understood as technical contents known to those skilled in the art.

[0055] In view of this, this embodiment provides a method for detecting disease of stone cultural relics. In this method, an electronic device obtains an image of a stone cultural relic to be detected; the image to be detected is processed by a pre-trained disease detection model to obtain a recognition result of the image to be detected; and the type of disease infected by the stone cultural relic is determined according to the recognition result. In this way, the disease of the stone cultural relic can be efficiently identified by using the pre-trained disease detection model.

[0056] In this embodiment, the disease detection model can detect disease types including crusting disease, accumulation disease, biological disease, peeling disease, etc. Among them, crusting disease refers to the long-term effect of atmospheric pollutants, which causes a layer of hard crust to form on the surface of stone cultural relics. Crusting disease will make the color of stone cultural relics darker and the texture rougher. In severe cases, it will also affect the structural stability of stone cultural relics. Accumulation disease refers to the attachment of dust, soil, microorganisms and other impurities on the surface of stone cultural relics, which will make the texture and pattern on the surface of stone cultural relics blurred, affecting the ornamental value of cultural relics. Biological disease refers to the growth and reproduction of microorganisms, plants, animals and other organisms on the surface of stone cultural relics, causing stone cultural relics to be damaged. Biological diseases have various manifestations, such as black mold spots of microorganisms, erosion of plant roots, corrosion of acidic substances produced by animal feces and corpse decomposition, etc. Peeling disease refers to the shedding of the stone layer or pigment layer on the surface of stone cultural relics. Spalling disease may be caused by physical reasons (such as temperature changes, vibrations, etc.) or chemical reasons (such as acid rain, salt crystallization, etc.). Spalling disease will make the patterns and texts on the surface of stone cultural relics incomplete, affecting the preservation and display of cultural relics.

[0057] In addition, the electronic device implementing the method may be, but is not limited to, a mobile terminal, a tablet computer, a laptop computer, a desktop computer, and a server, etc. When it is a server, the server may be a single server or a server group. The server group may be centralized or distributed (for example, the server may be a distributed system). In some embodiments, the server may be local or remote relative to the user terminal. In some embodiments, the server may be implemented on a cloud platform; as an example only, the cloud platform may include a private cloud, a public cloud, a hybrid cloud, a community cloud (Community Cloud), a distributed cloud, an inter-cloud (Inter-Cloud), a multi-cloud (Multi-Cloud), etc., or any combination thereof. In some embodiments, the server may be implemented on an electronic device having one or more components.

[0058] To make the solution provided by this embodiment clearer, it is assumed that the electronic device is a server, and combined with Figure 1 Each step of the method is described in detail. However, it should be understood that the operations of the flowchart may not be implemented in order, and steps without logical contextual relationships may be reversed in order or implemented simultaneously. In addition, those skilled in the art may add one or more other operations to the flowchart, or remove one or more operations from the flowchart under the guidance of the content of this application. Figure 1 As shown, the method includes:

[0059] S101, obtaining an image of a stone cultural relic to be detected.

[0060] In this embodiment, in order to enable the disease detection model to more accurately identify the diseases infected by the stone cultural relics, the image to be detected is obtained by preprocessing and normalizing the initial image of the stone cultural relics. Therefore, the optional implementation of step S101 includes:

[0061] S101-1, obtaining an initial image of a stone cultural relic.

[0062] S101-2, performing feature enhancement processing on the initial image to obtain a preprocessed image.

[0063] It should be understood that the initial image of the above-mentioned stone cultural relics refers to the unprocessed original image directly captured by the camera. In some embodiments, the initial image can be directly used as the image to be detected. However, it is found in practice that when the close-up image of the stone cultural relics is collected by the camera, it is easily affected by factors such as terrain, lighting, shooting angle, etc., resulting in the initial image having problems such as distortion, deformation, tilt, overexposure or underexposure. Therefore, before processing and analyzing the image, it is necessary to perform feature enhancement processing on it. The method of feature enhancement processing includes: at least one of curve adjustment (color correction, hue correction and contrast correction) and distortion correction.

[0064] Regarding distortion correction, it should be understood that when using a camera to capture images of stone cultural relics, the camera will produce lens distortion due to slight changes in the lens, shooting distance, focal length, etc., causing the image of the cultural relic to deform to a certain extent. Therefore, in order to avoid the distortion effect of the camera interfering with the recognition effect of the disease detection model, it is necessary to correct the deformation. As an optional implementation, the correction method can adopt the checkerboard method, that is, using the open source computer vision library OpenCV, based on the algorithm to analyze multiple checkerboard images pre-collected by the camera (15 images were collected in this embodiment), calculate the internal parameter matrix and distortion coefficient of the camera, and use these two parameters to construct an algorithm to correct the initial image of the stone cultural relic.

[0065] In practice, it was also found that some initial images had low contrast and uneven hue, which resulted in the lack of prominent disease feature information, which in turn reduced the recognition accuracy of the disease detection model. Therefore, at least one of the color, hue, and contrast of the initial image can be adjusted to enhance the disease feature information. For example, the hue and contrast of the initial image can be increased to enhance the disease feature information, making it easier to detect.

[0066] Based on the preprocessed image obtained in the above embodiment, step S101 further includes:

[0067] S101 - 3 , normalize the preprocessed image to obtain an image to be detected.

[0068] Among them, the preprocessed image is normalized to obtain the image to be detected, and the expression is:

[0069]

[0070] Where x represents the original pixel value in the preprocessed image, x′ represents the normalized pixel value, min represents the minimum pixel value in the preprocessed image, and max represents the maximum pixel value in the preprocessed image.

[0071] Based on the image to be detected obtained in the above embodiment, the stone cultural relic disease detection method provided in this embodiment also includes:

[0072] S102, processing the image to be detected by using a pre-trained disease detection model to obtain a recognition result of the image to be detected.

[0073] In this embodiment, the disease detection model is obtained by training a U-net structure model. The parameters of each network layer of the U-net model provided in this embodiment are as follows: Figure 2 As shown, the segmentation accuracy is improved by combining the encoder and the decoder. Cov,64,3×3 in the figure indicates that the network layer is a convolution layer. The feature map output by the convolution layer has 64 channels, and the size of each convolution kernel is 3×3. The parameters of other convolution layers are similar, and will not be repeated in this embodiment.

[0074] In the encoder, features are extracted through a series of convolutional layers (usually accompanied by ReLU activation functions and batch normalization) and maximum pooling layers, while gradually reducing the spatial dimensions (width and height) of the data and increasing the depth (number of channels). In the decoder, the spatial dimensions of the feature map are increased by upsampling operations, and low-level features (such as edges and textures) are combined with high-level features (such as shape and structure) by concatenating feature maps from corresponding symmetrical positions of the encoder. This combination is a key feature of U-net, which enables the model to recover details without losing spatial information.

[0075] The U-Net model usually obtains a model output image size after multi-layer convolution operations that does not match the original size. For example, during the down-convolution operation, the size of the output image after convolution is smaller than the original size of the input image, and during the up-convolution operation, the size of the output image after convolution is larger than the original size of the input image. In practice, it was found that it is difficult to achieve the desired recognition accuracy when using a disease detection model trained based on a conventional U-Net model to detect diseases of stone cultural relics. After research, it was found that the mismatch between the model output image size and the original size will make it inconvenient to accurately calculate the image pixels by position, which will in turn affect the accuracy of disease detection. In view of this, the disease detection model provided in this embodiment includes an encoder and a decoder; the input image and output image of each down-convolution layer in the encoder have the same size; and the input image and output image of each up-convolution layer in the decoder have the same size.

[0076] It should be understood that the recognition result output by the disease detection model is an integer matrix, in which the values ​​represent the labels corresponding to the disease type of each pixel. For example, in a binary classification problem, two labels, 0 and 1, are usually used to represent the background and foreground.

[0077] Based on the recognition results obtained in the above embodiment, continue to refer to Figure 1 The stone cultural relic disease detection method provided in this embodiment also includes:

[0078] S103, determining the disease type of the stone cultural relic infected according to the identification result.

[0079] In this embodiment, the disease type includes at least one of encrustation disease, deposition disease, biological disease, flaking disease and normal. In summary, the pre-trained disease recognition model can greatly improve the efficiency of disease detection on stone cultural relics.

[0080] In addition, since the disease detection model provided in this embodiment is obtained by training a model with a U-net structure, this embodiment also provides a corresponding model training method, which is described in detail below.

[0081] First, for the sample images collected in advance of stone cultural relics, the sample images were interpreted one by one, and the images that did not meet the further processing conditions were eliminated, including images with severe tilt of the target, partial lens blocking, severe overexposure or severe underexposure, etc. In addition, the color, tone and contrast of individual images were adjusted to address the problem of low contrast and uneven tone, which resulted in the lack of prominent feature information.

[0082] Furthermore, the processed sample images are manually interpreted one by one to analyze the types of diseases they display, and the sample images are annotated using image marking software. Different types are assigned different values, and the marking results are saved as marked images with the same format and size as the original images. The marked sample images and unmarked sample images are sorted and saved accordingly to form an original image set and a marked image set.

[0083] Furthermore, regular grids are used to divide sub-images in the original image set and the labeled image set to form an image set and a sample set, respectively. At the same time, data enhancement is performed on the image set and the sample set to increase the amount of training data. The training data set, validation data set and test data set are determined by random selection, and the image pixel values ​​are normalized to the [0,1] interval using a normalization method.

[0084] In this regard, it should be understood that the resolution of the images in the original image set and the labeled image set is 72dpi, and the width and height are 4032 pixels and 3024 pixels respectively. Directly inputting the images in the original image set and their labels into the U-net model calculation will cause memory overflow. Therefore, an image with a size of 512×512 pixels is used as the input of the model. This leads to the need to crop the images in the original image set and the labeled image set into a series of sub-images with a size of 512×512. The cropping method generally includes three methods: regular grid method, sliding window method and random selection method. Considering that the selection of training samples should cover all sample data as much as possible, the regular grid method is selected for cropping in this embodiment. During cropping, a 10% overlapping area is set on each of the four sides of the grid to increase the sample coverage overlap, and the original image set and the labeled image set are cropped at the same position and size, respectively, and the corresponding arrangement and preservation are formed to form a new original image set and labeled image set.

[0085] It should also be understood that data enhancement refers to performing some transformation operation on the training sample data to generate new data, so as to achieve the purpose of sufficient sample data volume. Data enhancement methods include translation, inversion, rotation, cropping, deformation, mirroring, scaling, noise, blurring, color conversion, erasing, filling, etc. In view of the morphological characteristics of stone cultural relics, this embodiment adopts the data enhancement methods of inversion, diagonal mirroring and translation to obtain the amplified original image set and the labeled image set.

[0086] In addition, this implementation also selects 20% of the data from the amplified original image set as the verification data set and the test data set by sampling without replacement, and the remaining 60% of the data is used as the training data set, so that the ratio of the three data sets reaches 6:2:2. In addition, the training data set is normalized to obtain a normalized training data set.

[0087] The U-Ne structure model is trained based on the normalized training data set. Before training, the model parameters need to be initialized. In this embodiment, the initial weight value of the convolution operation in the model is determined by he-normal. This method starts with a center of 0 and a standard deviation of The samples are drawn from a truncated normal distribution of , where n is the number of input units in the weight tensor.

[0088] After initialization, the study found that the parameter optimization algorithm in the U-Net model is usually the stochastic gradient descent method SGD, which is simple to calculate and does not require too many parameters to be adjusted, but is easily affected by the local minimum and converges to the local optimum. Therefore, in this embodiment, the parameter optimization algorithm used is Adam, which is an improvement on SGD. It adds updated momentum and adaptive learning rate, which can help the model converge faster, and can also automatically adjust the learning rate without too many parameter adjustments. Specifically, this embodiment constructs a loss function based on the predicted value calculated by the model and the true value of the corresponding labeled data, updates the parameters through the optimization algorithm, and adds the regularization method Dropout for possible overfitting, and determines that its discard probability is 0.5, so as to complete the back propagation to update the parameters of the model. Iterate the above training process until the preset conditions are met to obtain the disease detection model of this embodiment.

[0089] Based on the same inventive concept as the stone cultural relic disease detection method provided in this embodiment, this embodiment also provides a stone cultural relic disease detection device, which includes at least one software function module that can be stored in a memory or fixed in an electronic device in the form of software. The processor in the electronic device is used to execute the executable module stored in the memory. For example, the software function module and computer program included in the stone cultural relic disease detection device. Please refer to Figure 3 , from the functional point of view, the stone cultural relic disease detection device can include:

[0090] An image acquisition module 101 is used to acquire an image of a stone cultural relic to be detected;

[0091] The image recognition module 102 is used to process the image to be detected by using a pre-trained disease detection model to obtain a recognition result of the image to be detected;

[0092] The disease determination module 103 is used to determine the type of disease infected by the stone cultural relic based on the identification result.

[0093] In this embodiment, the image acquisition module 101 is used to implement Figure 1 In step S101, the image recognition module 102 is used to implement Figure 1 In step S102, the disease judgment module 103 is used to implement Figure 1Therefore, for the detailed description of each of the above steps, please refer to the specific implementation of the corresponding step, and this embodiment will not be repeated.

[0094] In addition, the functional modules in the various embodiments of the present application may be integrated together to form an independent part, or each module may exist separately, or two or more modules may be integrated to form an independent part.

[0095] It should also be understood that if the above implementation is implemented in the form of a software function module and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art, or the part of the technical solution, can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present application.

[0096] Therefore, this embodiment further provides a storage medium, which is a computer-readable storage medium. The storage medium stores a computer program, and when the computer program is executed by a processor, the stone cultural relic disease detection method provided in this embodiment is implemented. Among them, the storage medium can be a U disk, a mobile hard disk, a read-only memory (ROM, Read-Only Memory), a random access memory (RAM, Random Access Memory), a disk or an optical disk, etc., which can store program codes.

[0097] This embodiment provides an electronic device. Figure 4 As shown, the electronic device includes a processor 202 and a memory 201. In addition, the memory 201 stores a computer program, and the processor implements the stone cultural relic disease detection method provided in this embodiment by reading and executing the computer program corresponding to the above implementation in the memory 201.

[0098] Continue to see Figure 4 The electronic device further includes a communication unit 203. The memory 201, the processor 202 and the communication unit 203 are directly or indirectly electrically connected to each other through a system bus 204 to achieve data transmission or interaction.

[0099] The memory 201 may be an information recording device based on any electronic, magnetic, optical or other physical principle, used to record execution instructions, data, etc. In some implementations, the memory 201 may be, but is not limited to, a volatile memory, a non-volatile memory, a storage drive, etc.

[0100] In some embodiments, the volatile memory may be a random access memory (RAM); in some embodiments, the non-volatile memory may be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable read-only memory (EEPROM), a flash memory, etc.; in some embodiments, the storage drive may be a disk drive, a solid-state drive, any type of storage disk (such as a CD, a DVD, etc.), or a similar storage medium, or a combination thereof, etc.

[0101] The communication unit 203 is used to send and receive data through a network. In some embodiments, the network may include a wired network, a wireless network, a fiber optic network, a telecommunication network, an intranet, the Internet, a local area network (LAN), a wide area network (WAN), a wireless local area network (WLAN), a metropolitan area network (MAN), a wide area network (WAN), a public switched telephone network (PSTN), a Bluetooth network, a ZigBee network, or a near field communication (NFC) network, or any combination thereof. In some embodiments, the network may include one or more network access points. For example, the network may include a wired or wireless network access point, such as a base station and / or a network switching node, through which one or more components of the service request processing system may be connected to the network to exchange data and / or information.

[0102] The processor 202 may be an integrated circuit chip having a signal processing capability, and the processor may include one or more processing cores (e.g., a single-core processor or a multi-core processor). By way of example only, the processor may include a central processing unit (CPU), an application-specific integrated circuit (ASIC), an application-specific instruction set processor (ASIP), a graphics processing unit (GPU), a physical processing unit (PPU), a digital signal processor (DSP), a field programmable gate array (FPGA), a programmable logic device (PLD), a controller, a microcontroller unit, a reduced instruction set computer (RISC), or a microprocessor, or any combination thereof.

[0103] Understandably, Figure 4 The structure shown is for illustration only. The electronic device may also have Figure 4 More or fewer components than shown, or with Figure 4 Different configurations shown. Figure 4 The components shown may be implemented in hardware, software or a combination thereof.

[0104] It should be understood that the apparatus and method disclosed in the above-mentioned embodiments can also be implemented in other ways. The apparatus embodiments described above are merely schematic. For example, the flowcharts and block diagrams in the accompanying drawings show the possible architecture, functions and operations of the apparatus, methods and computer program products according to the multiple embodiments of the present application. In this regard, each box in the flowchart or block diagram can represent a module, a program segment or a part of a code, and the module, a program segment or a part of a code contains one or more executable instructions for implementing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two consecutive boxes can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram and / or the flowchart, and the combination of boxes in the block diagram and / or the flowchart can be implemented with a dedicated hardware-based system that performs a specified function or action, or can be implemented with a combination of dedicated hardware and computer instructions.

[0105] The above are only various implementations of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.

Claims

1. A method for detecting stone cultural relics diseases, characterized in that: The method comprises: Acquire the image of the stone cultural relic to be tested; Processing the image to be detected by using a pre-trained disease detection model to obtain a recognition result of the image to be detected; The type of disease that the stone cultural relic is infected with is determined based on the identification result.

2. The method for detecting stone cultural relics diseases according to claim 1, characterized in that: The disease detection model includes an encoder and a decoder; The input image of each lower convolutional layer in the encoder has the same size as the output image; The input image of each upper convolutional layer in the decoder has the same size as the output image.

3. The method for detecting stone cultural relics diseases according to claim 1, characterized in that: The step of obtaining the image of the stone cultural relic to be detected comprises: Acquiring an initial image of the stone cultural relic; Performing feature enhancement processing on the initial image to obtain a preprocessed image; The pre-processed image is normalized to obtain the image to be detected.

4. The method for detecting stone cultural relics diseases according to claim 3, characterized in that: The enhancement processing method includes at least one of color correction, tone correction, contrast correction and distortion correction.

5. The method for detecting stone cultural relics diseases according to claim 3, characterized in that: The pre-processed image is normalized to obtain the image to be detected, and the expression is: In the formula, x represents the original pixel value in the preprocessed image, x′ represents the normalized pixel value, min represents the minimum pixel value in the preprocessed image, and max represents the maximum pixel value in the preprocessed image.

6. The method for detecting stone cultural relics defects according to claim 1, characterized in that: The disease detection model is obtained by training a model with a U-net structure.

7. The method for detecting stone cultural relics diseases according to claim 1, characterized in that: The disease type includes at least one of encrustation disease, accumulation disease, biological disease, peeling disease and normal.

8. A device for detecting stone cultural relics diseases, characterized in that: The device comprises: An image acquisition module, used to acquire the image of the stone cultural relic to be detected; An image recognition module is used to process the image to be detected by using a pre-trained disease detection model to obtain a recognition result of the image to be detected; The disease judgment module is used to determine the type of disease infected by the stone cultural relic based on the identification result.

9. A storage medium, characterized in that: The storage medium stores a computer program, and when the computer program is executed by the processor, the stone cultural relic disease detection method described in any one of claims 1-7 is implemented.

10. An electronic device, characterized in that: The electronic device includes a processor and a memory, the memory stores a computer program, and when the computer program is executed by the processor, the stone cultural relic disease detection method according to any one of claims 1 to 7 is implemented.

Citation Information

Patent Citations

  • Crop disease recognition method and device, electronic equipment and storage medium

    CN113902735A

  • Calligraphy and painting cultural relic disease identification method based on target detection technology

    CN115049915A