Style DNA guide

Overview

Style DNA puts a number on how alike two pictures look, one measure at a time.

Two ornate portraits side by side above a white six-sided radar shape and 77% overall similarity
The sample pair side by side. Texture scores 100%, brightness 94% and warmth 46%; with every weight at 1.0 the overall similarity is 77%.

Two pictures can share a look without sharing a subject. Style DNA measures six parts of that look and scores each one from 0 to 100: how alike the two pictures are on that measure.

First it shrinks both pictures to 200 × 200 pixels. That is downsampling: the measures run fast, and the size of the file does not matter.

The six measures. Color histogram counts the red, green and blue values in each picture and keeps what the two counts share: a histogram intersection. Edge density finds edges with a Sobel filter and compares how much of each picture is edge. Texture compares local binary patterns: for each pixel, which of its eight neighbours are at least as bright, counted over the whole picture.

Brightness compares the average luminance and how widely it spreads. Contrast compares that spread measured against the average. Warmth compares how far the colours lean toward red and yellow rather than blue: warmth.

The radar draws the six scores as one shape; a full hexagon means the pictures match on every measure. The weights set how much each measure counts in the one overall similarity: an axis weight per measure.

Open Style DNA Start here

In this guide

  1. StartTwo pictures, six scores, and saving the result.
  2. Every controlEvery control in the panel, one line each.
  3. Three looksSide by side, blended and subtracted.
  4. HelpWhat to do when something goes wrong.

The sample pair loads and is scored as the page opens. It runs in your browser on a 2D canvas; it needs no WebGL. Your pictures are never uploaded.