Image effect evaluation method, device, storage medium and computer equipment
By acquiring and fusing image visual features and placement attribute features, the image effect is automatically evaluated using pre-trained models, solving the problem of time-consuming, labor-intensive and low accuracy of manual analysis, and achieving efficient and accurate image effect evaluation.
Patent Information
- Application Number
- CN202510369323.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-27
- Publication Date
- 2025-08-29
- Estimated Expiration
- 2045-03-27
AI Technical Summary
In the prior art, it is time-consuming and laborious to analyze image effects manually, and the uneven technical level of analysts leads to the problem of evaluation errors.
By obtaining the target image's placement attribute data and image visual characteristics, the pre-trained effect evaluation model is input to automatically evaluate after the fusion process to avoid manual participation.
It improves the efficiency and accuracy of image effect evaluation and realizes automatic evaluation of image effect.
Smart Images

Figure CN120298350B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of information technology, and in particular to an image effect evaluation method, device, storage medium and computer equipment. Background Art
[0002] Currently, e-commerce platforms use images to display product information. Image performance analysis is necessary to understand how images convey information and stimulate user exploration, thereby optimizing image design and improving image effectiveness.
[0003] Currently, image effects are usually analyzed manually. However, this effect analysis method is time-consuming and labor-intensive, and due to the uneven technical level of analysts, there may be errors in the image effect analysis. Summary of the Invention
[0004] The present invention provides an image effect evaluation method, device, storage medium and computer equipment, which are mainly capable of improving the efficiency and accuracy of image effect evaluation.
[0005] According to a first aspect of the present invention, there is provided a method for evaluating an image effect, comprising:
[0006] In response to an effect evaluation instruction of a target image, acquiring delivery attribute data of the target image;
[0007] Extracting the image visual features of the target image and the delivery attribute features of the delivery attribute data, and fusing the image visual features and the delivery attribute features to obtain effect evaluation fusion features;
[0008] The effect evaluation fusion feature is input into a preset effect evaluation model to perform image effect evaluation to obtain an effect evaluation result of the target image, wherein the preset effect evaluation model is pre-trained based on a sample data set with effect labels.
[0009] Optionally, the fusing of the image visual features and the delivery attribute features to obtain effect evaluation fusion features includes:
[0010] Inputting the target image into a preset aesthetic scoring model for aesthetic scoring, and determining an aesthetic feature vector corresponding to the aesthetic score;
[0011] The image visual features, the aesthetic features, and the delivery attribute features are fused to obtain an effect evaluation fusion feature. The method of fusing the image visual features, the aesthetic features, and the delivery attribute features to obtain an effect evaluation fusion feature includes:
[0012] Using the image visual feature as a visual query vector, using the concatenated feature of the aesthetic feature and the delivery attribute feature as a first key-value vector, and interacting the visual query vector with the first key-value vector to obtain a visual context feature;
[0013] Using the aesthetic feature as an aesthetic query vector, using the concatenated feature of the image visual feature and the delivery attribute feature as a second key-value vector, and interacting the aesthetic query vector with the second key-value vector to obtain an aesthetic context feature;
[0014] Using the delivery attribute feature as a delivery query vector, using the concatenated feature of the image visual feature and the aesthetic feature as a third key-value vector, and interacting the delivery query vector with the third key-value vector to obtain a delivery context feature;
[0015] The visual context features, the aesthetic context features, and the delivery context features are aggregated to obtain the effect evaluation fusion features.
[0016] Optionally, inputting the effect evaluation fusion feature into a preset effect evaluation model to perform image effect evaluation to obtain an effect evaluation result of the target image includes:
[0017] Inputting the effect evaluation fusion feature into a preset effect evaluation model to perform image effect evaluation, and obtaining an effect evaluation result of the target image based on a visual chart display form;
[0018] A target effect having a contribution greater than a preset threshold is determined in the effect evaluation result, and an evaluation area corresponding to the target effect is determined in the target image, and the evaluation area is marked and the contribution is displayed.
[0019] Optionally, after inputting the effect evaluation fusion feature into a preset effect evaluation model to perform image effect evaluation and obtaining the effect evaluation result of the target image, the method further includes:
[0020] In response to an image generation instruction of an image to be generated, acquiring image generation requirement information of the image to be generated;
[0021] Based on the image generation requirement information, image effect evaluation keywords are extracted from an effect evaluation database, and the extracted image effect evaluation keywords are mapped into image generation guidance elements that meet an image generation guidance format using a preset mapping rule, wherein the effect evaluation database is constructed based on effect evaluation results of multiple images;
[0022] Determining an image generation prompt word template for the image to be generated, and filling the commodity theme information of the image to be generated and the image generation guide element into the image generation prompt word template to obtain an image generation prompt word;
[0023] The image generation prompt word is input into a preset image generation model to generate an image to obtain a newly generated image, wherein the preset image generation model is pre-trained based on a sample data set with image labels.
[0024] Optionally, extracting image effect evaluation keywords from an effect evaluation database based on the image generation requirement information includes:
[0025] Based on the image generation requirement information, extracting initial image effect evaluation keywords whose image effect evaluation results meet preset conditions from the effect evaluation database;
[0026] Determine the style combination probability of the image style corresponding to each of the initial image effect evaluation keywords, and determine the initial image effect evaluation keywords whose style combination probability is greater than a preset probability threshold among the initial image effect evaluation keywords as the image effect evaluation keywords.
[0027] Optionally, determining the style combination probability of the image styles corresponding to the initial image effect evaluation keywords includes:
[0028] Dividing each of the initial image effect evaluation keywords into a plurality of evaluation keyword groups according to the image to which they belong, and sorting each evaluation keyword in each evaluation keyword group according to a preset sorting rule to obtain an evaluation keyword sequence corresponding to each evaluation keyword group;
[0029] The transition probabilities between adjacent evaluation keywords in each evaluation keyword sequence are counted, and the mean of the transition probabilities corresponding to each evaluation keyword group is determined as the style combination probability of the image style corresponding to each initial image effect evaluation keyword in each evaluation keyword group.
[0030] Optionally, inputting the image generation prompt word into a preset image generation model to generate an image to obtain a newly generated image includes:
[0031] Determining a reference image of the image to be generated, and determining an initial seed value of a preset image generation model in the process of generating the image;
[0032] Inputting the image generation prompt word and the initial seed value into the preset image generation model to generate an image, thereby obtaining an initial image;
[0033] Determining a fluctuation range of the initial seed value based on the similarity between the initial image and the reference image, and determining a plurality of seed values within the fluctuation range, inputting each of the seed values and the image generation prompt word into the preset image generation model to perform image generation, and obtaining candidate images corresponding to each of the seed values;
[0034] The similarity between each candidate image and the reference image is determined respectively, and the candidate image corresponding to the maximum similarity is used as the newly generated image.
[0035] According to a second aspect of the present invention, there is provided an image effect evaluation device, comprising:
[0036] an acquiring unit, configured to acquire delivery attribute data of a target image in response to an effect evaluation instruction of the target image;
[0037] a fusion unit, configured to extract the image visual features of the target image and the delivery attribute features of the delivery attribute data, and fuse the image visual features and the delivery attribute features to obtain an effect evaluation fusion feature;
[0038] The effect evaluation unit is used to input the effect evaluation fusion feature into a preset effect evaluation model to perform image effect evaluation and obtain the effect evaluation result of the target image, wherein the preset effect evaluation model is pre-trained based on a sample data set with effect labels.
[0039] According to a third aspect of the present invention, there is provided a computer-readable storage medium having a computer program stored thereon, which implements the above image effect evaluation method when executed by a processor.
[0040] According to a fourth aspect of the present invention, a computer device is provided, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the above-mentioned image effect evaluation method when executing the program.
[0041] According to the image effect evaluation method, device, storage medium and computer equipment provided by the present invention, compared with the current method of manually analyzing image effects, the present invention obtains the delivery attribute data of the target image by responding to the effect evaluation instruction of the target image; and extracts the image visual features of the target image and the delivery attribute features of the delivery attribute data, and fuses the image visual features and the delivery attribute features to obtain the effect evaluation fusion features; finally, the effect evaluation fusion features are input into a preset effect evaluation model to perform image effect evaluation, and the effect evaluation result of the target image is obtained, wherein the preset effect evaluation model is pre-trained based on a sample data set with effect labels. In this way, the image visual features of the target image and the delivery attribute features of the delivery attribute data are analyzed by the preset effect evaluation model to determine the effect evaluation result of the target image, avoiding manual participation, thereby improving the efficiency and accuracy of image effect evaluation and ensuring the degree of automation of image effect evaluation. BRIEF DESCRIPTION OF THE DRAWINGS
[0042] The drawings described herein are used to provide a further understanding of the present invention and constitute a part of this application. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention. In the drawings:
[0043] Figure 1 A flow chart of an image effect evaluation method provided by an embodiment of the present invention is shown;
[0044] Figure 2 A flow chart of another image effect evaluation method provided by an embodiment of the present invention is shown;
[0045] Figure 3 A schematic structural diagram of an image effect evaluation device provided by an embodiment of the present invention is shown;
[0046] Figure 4 A schematic structural diagram of another image effect evaluation device provided by an embodiment of the present invention is shown;
[0047] Figure 5 A schematic diagram of the physical structure of a computer device provided by an embodiment of the present invention is shown. DETAILED DESCRIPTION
[0048] The present invention will be described in detail below with reference to the accompanying drawings and in combination with embodiments. It should be noted that, unless there is a conflict, the embodiments and features in the embodiments of the present application can be combined with each other.
[0049] Currently, manual analysis of image effects is time-consuming and labor-intensive, and if the analyst is negligent, errors in the image effect analysis may occur.
[0050] In order to solve the above problems, an embodiment of the present invention provides an image effect evaluation method, such as Figure 1 As shown, the method includes:
[0051] 101. In response to an effect evaluation instruction of a target image, obtain delivery attribute data of the target image.
[0052] Among them, the target image can be any image, such as an advertising image of food, daily necessities, clothing, etc.; the target image can be a display image such as an image of the target product; the delivery attribute data refers to the total cost, exposure rate, click-through rate, transaction order amount, etc. of the target image during the delivery process.
[0053] In the embodiment of the present invention, when it is necessary to analyze the image effect of the target image, the effect evaluation instruction of the target image is triggered. When the effect evaluation instruction is received, the exposure rate, click rate and other delivery attribute data of the target image are obtained from the database.
[0054] 102. Extract the image visual features of the target image and the delivery attribute features of the delivery attribute data, and fuse the image visual features and the delivery attribute features to obtain effect evaluation fusion features.
[0055] Among them, the image visual features refer to the features of information such as color, texture, and object layout of the target image. For the embodiment of the present invention, in order to capture the complementary information between different features and thus improve the accuracy of effect evaluation, it is first necessary to fuse the image visual features and the delivery attribute features. Based on this, the specific fusion processing method includes: taking the image visual features as an example, constructing a feature matrix from each image visual feature; determining the element mean of each element in the feature matrix, and subtracting each element in the feature matrix from the element mean to obtain a centralized feature matrix; determining the covariance matrix corresponding to the centralized feature matrix; performing eigenvalue decomposition on the covariance matrix to obtain matrix eigenvalues and matrix eigenvectors; based on the size of the matrix eigenvalues, selecting a preset number of matrix eigenvectors from the matrix eigenvectors, and determining the preset number of matrix eigenvectors as the principal component features in the image visual features. Similarly, the principal component features in the delivery attribute features can be determined in the above manner; the principal component features in the image visual features and the principal component features in the delivery attribute features are subjected to feature-level cross-processing to obtain the effect evaluation fusion features.
[0056] The preset number is set according to actual needs. Specifically, if one feature of the image visual features is [1 1 2 4 2] and the other feature is [1 3 3 4 4], the feature matrix composed of the above two features is as follows:
[0057]
[0058] Where T represents the feature matrix. Then, the mean of the elements corresponding to the first row of elements in the feature matrix is determined, and each element in the first row is subtracted from the mean to obtain the subtraction results corresponding to each element in the first row. At the same time, the mean of the elements corresponding to each element in the second row is determined, and each element in the second row is subtracted from the corresponding element mean to obtain the subtraction results corresponding to each element in the second row. Finally, the subtraction results corresponding to each element in the first row and the subtraction results corresponding to each element in the second row are used to form the centralized feature matrix as follows:
[0059]
[0060] Among them, T z Represents the centralized feature matrix, and then calculates the covariance between each row of the centralized feature matrix. For example, the covariance between the first row of elements Cov(X1, X1) = [(-1) 2 +(-1) 2 +(0) 2 +(2) 2 +(0) 2] / (5-1)=1.5, the covariance between the first row elements and the second row elements Cov(X1, X2)=[(-1)×(-2)+(-1)×0+0×0+2×1+0×1] / (5-1)=1, thereby the covariance between all row elements can be calculated, and then the covariance matrix is composed of all covariances, and the covariance matrix is subjected to eigenvalue decomposition. The specific decomposition method is: first determine the eigenvector group of the covariance matrix, and calculate the corresponding eigenvalue according to the eigenvector group. For example, if the obtained eigenvector group is k groups, then the corresponding eigenvalues are k, and each eigenvalue has its corresponding eigenvector. Then, the k eigenvalues are sorted from large to small to obtain the sorted eigenvalues, and then the eigenvalues ranked in the top n (preset number) among the sorted eigenvalues are selected, and the eigenvectors corresponding to the top n eigenvalues are determined as the principal component features. Thus, the principal component features in the delivery attribute features can be determined according to the above method. For example, if the principal component feature in the image visual feature is (a1, a2) and the principal component feature in the delivery attribute feature is (b1, b2), then the method for performing feature-level cross-processing on the two principal component features is: after taking the Hadamard product of all elements between the two features, a convolution transformation is performed under a certain weight w, and the resulting effect evaluation fusion feature is f(w*(a1*b1,a2*b2)). It should be noted that the above examples are merely illustrative and do not limit the embodiments of this application. Therefore, the embodiment of the present invention first determines the principal component features in the image visual features and the delivery attribute features. Since the principal component captures the main variation information in the features and ignores the secondary information and noise, it can improve the generalization ability of the model and thus improve the accuracy of the image effect evaluation. At the same time, the embodiment of the present invention can automatically or explicitly combine different features by fusing multiple features to generate new feature combinations. These combined features may contain complex nonlinear relationships between the original features, so that the model can capture more detailed and rich information in the data, that is, it can make full use of the relationship between various data, extract more implicit features, make data utilization more comprehensive, and the image effect evaluation results obtained later are more accurate and meet the needs of actual application scenarios.
[0061] 103. Input the effect evaluation fusion feature into a preset effect evaluation model to perform image effect evaluation to obtain an effect evaluation result of the target image, wherein the preset effect evaluation model is pre-trained based on a sample data set with effect labels.
[0062] In an embodiment of the present invention, in order to improve the effect evaluation accuracy of a preset effect evaluation model, it is first necessary to train and construct a preset effect evaluation model. Based on this, the method includes: obtaining a preset initial effect evaluation model and obtaining a sample data set, wherein the sample data set includes delivery attribute data of a sample image with an effect evaluation label; dividing the sample data set into training data and test data, using the training data to train the preset initial effect evaluation model, and using the test data to test the trained preset initial effect evaluation model, and finally using the trained preset initial effect evaluation model that meets the test conditions as the preset effect evaluation model, wherein the test conditions include, for example, the number of training times meeting the requirements or the accuracy of the trained model meeting the requirements. Furthermore, the effect evaluation fusion feature is input into the preset effect evaluation model to perform image effect evaluation, and the effect evaluation result of the target image is output through the preset effect evaluation model. The effect evaluation results include visual appeal and product information. Examples of visual appeal include: Vivid Color: The image uses bright red and yellow, which are very eye-catching and stand out from the crowd; Clear Product Display: The product packaging and the actual product in the image are clearly displayed, allowing customers to clearly see the product's appearance and form; Attractive Product Close-up: A close-up of the plate of dried tofu, bright red and possibly seasoned, looks very tempting and stimulates appetite. Product information evaluation results include: Prominent Brand Logo: The brand logo is clearly visible, which helps brand recognition and builds trust; Prominent Product Name (display point): The name, with its auspicious meaning, easily attracts consumers, while the "Super Value Assorted Pack" also demonstrates the product's diverse and cost-effective product portfolio; Nutritional and Healthy: "Nutritious and healthy, loved by the whole family" highlights the product's health attributes, aligning with modern consumers' pursuit of healthy eating. This embodiment of the present invention uses a model to evaluate image effects, eliminating manual intervention and improving the efficiency and accuracy of image effect evaluation. Furthermore, based on the effect evaluation results of multiple images, the generation or optimization of the image to be delivered next can be guided.
[0063] In another embodiment of the present invention, in order to improve the accuracy of the effect evaluation of the image, the effect evaluation fusion feature can be first input into a preset evaluation index prediction model to predict the evaluation index, and then the evaluation index and the effect evaluation fusion feature can be input into the large model together, and the image is evaluated for the evaluation index using the large model to obtain the evaluation results under each evaluation index. Among them, the evaluation index includes a visual appeal evaluation index, a product name evaluation index, and a promotional information evaluation index. Product highlight evaluation index, etc. For example, the effect evaluation result under the product name evaluation index can be: the product name has auspicious meaning and is easy to attract consumers, etc.; the effect evaluation result under the promotion information evaluation index can be: the image is marked with "super value assorted package", indicating that the product combination is diverse and cost-effective; the effect evaluation result under the product highlight evaluation index can be: the image is marked with "nutritious and healthy", highlighting the health attributes of the product, which is in line with modern consumers' pursuit of healthy diet.
[0064] In another embodiment of the present invention, in terms of engineering architecture, to meet the real-time requirements of image effect evaluation, Flask (a popular Python framework for building web services) or FastAPI (a popular Python framework for building web services) can be used to build a service for asynchronous image processing and data analysis. The front end may need to upload images and input placement attribute data, and the back end calls the model to perform effect evaluation, and the effect evaluation results are displayed using visual charts.
[0065] According to a method for evaluating the effect of an image provided by the present invention, compared with the current method of manually analyzing the effect of an image, the present invention obtains the delivery attribute data of the target image by responding to the effect evaluation instruction of the target image; extracts the image visual features of the target image and the delivery attribute features of the delivery attribute data, and fuses the image visual features and the delivery attribute features to obtain the effect evaluation fusion features; finally, the effect evaluation fusion features are input into a preset effect evaluation model to perform image effect evaluation, and the effect evaluation result of the target image is obtained, wherein the preset effect evaluation model is pre-trained based on a sample data set with effect labels. Thus, the image visual features of the target image and the delivery attribute features of the delivery attribute data are analyzed by the preset effect evaluation model to determine the effect evaluation result of the target image, avoiding manual participation, thereby improving the efficiency and accuracy of image effect evaluation and ensuring the degree of automation of image effect evaluation.
[0066] Furthermore, in order to better illustrate the above process of evaluating the effect of an image, as a refinement and extension of the above embodiment, the embodiment of the present invention provides another method for evaluating the effect of an image, such as Figure 2 As shown, the method includes:
[0067] 201. In response to an effect evaluation instruction of a target image, obtain delivery attribute data of the target image.
[0068] Specifically, when an effect evaluation instruction of a target image is received, delivery attribute data of the target image is collected in a database.
[0069] 202. Extract the image visual features of the target image and the delivery attribute features of the delivery attribute data, and fuse the image visual features and the delivery attribute features to obtain effect evaluation fusion features.
[0070] In order to improve the accuracy of image effect evaluation and save computing resources, the present invention first performs pre-processing such as standardization on the delivery attribute data. For example, the standard deviation of the delivery attribute data such as exposure, click-through rate, conversion rate, etc. can be normalized, and the natural logarithm function can be used to process the delivery attribute data such as cost. Furthermore, the image visual features are extracted, for example, using a multimodal model such as CLIP. The ViT-L / 14 model generates image visual features of preset dimensions, and uses word embedding and other methods to determine the delivery attribute features of the delivery attribute data, and then fuses the image visual features and the delivery attribute features. In order to improve the accuracy of the image effect evaluation, on this basis, the aesthetic features of the target image can also be extracted, and then the image effect evaluation is performed based on the aesthetic features, image visual features, and delivery attribute features. Based on this, step 202 specifically includes: inputting the target image into a preset aesthetic scoring model for aesthetic scoring, and determining the aesthetic feature vector corresponding to the aesthetic score; fusing the image visual features, the aesthetic features, and the delivery attribute features to obtain the effect evaluation fusion feature, wherein the method of fusing the image visual features, the aesthetic features, and the delivery attribute features to obtain the effect evaluation fusion feature includes : Taking the image visual features as the visual query vector, taking the concatenated features of the aesthetic features and the delivery attribute features as the first key-value vector, and interacting the visual query vector with the first key-value vector to obtain visual context features; taking the aesthetic features as the aesthetic query vector, taking the concatenated features of the image visual features and the delivery attribute features as the second key-value vector, and interacting the aesthetic query vector with the second key-value vector to obtain aesthetic context features; taking the delivery attribute features as the delivery query vector, taking the concatenated features of the image visual features and the aesthetic features as the third key-value vector, and interacting the delivery query vector with the third key-value vector to obtain delivery context features; aggregating the visual context features, the aesthetic context features, and the delivery context features to obtain the effect evaluation fusion features.
[0071] Specifically, a preset aesthetic scoring model is pre-trained and constructed. The method for training and constructing the preset aesthetic scoring model includes: obtaining a preset initial aesthetic scoring model and obtaining a sample data set, wherein the sample data set includes sample images with aesthetic scores; dividing the sample data set into training data and test data, using the training data to train the preset initial aesthetic scoring model, and using the test data to test the trained preset initial aesthetic scoring model, and finally using the preset initial aesthetic scoring model that meets the test conditions as the preset aesthetic scoring model, wherein the test conditions can be that the number of training times meets the requirements or the test accuracy of the trained preset initial aesthetic scoring model meets the requirements. Furthermore, the target image is input into the preset aesthetic scoring model for scoring, and the preset aesthetic scoring model can output the aesthetic score of the target image. For example, the aesthetic score can be a 1-10 point system, with a higher score representing a more beautiful image.
[0072] Furthermore, word embedding and other methods are used to determine the aesthetic features corresponding to the aesthetic score. Then, a cross-modal attention mechanism is adopted. For example, a three-layer Transformer is used to achieve the interactive fusion of image visual features, aesthetic features, and delivery attribute features. For example, the following formula can be used to fuse image visual features, aesthetic features, and delivery attribute features:
[0073]
[0074] Among them, Q is any query vector among the visual query vector, aesthetic query vector, and delivery query vector. When Q is the visual query vector, K is the key of the splicing feature of the aesthetic feature and the delivery attribute feature, and V is the value corresponding to the key of the splicing feature of the aesthetic feature and the delivery attribute feature. When Q is the aesthetic query vector, K is the key of the splicing feature of the image visual feature and the delivery attribute feature, and V is the value corresponding to the key of the splicing feature of the image visual feature and the delivery attribute feature. When Q is the delivery query vector, K is the key of the splicing feature of the image visual feature and the aesthetic feature, and V is the value corresponding to the key of the splicing feature of the image visual feature and the delivery attribute feature. d k The vector dimensions of the first key-value vector, the second key-value vector, or the third key-value vector, respectively. Attention(Q, K, V) represents visual context features, aesthetic context features, or delivery context features, and softmax() represents the feature interaction function. Furthermore, the visual context features, aesthetic context features, and delivery context features are aggregated, such as by horizontally concatenating the visual context features, aesthetic context features, and delivery context features, to obtain a fused effect evaluation feature. The fused effect evaluation feature can be a feature of a preset dimension, such as a 768-dimensional fused feature.
[0075] In another embodiment of the present invention, the features may be interactively integrated using the following formula:
[0076] a ij =softmax(V T tanh(W q q i +W k k j ))
[0077] Among them, a ij To evaluate the fusion features, q i is the splicing feature of the image visual features and aesthetic features, k j V, W are the attributes of the delivery. q 、W k In order to enhance the feature fusion expression capability, the feature fusion coefficient is used, tanh() is the activation function for processing the feature fusion result, and softmax() is the feature interaction function. In another embodiment of the present invention, the weights corresponding to the image visual features, aesthetic features, and delivery attribute features can be set separately according to actual needs, and then the image visual features, aesthetic features, and delivery attribute features are weightedly fused according to the weights. By fusing multiple features, the embodiment of the present invention can provide hidden layer information in the features, that is, extract richer information, help the model better capture the complex patterns in the data, and thus improve the evaluation accuracy of the image effect.
[0078] 203. Input the effect evaluation fusion feature into a preset effect evaluation model to perform image effect evaluation to obtain an effect evaluation result of the target image, wherein the preset effect evaluation model is pre-trained based on a sample data set with effect labels.
[0079] For the embodiment of the present invention, after the image visual features, aesthetic features, and delivery attribute features are fused to obtain the effect evaluation fusion features, it is necessary to perform effect evaluation based on the effect evaluation fusion features using a preset effect evaluation model. Based on this, step 203 specifically includes: inputting the effect evaluation fusion features into the preset effect evaluation model to perform image effect evaluation, and obtaining an effect evaluation result of the target image based on a visual chart display form; determining a target effect whose contribution is greater than a preset threshold in the effect evaluation result, and determining an evaluation area corresponding to the target effect in the target image, and marking the evaluation area and displaying the contribution.
[0080] The preset threshold is set according to actual needs. Specifically, embodiments of the present invention can pre-train and construct a preset effect evaluation model based on a sample training set using XGBoost (eXtreme Gradient Boosting). During the model training process, the preset effect evaluation model can be trained and constructed based on the test conditions that the effect evaluation deviation of composition rationality is less than a first preset threshold, the color contrast color contrast space is greater than a second preset threshold, and the recognition rate of key elements of information communication efficiency is greater than a third preset threshold. The preset effect evaluation model can be an evaluation indicator prediction model. Subsequently, the fine-tuned large model can be used as an evaluation effect analysis model under different evaluation indicators. To improve the real-time performance of the effect evaluation, the model can be deployed in a high-memory and high-concurrency system. At the same time, an acceleration device, such as ONNX Runtime (an open source cross-platform machine learning inference engine), can be deployed in the system to accelerate the speed of image effect evaluation. The fine-tuned large model can ultimately output an effect evaluation result containing a multi-segment structure, such as an effect evaluation result containing a three-segment structure: core advantages → data support → optimization suggestions. The effect evaluation result can be displayed in the form of a visual chart. Furthermore, in order to enhance the readability of the effect evaluation results, the evaluation effects can also be annotated in the target image, that is, first determine the degree of influence of each effect evaluation indicator on the delivery attribute data, that is, the contribution. For example, if the contribution of the evaluation indicator of color contrast to the click-through rate is greater than the preset threshold, then determine the evaluation area corresponding to the color contrast in the target image, highlight the evaluation area, and mark the contribution on the evaluation area.
[0081] 204. In response to the image generation instruction of the image to be generated, obtain image generation requirement information of the image to be generated.
[0082] Among them, if the target image is a peanut image, the image to be generated can be other types of images such as instant cereals; the image generation requirement information includes basic product information (such as product name, brand, model, packaging information, etc.), visual style requirements (such as color matching, font style, image composition, etc.), target audience, usage scenarios, etc.
[0083] 205. Based on the image generation requirement information, image effect evaluation keywords are extracted from the effect evaluation database, and the extracted image effect evaluation keywords are mapped to image generation guidance elements that meet the image generation guidance format using preset mapping rules, wherein the effect evaluation database is constructed based on the effect evaluation results of multiple images.
[0084] The preset mapping rules are based on actual needs, mapping image effect evaluation keywords in the effect evaluation database to prompts (in prompt word format or image generation guidance format). For example, a rule engine or machine learning model is used to map structured image effect evaluation keywords to prompt elements that meet the requirements of the preset image generation model. For example, the keyword "golden ratio composition" corresponds to the image generation guidance element "balanced composition with golden ratio" in the prompt, and "high contrast" is mapped to "vivid color contrast."
[0085] For the embodiment of the present invention, the effect evaluation of multiple images can be performed in the manner of steps 201-203. During the effect evaluation, the good effects can be evaluated (i.e., the reasons why the image is good, such as composition, color, style, etc., are analyzed). Then, the good effect evaluation results of each image form an effect evaluation database, and the image to be generated is generated based on the effect evaluation database and the image generation requirement information. Based on this, it is first necessary to extract image effect evaluation keywords in the effect evaluation database according to the image generation requirement information. The specific extraction method includes: based on the image generation requirement information, extracting the initial image effect evaluation keywords whose image effect evaluation results meet the preset conditions in the effect evaluation database; determining the style combination probability of the image style corresponding to each of the initial image effect evaluation keywords, and determining the initial image effect evaluation keywords whose style combination probability is greater than the preset probability threshold among the initial image effect evaluation keywords as the image effect evaluation keywords. Among them, the method for determining the style combination probability of the image style corresponding to each initial image effect evaluation keyword includes: dividing each of the initial image effect evaluation keywords into multiple evaluation keyword groups according to the image to which they belong, and sorting each evaluation keyword in each of the evaluation keyword groups according to a preset sorting rule to obtain an evaluation keyword sequence corresponding to each of the evaluation keyword groups; counting the transition probabilities between adjacent evaluation keywords in each of the evaluation keyword sequences, and determining the mean of each transition probabilities corresponding to each of the evaluation keyword groups as the style combination probability of the image style corresponding to each initial image effect evaluation keyword in each of the evaluation keyword groups.
[0086] The preset conditions are set based on actual needs and set the conditions that meet the image generation requirement information. For example, if the target audience in the image generation requirement information is the elderly, the initial image effect evaluation keywords can be health-related descriptive information; the preset probability threshold is set based on actual needs; and the preset sorting rules are set based on actual needs, such as the evaluation order of the evaluation keywords, the first letter of the evaluation keywords, and other rules.
[0087] Specifically, if the data in the effect evaluation database is structured, the keywords therein are directly used. Otherwise, natural language techniques are used to extract initial image effect evaluation keywords from the effect evaluation database that meet the image generation requirement information. For example, if the image generation requirement information is a modern style, the initial image effect evaluation keywords can be the initial image effect evaluation keywords corresponding to image A (minimalist, black and white, bright), the initial image effect evaluation keywords corresponding to image B (monochrome, single item highlight, modern elements), and the initial image effect evaluation keywords corresponding to image C (black and white, bright, modern elements). It should be noted that if the data in the effect evaluation database is structured, for example, the effect analysis results for each image have clear fields such as color score and composition score, then prompts can be generated directly based on these fields. If the data is unstructured text, text mining techniques may be needed to extract keywords, such as using TF-IDF or BERT embedding clustering. Furthermore, in order to select the evaluation keywords ultimately used for image generation from the initial image effect evaluation keywords, it is necessary to determine the style combination probabilities of the image styles corresponding to each initial image effect evaluation keyword. Specifically, based on the above example, each initial image effect evaluation keyword (minimalist, black and white, bright) corresponding to image A is determined as evaluation keyword group A, each initial image effect evaluation keyword (monochrome, single product highlight, modern elements) corresponding to image B is determined as evaluation keyword group B, and each initial image effect evaluation keyword (black and white, bright, modern elements) corresponding to image C is determined as evaluation keyword group C. With the current keyword order as the sorting rule, the evaluation keyword sequence corresponding to evaluation keyword group A is (minimalist, black and white, bright), the evaluation keyword sequence corresponding to evaluation keyword group B is (monochrome, single product highlight, modern elements), and the evaluation keyword sequence corresponding to evaluation keyword group C is (black and white, bright, modern elements). Furthermore, if the evaluation keyword ranked first among the two adjacent evaluation keywords in each of the evaluation keyword sequences is k i , the evaluation keyword ranked later is k j , then calculate the two adjacent evaluation keywords k according to the following formula i and k j The transition probability p(k j k i ):
[0088]
[0089] Among them, k is the total number of initial image effect evaluation keywords, count(k i →k j ) is the value of the two evaluation keywords k i and k jThe number of co-occurrences in each evaluation keyword group, ∑ k count(k i →k k ) is the evaluation keyword k in each evaluation keyword group i The total number of occurrences. Thus, according to the above method, the transition probability between each two adjacent evaluation keywords in each evaluation keyword group can be determined, and then for each evaluation keyword group, the mean of all transition probabilities in the evaluation keyword group is determined as the style combination probability of the image style corresponding to each initial image effect evaluation keyword in the evaluation keyword group, and then the initial image effect evaluation keyword with a style combination probability greater than a preset probability threshold is determined as the image effect evaluation keyword. The embodiment of the present invention expresses the conversion law between different style combinations through the transition probability, thereby selecting the optimal effect evaluation keyword combination according to the transfer law, which can improve the image generation quality and generation accuracy.
[0090] 206 : Determine an image generation prompt word template for the image to be generated, and fill the product theme information and image generation guide elements of the image to be generated into the image generation prompt word template to obtain image generation prompt words.
[0091] The image generation prompt word template includes various title items, such as the theme description title item, style setting title item, composition rule title item, lighting effect title item, and artistic style title item. The product theme information and image effect evaluation keywords are automatically linked to the corresponding title items, thereby generating the image generation prompt word. For example, if the image effect evaluation keyword is "high color contrast," the image generation prompt word template needs to include relevant adjectives, such as "bright red and white form a strong contrast."
[0092] Specifically, the image effect evaluation keywords are converted into a format accepted by the image generation prompt word template to obtain image generation guiding elements. Finally, the product theme information (such as product name and product description information) of the image to be generated and the image effect evaluation keywords are filled into the image generation prompt word template to obtain image generation prompt words. For example, if the image to be generated is glutinous rice balls, that is, the product theme information is glutinous rice balls, and the image effect evaluation keywords are "soft lighting" and "close-up shot", then the generated image generation prompt words are "a bowl of hot glutinous rice balls, soft side lighting, close-up shot, high details, 8K resolution, and a warm family atmosphere." This embodiment of the present invention generates image generation prompt words through an image generation prompt word template, which can ensure the standardization of image generation prompt words, thereby improving the image generation quality and accuracy.
[0093] 207. Input the image generation prompt word into a preset image generation model to generate an image to obtain a newly generated image, wherein the preset image generation model is pre-trained based on a sample data set with image labels.
[0094] For an embodiment of the present invention, in order to improve the image generation accuracy of a preset image generation model, it is necessary to train and construct a preset image generation model. Based on this, the method includes: obtaining a preset initial image generation model and obtaining a sample data set, wherein the sample data set includes sample image generation prompt words with image labels; dividing the sample data set into training data and test data, using the training data to train the preset initial image generation model, and using the test data to test the trained preset initial image generation model, and finally using the trained preset initial image generation model that meets the test conditions as the preset image generation model, wherein meeting the test conditions means that the training test meets the requirements or the test accuracy of the trained preset initial image generation model meets the requirements. Furthermore, after constructing the preset image generation model, it is necessary to use the preset image generation model to generate an image. Based on this, step 207 specifically includes: determining the baseline image of the image to be generated, and determining the initial seed value of the preset image generation model in the image generation process; inputting the image generation prompt word and the initial seed value into the preset image generation model for image generation to obtain an initial image; based on the similarity between the initial image and the baseline image, determining the fluctuation range of the initial seed value, and determining multiple seed values within the fluctuation range, and inputting each seed value and the image generation prompt word into the preset image generation model for image generation to obtain a candidate image corresponding to each seed value; respectively determining the similarity between each candidate image and the baseline image, and taking the candidate image corresponding to the maximum similarity as the newly generated image.
[0095] Among them, the reference image refers to the original image of the image to be generated, that is, the image that only contains the image to be generated, or the image roughly designed by the brand with a general brand style; the initial seed value is the initialization state of the random noise that controls the preset image generation model. The initial seed value can be generated based on the feature hash value of the reference image, such as the initial seed value seed = 42. Then, the initial seed value and the image generation prompt word are input into the preset image generation model together. The preset image generation model can output the initial image, and extract the feature vectors of the reference image and the initial image respectively. Based on the feature vector, the similarity between the reference image and the initial image is calculated, such as the cosine similarity. If the similarity is greater than a preset similarity threshold (the preset similarity threshold is set according to actual needs), a smaller fluctuation range of the initial seed value is set, such as seed ± 100. If the similarity is less than or equal to the preset similarity threshold, a larger fluctuation range of the initial seed value is set, such as seed ± 1000, and N seed values are randomly selected within the fluctuation range, such as N = 10, and the N seed values and image generation prompt words are respectively input into the preset image generation model for image generation to obtain candidate images corresponding to the N seed values. The similarity between each candidate image and the reference image is then calculated, and finally the candidate image with the maximum similarity is used as the newly generated image. When generating images, the embodiment of the present invention introduces seed values to ensure that the generated images are both consistent with brand visual consistency and diverse, while reducing manual screening costs.
[0096] According to another image effect evaluation method provided by the present invention, compared with the current method of manually analyzing image effects, the present invention obtains the delivery attribute data of the target image by responding to the effect evaluation instruction of the target image; and extracts the image visual features of the target image and the delivery attribute features of the delivery attribute data, and fuses the image visual features and the delivery attribute features to obtain the effect evaluation fusion features; finally, the effect evaluation fusion features are input into a preset effect evaluation model to perform image effect evaluation, and the effect evaluation result of the target image is obtained, wherein the preset effect evaluation model is pre-trained based on a sample data set with effect labels. Thus, the image visual features of the target image and the delivery attribute features of the delivery attribute data are analyzed by the preset effect evaluation model to determine the effect evaluation result of the target image, avoiding manual participation, thereby improving the efficiency and accuracy of image effect evaluation and ensuring the degree of automation of image effect evaluation.
[0097] Further, as Figure 1 The embodiment of the present invention provides an image effect evaluation device, such as Figure 3 As shown, the device includes: an acquisition unit 31, a fusion unit 32, and an effect evaluation unit 33.
[0098] The acquisition unit 31 may be configured to acquire the delivery attribute data of the target image in response to an effect evaluation instruction of the target image.
[0099] The fusion unit 32 may be configured to extract the image visual features of the target image and the delivery attribute features of the delivery attribute data, and fuse the image visual features and the delivery attribute features to obtain effect evaluation fusion features.
[0100] The effect evaluation unit 33 can be used to input the effect evaluation fusion feature into a preset effect evaluation model to perform image effect evaluation to obtain the effect evaluation result of the target image, wherein the preset effect evaluation model is pre-trained based on a sample data set with effect labels.
[0101] In specific application scenarios, in order to fuse image visual features and delivery attribute features, such as Figure 4 As shown, the fusion unit 32 includes an aesthetic scoring module 321 and a fusion module 322 .
[0102] The aesthetic scoring module 321 may be configured to input the target image into a preset aesthetic scoring model for aesthetic scoring, and determine an aesthetic feature vector corresponding to the aesthetic score.
[0103] The fusion module 322 can be used to fuse the image visual features, the aesthetic features, and the delivery attribute features to obtain effect evaluation fusion features, wherein the method of fusing the image visual features, the aesthetic features, and the delivery attribute features to obtain effect evaluation fusion features includes: taking the image visual features as a visual query vector, taking the concatenation features of the aesthetic features and the delivery attribute features as a first key-value vector, and interacting the visual query vector with the first key-value vector to obtain visual context features; taking the aesthetic features as an aesthetic query vector, taking the concatenation features of the image visual features and the delivery attribute features as a second key-value vector, and interacting the aesthetic query vector with the second key-value vector to obtain aesthetic context features; taking the delivery attribute features as a delivery query vector, taking the concatenation features of the image visual features and the aesthetic features as a third key-value vector, and interacting the delivery query vector with the third key-value vector to obtain delivery context features; and aggregating the visual context features, the aesthetic context features, and the delivery context features to obtain the effect evaluation fusion features.
[0104] In a specific application scenario, in order to perform effect evaluation on a target image, the effect evaluation unit 33 includes an effect evaluation module 331 and an effect display module 332 .
[0105] The effect evaluation module 331 can be used to input the effect evaluation fusion feature into a preset effect evaluation model to perform image effect evaluation, and obtain an effect evaluation result of the target image based on a visual chart display form.
[0106] The effect display module 332 can be used to determine the target effect whose contribution is greater than a preset threshold in the effect evaluation result, determine the evaluation area corresponding to the target effect in the target image, mark the evaluation area and display the contribution.
[0107] In a specific application scenario, in order to generate another image, the device further includes: an extraction unit 34 , a filling unit 35 , and an image generation unit 36 .
[0108] The acquisition unit 31 may also be configured to acquire image generation requirement information of the image to be generated in response to an image generation instruction of the image to be generated.
[0109] The extraction unit 34 can be used to extract image effect evaluation keywords in the effect evaluation database based on the image generation requirement information, and use preset mapping rules to map the extracted image effect evaluation keywords into image generation guidance elements that meet the image generation guidance format, wherein the effect evaluation database is constructed based on the effect evaluation results of multiple images.
[0110] The filling unit 35 may be configured to determine an image generation prompt word template for the image to be generated, and fill the commodity theme information of the image to be generated and the image generation guide elements into the image generation prompt word template to obtain image generation prompt words.
[0111] The image generation unit 36 may be configured to input the image generation prompt word into a preset image generation model to generate an image, thereby generating a newly generated image. The preset image generation model is pre-trained based on a sample dataset with image labels. Based on the newly generated image, the image for the current or next round of delivery may be directly generated or optimized.
[0112] In a specific application scenario, in order to extract image effect evaluation keywords from the effect evaluation database, the extraction unit 34 includes an extraction module 341 and a first determination module 342 .
[0113] The extraction module 341 may be configured to extract initial image effect evaluation keywords whose image effect evaluation results meet preset conditions from the effect evaluation database based on the image generation requirement information.
[0114] The first determination module 342 can be used to determine the style combination probability of the image style corresponding to each of the initial image effect evaluation keywords, and determine the initial image effect evaluation keyword whose style combination probability is greater than a preset probability threshold among the initial image effect evaluation keywords as the image effect evaluation keyword.
[0115] In a specific application scenario, in order to determine the style combination probability of the image style corresponding to each initial image effect evaluation keyword, the first determination module 342 can be specifically used to divide each initial image effect evaluation keyword into multiple evaluation keyword groups according to the image to which it belongs, and sort each evaluation keyword in each evaluation keyword group according to a preset sorting rule to obtain an evaluation keyword sequence corresponding to each evaluation keyword group; count the transition probabilities between adjacent evaluation keywords in each evaluation keyword sequence, and determine the mean of each transition probabilities corresponding to each evaluation keyword group as the style combination probability of the image style corresponding to each initial image effect evaluation keyword in each evaluation keyword group.
[0116] In a specific application scenario, in order to generate an image, the image generation unit 36 includes a second determination module 361 and an image generation module 362 .
[0117] The second determination module 361 may be configured to determine a reference image for the image to be generated, and determine an initial seed value of a preset image generation model during the image generation process.
[0118] The image generation module 362 may be configured to input the image generation prompt word and the initial seed value into the preset image generation model to perform image generation and obtain an initial image.
[0119] The second determination module 361 can also be used to determine the fluctuation range of the initial seed value based on the similarity between the initial image and the reference image, and determine multiple seed values within the fluctuation range, and input each seed value and the image generation prompt word into the preset image generation model for image generation to obtain a candidate image corresponding to each seed value.
[0120] The second determination module 361 may be specifically configured to determine the similarity between each candidate image and the reference image, and use the candidate image corresponding to the maximum similarity as the newly generated image.
[0121] It should be noted that for other corresponding descriptions of the functional modules involved in the image effect evaluation device provided by the embodiment of the present invention, please refer to Figure 1 The corresponding description of the method shown will not be repeated here.
[0122] Based on the above Figure 1 The method shown, accordingly, an embodiment of the present invention further provides a computer-readable storage medium having a computer program stored thereon, which implements the following steps when executed by a processor: in response to an effect evaluation instruction of a target image, obtaining the delivery attribute data of the target image; extracting the image visual features of the target image and the delivery attribute features of the delivery attribute data, and fusing the image visual features and the delivery attribute features to obtain effect evaluation fusion features; inputting the effect evaluation fusion features into a preset effect evaluation model to perform image effect evaluation, and obtaining an effect evaluation result of the target image, wherein the preset effect evaluation model is pre-trained based on a sample data set with effect labels.
[0123] Based on the above Figure 1 The method shown and Figure 3 The embodiment of the device shown in the figure, the embodiment of the present invention also provides a physical structure diagram of a computer device, such as Figure 5 As shown, the computer device includes: a processor 41, a memory 42, and a computer program stored in the memory 42 and executable on the processor, wherein the memory 42 and the processor 41 are both arranged on a bus 43, and the processor 41 implements the following steps when executing the program: in response to an effect evaluation instruction of a target image, obtaining delivery attribute data of the target image; extracting image visual features of the target image and delivery attribute features of the delivery attribute data, and fusing the image visual features and the delivery attribute features to obtain effect evaluation fusion features; inputting the effect evaluation fusion features into a preset effect evaluation model to perform image effect evaluation, and obtaining an effect evaluation result of the target image, wherein the preset effect evaluation model is pre-trained based on a sample data set with effect labels.
[0124] Through the technical solution of the present invention, the present invention obtains the delivery attribute data of the target image in response to the effect evaluation instruction of the target image; extracts the image visual features of the target image and the delivery attribute features of the delivery attribute data, and fuses the image visual features and the delivery attribute features to obtain the effect evaluation fusion features; finally, the effect evaluation fusion features are input into the preset effect evaluation model to perform image effect evaluation to obtain the effect evaluation result of the target image, wherein the preset effect evaluation model is pre-trained based on a sample data set with effect labels, and then a new image can be generated based on the effect evaluation results of multiple images, and the image optimization of the current round or the next delivery can be directly performed based on the new image. Thus, the image visual features of the target image and the delivery attribute features of the delivery attribute data are analyzed by the preset effect evaluation model to determine the effect evaluation result of the target image, avoiding manual participation, thereby improving the efficiency and accuracy of the image effect evaluation, ensuring the automation of the image effect evaluation, and at the same time, according to the image effect evaluation result, guiding the generation or optimization of the image to be delivered.
[0125] Obviously, those skilled in the art will appreciate that the various modules or steps of the present invention described above can be implemented using a general-purpose computing device, centralized on a single computing device, or distributed across a network of multiple computing devices. Alternatively, they can be implemented using program code executable by a computing device, which can then be stored in a storage device and executed by the computing device. In some cases, the steps shown or described can be performed in a different order than that shown, or can be fabricated as separate integrated circuit modules, or multiple modules or steps can be fabricated as a single integrated circuit module. Thus, the present invention is not limited to any particular combination of hardware and software.
[0126] The foregoing description is merely a preferred embodiment of the present invention and is not intended to limit the present invention. Those skilled in the art will readily appreciate that various modifications and variations of the present invention are possible. Any modifications, equivalent substitutions, or improvements made within the spirit and principles of the present invention shall be included within the scope of protection of the present invention.
Claims
1. A method for evaluating the effect of an image, characterized in that: include: In response to an effect evaluation instruction of a target image, acquiring delivery attribute data of the target image; Extracting the image visual features of the target image and the delivery attribute features of the delivery attribute data, and fusing the image visual features and the delivery attribute features to obtain effect evaluation fusion features; Inputting the effect evaluation fusion feature into a preset effect evaluation model to perform image effect evaluation, thereby obtaining an effect evaluation result of the target image, wherein the preset effect evaluation model is pre-trained based on a sample data set with effect labels; The image visual features and the delivery attribute features are fused to obtain effect evaluation fusion features, including: The target image is input into a preset aesthetic scoring model for aesthetic scoring, and aesthetic features corresponding to the aesthetic score are determined; the image visual features, the aesthetic features, and the delivery attribute features are fused to obtain effect evaluation fused features, wherein the method for fusing the image visual features, the aesthetic features, and the delivery attribute features to obtain effect evaluation fused features includes: using the image visual features as a visual query vector, using the concatenation features of the aesthetic features and the delivery attribute features as a first key-value vector, and interacting the visual query vector with the first key-value vector to obtain visual context features; using the aesthetic features as an aesthetic query vector, using the concatenation features of the image visual features and the delivery attribute features as a second key-value vector, and interacting the aesthetic query vector with the second key-value vector to obtain aesthetic context features; using the delivery attribute features as a delivery query vector, using the concatenation features of the image visual features and the aesthetic features as a third key-value vector, and interacting the delivery query vector with the third key-value vector to obtain delivery context features; and aggregating the visual context features, the aesthetic context features, and the delivery context features to obtain the effect evaluation fused features.
2. The method according to claim 1, characterized in that The step of inputting the effect evaluation fusion feature into a preset effect evaluation model to perform image effect evaluation and obtain an effect evaluation result of the target image includes: Inputting the effect evaluation fusion feature into a preset effect evaluation model to perform image effect evaluation, and obtaining an effect evaluation result of the target image based on a visual chart display form; A target effect having a contribution greater than a preset threshold is determined in the effect evaluation result, and an evaluation area corresponding to the target effect is determined in the target image, and the evaluation area is marked and the contribution is displayed.
3. The method according to claim 1, characterized in that After inputting the effect evaluation fusion feature into a preset effect evaluation model to perform image effect evaluation and obtaining the effect evaluation result of the target image, the method further includes: In response to an image generation instruction of an image to be generated, acquiring image generation requirement information of the image to be generated; Based on the image generation requirement information, image effect evaluation keywords are extracted from an effect evaluation database, and the extracted image effect evaluation keywords are mapped into image generation guidance elements that meet an image generation guidance format using a preset mapping rule, wherein the effect evaluation database is constructed based on effect evaluation results of multiple images; Determining an image generation prompt word template for the image to be generated, and filling the commodity theme information of the image to be generated and the image generation guide element into the image generation prompt word template to obtain an image generation prompt word; The image generation prompt word is input into a preset image generation model to generate an image to obtain a newly generated image, wherein the preset image generation model is pre-trained based on a sample data set with image labels.
4. The method according to claim 3, characterized in that The extracting of image effect evaluation keywords from the effect evaluation database based on the image generation requirement information includes: Based on the image generation requirement information, extracting initial image effect evaluation keywords whose image effect evaluation results meet preset conditions from the effect evaluation database; Determine the style combination probability of the image style corresponding to each of the initial image effect evaluation keywords, and determine the initial image effect evaluation keywords whose style combination probability is greater than a preset probability threshold among the initial image effect evaluation keywords as the image effect evaluation keywords.
5. The method according to claim 4, characterized in that The determining of the style combination probability of the image styles corresponding to the initial image effect evaluation keywords includes: Dividing each of the initial image effect evaluation keywords into a plurality of evaluation keyword groups according to the image to which they belong, and sorting each evaluation keyword in each evaluation keyword group according to a preset sorting rule to obtain an evaluation keyword sequence corresponding to each evaluation keyword group; The transition probabilities between adjacent evaluation keywords in each evaluation keyword sequence are counted, and the mean of the transition probabilities corresponding to each evaluation keyword group is determined as the style combination probability of the image style corresponding to each initial image effect evaluation keyword in each evaluation keyword group.
6. The method according to claim 3, characterized in that The step of inputting the image generation prompt word into a preset image generation model to generate an image to obtain a newly generated image includes: Determining a reference image of the image to be generated, and determining an initial seed value of a preset image generation model in the process of generating the image; Inputting the image generation prompt word and the initial seed value into the preset image generation model to generate an image, thereby obtaining an initial image; Determining a fluctuation range of the initial seed value based on the similarity between the initial image and the reference image, and determining a plurality of seed values within the fluctuation range, inputting each of the seed values and the image generation prompt word into the preset image generation model to perform image generation, and obtaining candidate images corresponding to each of the seed values; The similarity between each candidate image and the reference image is determined respectively, and the candidate image corresponding to the maximum similarity is used as the newly generated image.
7. An image effect evaluation device, characterized in that: include: an acquiring unit, configured to acquire delivery attribute data of a target image in response to an effect evaluation instruction of the target image; a fusion unit, configured to extract the image visual features of the target image and the delivery attribute features of the delivery attribute data, and fuse the image visual features and the delivery attribute features to obtain an effect evaluation fusion feature; The image visual features and the delivery attribute features are fused to obtain effect evaluation fusion features, including: inputting the target image into a preset aesthetic scoring model for aesthetic scoring, and determining the aesthetic features corresponding to the aesthetic score; fusing the image visual features, the aesthetic features, and the delivery attribute features to obtain effect evaluation fusion features, wherein the method for fusing the image visual features, the aesthetic features, and the delivery attribute features to obtain effect evaluation fusion features includes: using the image visual features as a visual query vector, using the concatenation feature of the aesthetic features and the delivery attribute features as a first key value vector, and comparing the visual query vector with the The first key-value vector is interacted to obtain a visual context feature; the aesthetic feature is used as an aesthetic query vector, the concatenation feature of the image visual feature and the delivery attribute feature is used as a second key-value vector, and the aesthetic query vector and the second key-value vector are interacted to obtain an aesthetic context feature; the delivery attribute feature is used as a delivery query vector, the concatenation feature of the image visual feature and the aesthetic feature is used as a third key-value vector, and the delivery query vector and the third key-value vector are interacted to obtain a delivery context feature; the visual context feature, the aesthetic context feature, and the delivery context feature are aggregated to obtain the effect evaluation fusion feature; The effect evaluation unit is used to input the effect evaluation fusion feature into a preset effect evaluation model to perform image effect evaluation and obtain the effect evaluation result of the target image, wherein the preset effect evaluation model is pre-trained based on a sample data set with effect labels.
8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.
9. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.
Citation Information
Patent Citations
Aesthetics guidance-based text graph model optimization method, apparatus and device, and medium
CN118093882A
Image aesthetics quality evaluation method based on prompt learning
CN118865387A