Image Screening Method, Image Screening Device, Electronic Device and Storage Medium

By obtaining and analyzing the text areas and color differences of the pictures, we automatically filter out pictures suitable for secondary processing, which solves the problem of low manual screening accuracy, improves screening efficiency and accuracy, and improves the update efficiency and diversity of online malls and financial products.

CN117312593BActive Publication Date: 2025-07-22CHINA PING AN LIFE INSURANCE CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310839308.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-07-07
Publication Date
2025-07-22
Estimated Expiration
2043-07-07

AI Technical Summary

Technical Problem

In the prior art, the image screening method mainly relies on manual labor, resulting in poor screening accuracy and low efficiency, and it is impossible to efficiently screen out pictures suitable for secondary processing.

Method used

By obtaining the text content and location of the original picture, region division and difference detection are carried out, candidate pictures are selected using the color difference degree of text areas, and sort them, and provided to the image processing end for secondary processing.

Benefits of technology

It improves the accuracy and efficiency of image screening, can effectively screen out pictures suitable for secondary processing, reduce duplicate processing, improve product image update efficiency of online mall platforms, and enhance the diversity and transaction rate of financial products.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117312593B_ABST
    Figure CN117312593B_ABST
Patent Text Reader

Abstract

The present application provides a method and apparatus for image screening, an electronic device, and a storage medium, belonging to the technical field of fintech. The method includes: performing content recognition on an original image to obtain image text data, where the image text data includes text content and the text positions of the text content; dividing the text content into regions based on the text positions to obtain target regions, and the target regions are rectangular regions; obtaining regions adjacent to the target regions according to the edge coordinate data of the target regions to obtain adjacent regions; performing a difference detection on the adjacent regions and the target regions to obtain detection data, and the detection data is used to characterize the color difference degree between the adjacent regions and the target regions; filtering the original image according to the detection data to obtain candidate images; sorting the candidate images according to the detection data to obtain an image list; and the image list is used to be provided to an image processing terminal for secondary image processing. The present application can improve the accuracy and efficiency of image screening.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the technical field of fintech, and particularly to a method and apparatus for image screening, an electronic device, and a storage medium. Background Art

[0002] With the rapid development of the Internet and the continuous rise of e-commerce, online shopping has gradually become an indispensable part of people's lives. Currently, the number of goods on shopping websites is increasing rapidly every day.

[0003] Online mall platforms often need to update the images of the goods displayed, so that the images of the goods displayed on the online mall platform are consistent with the latest product information of the goods. If the images of all goods are updated one by one, it often takes a lot of time and cost. If the images that can be reprocessed can be screened out from the original product images for processing and updating, the update efficiency of the product images can be effectively improved.

[0004] Currently, when selecting images for reprocessing, it often takes a lot of time to screen the images. In related technologies, manual screening is often used to select images, which results in poor accuracy and low efficiency of image screening. Summary of the Invention

[0005] The main purpose of the embodiments of this application is to propose a method and apparatus for image screening, an electronic device, and a storage medium, aiming to improve the accuracy and efficiency of image screening.

[0006] To achieve the above object, in the first aspect of the embodiments of this application, a method for image screening is proposed, and the method includes:

[0007] Obtain an original image;

[0008] Perform content recognition on the original image to obtain image text data, where the image text data includes text content and the text position of the text content;

[0009] Based on the text position, divide the text content into regions to obtain target regions, where the target regions are rectangular regions;

[0010] According to the edge coordinate data of the target regions, obtain the regions adjacent to the target regions to obtain adjacent regions;

[0011] Perform difference detection on the adjacent regions and the target regions to obtain detection data, where the detection data is used to characterize the color difference degree between the adjacent regions and the target regions;

[0012] Filter the original image according to the detection data to obtain candidate images;

[0013] Sort the candidate images according to the detection data to obtain an image list; wherein, the image list is used to be provided to an image processing end for secondary image processing.

[0014] In some embodiments, the region division of the text content based on the text position to obtain a target region includes:

[0015] Perform region division on the text content according to the text position to obtain an initial region of the text content;

[0016] Perform magnification processing on the initial region according to preset parameters to obtain an intermediate region;

[0017] Detect the overlapping region between two intermediate regions to obtain region overlapping data;

[0018] If the region overlapping data indicates that there is an overlapping region between two intermediate regions, then perform region merging on the text content of the intermediate regions to obtain the target region.

[0019] In some embodiments, the performing region division on the text content according to the text position to obtain the initial region of the text content includes:

[0020] Determine the coordinate data of the edge characters of the text content according to a preset coordinate system and the text position;

[0021] Screen out the preliminary coordinate extreme values of the text content from the coordinate data, wherein the preliminary coordinate extreme values include the preliminary maximum value and the preliminary minimum value of the abscissa, and the preliminary maximum value and the preliminary minimum value of the ordinate;

[0022] Determine the initial region according to the preliminary maximum value and the preliminary minimum value of the abscissa, the preliminary maximum value and the preliminary minimum value of the ordinate.

[0023] In some embodiments, the detecting the overlapping region between two intermediate regions to obtain region overlapping data includes:

[0024] Obtain the edge coordinate data of each intermediate region;

[0025] If the edge coordinate data of the intermediate regions meet a preset condition, then the region overlapping data indicates that there is an overlapping region between two intermediate regions, wherein the preset condition is that the difference between the edge coordinate data is less than a preset first threshold.

[0026] In some embodiments, if the overlapping region data indicates that there is an overlapping region between the two intermediate regions, merging the text contents of the intermediate regions to obtain the target region includes:

[0027] For the text content of the intermediate region, determine the target coordinate extreme values according to the initial region of the text content, where the target coordinate extreme values include the target maximum value and the target minimum value of the abscissa, and the target maximum value and the target minimum value of the ordinate;

[0028] Determine the target region according to the target maximum value and the target minimum value of the abscissa, and the target maximum value and the target minimum value of the ordinate.

[0029] In some embodiments, the detection data includes first color difference data. Screening the original image according to the detection data to obtain candidate images includes:

[0030] Obtain the detection data of the original image to obtain the first color difference data;

[0031] Compare the first color difference data with a preset second threshold;

[0032] If the first color difference data is less than or equal to the second threshold, use the original image as the candidate image;

[0033] If the first color difference data is greater than the second threshold, store the original image in a preset image library.

[0034] In some embodiments, the detection data includes second color difference data. Sorting the candidate images according to the detection data to obtain a list of images includes:

[0035] Obtain the detection data of the candidate image to obtain the second color difference data;

[0036] Calculate the mean value of the second color difference data to obtain image recommendation data, where the image recommendation data is used to characterize the recommended priority of the candidate image;

[0037] Arrange the candidate images in ascending order based on the image recommendation data to obtain the list of images.

[0038] To achieve the above object, a second aspect of the embodiments of the present application proposes an image screening device, the device includes:

[0039] An image acquisition module, configured to acquire an original image;

[0040] A content recognition module, configured to perform content recognition on the original picture to obtain picture text data, where the picture text data includes text content and the text position of the text content;

[0041] A region division module, configured to perform region division on the text content based on the text position to obtain a target region, where the target region is a rectangular region;

[0042] An adjacent region determination module, configured to obtain an adjacent region adjacent to the target region according to the edge coordinate data of the target region, to obtain an adjacent region;

