Image similarity comparison processing method, electronic device, storage medium and program product

By identifying and enhancing the feature values ​​of the environment and subject feature points in the image, generating feature maps and calculating similarity, the problem of poor accuracy of image similarity after abnormal death of aquacultures is solved, and the accurate identification of repeated claims applications is achieved.

CN120164003BActive Publication Date: 2025-08-26PEOPLE'S INSURANCE COMPANY OF CHINA
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510637835.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-05-19
Publication Date
2025-08-26
Estimated Expiration
2045-05-19

AI Technical Summary

Technical Problem

In the prior art, after the aquaculture dies abnormally, the accuracy of determining the image similarity degree is poor, resulting in insufficient identification accuracy of repeated claims applications.

Method used

By obtaining the mask of the image, identifying the environmental part and the main body part, enhancing the characteristic values ​​of the environment and the main body feature points, generating the environmental feature map and the main body feature map, and calculating the similarity, and outputting similar comparison results.

Benefits of technology

The accuracy of image similarity calculation is improved, environmental features and subject features are avoided, and the identification accuracy of repeated claims applications is ensured.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120164003B_ABST
    Figure CN120164003B_ABST
Patent Text Reader

Abstract

The image similarity comparison processing method, electronic device, storage medium and program product provided by the present application relate to the field of image processing technology. Based on obtaining a target image to be processed and an image to be compared, the target image and the image to be compared are processed: a mask of the image is obtained, and feature extraction is performed on the image to obtain all feature points; based on the mask, the feature values ​​of the feature points of the environment part of the image and the feature values ​​of the feature points of the main part of the image are processed to obtain environment-enhanced feature points and main-body-enhanced feature points; based on the environment-enhanced feature points, an environment feature map is generated; based on the main-body-enhanced feature points, a main-body feature map is generated; the environment similarity between the target image and any image to be compared, and the main-body similarity between the target image and any image to be compared are calculated; and based on the environment similarity and the main-body similarity, a similarity comparison result is output. The problem of poor accuracy of similarity comparison results generated based on existing technical solutions is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of image processing technology, and in particular to an image similarity comparison processing method, electronic equipment, storage medium and program product. Background Art

[0002] With the development of insurance business, in the livestock farming industry, users usually insure their animals to obtain corresponding claims after the animals die abnormally. However, in the case of abnormal death of animals, there are cases where duplicate claims are filed for the same animal that died abnormally.

[0003] In the prior art, the degree of similarity between the image of the pending claim application and the image of the settled claim application is often determined by inputting the images into an image recognition model, and then determining whether the pending claim application is a duplicate claim application based on the degree of similarity between the images.

[0004] However, the similarity between the image of the pending claim application and the image of the settled claim application obtained by the prior art solution has a problem of poor accuracy. Summary of the Invention

[0005] The image similarity comparison processing method, electronic device, storage medium and program product provided in the embodiments of the present application are used to solve the problem of poor accuracy in the similarity between the image of the claim application to be settled and the image of the claim application obtained based on the existing technical solution.

[0006] In a first aspect, an embodiment of the present application provides an image similarity comparison processing method, comprising: obtaining at least two images to be processed, wherein the at least two images include a target image and at least one image to be compared; for each of the at least two images, performing the following steps: obtaining a mask of the image, wherein the mask is used to identify an environment part and a main part in the image; performing feature extraction on the image to obtain all feature points; based on the mask, increasing the feature values ​​of the feature points of the environment part in the image and reducing the feature values ​​of the feature points of the main part in the image to obtain environment enhancement feature points; based on the mask, increasing the feature values ​​of the feature points of the main part in the image The characteristic value is increased, and the characteristic value of the characteristic point of the environment part in the image is reduced to obtain the main enhanced feature point; based on the environment enhanced feature point, an environment feature map is generated; based on the main enhanced feature point, a main feature map is generated; the similarity between the environment feature map of the target image and the environment feature map of any image to be compared is calculated to obtain the environment similarity between the target image and any image to be compared; the similarity between the main feature map of the target image and the main feature map of any image to be compared is calculated to obtain the main similarity between the target image and any image to be compared; based on the environment similarity and the main similarity, a similarity comparison result between the target image and any image to be compared is output.

[0007] In a possible embodiment, based on the mask, the feature values ​​of the feature points of the environment part in the image are increased, and the feature values ​​of the feature points of the main part in the image are reduced to obtain environment-enhanced feature points, including: increasing the feature values ​​of the feature points of the environment part outside the mask according to a first preset weight to obtain a first environment feature value; reducing the feature values ​​of the feature points of the main part within the mask according to a second preset weight to obtain a first main feature value; arranging the first environment feature value and the first main feature value from large to small to obtain a first feature value sequence; determining the first environment feature value and / or the first main feature value in the first feature value sequence as environment-enhanced feature values ​​from large to small according to the first preset feature value number; and screening out the environment-enhanced feature point from all the feature points according to the environment-enhanced feature value.

[0008] In one possible embodiment, the process of generating the first preset weight and the second preset weight includes: inputting the image into a pre-trained multimodal large model, outputting at least one target environment feature identifier, and / or at least one target subject feature identifier; obtaining a first weighting coefficient based on the number of identifiers of the target environment feature identifier; obtaining a second weighting coefficient based on the number of identifiers of the target subject feature identifier; obtaining the first preset weight based on the environment feature weight corresponding to each target environment feature identifier and the first weighting coefficient; obtaining the second preset weight based on the subject feature weight corresponding to each target subject feature identifier and the second weighting coefficient.

[0009] In a possible embodiment, generating an environmental feature map based on the environmental enhancement feature points includes: expanding or compressing the position coordinates of the environmental enhancement feature points according to the size relationship between a preset image resolution and the image resolution of the image to generate environmental target position coordinates; generating the environmental feature map based on the increased and / or decreased feature values ​​corresponding to the environmental enhancement feature points and the environmental target position coordinates.

[0010] In a possible embodiment, before acquiring at least two images to be processed, the method further includes: acquiring the target image; determining first shooting location information of the target image; identifying the main object in the target image, and determining a transportation cost threshold of the main object, and insurance benefits obtained by insuring the main object; obtaining a transportation distance threshold based on the transportation cost threshold and the insurance benefits; obtaining regional scope information based on the transportation distance threshold and the first shooting location information; acquiring one or more similar images corresponding to the target image; determining second shooting location information of each similar image based on each similar image; judging whether each second shooting location information is within the regional scope information; determining the second shooting location information within the regional scope information as the target location information; and determining the similar images corresponding to the target location information as the images to be compared.

[0011] In a possible embodiment, the similarity between the environmental feature map of the target image and the environmental feature map of any image to be compared is calculated to obtain the environmental similarity between the target image and any image to be compared, including: obtaining the environmental feature vector of the target image based on the environmental feature map of the target image; obtaining the environmental feature vector of the image to be compared based on the environmental feature map of the image to be compared; and calculating the vector distance between the environmental feature vector of the target image and the environmental feature vector of any image to be compared to obtain the environmental similarity between the target image and any image to be compared.

[0012] In a second aspect, an embodiment of the present application provides an image similarity comparison processing device, comprising:

