Image edge searching method and device, computer equipment, storage medium and program product

By using the target edge-finding model to extract and classify images, it solves the problem of poor performance of traditional algorithms in low-brightness or similar background environments, achieves accurate identification and classification of document materials, and improves the work efficiency of the banking industry.

CN118570488APending Publication Date: 2024-08-30INDUSTRIAL AND COMMERCIAL BANK OF CHINA
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410656340.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-05-24
Publication Date
2024-08-30

AI Technical Summary

Technical Problem

The traditional image edge-finding algorithm has high requirements on the brightness and background color of the shooting environment, resulting in poor results in environments with low brightness or similar background colors, and cannot classify document materials, resulting in low efficiency in the banking industry.

Method used

Using a pre-built target edge-finding model, the image is processed through the feature extraction layer, area detection layer and classification layer to extract the category information and location information of the target object to achieve classification and cutting of document materials and reduce the requirements for the shooting environment. .

Benefits of technology

It improves the accuracy and efficiency of image edge finding, can effectively identify and cut document materials in different environments, reduces the requirements for the shooting environment, and does not need to photograph document materials in a specified order.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118570488A
    Figure CN118570488A
Patent Text Reader

Abstract

The invention provides an image edge searching method and device, computer equipment, a storage medium and a program product, and relates to the field of artificial intelligence, target image data is obtained by performing data processing on an original image, feature extraction is performed on the target image data by using a pre-constructed target edge searching model, and a target edge searching result is obtained. And determining category information and position information of a target object in the original image according to a feature extraction result, and determining an edge searching result according to the category information and the position information of the target object. According to the method and the device, the defects that the requirement of a traditional edge searching mode on a shooting environment is relatively strict and edge-searched certificates are difficult to classify are overcome, and the characteristics of various certificate materials are learned by utilizing the edge searching model; and the related certificate materials appearing in the image are classified and the positions of the related certificate materials are judged in the subsequent network structure through the obtained feature map, so that the high requirement on the shooting environment can be reduced in the process, and shooting does not need to be carried out according to a specified certificate material sequence.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of artificial intelligence technology, and in particular to an image edge finding method, device, computer equipment, storage medium and program product. Background Art

[0002] In today's digital age, more and more industries choose to save images of certificates and paper materials in servers by taking photos, reducing reliance on paper storage. In the banking industry, it is usually necessary to take and save image files of various types of related certificate materials. During the shooting process, it is necessary to find the edge of the captured image and cut it to ensure that most of the image content of the saved image is the certificate material.

[0003] In the traditional image edge finding algorithm, there are high requirements for the brightness of the image shooting environment and the related background color. In the environment with low brightness or the color of the document material and the shooting background is similar, the effect of the traditional edge finding algorithm may become poor. Summary of the invention

[0004] Based on this, it is necessary to provide an image edge finding method, device, computer equipment, storage medium and program product that can improve the edge finding effect in response to the above technical problems.

[0005] In a first aspect, the present application provides an image edge finding method, the method comprising:

[0006] Performing data processing on the original image to obtain target image data;

[0007] The pre-built target edge-finding model is used to extract features from the target image data, and the category information and location information of the target object in the original image are determined based on the feature extraction results;

[0008] The edge search result is determined based on the category information and location information of the target object.

[0009] In one of the embodiments, the target edge-finding model includes a feature extraction layer, a region detection layer, and a classification layer connected in sequence, and the region detection layer includes a region proposal network and an image processing network connected in sequence.

[0010] In one embodiment, the above-mentioned feature extraction of the target image data and determining the category information and position information of the target object in the original image according to the feature extraction result include:

[0011] Inputting the target image data into the feature extraction layer to perform multi-scale feature extraction processing to obtain a first feature map;

[0012] Inputting the first feature map into the region detection layer for region detection processing to obtain a second feature map corresponding to a plurality of candidate regions containing the target object;

[0013] Each second feature map is input into the classification layer for classification processing to obtain the image category and position information of the target object.

[0014] In one embodiment, the first feature map is input into the region detection layer for region detection processing to obtain a plurality of second feature maps corresponding to candidate regions containing target objects, including:

[0015] Inputting the first feature map into a region proposal network for region detection processing to obtain multiple candidate regions containing target objects;

[0016] Each candidate region is input into the image processing network for resizing to obtain a plurality of second feature maps.

[0017] In one embodiment, the edge finding result includes a cropping result and annotation information, and the edge finding result is determined according to the category information and the position information, including:

[0018] The original image is cropped according to the position information to obtain a cropping result;

[0019] The labeling information is determined according to the image category of the target image.

[0020] In one embodiment, the method further comprises:

[0021] Acquire multiple training samples, each training sample including a training image and a category label and a position label corresponding to the training image;

[0022] The initial edge-finding model is trained based on multiple training samples to determine the target edge-finding model.

