1. An image processing method comprising: designating one point on input image data as a start point of a retrieval line, the input image data containing an image of a subject; designating one point, which is different from the start point, on the input image data as an end point of the retrieval line; preparing a cumulative line profile of the retrieval line by calculating a cumulative sum of luminance values on the retrieval line; and calculating an edge position on the retrieval line based on the cumulative line profile of the retrieval line, the edge position corresponding to a boundary of the subject in the input image data.