[0043] A difference detection module, configured to perform difference detection on the adjacent region and the target region to obtain detection data, where the detection data is used to characterize the color difference degree between the adjacent region and the target region;

[0044] A picture filtering module, configured to filter the original picture according to the detection data to obtain a candidate picture;

[0045] A picture sorting module, configured to sort the candidate pictures according to the detection data to obtain a picture list; where the picture list is used to be provided to a picture processing end for secondary picture processing.

[0046] To achieve the above object, a third aspect of the embodiments of the present application provides an electronic device, where the electronic device includes a memory and a processor, the memory stores a computer program, and when the processor executes the computer program, the method described in the first aspect above is implemented.

[0047] To achieve the above object, a fourth aspect of the embodiments of the present application provides a computer-readable storage medium, where the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method described in the first aspect above is implemented.

[0048] The image screening method, image screening device, electronic device, and storage medium proposed in this application obtain the original image; perform content recognition on the original image to obtain image text data, where the image text data includes text content and the text position of the text content; divide the text content into target regions based on the text position, and the target regions are rectangular regions. This method of dividing regions based on the text position can improve the accuracy of region division of the text content. Obtain the regions adjacent to the target region based on the edge coordinate data of the target region to get the adjacent regions; perform difference detection on the adjacent regions and the target region to obtain detection data, where the detection data is used to characterize the color difference degree between the adjacent regions and the target region, and can determine the overall color difference change of the original image according to the color difference change between regions; finally, filter the original image according to the detection data to obtain candidate images; sort the candidate images according to the detection data to obtain an image list; the image list is used to be provided to the image processing end for secondary processing of the image. This method uses the text position of the text region to divide the original image into multiple target regions, and filters and sorts the original image based on the color difference degree between the target region and the adjacent region, which can realize image screening based on region division and region color difference detection, is beneficial to improving the accuracy and screening efficiency of image screening, and then effectively screens out the images that can be directly processed for the second time, and only reprocesses the commodity images that cannot be processed for the second time, thereby effectively improving the update efficiency of the commodity images displayed on the online mall platform, is beneficial to the product replacement and product marketing on online trading platforms such as insurance products and financial products, can improve the diversity of financial products, and thus improve the transaction rate of financial products. BRIEF DESCRIPTION OF THE DRAWINGS

[0049] Figure 1 is a flowchart of the image screening method provided by an embodiment of the present application;

[0050] Figure 2A is a schematic diagram of an application scenario of the image screening method provided by an embodiment of the present application;

[0051] Figure 2B is another schematic diagram of an application scenario of the image screening method provided by an embodiment of the present application;

[0052] Figure 2C is another schematic diagram of an application scenario of the image screening method provided by an embodiment of the present application;

[0053] Figure 3 is Figure 1 a flowchart of step S103 in

[0054] Figure 4 is Figure 3 a flowchart of step S301 in

[0055] Figure 5 is Figure 3 the flowchart of step S303 in

[0056] Figure 6 is Figure 3 the flowchart of step S304 in

[0057] Figure 7 is Figure 1 the flowchart of step S106 in

[0058] Figure 8 is Figure 1 the flowchart of step S107 in

[0059] Figure 9 is the structural schematic diagram of the picture screening device provided by the embodiment of the present application;

[0060] Figure 10 is the hardware structural schematic diagram of the electronic device provided by the embodiment of the present application. Specific Embodiments

[0061] In order to make the objectives, technical solutions and advantages of the present application more clear and understandable, the present application will be further described in detail below with reference to 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.

[0062] It should be noted that although functional module division is performed in the device schematic diagram and the logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in a different order from the module division in the device or the order in the flowchart. Terms such as "first" and "second" in the specification, claims and the above-mentioned drawings are used to distinguish similar objects and do not necessarily need to describe a specific order or sequence.

[0063] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by those skilled in the technical field to which the present application belongs. The terms used herein are only for the purpose of describing the embodiments of the present application and are not intended to limit the present application.

[0064] First, several nouns involved in the present application are analyzed:

[0065] Artificial Intelligence (AI): It is a new technical science that studies and develops theories, methods, technologies, and application systems for simulating, extending, and expanding human intelligence; AI is a branch of computer science. AI attempts to understand the essence of intelligence and produce a new intelligent machine that can react in a way similar to human intelligence. The research in this field includes robots, speech recognition, image recognition, natural language processing, and expert systems, etc. AI can simulate the information process of human consciousness and thinking. AI also refers to the theory, method, technology, and application system that uses digital computers or machines controlled by digital computers to simulate, extend, and expand human intelligence, perceive the environment, acquire knowledge, and use knowledge to obtain the best results.

[0066] Natural Language Processing (NLP): NLP uses computers to process, understand, and apply human languages (such as Chinese, English, etc.). NLP is a branch of AI and an interdisciplinary field of computer science and linguistics, and is often referred to as computational linguistics. Natural language processing includes syntactic analysis, semantic analysis, discourse understanding, etc. Natural language processing is commonly used in technical fields such as machine translation, handwritten and printed character recognition, speech recognition and text-to-speech conversion, information intention recognition, information extraction and filtering, text classification and clustering, public opinion analysis, and opinion mining. It involves data mining, machine learning, knowledge acquisition, knowledge engineering, artificial intelligence research related to language processing, and linguistic research related to language computing, etc.

[0067] Information Extraction (NER): It is a text processing technology that extracts factual information such as entities, relationships, and events of a specified type from natural language texts and forms structured data output. Information extraction is a technology for extracting specific information from text data. Text data is composed of some specific units, such as sentences, paragraphs, and passages. Text information is exactly composed of some small specific units, such as characters, words, phrases, sentences, paragraphs, or combinations of these specific units. Extracting noun phrases, personal names, place names, etc. from text data are all text information extraction. Of course, the information extracted by text information extraction technology can be various types of information.

[0068] With the rapid development of the Internet and the continuous rise of e-commerce, online shopping has gradually become an indispensable part of people's lives. Currently, the number of goods on shopping websites is increasing sharply every day.

[0069] Online shopping mall platforms often need to update the images of the products displayed to make the product images displayed on the online shopping mall platform consistent with the latest product information of the products. If the product images of all products are updated one by one, it often takes a lot of time and cost. If it is possible to screen out the images that can be reprocessed from the original product images for processing and updating, the update efficiency of product pictures can be effectively improved.

[0070] For example, for a certain insurance product trading platform, the platform will display product images of different insurance products, and the product images contain information such as the type of insurance product and the duration. If the duration of Insurance Product A changes from 5 years to 10 years, the original product image of Insurance Product A can be directly reprocessed to change the duration from 5 years to 10 years, without having to re-make the product image, which can save time and cost. If the product form or multiple information of Insurance Product B changes, reprocessing the original product image of Insurance Product B often takes more time and cost than re-making the product image. Then, the original product image of Insurance Product B is excluded from the images for reprocessing, and the image of Insurance Product B displayed is updated by re-making the product image.

[0071] Currently, when selecting pictures for reprocessing, it often takes a lot of time to screen the pictures. In related technologies, manual screening is often used to select pictures, which results in poor accuracy and low screening efficiency of picture screening.

[0072] Based on this, the embodiments of the present application provide a picture screening method, a picture screening device, an electronic device, and a storage medium, aiming to improve the accuracy and screening efficiency of picture screening.

[0073] The picture screening method, device, electronic device, and storage medium provided by the embodiments of the present application are specifically described through the following embodiments. First, the picture screening method in the embodiments of the present application is described.