[0013] An acquisition module, configured to acquire at least two images to be processed, wherein the at least two images include a target image and at least one image to be compared;

[0014] The processing module is configured to perform the following steps for each of the at least two images: obtaining a mask of the image, wherein the mask is used to identify an environment portion and a subject portion in the image; performing feature extraction on the image to obtain all feature points; based on the mask, increasing feature values ​​of feature points of the environment portion in the image and decreasing feature values ​​of feature points of the subject portion in the image to obtain environment-enhanced feature points; based on the mask, increasing feature values ​​of feature points of the subject portion in the image and decreasing feature values ​​of feature points of the environment portion in the image to obtain subject-enhanced feature points; generating an environment feature map based on the environment-enhanced feature points; and generating a subject feature map based on the subject-enhanced feature points.

[0015] The comparison module is used to calculate the similarity between the environmental feature map of the target image and the environmental feature map of any image to be compared, so as to obtain the environmental similarity between the target image and any image to be compared; calculate the similarity between the subject feature map of the target image and the subject feature map of any image to be compared, so as to obtain the subject similarity between the target image and any image to be compared; and output a similarity comparison result between the target image and any image to be compared based on the environmental similarity and the subject similarity.

[0016] In a possible embodiment, when the processing module increases the feature values ​​of the feature points of the environment part in the image and reduces the feature values ​​of the feature points of the main part in the image based on the mask to obtain environment-enhanced feature points, it is specifically used to: increase the feature values ​​of the feature points of the environment part outside the mask according to a first preset weight to obtain a first environment feature value; reduce the feature values ​​of the feature points of the main part within the mask according to a second preset weight to obtain a first main feature value; arrange the first environment feature value and the first main feature value from large to small to obtain a first feature value sequence; determine the first environment feature value and / or the first main feature value in the first feature value sequence as environment-enhanced feature values ​​from large to small according to the first preset feature value number; and screen out the environment-enhanced feature point from all the feature points based on the environment-enhanced feature value.

[0017] In a possible embodiment, the image similarity comparison processing device also includes a weight pre-generation module, which is specifically used to: input the image into a pre-trained multimodal large model, and output at least one target environment feature identifier, and / or at least one target subject feature identifier; obtain a first weighting coefficient based on the number of identifiers of the target environment feature identifier; obtain a second weighting coefficient based on the number of identifiers of the target subject feature identifier; obtain the first preset weight based on the environment feature weight corresponding to each target environment feature identifier and the first weighting coefficient; obtain the second preset weight based on the subject feature weight corresponding to each target subject feature identifier and the second weighting coefficient.

[0018] In a possible embodiment, when the processing module generates an environmental feature map based on the environmental enhancement feature points, it is specifically used to: expand or compress the position coordinates of the environmental enhancement feature points according to the size relationship between the preset image resolution and the image resolution of the image to generate environmental target position coordinates; generate the environmental feature map according to the increased and / or decreased feature values ​​corresponding to the environmental enhancement feature points and the environmental target position coordinates.

[0019] In a possible embodiment, before acquiring at least two images to be processed, the acquisition module is further used to: acquire the target image; determine first shooting location information of the target image; identify the main object in the target image, and determine the transportation cost threshold of the main object, and the insurance benefit obtained by insuring the main object; obtain a transportation distance threshold based on the transportation cost threshold and the insurance benefit; obtain regional scope information based on the transportation distance threshold and the first shooting location information; acquire one or more similar images corresponding to the target image; determine second shooting location information of each similar image based on each similar image; determine whether each second shooting location information is within the regional scope information; determine the second shooting location information within the regional scope information as the target location information; and determine the similar image corresponding to the target location information as the image to be compared.

[0020] In a possible embodiment, when the comparison module calculates the similarity between the environmental feature map of the target image and the environmental feature map of any image to be compared to obtain the environmental similarity between the target image and any image to be compared, it is specifically used to: obtain the environmental feature vector of the target image based on the environmental feature map of the target image; obtain the environmental feature vector of the image to be compared based on the environmental feature map of the image to be compared; calculate the vector distance between the environmental feature vector of the target image and the environmental feature vector of any image to be compared to obtain the environmental similarity between the target image and any image to be compared.

[0021] In a third aspect, an embodiment of the present application provides an electronic device, comprising: a memory, a processor;

[0022] The memory stores computer-executable instructions;

[0023] The processor executes the computer-executable instructions stored in the memory, so that the processor executes the above first aspect and / or various possible implementations of the first aspect.

[0024] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, in which computer-executable instructions are stored. When the computer-executable instructions are executed by a processor, they are used to implement the first aspect above and / or various possible implementation methods of the first aspect.

[0025] In a fifth aspect, an embodiment of the present application provides a computer program product, including a computer program, which, when executed by a processor, implements the above first aspect and / or various possible implementation methods of the first aspect.

[0026] The image similarity comparison processing method, electronic device, storage medium and program product provided in the embodiments of the present application, based on obtaining a target image to be processed and at least one image to be compared, performs the following processing on the target image and the image to be compared: obtains a mask of the image, performs feature extraction on the image, and obtains all feature points; based on the mask, processes the feature values ​​of the feature points of the environment part of the image and the feature values ​​of the feature points of the main part of the image, and obtains environment-enhanced feature points and main-body-enhanced feature points respectively; then, based on the environment-enhanced feature points, generates an environment feature map, and based on the main-body-enhanced feature points, generates a main-body feature map; on this basis, respectively calculates the target image and any image to be compared. The environmental similarity and the subject similarity between the target image and any image to be compared are determined; further, based on the environmental similarity and the subject similarity, a similarity comparison result between the target image and any image to be compared is output; that is, by respectively determining the environmental similarity and the subject similarity between the target image and any image to be compared, the similarity between the target image and at least one image to be compared is determined, thereby avoiding the mutual influence between the environmental features and the subject features of the image, which causes the problem of poor accuracy in the similarity between the determined target image and at least one image to be compared, and also solves the problem of poor accuracy in the similarity between the image to be applied for claim and the image of the applied for claim obtained based on the existing technical solution. BRIEF DESCRIPTION OF THE DRAWINGS

[0027] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.

[0028] Figure 1 A schematic diagram of a scenario for the image similarity comparison processing method provided in this application;

[0029] Figure 2 A flowchart of an image similarity comparison method provided in one embodiment of the present application;

[0030] Figure 3 A schematic diagram of the structure of an image similarity comparison processing device provided in one embodiment of the present application;

[0031] Figure 4 This is a schematic diagram of the structure of the electronic device provided in this application.

[0032] The above drawings illustrate specific embodiments of the present application, which will be described in more detail below. These drawings and the textual description are not intended to limit the scope of the present application in any way, but rather to illustrate the concepts of the present application to those skilled in the art by reference to specific embodiments. DETAILED DESCRIPTION

[0033] Exemplary embodiments will be described in detail herein, with examples illustrated in the accompanying drawings. In the following description, when referring to the drawings, identical numerals in different figures represent identical or similar elements, unless otherwise indicated. The embodiments described in the following exemplary embodiments are not intended to represent all embodiments consistent with the present application. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the present application, as detailed in the appended claims.