[0023] In one embodiment, the method further comprises:

[0024] Get the cropping data entered by the user;

[0025] According to the edge-finding results and cutting data, the target edge-finding model is optimized to obtain the optimized result.

[0026] In one embodiment, the data processing of the original image to obtain the image data includes:

[0027] Perform data cleaning on the original image to obtain target cleaned data;

[0028] Perform data enhancement processing on the target cleaned data to obtain the target image data.

[0029] In one embodiment, the data cleaning process of the original image is performed to obtain target cleaned data, including:

[0030] The original image is deduplicated and noise filtered to obtain the target cleaned data.

[0031] In one embodiment, the data enhancement processing is performed on the target cleaned data to obtain the target image data, including:

[0032] The target cleaning data is subjected to at least one of rotation, scaling and contrast adjustment to obtain target image data.

[0033] In a second aspect, the present application further provides an image edge finding device, the device comprising:

[0034] A data determination module is used to process the original image to obtain target image data;

[0035] A category and position determination module is used to extract features from target image data using a pre-built target edge-finding model, and determine category information and position information of the target object in the original image based on the feature extraction results;

[0036] The result determination module is used to determine the edge search result according to the category information and location information of the target object.

[0037] In a third aspect, the present application further provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the following steps are implemented:

[0038] Performing data processing on the original image to obtain target image data;

[0039] The pre-built target edge-finding model is used to extract features from the target image data, and the category information and location information of the target object in the original image are determined based on the feature extraction results;

[0040] The edge search result is determined based on the category information and location information of the target object.

[0041] In a fourth aspect, the present application further provides a computer-readable storage medium having a computer program stored thereon, wherein when the computer program is executed by a processor, the following steps are implemented:

[0042] Performing data processing on the original image to obtain target image data;

[0043] The pre-built target edge-finding model is used to extract features from the target image data, and the category information and location information of the target object in the original image are determined based on the feature extraction results;

[0044] The edge search result is determined based on the category information and location information of the target object.

[0045] In a fifth aspect, the present application further provides a computer program product, including a computer program, characterized in that when the computer program is executed by a processor, the following steps are implemented:

[0046] Performing data processing on the original image to obtain target image data;

[0047] The pre-built target edge-finding model is used to extract features from the target image data, and the category information and location information of the target object in the original image are determined based on the feature extraction results;

[0048] The edge search result is determined based on the category information and location information of the target object.

[0049] The above-mentioned image edge-finding method, device, computer equipment, storage medium and program product obtain target image data by performing data processing on the original image, and use the pre-constructed target edge-finding model to extract features of the target image data, and determine the category information and position information of the target object in the original image based on the feature extraction results, and determine the edge-finding result based on the category information and position information of the target object. The present application overcomes the shortcomings of the traditional edge-finding method that the shooting environment is relatively strict and it is difficult to classify the documents for edge-finding. The edge-finding model is used to learn the features of various types of document materials, and the acquired feature map is used in the subsequent network structure to classify and determine the position of the relevant document materials appearing in the image (i.e., edge-finding). The above process can reduce the high requirements for the shooting environment, and there is no need to shoot in the specified order of document materials. BRIEF DESCRIPTION OF THE DRAWINGS

[0050] Figure 1 A diagram showing an application environment of an image edge finding method in one embodiment;

[0051] Figure 2 A schematic diagram of a flow chart of an image edge finding method in one embodiment;

[0052] Figure 3 A schematic diagram of a process for determining category information and location information in one embodiment;

[0053] Figure 4 A schematic diagram of a process for obtaining a plurality of second characteristic graphs in one embodiment;

[0054] Figure 5 A schematic diagram of a process for determining an edge search result in one embodiment;

[0055] Figure 6 A schematic diagram of a flow chart of an image edge finding method in another embodiment;

[0056] Figure 7 A schematic diagram of a flow chart of an image edge finding method in another embodiment;

[0057] Figure 8 A schematic diagram of a process for obtaining image data in one embodiment;

[0058] Fig. 9 is a structural block diagram of an image edge finding device in one embodiment;

[0059] Fig.10 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION

[0060] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.

[0061] First of all, before specifically introducing the technical solution of the embodiments of the present application, the technical background based on the embodiments of the present application is introduced.

[0062] In today's digital age, more and more industries choose to save images of certificates and paper materials in servers by taking photos, reducing reliance on paper storage. In the banking industry, it is usually necessary to take and save image files of various types of related certificate materials. During the shooting process, edge finding and cropping of the captured images are required to ensure that most of the image content of the saved images is the certificate materials. The traditional edge finding method currently detects edges based on the intensity gradient of the image (such as brightness and color intensity), which can only handle relatively complex images or images under certain control conditions.

