Real Face Shape Detector

How it works

Local inference, visible reasoning.

The detector is a browser pipeline, not a remote AI service. This page explains what happens to the image, what the model measures, and where the styling suggestions come from.

01

The photo is decoded locally

Your browser reads the file, corrects its orientation, and scales it down for analysis. The image never leaves the device.

02

A local landmark model finds facial points

The bundled MediaPipe Face Landmarker model returns 478 normalized points, blendshapes, and a transformation matrix. The model and WASM runtime are served from this site.

03

The app checks whether the photo is usable

Face count, face size, sharpness, exposure, head roll, yaw, pitch, and eye openness are combined into a capture-quality score with specific warnings.

04

Landmarks become normalized measurements

The eye line is aligned, then widths, lengths, taper, thirds, symmetry, eye spacing, tilt, and brow arch are calculated as ratios.

05

Seven shape prototypes are compared

Each shape has weighted ranges for length-to-width, forehead-to-jaw, cheek-to-jaw, jaw-to-face, and lower-jaw taper. The scores are normalized and sorted. The jaw contour angle is reported for inspection but is not scored because it overlaps between shapes and shifts with pose.

06

Colour and styling rules are applied

Visible skin pixels are sampled for a Lab/ITA reading. Deterministic rules turn the shape and palette into hair, frame, grooming, colour, and outfit directions.

References are not analysis

Illustration and inference are separate.

The editorial portraits on this site are AI-generated references. They are not analysis overlays, not training data, and not compared with your photo. The detector only runs the local landmark model on the image you choose, then applies the measurement rules described above.

Some references are study sheets or a split-face symmetry composite. They are placed at a larger size so the variation stays visible. A single portrait was never meant to define a category.

Split-face symmetry study of a woman with a diamond-shaped face, prominent cheekbones, and a narrow forehead.Symmetry study
Grid of six portrait studies of men with triangle-shaped faces, broader jaws, and narrower foreheads.Portrait study

What runs where

The server sends files. It does not receive a face.

The site is static. The hosting layer serves HTML, CSS, JavaScript, fonts, icons, the model, and the WASM runtime. After those assets load, analysis happens in a Web Worker where the browser supports it, with a main-thread fallback.

AssetPathNotes
Face model/models/face_landmarker.taskBundled with the site. No model API call.
WASM runtime/wasm/vision_wasm_internal.js + .wasmServed from this origin, with SIMD support checked first.
FontsGeist Variable + Geist Mono VariableSelf-hosted through Fontsource packages.
IconsLucide + inline SVGNo icon CDN.

What the model gives us

Landmarks are not the result.

The landmark model returns 478 normalized 3D points, not a face-shape label. The app is responsible for the measurement logic, the classification prototypes, the quality score, and the recommendations. First, the browser decodes your photo with createImageBitmap, handles EXIF orientation, and scales the image to a bounded canvas before passing pixel data to a dedicated Web Worker (with a main-thread fallback if workers are restricted).

Next, every landmark is rotated around the outer eye-corner midpoint so the eye line sits level, removing camera roll before ratios are computed. Five normalized ratios—length-to-width, forehead-to-jaw, cheek-to-jaw, forehead-to-cheek, and jaw-to-face—are scored against seven weighted prototypes, while lower-jaw taper (136/365) and jaw angle are reported for inspection without biasing the score. No trained face-shape image classifier is bundled; the closest geometric match and its alternatives are shown with uncertainty.

The model is the MediaPipe Face Landmarker distributed by Google under the Apache 2.0 license. Both the .task model and WebAssembly runtime are bundled locally from this origin; photo analysis never calls an external AI API.

What can go wrong

Every pipeline has failure modes.

A turned head (yaw over 12°) compresses one cheek and inflates cheek-to-jaw asymmetry. A high or low camera angle (pitch over 14°) foreshortens or stretches face length. Wide-angle selfie lenses held close to the face enlarge the nose and cheeks relative to the temples and jaw. Strong glasses, a heavy fringe, or a cropped hairline can hide landmarks 10, 127/356, or 234/454.

Our capture-quality pass evaluates face area (flagging crops under 6% or over 68% of frame), Laplacian sharpness variance (flagging blur below 26 and soft focus below 70), mean luminance (58–208 range), clipped highlights, and eye-blink blendshapes. If the score drops below 58, the report automatically marks the reading Exploratory and prompts you to try a steadier, better-lit photo.

You can inspect every ratio, toggle landmark and measurement lines directly over your session preview, override the primary shape label without erasing the underlying numbers, or save/export a photo-free JSON brief for your barber, stylist, or optician.

Go deeper

The measurement definitions and limits.