[0034] In the technical solution of this application, the user personal information involved and the collection, storage, use, processing, transmission, provision and disclosure of data are in compliance with the provisions of relevant laws and regulations and do not violate public order and good morals.

[0035] 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 the relevant laws, regulations and standards of the relevant regions, and provide corresponding operation entrances for users to choose to authorize or refuse.

[0036] With the development of the insurance business, in the livestock breeding industry, users usually insure the livestock in order to obtain corresponding claims after the abnormal death of the livestock. However, in the case of abnormal death of the livestock, there may be repeated claims for the same abnormally dead livestock. In the prior art, the image of the to-be-claimed application and the image of the already-claimed application are often input into the image recognition model to determine the degree of similarity between the image of the to-be-claimed application and the image of the already-claimed application, and then determine whether the to-be-claimed application is a duplicate claim based on the degree of similarity between the images. However, the degree of similarity between the image of the to-be-claimed application and the image of the already-claimed application obtained by the prior art solution has the problem of poor accuracy.

[0037] The following explains the application scenarios of the embodiments of the present application:

[0038] The following specific embodiments describe in detail the technical solution of the present application and how the technical solution of the present application solves the above-mentioned technical problems. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. The embodiments of the present application will be described below in conjunction with the accompanying drawings.

[0039] Figure 1 A schematic diagram of a scene of the image similarity comparison processing method provided in this application, such as Figure 1 As shown, the specific application scenario of the present application is a scenario of determining the degree of similarity between a target image and at least one image to be compared, wherein the target image corresponds to an image of a pending claim application in the prior art, and the image to be compared corresponds to an image of a settled claim application in the prior art; the execution subject of the method provided in the embodiment of the present application can be any form of electronic device, and the electronic device, by executing the method provided in the embodiment of the present application, obtains the target image and at least one image to be compared, and respectively identifies and separates the environment part and the main part in the target image and at least one image to be compared, thereby generating corresponding environment feature maps and main feature maps; further, By calculating the similarity between the environmental feature map of the target image and the environmental feature map of any image to be compared, the environmental similarity between the target image and any image to be compared is obtained; by calculating the similarity between the subject feature map of the target image and the subject feature map of any image to be compared, the subject similarity between the target image and any image to be compared is obtained; and then, based on the environmental similarity and the subject similarity, the similarity comparison result between the target image and any image to be compared is output, thereby realizing the determination of the similarity between the target image and at least one image to be compared, and also solving the problem of poor accuracy of the similarity between the image of the claim application to be settled and the image of the claim application obtained based on the existing technical solution.

[0040] Figure 2A flowchart of an image similarity comparison processing method provided in one embodiment of the present application is shown as follows: Figure 2 As shown, the execution subject of the image similarity comparison processing method provided in this embodiment can be any form of electronic device. The image similarity comparison processing method provided in this embodiment includes the following steps:

[0041] Step S101 : obtaining at least two images to be processed, wherein the at least two images include a target image and at least one image to be compared.

[0042] Exemplarily, the target image corresponds to the image of the pending claim application in the prior art, and the image to be compared corresponds to the image of the already claimed application in the prior art; then, the electronic device obtains the target image to be processed and at least one image to be compared from the database, and implements the subsequent steps of similarity comparison processing between the target image and the image to be compared, and then determines whether the user has initiated a repeated claim application for the same abnormally dead farmed animal based on the similarity comparison result obtained from the similarity comparison processing.

[0043] In another possible implementation, before acquiring at least two images to be processed, the method provided in the embodiment of the present application further includes:

[0044] Step S100a: acquiring a target image.

[0045] Step S100b: determining first shooting location information of the target image.

[0046] For example, the image uploaded by the user includes longitude and latitude data, and the first shooting location information of the target image can be determined according to the longitude and latitude data of the target image.

[0047] Step S100c: identifying the main object in the target image, and determining a transportation cost threshold of the main object, and insurance benefits obtained by insuring the main object.

[0048] For example, the main object in the target image is identified to determine the object category of the main object; then, based on the object category of the main object, a transportation cost threshold for transporting the main object is determined. For example, the transportation cost threshold is the transportation cost per kilometer, and the transportation cost per kilometer for transporting a cow is , the transportation cost per kilometer of transporting a sheep is ; Further, according to the object category of the subject object, the insurance benefits obtained by the insured subject object are determined, that is, the insurance benefits obtained by the user after the subject object dies abnormally and the user initiates a claim application. For example, after a cow dies abnormally, the insurance benefits obtained by the user are , after a sheep dies abnormally, the insurance benefit obtained by the user is .

[0049] Step S100d: Obtain a transportation distance threshold based on the transportation cost threshold and the insurance benefit.

[0050] For example, the transportation cost threshold and insurance income are substituted into formula (1) to calculate the transportation distance threshold: ,in, 1,2,3, , .

[0051] (1)

[0052] in, Insurance proceeds obtained by the insured subject; It is the transportation cost threshold of the transportation subject object.

[0053] Specifically, for example, if the subject object is a sheep, then , and then the transportation cost per kilometer of transporting a sheep , the insurance benefits obtained by the user after a sheep dies abnormally , substituting into formula (1), the corresponding transportation distance threshold can be calculated .

[0054] Step S100e: obtaining area range information according to the transportation distance threshold and the first shooting location information.

[0055] For example, the longitude and latitude data corresponding to the first shooting location information is used as the center of the circle, and the transportation distance threshold is used as the radius of the circle to obtain a corresponding circular area, and then the circular area is determined as the corresponding regional range, and then the regional range information is obtained based on the longitude and latitude data within the regional range.

[0056] Step S100f: Obtain one or more similar images corresponding to the target image.

[0057] Exemplarily, based on the main object and / or environmental feature identifier of the target image, one or more similar images are screened out from the images stored in the database, wherein the main object in the similar image is similar to the main object of the target image, or the environmental feature identifier in the similar image is similar to the environmental feature identifier of the target image, or the main object and environmental feature identifier in the similar image are similar to the main object and environmental feature identifier of the target image.

[0058] Step S100g: determining the second shooting location information of each similar image based on each similar image.

[0059] For example, the image uploaded by the user includes longitude and latitude data, and the second shooting location information of the similar image can be determined based on the longitude and latitude data of the similar image.

[0060] Step S100h: determining whether each second shooting location information is within the area range information.

[0061] In step S100i, the second shooting location information within the area range information is determined as the target location information.

[0062] Step S100j: determining the similar image corresponding to the target location information as the image to be compared.

[0063] For example, by determining whether the latitude and longitude data corresponding to each piece of second shooting location information is within the data interval of the latitude and longitude data corresponding to the regional scope information, if the latitude and longitude data corresponding to the second shooting location information is within the data interval of the latitude and longitude data corresponding to the regional scope information, the second shooting location information is determined to be within the regional scope information, and the second shooting location information is then determined as the target location information. Furthermore, the similar image corresponding to the target location information is determined as the image to be compared, thereby executing step S101 and performing the subsequent steps of similarity comparison processing between the target image and the image to be compared.

