1. An image processing apparatus, comprising: an acquisition unit configured to acquire image data expressing an image including a specific subject; a production unit configured to produce a contour signal expressing a contour portion included in the image; a detection unit configured to detect, on the basis of the contour signal, a representative contour direction for each of a plurality of division regions obtained by dividing up the image, the detection unit detecting a specific direction as the representative contour direction when the direction of the entire contour portion included in the division regions is biased in the specific direction by at least a specific degree; a determination unit configured to determine a type of the subject on the basis of at least one of the following: a direction-based frequency distribution of the detected representative contour directions, a degree to which the division regions in which a representative contour direction of a predetermined direction was detected are continuously aligned in a direction perpendicular to the predetermined direction in the image, and a number of representative contour directions detected; and a correction unit configured to correct the image data according to a correction method corresponding to the type of the subject.