Skip to content

Dark spots

Dark spots picks up deeper-pigmented marks — sun spots, age spots, post-inflammatory hyperpigmentation. Larger than freckles; more discrete than melasma patches.

component: dark_spots
request:
query: "components=dark_spots,dark_spots_adjusted,dark_spots_visualization"
response_path: "results[].description == \"dark_spots\""
value_range: [0, 1]
also_request:
- dark_spots_adjusted # cross-tone-comparable variant
- dark_spots_visualization # spot-type features, intensity range [0..400]
warnings: [] # dark_spots emits no metric-specific codes

Reference imagery for this metric is not yet published.

const ds = response.results.find((r) => r.description === "dark_spots");
// visualization_data lives on each measurement_locations[] entry, not on the
// top-level finding. Each feature is a "spot": length-1 x[]/y[] arrays.
const markers = (ds.measurement_locations ?? []).flatMap(
(loc) => loc.visualization_data ?? []
);

For “treat these specific spots” UIs, render those markers prominently. For routine recommendations, the aggregate value is enough.

Each measurement_locations[] entry also carries its own per-region value (0..1) alongside its mask_shapes. A region scores -1 when its mask couldn’t be sampled — treat that as “region unavailable,” not a real low score.

  • Distinction between Freckles and darks spots can be partially overlapping in some cases.

The dark_spots metric emits no metric-specific local_warnings[] codes. It inherits global image-quality codes; a skin-mask sampling failure is reported as 401 on the hyperpigmentation finding (which shares the same analysis), not on dark_spots.