1. A non-transitory computer-readable storage medium storing an image processing device that causes a computer to execute a process comprising: individually detecting, as a detection target candidate, a first portion of each of detection targets that appear in an image imaged by an imaging device, by using a first detection area corresponding to the first portion; detecting a detection target for a detection target candidate corresponding to a detection target that is not covered by another detection target and that is included in the detected detection target candidates, by using a second detection area corresponding to a second portion including the first portion; and detecting a detection target for a detection target candidate corresponding to a detection target, covered by another detection target and included in the detected detection target candidates, by using a third detection area that corresponds to a third portion including the first portion and whose amount of overlapping with the second detection area is less than a predetermined amount.