[0064] In the steps of this embodiment, a transportation distance threshold is determined based on the transportation cost threshold and insurance benefit of the main object, and then similar images are screened based on the transportation distance threshold and the first shooting location information corresponding to the target image, thereby obtaining at least one image to be compared. On the basis of avoiding omission of images to be compared, the number of images to be compared with the target image in subsequent steps is reduced, thereby improving data processing efficiency.

[0065] Step S102 : For each of the at least two images, execute steps S103 to S108 .

[0066] Step S103: obtaining a mask of the image, wherein the mask is used to identify the environment part and the subject part in the image.

[0067] Exemplarily, the image is input into the image segmentation model, which segments and identifies the main part and the environment part in the image, using "0" to represent the pixel points corresponding to the environment part and "1" to represent the pixel points corresponding to the main part, and then generating a corresponding matrix based on "0", "1" and the corresponding pixel point positions, thereby obtaining the mask of the image; exemplarily, the image segmentation model includes an image semantic segmentation model.

[0068] Step S104: extract features from the image to obtain all feature points.

[0069] Exemplarily, the image is input into a pre-trained feature extraction model to perform feature extraction on the image, thereby obtaining all feature points of the image.

[0070] Step S105 : Based on the mask, the feature values ​​of the feature points of the environment part of the image are increased, and the feature values ​​of the feature points of the main part of the image are reduced to obtain environment enhanced feature points.

[0071] Exemplarily, based on the environment part and the main part of the image determined by the mask, the feature values ​​of the feature points of the environment part in the image are respectively increased to obtain increased feature values, and the feature values ​​of the feature points of the main part in the image are reduced to obtain reduced feature values; then, based on the increased feature values ​​and the reduced feature values, a preset number of feature points are determined, and then the determined preset number of feature points are determined as environment-enhanced feature points; wherein, the environment-enhanced feature points include feature points of the environment part corresponding to the increased feature values, and / or feature points of the main part corresponding to the reduced feature values.

[0072] Specifically, the specific implementation steps of step S105 include:

[0073] Step S1051 : For feature points of the environment outside the mask, the feature values ​​of the feature points are increased according to a first preset weight to obtain a first environment feature value.

[0074] Exemplarily, for the feature points of the environment portion corresponding to the mask, the feature values ​​of the feature points are increased based on the first preset weight to obtain the first environment feature value.

[0075] Step S1052 : For the feature points of the main body within the mask, the feature values ​​of the feature points are reduced according to the second preset weight to obtain a first main body feature value.

[0076] Exemplarily, for the feature points of the main body portion corresponding to the mask, the feature values ​​of the feature points are reduced based on the second preset weight to obtain the first main body feature values.

[0077] Step S1053: Arrange the first environmental characteristic value and the first subject characteristic value from large to small to obtain a first characteristic value sequence.

[0078] Exemplarily, based on the magnitude of the eigenvalues, the first environment eigenvalues ​​and the first subject eigenvalues ​​are sorted from large to small according to the eigenvalues, thereby obtaining a first eigenvalue sequence.

[0079] Step S1054 : determining the first environmental feature value and / or the first subject feature value in the first feature value sequence as the environment enhancement feature value from largest to smallest according to the first preset feature value quantity.

[0080] Step S1055 : Filter out environment enhancement feature points from all feature points according to the environment enhancement feature values.

[0081] Exemplarily, for the first environmental characteristic value and / or the first main characteristic value in the first characteristic value sequence, a first preset characteristic value number of the first environmental characteristic value and / or the first main characteristic value is selected in a descending order, and then the first environmental characteristic value and / or the first main characteristic value selected based on the first preset characteristic value number is determined as the environmental enhancement characteristic value; further, from all the feature points, the feature point corresponding to the environmental enhancement characteristic value is determined as the environmental enhancement feature point, that is, the environmental enhancement feature point is screened out from all the feature points; wherein the environmental enhancement feature point includes the feature point of the environmental part, and / or the feature point of the main part.

[0082] Furthermore, the method provided in the embodiment of the present application further includes a process of generating the first preset weight and the second preset weight, and the specific steps include:

[0083] Step S105a: input the image into a pre-trained multimodal large model, and output at least one target environment feature identifier and / or at least one target subject feature identifier.

[0084] Step S105b: Obtain a first weighting coefficient according to the number of target environment feature identifiers.

[0085] Step S105c: obtaining a second weighting coefficient according to the number of identifications of the target subject feature identification.

[0086] Exemplarily, the pre-trained multimodal large model identifies the target environment feature identifier and the target subject feature identifier in the image, and then outputs at least one target environment feature identifier, and / or at least one target subject feature identifier; further, the number of the output target environment feature identifiers is counted to obtain the number of identifications of the target environment feature identifiers, and then a first weighting coefficient is obtained based on the number of identifications of the target environment feature identifiers; the number of the output target subject feature identifiers is counted to obtain the number of identifications of the target subject feature identifiers, and then a second weighting coefficient is obtained based on the number of identifications of the target subject feature identifiers.

[0087] Step S105d: Obtain a first preset weight according to the environmental feature weight corresponding to each target environmental feature identifier and a first weighting coefficient.

[0088] Exemplarily, the environmental feature weights corresponding to the target environmental feature identifiers are summed to obtain the total environmental feature weight; and then the product of the total environmental feature weight and the first weighting coefficient is calculated to obtain the first preset weight.

[0089] Step S105e: Obtain a second preset weight according to the subject feature weight corresponding to each target subject feature identifier and the second weighting coefficient.

[0090] Exemplarily, the subject feature weights corresponding to each target subject feature identifier are summed up to obtain the total subject feature weight; and then the product of the total subject feature weight and the second weighting coefficient is calculated to obtain the second preset weight.

[0091] In the steps of this embodiment, the environmental feature weight corresponding to the target environmental feature identifier is processed by the first weighting coefficient to obtain the first preset weight, and the subject feature weight corresponding to the target subject feature identifier is processed by the second weighting coefficient to obtain the second preset weight, so as to associate the first preset weight with the number of identifiers of the target environmental feature identifier, and associate the second preset weight with the number of identifiers of the target subject feature identifier; thereby, the first environmental feature value obtained by the first preset weight in step S1051 is associated with the number of identifiers of the target environmental feature identifier, and the first subject feature value obtained by the second preset weight in step S1052 is associated with the number of identifiers of the target subject feature identifier; thereby, the accuracy of the determined environmental enhancement feature value is improved, and thereby the accuracy of the environmental enhancement feature points screened out from all feature points is improved.

[0092] Step S106 : Based on the mask, the feature values ​​of the feature points of the main body part in the image are increased, and the feature values ​​of the feature points of the environment part in the image are reduced to obtain the main body enhanced feature points.

[0093] Specifically, the specific implementation steps of step S106 include:

[0094] Step S1061 : For feature points of the environment outside the mask, the feature values ​​of the feature points are reduced according to a first preset weight to obtain a second environment feature value.

[0095] Exemplarily, for the feature points of the environment portion corresponding to the mask, the feature values ​​of the feature points are reduced based on the first preset weight to obtain the second environment feature value.