[0074] The embodiments of the present application can obtain and process relevant data based on artificial intelligence technology. Among them, artificial intelligence (AI) is a theory, method, technology, and application system that uses digital computers or machines controlled by digital computers to simulate, extend, and expand human intelligence, perceive the environment, acquire knowledge, and use knowledge to obtain the best results.

[0075] The basic technologies of artificial intelligence generally include technologies such as sensors, dedicated artificial intelligence chips, cloud computing, distributed storage, big data processing technologies, operation / interaction systems, and mechatronics. The software technologies of artificial intelligence mainly include several major directions such as computer vision technology, robotics, biometric technology, speech processing technology, natural language processing technology, and machine learning / deep learning.

[0076] The picture screening method provided by the embodiments of this application relates to the field of artificial intelligence technology. The picture screening method provided by the embodiments of this application can be applied to a terminal, or to a server side, or can also be software running on a terminal or a server side. In some embodiments, the terminal can be a smart phone, a tablet computer, a laptop computer, a desktop computer, etc.; the server side can be configured as an independent physical server, or can be configured as a server cluster or a distributed system composed of multiple physical servers, or can also be configured as a cloud server providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, CDN, and big data and artificial intelligence platforms; the software can be an application that implements the picture screening method, etc., but is not limited to the above forms.

[0077] This application can be used in many general or special computer system environments or configurations. For example: personal computers, server computers, handheld or portable devices, tablet devices, multi-processor systems, microprocessor-based systems, set-top boxes, programmable consumer electronic devices, network PCs, minicomputers, mainframe computers, distributed computing environments including any of the above systems or devices, and so on. This application can be described in the general context of computer-executable instructions executed by a computer, such as program modules. Generally, program modules include routines, programs, objects, components, data structures, etc. that perform specific tasks or implement specific abstract data types. This application can also be practiced in a distributed computing environment, where tasks are performed by remote processing devices connected through a communication network. In a distributed computing environment, program modules can be located in local and remote computer storage media including storage devices.

[0078] Figure 1 is an optional flowchart of the picture screening method provided by the embodiments of this application, Figure 1 The method in may include but is not limited to steps S101 to S107.

[0079] Step S101, obtain the original picture;

[0080] Step S102, perform content recognition on the original picture to obtain picture text data, where the picture text data includes text content and the text positions of the text content;

[0081] Step S103: Based on the text positions, divide the text content into regions to obtain target regions, where the target regions are rectangular regions.

[0082] Step S104: Obtain the regions adjacent to the target regions according to the edge coordinate data of the target regions to get adjacent regions.

[0083] Step S105: Perform difference detection on the adjacent regions and the target regions to obtain detection data, where the detection data is used to represent the color difference degree between the adjacent regions and the target regions.

[0084] Step S106: Filter the original image according to the detection data to obtain candidate images.

[0085] Step S107: Sort the candidate images according to the detection data to obtain an image list; the image list is used to be provided to the image processing end for secondary image processing.

[0086] Steps S101 to S107 shown in the embodiments of this application, by obtaining the original image; performing content recognition on the original image to obtain image text data, the image text data including the text content and the text positions of the text content; dividing the text content into regions based on the text positions to obtain target regions, the target regions being rectangular regions, this method of dividing regions based on text positions can improve the accuracy of region division of the text content, obtaining the adjacent regions according to the edge coordinate data of the target regions; performing difference detection on the adjacent regions and the target regions to obtain detection data, the detection data being used to represent the color difference degree between the adjacent regions and the target regions, can determine the overall color difference change of the original image according to the color difference change between regions; finally, filtering the original image according to the detection data to obtain candidate images; sorting the candidate images according to the detection data to obtain an image list; the image list is used to be provided to the image processing end for secondary image processing, this method uses the text positions of the text regions to divide the original image into multiple target regions, and filters and sorts the original image based on the color difference degree between the target regions and the adjacent regions, can achieve image screening based on region division and region color difference detection, which is beneficial to improving the accuracy and efficiency of image screening.

[0087] In step S101 of some embodiments, the original pictures can be obtained by photographing with a photographing device such as a camera, or a series of original pictures can be obtained by batch picture extraction from a preset picture library, or the original pictures can be obtained by downloading pictures from a network platform, and the like. The original pictures include pictures of different business scenarios and different types. For example, the original pictures can be pictures for product promotion, invitation letter pictures for exhibition invitations, and so on. The original pictures can contain various content data such as graphic content and text content.

[0088] In step S102 of some embodiments, the content of the original pictures can be recognized by using a preset optical character recognition algorithm (OCR) to obtain picture text data. Specifically, first, the original pictures are grayscale processed by using the optical character recognition algorithm to obtain the grayscale pictures corresponding to the original pictures, and the grayscale pictures are subjected to picture binarization processing to simplify the picture content and obtain binarized pictures. Based on the binarized pictures, content extraction is performed to obtain the text content of the original pictures. Further, the optical character algorithm is used to establish a two-dimensional coordinate system with the upper left corner of the original picture as the coordinate origin and the preset character length as the unit coordinate length. According to this two-dimensional coordinate system, the text position of the text content of the original picture is determined. The text position includes the character coordinates of each text content. For example, each character of the text content is used as a character block, and the character block is a rectangular area. According to the aforementioned two-dimensional coordinate system, the four endpoint coordinates of the rectangular area are used as the character coordinates of the character. For example, the character coordinates of a certain character "A" in the original picture include the upper left endpoint (x a1 , y a1 ), the lower left endpoint (x a1 , y a2 ), the upper right endpoint (x a2 , y a1 ), and the lower right endpoint (x a2 , y a2 ).

[0089] Please refer to Figure 2A -C and Figure 3 , in some embodiments, step S103 may include but is not limited to steps S301 to S304:

[0090] Step S301, according to the text position, divide the text content into regions to obtain the initial region of the text content;

[0091] Step S302, perform magnification processing on the initial region according to the preset parameters to obtain the intermediate region;

[0092] Step S303: Detect the overlapping area between the two intermediate areas to obtain area overlapping data;

[0093] Step S304: If the area overlapping data indicates that there is an overlapping area between the two intermediate areas, merge the text contents of the intermediate areas to obtain the target area.

[0094] In step S301 of some embodiments, according to the semantic continuity of the text content and the text positions of each character, the characters constituting continuous semantics are regarded as a whole, and the characters belonging to the same whole need to be divided into the same area. Further, when dividing the text content into areas, the text positions of the characters belonging to the same area are extracted. The text position includes the character coordinates of each character (i.e., the four endpoint coordinates of the rectangular area corresponding to each character). These series of character coordinates are compared in coordinates, and the coordinate extreme values among all the character coordinates are selected. The coordinate extreme values include the preliminary maximum value and the preliminary minimum value of the abscissa, the preliminary maximum value and the preliminary minimum value of the ordinate, and the horizontal and vertical coordinates are combined according to these four coordinate extreme values to form four coordinates, and a rectangular area is determined according to these four coordinates to obtain the initial area of the text content.

[0095] For example Figure 2A the initial area corresponding to the text content "Invitation Letter" in topleft1 is a rectangular area, and the four endpoint coordinates of this initial area are respectively (x topleft1 ), (x topright1 ), (x topright1 ), (x downleft1 ). downleft1 ). downright1 ), (x downright1 ).

