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

By using mask adjustment feature values ​​in image processing to generate feature maps, the calculation environment and subject similarity are solved, and the problem of poor image similarity ratio accuracy in the prior art is solved, and a more accurate identification of repeated claims applications is achieved.

CN120164003AActive Publication Date: 2025-06-17PEOPLE'S INSURANCE COMPANY OF CHINA
View PDF 8 Cites 0 Cited by

Patent Information

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

AI Technical Summary

Technical Problem

In the prior art, the degree of similarity between the images to be claimed and the images to be claimed and the images to be claimed are poor, making it difficult to effectively identify the duplicate claims.

Method used

By acquiring the target image to be processed and the image to be compared, the mask is used to identify the environmental part and the subject part in the image, the feature points are extracted and the characteristic values ​​are adjusted according to the mask, an environmental feature map and the subject feature map are generated, and the environment similarity and subject similarity are calculated to output the similar comparison result.

Benefits of technology

It improves the accuracy of image similarity comparison, avoids the problem of inaccurate similarity caused by the mutual influence of environmental features and subject features, and effectively identify repeated claims applications.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120164003A_ABST
    Figure CN120164003A_ABST
Patent Text Reader

Abstract

The invention provides an image similarity comparison processing method, an electronic device, a storage medium and a program product, and relates to the technical field of image processing, on the basis of obtaining a to-be-processed target image and a to-be-compared image, processing the target image and the to-be-compared image: obtaining a mask of the image, performing feature extraction on the image, and obtaining all feature points; based on the mask, processing the feature values of the feature points of the environment part in the image and the feature values of the feature points of the main body part in the image to obtain environment enhanced feature points and main body enhanced feature points; generating an environment feature map based on the environment enhancement feature points, and generating a main body feature map based on the main body enhancement feature points; calculating the environment similarity between the target image and any one to-be-compared image and the main body similarity between the target image and any one to-be-compared image; outputting a similarity comparison result according to the environment similarity and the subject similarity; the problem that a similar comparison result generated based on an existing technical scheme is poor in accuracy is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of image processing technologies, and particularly to an image similarity comparison processing method, an electronic device, a storage medium, and a program product. Background Art

[0002] With the development of insurance business, in the breeding and livestock industry, users usually insure the breeding objects to obtain corresponding claims after the abnormal death of the breeding objects. However, in the case of the abnormal death of breeding objects, there may be a situation where repeated claim applications are initiated for the same abnormally dead breeding object.

[0003] In the prior art, the similarity between the image of the claim application to be processed and the image of the already processed claim application is usually determined by inputting them into an image recognition model, and then it is determined whether the claim application to be processed is a repeated claim application based on the similarity between the images.

[0004] However, the similarity between the image of the claim application to be processed and the image of the already processed claim application obtained by the prior art solution has the problem of poor accuracy. Summary of the Invention

[0005] The image similarity comparison processing method, electronic device, storage medium, and program product provided by the embodiments of this application are used to solve the problem that the similarity between the image of the claim application to be processed and the image of the already processed claim application obtained by the prior art solution has poor accuracy.

[0006] In a first aspect, an embodiment of the present application provides an image similarity comparison processing method, including: obtaining at least two images to be processed, where 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, where the mask is used to identify an environmental part and a main body part in the image; extracting features of the image to obtain all feature points; based on the mask, increasing the feature values of the feature points in the environmental part of the image and decreasing the feature values of the feature points in the main body part of the image to obtain environmentally enhanced feature points; based on the mask, increasing the feature values of the feature points in the main body part of the image and decreasing the feature values of the feature points in the environmental part of the image to obtain main body enhanced feature points; generating an environmental feature map according to the environmentally enhanced feature points; generating a main body feature map according to the main body enhanced feature points; 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 the any image to be compared; calculating the similarity between the main body feature map of the target image and the main body feature map of any image to be compared to obtain the main body similarity between the target image and the any image to be compared; and outputting a similarity comparison result between the target image and any image to be compared according to the environmental similarity and the main body similarity.

[0007] In a possible implementation manner, the step of increasing the feature values of the feature points in the environmental part of the image and decreasing the feature values of the feature points in the main body part of the image based on the mask to obtain environmentally enhanced feature points includes: increasing the feature values of the feature points in the environmental part outside the mask according to a first preset weight to obtain a first environmental feature value; decreasing the feature values of the feature points in the main body part inside the mask according to a second preset weight to obtain a first main body feature value; arranging the first environmental feature value and the first main body feature value in descending order to obtain a first feature value sequence; determining the first environmental feature value and / or the first main body feature value in the first feature value sequence as environmentally enhanced feature values according to a first preset number of feature values in descending order; and screening out the environmentally enhanced feature points from all the feature points according to the environmentally enhanced feature values.

[0008] In a possible implementation manner, the generation process of the first preset weight and the second preset weight includes: inputting the image into a pre-trained multi-modal large model to output at least one target environmental feature identifier and / or at least one target subject feature identifier; obtaining a first weighting coefficient according to the number of identifiers of the target environmental feature identifier; obtaining a second weighting coefficient according to the number of identifiers of the target subject feature identifier; obtaining the first preset weight according to the environmental feature weights corresponding to the target environmental feature identifiers and the first weighting coefficient; obtaining the second preset weight according to the subject feature weights corresponding to the target subject feature identifiers and the second weighting coefficient.

