CN109903349B - Color harmony prediction method based on maximum likelihood estimation - Google Patents

Color harmony prediction method based on maximum likelihood estimation Download PDF

Info

Publication number
CN109903349B
CN109903349B CN201910079391.3A CN201910079391A CN109903349B CN 109903349 B CN109903349 B CN 109903349B CN 201910079391 A CN201910079391 A CN 201910079391A CN 109903349 B CN109903349 B CN 109903349B
Authority
CN
China
Prior art keywords
color
harmony
value
maximum likelihood
pairs
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201910079391.3A
Other languages
Chinese (zh)
Other versions
CN109903349A (en
Inventor
杨柏林
魏天祥
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhejiang Gongshang University
Original Assignee
Zhejiang Gongshang University
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhejiang Gongshang University filed Critical Zhejiang Gongshang University
Priority to CN201910079391.3A priority Critical patent/CN109903349B/en
Publication of CN109903349A publication Critical patent/CN109903349A/en
Application granted granted Critical
Publication of CN109903349B publication Critical patent/CN109903349B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)
  • Color Image Communication Systems (AREA)
  • Facsimile Image Signal Circuits (AREA)
  • Spectrometry And Color Measurement (AREA)

Abstract

The invention discloses a color harmony prediction method based on maximum likelihood estimation. On the basis of a large online website data set, firstly, dividing color subjects of five different colors into four different adjacent color pairs, and estimating maximum likelihood distribution of repeated color pair harmony values according to the distribution condition of data to obtain unique harmony values of the color pairs; and then, restoring the color pairs into the five-color theme in a searching way, so that one color theme has four different color pair harmony values, and calculating the maximum likelihood estimation value of the color pair harmony values to obtain the final color harmony value of the color theme. The invention adopts a method based on maximum likelihood estimation to solve the problem of color harmony prediction, quantifies the concept of color harmony into a determined harmony numerical value by analyzing the color relationship of adjacent color pairs, greatly improves the precision of the result and reduces the prediction error.

Description