[0096] The four endpoint coordinates of the initial area corresponding to the text content "XXX Forum" are respectively (x topleft2 ), (x topleft2 ), (x topright2 ), (x topright2 ). downleft2 ), (x downleft2 ), (x downright2 ), (x downright2 ).

[0097] The four endpoint coordinates of the initial area corresponding to the text content "INVITATION" are respectively (x topleft3 ), (x topleft3 ), (x topright3 ), (x topright3 ). downleft3 ), (x downleft3 ), (x downright3 ), (x downright3 ).

[0098] Among them, the endpoint coordinates of the initial area of each of the above text contents are represented by black circles.

[0099] In step S302 of some embodiments, the preset parameters can be set according to actual business requirements without limitation. For example, the preset parameter is delta, and the value of delta is not limited. For example, delta = 1. When the initial area is enlarged according to the preset parameter, the width and height of the initial area are expanded. Specifically, in the x-axis direction, the abscissas of the upper left endpoint and the lower left endpoint of the initial area are moved delta unit lengths towards the origin, and the abscissas of the upper right endpoint and the lower right endpoint of the initial area are moved delta unit lengths away from the origin; in the y-axis direction, the ordinates of the upper left endpoint and the upper right endpoint of the initial area are moved delta unit lengths towards the origin, and the ordinates of the lower left endpoint and the lower right endpoint of the initial area are moved delta unit lengths away from the origin, obtaining a new rectangular area, and the new rectangular area is used as the middle area of the text content.

[0100] For example Figure 2B the middle area corresponding to the text content "Invitation Letter" in topleft1 is a rectangular area, and the four endpoint coordinates of this middle area are respectively the upper left endpoint (x topleft1 -delta, y topright1 -delta), the upper right endpoint (x topright1 +delta, y downleft1 -delta), the lower left endpoint (x downleft1 -delta, y downright1 +delta), and the lower right endpoint (x downright1 +delta, y

[0101] The middle area corresponding to the text content "XXX Forum" is a rectangular area, and the four endpoint coordinates of this middle area are respectively the upper left endpoint (x topleft2 -delta, y topleft2 -delta), the upper right endpoint (x topright2 +delta, y topright2 -delta), the lower left endpoint (x downleft2 -delta, y doenleft2 +delta), and the lower right endpoint (x downright2 +delta, y downright2 +delta).

[0102] Among them, the endpoint coordinates of the middle region A, the middle region B, and the middle region C are represented by hollow circles.

[0103] In step S303 of some embodiments, when detecting the overlapping region between two middle regions, the horizontal and vertical coordinate values of the endpoint coordinates can be compared based on the endpoint coordinates of the middle regions. Specifically, the coordinate data of the endpoint coordinates of each middle region is extracted, and based on the coordinate data of the endpoint coordinates, the edge coordinate data of the middle region is determined. The edge coordinate data is the coordinate data of the two endpoints with the closest distance between the two middle regions. Coordinate difference calculation is performed based on the edge coordinate data. If the coordinate difference relationship of the horizontal and vertical coordinates of the middle region meets the preset conditions, it is determined that there is an overlapping region between the two middle regions.

[0104] For example Figure 2B the edge coordinate data between the middle region A corresponding to the text content "Invitation Letter" and the middle region B corresponding to the text content "XXX Forum" in downright1 is the coordinate data (x downright1 +delta, y topright2 +delta) of the lower right corner endpoint of the middle region A and the coordinate data (x topright2 +delta, y topright2 -delta) of the upper right corner endpoint of the middle region B. Then the preset condition is y topright2 -delta < y downright1 +delta, x topright2 +delta < x downright1 +delta, then there is an overlapping region between the two middle coordinates. Since the above middle region A and middle region B do not meet this preset condition, the region overlapping data is that there is no overlapping region between the middle region A and the middle region B.

[0105] In step S304 of some embodiments, if the region overlapping data indicates that there is an overlapping region between two middle regions, in order to improve the accuracy of picture screening, it is necessary to merge the text content of the middle regions to obtain the target region. Specifically, when merging the text content of the middle regions, the endpoint coordinate data of the initial regions of the two text contents can be obtained first, and the coordinate extreme values among all the endpoint coordinate data are determined based on the endpoint coordinate data to obtain the target coordinate extreme values. Among them, the target coordinate extreme values include the target maximum value and the target minimum value of the horizontal coordinate, and the target maximum value and the target minimum value of the vertical coordinate. Finally, horizontal and vertical coordinate combinations are performed based on these four coordinate extreme values to form four coordinates, and a rectangular region is determined based on these four coordinates to obtain the target region of the text content.

[0106] Through the above steps S301 to S304, it is possible to more conveniently divide the area of each text content, so that each text content forms an initial area, and detect whether there is area overlap according to the distance of each text content area, and frame the text content with area overlap in the same target area, thereby improving the accuracy of the area division of the text content and helping to improve the accuracy of picture screening.

[0107] Please refer to Figure 2A and Figure 4 , in some embodiments, step S301 may include but is not limited to steps S401 to S403:

[0108] Step S401, according to the preset coordinate system and the text position, determine the coordinate data of the edge characters of the text content;

[0109] Step S402, screen out the preliminary coordinate extreme values of the text content from the coordinate data, where the preliminary coordinate extreme values include the preliminary maximum value and the preliminary minimum value of the abscissa, and the preliminary maximum value and the preliminary minimum value of the ordinate;

[0110] Step S403, determine the initial area according to the preliminary maximum value and the preliminary minimum value of the abscissa, and the preliminary maximum value and the preliminary minimum value of the ordinate.

[0111] In step S401 of some embodiments, according to the semantic continuity of the text content and the text position of each character, the characters constituting continuous semantics are regarded as a whole, and the characters belonging to the same whole need to be divided into the same area. Further, when dividing the area of the text content, the text positions of the characters belonging to the same area are extracted, and the text position includes the character coordinates of each character (that is, the four endpoint coordinates of the rectangular area corresponding to each character).

[0112] In step S402 of some embodiments, the coordinate comparison of this series of character coordinates is performed, and the coordinate extreme values among all character coordinates are selected, and the coordinate extreme values include the preliminary maximum value and the preliminary minimum value of the abscissa, and the preliminary maximum value and the preliminary minimum value of the ordinate

[0113] In step S403 of some embodiments, according to these four coordinate extreme values, horizontal and vertical coordinate combinations are formed to form four coordinates, and a rectangular area is determined according to these four coordinates to obtain the initial area of the text content.

[0114] For example Figure 2A the initial area corresponding to the text content "Invitation Letter" in is a rectangular area, and the four endpoint coordinates of this initial area are respectively (x topleft1 , y topleft1 ), (x topright1 , y topright1), (x downleft1 , y downleft1 ), (x downright1 , y downright1 )。

[0115] The four endpoint coordinates of the initial region corresponding to the text content "INVITATION" are respectively (x topleft3 , y topleft3 ), (x topright3 , y topright3 ), (x downleft3 , y downleft3 ), (x downright3 , y downright3 ).

[0116] Through the above steps S401 to S403, it is relatively convenient to divide the region for each text content, so that each text content forms an initial region, and the color difference change of the picture can be detected in units of the region, and the picture can be screened according to the color difference change, and the pictures suitable for secondary processing can be selected, which can improve the picture screening efficiency and the picture screening accuracy.

[0117] Please refer to Figure 2B and Figure 5 , in some embodiments, step S303 may include but is not limited to steps S501 to S502:

[0118] Step S501, obtaining the edge coordinate data of each intermediate region;

[0119] Step S502, if the preset condition is satisfied among the edge coordinate data of the intermediate regions, the region overlap data indicates that there is an overlapping region between the two intermediate regions, where the preset condition is that the difference between the edge coordinate data is less than a preset first threshold.

[0120] In step S501 of some embodiments, when detecting the overlapping region between two intermediate regions, the horizontal and vertical coordinate values of the endpoint coordinates can be compared based on the endpoint coordinates of the intermediate regions. Specifically, the coordinate data of the endpoint coordinates of each intermediate region is extracted, and based on the coordinate data of the endpoint coordinates, the edge coordinate data of the intermediate region is determined, and the edge coordinate data is the coordinate data of the two endpoints with the closest distance between the two intermediate regions.

[0121] In step S502 of some embodiments, according to the edge coordinate data, the coordinate difference calculation is performed. If the coordinate difference relationship of the horizontal and vertical coordinates of the intermediate region satisfies the preset condition, it is determined that there is an overlapping region between the two intermediate regions. Among them, the preset condition is that the difference between the edge coordinate data is less than a preset first threshold.

[0122] For exampleFigure 2B The middle area corresponding to the Chinese text "Invitation Letter" is a rectangular area, and the four endpoint coordinates of this middle area are the upper left endpoint (x topleft1 -delta, y topleft1 -delta), the upper right endpoint (x topright1 +delta, y topright1 -delta), the lower left endpoint (x downleft1 -delta, y downleft1 +delta), and the lower right endpoint (x downright1 +delta, y downrighe1 +delta).

[0123] The four endpoint coordinates of the middle area corresponding to the text "INVITATION" are the upper left endpoint (x topleft3 -delta, y topleft3 -delta), the upper right endpoint (x topright3 +delta, y topright3 +delta), the lower left endpoint (x downleft3 -delta, y downleft3 +delta), and the lower right endpoint (x downright3 +delta, y downright3 +delta).

[0124] For example Figure 2B the edge coordinate data between the middle area A corresponding to the text "Invitation Letter" and the middle area C corresponding to the text "INVITATION" in is the coordinate data of the lower right endpoint of the middle area A (x downright1 +delta, y downright1 +delta) and the coordinate data of the upper left endpoint of the middle area C (x topleft3 -delta, y topleft3 -delta). Then the preset condition is y topleft3 -delta < y downright1 +delta, x topleft3 -delta < x downright1 +delta. That is, there is an overlapping area between the two middle coordinates, that is, the preset condition is that the difference in the abscissa and the difference in the ordinate are both less than twice delta. Since the above middle area A and middle area C satisfy this preset condition, the area overlapping data is that there is an overlapping area between the middle area A and the middle area C.

[0125] Among them, the endpoint coordinates of the middle area A, the middle area B, and the middle area C are marked with hollow circles.

[0126] Through the above steps S501 to S502, it is possible to relatively conveniently extract the endpoint coordinates of the two closest intermediate regions, and determine whether there is an overlapping region between the two intermediate regions by comparing the differences based on the endpoint coordinates. It is possible to detect the positional relationship between the two text contents in a numerically quantifiable form, improving the accuracy of region overlap detection, enabling the text contents to be regionally merged according to the proximity of the positions of the two text contents, so as to improve the accuracy of image screening.

[0127] Please refer to Figure 6 , in some embodiments, step S304 includes but is not limited to steps S601 to S602:

[0128] Step S601, for the text content of the intermediate region, determine the target coordinate extreme values according to the initial region of the text content, where the target coordinate extreme values include the target maximum value and the target minimum value of the abscissa, and the target maximum value and the target minimum value of the ordinate;

[0129] Step S602, determine the target region according to the target maximum value and the target minimum value of the abscissa, and the target maximum value and the target minimum value of the ordinate.

[0130] In step S601 of some embodiments, if the region overlap data indicates that there is an overlapping region between the two intermediate regions, in order to improve the accuracy of image screening, it is necessary to regionally merge the text contents of the intermediate regions to obtain the target region. Specifically, when regionally merging the text contents of the intermediate regions, the endpoint coordinate data of the initial regions of the two text contents can be obtained first, and the coordinate extreme values in all the endpoint coordinate data can be determined according to the endpoint coordinate data to obtain the target coordinate extreme values, where the target coordinate extreme values include the target maximum value and the target minimum value of the abscissa, and the target maximum value and the target minimum value of the ordinate.

[0131] In step S602 of some embodiments, perform horizontal and vertical coordinate combinations according to these four coordinate extreme values to form four coordinates, and determine a rectangular region according to these four coordinates to obtain the target region of the text content.

[0132] For example Figure 2A the text content "Invitation Letter" in topleft1 , y topleft1 ), (x topright1 , y topright1 ), (x downleft1 , y downleft1 ), (x downright1 , y downright1 ).

