Photo and classification · red = classified as particle, blue dashed = true outlineTap to show the photo only
Detected area ÷ true area –Blobs –
Pixel-value histogram · log vertical axisred line = threshold
Threshold –Coarse-particle diameter –
Backlight = shadows on a light pad
Elevation above the surface
Light that fills in the shadows
Share of the frame covered by particles
Brightness difference, left to right
Above 1, the background blows out to white
Relative to background brightness
Removes uneven lighting
Assumes a phone main camera at 15 cm (one pixel = 49.5 µm), blur σ 0.8 px, 2% noise, and pixel values stored as sRGB. Particle height is taken as 0.6× the diameter and coffee reflectance as 8% of the paper’s. Coarse particles are 300 µm and up. This is a model, not a real photo.