# Automated Image-Based User Interface Color Theme Generation
###### Abstract  
Color plays an essential role in the design of user interfaces and significantly impacts the user experience. To create aesthetically pleasing and user-friendly interfaces, the colors of the user interface should be consistent with the images. The latter can be challenging to achieve, as images often have different colors and are often changed by editors or authors who do not have sufficient design knowledge. To solve this problem, we have developed a model that automatically determines the color theme of the user interface based on a given image. The model first extracts the most prominent colors from the image and then considers both aesthetic (color harmony and compatibility with the image) and usability aspects (color contrast, color diversity, and color strength). All color calculations are performed in the perceptually uniform color space CAM02-UCS. In addition, the model can be adapted to the user's needs and requirements. To test the model, we implemented it in a web-based application in which the colors were automatically selected based on the featured image. The resulting color themes were then evaluated by the users, who were mainly professional designers. According to the results, the model generates color themes that are consistent with the image, aesthetic, and user-friendly. An important observation was also that color harmony can be achieved simply by using the most prominent colors of the image (regardless of their hue), suggesting that color harmony is strongly influenced by the context of use. The presented model holds significant practical importance as it can be utilized in various applications and tools. For instance, it can automatically choose a color theme for a user interface based on a particular image, such as a company logo or a product image. Moreover, it can dynamically adjust the colors of elements in real time based on the image that is visible simultaneously with the elements.  
a 2024 14 2850 10.100 10.100 10.100 10.100 10.100 10.1  
Much research in recent years has focused on creating models and tools for generating color palettes or themes. Despite being recognized as highly useful and practical, these tools exhibit at least one of the following deficiencies:  
* They do not consider the properties or characteristics of colors to achieve an optimal user experience (contrast, diversity, or prominence);
* They do not support dynamic, real-time computation of color themes;
* They do not support customization or settings to match user preferences;
* They do not consider images--the focus is solely on color harmony or preference.  
To address these shortcomings, we have developed a new model that automatically determines the UI color theme based on a given image and user preferences. When determining the color theme, the model starts by identifying the most prominent colors in the image. It then considers both the aesthetic aspect, such as color harmony and compatibility with the image, and the usability aspect, such as contrast between colors, color diversity, color suitability, and color strength. Furthermore, the model can be customized through settings to ensure that the generated color theme matches the user's requirements.  
This article is divided into two parts. The first part explains the framework and structure of the model, while the second part describes its implementation in a web-based application and its evaluation based on user feedback.