[0133] The four endpoint coordinates of the initial region corresponding to the text content "INVITATION" are respectively (x topleft3 , y topleft3 ), (x topright3 , y topright3 ), (x downleft3 , y downleft3 ), (x downright3 , y downright3 ).

[0134] Since there is an overlapping region (as shown in Figure 2C ) between the middle region A corresponding to the text content "Invitation Letter" and the middle region C corresponding to the text content "INVITATION", it is necessary to merge the regions of the text content "Invitation Letter" and the text content "INVITATION". According to the above method, the target coordinate extrema of the endpoint coordinate data of the initial regions of these two text contents are: the target minimum value of the abscissa x topleft1 , the target maximum value of the abscissa x downleft3 , the target minimum value of the ordinate y topleft1 , the target maximum value of the ordinate y downright3 , that is, the endpoint coordinates of the target region are (x topleft1 , y topleft1 ), (x topleft1 , y downright3 ), (x downleft3 , y topleft1 ), (x downleft3 , y downright3 ). The target region can be represented as shown in Figure 2C , where the endpoint coordinates of the target region are represented by hollow triangles.

[0135] By the above steps S601 to S602, it is possible to more conveniently merge the regions of adjacent text contents, improve the rationality of region division, and contribute to improving the accuracy of image detection and image screening based on regions.

[0136] Please refer to Figure 2C, in step S104 of some embodiments, when obtaining the regions adjacent to the target region based on the edge coordinate data of the target region to obtain the adjacent regions, first obtain the coordinate data of the endpoint coordinates of the target region, use the coordinate data of the endpoint coordinates as the edge coordinate data, and then perform coordinate calculations based on the edge coordinate data and preset parameters. Subtract a preset parameter from the ordinate values of the upper left endpoint coordinate and the upper right endpoint coordinate of the target region to obtain two coordinate points, and use the rectangular region formed by these two coordinate points, the upper left endpoint coordinate, and the upper right endpoint coordinate as the first adjacent region; subtract a preset parameter from the abscissa values of the upper left endpoint coordinate and the lower left endpoint coordinate of the target region to obtain two coordinate points, and use the rectangular region formed by these two coordinate points, the upper left endpoint coordinate, and the lower left endpoint coordinate as the second adjacent region; add a preset parameter to the abscissa values of the upper right endpoint coordinate and the lower right endpoint coordinate of the target region to obtain two coordinate points, and use the rectangular region formed by these two coordinate points, the upper right endpoint coordinate, and the lower right endpoint coordinate as the third adjacent region; add a preset parameter to the ordinate values of the lower left endpoint coordinate and the lower right endpoint coordinate of the target region to obtain two coordinate points, and use the rectangular region formed by these two coordinate points, the lower left endpoint coordinate, and the lower right endpoint coordinate as the fourth adjacent region.

