Formal definition of the Object Detection problem
This is just an idea
Given a set of pixels, the task is to decide:

Which pixel is the center of an object?
What is the size of the bounding boxes with the center is the pixel in part 1?

Formula, consider this is a 2D image, call $(x,y)$ is the horizontal and vertical coordinate and $(w_i,h_i)$ is the size of bouding box of object $i$:
$\text{For }m \in[x,x+w_i] \text{ and } n\in[y,y+h_i]$
$c_i(m,n) = \begin{cases}
    1, \text{if pixel at position (m,n) is belongs to object i,}\\
    0, \text{else}
\end{cases}$