[0063] In the traditional image edge-finding algorithm, there are high requirements for the brightness of the image shooting environment and the related background color. In the environment with low brightness or the color of the certificate material is similar to the shooting background, the effect of the traditional edge-finding algorithm may become poor. In addition, in the traditional edge-finding algorithm, only the edge-finding function can be realized, and the certificate material for edge-finding cannot be classified. This makes the bank staff only able to shoot each material in the specified order of certificate materials, which reduces the work efficiency in the process of certificate materials.

[0064] Based on this, the present application provides an image edge finding method, apparatus, computer device, storage medium and program product, aiming to solve the above technical problems.

[0065] The image edge finding method provided in the embodiment of the present application can be applied to Figure 1In the application environment shown. Among them, the terminal 102 communicates with the server 104 through the network. The data storage system can store the data that the server 104 needs to process. The data storage system can be integrated on the server 104, or it can be placed on the cloud or other network servers. The terminal 102 obtains the target image data by processing the original image, extracts the features of the target image data using the pre-built target edge-finding model, and determines the category information and location information of the target object in the original image according to the feature extraction results, and determines the edge-finding result according to the category information and location information of the target object. Among them, the terminal 102 can be but is not limited to various personal computers, laptops, smart phones, and tablet computers. Portable wearable devices can be smart watches, smart bracelets, head-mounted devices, etc. The server 104 can be implemented with an independent server or a server cluster consisting of multiple servers.

[0066] In an exemplary embodiment, Figure 2 As shown, the embodiment of the present application provides an image edge finding method, which is applied to Figure 1 The terminal in is taken as an example to illustrate, including the following S201 to S203. Among them:

[0067] S201, performing data processing on the original image to obtain target image data.

[0068] The original image refers to a picture taken by a user that contains a target object, and the target object may include a designated edge-seeking object such as an identity card, a bank card, etc.

[0069] In the embodiment of the present application, the user inputs the original image based on the original image upload interface, and the terminal extracts the image data in the original image and performs data processing on the data according to the original image input by the user. The data processing may include at least one method such as data cleaning, data enhancement and feature extraction. After the above data processing, the target image data is obtained.

[0070] S202, using a pre-built target edge-finding model to perform feature extraction on the target image data, and determining category information and position information of the target object in the original image according to the feature extraction result.

[0071] Among them, the target edge finding model can include logistic regression, random forest, and gradient boosting model. The embodiment of the present application does not specifically limit the specific type of the target edge finding model. Category information refers to the category of the target object, such as the front and back of an ID card, the front and back of a bank card. Position information refers to the coordinate data of the target object in the original image.

[0072] In an embodiment of the present application, based on the target image data obtained in the above embodiment, the terminal can input the target image data into a pre-built target edge-finding model. The target edge-finding model can perform feature extraction on the target image data, such as extracting the grayscale and granularity of the feature image, and inferring and judging the extracted results to obtain the category information and position information of the target object in the original image.

[0073] S203: Determine edge search results according to category information and location information of the target object.

[0074] In an embodiment of the present application, based on the category information and position information of the target object obtained in the above embodiment, the terminal can crop the original image according to the category information and position information of the target object to obtain an edge finding result, or directly output the target object as an edge finding result.

[0075] The above-mentioned image edge-finding method obtains target image data by performing data processing on the original image, extracts features of the target image data using a pre-constructed target edge-finding model, and determines the category information and position information of the target object in the original image based on the feature extraction result, and determines the edge-finding result based on the category information and position information of the target object. The embodiment of the present application overcomes the shortcomings of the traditional edge-finding method that the shooting environment is relatively strict and it is difficult to classify the documents for edge-finding. The edge-finding model is used to learn the features of various document materials, and the feature map obtained is used in the subsequent network structure to classify and determine the position of the relevant document materials appearing in the image. The above process can reduce the high requirements for the shooting environment, and there is no need to shoot in the specified order of document materials.

[0076] In an exemplary embodiment, based on the above embodiments, the target edge-finding model of the embodiment of the present application includes a feature extraction layer, a region detection layer and a classification layer connected in sequence, and the region detection layer of the embodiment of the present application also includes a region proposal network and an image processing network connected in sequence.

[0077] In the embodiment of the present application, the feature extraction layer can adopt the Swin Transformer model, which is a computer vision model based on the Transformer architecture, and can obtain the feature information of the image more efficiently and accurately through the hierarchical structure and the shift window mechanism. The region detection layer can adopt texture detection and edge detection models. The classification layer can adopt classification models such as decision tree, K nearest neighbor, Bayes, etc. The embodiment of the present application does not specifically limit the model or network adopted by the hierarchy.

[0078] The embodiment of the present application enhances data features by performing feature extraction on target image data so that the regions obtained by region detection are more accurate, thereby improving the accuracy of the model output.

[0079] In an exemplary embodiment, based on the above embodiment, see Figure 3 The embodiment of the present application relates to a process of extracting features from target image data and determining the category information and location information of the target object in the original image according to the feature extraction result, including the following S301 to S303. Among them:

[0080] S301, inputting target image data into a feature extraction layer for multi-scale feature extraction processing to obtain a first feature map.

[0081] In an embodiment of the present application, based on the target image data obtained in the above embodiment, the terminal inputs the target image data into the feature extraction layer, and the Swin Transformer network (feature extraction layer) performs multi-scale and hierarchical extraction on the target image data to finally obtain the first feature map.

[0082] S302, input the first feature map into the region detection layer for region detection processing, and obtain a second feature map corresponding to a plurality of candidate regions containing the target object.

[0083] In the embodiment of the present application, the first feature map extracted by the Swin Transformer network is processed by the region detection layer to obtain the region that may contain the target document material (the second feature map corresponding to the candidate region of the target object). The region detection process may include data extraction, candidate region detection, image processing, etc.

[0084] S303: Input each second feature map into a classification layer for classification processing to obtain image category and position information of the target object.

[0085] In an embodiment of the present application, based on the second feature maps obtained in the above embodiments, each second feature map is input into a classification layer, such as a decision tree, K nearest neighbor, Bayesian or other classification model for classification processing to obtain the image category and location information of the target object.

[0086] The embodiment of the present application further enhances data features by performing multi-scale and multi-level feature extraction on target image data, thereby further improving the accuracy of regions obtained by region detection.

[0087] In an exemplary embodiment, based on the above embodiment, see Figure 4 The embodiment of the present application relates to a process of inputting a first feature map into a region detection layer for region detection processing to obtain a second feature map corresponding to a plurality of candidate regions containing target objects, including the following S401 to S402. Among them:

[0088] S401, input the first feature map into a region proposal network for region detection processing to obtain multiple candidate regions containing target objects.

[0089] Among them, the region proposal network can be RPN (Region Proposal Network, region generation network).

[0090] In an embodiment of the present application, based on the first feature map obtained in the above embodiment, the terminal can input the first feature map into the region proposal network for region detection processing. Specifically, the input of the RPN network is a feature map, which is a shared feature map obtained from the original image through a convolutional neural network. The output is a series of rectangular candidate boxes (candidate areas) generated by the RPN network, which are used for further processing to identify objects. Operation mechanism: Sliding window processing: The feature map is processed through a 3x3 sliding window. This operation can be regarded as a 3x3 convolution of the feature map to obtain a 256-dimensional feature vector. Full connection operation: Two full connection operations are performed on each feature vector, one to obtain 2 scores and the other to obtain 4 coordinates (used to indicate the position of the candidate box). The RPN network predefines a series of anchor points of different sizes and proportions, which generate multiple rectangular boxes on the feature map. Each anchor point corresponds to the score of an object or non-object, as well as the candidate box coordinates relative to the anchor point.

[0091] S402, input each candidate region into the image processing network for resizing, and obtain multiple second feature maps.

[0092] Among them, the image processing network can adopt a PoI Pooling (target detection) network.

[0093] In an embodiment of the present application, based on each candidate region obtained in the above embodiment, each candidate region is input into an image processing network for resizing, and is converted into a feature map of uniform size after PoI Pooling, and finally a plurality of second feature maps are obtained.

[0094] The embodiment of the present application extracts feature maps corresponding to candidate regions of certificate materials in the image through a region proposal network, and then these feature maps are sent to the convolutional layer to further confirm the position, size and category label of each region, so that the type and location information of each certificate material in the image can be accurately obtained.

[0095] In an exemplary embodiment, based on the above embodiment, see Figure 5 The edge finding result of the embodiment of the present application includes a cropping result and annotated information. The embodiment of the present application is related to a process of determining the edge finding result according to category information and position information, including the following S501 to S502. Among them:

[0096] S501, cropping the original image according to the position information to obtain a cropping result.

[0097] In an embodiment of the present application, based on the position information obtained in the above embodiment, the terminal can perform cropping processing on the basis of the original image according to the position coordinates of each edge of the target object to obtain a cropping result, that is, an image that only contains the target object.

[0098] S502: Determine annotation information according to the image category of the target image.

[0099] In an embodiment of the present application, based on the category of the target image obtained in the above embodiment, the cropped image with the target object as the main body is annotated with the target object type information obtained previously, and the category and main body image corresponding to the target object are output.

[0100] In the embodiment of the present application, the original image is cropped according to the position information to obtain the required cropping result, and the annotation information is determined according to the image category of the target image. The annotation information is used as a new data set to train the model to continuously improve the model.

[0101] In an exemplary embodiment, based on the above embodiment, see Figure 6 The method of the embodiment of the present application further includes the following S601 to S602. Among them:

[0102] S601, obtaining multiple training samples.

[0103] Each training sample includes a training image and a category label and a position label corresponding to the training image.