[0137] For example Figure 2C in, the first adjacent region, the second adjacent region, the third adjacent region, and the fourth adjacent region of the target region formed by the text content "invitation letter" and "INVITATION" are distributed around the target region.

[0138] In step S105 of some embodiments, a preset image edge detection algorithm can be used to perform differential detection on the adjacent regions and the target region to obtain detection data. Among them, the preset image edge detection algorithm can be the Sobel image edge detection algorithm, etc. Taking the Sobel image edge detection algorithm as an example, based on the change of the derivative to detect the color difference degree between the adjacent region and the target region to obtain the detection data. The color difference degree can be represented by the Sobel score. The derivative can be selected from first-order derivative operators such as prewitt, sobel, and canny or second-order derivative operators such as lapacian, without limitation. Use the Sobel image edge detection algorithm to calculate the gray-scale approximation value of the pixel points of the adjacent region and the target region, and use the gray-scale approximation value as the Sobel score (i.e., the detection data). Since the derivative is an index reflecting the numerical change, the greater the derivative between the adjacent region and the target region, the greater the difference between the adjacent region and the target region, that is, there is a sharp color change between the adjacent region and the target region. Therefore, according to the detection data, the color difference degree between the adjacent region and the target region can be clearly obtained, and the detection accuracy of the color difference change of the picture can be improved.

[0139] Please refer to Figure 7 , in some embodiments, the detection data includes first color difference data, and step S106 may include but is not limited to steps S701 to S704:

[0140] Step S701, obtain the detection data of the original picture to obtain the first color difference data;

[0141] Step S702, compare the first color difference data with a preset second threshold;

[0142] Step S703, if the first color difference data is less than or equal to the second threshold, then use the original picture as a candidate picture;

[0143] Step S704, if the first color difference data is greater than the second threshold, then store the original picture in a preset picture library.

[0144] In step S701 of some embodiments, the detection data includes the color difference data between each adjacent area of each original picture and its corresponding target area, and the total color difference data of the original picture used to characterize the overall color difference degree of each target area. Among them, the first color difference data is the color difference data between each adjacent area of the original picture and its corresponding target area. The detection data of the original picture can be obtained directly through methods such as calling a preset script program or a preset interface to obtain the first color difference data.

[0145] In step S702 of some embodiments, the preset second threshold can be set according to actual business requirements without limitation. By comparing the first color difference data with the preset second threshold, according to the size relationship between the first color difference data and the preset second threshold, it can be clearly determined whether the color difference degree between each adjacent area and the corresponding target area meets the picture selection conditions. The larger the first color difference data, the greater the color change between the adjacent area and the corresponding target area. When the original picture is reprocessed, the reprocessing marks of this text area will be more obvious.

[0146] In step S703 of some embodiments, if the first color difference data is less than or equal to the second threshold, it indicates that the color change between each adjacent area of the original picture and the corresponding target area is small, meeting the requirements for reprocessing the original picture. Based on this original picture for reprocessing, the reprocessing marks of this original picture will not be too obvious. Therefore, the original picture can be used as a candidate picture, and the candidate picture can be used for picture reprocessing.

[0147] In step S704 of some embodiments, if the first color difference data is greater than the second threshold, it indicates that the color change between the adjacent region and the corresponding target region is large, that is, there is a too large color change between the adjacent region and the corresponding target region in the original picture. If secondary processing is performed based on this original picture, the secondary processing traces of the original picture will be relatively obvious, and this original picture is not suitable for picture secondary processing. Therefore, the original picture is stored in a preset picture library, and a non-whitelist mark is made on the original picture.

[0148] Through the above steps S701 to S704, it is possible to determine the color difference situation between each adjacent region and the corresponding target region based on the size relationship between the first color difference data and the second threshold, and determine whether there are target regions in the original picture that are not suitable for secondary processing according to the color difference situation, so as to select the original pictures suitable for secondary processing as candidate pictures, and store the original pictures not suitable for secondary processing in a preset picture library and perform picture marking, so as to perform repeated judgment on the original pictures, which is beneficial to improving the reusability of picture data and can improve the efficiency and accuracy of picture screening.

[0149] Please refer to Figure 8 , in some embodiments, the detection data includes second color difference data, and step S107 may include but is not limited to steps S801 to S803:

[0150] Step S801, obtain the detection data of the candidate picture to obtain the second color difference data;

[0151] Step S802, perform a mean calculation on the second color difference data to obtain picture recommendation data, where the picture recommendation data is used to characterize the recommended priority degree of the candidate picture;

[0152] Step S803, perform an ascending order arrangement on the candidate pictures based on the picture recommendation data to obtain a picture list.

[0153] In step S801 of some embodiments, since the detection data includes the total color difference data used to characterize the overall color difference degree of each target region, therefore, the detection data of the candidate picture can be directly obtained from the detection data by means of a preset script program or a preset interface call, etc., to obtain the second color difference data. This second color difference data is the total color difference data of each target region of the candidate picture, and can be obtained by summing the first color difference data of all adjacent regions of the target region.

[0154] In step S802 of some embodiments, when calculating the mean value of the second color difference data to obtain the picture recommendation data, first, the number of regions in the target region of the original picture is counted to obtain the total number of regions. Then, the second color difference data of all target regions are summed up, and the sum result is divided by the total number of regions to obtain the average color difference data of the original picture. This average color difference data is used as the picture recommendation data, where the picture recommendation data is used to represent the recommendation priority of the candidate picture. It should be noted that the smaller the average color difference data, the smaller the overall color difference change of the candidate picture, and the more the candidate picture meets the requirements of picture secondary processing.

[0155] In step S803 of some embodiments, since the larger the picture recommendation data, the larger the overall color difference change of the candidate picture, and the more difficult it is to perform picture secondary processing using the candidate picture. Therefore, according to the picture recommendation data, candidate pictures with smaller picture recommendation data can be preferentially selected for secondary processing. Therefore, the candidate pictures are sorted in ascending order based on the picture recommendation data to obtain a picture list, and the picture list is provided to the picture processing end for picture secondary processing, so that the candidate pictures at the front can be preferentially selected, which is beneficial to improving the difficulty of picture secondary processing and the efficiency of picture secondary processing.

[0156] Through the above steps S801 to S803, it is relatively convenient to determine the order of picture processing from multiple candidate pictures, further improving the accuracy of picture screening. It can enable the picture processing end to preferentially select candidate pictures that are easy to process, and improve the efficiency of picture screening and picture secondary processing.

