Copper-based solid waste material identification method and device, computer equipment and storage medium
Through the automated identification method of the object detection model, the identification of copper-based solid waste materials is solved by using hollow convolution and mixed attention mechanisms, and the problem of high misjudgment rate of manual identification in the existing technology is solved, and the efficiency and automation level of copper smelting production lines are improved. .
Patent Information
- Application Number
- CN202411401456.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-09
- Publication Date
- 2025-01-03
AI Technical Summary
The identification of existing copper-based solid waste materials mainly relies on manual operations, resulting in high misjudgment rate and low efficiency, which cannot meet the needs of modern smelting processes.
An automated recognition method based on the object detection model is adopted, and the training data set is generated by obtaining real-time images, and the model is trained using hollow convolution and mixed attention mechanisms to realize automatic identification and classification of copper-based solid waste materials, and determine whether crushing is needed.
The operating efficiency and automation level of the copper smelting production line are improved, the misjudgment rate is reduced, the stability and consistency of the identification results are ensured, and manual intervention is reduced.
Smart Images

Figure CN119251578A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of identification and detection, and in particular to a method, device, computer equipment and storage medium for identifying copper-based solid waste materials. Background Art
[0002] The smelting of copper-based solid waste is an emerging industry. The existing identification of copper-based solid waste materials mainly relies on manual operation, without the use of machine intelligent recognition technology and corresponding intelligent recognition methods. This leads to a high misjudgment rate because the accuracy of manual recognition is not high and is easily affected by subjective factors and the environment. Summary of the invention
[0003] In view of this, the purpose of the present invention is to overcome the deficiencies in the prior art and provide a method, device, computer equipment and storage medium for identifying copper-based solid waste materials, which are used to realize automatic identification of copper-based solid waste materials according to target detection, thereby improving the operating efficiency of the copper smelting production line.
[0004] The present invention provides the following technical solutions:
[0005] In a first aspect, the present invention provides a method for identifying copper-based solid waste materials, the method comprising:
[0006] Acquire a real-time image of copper-based solid waste material, and generate a training data set according to the real-time image;
[0007] The target detection model is trained by using the training data set to obtain a copper-based solid waste material recognition and detection model;
[0008] The copper-based solid waste material recognition and detection model is used to recognize the copper-based solid waste material image to be recognized, and a material recognition result is obtained.
[0009] In one embodiment, generating a training data set according to the real-time image includes:
[0010] Preprocessing the plurality of real-time images;
[0011] Annotating various copper-based solid waste materials in each pre-processed real-time image to obtain a plurality of annotated images;
[0012] Each of the labeled images is used as the training data set.
[0013] In one embodiment, the target detection model includes a dilated convolution and a hybrid attention mechanism, and the target detection model is trained by the training data set to obtain a copper-based solid waste material recognition detection model, including:
[0014] Performing feature extraction on the training data set through the dilated convolution to obtain target features;
[0015] Performing feature enhancement on the target feature through the hybrid attention mechanism;
[0016] Performing feature learning on the enhanced target features through the dilated convolution to obtain a prediction result;
[0017] Calculate a target loss value according to the training data set and the prediction result;
[0018] The model parameters of the target detection model are updated according to the target loss value to obtain the copper-based solid waste material identification and detection model.
[0019] In one embodiment, the hybrid attention mechanism includes the following formula: HybridAttention(Q, K, V)=λ×LocalAttention(Q, K, V)+(1-λ)×GlobalAttention(Q, K, V), where λ is a preset hyperparameter, HybridAttention(Q, K, V) is a feature vector of the hybrid attention mechanism, LocalAttention(Q, K, V) is a feature vector of the local attention mechanism, and GlobalAttention(Q, K, V) is a feature vector of the global attention mechanism.
[0020] In one embodiment, the calculating the target loss value according to the training data set and the prediction result includes:
[0021] Calculate an angle loss value based on the angle information between the training data set and the prediction result;
[0022] determining an attenuation factor according to the angle loss value;
[0023] Calculating a distance loss value according to the center point information of the training data set and the prediction result, and the attenuation factor;
[0024] Calculating a shape loss value according to the shape information of the training data set and the prediction result;
[0025] Calculating an intersection-over-union ratio based on the area information of the training data set and the prediction result;
[0026] The target loss value is calculated according to the angle loss value, the shape loss value, the distance loss value and the intersection-over-union ratio.
[0027] In one embodiment, the method of identifying the copper-based solid waste material image to be identified by the copper-based solid waste material identification detection model and obtaining the material identification result includes:
[0028] Determining whether the current copper-based solid waste material corresponding to the copper-based solid waste material image to be identified needs to be crushed according to the material identification result;
[0029] If not, the current copper-based solid waste material is sorted and stored according to the material identification result;
[0030] If so, the current copper-based solid waste material is sent to a crushing device for crushing according to the material identification result, and the copper-based solid waste material after the crushing is sorted and stored.
[0031] In one embodiment, judging whether the current copper-based solid waste material corresponding to the copper-based solid waste material image to be identified needs to be crushed according to the material identification result includes:
[0032] Classifying the copper-based solid waste materials in the material identification results to obtain classification results; the classification results include a category that needs to be crushed and / or a category that does not need to be crushed;
[0033] Determine whether the classification result contains the category that needs to be crushed;
[0034] If yes, the current copper-based solid waste material needs to be crushed;
[0035] If not, the current copper-based solid waste material does not need to be crushed.
[0036] In a second aspect, the present invention provides a copper-based solid waste material identification device, the device comprising:
[0037] An acquisition module, used to acquire a real-time image of the copper-based solid waste material and generate a training data set according to the real-time image;
[0038] A training module, used to train the target detection model through the training data set to obtain a copper-based solid waste material recognition and detection model;
[0039] The recognition module is used to recognize the copper-based solid waste material image to be recognized through the copper-based solid waste material recognition and detection model to obtain a material recognition result.
[0040] The third invention is a computer device comprising a memory and a processor, wherein the memory stores a computer program, and when the computer program is executed by the processor, the copper-based solid waste material identification method as described in the first aspect is implemented.
[0041] In a fourth aspect, the present invention provides a computer-readable storage medium storing a computer program, wherein the computer program, when executed by a processor, implements the copper-based solid waste material identification method as described in the first aspect.
[0042] The copper-based solid waste material identification method, device, computer equipment and storage medium disclosed in the present invention obtain real-time images of copper-based solid waste materials, generate training data sets according to the real-time images; train the target detection model through the training data sets to obtain the copper-based solid waste material identification detection model; identify the copper-based solid waste material image to be identified through the copper-based solid waste material identification detection model to obtain the material identification result. In this way, by constructing an efficient copper-based solid waste material identification model, the automation of the entire copper-based solid waste material identification process is realized from image acquisition to material identification. By utilizing the real-time processing capability of the target detection algorithm, it is possible to quickly respond to and process large quantities of copper-based solid waste materials on the production line, significantly improving the efficiency and automation level of the production line. BRIEF DESCRIPTION OF THE DRAWINGS
[0043] In order to more clearly illustrate the technical solution of the present invention, the following is a brief introduction to the drawings required for use in the embodiments. It should be understood that the following drawings only illustrate certain embodiments of the present invention and should not be regarded as limiting the scope of protection of the present invention. In each of the drawings, similar components are numbered similarly.
[0044] Figure 1 A schematic diagram of a process of the copper-based solid waste material identification method proposed in this embodiment is shown;
[0045] Figure 2 Another schematic diagram of the process of the copper-based solid waste material identification method proposed in this embodiment is shown;
[0046] Figure 3 Another schematic diagram of the process of the copper-based solid waste material identification method proposed in this embodiment is shown;
[0047] Figure 4 A schematic diagram showing the real annotation box and the predicted annotation box proposed in this embodiment is shown;
[0048] Figure 5 A schematic structural diagram of the copper-based solid waste material identification device proposed in this embodiment is shown.
[0049] Description of the accompanying drawings:
[0050] 500 - copper-based solid waste material identification device; 501 - acquisition module; 502 - training module; 503 - identification module. DETAILED DESCRIPTION
[0051] The technical solutions in the embodiments of the present invention will be described clearly and completely below in conjunction with the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all the embodiments.
[0052] The components of the embodiments of the present invention generally described and shown in the drawings herein may be arranged and designed in a variety of 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 of the present invention, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present invention.
[0053] Hereinafter, the terms "including", "having" and their cognates, which may be used in various embodiments of the present invention, are intended only to indicate specific features, numbers, steps, operations, elements, components or combinations of the foregoing items, and should not be understood as first excluding the existence of one or more other features, numbers, steps, operations, elements, components or combinations of the foregoing items or adding the possibility of one or more features, numbers, steps, operations, elements, components or combinations of the foregoing items.
[0054] Furthermore, the terms “first”, “second”, “third”, etc. are merely used for distinguishing descriptions and are not to be understood as indicating or implying relative importance.
[0055] Unless otherwise defined, all terms (including technical terms and scientific terms) used herein have the same meanings as those generally understood by those skilled in the art to which the various embodiments of the present invention belong. The terms (such as those defined in generally used dictionaries) will be interpreted as having the same meanings as the contextual meanings in the relevant technical field and will not be interpreted as having idealized meanings or overly formal meanings unless clearly defined in the various embodiments of the present invention.
[0056] Example 1
[0057] In recent years, the amount of copper-containing waste generated during the mining, smelting, processing and use of copper has increased, mainly including waste circuit boards, black copper mud, resin powder, rare and precious metals, waste slag after gold extraction, soot, etc. The problem of tight supply chain has also increased the demand for recycling copper-based solid waste such as waste circuit boards. In order to solve the problems of solid waste emissions and resource shortages, it is necessary to scientifically treat and recycle multi-source copper-based solid waste.
[0058] At present, the identification and classification of copper-based solid waste materials in the copper smelting industry mainly rely on manual inspection, which has problems such as low recognition rate, high misjudgment rate and low efficiency, and it is difficult to meet the needs of modern smelting processes. Multi-source recognition technology based on the YOLO algorithm has gradually become a research hotspot. However, the traditional YOLO algorithm faces challenges in the complex process of copper-based solid waste material identification, classification, warehousing and batching. By optimizing the network structure and loss function to improve the YOLO algorithm and applying it to the management of copper-based solid waste materials, the accuracy and robustness of recognition and detection can be improved.
[0059] The disclosed embodiment provides a copper-based solid waste material identification method, which is used to identify copper-based solid waste materials through target recognition detection, thereby improving operation efficiency.
[0060] See also Figure 1 The copper-based solid waste material identification method includes steps S101 to S103, and each step is described in detail below.
[0061] Step S101, obtaining a real-time image of copper-based solid waste materials, and generating a training data set according to the real-time image.
[0062] In this embodiment, when copper-based solid waste materials enter the site, professional tools are used to collect real-time images of them. After a sufficient number of diversified real-time images of copper-based solid waste materials are collected, a training data set for training the target detection model is generated based on the multiple real-time images. The professional tools can be devices such as cameras, scanners, or drones, and the training data set is an image set with the copper-based solid waste material type labeled.
[0063] It should be noted that before generating the training data set, the real-time image needs to be processed, such as adjusting the size of the real-time image, denoising, enhancing the contrast, etc., so as to improve the image quality of the real-time image and facilitate subsequent processing.
[0064] Step S102, training the target detection model using the training data set to obtain a copper-based solid waste material recognition and detection model.
[0065] In this embodiment, the selected object detection model is trained using the training data set. During the training process, the object detection model learns how to extract features from the input training data set images and predict the location and type of the material based on the learned annotation data.
[0066] Furthermore, the performance of the target detection model can be optimized and overfitting can be reduced by adjusting model parameters (such as learning rate, batch size, number of iterations, etc.) and using regularization, data augmentation and other techniques.
[0067] Furthermore, the validation set is used to regularly evaluate the model during the training process to ensure its generalization ability. The training strategy is adjusted according to the evaluation results until satisfactory performance indicators are achieved, and a mature copper-based solid waste material recognition and detection model has been obtained.
[0068] Step S103, identifying the copper-based solid waste material image to be identified by using the copper-based solid waste material identification and detection model to obtain a material identification result.
[0069] In this embodiment, the image of the copper-based solid waste material to be identified is input into the trained copper-based solid waste material identification and detection model. The model processes the input image, automatically detects and identifies the copper-based solid waste material in the image, including its location and type. The material identification results are displayed on the image in a visual form (such as a bounding box, a label), and the material identification result data can also be exported as a file or sent to other systems for processing. In this way, the processing speed is improved through the automatic recognition of target detection, and large quantities of copper-based solid waste materials on the production line can be detected in real time, which is highly efficient; and the algorithm recognition will not be affected by human factors such as fatigue, ensuring the stability and consistency of the material identification results. Among them, the image of the copper-based solid waste material to be identified is also obtained by the above-mentioned professional equipment.
[0070] In a specific embodiment, step S101 includes: preprocessing a plurality of the real-time images; labeling various copper-based solid waste materials in each preprocessed real-time image to obtain a plurality of labeled images; and using each of the labeled images as the training data set.
[0071] In this embodiment, preprocessing is a necessary step before image analysis, which aims to improve the image quality and make it more suitable for subsequent image processing and feature extraction. Preprocessing of copper-based solid waste images may include the following aspects: using filtering techniques (such as Gaussian filtering, median filtering, etc.) to remove random noise in the image and improve the clarity of the image; adjusting the contrast of the image to make the difference between the target material and the background more obvious, which is helpful for subsequent identification and classification; using edge detection algorithms (such as Canny operator, Sobel operator, etc.) to extract the edge information of the material in the image, which is very useful for identifying the shape and contour of the material; adjusting all images to a uniform size to facilitate a unified processing flow in subsequent processing; converting the image from the RGB color space to a space more suitable for a specific task (such as a grayscale image, HSV color space, etc.) as needed.
[0072] Furthermore, annotation refers to the process of manually or automatically labeling the target objects (in this case, copper-based solid waste materials) in the pre-processed images. The purpose of annotation is to provide accurate training samples for the machine learning model so that the model can learn and identify the target materials in the image.
[0073] Furthermore, the annotated real-time images are organized into a training data set, including the image file itself and the corresponding annotation information (such as bounding box coordinates, category labels, etc.), which is used to realize the automatic recognition and classification of copper-based solid waste materials.
[0074] See also Figure 2In a specific embodiment, the target detection model includes a dilated convolution and a hybrid attention mechanism, and step 102 includes steps S1021 to S1025. Each step is described in detail below.
[0075] Step S1021, performing feature extraction on the training data set through the dilated convolution to obtain target features.
[0076] In this embodiment, the training data set is input into the model, and feature extraction is performed through the dilated convolution layer to obtain preliminary target features. These features contain useful information in the image for identifying copper-based solid waste materials. The dilated convolution is used to replace the standard Neck convolution to enhance the feature extraction ability of the network and better adapt to targets of different shapes and sizes.
[0077] Step S1022: Enhance the target feature through the hybrid attention mechanism.
[0078] It should be noted that in the copper-based solid waste material recognition and detection model, the sliding window transformer (SwinTransformer) is introduced into the backbone network (backbone), and it is embedded in the C3 module to form a new module C3STR, replacing the last layer C3 module of the backbone extraction network.
[0079] By fusing the Swin Transformer module and the C3 module to form the C3STR module and replacing the last layer of the C3 module in the backbone extraction network, the feature extraction capability of the recognition detection model can be significantly improved, the receptive field can be expanded, the computational efficiency can be maintained, and the model structure can be improved. These improvements are of great significance for improving the accuracy and robustness of the recognition detection model.
[0080] On this basis, the hybrid attention mechanism is used to replace the window self-attention module in the Swin Transformer structure, so as to further enhance the target features that are more critical for identifying copper-based solid waste materials through the hybrid attention mechanism, while suppressing unimportant features, thereby enhancing feature semantic information and feature representation. Among them, the hybrid attention mechanism combines global attention and local attention generation.
[0081] Step S1023, performing feature learning on the enhanced target features through the dilated convolution to obtain a prediction result.
[0082] In this embodiment, the enhanced target features are input into the dilated convolution layer, and higher-level feature representations can be further extracted through the dilated convolution operation. These feature representations are usually more abstract and complex, and can capture more subtle differences and patterns in the input data. At the same time, the dilated convolution increases the receptive field by inserting holes, so that each output element can take into account a wider input area. This is particularly important for tasks that need to capture large-scale information or global context information. In the identification of copper-based solid waste materials, this helps the model understand the distribution of objects and scene structure in the entire image. In this way, the dilated convolution enables the model to understand the input data more comprehensively and make more accurate predictions based on the increased receptive field and the ability to extract high-level features.
[0083] Step S1024, calculating a target loss value according to the training data set and the prediction result.
[0084] In this embodiment, the target loss value (such as cross entropy loss, mean square error, etc.) is calculated based on the real label of the training data set and the prediction result of the model. This loss value reflects the difference between the model prediction result and the actual situation.
[0085] Step S1025, updating the model parameters of the target detection model according to the target loss value to obtain the copper-based solid waste material identification and detection model.
[0086] In this embodiment, the backpropagation algorithm and the optimizer are used to update the parameters of the model to minimize the loss value. This process is repeated for multiple iterations (i.e., training rounds) until the performance of the model on the validation set is satisfactory. After the above training process, a detection model that can accurately identify copper-based solid waste materials is finally obtained, which is used for real-time or batch detection and analysis of new image data.
[0087] In a specific embodiment, the hybrid attention mechanism includes the following formula: HybridAttention(Q, K, V) = λ×LocalAttention(Q, K, V)+(1-λ)×GlobalAttention(Q, K, V), where λ is a preset hyperparameter, HybridAttention(Q, K, V) is the feature vector of the hybrid attention mechanism, LocalAttention(Q, K, V) is the feature vector of the local attention mechanism, and GlobalAttention(Q, K, V) is the feature vector of the global attention mechanism.
[0088] It should be noted that Q, K, and V represent query, key, and value, respectively. These are three matrices commonly used in the attention mechanism to calculate attention scores and weighted sum feature representations. λ is a preset hyperparameter that controls the weights of local attention and global attention in the hybrid attention mechanism. By adjusting the value of λ, the contribution of the two to the final feature representation can be balanced. LocalAttention(Q, K, V) and GlobalAttention(Q, K, V) represent the feature vectors calculated by the local attention and global attention mechanisms, respectively.
[0089] When the hybrid attention mechanism is applied to feature enhancement, it actually re-weights and integrates the input features. By weighting and summing the corresponding feature representations, the hybrid attention mechanism can generate a richer feature vector that contains both local detail information and global context information. Such a feature vector can be used more effectively in subsequent network layers, thereby improving the overall performance of the model.
[0090] The attention mechanism determines which parts of the value V a given query should focus on by calculating the similarity score between the query Q and the key K. Here, dot product attention is used to calculate the attention score: Where Q is the query matrix, K is the key matrix, V is the value matrix, and d is the dimension of the key.
[0091] The local attention mechanism focuses on local information of the input. It only pays attention to values near the query, improving efficiency and capturing local context by limiting the attention range. The calculation formula of local attention is similar to global attention, but its key and value selection is a subset extracted from the local window: Among them, B represents a dimension M 2 ×M 2 The bias matrix, K local and V local A local subset of keys and values, typically selected via a sliding window approach.
[0092] The global attention mechanism focuses on the entire input sequence and captures the global context. It is usually more effective at modeling long-range dependencies and global patterns. The calculation formula for global attention is the same as standard attention: Among them, K global and V global are the keys and values of the entire input sequence.
[0093] The hybrid attention mechanism combines the advantages of local attention and global attention, and the generated feature representation contains both local and global information. In order to achieve this combination, a hyperparameter λ is usually introduced to balance the contribution of local and global attention. The calculation formula of the hybrid attention mechanism can be expressed as: HybridAttention(Q, K, V) = λ×LocalAttention(Q, K, V)+(1-λ)×GlobalAttention(Q, K, V), where λ is a preset hyperparameter that controls the contribution of local and global attention, and its value range is [0, 1]. When λ=1, the model only uses local attention; when λ=0, only global attention is used; when 0<λ<1, the model considers both local and global information.
[0094] By introducing the hybrid attention mechanism, local details and global context can be combined in feature representation, thereby enhancing the model's ability to perceive information of different ranges. This weighted summed feature vector can more effectively express the multi-level structure of the data in subsequent neural network layers.
[0095] See also Figure 3 In a specific embodiment, step S1024 includes steps S301 to S305, and each step is described in detail below.
[0096] Step S301, calculating an angle loss value according to the angle information of the training data set and the prediction result.
[0097] In this embodiment, the angle loss is used to measure the angle difference between the predicted bounding box and the true bounding box. It can be calculated according to the formula: To calculate the angle loss value Λ, see Figure 4 , B is the midpoint of the true bounding box, B GT is the midpoint of the predicted bounding box, σ is the midpoint B of the real bounding box and is the midpoint B of the predicted bounding box GT The distance between h is a right-angled side of a right triangle with σ as the hypotenuse,
[0098] Step S302, determining an attenuation factor according to the angle loss value, and calculating a distance loss value according to the center point information of the training data set and the prediction result, and the attenuation factor.
[0099] In this embodiment, the distance loss is used to measure the distance between the center point of the predicted bounding box and the center point of the true bounding box. The formula is: Calculate the distance loss value Δ, the formula uses an exponential decay function Where ρt is the distance metric in the x or y direction, and the attenuation factor γ is calculated according to the formula: γ = 2-Λ, which is used to adjust the weight of the distance loss according to the size of the angle difference, thereby giving more attention to the distance loss when the angle difference is large.
[0100] Step S303: Calculate a shape loss value according to the shape information of the training data set and the prediction result.
[0101] In this embodiment, the shape loss takes into account the differences in the width w and height h of the bounding box, and weights these differences through an exponential decay function and a shape error attention parameter θ. This loss term encourages the model to accurately predict not only the center point position when predicting the bounding box, but also the shape (i.e., width and height) of the bounding box as accurately as possible. Among them, the shape loss value Ω is based on the formula: to calculate.
[0102] Step S304, calculating an intersection-over-union ratio according to the area information of the training data set and the prediction result.
[0103] In this embodiment, the intersection over union (IoU) is a performance metric used to evaluate the accuracy of annotation, segmentation, and object detection algorithms. It quantifies the degree of overlap between the predicted bounding box or segmented area and the ground truth bounding box or annotated area. IoU is calculated by dividing the intersection area of the predicted area in the prediction result and the true area in the training dataset by their union area.
[0104] Step S305, calculating the target loss value according to the angle loss value, the shape loss value, the distance loss value and the intersection-over-union ratio.
[0105] In this embodiment, the target loss value L SIoU It is the weighted sum of the intersection over union (IoU) and the above three loss values (angle loss, distance loss, shape loss). The intersection over union (IoU) itself measures the overlap between the predicted bounding box and the true bounding box, while the other three loss values provide additional penalties for angle, distance, and shape differences. This helps the model optimize these aspects simultaneously during training, thereby improving the accuracy and robustness of bounding box prediction. According to the formula Calculate the target loss value.
[0106] In a specific embodiment, after step S103, it includes: judging whether the current copper-based solid waste material corresponding to the copper-based solid waste material image to be identified needs to be crushed according to the material identification result; if not, sorting and warehousing the current copper-based solid waste material according to the material identification result; if yes, sending the current copper-based solid waste material to the crushing equipment for crushing according to the material identification result, and sorting and warehousing the copper-based solid waste material after the crushing.
[0107] In this embodiment, it is determined whether the current copper-based solid waste material corresponding to the copper-based solid waste material to be identified needs to be crushed according to the material labeling information in the material identification result. If the judgment result shows that the current copper-based solid waste material does not need to be crushed, then the material will be directly sent to the sorting area for sorting. The purpose of sorting is to classify the material according to its nature, purpose or other standards for subsequent processing or storage. After the sorting is completed, the material will be sent to the corresponding warehouse or storage area for storage. If the judgment result shows that the current copper-based solid waste material needs to be crushed, then the material will be sent to the crushing equipment for crushing. The purpose of crushing is to decompose the material into smaller particles or fragments for subsequent separation, purification or other processing. After the crushing is completed, the crushed material will be sent back to the sorting area for sorting and stored in the same process. In this way, through material identification, the material processing requirements can be automatically determined, thereby reducing manual intervention and improving processing efficiency and accuracy. At the same time, automated sorting and crushing also reduce the labor intensity of workers and improve the working environment.
[0108] In a specific embodiment, judging whether the current copper-based solid waste material corresponding to the copper-based solid waste material image to be identified needs to be crushed according to the material identification result includes: classifying the copper-based solid waste material in the material identification result to obtain a classification result; the classification result includes a category that needs to be crushed and / or a category that does not need to be crushed; judging whether the category that needs to be crushed exists in the classification result; if so, the current copper-based solid waste material needs to be crushed; if not, the current copper-based solid waste material does not need to be crushed.
[0109] In this embodiment, the materials are classified into different categories according to the multiple material type information in the material identification result. The classification may be based on the physical properties (such as size, hardness), chemical composition, recycling value or other factors related to crushing.
[0110] For example, large, hard materials may be more suitable for crushing for subsequent sorting, refining or recycling; while small, fragile materials may not require additional crushing and can be directly processed in other ways.
[0111] Exemplarily, waste circuit boards are classified into a category that needs to be crushed, and resin powder is classified into a category that does not need to be crushed.
[0112] Furthermore, in the classification results, it is determined whether there are any categories that need to be crushed. Crushing processing helps to reduce the size of materials and improve the efficiency and effect of subsequent processing.
[0113] If it exists, it means that the current copper-based solid waste materials include materials that need to be crushed. Therefore, it is necessary to crush the materials corresponding to the categories that need to be crushed in the classification results, and then sort the crushed materials and the materials corresponding to the categories that do not need to be crushed into storage; or the materials corresponding to the categories that need to be crushed and the materials corresponding to the categories that do not need to be crushed can be crushed together, and then the crushed materials can be sorted into storage.
[0114] If it does not exist, that is, the classification results are all categories that do not require crushing, it means that the current material does not need to be crushed and can directly enter the next stage of sorting and storage. This process realizes the efficient and accurate processing of copper-based solid waste materials, avoids unnecessary crushing operations through classification judgment, and improves resource utilization and processing efficiency.
[0115] The copper-based solid waste material identification method proposed in this embodiment obtains a real-time image of the copper-based solid waste material, generates a training data set according to the real-time image; trains the target detection model through the training data set to obtain a copper-based solid waste material identification detection model; and identifies the copper-based solid waste material image to be identified through the copper-based solid waste material identification detection model to obtain a material identification result. In this way, by constructing an efficient copper-based solid waste material identification model, the automation of the entire copper-based solid waste material identification process from image acquisition to material identification is realized, and the real-time processing capability of the target detection algorithm is utilized to quickly respond to and process large quantities of copper-based solid waste materials on the production line, significantly improving the efficiency and automation level of the production line.
[0116] Example 2
[0117] In addition, the present disclosure provides a copper-based solid waste material identification device 500, see Figure 5 , the device comprises:
[0118] An acquisition module 501 is used to acquire a real-time image of copper-based solid waste materials and generate a training data set according to the real-time image;
[0119] A training module 502 is used to train the target detection model using the training data set to obtain a copper-based solid waste material recognition detection model;
[0120] The identification module 503 is used to identify the copper-based solid waste material image to be identified by using the copper-based solid waste material identification and detection model to obtain a material identification result.
[0121] Optionally, the acquisition module 501 is further used to preprocess the multiple real-time images; label various copper-based solid waste materials in each preprocessed real-time image to obtain multiple labeled images; and use each labeled image as the training data set.
[0122] Optionally, the target detection model includes a dilated convolution and a hybrid attention mechanism, and the training module 502 is further used to perform feature extraction on the training data set through the dilated convolution to obtain target features; perform feature enhancement on the target features through the hybrid attention mechanism; perform feature learning on the enhanced target features through the dilated convolution to obtain prediction results; calculate a target loss value based on the training data set and the prediction results; and update the model parameters of the target detection model based on the target loss value to obtain the copper-based solid waste material recognition and detection model.
[0123] Optionally, the hybrid attention mechanism includes the following formula: HybridAttention(Q, K, V)=λ×LocalAttention(Q, K, V)+(1-λ)×GlobalAttention(Q, K, V), where λ is a preset hyperparameter, HybridAttention(Q, K, V) is the feature vector of the hybrid attention mechanism, LocalAttention(Q, K, V) is the feature vector of the local attention mechanism, and GlobalAttention(Q, K, V) is the feature vector of the global attention mechanism.
[0124] Optionally, the training module 502 is also used to calculate an angle loss value based on the angle information of the training data set and the prediction result; determine an attenuation factor based on the angle loss value; calculate a distance loss value based on the center point information of the training data set and the prediction result, and the attenuation factor; calculate a shape loss value based on the shape information of the training data set and the prediction result; calculate an intersection-and-union ratio based on the area information of the training data set and the prediction result; and calculate the target loss value based on the angle loss value, the shape loss value, the distance loss value and the intersection-and-union ratio.
[0125] Optionally, the device also includes a processing module, which is used to determine whether the current copper-based solid waste material corresponding to the copper-based solid waste material image to be identified needs to be crushed according to the material identification result; if not, the current copper-based solid waste material is sorted and stored according to the material identification result; if yes, the current copper-based solid waste material is sent to the crushing equipment for crushing according to the material identification result, and the copper-based solid waste material after crushing is sorted and stored.
[0126] Optionally, the processing module is also used to classify the copper-based solid waste materials in the material identification results to obtain classification results; the classification results include categories that require crushing and / or categories that do not require crushing; determine whether the categories that require crushing exist in the classification results; if so, the current copper-based solid waste materials need to be crushed; if not, the current copper-based solid waste materials do not need to be crushed.
[0127] The device provided in the embodiment of the present disclosure can execute the steps of the copper-based solid waste material identification method provided in Example 1, which will not be described again to avoid repetition.
[0128] The copper-based solid waste material identification device proposed in this embodiment obtains a real-time image of the copper-based solid waste material, generates a training data set according to the real-time image; trains the target detection model through the training data set to obtain a copper-based solid waste material identification detection model; and identifies the copper-based solid waste material image to be identified through the copper-based solid waste material identification detection model to obtain a material identification result. In this way, by constructing an efficient copper-based solid waste material identification model, the automation of the entire copper-based solid waste material identification process from image acquisition to material identification is realized, and the real-time processing capability of the target detection algorithm is utilized to quickly respond to and process large quantities of copper-based solid waste materials on the production line, significantly improving the efficiency and automation level of the production line.
[0129] Example 3
[0130] In addition, an embodiment of the present disclosure provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and when the computer program is executed by the processor, the copper-based solid waste material identification method described in Example 1 is implemented.
[0131] The device provided in the embodiment of the present disclosure can execute the steps of the copper-based solid waste material identification method provided in Example 1, which will not be described again to avoid repetition.
[0132] Example 4
[0133] The disclosed embodiment provides a computer-readable storage medium storing a computer program, which implements the copper-based solid waste material identification method described in Embodiment 1 when executed by a processor.
[0134] In this embodiment, the computer-readable storage medium may be a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.
[0135] The computer-readable storage medium provided in this embodiment can implement the copper-based solid waste material identification method provided in Example 1, and will not be described again here to avoid repetition.
[0136] In all examples shown and described herein, any specific values should be interpreted as merely exemplary and not as limiting, and thus other examples of the exemplary embodiments may have different values.
[0137] 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.
[0138] The above-mentioned embodiments only express several implementation methods of the present invention, and the description thereof is relatively specific and detailed, but it cannot be understood as limiting the scope of the present invention. It should be pointed out that for ordinary technicians in this field, several variations and improvements can be made without departing from the concept of the present invention, which all belong to the protection scope of the present invention.
Claims
1. A method for identifying copper-based solid waste materials, characterized in that: The method comprises: Acquire a real-time image of a copper-based solid waste material, and generate a training data set according to the real-time image; The target detection model is trained by using the training data set to obtain a copper-based solid waste material recognition and detection model; The copper-based solid waste material recognition and detection model is used to recognize the copper-based solid waste material image to be recognized, and a material recognition result is obtained.
2. The copper-based solid waste material identification method according to claim 1, characterized in that: The step of generating a training data set according to the real-time image comprises: Preprocessing the plurality of real-time images; Annotating various copper-based solid waste materials in each pre-processed real-time image to obtain a plurality of annotated images; Each of the labeled images is used as the training data set.
3. The copper-based solid waste material identification method according to claim 1, characterized in that: The target detection model includes a dilated convolution and a hybrid attention mechanism. The target detection model is trained by the training data set to obtain a copper-based solid waste material recognition and detection model, including: Performing feature extraction on the training data set through the dilated convolution to obtain target features; Performing feature enhancement on the target feature through the hybrid attention mechanism; Performing feature learning on the enhanced target features through the dilated convolution to obtain a prediction result; Calculate a target loss value according to the training data set and the prediction result; The model parameters of the target detection model are updated according to the target loss value to obtain the copper-based solid waste material identification and detection model.
4. The method for identifying copper-based solid waste materials according to claim 3, characterized in that: The hybrid attention mechanism includes the following formula: HybridAttention(Q, K, V)=λ×LocalAttention(Q, K, V)+(1-λ)×GlobalAttention(Q, K, V), where λ is a preset hyperparameter, HybridAttention(Q, K, V) is the feature vector of the hybrid attention mechanism, LocalAttention(Q, K, V) is the feature vector of the local attention mechanism, and GlobalAttention(Q, K, V) is the feature vector of the global attention mechanism.
5. The method for identifying copper-based solid waste materials according to claim 3, characterized in that: The calculating the target loss value according to the training data set and the prediction result includes: Calculate an angle loss value based on the angle information between the training data set and the prediction result; determining an attenuation factor according to the angle loss value; Calculating a distance loss value according to the center point information of the training data set and the prediction result, and the attenuation factor; Calculating a shape loss value according to the shape information of the training data set and the prediction result; Calculating an intersection-over-union ratio based on the area information of the training data set and the prediction result; The target loss value is calculated according to the angle loss value, the shape loss value, the distance loss value and the intersection-over-union ratio.
6. The copper-based solid waste material identification method according to claim 1, characterized in that: After the copper-based solid waste material image to be identified is identified by the copper-based solid waste material identification and detection model and a material identification result is obtained, the method includes: Determining whether the current copper-based solid waste material corresponding to the copper-based solid waste material image to be identified needs to be crushed according to the material identification result; If not, the current copper-based solid waste material is sorted and stored according to the material identification result; If so, the current copper-based solid waste material is sent to a crushing device for crushing according to the material identification result, and the copper-based solid waste material after the crushing is sorted and stored.
7. The method for identifying copper-based solid waste materials according to claim 6, characterized in that: The determining, according to the material recognition result, whether the current copper-based solid waste material corresponding to the copper-based solid waste material image to be recognized needs to be crushed includes: Classifying the copper-based solid waste materials in the material identification results to obtain classification results; the classification results include a category that needs to be crushed and / or a category that does not need to be crushed; Determine whether the classification result contains the category that needs to be crushed; If yes, the current copper-based solid waste material needs to be crushed; If not, the current copper-based solid waste material does not need to be crushed.
8. A copper-based solid waste material identification device, characterized in that: The device comprises: An acquisition module, used to acquire a real-time image of the copper-based solid waste material and generate a training data set according to the real-time image; A training module, used to train the target detection model through the training data set to obtain a copper-based solid waste material recognition and detection model; The recognition module is used to recognize the copper-based solid waste material image to be recognized through the copper-based solid waste material recognition and detection model to obtain a material recognition result.
9. A computer device, characterized in that: The method comprises a memory and a processor, wherein the memory stores a computer program, and when the computer program is executed by the processor, the method for identifying copper-based solid waste materials according to any one of claims 1 to 7 is implemented.
10. A computer-readable storage medium, characterized in that: It stores a computer program, and when the computer program is executed by a processor, the copper-based solid waste material identification method according to any one of claims 1 to 7 is implemented.