Color harmony prediction method based on maximum likelihood estimation
Technical Field
The invention belongs to the technical field of image processing, and particularly relates to a color harmony prediction method based on maximum likelihood estimation.
Background
Color patterning is critical in visual applications of art, design and visualization. For centuries, people have been proposing different theories on how to make colors more harmonious. With the development of multimedia technology, most applications generally use a Color wheel as a user interface for visualizing and manipulating colors, such as an online website Adobe Color CC that generates a five-Color theme, introduced by Adobe corporation, and some researchers apply recoloring or replacing colors to images through the Color wheel. This is because the color wheel is able to visualize harmonious colors in a positional relationship, for example two colors at 180 ° in the color wheel are called complementary colors (red-green), 30 ° -60 ° are called similar colors (red-red orange-orange), less than 30 ° are called homogeneous colors (golden yellow-lemon yellow), etc.
However, although this method of quickly finding harmonious color matches using positional relationships is convenient, finding a set of the most harmonious color combinations among a plurality of differently colored color themes is far from such accuracy and color complexity by the color wheel alone. In order to quickly solve the problems, the most simple method is to measure the harmony degree of the color in a numerical mode, so that common people can quickly know the harmony degree of the color theme through the harmony degree value corresponding to the color theme without knowing many professional knowledge like designers, then select the most harmonious color matching, and greatly improve the efficiency.
The harmony degree of the colors is measured in a numerical mode, and the final effect is that the harmony degree of any group of color themes can be rapidly predicted. The traditional color harmony prediction method mainly takes psychological experiments through recruiting volunteers to obtain the evaluation of quantitative color combination, obtains the relation between the color combination and the evaluation in a formula form by analyzing simple color relation in CIE LAB color space, and finally generalizes the method to all colors. The method is limited by the number of volunteers and color combinations, so that the established prediction model is usually only suitable for specific colors, and meanwhile, the accuracy of the model is also seriously influenced by analyzing a small amount of simple color relations through experiments. While others speculate on color harmony by studying people's color preferences, and even develop color theme generation systems based on user color preferences. However, this approach only addresses a single user's preference for color, and the harmonious need for color is aesthetically pleasing to the public. Recently researchers trained large datasets to predict color harmony through the method of LASSO regression and used this method in color recommendations. Although the result is objective and robust, this method is not satisfactory in terms of prediction accuracy. Therefore, it is urgent to develop a method for predicting color harmony degree with high accuracy.
Disclosure of Invention
Aiming at the defects of the prior art, the invention provides a color harmony prediction method based on maximum likelihood estimation.
The method comprises the following steps:
a first part: analyzing color distribution relationship
1) Online crawlers are conducted on the Adobe Color CC and the COLOURLoverrs of the online websites, and the five-Color equal-area Color theme with the number of the viewed people being more than 10 in the websites, the corresponding viewing number and the corresponding praise number are obtained. And fitting the watching number and the like to the harmony value of the color theme in a linear regression mode to form a data set.
2) By sorting the data sets of Adobe and colorerrors, harmonious curves of a single color block and adjacent color pairs are respectively drawn.
3) By analyzing the distribution trends of the two graphs, color pairs are selected as important factors for predicting the harmony value and applied to the second part.
A second part: constructing a maximum likelihood estimation prediction framework
1) All five-color themes in the data set are segmented into four adjacent different color pairs and are given harmony values of the original five-color theme.
2) Sorting the segmented adjacent color pairs, deleting the color pairs with repeated colors, and simultaneously assigning harmony values to the unique and non-repeated color pairs so that a plurality of color pair values exist in the color pairs.
3) The distribution of each color pair and harmony value is counted by adopting Kolmogorov-Smirnov test, and the probability density function D is calculatednThe convergence situation determines whether the data satisfies the distribution:
Figure BDA0001959899380000021
where x is the color pair harmony values r (i), Fn(x) Is an empirical distribution function of x, F0(x) Is a cumulative distribution function of x,
Figure BDA0001959899380000022
is the supremum and represents the largest value in x. When D is presentnOn a time scale of → 0, the data is said to conform to the profile, otherwise it does not.
3) And carrying out maximum likelihood estimation calculation on the data of the determined distribution condition to obtain a maximum likelihood estimation value serving as a final harmony degree predicted value of the adjacent color pairs, wherein the value corresponds to the color pairs one by one.
4) The color pairs are reduced in a look-up manner into a five-color theme such that one color theme has four different color pair harmony values.
5) Determining the distribution of each group of color subjects, calculating the predicted value of the color subjects by utilizing maximum likelihood estimation, comparing the predicted value with the harmony value in the data set,
6) And optimizing a predicted value by utilizing linear regression of a least square method, and reducing the error of the harmony value in the same data set.
The invention has the beneficial effects that: the invention adopts a method based on maximum likelihood estimation to solve the problem of color harmony prediction, quantifies the concept of color harmony into a determined harmony numerical value by analyzing the color relationship of adjacent color pairs, greatly improves the precision of the result and reduces the prediction error.
Detailed Description
The invention provides a color harmony prediction method based on maximum likelihood estimation. The user can input five color themes with different colors and the same area, and the harmony degree of the color theme is predicted by the method to describe the harmony degree.
The technical scheme adopted by the invention for solving the technical problem comprises the following steps:
a first part: analyzing color distribution relationship
1) Online crawlers are conducted on the Adobe Color CC and the COLOURLoverrs of the online websites, and the five-Color equal-area Color theme with the number of the viewed people being more than 10 in the websites, the corresponding viewing number and the corresponding praise number are obtained. And fitting the watching number and the like into a harmony value of the color theme in a linear regression mode, and taking the harmony value and the color theme as a data set.
Fitting formula of watching number and like number:
Figure BDA0001959899380000031
note: r (h)i,vi) Harmony value of the color theme, hiTo like number, viTo view number, σ (v)i) The standard deviation thereof is shown.
2) By sorting the data sets of Adobe and colorerrors, respectively drawing a harmony curve graph of a single color block and an adjacent color pair, wherein the x axis is a color tone value (0-360 degrees) with the interval of 1, and the y axis is a harmony value corresponding to the color. Curves are convolved and denoised by a gaussian filter with width 5 and σ equal to 1.
3) By analyzing the distribution trends of the two graphs, color pairs are selected as important factors for predicting the harmony value and applied to the second part.
A second part: constructing a maximum likelihood estimation prediction framework
1) The first section of research has shown that the color relationship of adjacent color pairs in a color theme of five different colors is more reflective of the harmony of colors. All five-color themes in the data set are thus segmented into four adjacent different color pairs and given the harmony values r (i) of the original five-color theme.
2) Sorting the divided adjacent color pairs, deleting the color pairs with repeated colors, and assigning harmony values to the unique color pairs without repetition so that a plurality of color pair values r (i) { r ═ r exist in the color pairs(i,1),r(i,2),…,r(i,n)N represents the number of repeated color pairs.
3) The distribution of each color pair and harmony value is counted by adopting Kolmogorov-Smirnov test, and the probability density function D is calculatednThe convergence situation determines whether the data satisfies the distribution:
Figure BDA0001959899380000041
where x is the color pair harmony values r (i), Fn(x) Is an empirical distribution function of x, F0(x) Is a cumulative distribution function of x,
Figure BDA0001959899380000042
is the supremum and represents the largest value in x. When D is presentnOn a time scale of → 0, the data is said to conform to the profile, otherwise it does not. In the embodiment, all distributions are substituted into data under 95% confidence space to be tested one by one, and the result shows that about 80% of the data conform to approximate normal distribution, 15% conform to extreme value distribution, and 5% conform to other distributions, such as gamma distribution, Weibull distribution and the like.
3) The data for determining the distribution condition is subjected to the calculation of maximum likelihood estimation so as to obey the sample N (mu, sigma) of normal distribution2) For example, the following steps are carried out:
Figure BDA0001959899380000043
and the obtained maximum likelihood estimation value is used as a final harmony degree prediction value of the adjacent color pair, and the value is in one-to-one correspondence with the color pair.
4) The color pairs are reduced in a look-up manner into a five-color theme such that one color theme has four different color pair harmony values.
5) And determining the distribution condition of each group of color subjects, calculating the predicted value of the color subjects by utilizing maximum likelihood estimation, and comparing the predicted value with the harmony value in the data set.
6) And optimizing a predicted value by utilizing linear regression of a least square method, and reducing the error of the harmony value in the same data set.
Finally, the two data sets are weighted by Mean Square Error (MSE) and Mean Absolute Error (MAE) and compared with the prediction result generated by LASSO regression. The final results are shown in the following table:
color harmony prediction result comparison table
Adobe MAE Adobe MSE CL MAE CL MSE
Prediction result by maximum likelihood estimation method 0.4637 0.3207 0.5836 0.6274
LASSO prediction results 0.5191 0.4456 0.6630 0.6875
Adobe denotes the Adobe Color CC dataset and CL denotes the COLOURLovers dataset.