[0096] Step S1062 : For the feature points of the main body within the mask, the feature values ​​of the feature points are increased according to the second preset weight to obtain a second main body feature value.

[0097] Exemplarily, for the feature points of the main body portion corresponding to the mask, the feature values ​​of the feature points are increased based on the second preset weight to obtain the second main body feature value.

[0098] Step S1063 , arranging the second environment characteristic value and the second subject characteristic value from large to small to obtain a second characteristic value sequence.

[0099] Exemplarily, based on the magnitude of the eigenvalues, the second environment eigenvalues ​​and the second subject eigenvalues ​​are sorted from large to small according to the eigenvalues, thereby obtaining a second eigenvalue sequence.

[0100] Step S1064 : determining the second environmental feature values ​​and / or the second subject feature values ​​in the second feature value sequence as subject enhancement feature values ​​from largest to smallest according to the second preset feature value quantity.

[0101] Step S1065 : Filter out main body enhancement feature points from all feature points according to the main body enhancement feature values.

[0102] Exemplarily, for the second environmental characteristic value and / or the second subject characteristic value in the second characteristic value sequence, a second preset characteristic value number of the second environmental characteristic value and / or the second subject characteristic value is selected in a descending order, and then the second environmental characteristic value and / or the second subject characteristic value selected based on the second preset characteristic value number is determined as the subject reinforcement characteristic value; further, from all the feature points, the feature point corresponding to the subject reinforcement characteristic value is determined as the subject reinforcement feature point, that is, the subject reinforcement feature point is screened out from all the feature points; wherein, the subject reinforcement feature point includes the feature point of the subject part, and / or the feature point of the environment part.

[0103] Step S107: Generate an environmental feature map based on the environmental enhancement feature points.

[0104] Exemplarily, based on the increased and / or decreased characteristic values ​​corresponding to the environment enhancement feature points, a characteristic area of ​​corresponding size is drawn at the coordinate position corresponding to the environment enhancement feature point, for example, a circular area or a rectangular area of ​​corresponding size is drawn; and then, based on the characteristic area corresponding to the drawn environment enhancement feature point, an environment characteristic map is obtained.

[0105] In another possible implementation, the specific implementation steps of step S107 include:

[0106] Step S1071 : performing an expansion process or a compression process on the position coordinates of the environment enhancement feature points according to the size relationship between the preset image resolution and the image resolution, so as to generate the environment target position coordinates.

[0107] Step S1072: Generate an environmental feature map based on the increased and / or decreased feature values ​​corresponding to the environmental enhancement feature points and the environmental target position coordinates.

[0108] For example, the relationship between the preset image resolution and the image resolution of the image is determined. If the image resolution of the image is greater than the preset image resolution, the position coordinates of the environment enhancement feature points are compressed based on the preset image resolution to generate the environment target position coordinates; if the image resolution of the image is less than the preset image resolution, the position coordinates of the environment enhancement feature points are expanded based on the preset image resolution to generate the environment target position coordinates; if the image resolution of the image is equal to the preset image resolution, the environment target position coordinates are the position coordinates of the environment enhancement feature points, that is, the position coordinates of the environment enhancement feature points are not expanded or compressed.

[0109] Furthermore, after obtaining the coordinates of the environmental target position, based on the increased and / or decreased characteristic values ​​corresponding to the environmental enhancement feature points, a characteristic area of ​​corresponding size is drawn at the coordinate position of the environmental target position coordinates corresponding to the environmental enhancement feature points, for example, a circular area or a rectangular area of ​​corresponding size is drawn; and then, based on the characteristic area corresponding to the drawn environmental enhancement feature points, an environmental characteristic map is obtained.

[0110] In the steps of this embodiment, based on the comparison of the preset image resolution and the image resolution of the image, the position coordinates of the environment enhancement feature points in the image resolution of the image are expanded or compressed based on the preset image resolution, thereby obtaining the environmental target position coordinates, and further obtaining the environmental feature map; the position coordinates in images of different resolutions are processed into position coordinates under the same resolution, and then the corresponding environmental feature map is generated, which provides a normalized environmental feature map for the subsequent step of calculating the similarity between the environmental feature map of the target image and the environmental feature map of any image to be compared, thereby improving the accuracy of the similarity calculation.

[0111] Step S108: generating a subject feature map based on the subject enhancement feature points.

[0112] Exemplarily, based on the increased and / or decreased characteristic values ​​corresponding to the main reinforcement feature points, a characteristic area of ​​corresponding size is drawn at the coordinate position corresponding to the main reinforcement feature points, for example, a circular area or a rectangular area of ​​corresponding size is drawn; and then based on the characteristic area corresponding to the drawn main reinforcement feature points, a main feature map is obtained.

[0113] In another possible implementation, the specific implementation steps of step S108 include:

[0114] Step S1081 : performing an expansion process or a compression process on the position coordinates of the enhanced feature points of the subject according to the size relationship between the preset image resolution and the image resolution of the image, so as to generate the target position coordinates of the subject.

[0115] Step S1082: Generate a subject feature map based on the increased and / or decreased feature values ​​corresponding to the subject enhancement feature points and the subject target position coordinates.

[0116] In this embodiment, the implementation method of generating the subject feature map based on the subject enhancement feature points in steps S1081 and S1082 is the same as the implementation method of generating the environment feature map based on the environment enhancement feature points in steps S1071 and S1072, and will not be repeated here.

[0117] It can be understood that the "preset image resolution" in step S1071 and the "preset image resolution" in step S1081 can be the same value or different values. The embodiment of the present application does not impose any specific restrictions, that is, the corresponding preset image resolution can be selected according to the environment enhancement feature points and the subject enhancement feature points, that is, the corresponding preset image resolution can be selected according to the environment complexity corresponding to the environment enhancement feature points and the subject complexity corresponding to the subject enhancement feature points.

[0118] Step S109 : calculating the similarity between the environmental feature map of the target image and the environmental feature map of any image to be compared, so as to obtain the environmental similarity between the target image and any image to be compared.

[0119] Exemplarily, since the environmental feature map includes increased and / or decreased feature values ​​corresponding to the environmental enhancement feature points, based on the increased and / or decreased feature values ​​corresponding to the environmental feature map of the target image and the increased and / or decreased feature values ​​corresponding to the environmental feature map of the image to be compared, the similarity between the environmental feature map of the target image and the environmental feature map of any image to be compared can be calculated, thereby obtaining the environmental similarity between the target image and any image to be compared.

[0120] In another possible implementation, the specific implementation steps of step S109 include:

[0121] Step S1091: Obtain an environmental feature vector of the target image according to the environmental feature map of the target image.

[0122] Step S1092 , obtaining an environmental feature vector of the image to be compared based on the environmental feature map of the image to be compared.

[0123] Step S1093 , calculating the vector distance between the environmental feature vector of the target image and the environmental feature vector of any image to be compared, and obtaining the environmental similarity between the target image and any image to be compared.