[0157] The image screening method of the embodiment of the present application obtains an original image; performs content recognition on the original image to obtain image text data, wherein the image text data includes text content and text position of the text content; performs region division on the text content based on the text position to obtain a target region, wherein the target region is a rectangular region. This method performs region division based on the text position and can improve the accuracy of region division of the text content; obtains a region adjacent to the target region based on edge coordinate data of the target region and obtains an adjacent region; performs difference detection on the adjacent region and the target region and obtains detection data, wherein the detection data is used to characterize the degree of color difference between the adjacent region and the target region, and can determine the overall color difference change of the original image based on the color difference change between the regions; finally, filters the original image based on the detection data to obtain a candidate image. The candidate images are sorted according to the detection data to obtain a picture list; the picture list is used to provide the picture processing end for secondary processing of the picture. This method uses the text position in the text area to divide the original picture into multiple target areas, and filters and sorts the original picture based on the color difference between the target area and the adjacent area. It can realize picture screening based on area division and regional color difference detection, which is conducive to improving the accuracy and efficiency of picture screening, and then effectively screen out pictures that can be directly processed for secondary processing, and only reprocess the product images that cannot be processed for secondary processing, thereby effectively improving the updating efficiency of product images displayed on the online shopping mall platform, which is conducive to product replacement and product marketing on online trading platforms such as insurance products and financial products, and can improve the diversity of financial products, thereby improving the transaction rate of financial products.

[0158] See also Figure 9 The embodiment of the present application also provides a picture screening device, which can implement the above picture screening method, and the device includes:

[0159] Image acquisition module 901, used to acquire original images;

[0160] The content recognition module 902 is used to perform content recognition on the original image to obtain image text data, wherein the image text data includes text content and text position of the text content;

[0161] The area division module 903 is used to divide the text content into areas based on the text position to obtain a target area, wherein the target area is a rectangular area;

[0162] The adjacent region determining module 904 is used to obtain the region adjacent to the target region according to the edge coordinate data of the target region, thereby obtaining the adjacent region;

[0163] The difference detection module 905 is used to perform difference detection on the adjacent area and the target area to obtain detection data, wherein the detection data is used to characterize the degree of color difference between the adjacent area and the target area;

[0164] An image filtering module 906 is configured to filter the original image according to the detection data to obtain candidate images;

[0165] An image sorting module 907 is configured to sort the candidate images according to the detection data to obtain an image list; wherein, the image list is used to be provided to an image processing end for secondary image processing.

[0166] The specific implementation manner of this image screening device is basically the same as the specific embodiments of the above-mentioned image screening method, and will not be elaborated here.

[0167] An embodiment of this application further provides an electronic device, which includes: a memory, a processor, a program stored on the memory and executable on the processor, and a data bus for implementing connection communication between the processor and the memory. When the program is executed by the processor, the above-mentioned image screening method is implemented. This electronic device can be any intelligent terminal including a tablet computer, an in-vehicle computer, etc.

[0168] Please refer to Figure 10 , Figure 10 , which shows the hardware structure of an electronic device in another embodiment. The electronic device includes:

[0169] A processor 1001, which can be implemented in a general-purpose CPU (Central Processing Unit), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits, etc., and is used to execute relevant programs to implement the technical solutions provided by the embodiments of this application;

[0170] A memory 1002, which can be implemented in the form of a read-only memory (ROM), a static storage device, a dynamic storage device, or a random access memory (RAM), etc. The memory 1002 can store an operating system and other application programs. When implementing the technical solutions provided by the embodiments of this specification through software or firmware, the relevant program codes are stored in the memory 1002 and are called by the processor 1001 to execute the image screening method of the embodiments of this application;

[0171] An input / output interface 1003 is used to implement information input and output;

[0172] A communication interface 1004 is used to implement communication interaction between this device and other devices, and can implement communication through a wired manner (such as USB, network cable, etc.) or through a wireless manner (such as a mobile network, WIFI, Bluetooth, etc.);

[0173] The bus 1005 transmits information among various components of the device (such as the processor 1001, the memory 1002, the input / output interface 1003, and the communication interface 1004).

[0174] Among them, the processor 1001, the memory 1002, the input / output interface 1003, and the communication interface 1004 achieve communication connections with each other inside the device through the bus 1005.

[0175] The embodiment of the present application also provides a computer-readable storage medium. The computer-readable storage medium stores one or more programs, and the one or more programs can be executed by one or more processors to implement the above-mentioned picture screening method.

[0176] As a non-transitory computer-readable storage medium, the memory can be used to store non-transitory software programs and non-transitory computer-executable programs. In addition, the memory can include high-speed random access memory, and can also include non-transitory memory, such as at least one magnetic disk storage device, a flash memory device, or other non-transitory solid-state storage devices. In some embodiments, the memory optionally includes a memory remotely disposed relative to the processor, and these remote memories can be connected to the processor through a network. Examples of the above-mentioned network include but are not limited to the Internet, an enterprise intranet, a local area network, a mobile communication network, and combinations thereof.

[0177] The picture screening method, picture screening device, electronic device, and computer-readable storage medium provided by the embodiments of the present application obtain the original picture; perform content recognition on the original picture to obtain picture text data, where the picture text data includes text content and the text position of the text content; divide the text content into target regions based on the text position, and the target regions are rectangular regions. This method of dividing regions based on the text position can improve the accuracy of region division of the text content. Obtain the adjacent regions adjacent to the target regions according to the edge coordinate data of the target regions; perform difference detection on the adjacent regions and the target regions to obtain detection data, where the detection data is used to characterize the color difference degree between the adjacent regions and the target regions, and can determine the overall color difference change of the original picture according to the color difference change between the regions; finally, filter the original picture according to the detection data to obtain candidate pictures; sort the candidate pictures according to the detection data to obtain a picture list; the picture list is used to be provided to the picture processing end for secondary processing of the pictures. This method uses the text positions of the text regions to divide the original picture into multiple target regions, and filters and sorts the original picture based on the color difference degree between the target regions and the adjacent regions, which can realize picture screening based on region division and region color difference detection, is beneficial to improving the accuracy and screening efficiency of picture screening, and then effectively screens out the pictures that can be directly subjected to secondary processing, and only reprocesses the commodity images that cannot be subjected to secondary processing, thereby effectively improving the update efficiency of the commodity images displayed on the online shopping mall platform, is beneficial to the product iteration and product marketing on online trading platforms such as insurance products and financial products, can increase the diversity of financial products, and thus increase the transaction rate of financial products.

[0178] The embodiments described in the embodiments of the present application are for more clearly explaining the technical solutions of the embodiments of the present application, and do not constitute a limitation on the technical solutions provided by the embodiments of the present application. Those skilled in the art know that with the evolution of technology and the emergence of new application scenarios, the technical solutions provided by the embodiments of the present application are also applicable to similar technical problems.

[0179] Those skilled in the art can understand that Figure 1-7 the technical solutions shown in do not constitute a limitation on the embodiments of the present application, and may include more or fewer steps than shown in the figure, or combine some steps, or different steps.

[0180] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separated, that is, they may be located in one place, or may be distributed to multiple network units. Some or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0181] Those of ordinary skill in the art will understand that all or some of the steps in the methods disclosed above, and the functional modules / units in the systems and devices, can be implemented as software, firmware, hardware, or a suitable combination thereof.

[0182] As used in the specification of this application and the above-mentioned drawings, the terms "first", "second", "third", "fourth", etc. (if any) are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged under appropriate circumstances so that the embodiments of this application described herein can be implemented in an order different from those illustrated or described herein. In addition, the terms "comprising" and "having" and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or device that comprises a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units not clearly listed or inherent to these processes, methods, products, or devices.