[0104] In the embodiment of the present application, the training sample can be input by the user or can be collected annotation information. The terminal can obtain the user input and the collected annotation information at a preset time.

[0105] S602: Train an initial edge-finding model based on multiple training samples to determine a target edge-finding model.

[0106] In an embodiment of the present application, the terminal inputs multiple training samples into the initial edge-finding model to obtain output results, adjusts the model parameters by calculating the loss value of the output results and the target results, and when the loss value meets the preset conditions, uses the model at this time as the target edge-finding model.

[0107] The embodiment of the present application can improve the output accuracy of the model by continuously training the edge-finding model.

[0108] In an exemplary embodiment, based on the above embodiment, see Figure 7 The method of the embodiment of the present application further includes the following S701 to S702. Among them:

[0109] S701, obtaining cutting data input by a user.

[0110] In the embodiment of the present application, the user can provide feedback on the cropping result of the output certificate material image. If the final result is not satisfactory, the user can manually crop the original image and mark the type of certificate material. Finally, the relevant image and annotation information are used as a new data set to train the model to continuously improve the model. Specifically: the user judges the output result of the cropping module. If the feedback is not satisfactory with the cropping effect, the user can enter the manual cropping step. The user manually crops the original photographed certificate material and manually marks the type of the cropped certificate material, and the manual cropping result is used as the final output result after this edge-finding cropping.

[0111] S702, optimizing the target edge-finding model according to the edge-finding result and the cutting data to obtain an optimization result.

[0112] In the embodiment of the present application, based on the edge finding results and cropping data obtained in the above embodiment, the relevant position information and type information of the image cropped by the user are collected as label data, and the original image is saved, and these data are converted into part of the model training set data. When the collected relevant data of the user's manual cropping reaches a certain amount, these data are used as the new training set of the model to further train the original model to optimize the effect of the existing model outputting the type and position information of the certificate material

[0113] In an embodiment of the present application, the trained model output is optimized and used as the target detection model in the target detection module of the new document material image, thereby improving the final edge-finding and cutting effect.

[0114] In an exemplary embodiment, based on the above embodiment, see Figure 8 The embodiment of the present application involves data processing of an original image, and the process of obtaining image data includes the following S801 to S802. Among them:

[0115] S801, performing data cleaning processing on the original image to obtain target cleaned data.

[0116] In an embodiment of the present application, a user obtains data of an original image of a relevant certificate material by photographing relevant certificate material information, and a terminal obtains the original image and performs data cleaning on the original image, such as deduplication and noise removal, to obtain target cleaned data.

[0117] S802, performing data enhancement processing on the target cleaned data to obtain target image data.

[0118] In an embodiment of the present application, a user obtains data of an original image of a relevant certificate material by photographing relevant certificate material information. After the terminal obtains the original image and performs data cleaning on the original image to obtain target cleaned data, the target cleaned data is input into a data enhancement network for data enhancement processing to obtain target image data.

[0119] The embodiment of the present application can effectively reduce the error caused by data noise by performing data cleaning and data enhancement on the original image, and can make the data features more distinct by enhancing the data, thereby facilitating classification.

[0120] In an exemplary embodiment, based on the above embodiments, the embodiments of the present application involve a process of performing data cleaning processing on the original image to obtain target cleaned data, specifically including: performing deduplication processing and noise filtering processing on the original image to obtain target cleaned data.

[0121] In the embodiment of the present application, the original image data obtained by the user is subjected to data cleaning steps such as deduplication, noise filtering and standardization of image data format to reduce interference elements. By deduplication, noise filtering and standardization of image data format, the error caused by data noise can be effectively reduced.

[0122] In an exemplary embodiment, based on the above embodiments, the embodiments of the present application involve performing data enhancement processing on the target cleaning data to obtain target image data, specifically including: performing at least one of rotation, scaling and contrast adjustment on the target cleaning data to obtain target image data.

[0123] In the embodiment of the present application, the target cleaning data is obtained based on the above embodiment, and the target cleaning data is slightly rotated and scaled, and the brightness and contrast are appropriately adjusted to enhance the data of the cleaned image to a certain extent; the original image data is cleaned and the relevant image data after appropriate data enhancement is output. The embodiment of the present application can make the data features more distinct by enhancing the data, which is conducive to classification.

[0124] In an exemplary embodiment, based on the above embodiment, the method of the embodiment of the present application further includes the following steps:

[0125] Step 1: Obtain multiple training samples, train the initial edge-finding model based on the multiple training samples, and determine the target edge-finding model;

[0126] Step 2: performing deduplication processing and noise filtering processing on the original image to obtain target cleaned data, and performing at least one of rotation, scaling and contrast adjustment processing on the target cleaned data to obtain target image data;