[0124] Exemplarily, since the environmental feature map includes increased and / or decreased characteristic values ​​at the positions corresponding to the environmental enhancement feature points, the environmental feature map is feature-vectorized based on the increased and / or decreased characteristic values ​​at the positions corresponding to the environmental enhancement feature points, and the corresponding environmental feature vector can be obtained; that is, based on the increased and / or decreased characteristic values ​​at the positions corresponding to the environmental enhancement feature points in the environmental feature map of the target image, the environmental feature map of the target image is feature-vectorized, and the environmental feature vector of the target image can be obtained; based on the increased and / or decreased characteristic values ​​at the positions corresponding to the environmental enhancement feature points in the environmental feature map of the image to be compared, the environmental feature map of the image to be compared is feature-vectorized, and the environmental feature vector of the image to be compared can be obtained.

[0125] Furthermore, based on cosine similarity, the vector distance between the target image's environmental feature vector and the environmental feature vector of any image to be compared is calculated to obtain a corresponding cosine distance, which is then determined as the environmental similarity between the target image and the corresponding image to be compared. In the steps of this embodiment, since the environmental features of the target image and the image to be compared may differ in terms of angle, movement, rotation, and scaling, the cosine similarity is used to calculate the vector distance between the target image's environmental feature vector and the environmental feature vector of any image to be compared, thereby accurately capturing the similarity between the target image's environmental feature vector and the environmental feature vector of any image to be compared.

[0126] Optionally, the calculation method for calculating the environmental feature vector distance also includes a calculation method based on Euclidean similarity.

[0127] Step S110 : calculating the similarity between the subject feature map of the target image and the subject feature map of any image to be compared, so as to obtain the subject similarity between the target image and any image to be compared.

[0128] Exemplarily, since the subject feature map includes the increased and / or decreased feature values ​​corresponding to the subject enhancement feature points, based on the increased and / or decreased feature values ​​corresponding to the subject feature map of the target image and the increased and / or decreased feature values ​​corresponding to the subject feature map of the image to be compared, the similarity between the subject feature map of the target image and the subject feature map of any image to be compared can be calculated, thereby obtaining the subject similarity between the target image and any image to be compared.

[0129] In another possible implementation, the specific implementation steps of step S110 include:

[0130] Step S110a: obtaining a main feature vector of the target image according to the main feature map of the target image.

[0131] Step S110b: obtaining a main feature vector of the image to be compared according to the main feature map of the image to be compared.

[0132] In this embodiment, the implementation method of determining the subject feature vector in steps S110a and S110b is the same as the implementation method of determining the environment feature vector in steps S1091 and S1092, and will not be repeated here.

[0133] Step S110c: Calculate the vector distance between the main feature vector of the target image and the main feature vector of any image to be compared, and obtain the main similarity between the target image and any image to be compared.

[0134] For example, based on Euclidean similarity, the vector distance between the main feature vector of the target image and the main feature vector of any image to be compared is calculated to obtain the corresponding Euclidean distance, which is then determined as the main similarity between the target image and the corresponding image to be compared. In the steps of this embodiment, since the pixels between the main features of the target image and the image to be compared are evenly distributed and have a low spatial variation rate, the use of Euclidean similarity to calculate the vector distance between the main feature vector of the target image and the main feature vector of any image to be compared can accurately capture the similarity between the main features of the target image and the main features of the image to be compared in terms of pixel details.

[0135] Optionally, the calculation method for calculating the subject feature vector distance also includes a calculation method based on cosine similarity.

[0136] Step S111 : outputting a similarity comparison result between the target image and any image to be compared based on the environment similarity and the subject similarity.

[0137] Exemplarily, based on the size relationship between the environmental similarity and the first similarity threshold, the environmental similarity comparison result between the target image and any image to be compared is obtained; based on the size relationship between the subject similarity and the second similarity threshold, the subject similarity comparison result between the target image and any image to be compared is obtained; based on the environmental similarity and the subject similarity, the comprehensive similarity is obtained, and based on the size relationship between the comprehensive similarity and the third similarity threshold, the comprehensive similarity comparison result between the target image and any image to be compared is obtained; and further, based on the environmental similarity comparison result, the subject similarity comparison result and the comprehensive similarity comparison result, the similarity comparison result between the target image and any image to be compared is output.

[0138] Specifically, for example, if the environmental similarity is greater than the first similarity threshold, the environmental similarity comparison result resu_1 is "the environment of the target image is similar to the environment of the image to be compared"; if the subject similarity is less than the second similarity threshold, the subject similarity comparison result resu_2 is "the subject of the target image is not similar to the subject of the image to be compared"; based on the environmental similarity and the subject similarity, the comprehensive similarity is obtained. If the comprehensive similarity is greater than the third similarity threshold, the comprehensive similarity comparison result resu_3 is "the comprehensive features of the target image are similar to the comprehensive features of the image to be compared"; further, based on the environmental similarity comparison result resu_1, the subject similarity comparison result resu_2 and the comprehensive similarity comparison result resu_3, the similarity comparison result of the target image and any image to be compared is output as "the environment of the target image is similar to the environment of the image to be compared, the subject of the target image is not similar to the subject of the image to be compared, and the comprehensive features of the target image are similar to the comprehensive features of the image to be compared".

[0139] In this embodiment, on the basis of obtaining a target image to be processed and at least one image to be compared, the target image and the image to be compared are processed as follows: a mask of the image is obtained, and feature extraction is performed on the image to obtain all feature points; based on the mask, the feature values ​​of the feature points of the environment part of the image and the feature values ​​of the feature points of the main part of the image are processed to obtain environment-enhanced feature points and main-body-enhanced feature points respectively; then, based on the environment-enhanced feature points, an environment feature map is generated, and based on the main-body-enhanced feature points, a main-body feature map is generated; on this basis, the environmental similarity between the target image and any image to be compared, the similarity between the target image and any image to be compared, and the similarity between the target image and any image to be compared are calculated respectively. The subject similarity of the comparison image; further, according to the environmental similarity and the subject similarity, the similarity comparison result between the target image and any image to be compared is output; that is, by respectively determining the environmental similarity and the subject similarity between the target image and any image to be compared, the similarity between the target image and at least one image to be compared is determined, thereby avoiding the mutual influence between the environmental features and the subject features of the image, which causes the problem of poor accuracy in the similarity between the determined target image and at least one image to be compared, that is, solving the problem of poor accuracy in the similarity between the image of the claim application to be settled and the image of the claim application obtained based on the existing technical solution.

[0140] Figure 3 A schematic diagram of the structure of an image similarity comparison processing device provided in one embodiment of the present application is shown as follows: Figure 3 As shown, the image similarity comparison processing device 3 provided in this embodiment includes:

[0141] An acquisition module 31 is configured to acquire at least two images to be processed, wherein the at least two images include a target image and at least one image to be compared;

[0142] The processing module 32 is configured to perform the following steps for each of the at least two images: obtaining a mask of the image, wherein the mask is used to identify an environment portion and a subject portion in the image; performing feature extraction on the image to obtain all feature points; based on the mask, increasing the feature values ​​of the feature points of the environment portion in the image and decreasing the feature values ​​of the feature points of the subject portion in the image to obtain environment-enhanced feature points; based on the mask, increasing the feature values ​​of the feature points of the subject portion in the image and decreasing the feature values ​​of the feature points of the environment portion in the image to obtain subject-enhanced feature points; generating an environment feature map based on the environment-enhanced feature points; and generating a subject feature map based on the subject-enhanced feature points.

