Wildcard color¶
When performing a color search, the query colors can be manually defined and may include a wildcard color.
The wildcard color can be particularly advantageous when the user does not know exactly all colors he wishes to search for. In other words he needs to find images containing one or more known colors and one or more unknown or unspecified colors. To illustrate this, a possible example is when the user wants to retrieve images containing 50% red, 20% blue and 30% any other colors (see the color picker below). The 30% other colors do not need to be specified by the user and could be, for example, orange and green or just yellow, hence the term wildcard color.
Usage example¶
A specific usage example for the wildcard color is helping a user to search through his personal collection to find a particular image. For example, a user may be looking for an image of a friend wearing a red shirt on a hiking trip they took together many years ago. Because of the high volume of digital photos this user has, it may be difficult to sort through many thousands of image to find this particular image. With wildcard color searching, the user can search for an image that has some red and some blue (e.g., for the sky), with remaining possibilities being covered by the wildcard color. This approach can greatly filter the number of images that need to be reviewed in order to find the desired image.
Sample user interfaces¶
Below is an example of a color picker that can be used to define the query colors. This sample user interface contains a color picker for selecting colors and a color slider for defining the overall weight for each selected color. The color slider allows the user to define color weights so their sum is equal with 100%.

The figure below illustrates a user interface suitable for displaying search results. On the right side of the display screen is a color picker consistent with the one shown above. In this example, query colors are, as indicated, 21% red and 79% wildcard (displayed in the chequered neutral background pattern). Best matching images identified within a collection are presented to the user as uneven tiles in a rectangular grid at the left of the display screen.

Another example below illustrates the same user interface, wherein the query colors are 47% orange and 53% wildcard.

Request examples¶
Colors (with a wildcard color)¶
curl https://multicolorengine.tineye.com/<company>/rest/color_search/ \
-F "colors[0]=E7402D" \
-F "colors[1]=7FC1D9" \
-F "colors[2]=wildcard" \
-F "weights[0]=30" \
-F "weights[1]=30" \
-F "weights[2]=40"
curl https://multicolorengine.tineye.com/<company>/rest/color_search/ \
-F "colors[0]=162,96,149" \
-F "colors[1]=232,75,110" \
-F "colors[2]=wildcard" \
-F "colors[3]=61AA54" \
-F "colors[4]=F6D727" \
-F "weights[0]=20" \
-F "weights[1]=20" \
-F "weights[2]=30" \
-F "weights[3]=15" \
-F "weights[4]=15"
Colors (with a wildcard color and bad weights)¶
curl https://multicolorengine.tineye.com/<company>/rest/color_search/ \
-F "colors[0]=BA9B7B" \
-F "colors[2]=wildcard" \
-F "weights[0]=50" \
-F "weights[2]=60"
Response examples¶
An error message will be returned if the sum of weights is greater than 100%.
JSON¶
{
"status": "fail",
"error": [
"Weights cannot add up to less than 0 or more than 100."
],
"method": "color_search",
"result": []
}
XML¶
<?xml version="1.0" encoding="utf-8"?>
<data>
<status>fail</status>
<error>
<item>Weights cannot add up to less than 0 or more than 100.</item>
</error>
<method>color_search</method>
<result/>
</data>
If the sum of weights is less than 100% then the color search will be performed, however, all weights will be scaled up proportionally during the search so their sum is 100%. For example, if two query colors are used (one of them may or may not be the wildcard color) and the provided weights are 20% and 30%, then the actual weights used during the search will be 40% and 60%.