[0127] Step 3: Input the target image data into the feature extraction layer in the target edge-finding model for multi-scale feature extraction processing to obtain a first feature map; input the first feature map into the region proposal network in the target edge-finding model for region detection processing to obtain multiple candidate regions containing the target object; input each candidate region into the image processing network in the target edge-finding model for size adjustment processing to obtain multiple second feature maps;

[0128] Step 4: Input each second feature map into the classification layer for classification processing to obtain the image category and location information of the target object;

[0129] Step 5: Crop the original image according to the position information to obtain the cropping result, and determine the annotation information according to the image category of the target image.

[0130] It should be understood that, although the various steps in the flowcharts involved in the above-mentioned embodiments are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps does not have a strict order restriction, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above-mentioned embodiments can include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the steps or stages in other steps.

[0131] Based on the same inventive concept, the embodiment of the present application also provides an image edge finding device for implementing the image edge finding method involved above. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme recorded in the above method, so the specific limitations in one or more image edge finding device embodiments provided below can refer to the limitations of the image edge finding method above, and will not be repeated here.

[0132] In one embodiment, Fig. 9 As shown, an image edge finding device 900 is provided, comprising:

[0133] The data determination module 901 is used to process the original image to obtain target image data;

[0134] The category and position determination module 902 is used to extract features from the target image data using a pre-built target edge-finding model, and determine the category information and position information of the target object in the original image according to the feature extraction result;

[0135] The result determination module 903 is used to determine the edge search result according to the category information and location information of the target object.

[0136] In one embodiment, the target edge-finding model includes a feature extraction layer, a region detection layer, and a classification layer connected in sequence, and the region detection layer includes a region proposal network and an image processing network connected in sequence.

[0137] In one embodiment, the category location determination module 902 includes:

[0138] A first image determination unit is used to input the target image data into the feature extraction layer to perform multi-scale feature extraction processing to obtain a first feature map;

[0139] A second image determination unit is used to input the first feature map into the region detection layer to perform region detection processing, and obtain a second feature map corresponding to a plurality of candidate regions containing the target object;

[0140] The category position determination unit is used to input each second feature map into the classification layer for classification processing to obtain the image category and position information of the target object.

[0141] In one embodiment, the second image determining unit includes:

[0142] A candidate region determination subunit is used to input the first feature map into a region proposal network for region detection processing to obtain multiple candidate regions containing target objects;

[0143] The second image determination subunit is used to input each candidate area into the image processing network for resizing processing to obtain multiple second feature maps.

[0144] In one embodiment, the edge finding result includes a cutting result and annotation information, and the result determination module 903 includes:

[0145] A cropping result determination unit, used for performing cropping processing on the original image according to the position information to obtain a cropping result;

[0146] The labeling information determining unit is used to determine the labeling information according to the image category of the target image.

[0147] In one embodiment, the above device further comprises:

[0148] A sample acquisition module is used to acquire multiple training samples, each training sample includes a training image and a category label and a position label corresponding to the training image;

[0149] The model determination module is used to train the initial edge-finding model based on multiple training samples and determine the target edge-finding model.

[0150] In one embodiment, the above device further comprises:

[0151] A cutting data acquisition device, used to acquire cutting data input by a user;

[0152] The optimization result determination unit is used to optimize the target edge-finding model according to the edge-finding result and the cutting data to obtain the optimization result.

[0153] In one embodiment, the data determination module 901 includes:

[0154] A data cleaning unit, used for performing data cleaning processing on the original image to obtain target cleaned data;

[0155] The data enhancement unit is used to perform data enhancement processing on the target cleaned data to obtain target image data.

[0156] In one embodiment, the data cleaning unit includes:

[0157] The data cleaning subunit is used to perform deduplication processing and noise filtering on the original image to obtain target cleaned data.

[0158] In one embodiment, the data enhancement unit includes:

[0159] The data enhancement subunit is used to perform at least one of rotation, scaling and contrast adjustment on the target cleaned data to obtain target image data.

[0160] Each module in the above-mentioned image edge finding device can be implemented in whole or in part by software, hardware or a combination thereof. Each module can be embedded in or independent of a processor in a computer device in the form of hardware, or can be stored in a memory in a computer device in the form of software, so that the processor can call and execute the operations corresponding to each module.

[0161] In one embodiment, a computer device is provided. The computer device may be a terminal, and its internal structure diagram may be as follows: Fig.10As shown. The computer device includes a processor, a memory, an input / output interface, a communication interface, a display unit and an input device. The processor, the memory and the input / output interface are connected through a system bus, and the communication interface, the display unit and the input device are connected to the system bus through the input / output interface. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The input / output interface of the computer device is used to exchange information between the processor and the external device. The communication interface of the computer device is used to communicate with an external terminal in a wired or wireless manner, and the wireless manner can be realized through WIFI, a mobile cellular network, NFC (near field communication) or other technologies. When the computer program is executed by the processor, an image edge finding method is realized. The display unit of the computer device is used to form a visually visible picture, which can be a display screen, a projection device or a virtual reality imaging device. The display screen can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer device can be a touch layer covering the display screen, or a button, trackball or touchpad set on the computer device shell, or an external keyboard, touchpad or mouse.