Claims (3)

1. A color harmony prediction method based on maximum likelihood estimation is characterized by comprising the following steps:
a first part: analyzing color distribution relationship
1) Online crawlers are carried out on Adobe Color CC and COLOURLoverrs of online websites, and five-Color equal-area Color themes with the number of people over 10 and the corresponding watching numbers and praise numbers in the websites are obtained; fitting the watching number and the like into a harmony value of a color theme in a linear regression mode to serve as a data set;
2) respectively drawing harmony curves of a single color block and an adjacent color block pair by arranging data sets of Adobe and COLOURLovers;
3) selecting color pairs as important factors for predicting the harmony value by analyzing the distribution trends of the two graphs, and applying the color pairs to the second part;
a second part: constructing a maximum likelihood estimation prediction framework
1) Dividing all five-color themes in the data set into four adjacent different color pairs, and giving harmony values of the original five-color themes;
2) sorting the segmented adjacent color pairs, deleting the color pairs with repeated colors, and assigning a harmony value to the unique and unrepeated color pairs to enable the color pairs to have a plurality of color pair values;
3) the distribution of each color pair and harmony value is counted by adopting Kolmogorov-Smirnov test, and the probability density function D is calculatednThe convergence situation determines whether the data satisfies the distribution:
Figure FDA0003018597540000011
where x is the color pair harmony values r (i), Fn(x) Is an empirical distribution function of x, F0(x) Is a cumulative distribution function of x,
Figure FDA0003018597540000012
is supremum, representing the largest value in x; when D is presentnOn a time of → 0, the data is in accordance with the distribution, otherwise, the data is not in accordance;
3) carrying out maximum likelihood estimation calculation on the data of the determined distribution condition to obtain a maximum likelihood estimation value serving as a final harmony degree prediction value of an adjacent color pair, wherein the maximum likelihood estimation value corresponds to the color pair one by one;
4) restoring the color pairs into a five-color theme in a searching manner, so that one color theme has four different color pair harmony values;
5) determining the distribution of each group of color subjects, calculating the predicted value of the color subjects by utilizing maximum likelihood estimation, comparing the predicted value with the harmony value in the data set,
6) And optimizing a predicted value by utilizing linear regression of a least square method, and reducing the error of the harmony value in the same data set.
2. The method of claim 1, wherein the color harmony prediction method based on maximum likelihood estimation comprises: the harmony value of the color theme is fit by the watching number and the like in a linear regression mode, and the harmony value specifically comprises the following steps:
Figure FDA0003018597540000021
r(hi,vi) Harmony value of color theme, hiTo like number, viTo view number, σ (v)i) Is the standard deviation.
3. The method of claim 1, wherein the color harmony prediction method based on maximum likelihood estimation comprises: and the x axis in the harmony degree curve graph is a color hue value with an interval of 1, the y axis is a harmony degree value corresponding to the color, and the curve is subjected to convolution denoising through a Gaussian filter with the width of 5 and the sigma of 1.
CN201910079391.3A 2019-01-28 2019-01-28 Color harmony prediction method based on maximum likelihood estimation Active CN109903349B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910079391.3A CN109903349B (en) 2019-01-28 2019-01-28 Color harmony prediction method based on maximum likelihood estimation

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910079391.3A CN109903349B (en) 2019-01-28 2019-01-28 Color harmony prediction method based on maximum likelihood estimation