[0009] In a possible implementation manner, the generating the environmental feature map according to the environmentally enhanced feature points includes: performing an expansion process or a compression process on the position coordinates of the environmentally enhanced 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; generating the environmental feature map according to the increased and / or decreased feature values corresponding to the environmentally enhanced feature points and the environmental target position coordinates.

[0010] In a possible implementation manner, before obtaining at least two images to be processed, it further includes: obtaining the target image; determining the first shooting location information of the target image; identifying the subject object in the target image and determining the transportation cost threshold of the subject object and the insurance benefit 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 the second shooting location information of each similar image according to each similar image; determining whether each second shooting location information is within the regional range information; determining the second shooting location information within the regional range information as the target location information; and determining the similar image corresponding to the target location information as the image to be compared.

[0011] In a possible implementation manner, 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 the any image to be compared includes: obtaining the environmental feature vector of the target image according to the environmental feature map of the target image; obtaining the environmental feature vector of the image to be compared according to 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 the any image to be compared to obtain the environmental similarity between the target image and the any image to be compared.

[0012] Second aspect, an embodiment of the present application provides an image similarity comparison processing device, including:

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

[0014] A processing module, configured to perform the following steps for each of the at least two images: acquire a mask of the image, where the mask is used to identify an environmental part and a main body part in the image; extract features of the image to obtain all feature points; based on the mask, increase the feature values of the feature points of the environmental part in the image and decrease the feature values of the feature points of the main body part in the image to obtain environment-enhanced feature points; based on the mask, increase the feature values of the feature points of the main body part in the image and decrease the feature values of the feature points of the environmental part in the image to obtain main body-enhanced feature points; generate an environmental feature map according to the environment-enhanced feature points; generate a main body feature map according to the main body-enhanced feature points;

[0015] A comparison module, configured to calculate the similarity between the environmental feature map of the target image and the environmental feature map of any comparison image to be compared to obtain the environmental similarity between the target image and the any comparison image to be compared; calculate the similarity between the main body feature map of the target image and the main body feature map of any comparison image to be compared to obtain the main body similarity between the target image and the any comparison image to be compared; output the similarity comparison result between the target image and any comparison image to be compared according to the environmental similarity and the main body similarity.

[0016] In a possible implementation manner, when the processing module increases the feature values of the feature points of the environmental part in the image and decreases the feature values of the feature points of the main body part in the image based on the mask to obtain environment-enhanced feature points, it is specifically configured to: increase the feature values of the feature points of the environmental part outside the mask according to a first preset weight to obtain a first environmental feature value; decrease the feature values of the feature points of the main body part inside the mask according to a second preset weight to obtain a first main body feature value; arrange the first environmental feature value and the first main body feature value in descending order to obtain a first feature value sequence; determine, according to a first preset number of feature values, the first environmental feature value and / or the first main body feature value in the first feature value sequence from largest to smallest as environment-enhanced feature values; screen out the environment-enhanced feature points from all the feature points according to the environment-enhanced feature values.

[0017] In a possible implementation, the image similarity comparison processing device further includes a weight pre-generation module, and the weight pre-generation module is specifically configured to: input the image into a pre-trained multi-modal 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 according to the number of the target environment feature identifiers; obtain a second weighting coefficient according to the number of the target subject feature identifiers; obtain the first preset weight according to the environmental feature weights corresponding to the respective target environment feature identifiers and the first weighting coefficient; and obtain the second preset weight according to the subject feature weights corresponding to the respective target subject feature identifiers and the second weighting coefficient.

[0018] In a possible implementation, when generating the environmental feature map according to the environmental enhancement feature points, the processing module is specifically configured to: perform an expansion process or a compression process on 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, so as to generate environmental target position coordinates; and 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 implementation, before obtaining at least two images to be processed, the obtaining module is further configured to: obtain the target image; determine the first shooting location information of the target image; identify the subject object in the target image, and determine the transportation cost threshold of the subject object and the insurance proceeds obtained by insuring the subject object; obtain the transportation distance threshold according to the transportation cost threshold and the insurance proceeds; obtain the regional range information according to the transportation distance threshold and the first shooting location information; obtain one or more similar images corresponding to the target image; determine the second shooting location information of each similar image according to each similar image; determine whether each of the second shooting location information is within the regional range information; determine the second shooting location information within the regional range 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 implementation, when 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 the any image to be compared, the comparison module is specifically configured to: obtain the environmental feature vector of the target image according to the environmental feature map of the target image; obtain the environmental feature vector of the image to be compared according to the environmental feature map of the image to be compared; and calculate the vector distance between the environmental feature vector of the target image and the environmental feature vector of the any image to be compared to obtain the environmental similarity between the target image and the any image to be compared.

[0021] In a third aspect, an embodiment of the present application provides an electronic device, including: a memory and 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 implementation manners 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, and when the computer-executable instructions are executed by a processor, they are used to implement the above first aspect and / or various possible implementation manners of the first aspect.

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

[0026] The image similarity comparison processing method, electronic device, storage medium, and program product provided by the embodiments of the present application, on the basis of obtaining a target image to be processed and at least one image to be compared, perform the following processing on the target image and the images to be compared: obtain a mask of the image, extract features of the image to obtain all feature points; based on the mask, process the feature values of the feature points in the environmental part of the image and the feature values of the feature points in the main body part of the image to obtain environmental enhanced feature points and main body enhanced feature points respectively; then, based on the environmental enhanced feature points, generate an environmental feature map, and based on the main body enhanced feature points, generate a main body feature map; on this basis, calculate the environmental 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 respectively; further, according to the environmental similarity and the main body similarity, output the similarity comparison result between the target image and any image to be compared; that is, by respectively determining the environmental similarity and the main body similarity between the target image and any image to be compared, the similarity degree between the target image and at least one image to be compared is determined, avoiding the problem that the environmental features and main body features of the image affect each other, resulting in poor accuracy in determining the similarity degree between the target image and at least one image to be compared, that is, solving the problem of poor accuracy in the similarity degree between the image of the claim application to be processed and the image of the claimed application based on the existing technical solution. BRIEF DESCRIPTION OF THE DRAWINGS

[0027] The accompanying drawings here are incorporated into the specification and form a part of this specification, showing embodiments consistent with the present application, and are used together with the specification to explain the principles of the present application.

[0028] Figure 1 Scenario schematic diagram of the image similarity comparison processing method provided by this application;

[0029] Figure 2 Flowchart of the image similarity comparison processing method provided by an embodiment of this application;

[0030] Figure 3 Structural schematic diagram of the image similarity comparison processing device provided by an embodiment of this application;

[0031] Figure 4 Structural schematic diagram of the electronic device provided by this application.

[0032] Through the above-mentioned drawings, specific embodiments of this application have been shown, and there will be more detailed descriptions hereinafter. These drawings and textual descriptions are not intended to limit the scope of the concept of this application in any way, but to illustrate the concept of this application to those skilled in the art by referring to specific embodiments. Detailed implementation manners

[0033] Here, the exemplary embodiments will be described in detail, and the examples are shown in the drawings. When the following description refers to the drawings, unless otherwise indicated, the same numerals in different drawings represent the same or similar elements. The implementation manners described in the following exemplary embodiments do not represent all implementation manners consistent with this application. On the contrary, they are merely examples of devices and methods consistent with some aspects of this application as detailed in the appended claims.

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

[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 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 need to comply with the relevant laws, regulations, and standards of the relevant region, and a corresponding operation entry is provided for the user to choose to authorize or refuse.

[0036] With the development of insurance business, in the breeding and livestock industry, users usually insure the breeding entities to obtain corresponding claims after the abnormal death of the breeding entities. However, in the case of the abnormal death of the breeding entities, there may be a situation where repeated claim applications are initiated for the same abnormally dead breeding entity. In the prior art, the similarity between the image of the claim application to be processed and the image of the processed claim application is usually determined by inputting them into an image recognition model, and then it is determined whether the claim application to be processed is a repeated claim application based on the similarity between the images. However, the similarity between the image of the claim application to be processed and the image of the processed claim application obtained by the prior art solution has the problem of poor accuracy.

[0037] The application scenario of the embodiment of the present application will be explained below:

[0038] The technical solution of the present application and how the technical solution of the present application solves the above technical problems will be described in detail with specific embodiments below. These specific embodiments below 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 with reference to the accompanying drawings.

[0039] Figure 1 It is a schematic diagram of the scenario of the image similarity comparison processing method provided by the present application. As Figure 1 shown, the specific application scenario of the present application is a scenario for determining the similarity between a target image and at least one image to be compared. Among them, the target image corresponds to the image of the claim application to be processed in the prior art, and the image to be compared corresponds to the image of the processed claim application in the prior art; the execution subject of the method provided by the embodiment of the present application can be any form of electronic device. By executing the method provided by the embodiment of the present application, based on obtaining the target image and at least one image to be compared, the environment part and the main body part in the target image and at least one image to be compared are respectively recognized and separated, and then the corresponding environment feature map and main body feature map are generated; further, by calculating the similarity between the environment feature map of the target image and the environment feature map of any image to be compared, the environment similarity between the target image and any image to be compared is obtained; calculating the similarity between the main body feature map of the target image and the main body feature map of any image to be compared, the main body similarity between the target image and any image to be compared is obtained; furthermore, according to the environment similarity and the main body similarity, the similarity comparison result between the target image and any image to be compared is output, that is, the similarity between the target image and at least one image to be compared is determined, which also solves the problem of poor accuracy in the similarity between the image of the claim application to be processed and the image of the processed claim application obtained based on the prior art solution.

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

[0041] Step S101: Obtain at least two images to be processed, where 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 claim application to be processed in the prior art, and the image to be compared corresponds to the image of the claimed application in the prior art. Further, the electronic device obtains the target image to be processed and at least one image to be compared in the database, so as to implement the subsequent similarity comparison processing between the target image and the image to be compared, and further implement the judgment on whether the user has initiated a repeated claim application for the same abnormally dead breeding body according to the similarity comparison result obtained from the similarity comparison processing.

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

[0044] Step S100a: Obtain the target image.

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

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

[0047] Step S100c: Identify the main object in the target image, and determine the transportation cost threshold of the main object and the insurance benefit obtained by the insured main object.

[0048] Exemplarily, by identifying the main object in the target image, the object category of the main object is determined. Further, according to the object category of the main object, the transportation cost threshold for transporting the main object is determined. For example, the transportation cost threshold is the transportation cost per kilometer. The transportation cost per kilometer for transporting a cow is , and the transportation cost per kilometer for transporting a sheep is ; further, according to the object category of the main object, the insurance benefit obtained by the insured main object is determined, that is, the insurance benefit obtained by the user after initiating a claim application after the main object dies abnormally. For example, after a cow dies abnormally, the insurance benefit obtained by the user is , and 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] Exemplarily, substitute the transportation cost threshold and the insurance benefit into Equation (1) to calculate the transportation distance threshold. , where 1, 2, 3, , .

[0051] (1)

[0052] Where is the insurance benefit obtained by the insured subject; is the transportation cost threshold of the transportation subject.

[0053] Specifically, for example, if the subject is a sheep, then , and then substitute the transportation cost per kilometer for transporting one sheep , and the insurance benefit obtained by the user after one sheep dies abnormally into Equation (1) to calculate the corresponding transportation distance threshold .

[0054] Step S100e: Obtain area range information based on the transportation distance threshold and the first shooting location information.

[0055] Exemplarily, use the longitude and latitude data corresponding to the first shooting location information as the center of a circle, and use the transportation distance threshold as the radius of the circle to obtain the corresponding circular area. Then, determine the corresponding circular area as the area range, and then obtain the area range information based on the longitude and latitude data within this area range.

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

[0057] Exemplarily, based on the subject object and / or environmental feature identifier of the target image, filter out one or more similar images from the images stored in the database. Among them, the subject object in the similar image is similar to the subject 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 subject object and environmental feature identifier in the similar image are similar to the subject object and environmental feature identifier of the target image.

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

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

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

[0061] Step S100i: determining the second shooting location information within the area range information 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 judging whether the latitude and longitude data corresponding to each 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, that is, the second shooting location information is within the regional scope information, then the second shooting location information is determined as the target location information. Further, the similar image corresponding to the target location information can be determined as the image to be compared, thereby implementing step S101 and implementing the similarity comparison processing between the target image and the image to be compared in the subsequent steps.