[0162] Those skilled in the art will understand that Fig.10 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.

[0163] In one embodiment, a computer device is provided, including a memory and a processor, wherein a computer program is stored in the memory, and when the processor executes the computer program, the following steps are implemented:

[0164] Performing data processing on the original image to obtain target image data;

[0165] The pre-built target edge-finding model is used to extract features from the target image data, and the category information and location information of the target object in the original image are determined based on the feature extraction results;

[0166] The edge search result is determined based on the category information and location information of the target object.

[0167] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:

[0168] Inputting the target image data into the feature extraction layer to perform multi-scale feature extraction processing to obtain a first feature map;

[0169] Inputting the first feature map into the region detection layer for region detection processing to obtain a second feature map corresponding to a plurality of candidate regions containing the target object;

[0170] Each second feature map is input into the classification layer for classification processing to obtain the image category and position information of the target object.

[0171] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:

[0172] Inputting the first feature map into a region proposal network for region detection processing to obtain multiple candidate regions containing target objects;

[0173] Each candidate region is input into the image processing network for resizing to obtain a plurality of second feature maps.

[0174] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:

[0175] The original image is cropped according to the position information to obtain a cropping result;

[0176] The labeling information is determined according to the image category of the target image.

[0177] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:

[0178] Acquire multiple training samples, each training sample including a training image and a category label and a position label corresponding to the training image;

[0179] The initial edge-finding model is trained based on multiple training samples to determine the target edge-finding model.

[0180] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:

[0181] Get the cropping data entered by the user;

[0182] According to the edge-finding results and cutting data, the target edge-finding model is optimized to obtain the optimized result.

[0183] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:

[0184] Perform data cleaning on the original image to obtain target cleaned data;

[0185] Perform data enhancement processing on the target cleaned data to obtain the target image data.

[0186] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:

[0187] The original image is deduplicated and noise filtered to obtain the target cleaned data.

[0188] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:

[0189] The target cleaning data is subjected to at least one of rotation, scaling and contrast adjustment to obtain target image data.

[0190] In one embodiment, a computer readable storage medium is provided, on which a computer program is stored, and when the computer program is executed by a processor, the following steps are implemented:

[0191] Performing data processing on the original image to obtain target image data;

[0192] The pre-built target edge-finding model is used to extract features from the target image data, and the category information and location information of the target object in the original image are determined based on the feature extraction results;

[0193] The edge search result is determined based on the category information and location information of the target object.

[0194] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:

[0195] Inputting the target image data into the feature extraction layer to perform multi-scale feature extraction processing to obtain a first feature map;

[0196] Inputting the first feature map into the region detection layer for region detection processing to obtain a second feature map corresponding to a plurality of candidate regions containing the target object;

[0197] Each second feature map is input into the classification layer for classification processing to obtain the image category and position information of the target object.

[0198] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:

[0199] Inputting the first feature map into a region proposal network for region detection processing to obtain multiple candidate regions containing target objects;

[0200] Each candidate region is input into the image processing network for resizing to obtain a plurality of second feature maps.

[0201] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:

[0202] The original image is cropped according to the position information to obtain a cropping result;

[0203] The labeling information is determined according to the image category of the target image.

[0204] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:

[0205] Acquire multiple training samples, each training sample including a training image and a category label and a position label corresponding to the training image;

[0206] The initial edge-finding model is trained based on multiple training samples to determine the target edge-finding model.

[0207] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:

[0208] Get the cropping data entered by the user;

[0209] According to the edge-finding results and cutting data, the target edge-finding model is optimized to obtain the optimized result.

[0210] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:

[0211] Perform data cleaning on the original image to obtain target cleaned data;

[0212] Perform data enhancement processing on the target cleaned data to obtain the target image data.

[0213] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:

[0214] The original image is deduplicated and noise filtered to obtain the target cleaned data.

[0215] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:

[0216] The target cleaning data is subjected to at least one of rotation, scaling and contrast adjustment to obtain target image data.

[0217] In one embodiment, a computer program product is provided, comprising a computer program, which, when executed by a processor, implements the following steps:

[0218] Performing data processing on the original image to obtain target image data;

[0219] The pre-built target edge-finding model is used to extract features from the target image data, and the category information and location information of the target object in the original image are determined based on the feature extraction results;

[0220] The edge search result is determined based on the category information and location information of the target object.

[0221] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:

[0222] Inputting the target image data into the feature extraction layer to perform multi-scale feature extraction processing to obtain a first feature map;

[0223] Inputting the first feature map into the region detection layer for region detection processing to obtain a second feature map corresponding to a plurality of candidate regions containing the target object;

[0224] Each second feature map is input into the classification layer for classification processing to obtain the image category and position information of the target object.

[0225] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:

[0226] Inputting the first feature map into a region proposal network for region detection processing to obtain multiple candidate regions containing target objects;

[0227] Each candidate region is input into the image processing network for resizing to obtain a plurality of second feature maps.

[0228] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:

[0229] The original image is cropped according to the position information to obtain a cropping result;

[0230] The labeling information is determined according to the image category of the target image.

[0231] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:

[0232] Acquire multiple training samples, each training sample including a training image and a category label and a position label corresponding to the training image;

[0233] The initial edge-finding model is trained based on multiple training samples to determine the target edge-finding model.

[0234] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:

[0235] Get the cropping data entered by the user;

[0236] According to the edge-finding results and cutting data, the target edge-finding model is optimized to obtain the optimized result.

[0237] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:

[0238] Perform data cleaning on the original image to obtain target cleaned data;

[0239] Perform data enhancement processing on the target cleaned data to obtain the target image data.

[0240] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:

[0241] The original image is deduplicated and noise filtered to obtain the target cleaned data.

[0242] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:

[0243] The target cleaning data is subjected to at least one of rotation, scaling and contrast adjustment to obtain target image data.

[0244] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant laws, regulations and standards of relevant countries and regions.

[0245] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. Non-relational databases may include distributed databases based on blockchains, etc., but are not limited to this. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., but are not limited to this.

[0246] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0247] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.

Claims

1. An image edge finding method, It is characterized in that The method comprises: Performing data processing on the original image to obtain target image data; Using a pre-built target edge-finding model to perform feature extraction on the target image data, and determining category information and location information of the target object in the original image according to the feature extraction result; An edge search result is determined according to the category information and location information of the target object.

2. The method according to claim 1, It is characterized in that The target edge-finding model includes a feature extraction layer, a region detection layer and a classification layer connected in sequence, and the region detection layer includes a region proposal network and an image processing network connected in sequence.

3. The method according to claim 2, It is characterized in that The step of extracting features from the target image data and determining category information and location information of the target object in the original image according to the feature extraction result includes: Inputting the target image data into the feature extraction layer to perform multi-scale feature extraction processing to obtain a first feature map; Inputting the first feature map into the region detection layer for region detection processing to obtain a second feature map corresponding to a plurality of candidate regions containing target objects; Each of the second feature maps is input into the classification layer for classification processing to obtain the image category and position information of the target object.

4. The method according to claim 3, It is characterized in that The step of inputting the first feature map into the region detection layer for region detection processing to obtain a plurality of second feature maps corresponding to candidate regions containing target objects comprises: Inputting the first feature map into the region proposal network for region detection processing to obtain multiple candidate regions containing the target object; Each of the candidate regions is input into the image processing network for resizing to obtain a plurality of the second feature maps.

5. The method according to claim 1, It is characterized in that The edge finding result includes a cutting result and marking information, and the determining the edge finding result according to the category information and the position information includes: Performing cropping processing on the original image according to the position information to obtain the cropping result; The labeling information is determined according to the image category of the target image.

6. The method according to any one of claims 1 to 5, It is characterized in that The method further comprises: Acquire multiple training samples, each of which includes a training image and a category label and a position label corresponding to the training image; The initial edge-finding model is trained based on the multiple training samples to determine the target edge-finding model.

7. The method according to claim 6, It is characterized in that The method further comprises: Get the cropping data entered by the user; The target edge-finding model is optimized according to the edge-finding result and the cutting data to obtain an optimization result.

8. The method according to claim 1, It is characterized in that The processing of the original image to obtain image data comprises: Performing data cleaning processing on the original image to obtain target cleaned data; Perform data enhancement processing on the target cleaned data to obtain the target image data.

9. The method according to claim 8, It is characterized in that The performing data cleaning processing on the original image to obtain target cleaned data includes: The original image is subjected to deduplication processing and noise filtering processing to obtain the target cleaned data.

10. The method according to claim 9, It is characterized in that The performing data enhancement processing on the target cleaned data to obtain the target image data includes: The target cleaning data is subjected to at least one of rotation, scaling and contrast adjustment to obtain the target image data.

11. An image edge finding device, It is characterized in that The device comprises: A data determination module is used to process the original image to obtain target image data; A category and position determination module, used to extract features from the target image data using a pre-built target edge-finding model, and determine category information and position information of the target object in the original image based on the feature extraction result; The result determination module is used to determine the edge search result according to the category information and location information of the target object.

12. A computer device comprising a memory and a processor, wherein the memory stores a computer program. It is characterized in that When the processor executes the computer program, the steps of the method according to any one of claims 1 to 10 are implemented.

13. A computer-readable storage medium having a computer program stored thereon, It is characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 10 are implemented.

14. A computer program product comprising a computer program, It is characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 10 are implemented.