Cell sizes of a foam from an SEM image

SEM image of a foam with the evaluated cells marked in orange, with a page of the report and the cell size plot

In an SEM image of a foam a grey value threshold misses the brightly lit cells, while a trained segmentation model marks the cells with their floors, so that each cell can be measured.