[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, so as to obtain 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 an image segmentation model, which segments and identifies the main part and the surrounding part in the image, using "0" to represent the pixel points corresponding to the surrounding 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 positions, thereby obtaining a 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 extract features from the image, thereby obtaining all feature points of the image.

[0070] Step S105: Based on the mask, increase the feature values of the feature points in the environmental part of the image and decrease the feature values of the feature points in the main body part of the image to obtain environmentally enhanced feature points.

[0071] Exemplarily, based on the environmental part and the main body part of the image determined by the mask, increase the feature values of the feature points in the environmental part of the image respectively to obtain the increased feature values, and decrease the feature values of the feature points in the main body part of the image to obtain the decreased feature values; then, based on the increased feature values and the decreased feature values, determine a preset number of feature points, and further determine the determined preset number of feature points as environmentally enhanced feature points; wherein, the environmentally enhanced feature points include the feature points in the environmental part corresponding to the increased feature values and / or the feature points in the main body part corresponding to the decreased feature values.

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

[0073] Step S1051: Increase the feature values of the feature points in the environmental part outside the mask according to the first preset weight to obtain the first environmental feature values.

[0074] Exemplarily, for the feature points in the environmental part corresponding to the mask, increase the feature values of the feature points according to the first preset weight to obtain the first environmental feature values.

[0075] Step S1052: Decrease the feature values of the feature points in the main body part inside the mask according to the second preset weight to obtain the first main body feature values.

[0076] Exemplarily, for the feature points in the main body part corresponding to the mask, decrease the feature values of the feature points according to the second preset weight to obtain the first main body feature values.

[0077] Step S1053: Arrange the first environmental feature values and the first main body feature values in descending order to obtain the first feature value sequence.

[0078] Exemplarily, based on the magnitudes of the feature values, sort the first environmental feature values and the first main body feature values in descending order according to the feature values to obtain the first feature value sequence.

[0079] Step S1054: Determine the first environmental feature values and / or the first main body feature values in the first feature value sequence as environmentally enhanced feature values in descending order according to the first preset number of feature values.

[0080] Step S1055: Screen out the environmentally enhanced feature points from all the feature points according to the environmentally enhanced feature values.

[0081] Exemplarily, for the first environmental feature value and / or the first subject feature value in the first eigenvalue sequence, in a descending order, select the first environmental feature value and / or the first subject feature value with the number of the first preset feature values, and then determine the environmental enhancement feature value based on the first environmental feature value and / or the first subject feature value selected according to the number of the first preset feature values; further, from all the feature points, determine the feature points corresponding to the environmental enhancement feature value as the environmental enhancement feature points, that is, screen out the environmental enhancement feature points from all the feature points; wherein, the environmental enhancement feature points include the feature points of the environmental part and / or the feature points of the subject part.

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

[0083] Step S105a: Input the image into a pre-trained multi-modal large model to output at least one target environmental feature identifier and / or at least one target subject feature identifier.

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

[0085] Step S105c: Obtain a second weighting coefficient according to the number of the target subject feature identifiers.

[0086] Exemplarily, the pre-trained multi-modal large model identifies the target environmental feature identifiers and the target subject feature identifiers in the image, and then outputs at least one target environmental feature identifier and / or at least one target subject feature identifier; further, count the number of the output target environmental feature identifiers to obtain the number of the target environmental feature identifiers, and then obtain a first weighting coefficient according to the number of the target environmental feature identifiers; count the number of the output target subject feature identifiers to obtain the number of the target subject feature identifiers, and then obtain a second weighting coefficient according to the number of the target subject feature identifiers.

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

[0088] Exemplarily, perform a summation calculation on the environmental feature weights corresponding to the target environmental feature identifiers to obtain the total environmental feature weight; then calculate the product of the total environmental feature weight and the first weighting coefficient, that is, obtain the first preset weight.

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

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

[0091] In the steps of this embodiment, the first preset weight is associated with the number of identifiers of the target environment feature identifier, and the second preset weight is associated with the number of identifiers of the target subject feature identifier by processing the environmental feature weight corresponding to the target environment feature identifier with the first weighting coefficient to obtain the first preset weight and processing the subject feature weight corresponding to the target subject feature identifier with the second weighting coefficient to obtain the second preset weight; further, the first environmental feature value obtained by the first preset weight in step S1051 is associated with the number of identifiers of the target environment 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; further, the accuracy of the determined environmental enhancement feature value is improved, and further, the accuracy of the environmental enhancement feature points selected from all the feature points is improved.

[0092] Step S106: Based on the mask, increase the feature values of the feature points of the main body part in the image and decrease the feature values of the feature points of the environment part in the image to obtain the main body enhancement feature points.

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

[0094] Step S1061: Reduce the feature values of the feature points of the environment part outside the mask according to the first preset weight to obtain the second environmental feature value.

[0095] Exemplarily, for the feature points of the environment part corresponding to the mask, reduce the feature values of the feature points based on the first preset weight to obtain the second environmental feature value.

[0096] Step S1062: Increase the feature values of the feature points of the main body part inside the mask according to the second preset weight to obtain the second subject feature value.

[0097] Exemplarily, for the feature points of the main body part corresponding to the mask, increase the feature values of the feature points based on the second preset weight to obtain the second subject feature value.

[0098] Step S1063: Arrange the second environmental feature value and the second subject feature value in descending order to obtain the second feature value sequence.

[0099] Exemplarily, based on the magnitudes of the feature values, sort the second environmental feature value and the second subject feature value in descending order according to the feature values to obtain the second feature value sequence.

[0100] Step S1064: Determine the main body enhancement feature values from the second environmental feature values and / or the second main body feature values in the second feature value sequence in descending order according to the number of second preset feature values.

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

[0102] Exemplarily, for the second environmental feature values and / or the second main body feature values in the second feature value sequence, select the second environmental feature values and / or the second main body feature values of the number of second preset feature values in descending order, and then determine the second environmental feature values and / or the second main body feature values selected based on the number of second preset feature values as the main body enhancement feature values; further, from all the feature points, determine the feature points corresponding to the main body enhancement feature values as the main body enhancement feature points, that is, screen out the main body enhancement feature points from all the feature points; wherein, the main body enhancement feature points include the feature points of the main body part and / or the feature points of the environmental part.

[0103] Step S107: Generate an environmental feature map according to the environmental enhancement feature points.

[0104] Exemplarily, based on the increased and / or decreased feature values corresponding to the environmental enhancement feature points, draw a feature region of corresponding size at the coordinate positions corresponding to the environmental enhancement feature points, such as drawing a circular region or a rectangular region of corresponding size; then, based on the drawn feature regions corresponding to the environmental enhancement feature points, the environmental feature map is obtained.

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

[0106] Step S1071: Perform an expansion process or a compression process on 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.

[0107] Step S1072: Generate an 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.

[0108] Exemplarily, determine the size relationship between the preset image resolution and the image resolution of the image. If the image resolution of the image is greater than the preset image resolution, perform compression processing on the position coordinates of the environmental enhancement feature points based on the preset image resolution to generate environmental target position coordinates; if the image resolution of the image is less than the preset image resolution, perform expansion processing on the position coordinates of the environmental enhancement feature points based on the preset image resolution to generate environmental target position coordinates; if the image resolution of the image is equal to the preset image resolution, the environmental target position coordinates are the position coordinates of the environmental enhancement feature points, that is, no expansion processing or compression processing is performed on the position coordinates of the environmental enhancement feature points.

[0109] Furthermore, after obtaining the environmental target position coordinates, based on the increased and / or decreased feature values corresponding to the environmental enhancement feature points, draw a feature region of corresponding size at the coordinate position of the environmental target position coordinates corresponding to the environmental enhancement feature points, such as drawing a circular region or a rectangular region of corresponding size; furthermore, based on the drawn feature region corresponding to the environmental enhancement feature points, the environmental feature map is obtained.

[0110] In the steps of this embodiment, by comparing the size of the preset image resolution and the image resolution of the image, the position coordinates of the environmental enhancement feature points in the image resolution of the image are expanded or compressed based on the preset image resolution, and then the environmental target position coordinates are obtained, and further the environmental feature map is obtained; it realizes processing the position coordinates in images of different resolutions into position coordinates under the same resolution, and then generating the corresponding environmental feature map, providing a normalized environmental feature map for calculating the similarity between the environmental feature map of the target image and the environmental feature map of any image to be compared in the subsequent steps, and improving the accuracy of similarity calculation.

[0111] Step S108, generate a subject feature map according to the subject enhancement feature points.

[0112] Exemplarily, based on the increased and / or decreased feature values corresponding to the subject enhancement feature points, draw a feature region of corresponding size at the coordinate position corresponding to the subject enhancement feature points, such as drawing a circular region or a rectangular region of corresponding size; furthermore, based on the drawn feature region corresponding to the subject enhancement feature points, the subject feature map is obtained.

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

[0114] Step S1081, perform expansion processing or compression processing on the position coordinates of the subject enhancement feature points according to the size relationship between the preset image resolution and the image resolution of the image to generate subject target position coordinates.

[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 manner of generating the subject feature map based on the subject enhancement feature points in steps S1081 - S1082 is the same as that of generating the environmental feature map based on the environmental enhancement feature points in steps S1071 - S1072, and will not be elaborated here one by one.

[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 embodiments of the present application do not make specific limitations, that is, the corresponding preset image resolutions can be selected according to the environmental enhancement feature points and the subject enhancement feature points respectively, that is, the corresponding preset image resolutions can be selected according to the environmental complexity corresponding to the environmental enhancement feature points and the subject complexity corresponding to the subject enhancement feature points respectively.

[0118] Step S109: Calculate 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.

[0119] Exemplarily, since the environmental feature map includes the 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, and then the environmental similarity between the target image and any image to be compared can be obtained.

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

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

[0122] Step S1092: Obtain the environmental feature vector of the image to be compared according to the environmental feature map of the image to be compared.

[0123] Step S1093: 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.

[0124] Exemplarily, since the environmental feature map includes increased and / or decreased feature values at positions corresponding to environmental enhancement feature points, and then, based on the increased and / or decreased feature values at positions corresponding to environmental enhancement feature points, the environmental feature map is vectorized to obtain the corresponding environmental feature vector; that is, based on the increased and / or decreased feature values at positions corresponding to environmental enhancement feature points in the environmental feature map of the target image, the environmental feature map of the target image is vectorized to obtain the environmental feature vector of the target image; based on the increased and / or decreased feature values at positions corresponding to 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 vectorized to obtain the environmental feature vector of the image to be compared.

[0125] Further, based on the cosine similarity, 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 corresponding cosine distance, and then the cosine distance is determined as the environmental similarity between the target image and the corresponding image to be compared. In the steps of this embodiment, since there may be differences in angle change, movement, rotation, and scaling between the environmental features of the target image and the image to be compared, using the cosine similarity to calculate the vector distance between the environmental feature vector of the target image and the environmental feature vector of any image to be compared can accurately capture the similarity between the environmental feature vector of the target image 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, calculate the similarity between the main feature map of the target image and the main feature map of any image to be compared to obtain the main similarity between the target image and any image to be compared.

[0128] Exemplarily, since the main feature map includes increased and / or decreased feature values corresponding to main enhancement feature points, and then, based on the increased and / or decreased feature values corresponding to the main feature map of the target image and the increased and / or decreased feature values corresponding to the main feature map of the 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 can be calculated, and then the main similarity between the target image and any image to be compared can be obtained.

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

[0130] Step S110a, obtain the main feature vector of the target image according to the main feature map of the target image.

[0131] Step S110b: Obtain the main feature vector of the image to be compared based on the main feature map of the image to be compared.

[0132] In this embodiment, the implementation manner of determining the main feature vector in steps S110a - S110b is the same as that of determining the environmental feature vector in steps S1091 - S1092, and will not be elaborated here one by one.

[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] Exemplarily, based on the Euclidean similarity, 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 the corresponding Euclidean distance can be obtained. Then, determine the Euclidean distance as the main similarity between the target image and the corresponding image to be compared. In the steps of this embodiment, since the pixel distribution between the main features of the target image and the image to be compared is uniform and the spatial change rate is low, using the 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 in pixel details between the main features of the target image and the image to be compared.

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

[0136] Step S111: Output the similarity comparison result between the target image and any image to be compared according to the environmental similarity and the main similarity.

[0137] Exemplarily, obtain the environmental similarity comparison result between the target image and any image to be compared according to the size relationship between the environmental similarity and the first similarity threshold; obtain the main similarity comparison result between the target image and any image to be compared according to the size relationship between the main similarity and the second similarity threshold; obtain the comprehensive similarity according to the environmental similarity and the main similarity, and obtain the comprehensive similarity comparison result between the target image and any image to be compared according to the size relationship between the comprehensive similarity and the third similarity threshold; furthermore, output the similarity comparison result between the target image and any image to be compared according to the environmental similarity comparison result, the main similarity comparison result, and the comprehensive similarity comparison result.

[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"; furthermore, 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, "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, based on obtaining the target image to be processed and at least one image to be compared, the following processing is performed on the target image and the image to be compared: obtaining the mask of the image, extracting the features of the image to obtain all feature points; based on the mask, processing the feature values of the feature points of the environmental part in the image and the feature values of the feature points of the subject part in the image to obtain environmental enhanced feature points and subject enhanced feature points respectively; furthermore, based on the environmental enhanced feature points, an environmental feature map is generated, and based on the subject enhanced feature points, a subject feature map is generated; on this basis, the environmental similarity between the target image and any image to be compared and the subject similarity between the target image and any image to be compared are calculated respectively; furthermore, according to the environmental similarity and the subject similarity, the similarity comparison result of 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 degree between the target image and at least one image to be compared is determined, avoiding the problem that the environmental features and subject features of the image affect each other, resulting in poor accuracy in determining the similarity degree between the target image and at least one image to be compared, that is, solving the problem of poor accuracy in the similarity degree between the image of the claim application to be processed and the image of the claim application that has been processed based on the existing technical solution.

[0140] Figure 3 It is a schematic structural diagram of an image similarity comparison processing device provided by an embodiment of the present application, as Figure 3 shown, the image similarity comparison processing device 3 provided in this embodiment includes:

[0141] An acquisition module 31, configured to acquire at least two images to be processed, where 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 at least two images: obtain a mask of the image, where the mask is used to identify the environmental part and the main part in the image; extract features from the image to obtain all feature points; based on the mask, increase the feature values of the feature points in the environmental part of the image and decrease the feature values of the feature points in the main part of the image to obtain environmentally enhanced feature points; based on the mask, increase the feature values of the feature points in the main part of the image and decrease the feature values of the feature points in the environmental part of the image to obtain main-part enhanced feature points; generate an environmental feature map according to the environmentally enhanced feature points; generate a main-part feature map according to the main-part enhanced feature points;

[0143] The comparison module 33 is configured to calculate 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; calculate the similarity between the main-part feature map of the target image and the main-part feature map of any image to be compared to obtain the main-part 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 according to the environmental similarity and the main-part similarity.

[0144] In a possible implementation manner, when the processing module 32 increases the feature values of the feature points in the environmental part of the image and decreases the feature values of the feature points in the main part of the image based on the mask to obtain environmentally enhanced feature points, it is specifically configured to: increase the feature values of the feature points in the environmental part outside the mask according to a first preset weight to obtain a first environmental feature value; decrease the feature values of the feature points in the main part inside the mask according to a second preset weight to obtain a first main-part feature value; arrange the first environmental feature value and the first main-part feature value in descending order to obtain a first feature value sequence; determine the first environmental feature value and / or the first main-part feature value in the first feature value sequence as environmentally enhanced feature values according to a first preset number of feature values; and screen out the environmentally enhanced feature points from all the feature points according to the environmentally enhanced feature values.

[0145] In a possible implementation manner, the image similarity comparison processing device 3 further includes a weight pre-generation module, and the weight pre-generation module is specifically configured to: input the image into a pre-trained multi-modal large model to output at least one target environmental feature identifier and / or at least one target main-part feature identifier; obtain a first weighting coefficient according to the number of identifiers of the target environmental feature identifier; obtain a second weighting coefficient according to the number of identifiers of the target main-part feature identifier; obtain a first preset weight according to the environmental feature weights corresponding to the target environmental feature identifiers and the first weighting coefficient; and obtain a second preset weight according to the main-part feature weights corresponding to the target main-part feature identifiers and the second weighting coefficient.

[0146] In a possible implementation, when the processing module 32 strengthens the feature points according to the environment to generate an environmental feature map, it is specifically configured to: perform an expansion process or a compression process on the position coordinates of the environment-strengthened feature points according to the relationship between the preset image resolution and the image resolution of the image, so as to generate environmental target position coordinates; generate an environmental feature map according to the increased and / or decreased feature values corresponding to the environment-strengthened feature points and the environmental target position coordinates.

[0147] In a possible implementation, before obtaining at least two images to be processed, the obtaining module 31 is further configured to: obtain a 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, as well as the insurance benefits obtained from insuring the main object; obtain a transportation distance threshold according to the transportation cost threshold and the insurance benefits; obtain regional range information according to the transportation distance threshold and the first shooting location information; obtain one or more similar images corresponding to the target image; determine the second shooting location information of each similar image according to each similar image; determine whether each second shooting location information is within the regional range information; determine the second shooting location information within the regional range information as the target location information; and determine the similar image corresponding to the target location information as the image to be compared.

[0148] In a possible implementation, 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 configured to: obtain the environmental feature vector of the target image according to the environmental feature map of the target image; obtain the environmental feature vector of the image to be compared according to the environmental feature map of the image to be compared; and 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 obtaining 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 execute the technical solution of the method embodiment as Figure 2 shown. The implementation principle and technical effects are similar, and will not be elaborated here.

[0151] Figure 4 is a schematic structural diagram of the electronic device provided in this application. As Figure 4 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. Among them, the processor 501, the memory 502, and the communication component 503 are connected through a bus 504.

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

[0153] For the specific implementation process of the processor 501, reference can be made to the above method embodiments. Their implementation principles and technical effects are similar, and will not be elaborated here in this embodiment.

[0154] In the above embodiments, it should be understood that the processor may be a central processing unit (Central Processing Unit, CPU for short), or other general-purpose processors, digital signal processors (Digital Signal Processor, DSP for short), application specific integrated circuits (Application Specific Integrated Circuit, ASIC for short), etc. The general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc. The steps of the method disclosed in combination with the invention can be directly implemented by a hardware processor, or implemented by a combination of hardware and software modules in the processor.

[0155] The memory may include a high-speed memory (Random Access Memory, RAM), and may also include a non-volatile memory (Non-volatile Memory, NVM), such as at least one disk memory.

[0156] The bus may be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, an Extended Industry Standard Architecture (EISA) bus, etc. The bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, the buses in the drawings of this application are not limited to only one bus or one type of bus.

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

[0158] This application also provides a computer-readable storage medium, in which computer-executable instructions are stored, and when the processor executes the computer-executable instructions, the above-mentioned method is implemented.

[0159] The above-readable storage medium can be implemented by any type of volatile or non-volatile storage 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 memory, flash memory, magnetic disk or optical disk. The readable storage medium can be any available medium accessible by a general-purpose or special-purpose computer.

[0160] An exemplary readable storage medium is coupled to the processor, enabling the processor to read information from the readable storage medium and write information to the readable storage medium. Of course, the readable storage medium can also be a component 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 as discrete components in a device.

[0161] The division of units is only a logical function division. In actual implementation, there may be other division methods. 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 couplings or direct couplings or communication connections to each other can be indirect couplings or communication connections through some interfaces, devices or units, and can be in electrical, mechanical or other forms.

[0162] The units described as separate components may or may not be physically separated. The components displayed as units may or may not be physical units, that is, they can be located in one place or distributed to 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.

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

[0164] If a function 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 invention, in essence, or the part that contributes to the prior art, or a 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 several 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 of various embodiments of the present invention. The aforementioned storage medium includes: USB flash drives, mobile hard disks, read-only memories (ROMs), random access memories (RAMs), magnetic disks, or optical discs, etc., various media that can store program codes.

[0165] Those of ordinary skill in the art can understand that all or part of the steps of implementing the above method embodiments can be completed by hardware related to program instructions. The aforementioned program can be stored in a computer-readable storage medium. When this program is executed, it executes the steps including the above method embodiments; and the aforementioned storage medium includes: ROMs, RAMs, magnetic disks, or optical discs, etc., various media that can store program codes.

[0166] Finally, it should be noted that: After considering the specification and practicing the invention disclosed herein, those skilled in the art will easily think of other implementation manners of the present invention. The present invention is intended to cover any variations, uses, or adaptive changes of the present invention. These variations, uses, or adaptive changes follow the general principles of the present invention and include the common general knowledge or conventional technical means in the technical field of the present invention that are not disclosed in the present invention. It is not limited to the exact structures described above and shown in the drawings, and various modifications and changes can be made without departing from its scope. The scope of the present invention is only limited 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: Acquire 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 reduced 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; Generate an environmental feature map according to the environmental enhancement feature points; Generating a subject feature map according to the subject enhancement feature points; 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; 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; According to the environment similarity and the subject similarity, a similarity comparison result between the target image and any image to be compared is output.

2. The method according to claim 1, characterized in that The step of 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 based on the mask to obtain the environment enhanced feature points includes: The feature points of the environment outside the mask are increased by a feature value of the feature points according to a first preset weight to obtain a first environment feature value; The feature points of the main body within the mask are reduced in feature value according to a second preset weight to obtain a first main feature value; Arrange the first environment characteristic value and the first subject characteristic value from large to small to obtain a first characteristic value sequence; According to a first preset number of characteristic values, the first environment characteristic value and / or the first subject characteristic value in the first characteristic value sequence are determined from largest to smallest as environment 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, characterized in that The step of 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 enlarged or compressed to generate the environmental target position coordinates; The environmental characteristic map is generated according to the increased and / or decreased characteristic values ​​corresponding to the environmental enhancement characteristic points and the environmental target position coordinates.

5. The method according to claim 1, characterized in that Before acquiring at least two images to be processed, the method further includes: Acquire the target image; Determining first shooting location information of the target image; Identify the subject object in the target image, and determine a transportation cost threshold of the subject object and insurance benefits 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; Acquire one or more similar images corresponding to the target image; Determining second shooting location information of each similar image according to 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.

6. The method according to any one of claims 1 to 5, 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.

7. An image similarity comparison processing device, characterized in that: include: An acquisition module, used for acquiring 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 used 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 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 and reducing the feature values ​​of the feature points of the environment part in the image to obtain main part enhancement feature points; generating an environment feature map according to the environment enhancement feature points; Generating a subject feature map according to the subject enhancement feature points; 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 the similarity comparison result between the target image and any image to be compared according to the environmental similarity and the subject similarity.

8. 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 6.

9. 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 6 when executed by a processor.

10. 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 6 when being executed by a processor.

Citation Information

Patent Citations

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

    CN112232971A

  • Image similarity calculation method and system based on feature fusion and storage medium

    CN113283463A

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

    CN114120160A

  • Claim settlement detection method and device, equipment and storage medium

    CN115359272A

  • Image duplicate checking method and device, computer equipment and storage medium

    CN115661472A