Publications (2)

Publication Number Publication Date
CN109903349A CN109903349A (en) 2019-06-18
CN109903349B true CN109903349B (en) 2021-07-02

Family

ID=66944353

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910079391.3A Active CN109903349B (en) 2019-01-28 2019-01-28 Color harmony prediction method based on maximum likelihood estimation

Country Status (1)

Country Link
CN (1) CN109903349B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112652024B (en) * 2020-12-11 2023-05-05 浙江工商大学 Method for replacing colors of images based on color harmony
TWI838887B (en) * 2022-09-28 2024-04-11 國立臺灣師範大學 Artificial intelligence importing personal photo background color recommendation system and method thereof

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7433511B2 (en) * 2003-10-17 2008-10-07 Hewlett-Packard Development Company, L.P. Color adjustment using black generation and under color removal
CN104657468B (en) * 2015-02-12 2018-07-31 中国科学院自动化研究所 The rapid classification method of video based on image and text
CN108564534A (en) * 2017-11-29 2018-09-21 宁波大学 A kind of picture contrast method of adjustment based on retrieval
CN109087364B (en) * 2018-08-08 2021-11-12 浙江工商大学 Method for predicting color harmony degree according to mode
CN108961346B (en) * 2018-08-08 2022-02-18 浙江工商大学 Method for predicting color harmony based on BP neural network

Also Published As

Publication number Publication date
CN109903349A (en) 2019-06-18

Similar Documents

Publication Publication Date Title
CN110992354B (en) Abnormal region detection method for countering self-encoder based on introduction of automatic memory mechanism
EP2161555B1 (en) Coating color database creating method, search method using the database, their system, program, and recording medium
Reinecke et al. Predicting users' first impressions of website aesthetics with a quantification of perceived visual complexity and colorfulness
Blostein et al. On modeling left-truncated loss data using mixtures of distributions
CN109903349B (en) Color harmony prediction method based on maximum likelihood estimation
McCann et al. Algorithm and benchmark dataset for stain separation in histology images
JP2023551514A (en) Methods and systems for accounting for uncertainty from missing covariates in generative model predictions
CN107016415A (en) A kind of coloured image Color Semantic sorting technique based on full convolutional network
Jain et al. Validating clustering frameworks for electric load demand profiles
CN108873401B (en) Liquid crystal display response time prediction method based on big data
WO2023236387A1 (en) Method and apparatus for predicting element information, and device and medium
CN115713634A (en) Color collocation evaluation method combining similarity measurement and visual perception
CN109271555B (en) Information clustering method, system, server and computer readable storage medium
CN111241372B (en) Method for predicting color harmony degree according to user preference learning
CN112085668B (en) Image tone mapping method based on region self-adaptive self-supervision learning
CN112257958A (en) Power saturation load prediction method and device
CN110751660B (en) Color image segmentation method
Gomez et al. The relationship between transcription and eccentricity in human V1
CN108022241B (en) Consistency enhancement quality evaluation method for underwater image set
CN108428226A (en) A kind of distorted image quality evaluating method based on ICA rarefaction representations and SOM
Czarnowske et al. Inference in unbalanced panel data models with interactive fixed effects
Li et al. Underwater image quality assessment based on multiscale and antagonistic energy
CN113673456A (en) Street view image scoring method based on color distribution learning
CN110991225A (en) Crowd counting and density estimation method and device based on multi-column convolutional neural network
CN109919392B (en) Data processing method and device, electronic equipment and computer readable storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant