inferredBins = rects.map((rect) => {
const rx = +rect.getAttribute("x");
const rw = +rect.getAttribute("width");
const ry = +rect.getAttribute("y");
return {
x1: Math.round(x.invert(rx)),
x2: Math.round(x.invert(rx + rw)),
inferredCount: Math.round(y.invert(ry))
};
})