[0183] It should be understood that in this application, "at least one (item)" means one or more, and "a plurality" means two or more. "And / or" is used to describe the association relationship of associated objects and indicates that there can be three relationships. For example, "A and / or B" can mean: only A exists, only B exists, and both A and B exist at the same time. Among them, A and B can be singular or plural. The character " / " generally means that the associated objects before and after are in an "or" relationship. "At least one (one) of the following" or a similar expression means any combination of these items, including any combination of single items (ones) or plural items (ones). For example, at least one (one) of a, b, or c can mean: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, and c can be single or multiple.

[0184] In the several embodiments provided in this application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the above-mentioned unit division is only a logical function division, and there can be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the displayed or discussed coupling or direct coupling or communication connection to each other can be through some interfaces, and the indirect coupling or communication connection of the devices or units can be in an electrical, mechanical, or other form.

[0185] The units described above as separate components may or may not be physically separated. The components shown as units may or may not be physical units, that is, they may be located in one place or distributed over multiple network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0186] In addition, each functional unit in various embodiments of the present application may be integrated into a processing unit, may exist separately as individual physical units, or two or more units may be integrated into one unit. The above-mentioned integrated units can be implemented in the form of hardware or in the form of software functional units.

[0187] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application, in essence, or the part that contributes to the prior art, or all or part of this technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes multiple instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods in various embodiments of the present application. The foregoing storage medium includes: USB flash drives, mobile hard disks, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical discs and other various media that can store programs.

[0188] The preferred embodiments of the embodiments of the present application have been described above with reference to the accompanying drawings, but this does not limit the scope of the rights of the embodiments of the present application. Any modifications, equivalent replacements, and improvements made by those skilled in the art without departing from the scope and essence of the embodiments of the present application shall fall within the scope of the rights of the embodiments of the present application.

Claims

1. A method for image screening, characterized in that, The method includes: Obtain the original image; Perform content recognition on the original image to obtain image text data, where the image text data includes text content and the text position of the text content; Based on the text position, divide the text content into regions to obtain target regions, where the target regions are rectangular regions; Obtain the regions adjacent to the target regions according to the edge coordinate data of the target regions to obtain adjacent regions; Perform difference detection on the adjacent regions and the target regions to obtain detection data, where the detection data is used to characterize the color difference degree between the adjacent regions and the target regions, and the detection data includes first color difference data and second color difference data; Filter the original image according to the detection data to obtain candidate images; Sort the candidate images according to the detection data to obtain an image list; where the image list is used to be provided to an image processing end for secondary image processing; The dividing the text content into regions based on the text position to obtain target regions includes: According to the text position, divide the text content into regions to obtain the initial regions of the text content; perform magnification processing on the initial regions according to preset parameters to obtain intermediate regions; perform overlapping region detection between the two intermediate regions to obtain region overlapping data; if the region overlapping data indicates that there is an overlapping region between the two intermediate regions, then merge the text content of the intermediate regions to obtain the target regions; The filtering the original image according to the detection data to obtain candidate images includes: if the first color difference data is less than or equal to a preset second threshold, then use the original image as the candidate image; The sorting the candidate images according to the detection data to obtain an image list includes: Obtain the detection data of the candidate images to obtain the second color difference data; perform mean calculation on the second color difference data to obtain image recommendation data, where the image recommendation data is used to characterize the recommended priority degree of the candidate images; perform ascending sorting on the candidate images based on the image recommendation data to obtain the image list.

2. The picture screening method according to claim 1, characterized in that The dividing the text content into regions according to the text position to obtain the initial regions of the text content includes: Determine the coordinate data of the edge characters of the text content according to a preset coordinate system and the text position; Screen out the preliminary coordinate maximum and minimum values of the text content from the coordinate data, where the preliminary coordinate maximum and minimum values include the preliminary maximum value and preliminary minimum value of the abscissa, and the preliminary maximum value and preliminary minimum value of the ordinate; Determine the initial regions according to the preliminary maximum value and preliminary minimum value of the abscissa, the preliminary maximum value and preliminary minimum value of the ordinate; 3. The picture screening method according to claim 1, wherein The performing overlapping region detection between the two intermediate regions to obtain region overlapping data includes: Obtain the edge coordinate data of each intermediate region; If the edge coordinate data in the middle region satisfy a preset condition, the region overlap data indicates that there is an overlapping region between the two middle regions, where the preset condition is that the difference between the edge coordinate data is less than a preset first threshold.

4. The picture screening method according to claim 1, wherein If the region overlap data indicates that there is an overlapping region between the two middle regions, then the text content of the middle regions is merged by region to obtain the target region, including: For the text content of the middle regions, according to the initial region of the text content, the target coordinate extreme values are determined, where the target coordinate extreme values include the target maximum value and the target minimum value of the abscissa, and the target maximum value and the target minimum value of the ordinate; According to the target maximum value and the target minimum value of the abscissa, and the target maximum value and the target minimum value of the ordinate, the target region is determined.

5. The picture screening method according to claim 1, wherein The detection data includes first color difference data. Filtering the original image according to the detection data to obtain a candidate image includes: Obtaining the detection data of the original image to obtain the first color difference data; Comparing the first color difference data with a preset second threshold; If the first color difference data is less than or equal to the second threshold, then taking the original image as the candidate image; If the first color difference data is greater than the second threshold, then storing the original image in a preset image library.

6. An image screening device, characterized in that, The device includes: An image acquisition module, configured to acquire an original image; A content recognition module, configured to perform content recognition on the original image to obtain image text data, where the image text data includes text content and the text position of the text content; A region division module, configured to divide the text content by region based on the text position to obtain a target region, where the target region is a rectangular region; An adjacent region determination module, configured to obtain a region adjacent to the target region according to the edge coordinate data of the target region to obtain an adjacent region; A difference detection module, configured to perform difference detection on the adjacent region and the target region to obtain detection data, where the detection data is used to characterize the color difference degree between the adjacent region and the target region, and the detection data includes first color difference data and second color difference data; An image filtering module, configured to filter the original image according to the detection data to obtain a candidate image; An image sorting module, configured to sort the candidate images according to the detection data to obtain an image list; where the image list is used to be provided to an image processing terminal for secondary image processing; Dividing the text content by region based on the text position to obtain a target region includes: Divide the text content into regions according to the text position to obtain the initial region of the text content; perform a magnification process on the initial region according to preset parameters to obtain an intermediate region; detect the overlapping region between the two intermediate regions to obtain region overlapping data; if the region overlapping data indicates that there is an overlapping region between the two intermediate regions, merge the text content of the intermediate regions to obtain the target region. Filtering the original image according to the detection data to obtain a candidate image includes: if the first color difference data is less than or equal to a preset second threshold, using the original image as the candidate image. Sorting the candidate images according to the detection data to obtain an image list includes: Obtain the detection data of the candidate image to obtain the second color difference data; calculate the mean value of the second color difference data to obtain image recommendation data, where the image recommendation data is used to represent the recommended priority of the candidate image; sort the candidate images in ascending order based on the image recommendation data to obtain the image list.

7. An electronic device, characterized in that, The electronic device includes a memory and a processor, the memory stores a computer program, and when the processor executes the computer program, it implements the image screening method according to any one of claims 1 to 5.

8. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by the processor, it implements the image screening method according to any one of claims 1 to 5.

Citation Information

Patent Citations

  • Method and device for identifying specified target in image, electronic equipment and storage medium

    CN112883827A

  • Image description generation method and device, electronic equipment and storage medium

    CN114648631A