[0143] The comparison module 33 is used to calculate the similarity between the environmental feature map of the target image and the environmental feature map of any image to be compared, so as to obtain the environmental similarity between the target image and any image to be compared; calculate the similarity between the subject feature map of the target image and the subject feature map of any image to be compared, so as to obtain the subject similarity between the target image and any image to be compared; and output the similarity comparison result between the target image and any image to be compared based on the environmental similarity and the subject similarity.

[0144] In a possible embodiment, when the processing module 32 increases the feature values ​​of the feature points of the environment part in the image and reduces the feature values ​​of the feature points of the main part in the image based on the mask to obtain environment-enhanced feature points, it is specifically used to: increase the feature values ​​of the feature points of the environment part outside the mask according to the first preset weight to obtain a first environment feature value; reduce the feature values ​​of the feature points of the main part within the mask according to the second preset weight to obtain a first main feature value; arrange the first environment feature value and the first main feature value from large to small to obtain a first feature value sequence; determine the first environment feature value and / or the first main feature value in the first feature value sequence as the environment-enhanced feature value from large to small according to the first preset feature value number; and screen out the environment-enhanced feature point from all feature points according to the environment-enhanced feature value.

[0145] In a possible embodiment, the image similarity comparison processing device 3 also includes a weight pre-generation module, which is specifically used to: input the image into a pre-trained multimodal large model, and output at least one target environment feature identifier, and / or at least one target subject feature identifier; obtain a first weighting coefficient based on the number of identifiers of the target environment feature identifier; obtain a second weighting coefficient based on the number of identifiers of the target subject feature identifier; obtain a first preset weight based on the environment feature weight corresponding to each target environment feature identifier and the first weighting coefficient; obtain a second preset weight based on the subject feature weight corresponding to each target subject feature identifier and the second weighting coefficient.

[0146] In one possible embodiment, when the processing module 32 generates an environmental feature map based on environmental enhancement feature points, it is specifically used to: expand or compress the position coordinates of the environmental enhancement feature points according to the size relationship between the preset image resolution and the image resolution of the image to generate environmental target position coordinates; generate an environmental feature map based on the increased and / or decreased feature values ​​and environmental target position coordinates corresponding to the environmental enhancement feature points.

[0147] In one possible embodiment, before acquiring at least two images to be processed, the acquisition module 31 is further used to: acquire a target image; determine first shooting location information of the target image; identify the main object in the target image, and determine the transportation cost threshold of the main object, and the insurance benefit obtained by insuring the main object; obtain a transportation distance threshold based on the transportation cost threshold and the insurance benefit; obtain regional scope information based on the transportation distance threshold and the first shooting location information; acquire one or more similar images corresponding to the target image; determine second shooting location information of each similar image based on each similar image; determine whether each second shooting location information is within the regional scope information; determine the second shooting location information within the regional scope information as the target location information; and determine the similar images corresponding to the target location information as images to be compared.

[0148] In a possible embodiment, when the comparison module 33 calculates the similarity between the environmental feature map of the target image and the environmental feature map of any image to be compared to obtain the environmental similarity between the target image and any image to be compared, it is specifically used to: obtain the environmental feature vector of the target image based on the environmental feature map of the target image; obtain the environmental feature vector of the image to be compared based on the environmental feature map of the image to be compared; calculate the vector distance between the environmental feature vector of the target image and the environmental feature vector of any image to be compared to obtain the environmental similarity between the target image and any image to be compared.

[0149] Among them, the acquisition module 31, the processing module 32 and the comparison module 33 are connected in sequence.

[0150] The image similarity comparison processing device 3 provided in this embodiment can perform the following operations: Figure 2 The technical solution of the method embodiment shown has similar implementation principles and technical effects, which will not be repeated here.

[0151] Figure 4 This is a schematic diagram of the structure of the electronic device provided in this application. Figure 4 As shown, the electronic device 50 provided in this embodiment includes: at least one processor 501 and a memory 502. Optionally, the device 50 further includes a communication component 503. The processor 501, the memory 502 and the communication component 503 are connected via a bus 504.

[0152] In a specific implementation process, at least one processor 501 executes the computer-executable instructions stored in the memory 502, so that the at least one processor 501 performs the above method.

[0153] The specific implementation process of the processor 501 can be found in the above method embodiment. Its implementation principle and technical effects are similar and will not be repeated here in this embodiment.

[0154] In the above embodiments, it should be understood that the processor may be a central processing unit (CPU), other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASICs), etc. A general-purpose processor may be a microprocessor or any conventional processor. The steps of the method disclosed in the present invention may be directly executed by a hardware processor or by a combination of hardware and software modules within the processor.

[0155] The memory may include random access memory (RAM) and may also include non-volatile memory (NVM), such as at least one disk storage.

[0156] A bus can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Architecture (EISA) bus. Buses can be categorized as address buses, data buses, and control buses. For ease of illustration, the buses in the drawings of this application are not limited to just one bus or just one type of bus.

[0157] The present application also provides a computer program product, including a computer program, which implements the above method when executed by a processor.

[0158] The present application also provides a computer-readable storage medium, in which computer-executable instructions are stored. When a processor executes the computer-executable instructions, the above method is implemented.

[0159] The readable storage medium may be implemented by any type of volatile or non-volatile memory device, or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk. The readable storage medium may be any available medium that can be accessed by a general-purpose or special-purpose computer.

[0160] An exemplary readable storage medium is coupled to a processor so that the processor can read information from the readable storage medium and write information to the readable storage medium. Of course, the readable storage medium can also be an integral part of the processor. The processor and the readable storage medium can be located in an application specific integrated circuit (ASIC). Of course, the processor and the readable storage medium can also exist in the device as discrete components.

[0161] The division of units is merely a logical functional division; actual implementations may employ alternative divisions, such as combining or integrating multiple units or components into another system, or omitting or disabling certain features. Furthermore, any direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection between devices or units, either through an interface, electrical, mechanical, or other means.

[0162] Units described as separate components may or may not be physically separate, and components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of these units may be selected to achieve the purpose of this embodiment according to actual needs.

[0163] In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.

[0164] If a function is implemented as 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 invention, or the portion that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions for causing a computer device (which can be a personal computer, server, or network device, etc.) to execute all or part of the steps of the various embodiments of the method of the present invention. The aforementioned storage medium includes various media that can store program code, such as USB flash drives, mobile hard drives, read-only memories (ROMs), random access memories (RAMs), magnetic disks, or optical disks.

[0165] Those skilled in the art will appreciate that all or part of the steps in the above-described method embodiments can be implemented using hardware associated with program instructions. The aforementioned program can be stored in a computer-readable storage medium. When executed, the program performs the steps of the above-described method embodiments. The aforementioned storage medium includes various media capable of storing program code, such as ROM, RAM, magnetic disks, or optical disks.

