DOC: Find the indices and number of pixels for rectangle shapes

open this branch due to conflicts in the previous branch( merge conflicts markers)
This should be `mesh = zeros(dectector_size, dtype=np.int64)`