[0166] Finally, it should be noted that those skilled in the art will readily identify other embodiments of the present invention after considering the specification and practicing the invention disclosed herein. The present invention is intended to cover any variations, uses, or adaptations of the present invention that follow the general principles of the present invention and include common knowledge or customary techniques in the art not disclosed herein. The present invention is not limited to the precise structure described above and illustrated in the accompanying drawings, and various modifications and variations may be made without departing from the scope thereof. The scope of the present invention is limited solely by the appended claims.

Claims

1. A method for image similarity comparison, characterized in that: include: Acquire at least two images to be processed, wherein the at least two images include a target image and at least one image to be compared; For each of the at least two images, perform the following steps: obtaining a mask of the image, wherein the mask is used to identify an environment portion and a subject portion in the image; Performing feature extraction on the image to obtain all feature points; Based on the mask, the feature values ​​of the feature points of the environment part in the image are increased, and the feature values ​​of the feature points of the main part in the image are decreased to obtain the environment enhanced feature points; Based on the mask, the feature values ​​of the feature points of the main body part in the image are increased, and the feature values ​​of the feature points of the environment part in the image are reduced to obtain the main body enhanced feature points; generating an environmental feature map according to the environmental enhancement feature points; generating a subject feature map according to the subject enhancement feature points; Calculating similarity between the environmental feature map of the target image and the environmental feature map of any image to be compared, so as to obtain environmental similarity between the target image and any image to be compared; Calculating similarity between the subject feature map of the target image and the subject feature map of any image to be compared, so as to obtain subject similarity between the target image and any image to be compared; Outputting a similarity comparison result between the target image and any image to be compared based on the environment similarity and the subject similarity; Before acquiring at least two images to be processed, the method further includes: Acquiring the target image; Determining first shooting location information of the target image; Identifying a subject object in the target image, and determining a transportation cost threshold for the subject object and insurance proceeds obtained by insuring the subject object; Obtaining a transportation distance threshold according to the transportation cost threshold and the insurance benefit; Obtaining regional range information according to the transportation distance threshold and the first shooting location information; Obtaining one or more similar images corresponding to the target image; determining second shooting location information of each similar image based on each similar image; determining whether each of the second shooting location information is within the area range information; determining the second shooting location information within the area range information as target location information; The similar image corresponding to the target location information is determined as the image to be compared.

2. The method according to claim 1, characterized in that The step of increasing the feature values ​​of the feature points of the environment portion of the image and decreasing the feature values ​​of the feature points of the main portion of the image based on the mask to obtain the environment enhanced feature points includes: The feature points of the environment outside the mask are increased by the feature values ​​of the feature points according to the first preset weight to obtain a first environment feature value; The feature points of the main body within the mask are reduced in their feature values ​​according to a second preset weight to obtain a first main body feature value; Arrange the first environmental characteristic value and the first subject characteristic value from largest to smallest to obtain a first characteristic value sequence; According to a first preset number of characteristic values, determining the first environmental characteristic values ​​and / or the first subject characteristic values ​​in the first characteristic value sequence from largest to smallest as environmental enhancement characteristic values; The environment enhancement feature point is selected from all the feature points according to the environment enhancement feature value.

3. The method according to claim 2, characterized in that The process of generating the first preset weight and the second preset weight includes: Inputting the image into a pre-trained multimodal large model, and outputting at least one target environment feature identifier and / or at least one target subject feature identifier; Obtaining a first weighting coefficient according to the number of identifications of the target environment feature identification; Obtaining a second weighting coefficient according to the number of identifications of the target subject feature identification; Obtaining the first preset weight according to the environmental feature weight corresponding to each target environmental feature identifier and the first weighting coefficient; The second preset weight is obtained according to the subject feature weight corresponding to each target subject feature identifier and the second weighting coefficient.

4. The method according to claim 1, wherein Generating an environmental feature map according to the environmental enhancement feature points includes: According to the relationship between the preset image resolution and the image resolution of the image, the position coordinates of the environmental enhancement feature points are expanded or compressed to generate the environmental target position coordinates; The environmental feature map is generated according to the increased and / or decreased feature values ​​corresponding to the environmental enhancement feature points and the environmental target position coordinates.

5. The method according to any one of claims 1 to 4, characterized in that The calculating the similarity between the environmental feature map of the target image and the environmental feature map of any image to be compared to obtain the environmental similarity between the target image and any image to be compared includes: Obtaining an environmental feature vector of the target image according to the environmental feature map of the target image; Obtaining an environmental feature vector of the image to be compared according to the environmental feature map of the image to be compared; The vector distance between the environmental feature vector of the target image and the environmental feature vector of any image to be compared is calculated to obtain the environmental similarity between the target image and any image to be compared.

6. An image similarity comparison processing device, characterized in that: include: An acquisition module, configured to acquire at least two images to be processed, wherein the at least two images include a target image and at least one image to be compared; The processing module is configured to perform the following steps for each of the at least two images: obtaining a mask for the image, wherein the mask is used to identify an environment portion and a main portion in the image; performing feature extraction on the image to obtain all feature points; based on the mask, increasing feature values ​​of feature points of the environment portion in the image and decreasing feature values ​​of feature points of the main portion in the image to obtain environment-enhanced feature points; based on the mask, increasing feature values ​​of feature points of the main portion in the image and decreasing feature values ​​of feature points of the environment portion in the image to obtain main portion-enhanced feature points; and generating an environment feature map based on the environment-enhanced feature points. generating a subject feature map according to the subject enhancement feature points; a comparison module, configured to calculate a similarity between an environmental feature map of the target image and an environmental feature map of any image to be compared, so as to obtain an environmental similarity between the target image and the image to be compared; calculate a similarity between a subject feature map of the target image and the subject feature map of any image to be compared, so as to obtain a subject similarity between the target image and the image to be compared; and output a similarity comparison result between the target image and the image to be compared based on the environmental similarity and the subject similarity; Before acquiring at least two images to be processed, the acquisition module is further used to acquire the target image; determine the first shooting location information of the target image; identify the main object in the target image, and determine the transportation cost threshold of the main object, and the insurance benefit obtained by insuring the main object; obtain the transportation distance threshold based on the transportation cost threshold and the insurance benefit; obtain the regional scope information based on the transportation distance threshold and the first shooting location information; acquire one or more similar images corresponding to the target image; determine the second shooting location information of each similar image based on each similar image; determine whether each second shooting location information is within the regional scope information; determine the second shooting location information within the regional scope information as the target location information; and determine the similar image corresponding to the target location information as the image to be compared.

7. An electronic device, characterized in that: include: a processor, and a memory communicatively connected to the processor; The memory stores computer-executable instructions; The processor executes the computer-executable instructions stored in the memory to implement the method according to any one of claims 1 to 5.

8. A computer-readable storage medium, characterized in that The computer-readable storage medium stores computer-executable instructions, which are used to implement the method according to any one of claims 1 to 5 when executed by a processor.

9. A computer program product, characterized in that The invention comprises a computer program, which implements the method according to any one of claims 1 to 5 when executed by a processor.

Citation Information

Patent Citations

  • Anti-fraud detection method and device, computer equipment and storage medium

    CN112232971A

  • Faster-RCNN-based object space distinguishing method and device, computer equipment and storage medium

    CN114120160A